In CPAL/COLR font accented letters created automatically with diacritical marks and base letters. Is there a method to make them the same color as their base letters without adding color layers?
I’ve tried “Convert Layerfont to CPAL+COLR font” script but I guess it is not used for this scenario.
Yes, just put the components on the respective iColor letter. Not sure I understand your question though. Can you post a mock-up of what you want to achieve?
When I export the font letters with diacritics look like this.
My question was is there a way to export the accented glyphs as coloured as their base glyphs without adding the same color layers to the all of them one by one? I hope this explains well.
Which exact version of the app are you running?
You need to add the color layers ot the accented letters, too. Duplicate the default layers for each color and the components will match to the color layers.
Color Palette layers should be added anyway.
Here a script to automate it (if anyone will be looking for it in a future).
font = Glyphs.font
id = font.selectedFontMaster.id
for glyph in font.glyphs:
layer = glyph.layers[id]
for component in layer.components:
source = component.component.layers[layer.associatedMasterId].parent
for sourceLayer in source.layers:
if sourceLayer.attributes['colorPalette'] or sourceLayer.attributes['colorPalette'] == 0:
newLayer = GSLayer()
newLayer.associatedMasterId = id
newLayer.attributes['colorPalette'] = sourceLayer.attributes['colorPalette']
colorComponent = GSComponent(source)
colorComponent.automaticAlignment = False
colorComponent.x = component.x
colorComponent.y = component.y