diff options
| author | Lex Neva <github.com@lexneva.name> | 2019-03-06 20:32:51 -0500 |
|---|---|---|
| committer | Lex Neva <github.com@lexneva.name> | 2019-03-08 19:57:11 -0500 |
| commit | 602f201cb6236a7cb4a041b84e761aaedc358ab0 (patch) | |
| tree | 0a2148fc4f49bd271a12cbbd4fe057c5a19fd9bd /lib/commands.py | |
| parent | 53a9bd6b31ca3a1f50d41f228e0b598a7d9da8ea (diff) | |
implement trim option for lettering
Diffstat (limited to 'lib/commands.py')
| -rw-r--r-- | lib/commands.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/commands.py b/lib/commands.py index ddee8326..53b9e77f 100644 --- a/lib/commands.py +++ b/lib/commands.py @@ -254,7 +254,12 @@ def symbol_defs(): @cache def get_defs(document): - return document.find(SVG_DEFS_TAG) + defs = document.find(SVG_DEFS_TAG) + + if defs is None: + defs = inkex.etree.SubElement(document, SVG_DEFS_TAG) + + return defs def ensure_symbol(document, command): |
