Comment by rikroots
16 hours ago
> This thing is very impressive.
Agreed! Text layout engines are stupidly hard. You start out thinking "It's a hard task, but I can do it" and then 3 months later you find yourself in a corner screaming "Why, Chinese? Why do you need to rotate your punctuation differently when you render in columns??"
This effort feeds back to the DOM, making it far more useful than my efforts which are confined to rendering multiline text on a canvas - for example: https://scrawl-v8.rikweb.org.uk/demo/canvas-206.html
Why do you bring up Chinese cornes if the basic Latin text in the Pretext demo is deficient?
(by the way, in your cool demo the wheel template can have some letter parts like the top of L or d extend beyond the wheel)
> the wheel template can have some letter parts like the top of L or d extend beyond the wheel
Yeah - I use the template (in that case, a circle) to calculate line lengths, then I run 2d text along the 1d lines. Even if I tried to keep all of the glyphs inside the wheel I'd fail - because some fonts lie about how tall they are. Fonts are, basically, criminals.