diff --git a/sugar/graphics/radiotoolbutton.py b/sugar/graphics/radiotoolbutton.py index 52fe61c7..fb584ee2 100644 --- a/sugar/graphics/radiotoolbutton.py +++ b/sugar/graphics/radiotoolbutton.py @@ -50,7 +50,7 @@ class RadioToolButton(gtk.RadioToolButton): self._palette.props.invoker = WidgetInvoker(self.child) def do_expose_event(self, event): - if self._palette: + if self._palette and self._palette.props.draw_gap: if self._palette.is_up() or self.child.state == gtk.STATE_PRELIGHT: invoker = self._palette.props.invoker invoker.draw_invoker_rect(event, self._palette) diff --git a/sugar/graphics/toggletoolbutton.py b/sugar/graphics/toggletoolbutton.py index 975e78a4..41050e21 100644 --- a/sugar/graphics/toggletoolbutton.py +++ b/sugar/graphics/toggletoolbutton.py @@ -49,7 +49,7 @@ class ToggleToolButton(gtk.ToggleToolButton): self._palette.props.invoker = WidgetInvoker(self.child) def do_expose_event(self, event): - if self._palette: + if self._palette and self._palette.props.draw_gap: if self._palette.is_up() or self.child.state == gtk.STATE_PRELIGHT: invoker = self._palette.props.invoker invoker.draw_invoker_rect(event, self._palette) diff --git a/sugar/graphics/toolbutton.py b/sugar/graphics/toolbutton.py index c447b3c6..52a5d62c 100644 --- a/sugar/graphics/toolbutton.py +++ b/sugar/graphics/toolbutton.py @@ -51,7 +51,7 @@ class ToolButton(gtk.ToolButton): self.set_palette(Palette(text)) def do_expose_event(self, event): - if self._palette: + if self._palette and self._palette.props.draw_gap: if self._palette.is_up() or self.child.state == gtk.STATE_PRELIGHT: invoker = self._palette.props.invoker invoker.draw_invoker_rect(event, self._palette)