dimitar@quintus.UUCP (Dimitar Bojantchev) (10/06/90)
I am unable to display text in the XmText widget if I set the font to k14, (two byte, Japanese font). Looking through the sources of the text widget it seems that it should handle 16 bit characters, at least there is code to invoke XDrawImageString16 to draw the text. It seems that I am setting the right character codes because it works for me if I invoke XDrawImageString16 directly. What am I doing wrong then? I am using Motif1.0 and Motif1.1 on SUN4/110. Thanks, Dimitar -- Dimitar Bojantchev ARPANET: quintus!dimitar@SUN.COM Quintus Computer Systems, Inc. ...sun!quintus!dimitar 1310 Villa Street tel. (415) 965-7700 Ext. 314 (work) Mountain View, CA 94041 (415) 964-4361 (home)
ogawa@sm.sony.co.jp (Masato Ogawa) (10/16/90)
In article <1431@quintus.UUCP> dimitar@quintus.UUCP (Dimitar Bojantchev) writes: > I am unable to display text in the XmText widget if I set the font to > k14, (two byte, Japanese font). Looking through the sources of the > text widget it seems that it should handle 16 bit characters, at least > there is code to invoke XDrawImageString16 to draw the text. It seems > : No. I'm looking the source in few days (and more), there is not the right implementation for 16bit code in XmText. XmText works with "block" structure as you know, but everywhere to set string data into the structure, block.format is set to FMT8BIT. So every data are treated as "roman". In some places, there are codes for FMT16BIT, but I think they haven't tested. For example, the "Draw" routine in TextOut.c, the x value of XDrawImageString16 must be offseted by hoffset of XmText, but not (refer to the FMT8BIT portion in that routine to know how it should be written ). So, If you could set FMT16BIT data into XmText, Kanji's are never scrolled horizontally. And more essential question: How to treat mixed sentense with Kanji and roman alphabet with XmText...