[Top][All Lists]

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

Pango-like font fallback (was Re: Russian numero sign)

From: Paul Pogonyshev
Subject: Pango-like font fallback (was Re: Russian numero sign)
Date: Thu, 23 Feb 2006 22:37:54 +0200
User-agent: KMail/1.7.2

Kenichi Handa wrote:
> In article <address@hidden>, Paul Pogonyshev <address@hidden> writes:
> >   character: � (3696, #o7160, #xe70)
> >     charset: cyrillic-iso8859-5 (Right-Hand Part of Latin/Cyrillic Alphabet 
> > (ISO/IEC 8859-5): ISO-IR-144.)
> >  code point: #x70
> >      syntax: .      which means: punctuation
> >    category: y:Cyrillic
> >    to input: type "#" with russian-computer
> > buffer code: #x8C #xF0
> >   file code: not encodable by coding system mule-utf-8-unix
> >     display: by this font (glyph code)
> >      -ETL-fixed-medium-r-normal--16-160-72-72-C-80-ISO8859-5 (#xF0)
> This is very strange.
> Benjamin Riefenstahl <address@hidden> writes:
> [...]
> > Alternatively use unify-8859-on-encoding-mode, than cyrillic-iso8859-5
> > is preserved during input, but still can be saved as UTF-8.
> But, unify-8859-on-encoding-mode should be on by default (at
> least with CVS HEAD emacs).
> Paul, do you turn it off intentionally?  Can you reproduce
> this problem by starting your emacs with "-Q"?

Uh, indeed.  I think I turned it off because of poor support of
Cyrillic characters by the fonts...  If I start it with `-Q',
the numero sign is automatically encodable in UTF-8 as it
should be, but the Cyrillic characters appear as boxes which is
of course even worse for me.

I wonder if Emacs could implement some smart font substitution
when a glyph is not available in a font.  You can see what I
mean in e.g. recent `gnome-character-map' (it actually seems to
be a very nice trait of all GTK+/Pango programs.)  My `standard'
desktop font is Bitstream Vera Sans and all common characters
are displayed in this font in GNOME Character Map.  However,
certain characters are displayed in other fonts, presumably
because glyphs for them are missed from Bitstream Vera Sans.

Now, if I create a string of symbols in the Character Map and
copy it into another program, I get these results:

* GTK+ (hence Pango) programs: symbols that are displayed OK
  in the Map are displayed OK here too.

* KDE/Qt programs: symbols that are displayed with the Bitstream
  font in the Character Map are displayed OK (my KDE is
  configured with Bitstream Vera Sans as default too), other
  symbols (drawn with different fonts in the Map) are shown as
  boxes.  Apparently, Qt lacks font substitution just as Emacs.

* Emacs is the worst, since it uses `adobe-courier'.

So I think Pango fallback mechanism is great since many fonts
are really poor wrt number of provided glyphs.  It would be
really nice if Emacs could use something symilar or even relay
font/glyph-related tasks to Pango.  Not in the upcoming release,
of course, but I think it is one of the areas where improvement
is certainly needed.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]