RE: Cairo in tooltips




This message appears to have been cross-posted from gtk-devel-list, so I guess I'd better cross-post it back 
again.  Anyhow...


The rectangle drawing code is from cairo snippets. My first
idea was to put a balloon, but I don't know how to draw it quickly
yet since I've just started learning Cairo for real. But perhaps
the "container" drawing doesn't have to be drawn in code at all;
instead it could be loaded from a .svg with librsvg and cached
at program startup or idle time. Then some text could be rendered
over that context with Pango.

I am deftly afraid that every program will start drawing tooltip bubbles their own way.  I happen to rather 
like the current, boring, tooltip style.  They're simple, compact, and fast.  Exactly what a tooltip should 
be.

What MIGHT work, is for the theme engine to be able to do this sort of thing by embedding an app-provided 
tooltip "body" widget in whatever kind of border it wishes.  That isn't to say the ability for an app to 
provide its own tooltip look entirely, there may be some cases where that would be useful.  But it should be 
strongly discouraged.


While this approach could be taken instead of the usual (mostly)
boring tooltips, a program could have something like a help mode
which would turn on extended tooltips showing more text and some
small images to help the user.  This is just an idea of course.

Tooltips already have a secondary tooltip text.  I was under the impression that secondary text was designed 
to hold information for such help modes.  Presumably something along the lines of those little [?] buttons 
you get in the title bar of Windows programs, and then click on a widget to get detailed help.  I'm not sure 
whether the mechanism is in place to actually use it, though..?


I think that this is useful and gives more pleasant experience
to the user, thus not just useless eye candy. If you think that
it is a good idea to suggest the developers to consider making
such tooltips then perhaps it would be good to make it even easier
in the API.

I don't really want it to be easier for an application to draw its tooltips in fancy ways.  Possible, yes.  
Utilised by the style system for all applications, certainly.  But easier and encouraged on a per-application 
basis?  No thanks.

In most cases, attaching a simple text string to a widget, to be popped up in the "normal" 
application-independant way, is very much the desired thing.  In some cases it's good if you can set the text 
string just before it's presented, and keep it updated until the tooltip closes.  In some rarer cases, being 
able to present more complex content (icons, etc.) is useful.

But personally, I think that the only situation where a single application would need to change the outer 
shape or style of a tooltip, is perhaps for a select few widgets within its UI, in which a custom tooltip 
object would work well.  On the other hand, utilising the tooltip system to present help text within a 
specific area of the UI would probably still be preferable.


Just another 0.000002c worth...

Fredderic

_______________________________________________
Join Excite! - http://www.excite.com
The most personalized portal on the Web!





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