I am currently trying to select all global guides via script. However, it seems that there is a bug (or at least a problem) that needs to be addressed before this is possible:
When I try to add local guides to the selection, I do it like this
layer = Glyphs.font.selectedLayers for guide in layer.guides: guide.selected = True
And it works.
When I try this with global guides analogously,
master = Glyphs.font.selectedFontMaster for guide in master.guides: guide.selected = True
I end up with the following error:
Traceback (most recent call last): File "<macro>", line 3, in <module> File "GlyphsApp/GlyphsApp/__init__.py", line 3820, in <lambda> File "GlyphsApp/GlyphsApp/__init__.py", line 2546, in SetObjectInLayer_selected AttributeError: 'GSFontMaster' object has no attribute 'selection'
Is it me or is it Glyphs? To me, it seems like it’s trying to add the guides to the
selection attribute in
GSLayer but searches in the wrong place because the guides are global (not local) and thus children of a