#4311 HIGH Update.: Need cancel button icon in search field
Zarro Boogs per Child
bugtracker at laptop.org
Mon Nov 19 12:07:55 EST 2007
#4311: Need cancel button icon in search field
-------------------------------+--------------------------------------------
Reporter: Eben | Owner: rwh
Type: defect | Status: new
Priority: high | Milestone: Update.1
Component: journal-activity | Version:
Resolution: | Keywords: Update.1? review-
Verified: 0 |
-------------------------------+--------------------------------------------
Comment(by rwh):
Replying to [comment:7 tomeu]:
{{{
from sugar.graphics.icon import _SVGLoader
}}}
>
> Should we make this class public? I could use it also for the icons in
comboboxes (see #4420). Marco?
I think so!
{{{
color = sugar.profile.get_color()
entities = {'fill_color': color.get_fill_color(),
'stroke_color': color.get_stroke_color()}
}}}
>
> SVG icons will always get colored with the xo colors? Eben? Perhaps the
colors should be arguments of the set_icon_from_name method.
It's very practical: the default coloring leaves quite a few icons
invisible. One example is the dialog-cancel icon I'm using here. I guess
this is a bug on its own; at least it was very confusing to me!
{{{
def remove_icon(self, position):
empty_image = gtk.Image()
_sugarext.IconEntry.set_icon(self, position, empty_image)
}}}
>
> IconEntry already has an API for removing an icon:
icon_entry.set_icon(position, None). Not sure how we should document that,
though :/
Ah, I didn't know, and it wasn't exactly obvious from the code either.
I'll change that and put it in a docstring somewhere
{{{
self._cancel_shown = None
}}}
> Please initialize all member variables in the constructor.
np
{{{
self.connect('key_press_event', self._keypress_event_cb)
}}}
>
> Why only connect to key-press-event when the cancel button is added? We
only want to respond to the Escape key after a cancel button has been
added? Perhaps we should connect in the constructor?
Sounds good, will do
--
Ticket URL: <http://dev.laptop.org/ticket/4311#comment:8>
One Laptop Per Child <http://dev.laptop.org>
OLPC bug tracking system
More information about the Bugs
mailing list