emacs-devel
[Top][All Lists]
Advanced

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

Re: Ligatures (was: Unify the Platforms: Cairo+FreeType+Harfbuzz Everywh


From: Eli Zaretskii
Subject: Re: Ligatures (was: Unify the Platforms: Cairo+FreeType+Harfbuzz Everywhere (except TTY))
Date: Sat, 23 May 2020 09:58:36 +0300

> From: Pip Cet <address@hidden>
> Date: Fri, 22 May 2020 13:56:29 +0000
> Cc: address@hidden, address@hidden, address@hidden
> 
> > I thought the set of all the ligatures is known, and guided by
> > typography experts.
> 
> No, that's not how Opentype handles things at all. I just added a "ta"
> ligature to a font by converting it to ttx format, editing the XML,
> and converting back to .otf. It works fine.

Why would you add such a ligature? what is the purpose of having it?

> > Do font designers really support ligatures from
> > any arbitrary combination of characters?  If so, where can I read
> > about this?
> 
> https://docs.microsoft.com/en-us/typography/opentype/spec/gsub#lookuptype-4-ligature-substitution-subtable

Maybe I'm missing something, but that's a spec, and it doesn't say
that the number of ligatures is in practice unbounded.

> The font I'm looking at right now has these: Th, ch, ck, ffh, ffi,
> ffj, ffk, ffl, ff, fh, fi, fj, fk, fl, ft, tt, tz

Most of these are in the Wikipedia article, and others can be added.
This still doesn't mean the ligatures can be any combination of any
number of characters, at least not in practice.  We could still
collect a large enough list of known ligatures and provide a
reasonable support for Emacs users, even if that covers only 90% of
use cases.

> > > > For example, when displaying program source code
> > > > you'd probably want the various symbols, like -> etc., to produce
> > > > ligatures, but you most probably won't want "ffi" in a variable name
> > > > to produce a ligature.
> > >
> > > Why not?
> >
> > It makes no sense to me.  Why ligate them in that use case?  Program
> > source code isn't supposed to behave like typeset human-readable text.
> 
> Seems like an aesthetic decision. As far as I'm concerned, program
> source code is typeset human-readable text, it just has different (and
> possibly better) conventions for typesetting it.

Yes, and one of the convention is the use of fixed-pitch fonts, which
ligatures made out of letters usually violate.

> I wouldn't choose to use a variable-pitch font for program source
> code ordinarily, but if I did, I'd want ligatures.

If we want to support variable-pitch fonts for program sources, we
have much more fundamental problems than ligatures.  Those other
problems need to be resolved first.

> > Indeed, ligatures don't have to have Unicode codepoints, only some of
> > them are precomposed.  Emacs doesn't need them to have codepoints when
> > we use auto-composition-mode.  The reference is there only to show the
> > list of ligatures, and I believe the list is full regardless of the
> > codepoint issue.  Can you point me to a larger list of ligatures made
> > out of ASCII letters?
> 
> "Th" is mentioned as an example in a few places, and it's not on the list.

It's mentioned in the article, under "Stylistic ligatures".



reply via email to

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