Re: GtkStockItem ...



Michael Meeks <michael ximian com> writes:

> Hi Owen,
> 
> On 19 Oct 2001, Owen Taylor wrote:
> > I guess one question, which is more of a style question, is whether
> > it's possible to have useful tooltips that are generic:
> 
>         Good point; clearly people will want to override them, but I think
> many of them could have useful fallback tips, and some purely generic ones
> eg.
> 
> Generic:  Undo, Redo, Cut, Paste, Copy, Find, Replace, Back, Forward,
>           Help, Home, Italic, Center, Fill, Left, Right, No, Ok,
>           Paste, Preferences, Quit, Zoom 100%, Zoom to Fit, Zoom In,
>           Zoom Out, Spell Check, Strikethrough

In what of these would you have anything but an echoing of the 
label as the tooltip? Why is echoing the label useful?

> Less generic: New, Save, Open, Save As, Print, Print Preview ...
> 
> > That, is, for "Save", would I want the tooltip to be "Save" (that's
> > not useful is it?), or should it be:
> >
> >   Save Document
> 
>         Well - I think using a word such as document would prolly be best
> in many cases, or perhaps 'data' if we're Anal; or even just having a NULL
> tooltip for these cases.
> 
>         Convinced of the utility ? it's a real pain having standard
> everything but tooltips :-) still gagging to make up a patch.

No, I'm not really convinced, I'm afraid. If we can't normally 
provide a useful standard tooltip, then I think it is better
to say "you must provide a tooltip even for stock items" rather
than "some stock items provide tooltips, some provide tooltips
that you'd be better off replace, some don't provide tooltips."

The unfortunate thing here is that we can't compatibly extend
the structure in the future, except with something MS-like thing
like:

struct _GtkStockItemExtended
{
  [ GtkStockItem fields]
  char *tooltip;
};

void gtk_stock_add_extended (const GtkStockItemExtended *items,
                              guint                      n_items);

Which is gross, if workable. 

I'm not happy about it one way or the other, but in the interests
of cutting off API changes, I think we should stick with the
current GtkStockItem.

Regards,
                                        Owen




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]