Reorder shapes of many glyphs at once

I have 118 glyphs over 12 masters that consists solely of component instances and use automatic alignment with anchors. However the components’ order is wrong, leading to anchors not aligning/working. I can manually resolve the issue via Filter → Shape Order but it will take me an hour at least and be extremely boring (drag stuff 1416 times.)

Is there any way to “correct shape order for anchor alignment” automatically en masse? Has anyone written a script for this?

This is what the glyphs looks like:

After manually correcting order:

PathCorrect Path Direction (Command-Shift-R) should suffice. Hold down the Option key to perform the action on all master layers of the selected glyphs (Command-Option-Shift-R).

1 Like

If it is components, you can recreate the glyph(s) with a recipe in Glyph > Add Glyphs… (Cmd-Shift-G), like:

comp1name+comp2name=glyphname

1 Like

Thank you both. This (recreating the glyphs) is what I ended up doing and scripting the transfer of Unicodes (most had private-space codepoints assigned.)

This didn’t work unfortunately, but I appreciate the suggestion!