Ah, I see. Thanks for clearing that up! On Fri, Apr 3, 2009 at 9:53 PM, Eben Eliason <[email protected]> wrote:
> 2009/4/2 Vamsi Krishna Davuluri <[email protected]>: > > Hello, > > > > So I was wondering, after right clicking on a journal item, the palette > > again shows the file name. Why is that? as on most of the standard > operating > > systems, when ever we right click on an item, we are given options such > as > > open, open with, print, copy etc. Never the file name. > > > > Couldn't the alternate be to highlight the clicked item instead. > > This is because Sugar has "palettes", which can serve the purpose of > the normal contextual menu, but are also much more extensible. It's > possible to embed images, descriptions, and other controls into these > palettes, in addition to the usual menu of actions. > > It's true that in the list view of the Journal, the name of the entry > is redundant, but that's often not the case (consider the Neighborhood > view, or Home, etc.). The idea behind the palette is to a) provide > more info about the object it relates to (in this case, entry name, > and activity type), as well as provide the list of actions/options for > that object. We keep the redundancy here for consistency across the > UI, and also because the palette itself can cover the name of the > entry in the list. > > Eben > > > > > Also a fix to bug #610 would be > > > > def __init__(self, label=None, accel_path=None, > > menu_after_content=False, > > text_maxlen=0, **kwargs): > > > > screen = gtk.gdk.Screen() > > self.wwidth = screen.get_width() > > > > #window = gtk.Window() > > #self.wwidth, self.wheight = window.get_size() > > > > self.max_pixels = int((1.0/4)*(self.wwidth)) > > > > -------------------------------- > > if text_maxlen >= 0: > > self._label.set_max_width_chars(text_maxlen) > > self._label.set_ellipsize(pango.ELLIPSIZE_MIDDLE) > > > > labels_box.pack_start(self._label, expand=True) > > > > self._secondary_label = gtk.Label() > > self._secondary_label.set_alignment(0, 0.5) > > > > if text_maxlen >= 0: > > self._secondary_label.set_max_width_chars(text_maxlen) > > self._secondary_label.set_ellipsize(pango.ELLIPSIZE_END) > > > > > > > > > > > > ------------------------------------------------- > > > > def do_size_request(self, requisition): > > gtk.Window.do_size_request(self, requisition) > > > > # gtk.AccelLabel request doesn't include the accelerator. > > #label_width = self._label_alignment.size_request()[0] + \ > > #self._label.get_accel_width() + \ > > #2 * self.get_border_width() > > label_width= self.max_pixels > > > > requisition.width = max(requisition.width, > > style.GRID_CELL_SIZE * 2, > > label_width, > > self._full_request[0]) > > > > > > > > > > > > What this does is, It draws the screen proportional to the max_pixels > > specified(the ratio can be fine tuned by the design team), and ellipsizes > > which ever exceeds that limit. > > > > > > > > Thank you. > > > > > > > > > > _______________________________________________ > > Sugar-devel mailing list > > [email protected] > > http://lists.sugarlabs.org/listinfo/sugar-devel > > > > >
_______________________________________________ Sugar-devel mailing list [email protected] http://lists.sugarlabs.org/listinfo/sugar-devel

