[cairo-commit] [cairo-www] src/gdkpixbufpycairo.mdwn

Carl Worth cworth at freedesktop.org
Sat Feb 23 09:31:20 PST 2008


 src/gdkpixbufpycairo.mdwn |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit e4a67db6ba255aef445529b59ff4fa925682d54e
Author: Carl Worth <cworth at cworth.org>
Date:   Sat Feb 23 09:31:07 2008 -0800

    Simplify GdkPixbuf example by removing unnecessary line

diff --git a/src/gdkpixbufpycairo.mdwn b/src/gdkpixbufpycairo.mdwn
index 87a67fa..a414ab5 100644
--- a/src/gdkpixbufpycairo.mdwn
+++ b/src/gdkpixbufpycairo.mdwn
@@ -13,8 +13,7 @@ Can be used as a very primitive image viewer.
     def expose (da, event, pixbuf):
       ctx = da.window.cairo_create()
       # You can put ctx.scale(..) or ctx.rotate(..) here, if you need some
-      ct = gtk.gdk.CairoContext(ctx)
-      ct.set_source_pixbuf(pixbuf,0,0)
+      ctx.set_source_pixbuf(pixbuf,0,0)
       ctx.paint()
       ctx.stroke()
 


More information about the cairo-commit mailing list