help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Display of decomposed characters


From: Philipp Stephani
Subject: Re: Display of decomposed characters
Date: Sun, 24 Jan 2021 19:58:18 +0100

Am Fr., 25. Dez. 2020 um 20:02 Uhr schrieb Eli Zaretskii <eliz@gnu.org>:
>
> > From: Philipp Stephani <p.stephani2@gmail.com>
> > Date: Fri, 25 Dec 2020 18:14:31 +0100
> > Cc: help-gnu-emacs <help-gnu-emacs@gnu.org>
> >
> > > They are (or should be) displayed as a composed glyph if you are using
> > > a font that supports both a and COMBINING DIAERESIS.  Emacs cannot
> > > compose characters that aren't supported by the same font (because
> > > composition processing stops at face boundaries, and each font defines
> > > internally a separate face).
> >
> > Interesting. Indeed the two glyphs come from different fonts. Is there
> > a way to force a single font for both of them?
>
> If the default font supports the diaeresis, that will happen
> automatically.  If not, then simply don't choose the default font that
> doesn't support accents.

The font will always support the composite variant (because it's part
of Latin-1). I guess fonts assume that applications will first try to
normalize strings to avoid issues like this?

>
> > Or should the algorithm be changed to perform composition before
> > font selection?
>
> That's (a) hard, and (b) a bad idea in general, because different
> fonts generally have very different sizes of accents, and are
> generally incompatible in terms of pixel dimensions of characters vs
> accents.
>

But the situation here is that all characters should be contained in
the default font *except* the combining diaeresis. So normalizing the
string to the composite form before trying to display it would
increase compatibility between the characters.
Does it ever make sense to pick different fonts for a base character
and its combining characters? Wouldn't that fundamentally prevent
using combining characters? IIUC text rendering engines should be able
to pick the right glyph if that didn't happen (assuming they can
perform Unicode normalization).



reply via email to

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