Macro worksflow

Hi all,
I am currently starting to play with Python in GlyphsApp. I wonder how is everybody’s workflow. My current situation now is

  1. Open Macro : write some code
  2. Copy the whole thing >> Sublime Text
  3. Save it to snippet folder

I do it in reverse for using the code in the snippet folder. It is good that I can keep the macro tab, but now I have multiple Marco tabs. I went to look at this :

My question is now Marco can save to script folder yet? Or the above article is still be the recommended workflow?

Thank you!


Don’t use the macro for code that is longer than ~50 lines and for non-important code drafts. Use python files right away if you can.

Longer version:

I made a little script that saves all macro tabs to the scripts folder and adds the MenuTitle (if they have a Macro title, it uses that), then it closes all the macro tabs.

I rarely use it nowadays, as I started the habit to not use the macro a lot. It is really not meant to keep intensive scripts at hand, it is more a scratch board for short little drafts (I also lost some really long spent hours of code, when I accidentally closed a tab that I have not saved to a python file yet. Will never let that happen again)

1 Like

The macro panel will be way better soon, as Georg mentioned in the other thread.

So the current bugs (e.g. the annoying added tabstops, when creating a new line, or the inability to properly navigate tabs, when there are so many that they are collapsed, or that you cannot get back a closed tab, and and and …) are history

1 Like

Hi Mark, thank you for the reply! Is there a way to get this bottom window of the macro panel independently to see the output? My code is not yet stable, so I have to read what is wrong after ran it all the time. Or do I have to just leave the whole macro panel open?

Hi Boom :slight_smile:

the macro panel has the split view divider, you could move it up, if you don’t want to use the coding area and see only the console area. Is that what you mean?

And yes, is is definitely a good idea to use the console area to debug your code. There is also the showMacroWindow() method you can call from your python script, when you want to force open the macro even if it is closed. Also clearLog() is useful.

Lastly, as you are relatively new to scripting in Glyphs (welcome aboard), this might be also interesting for you:


Amazing!! Thank you Mark :dizzy:

1 Like