home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / windows / x / motif / 8911 < prev    next >
Encoding:
Text File  |  1993-01-28  |  3.0 KB  |  63 lines

  1. Newsgroups: comp.windows.x.motif
  2. Path: sparky!uunet!europa.eng.gtefsd.com!emory!gatech!paladin.american.edu!howland.reston.ans.net!spool.mu.edu!uwm.edu!cs.utexas.edu!swrinde!sdd.hp.com!hp-cv!hp-pcd!hpcvusn!hpcvusc.cv.hp.com!tommc
  3. From: tommc@hpcvusc.cv.hp.com (Tom McFarland)
  4. Subject: Re: Japanese characters for XmLabel
  5. Message-ID: <1993Jan28.190655.18382@hpcvusn.cv.hp.com>
  6. Keywords: Japan, Label, String
  7. Sender: nobody@hpcvusn.cv.hp.com (Nobody - UID must be 99999)
  8. Nntp-Posting-Host: hpcvusc.cv.hp.com
  9. Reply-To: tommc@cv.hp.com
  10. Organization: Hewlett Packard UTD-Corvallis
  11. References:  <1j413oINN9r2@hal.com> <1993Jan26.095201@lectra.fr>
  12. Date: Thu, 28 Jan 1993 19:06:55 GMT
  13. Lines: 48
  14.  
  15. In article <1993Jan26.095201@lectra.fr>, pierre@lectra.fr (Pierre Ficheux) writes:
  16. |> In article <1j413oINN9r2@hal.com>, randolph@hal.COM (Randolph Bertin) writes:
  17. |> > 
  18. |> > How can I display Japanese characters on an XmLabel (PushButton, etc)
  19. |> > widget?  Ideally, I would like to be able to set up a Japanese version
  20. |> > of the resource file containing all of the label strings.
  21. |> > 
  22. |> 
  23. |>     No problem. You just have to put the ascii string corresponding to the
  24. |> kanji character 16 bits code ==> example with the k14 font :
  25. |> 
  26. |>     *fontList: k14
  27. |>     *label1*labelString:    0!
  28. |> 
  29. |>     It will display the first kanji charactere of the k14 font (code 0x3021 =>
  30. |> string 0!).
  31.  
  32. Actually, this is a function of vendor and release of Motif.  As of Motif 1.2,
  33. all that should be necessary is to specify the string in the codeset of the
  34. locale (i.e. type it into the defaults file using a japanese term emulator
  35. and an internationalized editor).  For example, on HP systems I would launch
  36. an hpterm with LANG=japanese (or LANG=japanese.euc if I wanted EUC instead of
  37. shift-JIS encoding) and a japanese font selected.  Then I would vi the resource
  38. file and type in a shift-JIS (or EUC) string of mixed ASCII, 8-bit Katakana
  39. and 16-bit/24-bit Kanji.  Then when launching the application, all that is
  40. necessary is to make sure the application's LANG is set appropriately and
  41. that a fontset is specified in the applications font list.
  42.  
  43. For pre-1.2, each vendor provided his/her own solution.  In HP's case,
  44. the situation is pretty much as described above, except the concept of
  45. fontsets didn't exist.  Instead, it was necessary to specify a Japanese
  46. font (such as jpn.8x18 or jpn.12x24).  Vendors that did not internationalize
  47. their Xlib or their Xt would have to resort to the work around described
  48. by Randolph above.
  49.  
  50. |>  ._______________________________.__________________________. 
  51. |> +-------------------------------'--------------------------'|
  52. |> | Pierre FICHEUX                | tel   : +33 56 68 80 00  ||
  53. |> | Lectra Systemes               | fax   : +33 56 78 88 31  ||
  54. |> | ZI Marticot 33610 CESTAS      | E-mail: pierre@lectra.fr ||          
  55. |> | FRANCE                        |                    ||    
  56. |> `-------------------------------^--------------------------'
  57. |> Comment ? (Beethoven)
  58.  
  59. Tom McFarland
  60. Hewlett-Packard, Co.
  61. R&D Motif team
  62. <tommc@cv.hp.com>
  63.