[cairo-commit] pycairo/doc FAQ,1.1,1.2

Steve Chaplin commit at pdx.freedesktop.org
Wed Jul 16 20:41:59 PDT 2008


Committed by: stevech1097

Update of /cvs/cairo/pycairo/doc
In directory kemper:/tmp/cvs-serv11561/doc

Modified Files:
	FAQ 
Log Message:
'SC'

Index: FAQ
===================================================================
RCS file: /cvs/cairo/pycairo/doc/FAQ,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- FAQ	13 Dec 2007 05:23:20 -0000	1.1
+++ FAQ	17 Jul 2008 03:41:56 -0000	1.2
@@ -1,12 +1,11 @@
 Pycairo FAQ - Frequently Asked Questions
 ----------------------------------------
 
-Q Can I subclass pycairo classes?
-A
-Cairo, the C library, is not an object oriented library, so a Python binding
-can never be a truly object oriented interface to cairo.  One way to write the
-Python bindings for cairo would be as a single long list of module functions -
-this would be the most accurate representation of the underlying C
+Q: Can I subclass pycairo classes?
+A: Cairo, the C library, is not an object oriented library, so a Python
+binding can never be a truly object oriented interface to cairo.  One way to
+write the Python bindings for cairo would be as a single long list of module
+functions - this would be the most accurate representation of the underlying C
 library. Pycairo (and most other cairo language bindings?) instead chose to
 implement the bindings using Context, Surface, Pattern, etc classes.  An
 advantage is that the classes organise cairo into groups of similar functions.
@@ -21,3 +20,23 @@
 
 cairo.Context can be subclassed.
 All other pycairo subclasses cannot be subclassed.
+
+
+Q: Where is the pycairo documentation?
+A: The documentation has not been written or generated yet.  The Python cairo
+bindings follow the underlying C API quite closely, so the C documentation can
+be used. It would be quite a long and tedious task to write Pycairo
+documentation from scratch; and it would essentially involve duplicating most
+of the C documentation. Another approach would be to take the existing C
+documentation and generate Python documentation from it, and just edit bits to
+make it Python-specific.  If anyone knows a good way to do this then any
+contributions would be welcome ...
+
+
+Q: How do I use pycairo with numpy?
+A: See test/isurface_create_for_data2.py
+
+
+Q: How do I use pycairo with pygame?
+A: See test/pygame-test1.py
+       test/pygame-test2.py



More information about the cairo-commit mailing list