Re: [gtkmm] Tooltips on Toolbuttons



>On Thu, 2004-09-30 at 16:34, John Spray wrote:
>> Firstly, here's what I've tried and found doesn't work: in my class
>> ("GToolbar"), I have a member "Gtk::Tooltips tooltips_".  For each
>> ToolButton created and added, I do "tooltips_.set_tip(*toolbutton, tip,
>> tip);".  This compiles and runs without errors or warnings, but no
>> tooltips are displayed.  I've tried calling tooltips_.enable().
>
>Hmmm, I've now found that doing "toolbutton->set_tooltip(tooltips_,tip)"
>works perfectly.  So now my question is: under what circumstances would
>I want to use the Gtk::Tooltips::set_tip function, and why didn't it
>work in this case?

Hi.

Maybe I get something wrong on this topic, which might explain, why I have some
troubles with tool tips myself, but please read.

As the signatures of set_tip are
<code>
Gtk::Tooltips::set_tip(Widget& widget, const Glib::ustring& tip_text)
Gtk::Tooltips::set_tip(Widget& widget, const Glib::ustring& tip_text, const
Glib::ustring& tip_private)
</code>
you can set a tip for any widget not just a tool button, right?

So I want to have tool tips on a lot of things other than tool buttons (text
boxes, regular buttons, tree view...) and this is why I call this function instead.


Still I have the problem, that none of the tool tips ever shows up, so maybe
my approach is wrong.

Best regards,

DJ



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