When I export a layered font as a SVG Color font using a Color Layers to SVG Custom Parameter, Glyphs will decompose all components, something that it doesn’t do if this CP isn’t present.
Is there a way to stop this? There have been a few times when I’ve exported this way and then saved the file, overwriting the version that contains components when I shouldn’t have and I’ve had to go back and recreate things. Is possible that the behaviour for this could be changed?
I’m having a similar issue. I’m trying to export a svg Pixel Font in Glyphs 3. The “pixels” are all made from a single component, which is a native Color layer containing a rectangle filled with a gradient.
This is a test glyph made from intact components (all on one Color layer):
Custom parameters: “Color Layers to SVG”, “Export SVG table” checked.
Export: “Autohinting” and “remove overlap” unchecked.
When I export as .otf and test the font, all components are decomposed and merged to one shape, which is filled with a singular gradient:
How can I prevent this from happening? Is it possible what I’m trying to achieve?
While working in the Glyphs editor (singular native color layer) I also noticed that sometimes gradient fills expand over multiple shapes when copied. Only the first time a “true” copy of the shape with the intact gradient relative to its shape is made - which then is overwritten with the same “global gradient position” on export.
I noticed building the gradient from scratch again – no copying or components – helps this last issue, but is extremely time consuming.
This issue in various forms has been keeping me busy the last couple of days, which makes me think that I might not understand a fundamental principle of Color Layer/SVG fonts. I always run into issues when placing multiple of the same (native gradient or SVG) elements on one layer.
If two shapes have the same attributes, they are merged into one shape. This mostly fine, except in your case. To hack it, you could ad a small, invisible shape to the pixel glyph.
Can you send me the file? I’ll see if I can fix this.