tooltip colors
- From: Bob Stafford <bobstaff snowhill com>
- To: gtk-list redhat com
- Subject: tooltip colors
- Date: Tue, 12 Oct 1999 21:12:45 -0500
I've got one question and one bug report (I think).
Firstly the bug report (I assume that the people who maintain GTK read
this list, if there is a better place to report bugs please let me
know).
In the file gtktooltips.c at around line 401 is the following piece of
code
if (background != NULL) -- I think this should be
foreground
tooltips->foreground = foreground;
if (foreground != NULL) -- and this should be
background.
tooltips->background = background;
Next the question that led me to be looking at the code in the first
place.
Can anybody tell me why the tooltip in the following test program does
not have black text on a blue background. I'm running gtk 1.2.6 on
RH 6.0.
Thanks
Bob S.
#include <gtk/gtk.h>
#include <gtk/gtk.h>
int main(int argc,char *argv[])
GtkWidget *window;
GtkTooltips *tooltips;
GdkColor blue = {0,0x0000,0x0000,0xffff};
GdkColor black = {0,0x0000,0x0000,0x0000};
gtk_init(&argc,&argv);
gdk_color_alloc(gdk_colormap_get_system(),&blue);
gdk_color_alloc(gdk_colormap_get_system(),&black);
window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
gtk_widget_show_all(window);
tooltips = gtk_tooltips_new();
gtk_tooltips_set_colors(tooltips,&blue,&black);
gtk_tooltips_set_tip(tooltips,window,"This is a tooltip",NULL);
gtk_main();
return(0);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]