SOLVED Can I lock and unlock guides via script?
-
In Robofont 3 (built 1803062007)
I have a simple script that adds or removes a grid of guides to a glyph. The only issue is that these block drawing if I don't also right-click and "lock guides."
Is there a way to set guides as locked? I'm not finding the method or data descriptor in the
CurrentFont()
,CurrentGlyph()
,CurrentGlyph().guidelines[0]
, or thenaked()
versions of these.I also don't see it at http://robofont.com/documentation/workspace/glyph-editor/guidelines/?highlight=lock guides.
Am I missing something, or is it not currently possible?
-
oh, typo, Ive edited it out, thanks!
-
@frederik said in Can I lock and unlock guides via script?:
from mojo.UI import setDefault
getDefault("glyphViewLockGuides", True) # set to False to unlockOne quick edit to your code snippet, for the next person who sees this: the method has to be
setDefault()
, notgetDefault()
. Obviously a simple typo, and it was simple to correct. :)So, the code needs to be:
from mojo.UI import setDefault setDefault("glyphViewLockGuides", True) # set to False to unlock
Thanks again for the help!
-
Ahhh brilliant, thank you!
-
you can!
from mojo.UI import setDefault setDefault("glyphViewLockGuides", True) # set to False to unlock