question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Suggested check: tnum glyphs have same metrics, across glyphs and styles

See original GitHub issue

Observed behaviour

I noticed that the tabular figures (tnum) of Libre Caslon Text Italic didn’t share the same horizontal width metrics.

This, of course, means that glyphs marked as .tnum and in the OpenType tnum feature are not yet actual tabular figures.

In the case of Libre Caslon Text, the Regular and Bold masters have proper tabular figures and .tnum glyphs:

image image

However, in Libre Caslon Text Italic, many of the glyphs named as .tnum are not yet modified to be tabular:

image

In the image above, then /yen.tnum is 1222, the dollar.tnum is 1007, and several other glyphs are also completely wrong.

Especially as we process fonts more quickly, this sort of broken OpenType feature will be easy to miss.

Expected behaviour

I think it would be relatively simple to add a check for this problem. My thought is, we could make a list of all width values for glyphs named .tnum, then check if a set of those widths is great than 1. If so, the test fails. I’m not sure whether it’s possible to cross-check other weights in a set of static fonts, but this simple test would go a long way, especially in variable fonts.

Resources and exact process needed to replicate

If you wish, the source files for LC are available at https://github.com/thundernixon/Libre-Caslon. I’m fixing the problem now, however, so you may need to go back to older versions to see this in action.

Issue Analytics

  • State:open
  • Created 5 years ago
  • Comments:19 (16 by maintainers)

github_iconTop GitHub Comments

1reaction
thundernixoncommented, Jan 14, 2019

Can you please mention the commit id of the version that has the problem?

@felipesanches Definitely! Specific commits which include the problem:

Libre Caslon Roman; Dec 10, 2018

Libre Caslon Italic; Dec 10, 2018

0reactions
hyvyyscommented, Dec 5, 2020

Tabular figures should have the same width across weights, but not widths! When generating fonts from UFO + designspace sources with a Width axis, this check gives false positives.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Glyphs 3 Handbook
Glyphs 3 is a professional Mac application for creating OpenType fonts. It allows you to draw, edit and test letter shapes in a...
Read more >
Syntax for OpenType features in CSS - Adobe Support
This feature replaces a sequence of glyphs with a single glyph, called a ligature, which is preferred for typographic purposes.
Read more >
How OpenType Works - Simon Cozens technical blog
OpenType fonts have two distinct ways of representing glyph outline data: ... used, as its name implies, to determine the style of the...
Read more >
Glyph Design for Temporal and Multi-Dimensional Data
outcomes suggest that radial glyph layouts making use of the visual variable orientation ... Summary: We found similar study goals across many experiments, ......
Read more >
otftotfm - create TeX font metrics from OpenType fonts
For pattern syntax, see GLYPH PATTERNS, below. OpenType fonts can have many alternates per character, most of which aren't interesting. For example, the ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found