Robin Dunn
9912e33123
* Add PyFunctionDef and PyClassDef extractor classes, which can be used for defining pure python functions and classes instead of just including them as blocks of text. This way the meta-data is preserved so it can be used by generators such as the sphinx generator.
...
* Implement wx.CallAfter and wx.CallLater this way for the initial test cases.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@70010 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-15 02:36:01 +00:00
Robin Dunn
06a7072ddf
docstring fixes
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69972 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-10 04:36:51 +00:00
Robin Dunn
a236ea1867
* Use all_raise_py_exception=True in the %Module directive.
...
* remove pyRaisesException (May want to add it back later with different meaning...)
* Fix use of const for CppMethods
* Make flattenNode optionally not rstrip the string segments
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69906 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-02 01:10:49 +00:00
Robin Dunn
fd0a62c1c4
check for overloads when it's a CppMethod too
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69779 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-17 03:51:02 +00:00
Robin Dunn
8f8c7a3d43
Add the ability to raise a wx.PyAssertionError when a wxASSERT (or other similar debug macros) fail. To do this support for the /RaisesPyException/ annotation is added, but it defaults to turned on for every function or non-ctor method.
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69723 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-10 02:43:05 +00:00
Robin Dunn
4c3663e283
Add extracting and using of class template info
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69575 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-29 06:04:32 +00:00
Robin Dunn
36e4395f88
* Add CppMethods to overload lists if there is already a matching Method.
...
* Look at all overloads when adding auto properties
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69539 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-26 05:21:47 +00:00
Robin Dunn
470c088a85
* Add the pi generator (for "Python Interface" files used by WingIDE and maybe others.)
...
* Some improvements in docstring generation
* refactor and shuffle some code around
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69497 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-21 08:09:26 +00:00
Robin Dunn
7ac7596aaa
Add support for nested classes to the extractors and sip_generator
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69414 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-14 01:28:32 +00:00
Robin Dunn
a87c196def
Instead of passing sipIsErr into custom functions made for CppMethodDefs and etc. just check PyErr_Occurred after the function returns and then set sipIsErr there.
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69400 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-13 04:58:46 +00:00
Robin Dunn
d0523eba2d
don't output an extra newline in the docstring for constructors
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69370 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-11 00:39:25 +00:00
Robin Dunn
8e2363a505
tweak the output of the docstrings a little, and also save a copy of it in case it is needed later
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69336 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-09 07:43:29 +00:00
Robin Dunn
60be5b7dfc
Make it possible for parameters to be ignored. It works in regular wrappers for args on the end of the list that have default values, and also for things like functions that have their C++ code replaced with .setCppCode
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69301 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-04 07:54:49 +00:00
Robin Dunn
8f9862b23e
Add the ability to create class properties from Python methods
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69260 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-01 07:20:19 +00:00
Robin Dunn
9dbcd04fa7
Use %DefaultDocstringFormat and write the %Docstrings indented inside the classes as expected to make the generated .sip files easier for mere humans to read and understand.
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69234 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-29 20:55:57 +00:00
Robin Dunn
e44dd28fd4
* Replacing method code with .setCppCode is now not SIP-specific. The generated code creates a new function to place the code in, like CppMethodDef does, so the given code can use 'self' and return values instead of using special SIP variables.
...
* added setCppCode_sip for when SIP-specific stuff is needed.
* Adding the 'const' on to const methods had somehow been forgotten, fix that.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69187 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-25 04:06:16 +00:00
Robin Dunn
25a28bf6cc
* Enable the use of the KeepReference annotation
...
* Use keepReference=True for the dc and buffer args in the buffered DCs to ensure that the target DC and the buffer are not GC's before the buffered DC is.
* Change #defines to output a "const int NAME" instead of an enum. It looks lots better, and is closer to the truth.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69139 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-18 04:52:28 +00:00
Robin Dunn
75b3dafeb8
Clarify a comment
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69130 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-17 19:49:33 +00:00
Robin Dunn
40c6a0d468
* Add generation of docstrings
...
* addPyMethod can now take a deprecated=True arg
* Deprecate some python methods
* Deprecate PyEvtHandler
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69126 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-17 19:46:26 +00:00
Kevin Ollivier
6b9f5b8d91
We want the name of the parent module, not the name of the module itself, for the pycode annotations.
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69109 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-17 04:47:33 +00:00
Kevin Ollivier
fdb9319c3e
Adding several new classes, some transfer annotations, and a start on a dataview model (compiles but is still a work in progress).
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@69098 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-16 05:15:38 +00:00
Robin Dunn
04f10c5868
Update Phoenix copyright statements to 2011
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@68978 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-03 01:52:23 +00:00
Kevin Ollivier
49fda7ada4
Add automatic class property generation, add support for defines, remove layout constraints from the build as they appear not to be generated with the docs for me, and add wrappers for a bunch of classes.
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@68963 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-30 15:39:33 +00:00
Robin Dunn
911d90273c
Lots of little changes made to Phoenix code over the past few months, plus some tweaks to get it running with the current wx.
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@68905 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-25 23:45:50 +00:00
Robin Dunn
6733e06ff2
We can now use PyObject* instead of SIP_PYOBJECT
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@66509 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-12-31 19:26:22 +00:00
Robin Dunn
212f1ff9f0
Gobs and gobs of changes, and tons of progress made. Can now create a wx.App, show a wx.Frame, run the MainLoop, bind event handlers and dispatch the events to the handler! YeeHa!
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@66393 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-12-17 08:08:24 +00:00
Robin Dunn
9a7f1269c1
Generate CppMethods as a separate function that is called from the wrapper, instead of embedding it in the wrapper itself. This helps us be less SIP-specific and also be able to do things like 'return' the value and use 'self->' instead of having to use variable names that make less sense.
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@66348 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-12-07 02:58:21 +00:00
Robin Dunn
971d058e6b
Add the ability to replacde the implementation of a wrapper with C++ code, but still keep all the info we pulled from the DoxyXML
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@66317 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-12-04 00:22:00 +00:00
Robin Dunn
96717983ad
A boatload of changes and additions, all my Phoenix work for the past few days. Lots of lower level classes are wrapped, wxApp is working up through OnInit, plus there's a good start on some unit tests.
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@66272 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-27 08:53:17 +00:00
Robin Dunn
5d686a914f
Add more helper functions to the exgractor classes.
...
Make it possible to distinguish between virtual and pure-virtual methods.
Switch to %AutoPyName and don't automatically use /PyName/ just to drop the leading 'wx'
Write %ModuleHeaderCode items before %Include items
git-svn-id: https://svn.wxwidgets.org/svn/wx/sandbox/trunk/Phoenix@66195 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-18 08:25:38 +00:00
Robin Dunn
24c86126d9
Add magic methods to wx.Size and add unit tests for wx.Size. Also a bit of related refactoring and cleanup.
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/sandbox/trunk/Phoenix@66147 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-14 01:29:52 +00:00
Robin Dunn
2cce365c83
"c++" --> "C++"
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/sandbox/trunk/Phoenix@66134 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-13 08:07:02 +00:00
Robin Dunn
4b9c4f29c7
Add ability to generate code into a .py file which does the import of the extension module. This will be used to add Python code to a module so we dont' have to do everything in C++.
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/sandbox/trunk/Phoenix@66127 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-12 22:20:16 +00:00
Robin Dunn
2c4ebc512e
Add file headers to the rest of the source files, don't bother with cvs keywords, fix some typos, etc.
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/sandbox/trunk/Phoenix@66114 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-11 00:54:15 +00:00
Robin Dunn
ab37739a9b
initial commit of experimental Phoenix code
...
git-svn-id: https://svn.wxwidgets.org/svn/wx/sandbox/trunk/Phoenix@66111 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-11 00:08:20 +00:00