Sun Microsystems, Inc.
spacerspacer
spacer www.sun.com docs.sun.com |
spacer
black dot
 
 
6.  Complex Text Layout Text Resources and Geometry  Previous   Contents   Next 
   
 

Porting Instructions

The new Motif library enabled for Complex Text Layout (CTL) , is located in /usr/dt/lib/libXm.so.4. If your application links to libXm.so.3 it does not support CTL. ldd app_name shows the library to which the application is linking. To port the existing applications to enable CTL, you need to perform the following steps.

  1. Add -DSUN_CTL to your Makefile. This flag is important and includes the necessary data structures to support CTL. This should be set during compilation.

  2. Recompile the existing application. This recompilation automatically links with the CTL-enabled Motif library libXm.so.4

  3. Add the XmText.translations resources to your application resource file. Without these resources, the layout engine of the locale does not launch.

  4. Refer to the sample application attached to your documentation.


Note - Use the font name that is available and appropriate to your locale in the fontName resource.


For example, if you want the cell-based character movement (Thai) in XmTextField or XmText widgets, set the translations of the corresponding widgets as follows:

XmText.translations: #override \n\

<Key>osfRight:forward-cell() \n\

<Key>osfLeft:backward-cell() \n\

<Key>osfDelete:delete-next-cell() \n\

<Key>osfBackSpace:delete-previous-cell() \n\

 
 
 
  Previous   Contents   Next