• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Overview
2This version of Selawik is a test case and demonstration of OpenType 1.8 Font Variations technology and tables. It also includes some handy debugging characters.
3
4This version of Selawik is intended for testing only, and is not recommended for shipping in applications, etc. For that, it is better to use the main branch of [Selawik](https://github.com/Microsoft/Selawik).
5
6# Features
7
8* Full TrueType hinting with VTT source tables included. See [Hinting](#hinting) for details.
9* All tables required for OpenType 1.8 are present (see [Table Status](#table-status), below). This includes cvar (varied CVTs), GPOS/GDEF (kerning varies), and avar (coordinate space warping to match Segoe UI).
10
11	Note: This version of Selawik does not include an MVAR because its vertical metrics do not change anywhere in the design space, thus there is no need for MVAR. A future release will contain an axis that varies vertical metrics as an excuse to have an MVAR.
12
13* Numerous interesting debugging glyphs (requires liga to be enabled). For example, \axis1 will show the current normalized wght coordinate. See [Debugging Glyphs](#debugging-glyphs) for details.
14* 1 axis: weight
15
16## Table status
17The following tables are currently supported:
18
19- [x] fvar
20- [x] gvar
21- [x] cvar
22- [x] avar (to match Segoe UI weights and metrics)
23- [x] STAT
24- [x] GPOS/GDEF - kerning
25- [x] HVAR
26
27Not yet complete:
28
29- [ ] GSUB/GDEF - to change dollar signs in the bold
30- [ ] MVAR (future release)
31
32## To do
33* Add a second axis that varies vertical metrics so we need an MVAR table. This axis will not be one of the standard axes listed in the [OpenType 1.8 specification] (https://www.microsoft.com/typography/otspec/fvar.htm), so that it becomes an example of out to do a foundry-defined axis.
34* Add Feature Variations (GPOS/GDEF) to switch dollar sign glyphs across weights.
35
36
37# Debugging glyphs
38Thanks to Greg Hitchcock's TrueType coding wizardry, this font includes many glyphs that are helpful for debugging implementations of variable fonts. It has a number of substitutions implemented as liga features:
39
40Feature | Description
41-------- | ----------
42\axis1 | Shows the normalized coordinate on the wght axis for the currently selected instance (e.g. 1.0 for bold, -1.0 for light, or something in between).
43\axis2 | Shows 0 because this font doesn't yet have a second axis.
44\axis1hex | Same as \axis1 but in hex.
45\axis2hex | Same as \axis2 but in hex.
46\pointsize | Shows the point size passed to the TrueType rasterizer. Note that depending on how the application calls the rasterizer, this may not be what you expect - e.g. on Safari on MacOS, this is always 1024.
47\ppem | Shows the pixels per em passed to the TrueType rastersize. Note that depending on how the application calls the rasterizer, this may not be what you expect - e.g. on Safari on MacOS, this is always 1024.
48\ttversion | Shows the version of the TrueType rasterizer.
49\ttmode | Shows the current TrueType rasterizer mode flags.
50\boldtest | A glyph to help you detect artificial emboldening. The glyph has a vertical bar and a circle. The vertical bar's weight varies with the weight of the rest of the font: it gets bolder at bolder weights, lighter at lighter weights. The circle changes weight (and size) in opposition to the rest of the font: lighter at bold weights and vice versa. Thus, if you use this character and see both the circle and bar look bold, you're not looking at a true bold instance, but an algorithmically emboldened one.
51\family | Shows the family name of the font.
52\version | Shows the version of this font
53
54
55
56
57# Hinting
58This version of Selawik is primarily hinted with the light Latin hinting style Microsoft recommends for variable Latin fonts. The VTT Light Latin autohinter was used to create the first round of hints, which were then reviewed and touched up.
59
60This hinting style only uses CVTs for vertical metrics anchors (ascender, descender, cap height, x-height, and baseline). While this makes for an easy job hinting a Latin font, it makes for a poor test case because Selawik doesn't vary vertical metrics with weight, thus doesn't vary CVTs, thus doesn't need a cvar. So, to make it more interesting, we added CVT-based stem hints to the lowercase only. This provided the need to vary CVTs and thus require a cvar. Note that this was only done for testing purposes. For variable fonts, Microsoft recommends the light hinting style using the `ResYDist()` command instead of a CVT-based stem hint.
61