diff options
Diffstat (limited to 'lib/svg/path.py')
| -rw-r--r-- | lib/svg/path.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/svg/path.py b/lib/svg/path.py index 5e6e7007..a7c7b1ca 100644 --- a/lib/svg/path.py +++ b/lib/svg/path.py @@ -85,6 +85,19 @@ def get_correction_transform(node: inkex.BaseElement, child=False) -> str: return str(transform) +def line_strings_to_coordinate_lists(line_strings): + try: + # This lets us accept a MultiLineString or a list. + line_strings = line_strings.geoms + except AttributeError: + pass + + if line_strings is None: + return None + + return [list(ls.coords) for ls in line_strings] + + def line_strings_to_csp(line_strings): try: # This lets us accept a MultiLineString or a list. |
