From ec4e2d459029e2695b27406e85fa73ab91680d0e Mon Sep 17 00:00:00 2001 From: Bastien Nocera Date: Tue, 8 Apr 2014 18:39:04 +0200 Subject: Expand docs for gdk_pixbuf_new_from_stream_at_scale() The case where preserve_aspect_ratio is TRUE and both the width and height are given wasn't explicitely documented. https://bugzilla.gnome.org/show_bug.cgi?id=727848 --- gdk-pixbuf/gdk-pixbuf-io.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/gdk-pixbuf/gdk-pixbuf-io.c b/gdk-pixbuf/gdk-pixbuf-io.c index e64b0620f..39f85a45c 100644 --- a/gdk-pixbuf/gdk-pixbuf-io.c +++ b/gdk-pixbuf/gdk-pixbuf-io.c @@ -1496,11 +1496,16 @@ load_from_stream (GdkPixbufLoader *loader, * the #GDK_PIXBUF_ERROR and %G_IO_ERROR domains. * * The image will be scaled to fit in the requested size, optionally - * preserving the image's aspect ratio. When preserving the aspect ratio, - * a @width of -1 will cause the image to be scaled to the exact given - * height, and a @height of -1 will cause the image to be scaled to the - * exact given width. When not preserving aspect ratio, a @width or - * @height of -1 means to not scale the image at all in that dimension. + * preserving the image's aspect ratio. + * + * When preserving the aspect ratio, a @width of -1 will cause the image to be + * scaled to the exact given height, and a @height of -1 will cause the image + * to be scaled to the exact given width. If both @width and @height are + * given, this function will behave as if the smaller of the two values + * is passed as -1. + * + * When not preserving aspect ratio, a @width or @height of -1 means to not + * scale the image at all in that dimension. * * The stream is not closed. * -- cgit v1.2.1