diff --git a/extensions/fablabchemnitz_checkerboard.inx b/extensions/fablabchemnitz_checkerboard.inx index 2a03bf9e..e860a445 100644 --- a/extensions/fablabchemnitz_checkerboard.inx +++ b/extensions/fablabchemnitz_checkerboard.inx @@ -1,47 +1,37 @@ - Checkerboard - fablabchemnitz.de.checkerboard - - - 50 - 10 - 10 - true - - - #000000ff - - - #ffffffff - - - Create a checkerboard - -1. On the Params tab, choose the cell size - (size of the constituent squares), number - of rows and columns, and whether to add - the checkerboard to the current layer - (if unchecked, the checkerboard will be - added to the root layer) -2. On the 1st color and 2nd color tabs, - select the colors for the two sets of - squares -3. Click Apply - -More information and source code: -https://github.com/jeffkayser/inkscape-checkerboard - - - - all - + Checkerboard + fablabchemnitz.de.checkerboard + + + 50 + 10 + 10 + true + + + 4286282751 + + + 8092671 + + + + + + + + + + + all + - - - - \ No newline at end of file + + + + diff --git a/extensions/fablabchemnitz_checkerboard.py b/extensions/fablabchemnitz_checkerboard.py index 719bde37..1e9fcbba 100644 --- a/extensions/fablabchemnitz_checkerboard.py +++ b/extensions/fablabchemnitz_checkerboard.py @@ -21,7 +21,6 @@ along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA """ -from gettext import gettext as _ import inkex from lxml import etree import re @@ -66,8 +65,8 @@ class Checkerboard(inkex.Effect): def __init__(self): inkex.Effect.__init__(self) self.arg_parser.add_argument("--tab") - self.arg_parser.add_argument("--color1", type=Color) - self.arg_parser.add_argument("--color2", type=Color) + self.arg_parser.add_argument("--color1", type=Color, default=4286282751) + self.arg_parser.add_argument("--color2", type=Color, default=8092671) self.arg_parser.add_argument("--size") self.arg_parser.add_argument("--rows", type=int) self.arg_parser.add_argument("--cols", type=int) @@ -90,5 +89,4 @@ class Checkerboard(inkex.Effect): x, y = self.svg.namedview.center[0] - cols * size / 2, self.svg.namedview.center[1] - rows * size / 2 draw_grid(x, y, rows, cols, size, color1, color2, group) -if __name__ == '__main__': - Checkerboard().run() \ No newline at end of file +Checkerboard().run()