Background:
- I have some unicode characters in my prompt (git status markers essentially)
- I'm running urxvt under xfce on arch linux.
I'm using DejaVu Sans Mono for Powerline font, specified via .Xresources line:
URxvt*font: xft:DejaVu Sans Mono for Powerline:pixelsize=14
When I start urxvt the unicode characters do not render correctly.
For example
● renders as â
However, if I then start a new urxvt
from inside the first terminal everything renders correctly.
There doesn't appear to be any difference in the environment between the two terminals.
What could be the difference between the first invocation and the nested invocation? I suspect the font is not correct in the 'outer' instance, but I'm unsure how to check the font of a running X window
UPDATE: It seems that the locale is not correctly set up in the app launcher for xfce4, but presumably the shell inside the first terminal inits it's own locale, meaning that both shells have the same locale.
adding
export LANG=en_GB.UTF-8
to .xinitrc before xfce4 is started seems to fix it. I suspect this isn't the correct way, but it works well enough for me.
screenshot demonstrates the problem:
Note: I moved this question from serverfault.com - i hope this site is more appropriate
LC_ALL=ru_RU.utf8 urxvt
from the current X session. If the Russian (and other Unicode) chars became correct you are in case when your environment have been running under C locale. So check locale settings forxfce
. For example if you are started it in.xinitrc
try to set locale before run likeLANG=ru_RU.utf8 exec startxfce4
.