From 349d91703b6b4585b24501bb58b8e3bccf60c363 Mon Sep 17 00:00:00 2001 From: "newman.daniel1" Date: Mon, 18 Oct 2010 13:43:26 +0000 Subject: [PATCH] Issue 29 as regards this extension git-svn-id: https://eggbotcode.googlecode.com/svn/trunk@148 72233254-1b6c-9e9c-5072-401df62706fb --- inkscape_driver/eggbot_maze.py | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/inkscape_driver/eggbot_maze.py b/inkscape_driver/eggbot_maze.py index aa07309..96166a8 100644 --- a/inkscape_driver/eggbot_maze.py +++ b/inkscape_driver/eggbot_maze.py @@ -490,7 +490,12 @@ class Maze(inkex.Effect): def draw_horizontal(self, y, wall, isborder): - dy = 0 if wall == Maze._NORTH else 1 + # Cater to Python 2.4 and earlier + # dy = 0 if wall == Maze._NORTH else 1 + if wall == Maze._NORTH: + dy = 0 + else: + dy = 1 thickness = 4 if isborder else 1 tracing = False @@ -519,7 +524,12 @@ class Maze(inkex.Effect): def draw_vertical(self, x, wall, isborder): - dx = 0 if wall == Maze._WEST else 1 + # Cater to Python 2.4 and earlier + # dx = 0 if wall == Maze._WEST else 1 + if wall == Maze._WEST: + dx = 0 + else: + dx = 1 thickness = 4 if isborder else 1 # We alternate the direction in which we draw each vertical wall.