Hi. When I use AppleScript to execute generate aInstance to file ResultFolder as TTF with properties {autohint:false, useSubroutines:false}
, the properties {autohint:false, useSubroutines:false}
don’t work, while everything else is normal. What could be the reason?
What have you tried that worked?
I use script can be worked. instance.generate(Format = formata, FontPath = exportFolder, AutoHint = False, UseSubroutines = False)
That seems to be a python script. You mentioned
Do you have an Apple Script that works? And why do you are trying apple Script then the other script is Python?
The font generated by generate aInstance to file ResultFolder as TTF with properties {autohint:false, useSubroutines:false}
is the same as that generated by generate aInstance to file ResultFolder as TTF
, this looks with properties {autohint:false, useSubroutines:false }
Didn’t work. I want to use AppleScript to try to automatically generate fonts
The reach you have through any osascript language is limited, I am afraid. The Python interface is better developed. But the generate command works for me as expected:
use scripting additions
set myFile to choose folder with prompt "Destination for font"
tell application "Glyphs 3"
tell font of first document
set myInstance to instance 2
generate myInstance to myFile as TTF with properties {autohint:false, removeOverlap:true}
end tell
end tell
Which error do you get? And can you paste your actual code?
Ah, now I see. I can reproduce this. I had another look and from what I see, the attribute is actually called RemoveOverlap
with a cap R
(a mistake, will fix). The AppleScript parser force-corrects it back to removeOverlap
.
In Python it works with RemoveOverlap=True
.