From 7b92d235aedf6026f784ab6cdab057d0422a6884 Mon Sep 17 00:00:00 2001 From: Walter Bender Date: Fri, 19 Apr 2013 03:16:39 +0000 Subject: use show/hide blocks to set execution speed as debugging aid --- diff --git a/plugins/turtle_blocks_extras/turtle_blocks_extras.py b/plugins/turtle_blocks_extras/turtle_blocks_extras.py index 1447b11..d2e6cfb 100644 --- a/plugins/turtle_blocks_extras/turtle_blocks_extras.py +++ b/plugins/turtle_blocks_extras/turtle_blocks_extras.py @@ -1480,6 +1480,8 @@ bullets')) def _prim_hideblocks(self): """ hide blocks and show showblocks button """ self.tw.hideblocks() + self.tw.lc.trace = 0 + self.tw.step_time = 0 if self.tw.running_sugar: self.tw.activity.stop_turtle_button.set_icon("hideshowoff") self.tw.activity.stop_turtle_button.set_tooltip(_('Show blocks')) @@ -1487,6 +1489,8 @@ bullets')) def _prim_showblocks(self): """ show blocks and show stop turtle button """ self.tw.showblocks() + self.tw.lc.trace = 1 + self.tw.step_time = 3 if self.tw.running_sugar: self.tw.activity.stop_turtle_button.set_icon("stopiton") self.tw.activity.stop_turtle_button.set_tooltip(_('Stop turtle')) -- cgit v0.9.1