Given the traced font information, implement automation of what font style matcher lets a human do.
This could be useful for future automation of injection of a fallback for system fonts that avoids font metric jumps when webfonts load late. See the technique presented in https://www.youtube.com/watch?v=tO01ul1WNW8
Possible techniques for a heuristic that can approximate the different font settings:
For all visible letters, compare the rendered webfont with different local fonts in different sizes to approximate the best fitting fallback font and its font-size.
For all sentences, compare the length of the spaces between words to approximate the best word-spacing.
For all sentences (or just the longest one), use a fitting of the X-coordinate of the right edge of the last letter to approximate the best word-spacing.
For all sentences (or just the longest one), compare the line-wrapped renderings of the original and fallback to approximate the best line-height
Maybe we should use a canvas and overlay the two fonts, like font style matcher does, then fit on the least amount of discrepancy between the font outlines, determined by the lest color difference
Given the traced font information, implement automation of what font style matcher lets a human do.
This could be useful for future automation of injection of a fallback for system fonts that avoids font metric jumps when webfonts load late. See the technique presented in https://www.youtube.com/watch?v=tO01ul1WNW8
Possible techniques for a heuristic that can approximate the different font settings:
font-size
.word-spacing
.word-spacing
.line-height
Maybe we should use a canvas and overlay the two fonts, like font style matcher does, then fit on the least amount of discrepancy between the font outlines, determined by the lest color difference