Re: ISO 10646 fonts in GTK+

Robert Brady <> writes:

> On 16 Aug 1999, Owen Taylor wrote:
> > > If it does work, probably a medium-term hack would involve forcing 
> > > *-iso10646-1 fonts to have their ranges set to 0x0000 to 0x00ff in GDK 
> > > somewhere. Would this be an acceptable solution for 1.2?
> > 
> > That is closer to being acceptable, but I believe the correct
> > solution is simply to specify the encoding for the fonts
> > that GTK+ loads by default; having it as a wildcard really
> > never made sense (I can conceive of people using this to
> > get their native character set by arranging their font path,
> > but that was 
> This solution had not occurred to me. It certainly makes sense, and would
> be trivial to do. (just change -*-* to -iso8859-1) in gtkstyle.c (and,
> for completeness, the test program). Will this happen in the next stable
> release of GTK+?
> The downside of this is that it does not magically fix applications.
> It is hard to estimate, but on, there are 95 files which
> call gdk_load_font, some files calling it multiply, and a fair proportion
> of these use -*-*. There are no doubt many apps not in cvs that use
> similar strings. They will _all_ break when pointed at iso10646-1 fonts.
> If you aren't convinced by that argument, which I admit isn't very
> strong, then I suppose I had better get making patches to send off to the
> appropriate maintainers...

No, it is a fairly convincing argument. We cannot assume
that people will upgrade all GTK+ apps when they upgrade
to XFree86 4.0. (Though I would recommend that the XFree86
people think about making 8859-1 appear before 10646-1
by default - if nothing else it will speed up programs
that do XLoadQueryFont, possibly by a _lot_, if you
have Unicode fonts including the Han characters.)

I guess the fallback position I would take is that
we should add a hack to GTK+ where the double-byte
font logic is disabled for iso10646-1 fonts with
an explicit check.

This still could conceivably break some apps, but
only those programs that are trying to draw Unicode
characters by glyph index explicitely, and I don't
know of any such GTK+ programs offhand.

(There is some irony there, though)


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