From f3a3965e9b1baac7e30c0e55eb851fc2b30aa836 Mon Sep 17 00:00:00 2001 From: Alexandre Antonino Gonçalves Martinazzo Date: Mon, 10 Sep 2007 21:23:51 +0000 Subject: Squashed commit of the following: commit e1108821e698adc06a10ed18e9d4caec35c811d2 Author: Alexandre Antonino Gonçalves Martinazzo Date: Mon Sep 10 18:17:35 2007 -0300 Bug #3172 fixed. Paint now start with 'Pencil' tool selected Minor changes in Area, new tool structure is comming. --- (limited to 'Desenho.py') diff --git a/Desenho.py b/Desenho.py index c73d62d..a08243c 100644 --- a/Desenho.py +++ b/Desenho.py @@ -520,6 +520,8 @@ class Desenho: event -- GdkEvent """ + + #print self.d.estadoTexto if self.d.estadoTexto == 0: self.d.estadoTexto = 1 @@ -536,28 +538,27 @@ class Desenho: try: # This works for a gtk.Entry text = self.d.janela._textview.get_text() - except: + except AttributeError: # This works for a gtk.TextView buf = self.d.janela._textview.get_buffer() start, end = buf.get_bounds() text = buf.get_text(start, end) layout = self.d.create_pango_layout(text) - layout.set_font_description(self.d.font) + #layout.set_font_description(self.d.font) self.d.pixmap.draw_layout(self.d.gc, self.d.oldx, self.d.oldy, layout) self.d.pixmap_temp.draw_layout(self.d.gc, self.d.oldx, self.d.oldy, layout) self.d.janela._textview.hide() try: self.d.janela._textview.set_text('') - except: + except AttributeError: buf.set_text('') self.d.enableUndo(widget) widget.queue_draw() - #print self.d.estadoTexto def selection(self, widget, coords, temp, fill): """Make a selection. -- cgit v0.9.1