From 1fdc9d670f1004835dc104506a4493f8f09f7d51 Mon Sep 17 00:00:00 2001 From: Jon Dowland Date: Fri, 1 Feb 2008 20:43:14 +0000 Subject: [PATCH] some debugging prints (need to fix the offsets, etc. for this copy bit) --- tools/cleanroom/tmp_cleanui.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tools/cleanroom/tmp_cleanui.py b/tools/cleanroom/tmp_cleanui.py index a50d9700..f5d617fa 100644 --- a/tools/cleanroom/tmp_cleanui.py +++ b/tools/cleanroom/tmp_cleanui.py @@ -73,9 +73,10 @@ class HellowWorldGTK: # copy each patch into the texture pixbuf for patch in texture.patches: - print "about to copy patch %s\n"%patch.name - width = min(patch.pixbuf.get_width(), int(texture.width)) - height = min(patch.pixbuf.get_height(), int(texture.height)) + print "about to copy patch %s (%d,%d)\n"% ( patch.name, patch.pixbuf.get_width(), patch.pixbuf.get_height()) + width = max(patch.pixbuf.get_width(), int(texture.width) - patch.xoff) + height = max(patch.pixbuf.get_height(), int(texture.height) - patch.yoff) + print "debug: %d,%d,%d,%d\n" % (width,height,patch.xoff,patch.yoff) patch.pixbuf.copy_area(0,0, width, height, texbuf, patch.xoff, patch.yoff)