We'll provide a test font that has multiple glyphs within an SVG doc. I agree that this should be in a test suite repo.
We at Adobe Type don't know of shipping fonts that use this facility, and Fontself Maker doesn't generate fonts using it. It will be an interesting subroutizer project for some font creation tool some day! FYI example 4 in the SVG table spec illustrates this facility: https://docs.microsoft.com/en-us/typography/opentype/spec/svg#examples. Best, Sairus On 5/14/19, 11:52 PM, "Freetype-devel on behalf of Werner LEMBERG" <freetype-devel-bounces+sppatel=adobe....@nongnu.org on behalf of w...@gnu.org> wrote: >> Do you think that this kind of `caching' should be done on the >> FreeType side or on the SVG side? > > That's interesting question. Ideally font is memory-mapped and > FreeType just returns a pointer to the SVG document, so there's no > copying involved. Then the client can do any caching if they deem > necessary. But given the way FreeType works, that might not be > possible. I suggest returning a copy of the string as FreeType > probably have to, but possibly expose API that shows which glyph > ranges share the same document. OK. > In HarfBuzz, we have a type hb_blob_t to encapsulate chunk of bytes and do > the memory-ownership management on it. [...] > > I think something as simple as that is a good start. Thanks. > Realistically, not many fonts combine multiple glyphs into the same > SVG documents, for obvious reasons of workflow: fonts are built out > of a collection of standalone SVGs much more often than hand-curated > SVG documents representing multiple glyphs each. Not having had a closer look at your SVG Emoji font, so I wonder whether it contains such `hand-curated' stuff for testing purposes... Otherwise, do you know test examples for that? Eventually, this should all be added to a proper test suite. Werner _______________________________________________ Freetype-devel mailing list Freetype-devel@nongnu.org https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.nongnu.org%2Fmailman%2Flistinfo%2Ffreetype-devel&data=02%7C01%7Csppatel%40adobe.com%7Cee12156c9a12470e058508d6d901d2c1%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636934999198162685&sdata=ntYyhed1BZ7xgo8lOFARKTQ5GczzhR%2BvJhKlDWvsF0k%3D&reserved=0 _______________________________________________ Freetype-devel mailing list Freetype-devel@nongnu.org https://lists.nongnu.org/mailman/listinfo/freetype-devel