Re: OpenType font variations and cairo
Adrian Johnson <[email protected]>
| Newsgroups | gmane.comp.lib.cairo |
|---|---|
| Message-ID | <[email protected]> |
On 15/09/17 21:05, Matthias Clasen wrote: > On Fri, Sep 15, 2017 at 6:51 AM, Adrian Johnson > > > Is the text string supplied to cairo_font_options_set_variations() > likely to be generated by sprintf or is it always read from an external > source in C locale format? > > > You have a good point here. The string is expected to be generated > programmatically, as in this example here: > > https://git.gnome.org/browse/gtk+/tree/demos/gtk-demo/font_features.c?h=wip/matthiasc/font-variations#n454 In cairo_begin_tag() where the attributes are expected to be generated programmatically, I ignore the locale since the strings as parsed in the same locale as the printf. That is also why I avoided commas between the key=value so it will work with decimal commas. > > I need to fix that code up to use C locale as well. > > > We really need a test case for this. It is hard to review code I > can't test. > > > I don't disagree. As always with testing font-related things, the > problem is to find a suitable > font that can be shipped with the tests... > If you don't have a redistributable font, just provide a test that can be run manually similar to what I did in 23fd706b. Include a comment explaining where a suitable font could be downloaded from. I used this font for testing 0fd0fd0a. https://github.com/adobe-fonts/adobe-variable-font-prototype/releases -- cairo mailing list [email protected] https://lists.cairographics.org/mailman/listinfo/cairo