Subject: bug#41747: 27.0.91; Add default fontset setup for "Symbols and Pictographs Extended-A"

From: Kévin Le Gouguec <[email-masked]>
Date: Mon, 08 Jun 2020 22:59:32 +0200

Eli Zaretskii <[email-masked]> writes:

> Maybe you could find a free font that covers this block, then we could
> use that instead of Symbola.

I've looked, but no clear winner has emerged.

Of course, GNU Unifont covers this block, though I had not realized this
at first because one has to install Unifont Upper, which I had to grab
from unifoundry.com because my distro does not package it AFAICT.  Once
that's installed, emacs -Q seems to pick it up automatically, so the
situation is not as critical as I thought.

Then there are color fonts dedicated to emoji.  If we start using such a
font for the default fontset setup, it would probably make sense to
assign it to more blocks than just "Symbols and Pictographs Extended-A",
otherwise people will wonder why some emoji show up with a color font
while others don't.

Finding all emoji that should be displayed with a color font sounds like
a whole other issue which probably deserves its own bug report.  I
imagine we'd need to scrape Unicode's emoji-data.txt to figure which
characters have Emoji_Presentation set; IIUC the subject has already
been broached in bug#39799.

As to which emoji font we could pick…

- Noto Color Emoji (SIL Open Font License) seems the most ubiquitous
  AFAICT (packaged in e.g. Debian, OpenSUSE, Fedora; a .ttf file is
  available in the developer repository).  It doesn't cover Unicode 13
  yet but that shouldn't take long.

- Twemoji (CC-BY) covers Unicode 13, unfortunately the procedure to get
  a .ttf is a bit… involved.  IIUC Fedora re-uses Noto's machinery to
  generate a TrueType font from SVG assets[1].  I haven't seen many
  distributions packaging it yet.

- OpenMoji (CC-BY-SA) is making progress on Unicode 13 coverage[2]; it
  also has a "black" (non-colored) variant, which means we could use it
  for blocks not covered by the older Symbola and it wouldn't look out
  of place.  In fact the "color" variant only shows up as colored with
  Firefox, for some reason[3].  There are .ttf files in the developer
  repository, but they don't seem to be packaged by many distros yet
  (it's in OpenSUSE, it'll get into Fedora Soonish™[4]).

There are probably other candidates.  For the purpose of this bug report
however, GNU Unifont is the only free, readily available, and non-color
option I have found for "Symbols and Pictographs Extended-A".

Since Emacs already uses that… SNAFU, I'd conclude.

[1] https://bugzilla.redhat.com/show_bug.cgi?id=1514274
[2] https://github.com/hfg-gmuend/openmoji/issues/124
[3] https://github.com/hfg-gmuend/openmoji/issues/93
[4] https://bugzilla.redhat.com/show_bug.cgi?id=1803059