summaryrefslogtreecommitdiff
path: root/lib/extensions/commands.py
blob: 0f1fefabdf02f4756356993760f78b1bb1e24ae0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# Authors: see git history
#
# Copyright (c) 2010 Authors
# Licensed under the GNU GPL version 3.0 or later.  See the file LICENSE for details.

from inkex import Boolean

from .base import InkstitchExtension


class CommandsExtension(InkstitchExtension):
    """Base class for extensions that manipulate commands."""

    def __init__(self, *args, **kwargs):
        InkstitchExtension.__init__(self, *args, **kwargs)
        for command in self.COMMANDS:
            self.arg_parser.add_argument("--%s" % command, type=Boolean)