Re: GDK_FONT_XFTFONT
- From: Owen Taylor <otaylor redhat com>
- To: Keith Packard <keithp keithp com>
- Cc: gtk-devel-list gnome org
- Subject: Re: GDK_FONT_XFTFONT
- Date: Mon, 25 Feb 2002 10:35:10 -0500 (EST)
Keith Packard <keithp keithp com> writes:
> I've added a third enum to the the kinds of fonts gdk exposes to
> applications. The abstraction is already sufficient for many applications
> to operate quite nicely; making it official for Gtk+ 2.n would allow
> application developers to prepare their code for this condition.
>
> Yes, this change obviously breaks many application assumptions about how
> fonts work in Gtk. I don't know any alternative that will eliminate
> server-side fonts from Gnome; the only perfectly compatible system is one
> which never changes.
>
> To protect code which is unprepared for a third alternative, I suggest that
> the application be able to force the library to skip the Xft code when
> opening fonts. In my current patch, I control it with an environment
> variable (export GDK_XFT=0 to disable Xft text).
>
> With this and Pango support for Xft, I've been able to eliminate ugly text
> from the Gtk+ 2.0 apps on my screen.
What we decided for GTK+-2.0 is is that we would simply deprecate
GdkFont and keep them working the same way, rather than trying to make
them take advantage of any of the new features of GTK+-2.0.
GTK+-2.0 programs shouldn't be using GdkFont at all, but rather using
Pango for everything. (The one widget that hasn't been converted over
- GtkText, is there only as a porting aid - you have to define
GTK_ENABLE_BROKEN to get it at all.)
Some programs haven't been converted yet:
gnome-terminal - it actually mostly access X11 fonts directly, probably
easiest to switch it over using Xft directly. Complex-text in
a terminal is a very different proposition than real complex-text
so Pango is a poor match here.
xchat - Main text widget hasn't been ported yet; needs a rewrite
to work in terms of Pango.
But the planned path is definitely to get rid of GdkFont rather than
trying to fix it.
(It's not just rendering technology -- it doesn't fit into the "new
world" in terms of font naming, character set handling, etc.)
Regards,
Owen
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]