From a5a7b818b1a9b8f5cf721d9e112846b8c28f3abd Mon Sep 17 00:00:00 2001 From: Walther Neuper Date: Wed, 16 Dec 2009 13:31:44 +0000 Subject: debug settings_table, resize butts at bottom, cleanups --- diff --git a/ReckonPrimer.activity/collection.py b/ReckonPrimer.activity/collection.py index 8c49451..53ababe 100644 --- a/ReckonPrimer.activity/collection.py +++ b/ReckonPrimer.activity/collection.py @@ -56,7 +56,7 @@ class Collection: #WN.LV diesen Code ersetzen: collection_table.attach(self.colldata,... self.topic_box = gtk.HBox(True, 0) #self._display.collection_table.attach(self.topic_box, 0, 6, 0, 1) - self._display.collection_table.attach(self.topic_box, 0, 6, 5, 6) + self._display.collection_table.attach(self.topic_box, 0, 9, 5, 6) def set_coll_gui(self, coll_data): """ Set gui-elements according to Collection.data. """ diff --git a/ReckonPrimer.activity/display.py b/ReckonPrimer.activity/display.py index 982924d..5cc1a95 100755 --- a/ReckonPrimer.activity/display.py +++ b/ReckonPrimer.activity/display.py @@ -122,7 +122,8 @@ class Display: # button releasing settings_table and coach.notify('setting-done',..) self.see_butt = gtk.Button(None, gtk.STOCK_GO_FORWARD) self.see_butt.connect("clicked", self.release_sett_callback) - self.settings_table.attach(self.see_butt, 0, 5, 14, 15) + #self.settings_table.attach(self.see_butt, 0, 5, 14, 15) + self.settings_table.attach(self.see_butt, 0, 8, 13, 14) self.see_alignment = self.see_butt.get_children()[0] self.see_hbox = self.see_alignment.get_children()[0] self.see_image, self.see_label = self.see_hbox.get_children() @@ -131,7 +132,8 @@ class Display: # button switching from settings_table to collect_table self.sec_butt = gtk.Button("") self.sec_butt.connect("clicked", self.switch_setts_to_coll_callback) - self.settings_table.attach(self.sec_butt, 5, 6, 14, 15) + #self.settings_table.attach(self.sec_butt, 5, 6, 14, 15) + self.settings_table.attach(self.sec_butt, 8, 9, 13, 14) self.sec_alignment = self.sec_butt.get_children()[0] self.sec_butt.show() @@ -146,13 +148,15 @@ class Display: self.stopwatch = Timer() self.stopwatch_label = gtk.Label("00:00") self.stopwatch_label.modify_font(pango.FontDescription("sans 16")) - self.feedback_table.attach(self.stopwatch_label, 3, 5, 12, 13) + #self.feedback_table.attach(self.stopwatch_label, 3, 5, 12, 13) + self.feedback_table.attach(self.stopwatch_label, 4, 6, 12, 13) # Section for nickname self.name = profile.get_nick_name() self.name_label = gtk.Label(self.name) self.name_label.modify_font(pango.FontDescription("sans 16")) - self.feedback_table.attach(self.name_label, 0, 6, 13, 14) + #self.feedback_table.attach(self.name_label, 0, 6, 13, 14) + self.feedback_table.attach(self.name_label, 0, 9, 13, 14) # Section for progress bar self.progressbar = gtk.ProgressBar(adjustment=None) @@ -162,7 +166,7 @@ class Display: style.bg[gtk.STATE_PRELIGHT] = gtk.gdk.color_parse("green") self.progressbar.set_style (style) self.progressbar.set_fraction(0) - self.feedback_table.attach(self.progressbar, 0, 6, 8, 9) + self.feedback_table.attach(self.progressbar, 0, 9, 8, 9) # Labels for progress bar self.progress0 = gtk.Label("0") @@ -180,7 +184,8 @@ class Display: attr.insert(fg_color) self.correct_counter.set_attributes(attr) - self.feedback_table.attach(self.correct_counter, 2, 4, 9, 10 ) + #self.feedback_table.attach(self.correct_counter, 2, 4, 9, 10 ) + self.feedback_table.attach(self.correct_counter, 3, 5, 9, 10 ) self.false_count = 0 self.false_counter = gtk.Label(str(self.false_count)) @@ -192,7 +197,8 @@ class Display: attr.insert(fg_color) self.false_counter.set_attributes(attr) - self.feedback_table.attach(self.false_counter, 2, 4, 10, 11 ) + #self.feedback_table.attach(self.false_counter, 2, 4, 10, 11 ) + self.feedback_table.attach(self.false_counter, 3, 5, 10, 11 ) self.stopwatch_label.show() gobject.timeout_add(1000, self.update_time) @@ -205,12 +211,13 @@ class Display: self.total_calcs = self._ex.count() self.progress_total = gtk.Label(str(self.total_calcs)) self.progress_total.modify_font(pango.FontDescription("sans 16")) - self.feedback_table.attach(self.progress_total, 5, 6, 9, 10 ) + #self.feedback_table.attach(self.progress_total, 5, 6, 9, 10 ) + self.feedback_table.attach(self.progress_total, 8, 9, 9, 10 ) self.progress_total.show() self.sfb_butt = gtk.Button(None, gtk.STOCK_STOP) self.sfb_butt.connect("clicked", self.release_feedb_callback) - self.feedback_table.attach(self.sfb_butt, 0, 6, 14, 15) + self.feedback_table.attach(self.sfb_butt, 0, 9, 13, 14) self.sfb_alignment = self.sfb_butt.get_children()[0] self.sfb_hbox = self.sfb_alignment.get_children()[0] self.sfb_image, self.sfb_label = self.sfb_hbox.get_children() @@ -373,12 +380,12 @@ class Display: def switch_exercise(self): """ Another exercise has been selected. """ - #WN091215 DAS IST AB JETZT FALSCH: ex<->sett + ex<->coll moeglich - self.settings_table.destroy() - self.settings_table = gtk.Table(15, 6, True) - self.table.attach(self.settings_table, 1, 2, 0, 5) - self.settings_table.show() - +# #WN091215 DAS IST AB JETZT FALSCH: ex<->sett + ex<->coll moeglich +# self.settings_table.destroy() +# self.settings_table = gtk.Table(15, 6, True) +# self.table.attach(self.settings_table, 1, 2, 0, 5) +# self.settings_table.show() +# self.feedback_table.destroy() self.feedback_table = gtk.Table(15, 6, True) self.table.attach(self.feedback_table, 1, 2, 0, 5) @@ -395,7 +402,7 @@ class Display: # button switching from collect_table to calcs self.flc_butt = gtk.Button(None, gtk.STOCK_GO_FORWARD) self.flc_butt.connect("clicked", self.finish_learner_coll_callback) - self.collection_table.attach(self.flc_butt, 0, 5, 14, 15) + self.collection_table.attach(self.flc_butt, 0, 8, 13, 14) self.flc_alignment = self.flc_butt.get_children()[0] self.flc_hbox = self.flc_alignment.get_children()[0] self.flc_image, self.flc_label = self.flc_hbox.get_children() @@ -405,7 +412,7 @@ class Display: # button switching from collect_table to settings_table self.sts_butt = gtk.Button("") self.sts_butt.connect("clicked", self.switch_learner_to_setts) - self.collection_table.attach(self.sts_butt, 5, 6, 14, 15) + self.collection_table.attach(self.sts_butt, 8, 9, 13, 14) self.sts_alignment = self.sts_butt.get_children()[0] self.sts_butt.show() -- cgit v0.9.1