+1998-05-11 Federico Mena Quintero <federico@nuclecu.unam.mx>
+
+ * gtk/gtkpreview.c (gtk_preview_realize): Create the window using
+ GtkPreview's visual and colormap, otherwise things can BadMatch.
+
+ * gtk/testgtk.c (create_color_preview):
+ (create_gray_preview): Removed pushing/popping of visual/colormap
+ now that GtkPreview does things correctly.
+
+ * gtk/gtkcolorsel.c (gtk_color_selection_draw_wheel_frame):
+ (gtk_color_selection_draw_wheel): Pick the style from the correct
+ place (the colorsel->wheel_area widget) so that the GCs will match
+ with where we are going to paint to.
+
+ * gtk/testgtk.c (create_color_selection): Removed pushing/popping
+ of visual/colormap now that GtkColorSelection does things the
+ right way.
+
Mon May 11 21:04:51 1998 Owen Taylor <otaylor@gtk.org>
* gtk/gtkwindow.c (gtk_real_window_move_resize): Use the
+1998-05-11 Federico Mena Quintero <federico@nuclecu.unam.mx>
+
+ * gtk/gtkpreview.c (gtk_preview_realize): Create the window using
+ GtkPreview's visual and colormap, otherwise things can BadMatch.
+
+ * gtk/testgtk.c (create_color_preview):
+ (create_gray_preview): Removed pushing/popping of visual/colormap
+ now that GtkPreview does things correctly.
+
+ * gtk/gtkcolorsel.c (gtk_color_selection_draw_wheel_frame):
+ (gtk_color_selection_draw_wheel): Pick the style from the correct
+ place (the colorsel->wheel_area widget) so that the GCs will match
+ with where we are going to paint to.
+
+ * gtk/testgtk.c (create_color_selection): Removed pushing/popping
+ of visual/colormap now that GtkColorSelection does things the
+ right way.
+
Mon May 11 21:04:51 1998 Owen Taylor <otaylor@gtk.org>
* gtk/gtkwindow.c (gtk_real_window_move_resize): Use the
+1998-05-11 Federico Mena Quintero <federico@nuclecu.unam.mx>
+
+ * gtk/gtkpreview.c (gtk_preview_realize): Create the window using
+ GtkPreview's visual and colormap, otherwise things can BadMatch.
+
+ * gtk/testgtk.c (create_color_preview):
+ (create_gray_preview): Removed pushing/popping of visual/colormap
+ now that GtkPreview does things correctly.
+
+ * gtk/gtkcolorsel.c (gtk_color_selection_draw_wheel_frame):
+ (gtk_color_selection_draw_wheel): Pick the style from the correct
+ place (the colorsel->wheel_area widget) so that the GCs will match
+ with where we are going to paint to.
+
+ * gtk/testgtk.c (create_color_selection): Removed pushing/popping
+ of visual/colormap now that GtkColorSelection does things the
+ right way.
+
Mon May 11 21:04:51 1998 Owen Taylor <otaylor@gtk.org>
* gtk/gtkwindow.c (gtk_real_window_move_resize): Use the
+1998-05-11 Federico Mena Quintero <federico@nuclecu.unam.mx>
+
+ * gtk/gtkpreview.c (gtk_preview_realize): Create the window using
+ GtkPreview's visual and colormap, otherwise things can BadMatch.
+
+ * gtk/testgtk.c (create_color_preview):
+ (create_gray_preview): Removed pushing/popping of visual/colormap
+ now that GtkPreview does things correctly.
+
+ * gtk/gtkcolorsel.c (gtk_color_selection_draw_wheel_frame):
+ (gtk_color_selection_draw_wheel): Pick the style from the correct
+ place (the colorsel->wheel_area widget) so that the GCs will match
+ with where we are going to paint to.
+
+ * gtk/testgtk.c (create_color_selection): Removed pushing/popping
+ of visual/colormap now that GtkColorSelection does things the
+ right way.
+
Mon May 11 21:04:51 1998 Owen Taylor <otaylor@gtk.org>
* gtk/gtkwindow.c (gtk_real_window_move_resize): Use the
+1998-05-11 Federico Mena Quintero <federico@nuclecu.unam.mx>
+
+ * gtk/gtkpreview.c (gtk_preview_realize): Create the window using
+ GtkPreview's visual and colormap, otherwise things can BadMatch.
+
+ * gtk/testgtk.c (create_color_preview):
+ (create_gray_preview): Removed pushing/popping of visual/colormap
+ now that GtkPreview does things correctly.
+
+ * gtk/gtkcolorsel.c (gtk_color_selection_draw_wheel_frame):
+ (gtk_color_selection_draw_wheel): Pick the style from the correct
+ place (the colorsel->wheel_area widget) so that the GCs will match
+ with where we are going to paint to.
+
+ * gtk/testgtk.c (create_color_selection): Removed pushing/popping
+ of visual/colormap now that GtkColorSelection does things the
+ right way.
+
Mon May 11 21:04:51 1998 Owen Taylor <otaylor@gtk.org>
* gtk/gtkwindow.c (gtk_real_window_move_resize): Use the
+1998-05-11 Federico Mena Quintero <federico@nuclecu.unam.mx>
+
+ * gtk/gtkpreview.c (gtk_preview_realize): Create the window using
+ GtkPreview's visual and colormap, otherwise things can BadMatch.
+
+ * gtk/testgtk.c (create_color_preview):
+ (create_gray_preview): Removed pushing/popping of visual/colormap
+ now that GtkPreview does things correctly.
+
+ * gtk/gtkcolorsel.c (gtk_color_selection_draw_wheel_frame):
+ (gtk_color_selection_draw_wheel): Pick the style from the correct
+ place (the colorsel->wheel_area widget) so that the GCs will match
+ with where we are going to paint to.
+
+ * gtk/testgtk.c (create_color_selection): Removed pushing/popping
+ of visual/colormap now that GtkColorSelection does things the
+ right way.
+
Mon May 11 21:04:51 1998 Owen Taylor <otaylor@gtk.org>
* gtk/gtkwindow.c (gtk_real_window_move_resize): Use the
+1998-05-11 Federico Mena Quintero <federico@nuclecu.unam.mx>
+
+ * gtk/gtkpreview.c (gtk_preview_realize): Create the window using
+ GtkPreview's visual and colormap, otherwise things can BadMatch.
+
+ * gtk/testgtk.c (create_color_preview):
+ (create_gray_preview): Removed pushing/popping of visual/colormap
+ now that GtkPreview does things correctly.
+
+ * gtk/gtkcolorsel.c (gtk_color_selection_draw_wheel_frame):
+ (gtk_color_selection_draw_wheel): Pick the style from the correct
+ place (the colorsel->wheel_area widget) so that the GCs will match
+ with where we are going to paint to.
+
+ * gtk/testgtk.c (create_color_selection): Removed pushing/popping
+ of visual/colormap now that GtkColorSelection does things the
+ right way.
+
Mon May 11 21:04:51 1998 Owen Taylor <otaylor@gtk.org>
* gtk/gtkwindow.c (gtk_real_window_move_resize): Use the
GtkStyle *style;
gint w, h;
- style = gtk_widget_get_style (GTK_WIDGET (colorsel));
+ style = gtk_widget_get_style (colorsel->wheel_area);
w = colorsel->wheel_area->allocation.width;
h = colorsel->wheel_area->allocation.height;
gint x, y, i, wid, heig, n;
gdouble cx, cy, h, s, c[3];
guchar bg[3];
- GtkStyle *style = gtk_widget_get_style (GTK_WIDGET (colorsel));
+ GtkStyle *style = gtk_widget_get_style (colorsel->wheel_area);
wid = colorsel->wheel_area->allocation.width;
heig = colorsel->wheel_area->allocation.height;
attributes.width = widget->allocation.width;
attributes.height = widget->allocation.height;
attributes.wclass = GDK_INPUT_OUTPUT;
- attributes.visual = gtk_widget_get_visual (widget);
- attributes.colormap = gtk_widget_get_colormap (widget);
+ attributes.visual = preview_class->info.visual;
+ attributes.colormap = preview_class->info.cmap;
attributes.event_mask = gtk_widget_get_events (widget) | GDK_EXPOSURE_MASK;
attributes_mask = GDK_WA_X | GDK_WA_Y | GDK_WA_VISUAL | GDK_WA_COLORMAP;
if (!window)
{
- gtk_preview_set_install_cmap (TRUE);
- gtk_widget_push_visual (gtk_preview_get_visual ());
- gtk_widget_push_colormap (gtk_preview_get_cmap ());
-
window = gtk_color_selection_dialog_new ("color selection dialog");
gtk_color_selection_set_opacity (
"clicked",
GTK_SIGNAL_FUNC(gtk_widget_destroy),
GTK_OBJECT (window));
-
- gtk_widget_pop_colormap ();
- gtk_widget_pop_visual ();
}
if (!GTK_WIDGET_VISIBLE (window))
if (!window)
{
- gtk_widget_push_visual (gtk_preview_get_visual ());
- gtk_widget_push_colormap (gtk_preview_get_cmap ());
-
window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
gtk_signal_connect (GTK_OBJECT (window), "destroy",
}
color_idle = gtk_idle_add ((GtkFunction) color_idle_func, preview);
-
- gtk_widget_pop_colormap ();
- gtk_widget_pop_visual ();
}
if (!GTK_WIDGET_VISIBLE (window))
if (!window)
{
- gtk_widget_push_visual (gtk_preview_get_visual ());
- gtk_widget_push_colormap (gtk_preview_get_cmap ());
-
window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
gtk_signal_connect (GTK_OBJECT (window), "destroy",
}
gray_idle = gtk_idle_add ((GtkFunction) gray_idle_func, preview);
-
- gtk_widget_pop_colormap ();
- gtk_widget_pop_visual ();
}
if (!GTK_WIDGET_VISIBLE (window))
if (!window)
{
- gtk_preview_set_install_cmap (TRUE);
- gtk_widget_push_visual (gtk_preview_get_visual ());
- gtk_widget_push_colormap (gtk_preview_get_cmap ());
-
window = gtk_color_selection_dialog_new ("color selection dialog");
gtk_color_selection_set_opacity (
"clicked",
GTK_SIGNAL_FUNC(gtk_widget_destroy),
GTK_OBJECT (window));
-
- gtk_widget_pop_colormap ();
- gtk_widget_pop_visual ();
}
if (!GTK_WIDGET_VISIBLE (window))
if (!window)
{
- gtk_widget_push_visual (gtk_preview_get_visual ());
- gtk_widget_push_colormap (gtk_preview_get_cmap ());
-
window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
gtk_signal_connect (GTK_OBJECT (window), "destroy",
}
color_idle = gtk_idle_add ((GtkFunction) color_idle_func, preview);
-
- gtk_widget_pop_colormap ();
- gtk_widget_pop_visual ();
}
if (!GTK_WIDGET_VISIBLE (window))
if (!window)
{
- gtk_widget_push_visual (gtk_preview_get_visual ());
- gtk_widget_push_colormap (gtk_preview_get_cmap ());
-
window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
gtk_signal_connect (GTK_OBJECT (window), "destroy",
}
gray_idle = gtk_idle_add ((GtkFunction) gray_idle_func, preview);
-
- gtk_widget_pop_colormap ();
- gtk_widget_pop_visual ();
}
if (!GTK_WIDGET_VISIBLE (window))