[gtkada] Text widget that can display Wide_Strings

Emmanuel Briot briot at ACT-Europe.FR
Mon Aug 13 15:26:54 CEST 2001


Rabbix het Netwerkkeun writes:
 > Does Gtkada contain a widget like Gtk_Text that can display Wide_Strings
 > or as has anyone already constructed such a widget?
 > 
 > The only 'primitive' to draw a Wide_String aka Gdk_WString I could find
 > is the Draw_Text prcedure defined in the Gdk.Drawable package. However,
 > this procedure is nowhere used in the Gtkada library.


The Draw_Text procedure is probably a direct mapping, on X-Window systems, to
XDrawString16.
This might indeed be what you are looking for, if you want to draw text
directly yourself. However, Gtk_Text doesn't use it (you have to look in the
sources of gtk+, not GtkAda to find this out).
So the short answer is that, as far as version 1.2.* are concerned, there is
indeed no way to display wide strings (and in fact, it is a known problem on
windows that even european accented letters can not be displayed properly).

The good news is that the next version of gtk+ (and thus GtkAda) do support
fully wide strings (and in fact probably more than you need, including
right-to-left printing, asian characters, ...). This is available in CVS
already, see
   http://libre.act-europe.fr
if you want to give it a try.

Emmanuel




More information about the gtkada mailing list