Commit 0bb5a764 authored by Michael Natterer's avatar Michael Natterer 😴

app: fix wilber dawing offset on widgets that don't have a window

parent ebe4b410
...@@ -159,6 +159,9 @@ gimp_cairo_draw_toolbox_wilber (GtkWidget *widget, ...@@ -159,6 +159,9 @@ gimp_cairo_draw_toolbox_wilber (GtkWidget *widget,
factor = allocation.width / wilber_width * 0.9; factor = allocation.width / wilber_width * 0.9;
if (! gtk_widget_get_has_window (widget))
cairo_translate (cr, allocation.x, allocation.y);
cairo_scale (cr, factor, factor); cairo_scale (cr, factor, factor);
gimp_cairo_wilber (cr, gimp_cairo_wilber (cr,
...@@ -208,6 +211,9 @@ gimp_cairo_draw_drop_wilber (GtkWidget *widget, ...@@ -208,6 +211,9 @@ gimp_cairo_draw_drop_wilber (GtkWidget *widget,
factor = MIN (width / wilber_width, height / wilber_height); factor = MIN (width / wilber_width, height / wilber_height);
if (! gtk_widget_get_has_window (widget))
cairo_translate (cr, allocation.x, allocation.y);
cairo_scale (cr, factor, factor); cairo_scale (cr, factor, factor);
/* magic factors depend on the image used, everything else is generic /* magic factors depend on the image used, everything else is generic
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment