David Farning wrote:

- To create a python gtk widget from a C gtk widget:
      pygobject_new((GObject*) widget);
  If a python wrapper for 'widget' already exists, it will incref and
  return that, other wise it will create a new python wrapper object.

Do you possibly have a concrete example for this? In particular, I have a a custom gtk treeModel that I would like to wrap?

The method I described is really only useful for small things. For wrapping a new type, you would be best to use the "codegen" autogeneration system. There is a good tutorial here:
http://www-106.ibm.com/developerworks/linux/library/l-wrap/


Looking at the source for pygtk is also a good source of information, but it's rather complex. You will need to download the source anyway to get the codegen package.

--
Tim Evans
Applied Research Associates NZ
http://www.aranz.com/

_______________________________________________
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/

Reply via email to