[cairo-commit] pycairo/examples/cairo_snippets/snippets
clip_image.py, 1.1, 1.2 image.py, 1.1, 1.2 imagepattern.py, 1.1, 1.2
Steve Chaplin
commit at pdx.freedesktop.org
Wed May 18 21:47:58 PDT 2005
Committed by: stevech1097
Update of /cvs/cairo/pycairo/examples/cairo_snippets/snippets
In directory gabe:/tmp/cvs-serv29955/examples/cairo_snippets/snippets
Modified Files:
clip_image.py image.py imagepattern.py
Log Message:
SC
Index: clip_image.py
===================================================================
RCS file: /cvs/cairo/pycairo/examples/cairo_snippets/snippets/clip_image.py,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- clip_image.py 16 May 2005 01:05:28 -0000 1.1
+++ clip_image.py 19 May 2005 04:47:56 -0000 1.2
@@ -4,8 +4,8 @@
cr.clip ()
image = cairo.ImageSurface.create_from_png ("data/romedalen.png")
-w = image.width
-h = image.height
+w = image.get_width()
+h = image.get_height()
cr.scale (1.0/w, 1.0/h)
Index: image.py
===================================================================
RCS file: /cvs/cairo/pycairo/examples/cairo_snippets/snippets/image.py,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- image.py 16 May 2005 01:05:28 -0000 1.1
+++ image.py 19 May 2005 04:47:56 -0000 1.2
@@ -1,8 +1,8 @@
snippet_normalize (cr, width, height)
image = cairo.ImageSurface.create_from_png ("data/romedalen.png")
-w = image.width
-h = image.height
+w = image.get_width()
+h = image.get_height()
cr.translate (0.5, 0.5)
cr.rotate (45* M_PI/180)
Index: imagepattern.py
===================================================================
RCS file: /cvs/cairo/pycairo/examples/cairo_snippets/snippets/imagepattern.py,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- imagepattern.py 16 May 2005 01:05:28 -0000 1.1
+++ imagepattern.py 19 May 2005 04:47:56 -0000 1.2
@@ -3,8 +3,8 @@
snippet_normalize (cr, width, height)
image = cairo.ImageSurface.create_from_png ("data/romedalen.png")
-w = image.width
-h = image.height
+w = image.get_width()
+h = image.get_height()
pattern = cairo.Pattern.create_for_surface (image)
pattern.set_extend (cairo.EXTEND_REPEAT)
More information about the cairo-commit
mailing list