Re: tooltips colors



Hi Sergio,

Sergio Rua wrote:

Hello,

    I would like to change the tooltips color but I don't see this new 
colors.
[...]
$tooltips->set_colors($background, $foreground);
The source for gtktooltips.c mentions that set_colors() has no effect
as the values are used from the style - so use a gtkrc file instead.

I tried to set the style in code but there is no binding to get at the
actual tooltip window. I reckon that the XS code below should return
the tip_window field so that after the tooltip is shown you can call eg.

    $new_style = new Gtk::Style;
    $new_style->bg('normal', $background);
    $new_style->fg('normal', $foreground);
    $new_style->font(Gtk::Gdk::Font->load(
        '-adobe-helvetica-bold-*-*-*-*-100-*-*-*-*-*-*'));

    $form->{'tooltips'}->tip_window->set_style($new_style);

XS code to be added to Gtk-Perl-0.7008/Gtk/xs/GtkTooltips.xs
-------------------------------------------------------
Gtk::Widget_Up
tip_window (tooltips)
    Gtk::Tooltips       tooltips

    CODE:
        RETVAL = tooltips->tip_window;

    OUTPUT:
    RETVAL
-------------------------------------------------------

Regards, Dermot




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