From 0d101829afb737a93d48ee8e6a545c11613ee2a9 Mon Sep 17 00:00:00 2001 From: Jeremy Katz Date: Fri, 23 Mar 2007 21:46:17 +0000 Subject: 2007-03-23 Jeremy Katz * gui.py (readImageFromFile): Make width/height args be in the same order as GTK functions --- gui.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'gui.py') diff --git a/gui.py b/gui.py index 8c14f8d7f..5093acea8 100755 --- a/gui.py +++ b/gui.py @@ -447,17 +447,17 @@ def getPixbuf(file): return pixbuf -def readImageFromFile(file, height = None, width = None, dither = None, +def readImageFromFile(file, width = None, height = None, dither = None, image = None): pixbuf = getPixbuf(file) if pixbuf is None: log.warning("can't find pixmap %s" %(file,)) return None - if (height is not None and width is not None + if (width is not None and height is not None and height != pixbuf.get_height() and width != pixbuf.get_width()): - pixbuf = pixbuf.scale_simple(height, width, + pixbuf = pixbuf.scale_simple(width, height, gtk.gdk.INTERP_BILINEAR) if image is None: -- cgit