diff options
| author | Teddy Wing | 2015-11-19 21:18:03 -0500 |
|---|---|---|
| committer | Teddy Wing | 2015-11-19 21:18:03 -0500 |
| commit | 084d0770bb210e76946e885e6485e4045b5617a7 (patch) | |
| tree | a206864af48f1255a130e406f24ef2b2844a068a | |
| parent | 6b6cfacb193ca1c26f6e4511749a911e283d016f (diff) | |
| download | RoboFont-Equalize-Sidebearings-Key-084d0770bb210e76946e885e6485e4045b5617a7.tar.bz2 | |
equalize_sidebearings.py: Add undo capability
Allow centering to be undone.
| -rw-r--r-- | equalize_sidebearings.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/equalize_sidebearings.py b/equalize_sidebearings.py index 22cde71..92f518b 100644 --- a/equalize_sidebearings.py +++ b/equalize_sidebearings.py @@ -6,6 +6,12 @@ class EqualizeSidebearings(object): def center(self, info): if info['event'].characters() == 'a': - info['glyph'].center() + g = info['glyph'] + + g.prepareUndo('Equalize Sidebearings') + + g.center() + + g.performUndo() EqualizeSidebearings()
\ No newline at end of file |
