Problems with color components
simoncozens opened this issue · 4 comments
simoncozens commented
This glyphs file: BadColor.glyphs.gz has two masters, each with two color layers. I would expect these layers to be exported as ".color0" and ".color1". However, the names of some (not all!) component glyphs used in these masters are incorrect:
$ glyphs2ufo BadColor.glyphs
$ cat BadColor-Thin.ufo/glyphs.color.1/A_acute.glif
<?xml version='1.0' encoding='UTF-8'?>
<glyph name="Aacute" format="2">
<advance width="500"/>
<unicode hex="00C1"/>
<anchor x="685" y="10" name="ogonek"/>
<anchor x="355" y="708" name="top"/>
<outline>
<component base="A.color1"/>
<component base="acutecomb.color2" xOffset="370" yOffset="208"/>
</outline>
There is no color2, so the font does not compile.
anthrotype commented
the issue must be somewhere here:
glyphsLib/Lib/glyphsLib/builder/components.py
Lines 50 to 69 in ed02363
simoncozens commented
Yep, that looks suspicious. I will try to fix.
anthrotype commented
thanks. I tried to understand what was going on but failed so far, happy to pass it to you
anthrotype commented
Fixed by #974