non-ascii characters in Gtk+

From: Alexander Nikolov (at_nikolovNOSPAM_at_mnet.bg)
Date: 01/28/04


Date: 28 Jan 2004 16:32:39 +0200

I am using KDE 3.1.3 on a Gentoo system. I have gtk+-1.2.10-r10, gtk+-2.2.4-r1
installed. My locale is bg_BG.CP1251(bulgarian with windows-cp1251 cyrillic
encoding). When I try to use a Gtk+2 app such as Gaim boxes with numbers inside
are displayed instead of cyrillic characters. It is the same with a wxGTK app
such as xMule.

I have installed cronyx cyrillic fonts with cp1251 and Ms Windows ttf
fonts. This is the content of my /etc/X11/gtk/gtkrc.bg_BG.CP1251 file:
,----
| style "gtk-default-cp1251" {
| fontset = "-monotype-Times New Roman-bold-r-normal--0-0-0-0-p-0-microsoft-cp1251,\
| -cronyx-helvetica-medium-r-normal--*-*-*-*-*-*-microsoft-cp1251,\
| -cronyx-courier-medium-r-normal--*-*-*-*-*-*-microsoft-cp1251,\
| -cronyx-times-medium-i-normal--*-*-*-*-*-*-microsoft-cp1251"
| }
| class "GtkWidget" style "gtk-default-cp1251"
|
`----
The first one is a ttf font. All font names are taken from fonts.dir files in
the respective diretories. The file /etc/X11/gtk/gtkrc.bg_BG.CP1251 is a
symlink to /etc/X11/gtk/gtkrc.bg which is a symlink to
/etc/X11/gtk/gtkrc.cp1251. I have symlinked /etc/X11/gtk to /etc/gtk and
/etc/X11/gtk/gtkrc.bg_BG.CP1251 to /etc/gtk-2.0. When nothing worked I created
a ~/.gtkrc-2.0 with the following content:
,----
|
| gtk-font-name = "Times New Roman 12"
|
| gtk-key-theme-name = "Emacs"
`----
This did change the font for Gaim and xMule but didn't stop them from
displaying cyrillic characters as boxes with numbers inside. Still this is a
windows ttf font and it is capable of displaying cp1251-encoded text- I can use
it successfully in KDE, for example, to write in cyrillic.
Any help appreciated.

-- 
export AUTHOR=Alex\ Nikolov
echo $AUTHOR


Relevant Pages

  • Re: Unicode symbols in my app not displaying on other workstations
    ... I clicked yes and then deployed the app (using Click ... Most likely you are using a font which is not available in the same version on the target machine. ... Which font are you using for the character not displaying on the machine? ...
    (microsoft.public.dotnet.languages.vb)
  • Re: display problems in W2K TS client / W2K server is VirtPC guest
    ... I noted that I am having the same graphics issues when I run ... > You will have to install the Century Gothic font on the server. ... >> I have just converted a desktop app to be Terminal Services ...
    (microsoft.public.win2000.termserv.apps)
  • Re: Mobile2Market help...
    ... Since my app is mainly in the CF, ... > options must appear in this order, left to right: style, font, font size, ... > side of my form, I have the checkboxes for Bold, Italic, Underline, from ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: Bullet weirdness
    ... parts after looking into the bullets). ... I'm still stumped as to why my simple document is displaying different ... only the two computers. ... I think opened Font Book and both computers have Cambria ...
    (microsoft.public.mac.office.word)
  • Re: Mobile2Market help...
    ... You can see this in practise on any of the settings dialogs e.g. Start> ... Peter Foot ... Since my app is mainly in the CF, ... >>> options must appear in this order, left to right: style, font, font ...
    (microsoft.public.dotnet.framework.compactframework)