Xt translated labels ?
glynn at gclements.plus.com
Sat Aug 26 10:48:40 PDT 2006
Samuel Thibault wrote:
> > > fr/app-defaults/XTerm.msg contains translations:
> > I would expect so.
> Is there a usual "suffix" instead of ".msg" that I arbitrary chose?
app-defaults files occasionally have a ".ad" suffix, but this is
usually removed when the file is installed.
> Some debian people were also wondering about UTF-8 support. I tried
> XTerm with a UTF-8 locale, and it was still using the latin1 encoding.
> Is it always this way with, say, Xaw applications?
Regarding XTerm, see the documentation for the "utf8" and "locale"
resources (-u8 and -lc options) in the xterm(1) manpage. UXTerm is a
script which runs XTerm with the relevant options.
Athena widgets have two distinct modes of operation, depending upon
whether the widget's "international" resource is set.
If unset, label strings use either unibyte or 2-byte encodings,
depending upon the setting of the "encoding" resource; the "font"
resource determines how these strings are displayed (i.e. Athena
itself just treats strings as strings of bytes or byte-pairs, not
If set, label strings are interpreted according to the locale
(although I don't think that meta-encodings such as UTF-8 or ISO-2022
work), and the "fontSet" resource is used instead of the "font"
Also, to get the internationalised behaviour, XtSetLanguageProc() must
be called prior to calling XtDisplayInitialize() or XtAppInitialize(),
otherwise the widget behaves as if the "international" resource is
false, regardless of its actual setting.
Motif uses compound strings (XmString) for labels; string resources
stored in resource files are interpreted according to the locale
(although, again, I don't know whether it will accept UTF-8).
Glynn Clements <glynn at gclements.plus.com>
More information about the xorg