"╭─ " Character combo in $PATH causes strange autocompletion behavior in zsh

I've posted about this before, but only recently narrowed the problem down to a specific cause.

Ok, first of all, the behavior:

It occurs when autocompletion brings up its list (not when there is only a single option). Basically, if I were to type, say,

cd ~/<TAB>

I would get something like:

cd ~cd ~/.FontForge/ 

Where FontForge is the first item in my list, and the first "cd ~/" is duplicated (but it doesn't affect the command and it can't be deleted either).

Incidentally, I have noticed the problem goes away when using a TERM other than xterm-color.

However, I have determined what is causing the issue with xterm-color. Specifically, my prompt is set up as follows:

local smiley="%(?,%{$fg[green]%}:%)%{$reset_color%},%{$fg[red]%}:(%{$reset_color%})"

PS1="[$PR_LIGHT_MAGENTA%n$PR_NO_COLOR@$PR_GREEN%U%m%u$PR_NO_COLOR:$PR_RED%2c$PR_NO_COLOR]
[ ${smiley} ] %(!.#.$) "

RPS1="$PR_LIGHT_YELLOW(%D{%m-%d %H:%M})$PR_NO_COLOR"

I chipped away at that, eventually character by character, until I discovered that the "" and "" character combos are to blame (any of those characters seems to be sufficient to cause the issue). Removing those 4 characters resolves the issue.

The thing is, I like those characters in my prompt.

So, does anybody have any idea what's going on here?

Incidentally, I am running Mac OS X (Lion, although this problem goes back at least to snow leopard) and zsh 4.2.7.

sounds like a character encoding mismatch. are you seeing this error from within Apples terminal ? try with a non apple terminal window. then check the encoding in the preferences . There is an emulation feature and character encoding setting in the terminal preferences.

hope this helps

My character encoding is set to Unicode (UTF-8).

Changing to to anything else resolves the issue, but then my characters are no longer the same either.

What's the deal with those characters anyway? I only use them for a bit of ASCII "art", but they seem to be interpreted as something other than merely a character.

---------- Post updated at 06:32 PM ---------- Previous update was at 06:08 PM ----------

Just tried iTerm2, and the problem is present there as well.