"Venkat Ramakrishnan" <[EMAIL PROTECTED]> writes: > I am new to GTK+ . I used to use X and motif calls for UI design and > i really find GTK to be very flexible and powerful. Thanks to the > people who brought it up . > I have a small question . I want to write some strings into a drawing > area using certain fonts . And I am using Pango for this . Now I want > to find out the height and width (ascent and descent etc) of the > string so that i can place it properly . Hence I am using the > PangoFontMterics. > But there is one call which is confusing for me > pango_language_from_string (const char *language); > where > language : a string representing a language tag (as the API says) > > Can somebosy tell me what string to passed as the "language" in the > above call .Is it related somehow to the locale . > I tried passing the string (i want to draw , but it does not work ) > I mean for different strings I get the same ascent and descent . > > I am confused . I think the ascent and descent is based on the font > being used . > I would apprecite any help on this. Is there any application using > pango . Cyrrently I am refering the API Refarence (from gtk.org) >
Rather than fooling with font metrics, you probably just want to call pango_layout_get_pixel_extents(). If you need a PangoLanguage gtk_get_default_language() is the simplest way. Havoc _______________________________________________ gtk-list mailing list [EMAIL PROTECTED] http://mail.gnome.org/mailman/listinfo/gtk-list
