diff options
Diffstat (limited to 'ReckonPrimer.activity/exercises/exaddsimp.py')
-rwxr-xr-x | ReckonPrimer.activity/exercises/exaddsimp.py | 25 |
1 files changed, 16 insertions, 9 deletions
diff --git a/ReckonPrimer.activity/exercises/exaddsimp.py b/ReckonPrimer.activity/exercises/exaddsimp.py index a774436..9c8338d 100755 --- a/ReckonPrimer.activity/exercises/exaddsimp.py +++ b/ReckonPrimer.activity/exercises/exaddsimp.py @@ -117,16 +117,22 @@ class ExAddSimp(Exercise): self.toggle_equal_fixed_right = gtk.ToggleButton("<<") self.toggle_label = self.toggle_equal_fixed_right.get_child() - self.toggle_label.modify_font(pango.FontDescription("sans %d" % style.zoom(12))) - self.toggle_equal_fixed_right.connect("toggled", self.toggle_equal_fixed_right_callback) - self._display.settings_table.attach(self.toggle_equal_fixed_right, 5, 6, 10, 11 ) + self.toggle_label.modify_font(pango.FontDescription( + "sans %d" % style.zoom(12))) + self.toggle_equal_fixed_right.connect( + "toggled", self.toggle_equal_fixed_right_callback) + self._display.settings_table.attach( + self.toggle_equal_fixed_right, 7, 8, 10, 11 ) self.toggle_equal_fixed_right.show() self.toggle_equal_fixed_left = gtk.ToggleButton("<<") self.toggle_label = self.toggle_equal_fixed_left.get_child() - self.toggle_label.modify_font(pango.FontDescription("sans %d" % style.zoom(12))) - self.toggle_equal_fixed_left.connect("toggled", self.toggle_equal_fixed_left_callback) - self._display.settings_table.attach(self.toggle_equal_fixed_left, 5, 6, 12, 13 ) + self.toggle_label.modify_font(pango.FontDescription( + "sans %d" % style.zoom(12))) + self.toggle_equal_fixed_left.connect( + "toggled", self.toggle_equal_fixed_left_callback) + self._display.settings_table.attach( + self.toggle_equal_fixed_left, 7, 8, 12, 13 ) self.toggle_equal_fixed_left.show() self.toggle_pos1 = gtk.ToggleButton("--") @@ -227,12 +233,13 @@ class ExAddSimp(Exercise): # Buttons 9 .. 0 self.number_butts = [] - for i in range(0,9+1): + for i in range(0,10+1): self.toggle = gtk.ToggleButton(str(i)) self.toggle_label = self.toggle.get_child() - self.toggle_label.modify_font(pango.FontDescription("sans %d" % style.zoom(12))) + self.toggle_label.modify_font(pango.FontDescription( + "sans %d" % style.zoom(12))) self.toggle.connect("toggled", self.toggle_number_callback, i) - self._display.settings_table.attach(self.toggle, 4, 5, 10-i, 11-i) + self._display.settings_table.attach(self.toggle, 6, 7, 10-i, 11-i) self.toggle.show() self.number_butts.append(self.toggle) |