[NTG-context] font fallbacks

Henning Hraban Ramm texml at fiee.net
Sat Jul 30 15:51:54 CEST 2022


Hi,
I thought I could use more than one fallback font, but as soon as I list 
fallbacks, they stop working.

In my example, I’d like to take all missing glyphs from Segoe UI 
Symbols, and what’s still missing (emojis) from EmojiOneColor, 
preferably without specifying the exact range.

Additionally, I want to replace the tilde ~ of LM Modern:

"""
\definefontfallback[seguiFB]
   [file:seguisym.ttf]
   [0x00000-0xFFFFF]
   [check=yes,force=no]

\definefontfallback[emoneFB]
   [name:EmojiOneColor]
   [0x00000-0xFFFFF]
   [check=yes,force=no]

% replace tilde in LM
\definefontfallback[tildeFB]
   [file:seguisym.ttf]
   [0x0007E-0x0007E]
   [force=yes]


\starttypescript [start]
   \definetypeface [start] [rm] [serif] [cambria] 
[default][fallbacks={seguiFB,emoneFB}]
   \definetypeface [start] [ss] [sans]  [modern] 
[default][fallbacks={seguiFB,emoneFB}]
   \definetypeface [start] [tt] [mono]  [modern] 
[default][fallbacks={seguiFB,tildeFB,emoneFB}]
   \definetypeface [start] [mm] [math]  [modern] 
[default][fallbacks={seguiFB,emoneFB}]
\stoptypescript


\setupbodyfont[start,rm,12pt]

\starttext

\Omega\ (Omega) and \aleph\ (Aleph)

\startbuffer[example]
start missing characters: lmmono10-regular.otf
    7  U+00327  ̧  COMBINING CEDILLA
    7  U+00335  ̵  COMBINING SHORT STROKE OVERLAY
   14  U+003B7  η  GREEK SMALL LETTER ETA
    7  U+021A9  ↩  LEFTWARDS ARROW WITH HOOK
  350  U+02500  ─  BOX DRAWINGS LIGHT HORIZONTAL
   98  U+02502  │  BOX DRAWINGS LIGHT VERTICAL
   42  U+02514  └  BOX DRAWINGS LIGHT UP AND RIGHT
  133  U+0251C  ├  BOX DRAWINGS LIGHT VERTICAL AND RIGHT
  154  U+02772  ❲  LIGHT LEFT TORTOISE SHELL BRACKET ORNAMENT
  154  U+02773  ❳  LIGHT RIGHT TORTOISE SHELL BRACKET ORNAMENT
   14  U+0278A  ➊  DINGBAT NEGATIVE CIRCLED SANS-SERIF DIGIT ONE
stop missing characters
start missing characters: cambria.ttc
    9  U+0278A  ➊  DINGBAT NEGATIVE CIRCLED SANS-SERIF DIGIT ONE
    9  U+0FFFD  �  REPLACEMENT CHARACTER
stop missing characters
start missing characters: cambriai.ttf
  266  U+0276C  ❬  MEDIUM LEFT-POINTING ANGLE BRACKET ORNAMENT
  266  U+0276D  ❭  MEDIUM RIGHT-POINTING ANGLE BRACKET ORNAMENT
stop missing characters
\stopbuffer

\typebuffer[example]

\startlines
\getbuffer[example]

{\ss\getbuffer[example]}
\stoplines

\tex{abra}\arg{...}
\type{kadabra} \type{~~~}

\stoptext
"""

What’s wrong?

Hraban


More information about the ntg-context mailing list