Commit d65da691 authored by Victor Ananjevsky's avatar Victor Ananjevsky

improve scaling

parent ea77e6b6
...@@ -218,7 +218,7 @@ change_size_cb (GtkWidget *w, gint type) ...@@ -218,7 +218,7 @@ change_size_cb (GtkWidget *w, gint type)
options.picture_data.size = YAD_PICTURE_ORIG; options.picture_data.size = YAD_PICTURE_ORIG;
break; break;
case SIZE_INC: case SIZE_INC:
new_pb = gdk_pixbuf_scale_simple (pb, width + options.picture_data.inc, new_pb = gdk_pixbuf_scale_simple (img->orig_pb, width + options.picture_data.inc,
height + options.picture_data.inc, GDK_INTERP_HYPER); height + options.picture_data.inc, GDK_INTERP_HYPER);
if (new_pb) if (new_pb)
{ {
...@@ -227,7 +227,7 @@ change_size_cb (GtkWidget *w, gint type) ...@@ -227,7 +227,7 @@ change_size_cb (GtkWidget *w, gint type)
} }
break; break;
case SIZE_DEC: case SIZE_DEC:
new_pb = gdk_pixbuf_scale_simple (pb, width - options.picture_data.inc, new_pb = gdk_pixbuf_scale_simple (img->orig_pb, width - options.picture_data.inc,
height - options.picture_data.inc, GDK_INTERP_HYPER); height - options.picture_data.inc, GDK_INTERP_HYPER);
if (new_pb) if (new_pb)
{ {
......
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