Robofab script to address separate masters of a MM font.

ttmt's picture

Hi all

I have this simple Robofab script here that adjust the height of accents above glyphs.
I'm sure there are better ways of doing this but I like this method.


from robofab.world import CurrentFont
#
f = CurrentFont()
#
glyphs = [
'Aacute',
'Abreve',
'Acircumflex',
'Adieresis',
'Agrave',
'Amacron',
'Atilde',
'AEacute',
'Aring',
'Aringacute',
……
]
#
for g in glyphs:
f[g].components[1].move((0,5))
f[g].mark = 10
f.update()

If I use this on a MM font it will adjust the height of the accents in both masters.

Is it possible it adjust the height in just one of the masters.

pvanderlaan's picture

No, RoboFab cannot address seperate masters in FontLab.

For this you need to use FontLab’s native Python API

Syndicate content Syndicate content