Re: Hebrew Support in GTK+



"Gilad Rom" <rom_glsa ein-hashofet co il> writes: 
> I am looking for some tips on using Pango (the pango home page does not have
> example
> code on-line, and the API reference seems very complicated), so If anyone
> has some code
> which uses a non-latin language and specifically ISO-8859-8/6
> (Hebrew/Arabic, which are written right-to-left) codepages,  I'd be very
> happy to receive some information about general usage.
>

Pango requires the use of Unicode, so you would use a function such as
g_convert() (or iconv() from the C library) to convert ISO-8859-8/6 to
UTF-8 before passing it to Pango.  However, typically you would not
use Pango directly, rather you just set some Unicode text that happens
to be Hebrew into a GTK widget, such as GtkLabel, and the appropriate
thing will happen. GTK should automatically determine that the default
text direction is right-to-left if your locale is a right-to-left
locale, though this depends on someone having done the translation
work for GTK for your locale. (Not hard work to do, if it's not done.)

All this applies to GTK 2.0; for GTK 1.2, you won't be able to get
this stuff working, basically.
 
> Plus, I've checked out and built the development (1.3) branch, which seems
> to be the only branch which has these specific options included (fb and
> Pango support).

Right. 1.3.x is the unstable development branch where we are
introducing these features. It isn't yet API-frozen, so expect a few
bugs and things. But it should be stabilizing now. (You can track
progress and report issues on http://bugzilla.gnome.org, query for the
"2.0.0" and "2.0 API freeze" milestones on the glib/pango/gtk+
products.)

> I have an ATI Mach64 card, which appears on the supported Frame Buffer cards
> list, and I can
> boot init on a graphical mode (I have the small Tux icon on top), however,
> Gdk cannot
> open /dev/fb0 for some reason. Has anyone successfully used it?
> 

Alex may be able to answer this, he's been hacking on the linux-fb
port.

Havoc




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]