Proposal: ToolTips Additions



hello everybody,

i'd like to make some changes additions to the tooltips
object if nobody objects ;)

first i'd like the "_GtkTooltips" object data key that
is set for widgets that have a tooltip set to be renamed
to "_GtkToolTipsData", because that name identifies the
structure name that the pointer actually points to.

second, i'd like to add a
gchar *tip_help_index field (or similar) to _GtkTooltipsData
that can acts as a help document index (can be used for context
sensitive help).
therefore i'd like to have a new function
void         gtk_tooltips_set_tip   (GtkTooltips *tooltips,
                                     GtkWidget   *widget,
                                     const gchar *tip_text,
				     const gchar *tip_help_index);

that is going to be used in case of the old gtk_tooltips_set_tips()
function.
some might argue that function better be called
gtk_tooltips_set_tips_with_index or something similar, but since i'd
like gtk_tooltips_set_tip() the new commonly used tooltips set function
use of gtk_tooltips_set_tips should soon become discouraged and can be
removed at some point. (but i already feel that this needs to stand some
further discussion ;)

now with the above mentioned changes, it'll be quite easy to provide
a GtkQueryTip widget that can be activated on a (much cited) [?] button.
it'll grab the pointer and can display the tooltips string of a widget
crossed by the pointer in a customized label (or printf() it via signal
emission...).
further, if a widget is clicked on in this "tip inspection mode", the grab
will be released and context sensitive help for the clicked widget
can be invoked via the tip_help_index.

[for the ones more familiar involved with gtk, the button clicks
 or even keypresses can easily be captured for the crossed widgets
 by changing their event masks "on the fly" that is when a widgets
 window is left or entered]

further suggestions?


---
ciaoTJ



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