Closed tiffany352 closed 2 years ago
Yes, the characters -> glyphs mapping is still being driven by Prince at the moment but we're definitely going to push that into Allsorts in the future.
Since Allsorts 0.5 there it's now easier to shape text. The Font
type has a shape
method that handles most shaping concerns. Note that shape.rs in allsorts-tools is now much simpler.
Harfbuzz has a simplified API where you create an
hb_buffer_t
and callhb_shape()
on it, while with this crate it looks like you have to write a bunch of boilerplate to apply gsub, gpos, and cmap table transformations separately. Could that code be streamlined into an API oriented around converting characters -> glyph indices? With other inputs similar to Harfbuzz, such as the language to use for shaping localized forms, and any OpenType features to apply during shaping such as smallcaps.I could also be misunderstanding. I'm going off of the example located here: https://github.com/yeslogic/allsorts-tools/blob/master/src/shape.rs