Re: [gtk-list] gtk_label and internationalisation question



In article <XFMail.981218031806.asbel@dial.pipex.com>
asbel@dial.pipex.com writes:

>> 
>> Hi,
>> 
>> I notice that gtk_label has followed gtk_entry in moving to wide chars
>> internally. While this sounds like a great idea in theory, I'm having
>> trouble working out how to get actual multibyte text into the label
>> under the new scheme. Before I could simply do something like...
>> 
>>   /* create Japanese style */
>>   jstyle = gtk_style_new();
>>   jfont = gdk_fontset_load("-*-fixed-medium-r-*--16-*-jisx0208.1983-0");

This line seems odd. If you want to load a single font, you should
use gdk_font_load() instead.

>>   gdk_font_unref(jstyle->font);
>>   jstyle->font = jfont;
>> 
>>   /* Insert Kana "A" */
>>   gtk_label_set_text (GTK_LABEL(search_entry_mode_label),"\x24\x22");
>>   gtk_widget_set_style (search_entry_mode_label, jstyle);

I guess you are trying to draw 2-byte characters without locale
support, aren't you? If so, we have to add 2-byte font support
into *_wc() functions. Shall I write a patch?

--------------------------------------
Akira Higuchi
Dept. of Mathematics, Hokkaido Univ.
Hokkaido, Japan
Email: a-higuti@math.sci.hokudai.ac.jp



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]