Copied/merged from the 2.2 branch.
Changes needed to build with new event system git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@9374 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
7aa54cf749
commit
1b62f00d8e
@ -55,10 +55,6 @@ B. You'll usually want to use wxWindows sources that have the same
|
||||
version number as the wxPython sources you are using. (Another
|
||||
advantage of using CVS is that you'll get both at the same time.)
|
||||
|
||||
NOTE: There probably isn't going to be an official 2.2.2 release
|
||||
for wxMSW so I have taken a snapshot of my workspace and made it
|
||||
available at http://alldunn.com/wxPython/dist/others/
|
||||
|
||||
C. Once you get the sources be sure to put them in a path without a
|
||||
space in it (i.e., NOT c:\Program Files\wx) and set an environment
|
||||
variable named WXWIN to this directory. For example:
|
||||
@ -93,7 +89,6 @@ D. Change to the wx2\include\wx\msw directory and copy setup0.h to
|
||||
wxUSE_DIALUP_MANAGER 0
|
||||
wxUSE_DYNLIB_CLASS 0
|
||||
wxUSE_DOC_VIEW_ARCHITECTURE 0
|
||||
wxUSE_MDI_ARCHITECTURE 0
|
||||
wxUSE_PLOT 0
|
||||
wxUSE_POSTSCRIPT_ARCHITECTURE_IN_MSW 0
|
||||
|
||||
|
@ -2,7 +2,8 @@ CHANGES.txt for wxPython
|
||||
|
||||
----------------------------------------------------------------------
|
||||
|
||||
2.3b2
|
||||
|
||||
2.2.5
|
||||
-----
|
||||
|
||||
New typemaps for wxString when compiling for Python 2.0 and beyond
|
||||
@ -35,8 +36,8 @@ Fixed GOBS of reference leaks.
|
||||
|
||||
Massive code changes and cleanup to allow wxPython to be split into
|
||||
multiple extension modules again. A Python CObject is used to allow
|
||||
the "export" of SWIG and other common helper functions from the wxc
|
||||
module to other modules, even if they are in separate shared
|
||||
the "export" of SWIG functions and other common helper functions from
|
||||
the wxc module to other modules, even if they are in separate shared
|
||||
libraries. Should also be usable from 3rd party code, just include
|
||||
wxPython/src/export.h
|
||||
|
||||
@ -44,6 +45,22 @@ Changed the default setup so the following are built as separate
|
||||
extension modules: calendar, glcanvas, grid, html, ogl, stc, and
|
||||
utils. Will probably add more later.
|
||||
|
||||
Changed the wxPrinterDC to use the new constructor taking a
|
||||
wxPrintData object. The old ctor is still there using the
|
||||
wxPrinterDC2 name.
|
||||
|
||||
Added wxPython.lib.anchors.py from Riaan Booysen. It contains a class
|
||||
that implements Delphi's Anchors with wxLayoutConstraints.
|
||||
|
||||
Added wxPython.lib.fancytext from Timothy Hochberg.
|
||||
|
||||
Changed the GenericButtons to send their event in idle time, so the
|
||||
mouse won't be captured when the event handler is called.
|
||||
|
||||
Added wxPython.lib.rpcMixin from Greg Landrum, although it's not
|
||||
integrated with the demo yet. It allows a wxPython GUI to be an
|
||||
XML-RPC server.
|
||||
|
||||
|
||||
|
||||
New in 2.2.2
|
||||
|
@ -2,6 +2,8 @@ include *.txt
|
||||
include my_distutils.py
|
||||
## include my_install_data.py
|
||||
include licence/*.txt
|
||||
include b
|
||||
include b.bat
|
||||
|
||||
include demo/*.py
|
||||
include demo/bitmaps/*.bmp
|
||||
|
27
wxPython/b
27
wxPython/b
@ -33,8 +33,31 @@ elif [ "$1" = "s" ]; then
|
||||
|
||||
# "r" --> rpm dist
|
||||
elif [ "$1" = "r" ]; then
|
||||
shift
|
||||
CMD="$SETUP $OTHERFLAGS bdist_rpm"
|
||||
|
||||
# save the original
|
||||
cp setup.py setup.py.save
|
||||
|
||||
# fix up setup.py the way we want...
|
||||
sed "s/BUILD_GLCANVAS = /BUILD_GLCANVAS = 0 #/" < setup.py.save > setup.py.temp
|
||||
sed "s/GL_ONLY = /GL_ONLY = 1 #/" < setup.py.temp > setup.py
|
||||
|
||||
# build wxPython-gl RPM
|
||||
$SETUP $OTHERFLAGS bdist_rpm --binary-only --doc-files README.txt
|
||||
rm dist/wxPython-gl*.tar.gz
|
||||
|
||||
# Build wxPython RPM
|
||||
cp setup.py setup.py.temp
|
||||
sed "s/GL_ONLY = /GL_ONLY = 0 #/" < setup.py.temp > setup.py
|
||||
$SETUP $OTHERFLAGS bdist_rpm
|
||||
|
||||
# put the oringal back
|
||||
cp setup.py.save setup.py
|
||||
rm setup.py.*
|
||||
|
||||
# rebuild the source dist without the munched up setup.py
|
||||
$SETUP $OTHERFLAGS sdist
|
||||
exit 0
|
||||
|
||||
|
||||
# (no command arg) --> normal build for development
|
||||
else
|
||||
|
@ -653,9 +653,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPNMHandler","_class_wxPNMHandler",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_wxLogGui","_class_wxLogGui",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
{ "_wxSysColourChangedEvent","_class_wxSysColourChangedEvent",0},
|
||||
@ -972,12 +972,12 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxPyApp","_wxPyApp",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxLogTextCtrl","_wxLogTextCtrl",0},
|
||||
{ "_class_wxLogGui","_wxLogGui",0},
|
||||
{ "_class_wxMDIParentFrame","_wxMDIParentFrame",0},
|
||||
{ "_wxPyTreeItemData","_class_wxPyTreeItemData",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_wxStaticBoxSizer","_class_wxStaticBoxSizer",0},
|
||||
{ "_class_wxTimeSpan","_wxTimeSpan",0},
|
||||
{ "_class_wxPyFileSystemHandler","_wxPyFileSystemHandler",0},
|
||||
|
@ -351,6 +351,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxPNMHandler","_class_wxPNMHandler",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_wxLogGui","_class_wxLogGui",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxPyShapeEvtHandler","_wxPyShapeEvtHandler",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -360,7 +361,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxPySizer","_wxPySizer",0},
|
||||
{ "_class_wxPyCompositeShape","_wxPyCompositeShape",0},
|
||||
{ "_wxPyPolygonShape","_class_wxPyPolygonShape",0},
|
||||
{ "_class_wxPostScriptDC","_wxPostScriptDC",0},
|
||||
{ "_wxPanel","_class_wxPanel",0},
|
||||
{ "_wxInitDialogEvent","_class_wxInitDialogEvent",0},
|
||||
{ "_wxCheckBox","_class_wxCheckBox",0},
|
||||
@ -426,6 +426,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxZipFSHandler","_wxZipFSHandler",0},
|
||||
{ "_char","_wxChar",0},
|
||||
{ "_wxBitmap","_class_wxBitmap",0},
|
||||
{ "_wxTaskBarIcon","_class_wxTaskBarIcon",0},
|
||||
{ "_wxPrintDialog","_class_wxPrintDialog",0},
|
||||
{ "_wxPyControlPoint","_class_wxPyControlPoint",0},
|
||||
{ "_wxWindowDC","_class_wxWindowDC",0},
|
||||
@ -517,6 +518,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxTextCtrl","_wxTextCtrl",0},
|
||||
{ "_class_wxListItemAttr","_wxListItemAttr",0},
|
||||
{ "_wxLayoutConstraints","_class_wxLayoutConstraints",0},
|
||||
{ "_wxMetaFileDC","_class_wxMetaFileDC",0},
|
||||
{ "_class_wxTextDataObject","_wxTextDataObject",0},
|
||||
{ "_wxMenu","_class_wxMenu",0},
|
||||
{ "_class_wxMoveEvent","_wxMoveEvent",0},
|
||||
@ -552,6 +554,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxBusyInfo","_class_wxBusyInfo",0},
|
||||
{ "_class_wxMenuEvent","_wxMenuEvent",0},
|
||||
{ "_wxPaletteChangedEvent","_class_wxPaletteChangedEvent",0},
|
||||
{ "_wxJoystick","_class_wxJoystick",0},
|
||||
{ "_class_wxPyBitmapDataObject","_wxPyBitmapDataObject",0},
|
||||
{ "_class_wxPyCircleShape","_wxPyCircleShape",0},
|
||||
{ "_wxClientDC","_class_wxClientDC",0},
|
||||
@ -569,6 +572,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_signed_short","_short",0},
|
||||
{ "_wxMemoryDC","_class_wxMemoryDC",0},
|
||||
{ "_wxPyTextDataObject","_class_wxPyTextDataObject",0},
|
||||
{ "_class_wxTaskBarIcon","_wxTaskBarIcon",0},
|
||||
{ "_class_wxPrintDialog","_wxPrintDialog",0},
|
||||
{ "_wxPyFileSystemHandler","_class_wxPyFileSystemHandler",0},
|
||||
{ "_class_wxPyControlPoint","_wxPyControlPoint",0},
|
||||
@ -579,7 +583,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxStatusBar","_class_wxStatusBar",0},
|
||||
{ "_class_wxAcceleratorEntry","_wxAcceleratorEntry",0},
|
||||
{ "_class_wxCursor","_wxCursor",0},
|
||||
{ "_wxPostScriptDC","_class_wxPostScriptDC",0},
|
||||
{ "_wxPyFileDropTarget","_class_wxPyFileDropTarget",0},
|
||||
{ "_class_wxPyProcess","_wxPyProcess",0},
|
||||
{ "_class_wxImageHandler","_wxImageHandler",0},
|
||||
@ -588,6 +591,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxLog","_wxLog",0},
|
||||
{ "_wxTreeItemId","_class_wxTreeItemId",0},
|
||||
{ "_unsigned_char","_byte",0},
|
||||
{ "_class_wxMetaFileDC","_wxMetaFileDC",0},
|
||||
{ "_class_wxMenu","_wxMenu",0},
|
||||
{ "_wxControl","_class_wxControl",0},
|
||||
{ "_class_wxListBox","_wxListBox",0},
|
||||
@ -680,6 +684,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxLogGui","_wxLogGui",0},
|
||||
{ "_class_wxMDIParentFrame","_wxMDIParentFrame",0},
|
||||
{ "_wxPyTreeItemData","_class_wxPyTreeItemData",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_wxStaticBoxSizer","_class_wxStaticBoxSizer",0},
|
||||
{ "_class_wxTimeSpan","_wxTimeSpan",0},
|
||||
{ "_class_wxPyFileSystemHandler","_wxPyFileSystemHandler",0},
|
||||
@ -738,6 +743,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxGauge","_class_wxGauge",0},
|
||||
{ "_class_wxCheckListBox","_wxCheckListBox",0},
|
||||
{ "_class_wxBusyInfo","_wxBusyInfo",0},
|
||||
{ "_class_wxJoystick","_wxJoystick",0},
|
||||
{ "_class_wxCommandEvent","_wxCommandEvent",0},
|
||||
{ "_class_wxClientDC","_wxClientDC",0},
|
||||
{ "_class_wxSizeEvent","_wxSizeEvent",0},
|
||||
|
@ -8466,6 +8466,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxPNMHandler","_class_wxPNMHandler",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_wxLogGui","_class_wxLogGui",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxPyShapeEvtHandler","_class_wxPyShape",SwigwxPyShapeTowxPyShapeEvtHandler},
|
||||
{ "_class_wxPyShapeEvtHandler","_wxPyShape",SwigwxPyShapeTowxPyShapeEvtHandler},
|
||||
{ "_class_wxPyShapeEvtHandler","_wxPyShapeEvtHandler",0},
|
||||
@ -8475,7 +8476,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxStatusBar","_wxStatusBar",0},
|
||||
{ "_class_wxGIFHandler","_wxGIFHandler",0},
|
||||
{ "_class_wxPySizer","_wxPySizer",0},
|
||||
{ "_class_wxPostScriptDC","_wxPostScriptDC",0},
|
||||
{ "_wxPanel","_class_wxPanel",0},
|
||||
{ "_wxInitDialogEvent","_class_wxInitDialogEvent",0},
|
||||
{ "_wxCheckBox","_class_wxCheckBox",0},
|
||||
@ -8538,6 +8538,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxZipFSHandler","_wxZipFSHandler",0},
|
||||
{ "_char","_wxChar",0},
|
||||
{ "_wxBitmap","_class_wxBitmap",0},
|
||||
{ "_wxTaskBarIcon","_class_wxTaskBarIcon",0},
|
||||
{ "_wxPrintDialog","_class_wxPrintDialog",0},
|
||||
{ "_wxWindowDC","_class_wxWindowDC",0},
|
||||
{ "_wxTimerEvent","_class_wxTimerEvent",0},
|
||||
@ -8622,6 +8623,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxTextCtrl","_wxTextCtrl",0},
|
||||
{ "_class_wxListItemAttr","_wxListItemAttr",0},
|
||||
{ "_wxLayoutConstraints","_class_wxLayoutConstraints",0},
|
||||
{ "_wxMetaFileDC","_class_wxMetaFileDC",0},
|
||||
{ "_class_wxTextDataObject","_wxTextDataObject",0},
|
||||
{ "_wxMenu","_class_wxMenu",0},
|
||||
{ "_class_wxMoveEvent","_wxMoveEvent",0},
|
||||
@ -8656,6 +8658,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxBusyInfo","_class_wxBusyInfo",0},
|
||||
{ "_class_wxMenuEvent","_wxMenuEvent",0},
|
||||
{ "_wxPaletteChangedEvent","_class_wxPaletteChangedEvent",0},
|
||||
{ "_wxJoystick","_class_wxJoystick",0},
|
||||
{ "_class_wxPyBitmapDataObject","_wxPyBitmapDataObject",0},
|
||||
{ "_wxClientDC","_class_wxClientDC",0},
|
||||
{ "_wxMouseEvent","_class_wxMouseEvent",0},
|
||||
@ -8671,6 +8674,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_signed_short","_short",0},
|
||||
{ "_wxMemoryDC","_class_wxMemoryDC",0},
|
||||
{ "_wxPyTextDataObject","_class_wxPyTextDataObject",0},
|
||||
{ "_class_wxTaskBarIcon","_wxTaskBarIcon",0},
|
||||
{ "_class_wxPrintDialog","_wxPrintDialog",0},
|
||||
{ "_wxPyFileSystemHandler","_class_wxPyFileSystemHandler",0},
|
||||
{ "_wxPaintDC","_class_wxPaintDC",0},
|
||||
@ -8680,7 +8684,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxStatusBar","_class_wxStatusBar",0},
|
||||
{ "_class_wxAcceleratorEntry","_wxAcceleratorEntry",0},
|
||||
{ "_class_wxCursor","_wxCursor",0},
|
||||
{ "_wxPostScriptDC","_class_wxPostScriptDC",0},
|
||||
{ "_wxPyFileDropTarget","_class_wxPyFileDropTarget",0},
|
||||
{ "_class_wxPyProcess","_wxPyProcess",0},
|
||||
{ "_class_wxImageHandler","_wxImageHandler",0},
|
||||
@ -8689,6 +8692,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxLog","_wxLog",0},
|
||||
{ "_wxTreeItemId","_class_wxTreeItemId",0},
|
||||
{ "_unsigned_char","_byte",0},
|
||||
{ "_class_wxMetaFileDC","_wxMetaFileDC",0},
|
||||
{ "_class_wxMenu","_wxMenu",0},
|
||||
{ "_wxControl","_class_wxControl",0},
|
||||
{ "_class_wxListBox","_wxListBox",0},
|
||||
@ -8779,6 +8783,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxLogGui","_wxLogGui",0},
|
||||
{ "_class_wxMDIParentFrame","_wxMDIParentFrame",0},
|
||||
{ "_wxPyTreeItemData","_class_wxPyTreeItemData",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_wxStaticBoxSizer","_class_wxStaticBoxSizer",0},
|
||||
{ "_class_wxTimeSpan","_wxTimeSpan",0},
|
||||
{ "_class_wxPyFileSystemHandler","_wxPyFileSystemHandler",0},
|
||||
@ -8834,6 +8839,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxGauge","_class_wxGauge",0},
|
||||
{ "_class_wxCheckListBox","_wxCheckListBox",0},
|
||||
{ "_class_wxBusyInfo","_wxBusyInfo",0},
|
||||
{ "_class_wxJoystick","_wxJoystick",0},
|
||||
{ "_class_wxCommandEvent","_wxCommandEvent",0},
|
||||
{ "_class_wxClientDC","_wxClientDC",0},
|
||||
{ "_class_wxSizeEvent","_wxSizeEvent",0},
|
||||
|
@ -2107,6 +2107,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxPNMHandler","_class_wxPNMHandler",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_wxLogGui","_class_wxLogGui",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxPyShapeEvtHandler","_wxPyShapeEvtHandler",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -2114,7 +2115,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxStatusBar","_wxStatusBar",0},
|
||||
{ "_class_wxGIFHandler","_wxGIFHandler",0},
|
||||
{ "_class_wxPySizer","_wxPySizer",0},
|
||||
{ "_class_wxPostScriptDC","_wxPostScriptDC",0},
|
||||
{ "_wxPanel","_class_wxPyShapeCanvas",SwigwxPyShapeCanvasTowxPanel},
|
||||
{ "_wxPanel","_wxPyShapeCanvas",SwigwxPyShapeCanvasTowxPanel},
|
||||
{ "_wxPanel","_class_wxPanel",0},
|
||||
@ -2180,6 +2180,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxZipFSHandler","_wxZipFSHandler",0},
|
||||
{ "_char","_wxChar",0},
|
||||
{ "_wxBitmap","_class_wxBitmap",0},
|
||||
{ "_wxTaskBarIcon","_class_wxTaskBarIcon",0},
|
||||
{ "_wxPrintDialog","_class_wxPrintDialog",0},
|
||||
{ "_wxWindowDC","_class_wxWindowDC",0},
|
||||
{ "_wxTimerEvent","_class_wxTimerEvent",0},
|
||||
@ -2267,6 +2268,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxTextCtrl","_wxTextCtrl",0},
|
||||
{ "_class_wxListItemAttr","_wxListItemAttr",0},
|
||||
{ "_wxLayoutConstraints","_class_wxLayoutConstraints",0},
|
||||
{ "_wxMetaFileDC","_class_wxMetaFileDC",0},
|
||||
{ "_class_wxTextDataObject","_wxTextDataObject",0},
|
||||
{ "_wxMenu","_class_wxMenu",0},
|
||||
{ "_class_wxMoveEvent","_wxMoveEvent",0},
|
||||
@ -2303,6 +2305,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxBusyInfo","_class_wxBusyInfo",0},
|
||||
{ "_class_wxMenuEvent","_wxMenuEvent",0},
|
||||
{ "_wxPaletteChangedEvent","_class_wxPaletteChangedEvent",0},
|
||||
{ "_wxJoystick","_class_wxJoystick",0},
|
||||
{ "_class_wxPyBitmapDataObject","_wxPyBitmapDataObject",0},
|
||||
{ "_wxClientDC","_class_wxClientDC",0},
|
||||
{ "_wxMouseEvent","_class_wxMouseEvent",0},
|
||||
@ -2318,6 +2321,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_signed_short","_short",0},
|
||||
{ "_wxMemoryDC","_class_wxMemoryDC",0},
|
||||
{ "_wxPyTextDataObject","_class_wxPyTextDataObject",0},
|
||||
{ "_class_wxTaskBarIcon","_wxTaskBarIcon",0},
|
||||
{ "_class_wxPrintDialog","_wxPrintDialog",0},
|
||||
{ "_wxPyFileSystemHandler","_class_wxPyFileSystemHandler",0},
|
||||
{ "_wxPaintDC","_class_wxPaintDC",0},
|
||||
@ -2327,7 +2331,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxStatusBar","_class_wxStatusBar",0},
|
||||
{ "_class_wxAcceleratorEntry","_wxAcceleratorEntry",0},
|
||||
{ "_class_wxCursor","_wxCursor",0},
|
||||
{ "_wxPostScriptDC","_class_wxPostScriptDC",0},
|
||||
{ "_wxPyFileDropTarget","_class_wxPyFileDropTarget",0},
|
||||
{ "_class_wxPyProcess","_wxPyProcess",0},
|
||||
{ "_class_wxImageHandler","_wxImageHandler",0},
|
||||
@ -2338,6 +2341,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxLog","_wxLog",0},
|
||||
{ "_wxTreeItemId","_class_wxTreeItemId",0},
|
||||
{ "_unsigned_char","_byte",0},
|
||||
{ "_class_wxMetaFileDC","_wxMetaFileDC",0},
|
||||
{ "_class_wxMenu","_wxMenu",0},
|
||||
{ "_wxControl","_class_wxControl",0},
|
||||
{ "_class_wxListBox","_wxListBox",0},
|
||||
@ -2428,6 +2432,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxLogGui","_wxLogGui",0},
|
||||
{ "_class_wxMDIParentFrame","_wxMDIParentFrame",0},
|
||||
{ "_wxPyTreeItemData","_class_wxPyTreeItemData",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_wxStaticBoxSizer","_class_wxStaticBoxSizer",0},
|
||||
{ "_class_wxTimeSpan","_wxTimeSpan",0},
|
||||
{ "_class_wxPyFileSystemHandler","_wxPyFileSystemHandler",0},
|
||||
@ -2484,6 +2489,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxGauge","_class_wxGauge",0},
|
||||
{ "_class_wxCheckListBox","_wxCheckListBox",0},
|
||||
{ "_class_wxBusyInfo","_wxBusyInfo",0},
|
||||
{ "_class_wxJoystick","_wxJoystick",0},
|
||||
{ "_class_wxCommandEvent","_wxCommandEvent",0},
|
||||
{ "_class_wxClientDC","_wxClientDC",0},
|
||||
{ "_class_wxSizeEvent","_wxSizeEvent",0},
|
||||
|
@ -12663,6 +12663,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxPNMHandler","_class_wxPNMHandler",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_wxLogGui","_class_wxLogGui",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxPyShapeEvtHandler","_class_wxPyDivisionShape",SwigwxPyDivisionShapeTowxPyShapeEvtHandler},
|
||||
{ "_class_wxPyShapeEvtHandler","_wxPyDivisionShape",SwigwxPyDivisionShapeTowxPyShapeEvtHandler},
|
||||
{ "_class_wxPyShapeEvtHandler","_class_wxPyDividedShape",SwigwxPyDividedShapeTowxPyShapeEvtHandler},
|
||||
@ -12687,7 +12688,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxPyCompositeShape","_class_wxPyDivisionShape",SwigwxPyDivisionShapeTowxPyCompositeShape},
|
||||
{ "_class_wxPyCompositeShape","_wxPyDivisionShape",SwigwxPyDivisionShapeTowxPyCompositeShape},
|
||||
{ "_class_wxPyCompositeShape","_wxPyCompositeShape",0},
|
||||
{ "_class_wxPostScriptDC","_wxPostScriptDC",0},
|
||||
{ "_wxPanel","_class_wxPanel",0},
|
||||
{ "_wxInitDialogEvent","_class_wxInitDialogEvent",0},
|
||||
{ "_wxCheckBox","_class_wxCheckBox",0},
|
||||
@ -12752,6 +12752,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxZipFSHandler","_wxZipFSHandler",0},
|
||||
{ "_char","_wxChar",0},
|
||||
{ "_wxBitmap","_class_wxBitmap",0},
|
||||
{ "_wxTaskBarIcon","_class_wxTaskBarIcon",0},
|
||||
{ "_wxPrintDialog","_class_wxPrintDialog",0},
|
||||
{ "_wxPyControlPoint","_class_wxPyControlPoint",0},
|
||||
{ "_wxWindowDC","_class_wxWindowDC",0},
|
||||
@ -12839,6 +12840,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxTextCtrl","_wxTextCtrl",0},
|
||||
{ "_class_wxListItemAttr","_wxListItemAttr",0},
|
||||
{ "_wxLayoutConstraints","_class_wxLayoutConstraints",0},
|
||||
{ "_wxMetaFileDC","_class_wxMetaFileDC",0},
|
||||
{ "_class_wxTextDataObject","_wxTextDataObject",0},
|
||||
{ "_wxMenu","_class_wxMenu",0},
|
||||
{ "_class_wxMoveEvent","_wxMoveEvent",0},
|
||||
@ -12873,6 +12875,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxBusyInfo","_class_wxBusyInfo",0},
|
||||
{ "_class_wxMenuEvent","_wxMenuEvent",0},
|
||||
{ "_wxPaletteChangedEvent","_class_wxPaletteChangedEvent",0},
|
||||
{ "_wxJoystick","_class_wxJoystick",0},
|
||||
{ "_class_wxPyBitmapDataObject","_wxPyBitmapDataObject",0},
|
||||
{ "_wxClientDC","_class_wxClientDC",0},
|
||||
{ "_wxMouseEvent","_class_wxMouseEvent",0},
|
||||
@ -12889,6 +12892,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_signed_short","_short",0},
|
||||
{ "_wxMemoryDC","_class_wxMemoryDC",0},
|
||||
{ "_wxPyTextDataObject","_class_wxPyTextDataObject",0},
|
||||
{ "_class_wxTaskBarIcon","_wxTaskBarIcon",0},
|
||||
{ "_class_wxPrintDialog","_wxPrintDialog",0},
|
||||
{ "_wxPyFileSystemHandler","_class_wxPyFileSystemHandler",0},
|
||||
{ "_class_wxPyControlPoint","_wxPyControlPoint",0},
|
||||
@ -12899,7 +12903,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxStatusBar","_class_wxStatusBar",0},
|
||||
{ "_class_wxAcceleratorEntry","_wxAcceleratorEntry",0},
|
||||
{ "_class_wxCursor","_wxCursor",0},
|
||||
{ "_wxPostScriptDC","_class_wxPostScriptDC",0},
|
||||
{ "_wxPyFileDropTarget","_class_wxPyFileDropTarget",0},
|
||||
{ "_class_wxPyProcess","_wxPyProcess",0},
|
||||
{ "_class_wxImageHandler","_wxImageHandler",0},
|
||||
@ -12922,6 +12925,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxLog","_wxLog",0},
|
||||
{ "_wxTreeItemId","_class_wxTreeItemId",0},
|
||||
{ "_unsigned_char","_byte",0},
|
||||
{ "_class_wxMetaFileDC","_wxMetaFileDC",0},
|
||||
{ "_class_wxMenu","_wxMenu",0},
|
||||
{ "_wxControl","_class_wxControl",0},
|
||||
{ "_class_wxListBox","_wxListBox",0},
|
||||
@ -13013,6 +13017,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxLogGui","_wxLogGui",0},
|
||||
{ "_class_wxMDIParentFrame","_wxMDIParentFrame",0},
|
||||
{ "_wxPyTreeItemData","_class_wxPyTreeItemData",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_wxStaticBoxSizer","_class_wxStaticBoxSizer",0},
|
||||
{ "_class_wxTimeSpan","_wxTimeSpan",0},
|
||||
{ "_class_wxPyFileSystemHandler","_wxPyFileSystemHandler",0},
|
||||
@ -13083,6 +13088,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxGauge","_class_wxGauge",0},
|
||||
{ "_class_wxCheckListBox","_wxCheckListBox",0},
|
||||
{ "_class_wxBusyInfo","_wxBusyInfo",0},
|
||||
{ "_class_wxJoystick","_wxJoystick",0},
|
||||
{ "_class_wxCommandEvent","_wxCommandEvent",0},
|
||||
{ "_class_wxClientDC","_wxClientDC",0},
|
||||
{ "_class_wxSizeEvent","_wxSizeEvent",0},
|
||||
|
@ -8004,6 +8004,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxPNMHandler","_class_wxPNMHandler",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_wxLogGui","_class_wxLogGui",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxPyShapeEvtHandler","_class_wxPyTextShape",SwigwxPyTextShapeTowxPyShapeEvtHandler},
|
||||
{ "_class_wxPyShapeEvtHandler","_wxPyTextShape",SwigwxPyTextShapeTowxPyShapeEvtHandler},
|
||||
{ "_class_wxPyShapeEvtHandler","_class_wxPyPolygonShape",SwigwxPyPolygonShapeTowxPyShapeEvtHandler},
|
||||
@ -8023,7 +8024,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxPySizer","_wxPySizer",0},
|
||||
{ "_class_wxPyCompositeShape","_wxPyCompositeShape",0},
|
||||
{ "_wxPyPolygonShape","_class_wxPyPolygonShape",0},
|
||||
{ "_class_wxPostScriptDC","_wxPostScriptDC",0},
|
||||
{ "_wxPanel","_class_wxPanel",0},
|
||||
{ "_wxInitDialogEvent","_class_wxInitDialogEvent",0},
|
||||
{ "_wxCheckBox","_class_wxCheckBox",0},
|
||||
@ -8088,6 +8088,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxZipFSHandler","_wxZipFSHandler",0},
|
||||
{ "_char","_wxChar",0},
|
||||
{ "_wxBitmap","_class_wxBitmap",0},
|
||||
{ "_wxTaskBarIcon","_class_wxTaskBarIcon",0},
|
||||
{ "_wxPrintDialog","_class_wxPrintDialog",0},
|
||||
{ "_wxPyControlPoint","_class_wxPyControlPoint",0},
|
||||
{ "_wxWindowDC","_class_wxWindowDC",0},
|
||||
@ -8178,6 +8179,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxTextCtrl","_wxTextCtrl",0},
|
||||
{ "_class_wxListItemAttr","_wxListItemAttr",0},
|
||||
{ "_wxLayoutConstraints","_class_wxLayoutConstraints",0},
|
||||
{ "_wxMetaFileDC","_class_wxMetaFileDC",0},
|
||||
{ "_class_wxTextDataObject","_wxTextDataObject",0},
|
||||
{ "_wxMenu","_class_wxMenu",0},
|
||||
{ "_class_wxMoveEvent","_wxMoveEvent",0},
|
||||
@ -8213,6 +8215,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxBusyInfo","_class_wxBusyInfo",0},
|
||||
{ "_class_wxMenuEvent","_wxMenuEvent",0},
|
||||
{ "_wxPaletteChangedEvent","_class_wxPaletteChangedEvent",0},
|
||||
{ "_wxJoystick","_class_wxJoystick",0},
|
||||
{ "_class_wxPyBitmapDataObject","_wxPyBitmapDataObject",0},
|
||||
{ "_class_wxPyCircleShape","_wxPyCircleShape",0},
|
||||
{ "_wxClientDC","_class_wxClientDC",0},
|
||||
@ -8230,6 +8233,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_signed_short","_short",0},
|
||||
{ "_wxMemoryDC","_class_wxMemoryDC",0},
|
||||
{ "_wxPyTextDataObject","_class_wxPyTextDataObject",0},
|
||||
{ "_class_wxTaskBarIcon","_wxTaskBarIcon",0},
|
||||
{ "_class_wxPrintDialog","_wxPrintDialog",0},
|
||||
{ "_wxPyFileSystemHandler","_class_wxPyFileSystemHandler",0},
|
||||
{ "_class_wxPyControlPoint","_wxPyControlPoint",0},
|
||||
@ -8240,7 +8244,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxStatusBar","_class_wxStatusBar",0},
|
||||
{ "_class_wxAcceleratorEntry","_wxAcceleratorEntry",0},
|
||||
{ "_class_wxCursor","_wxCursor",0},
|
||||
{ "_wxPostScriptDC","_class_wxPostScriptDC",0},
|
||||
{ "_wxPyFileDropTarget","_class_wxPyFileDropTarget",0},
|
||||
{ "_class_wxPyProcess","_wxPyProcess",0},
|
||||
{ "_class_wxImageHandler","_wxImageHandler",0},
|
||||
@ -8259,6 +8262,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxLog","_wxLog",0},
|
||||
{ "_wxTreeItemId","_class_wxTreeItemId",0},
|
||||
{ "_unsigned_char","_byte",0},
|
||||
{ "_class_wxMetaFileDC","_wxMetaFileDC",0},
|
||||
{ "_class_wxMenu","_wxMenu",0},
|
||||
{ "_wxControl","_class_wxControl",0},
|
||||
{ "_class_wxListBox","_wxListBox",0},
|
||||
@ -8351,6 +8355,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxLogGui","_wxLogGui",0},
|
||||
{ "_class_wxMDIParentFrame","_wxMDIParentFrame",0},
|
||||
{ "_wxPyTreeItemData","_class_wxPyTreeItemData",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_wxStaticBoxSizer","_class_wxStaticBoxSizer",0},
|
||||
{ "_class_wxTimeSpan","_wxTimeSpan",0},
|
||||
{ "_class_wxPyFileSystemHandler","_wxPyFileSystemHandler",0},
|
||||
@ -8418,6 +8423,7 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxGauge","_class_wxGauge",0},
|
||||
{ "_class_wxCheckListBox","_wxCheckListBox",0},
|
||||
{ "_class_wxBusyInfo","_wxBusyInfo",0},
|
||||
{ "_class_wxJoystick","_wxJoystick",0},
|
||||
{ "_class_wxCommandEvent","_wxCommandEvent",0},
|
||||
{ "_class_wxClientDC","_wxClientDC",0},
|
||||
{ "_class_wxSizeEvent","_wxSizeEvent",0},
|
||||
|
41
wxPython/demo/FancyText.py
Normal file
41
wxPython/demo/FancyText.py
Normal file
@ -0,0 +1,41 @@
|
||||
|
||||
from wxPython.wx import *
|
||||
from wxPython.lib import fancytext
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
test_str = ('<font style="italic" family="swiss" color="red" weight="bold" >'
|
||||
'some |<sup>23</sup> <angle/>text<sub>with <angle/> subscript</sub>'
|
||||
'</font> some other text')
|
||||
|
||||
test_str2 = '<font family="swiss" color="dark green" size="40">big green text</font>'
|
||||
|
||||
|
||||
class TestPanel(wxPanel):
|
||||
def __init__(self, parent):
|
||||
wxPanel.__init__(self, parent, -1)
|
||||
EVT_PAINT(self, self.OnPaint)
|
||||
|
||||
|
||||
def OnPaint(self, evt):
|
||||
dc = wxPaintDC(self)
|
||||
|
||||
sz = fancytext.getExtent(test_str, dc)
|
||||
fancytext.renderToDC(test_str, dc, 20, 20)
|
||||
|
||||
fancytext.renderToDC(test_str2, dc, 20, 20 + sz.height + 10)
|
||||
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
def runTest(frame, nb, log):
|
||||
win = TestPanel(nb)
|
||||
return win
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
import string
|
||||
overview = string.replace(fancytext.__doc__, "<", "<")
|
||||
|
@ -1,6 +1,10 @@
|
||||
""" Demonstrate filebrowsebutton module of the wxPython.lib Library.
|
||||
|
||||
14.1.2001 Bernhard Reiter <bernhard@intevation.de>
|
||||
Added demo for DirBrowseButton and improved overview text.
|
||||
"""
|
||||
from wxPython.wx import *
|
||||
from wxPython.lib.filebrowsebutton import FileBrowseButton, FileBrowseButtonWithHistory
|
||||
from wxPython.lib.filebrowsebutton import FileBrowseButton, FileBrowseButtonWithHistory,DirBrowseButton
|
||||
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
@ -15,6 +19,9 @@ class TestPanel(wxPanel):
|
||||
wxSize(450, -1),
|
||||
#changeCallback = self.fbbhCallback
|
||||
)
|
||||
self.dbb = DirBrowseButton(self, -1, wxPoint(20,80), wxSize(450,-1),
|
||||
changeCallback = self.dbbCallback)
|
||||
|
||||
|
||||
self.fbbh.SetHistory(['You', 'can', 'put', 'some', 'file', 'names', 'here'])
|
||||
|
||||
@ -23,6 +30,7 @@ class TestPanel(wxPanel):
|
||||
self.log.write('FileBrowseButton: %s\n' % evt.GetString())
|
||||
|
||||
|
||||
|
||||
def fbbhCallback(self, evt):
|
||||
if hasattr(self, 'fbbh'):
|
||||
value = evt.GetString()
|
||||
@ -31,6 +39,10 @@ class TestPanel(wxPanel):
|
||||
history.append(value)
|
||||
self.fbbh.SetHistory(history)
|
||||
|
||||
def dbbCallback(self, evt):
|
||||
self.log.write('DirBrowseButton: %s\n' % evt.GetString())
|
||||
|
||||
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
@ -42,6 +54,23 @@ def runTest(frame, nb, log):
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
overview = """<html><body>
|
||||
<h2>class FileBrowseButton:</h2>
|
||||
<small><pre>
|
||||
%s
|
||||
</pre></small>
|
||||
|
||||
<h2>class FileBrowseButtonWithHistory(FileBrowseButton):</h2>
|
||||
<small><pre>
|
||||
%s
|
||||
</pre></small>
|
||||
|
||||
overview = FileBrowseButton.__doc__
|
||||
<h2>class DirBrowseButton(FileBrowseButton):</h2>
|
||||
<small><pre>
|
||||
%s
|
||||
</pre></small>
|
||||
|
||||
</body><</html>
|
||||
""" % ( FileBrowseButton.__doc__,
|
||||
FileBrowseButtonWithHistory.__doc__ ,
|
||||
str(DirBrowseButton.__doc__) )
|
||||
|
140
wxPython/demo/LayoutAnchors.py
Normal file
140
wxPython/demo/LayoutAnchors.py
Normal file
@ -0,0 +1,140 @@
|
||||
|
||||
from wxPython.wx import *
|
||||
from wxPython.lib.anchors import LayoutAnchors
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
|
||||
[wxID_ANCHORSDEMOFRAMEANCHOREDPANEL, wxID_ANCHORSDEMOFRAMEHELPSTATICTEXT,
|
||||
wxID_ANCHORSDEMOFRAMEMAINPANEL, wxID_ANCHORSDEMOFRAMEBACKGROUNDPANEL,
|
||||
wxID_ANCHORSDEMOFRAMERIGHTCHECKBOX, wxID_ANCHORSDEMOFRAMEOKBUTTON,
|
||||
wxID_ANCHORSDEMOFRAMETOPCHECKBOX, wxID_ANCHORSDEMOFRAMEBOTTOMCHECKBOX,
|
||||
wxID_ANCHORSDEMOFRAME, wxID_ANCHORSDEMOFRAMELEFTCHECKBOX,
|
||||
] = map(lambda _init_ctrls: wxNewId(), range(10))
|
||||
|
||||
class AnchorsDemoFrame(wxFrame):
|
||||
def _init_utils(self):
|
||||
pass
|
||||
|
||||
def _init_ctrls(self, prnt):
|
||||
wxFrame.__init__(self, size = wxSize(328, 187), id = wxID_ANCHORSDEMOFRAME, title = 'LayoutAnchors Demonstration', parent = prnt, name = 'AnchorsDemoFrame', style = wxDEFAULT_FRAME_STYLE | wxCLIP_CHILDREN, pos = wxPoint(261, 123))
|
||||
self._init_utils()
|
||||
|
||||
self.mainPanel = wxPanel(size = wxSize(320, 160), parent = self, id = wxID_ANCHORSDEMOFRAMEMAINPANEL, name = 'panel1', style = wxTAB_TRAVERSAL | wxCLIP_CHILDREN, pos = wxPoint(0, 0))
|
||||
self.mainPanel.SetAutoLayout(true)
|
||||
|
||||
self.okButton = wxButton(label = 'OK', id = wxID_ANCHORSDEMOFRAMEOKBUTTON, parent = self.mainPanel, name = 'okButton', size = wxSize(72, 24), style = 0, pos = wxPoint(240, 128))
|
||||
self.okButton.SetConstraints(LayoutAnchors(self.okButton, false, false, true, true))
|
||||
EVT_BUTTON(self.okButton, wxID_ANCHORSDEMOFRAMEOKBUTTON, self.OnOkButtonButton)
|
||||
|
||||
self.backgroundPanel = wxPanel(size = wxSize(304, 80), parent = self.mainPanel, id = wxID_ANCHORSDEMOFRAMEBACKGROUNDPANEL, name = 'backgroundPanel', style = wxSIMPLE_BORDER | wxCLIP_CHILDREN, pos = wxPoint(8, 40))
|
||||
self.backgroundPanel.SetBackgroundColour(wxColour(255, 255, 255))
|
||||
self.backgroundPanel.SetConstraints(LayoutAnchors(self.backgroundPanel, true, true, true, true))
|
||||
|
||||
self.anchoredPanel = wxPanel(size = wxSize(88, 48), id = wxID_ANCHORSDEMOFRAMEANCHOREDPANEL, parent = self.backgroundPanel, name = 'anchoredPanel', style = wxSIMPLE_BORDER, pos = wxPoint(104, 16))
|
||||
self.anchoredPanel.SetBackgroundColour(wxColour(0, 0, 222))
|
||||
self.anchoredPanel.SetConstraints(LayoutAnchors(self.anchoredPanel, false, false, false, false))
|
||||
|
||||
self.leftCheckBox = wxCheckBox(label = 'Left', id = wxID_ANCHORSDEMOFRAMELEFTCHECKBOX, parent = self.mainPanel, name = 'leftCheckBox', size = wxSize(40, 16), style = 0, pos = wxPoint(8, 8))
|
||||
self.leftCheckBox.SetConstraints(LayoutAnchors(self.leftCheckBox, false, true, false, false))
|
||||
EVT_CHECKBOX(self.leftCheckBox, wxID_ANCHORSDEMOFRAMELEFTCHECKBOX, self.OnCheckboxCheckbox)
|
||||
|
||||
self.topCheckBox = wxCheckBox(label = 'Top', id = wxID_ANCHORSDEMOFRAMETOPCHECKBOX, parent = self.mainPanel, name = 'topCheckBox', size = wxSize(40, 16), style = 0, pos = wxPoint(88, 8))
|
||||
self.topCheckBox.SetConstraints(LayoutAnchors(self.topCheckBox, false, true, false, false))
|
||||
EVT_CHECKBOX(self.topCheckBox, wxID_ANCHORSDEMOFRAMETOPCHECKBOX, self.OnCheckboxCheckbox)
|
||||
|
||||
self.rightCheckBox = wxCheckBox(label = 'Right', id = wxID_ANCHORSDEMOFRAMERIGHTCHECKBOX, parent = self.mainPanel, name = 'rightCheckBox', size = wxSize(48, 16), style = 0, pos = wxPoint(168, 8))
|
||||
self.rightCheckBox.SetConstraints(LayoutAnchors(self.rightCheckBox, false, true, false, false))
|
||||
EVT_CHECKBOX(self.rightCheckBox, wxID_ANCHORSDEMOFRAMERIGHTCHECKBOX, self.OnCheckboxCheckbox)
|
||||
|
||||
self.bottomCheckBox = wxCheckBox(label = 'Bottom', id = wxID_ANCHORSDEMOFRAMEBOTTOMCHECKBOX, parent = self.mainPanel, name = 'bottomCheckBox', size = wxSize(56, 16), style = 0, pos = wxPoint(248, 8))
|
||||
self.bottomCheckBox.SetConstraints(LayoutAnchors(self.bottomCheckBox, false, true, false, false))
|
||||
EVT_CHECKBOX(self.bottomCheckBox, wxID_ANCHORSDEMOFRAMEBOTTOMCHECKBOX, self.OnCheckboxCheckbox)
|
||||
|
||||
self.helpStaticText = wxStaticText(label = 'Select anchor options above, then resize window to see the effect', id = wxID_ANCHORSDEMOFRAMEHELPSTATICTEXT, parent = self.mainPanel, name = 'helpStaticText', size = wxSize(224, 24), style = wxST_NO_AUTORESIZE, pos = wxPoint(8, 128))
|
||||
self.helpStaticText.SetConstraints(LayoutAnchors(self.helpStaticText, true, false, true, true))
|
||||
|
||||
def __init__(self, parent):
|
||||
self._init_ctrls(parent)
|
||||
|
||||
def OnCheckboxCheckbox(self, event):
|
||||
self.anchoredPanel.SetConstraints(
|
||||
LayoutAnchors(self.anchoredPanel,
|
||||
self.leftCheckBox.GetValue(), self.topCheckBox.GetValue(),
|
||||
self.rightCheckBox.GetValue(), self.bottomCheckBox.GetValue()) )
|
||||
|
||||
def OnOkButtonButton(self, event):
|
||||
self.Close()
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
def runTest(frame, nb, log):
|
||||
win = AnchorsDemoFrame(frame)
|
||||
frame.otherWin = win
|
||||
win.Show(true)
|
||||
|
||||
|
||||
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
|
||||
overview = """<html><body>
|
||||
<h2>LayoutAnchors</h2>
|
||||
A class that implements Delphi's Anchors with wxLayoutConstraints.
|
||||
<p>
|
||||
Anchored sides maintain the distance from the edge of the
|
||||
control to the same edge of the parent.
|
||||
When neither side is selected, the control keeps the same
|
||||
relative position to both sides.
|
||||
<p>
|
||||
The current position and size of the control and it's parent
|
||||
is used when setting up the constraints. To change the size or
|
||||
position of an already anchored control, set the constraints to
|
||||
None, reposition or resize and reapply the anchors.
|
||||
<p>
|
||||
Examples:
|
||||
<p>
|
||||
Let's anchor the right and bottom edge of a control and
|
||||
resize it's parent.
|
||||
<p>
|
||||
<pre>
|
||||
ctrl.SetConstraints(LayoutAnchors(ctrl, left=0, top=0, right=1, bottom=1))
|
||||
|
||||
+=========+ +===================+
|
||||
| +-----+ | | |
|
||||
| | * | -> | |
|
||||
| +--*--+ | | +-----+ |
|
||||
+---------+ | | * |
|
||||
| +--*--+ |
|
||||
+-------------------+
|
||||
* = anchored edge
|
||||
</pre>
|
||||
<p>
|
||||
When anchored on both sides the control will stretch horizontally.
|
||||
<p>
|
||||
<pre>
|
||||
ctrl.SetConstraints(LayoutAnchors(ctrl, 1, 0, 1, 1))
|
||||
|
||||
+=========+ +===================+
|
||||
| +-----+ | | |
|
||||
| * * | -> | |
|
||||
| +--*--+ | | +---------------+ |
|
||||
+---------+ | * ctrl * |
|
||||
| +-------*-------+ |
|
||||
+-------------------+
|
||||
* = anchored edge
|
||||
</pre>
|
||||
</html></body>
|
||||
"""
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
@ -20,7 +20,7 @@ from wxPython.html import wxHtmlWindow
|
||||
|
||||
|
||||
_treeList = [
|
||||
('New since last release', ['wxProcess',
|
||||
('New since last release', ['LayoutAnchors', "FancyText",
|
||||
]),
|
||||
|
||||
('Managed Windows', ['wxFrame', 'wxDialog', 'wxMiniFrame']),
|
||||
@ -43,14 +43,14 @@ _treeList = [
|
||||
'wxCalendarCtrl',
|
||||
]),
|
||||
|
||||
('Window Layout', ['wxLayoutConstraints', 'Sizers', ]),
|
||||
('Window Layout', ['wxLayoutConstraints', 'LayoutAnchors', 'Sizers', ]),
|
||||
|
||||
('Miscellaneous', [ 'DragAndDrop', 'CustomDragAndDrop', 'FontEnumerator',
|
||||
'wxTimer', 'wxValidator', 'wxGLCanvas', 'DialogUnits',
|
||||
'wxImage', 'wxMask', 'PrintFramework', 'wxOGL',
|
||||
'PythonEvents', 'Threads',
|
||||
'ActiveXWrapper_Acrobat', 'ActiveXWrapper_IE',
|
||||
'wxDragImage',
|
||||
'wxDragImage', "wxProcess", "FancyText",
|
||||
]),
|
||||
|
||||
('wxPython Library', ['Layoutf', 'wxScrolledMessageDialog',
|
||||
|
BIN
wxPython/demo/bitmaps/robin.jpg
Normal file
BIN
wxPython/demo/bitmaps/robin.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 4.7 KiB |
Binary file not shown.
Before Width: | Height: | Size: 12 KiB After Width: | Height: | Size: 12 KiB |
BIN
wxPython/demo/data/pic2.gif
Normal file
BIN
wxPython/demo/data/pic2.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 9.0 KiB |
@ -57,6 +57,10 @@ display some tiny nice image</TT>, he?</FONT>
|
||||
this is text......
|
||||
<BR><A HREF="pic.png"><IMG SRC="pic.png" ALT="Testing image image" HEIGHT=160 WIDTH=100 ALIGN=TEXTTOP></A> (try clicking on the image :-) and
|
||||
this is text......
|
||||
|
||||
<br>
|
||||
Here is a GIF: <IMG SRC="pic2.gif">
|
||||
|
||||
<BR>
|
||||
<BR>
|
||||
<UL>
|
||||
|
@ -15,8 +15,8 @@ class TestChoice(wxPanel):
|
||||
wxPoint(15, 10))
|
||||
|
||||
wxStaticText(self, -1, "Select one:", wxPoint(15, 50), wxSize(75, 20))
|
||||
wxChoice(self, 40, wxPoint(80, 50), wxSize(95, 20), #wxDefaultSize,
|
||||
sampleList)
|
||||
wxChoice(self, 40, (80, 50), (95, 125),
|
||||
choices = sampleList)
|
||||
EVT_CHOICE(self, 40, self.EvtChoice)
|
||||
|
||||
def EvtChoice(self, event):
|
||||
|
@ -4,9 +4,8 @@ from wxPython.wx import *
|
||||
#---------------------------------------------------------------------------
|
||||
|
||||
def runTest(frame, nb, log):
|
||||
data = wxColourData()
|
||||
data.SetChooseFull(true)
|
||||
dlg = wxColourDialog(frame, data)
|
||||
dlg = wxColourDialog(frame)
|
||||
dlg.GetColourData().SetChooseFull(true)
|
||||
if dlg.ShowModal() == wxID_OK:
|
||||
data = dlg.GetColourData()
|
||||
log.WriteText('You selected: %s\n' % str(data.GetColour().Get()))
|
||||
|
@ -66,7 +66,7 @@ class TestListBox(wxPanel):
|
||||
EVT_LISTBOX(self, 60, self.EvtListBox)
|
||||
EVT_LISTBOX_DCLICK(self, 60, self.EvtListBoxDClick)
|
||||
EVT_RIGHT_UP(self.lb1, self.EvtRightButton)
|
||||
self.lb1.SetSelection(0)
|
||||
self.lb1.SetSelection(3)
|
||||
|
||||
|
||||
wxStaticText(self, -1, "Select many:", wxPoint(200, 50), wxSize(65, 18))
|
||||
|
@ -15,7 +15,7 @@ class TestSashWindow(wxPanel):
|
||||
|
||||
self.log = log
|
||||
|
||||
# will accupy the space not uised by the Layout Algorithm
|
||||
# will occupy the space not used by the Layout Algorithm
|
||||
self.remainingSpace = wxPanel(self, -1, style=wxSUNKEN_BORDER)
|
||||
|
||||
EVT_SASH_DRAGGED_RANGE(self, self.ID_WINDOW_TOP,
|
||||
|
@ -14,10 +14,16 @@ class TestPanel(wxPanel):
|
||||
wxStaticText(self, -1, "This is a wxStaticBitmap.", wxPoint(45, 15))
|
||||
|
||||
bmp = wxBitmap('bitmaps/test2.bmp', wxBITMAP_TYPE_BMP)
|
||||
mask = wxMaskColour(bmp, wxBLUE)
|
||||
bmp.SetMask(mask)
|
||||
wxStaticBitmap(self, -1, bmp, wxPoint(80, 50),
|
||||
wxSize(bmp.GetWidth(), bmp.GetHeight()))
|
||||
|
||||
bmp = wxBitmap('bitmaps/robin.jpg', wxBITMAP_TYPE_JPEG)
|
||||
wxStaticBitmap(self, -1, bmp, (80, 150))
|
||||
|
||||
wxStaticText(self, -1, "Hey, if Ousterhout can do it, so can I.",
|
||||
(200, 175))
|
||||
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
@ -26,25 +26,5 @@ def runTest(frame, nb, log):
|
||||
|
||||
|
||||
overview = """\
|
||||
This class represents a dialog that requests a one-line text string from the user. It is implemented as a generic wxWindows dialog.
|
||||
|
||||
wxTextEntryDialog()
|
||||
----------------------------------
|
||||
|
||||
wxTextEntryDialog(wxWindow* parent, const wxString& message, const wxString& caption = "Please enter text", const wxString& defaultValue = "", long style = wxOK | wxCANCEL | wxCENTRE, const wxPoint& pos = wxDefaultPosition)
|
||||
|
||||
Constructor. Use wxTextEntryDialog::ShowModal to show the dialog.
|
||||
|
||||
Parameters
|
||||
-------------------
|
||||
|
||||
parent = Parent window.
|
||||
|
||||
message = Message to show on the dialog.
|
||||
|
||||
defaultValue = The default value, which may be the empty string.
|
||||
|
||||
style = A dialog style, specifying the buttons (wxOK, wxCANCEL) and an optional wxCENTRE style.
|
||||
|
||||
pos = Dialog position.
|
||||
"""
|
||||
|
@ -13,7 +13,7 @@ class TestToolBar(wxFrame):
|
||||
|
||||
wxWindow(self, -1).SetBackgroundColour(wxNamedColour("WHITE"))
|
||||
|
||||
tb = self.CreateToolBar(wxTB_HORIZONTAL|wxNO_BORDER) #|wxTB_FLAT)
|
||||
tb = self.CreateToolBar(wxTB_HORIZONTAL|wxNO_BORDER|wxTB_FLAT)
|
||||
#tb = wxToolBarSimple(self, -1, wxDefaultPosition, wxDefaultSize,
|
||||
# wxTB_HORIZONTAL | wxNO_BORDER | wxTB_FLAT)
|
||||
#self.SetToolBar(tb)
|
||||
|
Binary file not shown.
@ -1,7 +1,7 @@
|
||||
Document Type: WSE
|
||||
item: Global
|
||||
Version=6.01
|
||||
Title=wxPython 2.3 Installation
|
||||
Title=wxPython 2.2 Installation
|
||||
Flags=10010111
|
||||
Languages=65 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
|
||||
Japanese Font Name=MS Gothic
|
||||
@ -17,7 +17,7 @@ item: Global
|
||||
Patch Flags=0000000000001001
|
||||
Patch Threshold=85
|
||||
Patch Memory=4000
|
||||
EXE Filename=wxPython-2.3b1.exe
|
||||
EXE Filename=wxPython-2.2.5-PyXX.exe
|
||||
FTP Cluster Size=20
|
||||
Per-User Version ID=1
|
||||
Dialogs Version=6
|
||||
@ -55,12 +55,12 @@ item: End Block
|
||||
end
|
||||
item: Set Variable
|
||||
Variable=APPTITLE
|
||||
Value=wxPython 2.3
|
||||
Value=wxPython 2.2
|
||||
Flags=10000000
|
||||
end
|
||||
item: Set Variable
|
||||
Variable=GROUP
|
||||
Value=wxPython 2.3
|
||||
Value=wxPython 2.2
|
||||
Flags=10000000
|
||||
end
|
||||
item: Set Variable
|
||||
@ -72,17 +72,17 @@ item: Set Variable
|
||||
Value=wxPython
|
||||
Flags=10000000
|
||||
end
|
||||
item: Check Configuration
|
||||
Flags=10111011
|
||||
end
|
||||
item: Remark
|
||||
end
|
||||
item: Set Variable
|
||||
Variable=PYTHONVER
|
||||
Value=2.0
|
||||
Value=1.5
|
||||
end
|
||||
item: Remark
|
||||
end
|
||||
item: Check Configuration
|
||||
Flags=10111011
|
||||
end
|
||||
item: Get Registry Key Value
|
||||
Variable=PYTHONDIR
|
||||
Key=SOFTWARE\Python\PythonCore\%PYTHONVER%\InstallPath
|
||||
@ -814,8 +814,8 @@ item: Install File
|
||||
Flags=0000001010000011
|
||||
end
|
||||
item: Install File
|
||||
Source=c:\projects\wx\lib\wx23_0.dll
|
||||
Destination=%MAINDIR%\wxPython\wx23_0.dll
|
||||
Source=c:\projects\wx\lib\wx22_5.dll
|
||||
Destination=%MAINDIR%\wxPython\wx22_5.dll
|
||||
Flags=0000000010010010
|
||||
end
|
||||
item: Install File
|
||||
@ -909,7 +909,7 @@ item: Install File
|
||||
Flags=0000000010000010
|
||||
end
|
||||
item: Install File
|
||||
Source=c:\Projects\wx\wxPython\demo\data\*.htm
|
||||
Source=c:\Projects\wx\wxPython\demo\data\*.html
|
||||
Destination=%MAINDIR%\wxPython\demo\data
|
||||
Description=Demos
|
||||
Flags=0000000010000010
|
||||
@ -965,7 +965,7 @@ item: Install File
|
||||
Flags=0000000010000010
|
||||
end
|
||||
item: Install File
|
||||
Source=c:\PROJECTS\wx\docs\html\ogl\ogl.chm
|
||||
Source=c:\PROJECTS\wx\docs\htmlhelp\ogl.chm
|
||||
Destination=%MAINDIR%\wxPython\docs\ogl.chm
|
||||
Description=wxPython documentation
|
||||
Flags=0000000010000010
|
||||
|
4
wxPython/distrib/zipall.bat
Executable file
4
wxPython/distrib/zipall.bat
Executable file
@ -0,0 +1,4 @@
|
||||
|
||||
find . | grep -v "/CVS" | grep -v "./build/" | grep -v "./distrib/" | grep -v ".pyd" | grep -v ".pdb" | grep -v "contrib/ogl/contrib" | grep -v "contrib/stc/contrib" | zip -@ wxPython.zip
|
||||
|
||||
|
@ -13,7 +13,7 @@ from my_distutils import run_swig, contrib_copy_tree
|
||||
# flags and values that affect this script
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
VERSION = "2.3b2"
|
||||
VERSION = "2.3b3"
|
||||
DESCRIPTION = "Cross platform GUI toolkit for Python"
|
||||
AUTHOR = "Robin Dunn"
|
||||
AUTHOR_EMAIL = "robin@alldunn.com"
|
||||
@ -22,7 +22,7 @@ LICENCE = "wxWindows (LGPL derivative)"
|
||||
LONG_DESCRIPTION = """\
|
||||
wxPython is a GUI toolkit for Python that is a wrapper around the
|
||||
wxWindows C++ GUI library. wxPython provides a large variety of
|
||||
window types and controls, all imlemented with a native look and
|
||||
window types and controls, all implemented with a native look and
|
||||
feel (and native runtime speed) on the platforms it is supported
|
||||
on.
|
||||
"""
|
||||
@ -32,6 +32,8 @@ BUILD_GLCANVAS = 1 # If true, build the contrib/glcanvas extension module
|
||||
BUILD_OGL = 1 # If true, build the contrib/ogl extension module
|
||||
BUILD_STC = 1 # If true, build the contrib/stc extension module
|
||||
CORE_ONLY = 0 # if true, don't build any of the above
|
||||
GL_ONLY = 0 # Only used when making the -gl RPM. See the "b" script
|
||||
# for the ugly details
|
||||
|
||||
USE_SWIG = 0 # Should we actually execute SWIG, or just use the
|
||||
# files already in the distribution?
|
||||
@ -189,120 +191,128 @@ else:
|
||||
if IN_CVS_TREE and newer('setup.py', 'src/__version__.py'):
|
||||
open('src/__version__.py', 'w').write("ver = '%s'\n" % VERSION)
|
||||
|
||||
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
# Define the CORE extension module
|
||||
# SWIG defaults
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
print 'Preparing CORE...'
|
||||
swig_force = force
|
||||
swig_args = ['-c++', '-shadow', '-python', '-keyword', '-dnone', #'-dascii',
|
||||
'-I./src', '-D'+WXPLAT]
|
||||
swig_deps = ['src/my_typemaps.i']
|
||||
|
||||
swig_files = [ 'wx.i', 'windows.i', 'windows2.i', 'windows3.i', 'events.i',
|
||||
'misc.i', 'misc2.i', 'gdi.i', 'mdi.i', 'controls.i',
|
||||
'controls2.i', 'cmndlgs.i', 'stattool.i', 'frames.i', 'image.i',
|
||||
'printfw.i', 'sizers.i', 'clip_dnd.i',
|
||||
'filesys.i', 'streams.i',
|
||||
##'grid.i', 'html.i', 'htmlhelp.i', 'calendar.i', 'utils.i',
|
||||
]
|
||||
|
||||
swig_sources = run_swig(swig_files, 'src', GENDIR, PKGDIR,
|
||||
USE_SWIG, swig_force, swig_args, swig_deps)
|
||||
#----------------------------------------------------------------------
|
||||
# Define the CORE extension module
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
copy_file('src/__init__.py', PKGDIR, update=1, verbose=0)
|
||||
copy_file('src/__version__.py', PKGDIR, update=1, verbose=0)
|
||||
if not GL_ONLY:
|
||||
print 'Preparing CORE...'
|
||||
swig_files = [ 'wx.i', 'windows.i', 'windows2.i', 'windows3.i', 'events.i',
|
||||
'misc.i', 'misc2.i', 'gdi.i', 'mdi.i', 'controls.i',
|
||||
'controls2.i', 'cmndlgs.i', 'stattool.i', 'frames.i', 'image.i',
|
||||
'printfw.i', 'sizers.i', 'clip_dnd.i',
|
||||
'filesys.i', 'streams.i',
|
||||
##'grid.i', 'html.i', 'htmlhelp.i', 'calendar.i', 'utils.i',
|
||||
]
|
||||
|
||||
swig_sources = run_swig(swig_files, 'src', GENDIR, PKGDIR,
|
||||
USE_SWIG, swig_force, swig_args, swig_deps)
|
||||
|
||||
copy_file('src/__init__.py', PKGDIR, update=1, verbose=0)
|
||||
copy_file('src/__version__.py', PKGDIR, update=1, verbose=0)
|
||||
|
||||
|
||||
if IN_CVS_TREE: # update the licence files
|
||||
mkpath('licence')
|
||||
for file in ['preamble.txt', 'licence.txt', 'licendoc.txt', 'lgpl.txt']:
|
||||
copy_file(WXDIR+'/docs/'+file, 'licence/'+file, update=1, verbose=0)
|
||||
if IN_CVS_TREE: # update the licence files
|
||||
mkpath('licence')
|
||||
for file in ['preamble.txt', 'licence.txt', 'licendoc.txt', 'lgpl.txt']:
|
||||
copy_file(WXDIR+'/docs/'+file, 'licence/'+file, update=1, verbose=0)
|
||||
|
||||
|
||||
if os.name == 'nt':
|
||||
rc_file = ['src/wxc.rc']
|
||||
else:
|
||||
rc_file = []
|
||||
if os.name == 'nt':
|
||||
rc_file = ['src/wxc.rc']
|
||||
else:
|
||||
rc_file = []
|
||||
|
||||
|
||||
ext = Extension('wxc', ['src/helpers.cpp',
|
||||
'src/libpy.c',
|
||||
] + rc_file + swig_sources,
|
||||
ext = Extension('wxc', ['src/helpers.cpp',
|
||||
'src/libpy.c',
|
||||
] + rc_file + swig_sources,
|
||||
|
||||
include_dirs = includes,
|
||||
define_macros = defines,
|
||||
include_dirs = includes,
|
||||
define_macros = defines,
|
||||
|
||||
library_dirs = libdirs,
|
||||
libraries = libs,
|
||||
library_dirs = libdirs,
|
||||
libraries = libs,
|
||||
|
||||
extra_compile_args = cflags,
|
||||
extra_link_args = lflags,
|
||||
)
|
||||
wxpExtensions.append(ext)
|
||||
extra_compile_args = cflags,
|
||||
extra_link_args = lflags,
|
||||
)
|
||||
wxpExtensions.append(ext)
|
||||
|
||||
|
||||
# Extension for the grid module
|
||||
swig_sources = run_swig(['grid.i'], 'src', GENDIR, PKGDIR,
|
||||
USE_SWIG, swig_force, swig_args, swig_deps)
|
||||
ext = Extension('gridc', swig_sources,
|
||||
include_dirs = includes,
|
||||
define_macros = defines,
|
||||
library_dirs = libdirs,
|
||||
libraries = libs,
|
||||
extra_compile_args = cflags,
|
||||
extra_link_args = lflags,
|
||||
)
|
||||
wxpExtensions.append(ext)
|
||||
# Extension for the grid module
|
||||
swig_sources = run_swig(['grid.i'], 'src', GENDIR, PKGDIR,
|
||||
USE_SWIG, swig_force, swig_args, swig_deps)
|
||||
ext = Extension('gridc', swig_sources,
|
||||
include_dirs = includes,
|
||||
define_macros = defines,
|
||||
library_dirs = libdirs,
|
||||
libraries = libs,
|
||||
extra_compile_args = cflags,
|
||||
extra_link_args = lflags,
|
||||
)
|
||||
wxpExtensions.append(ext)
|
||||
|
||||
|
||||
# Extension for the html modules
|
||||
swig_sources = run_swig(['html.i', 'htmlhelp.i'], 'src', GENDIR, PKGDIR,
|
||||
USE_SWIG, swig_force, swig_args, swig_deps)
|
||||
ext = Extension('htmlc', swig_sources,
|
||||
include_dirs = includes,
|
||||
define_macros = defines,
|
||||
library_dirs = libdirs,
|
||||
libraries = libs,
|
||||
extra_compile_args = cflags,
|
||||
extra_link_args = lflags,
|
||||
)
|
||||
wxpExtensions.append(ext)
|
||||
# Extension for the html modules
|
||||
swig_sources = run_swig(['html.i', 'htmlhelp.i'], 'src', GENDIR, PKGDIR,
|
||||
USE_SWIG, swig_force, swig_args, swig_deps)
|
||||
ext = Extension('htmlc', swig_sources,
|
||||
include_dirs = includes,
|
||||
define_macros = defines,
|
||||
library_dirs = libdirs,
|
||||
libraries = libs,
|
||||
extra_compile_args = cflags,
|
||||
extra_link_args = lflags,
|
||||
)
|
||||
wxpExtensions.append(ext)
|
||||
|
||||
|
||||
# Extension for the utils module
|
||||
swig_sources = run_swig(['utils.i'], 'src', GENDIR, PKGDIR,
|
||||
USE_SWIG, swig_force, swig_args, swig_deps)
|
||||
ext = Extension('utilsc', swig_sources,
|
||||
include_dirs = includes,
|
||||
define_macros = defines,
|
||||
library_dirs = libdirs,
|
||||
libraries = libs,
|
||||
extra_compile_args = cflags,
|
||||
extra_link_args = lflags,
|
||||
)
|
||||
wxpExtensions.append(ext)
|
||||
# Extension for the utils module
|
||||
swig_sources = run_swig(['utils.i'], 'src', GENDIR, PKGDIR,
|
||||
USE_SWIG, swig_force, swig_args, swig_deps)
|
||||
ext = Extension('utilsc', swig_sources,
|
||||
include_dirs = includes,
|
||||
define_macros = defines,
|
||||
library_dirs = libdirs,
|
||||
libraries = libs,
|
||||
extra_compile_args = cflags,
|
||||
extra_link_args = lflags,
|
||||
)
|
||||
wxpExtensions.append(ext)
|
||||
|
||||
|
||||
# Extension for the calendar module
|
||||
swig_sources = run_swig(['calendar.i'], 'src', GENDIR, PKGDIR,
|
||||
USE_SWIG, swig_force, swig_args, swig_deps)
|
||||
ext = Extension('calendarc', swig_sources,
|
||||
include_dirs = includes,
|
||||
define_macros = defines,
|
||||
library_dirs = libdirs,
|
||||
libraries = libs,
|
||||
extra_compile_args = cflags,
|
||||
extra_link_args = lflags,
|
||||
)
|
||||
wxpExtensions.append(ext)
|
||||
# Extension for the calendar module
|
||||
swig_sources = run_swig(['calendar.i'], 'src', GENDIR, PKGDIR,
|
||||
USE_SWIG, swig_force, swig_args, swig_deps)
|
||||
ext = Extension('calendarc', swig_sources,
|
||||
include_dirs = includes,
|
||||
define_macros = defines,
|
||||
library_dirs = libdirs,
|
||||
libraries = libs,
|
||||
extra_compile_args = cflags,
|
||||
extra_link_args = lflags,
|
||||
)
|
||||
wxpExtensions.append(ext)
|
||||
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
# Define the GLCanvas extension module
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
if BUILD_GLCANVAS:
|
||||
if BUILD_GLCANVAS or GL_ONLY:
|
||||
print 'Preparing GLCANVAS...'
|
||||
location = 'contrib/glcanvas'
|
||||
swig_files = ['glcanvas.i']
|
||||
@ -337,8 +347,7 @@ if BUILD_GLCANVAS:
|
||||
# Define the OGL extension module
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
|
||||
if BUILD_OGL:
|
||||
if not GL_ONLY and BUILD_OGL:
|
||||
print 'Preparing OGL...'
|
||||
location = 'contrib/ogl'
|
||||
OGLLOC = location + '/contrib/src/ogl'
|
||||
@ -387,7 +396,7 @@ if BUILD_OGL:
|
||||
# Define the STC extension module
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
if BUILD_STC:
|
||||
if not GL_ONLY and BUILD_STC:
|
||||
print 'Preparing STC...'
|
||||
location = 'contrib/stc'
|
||||
STCLOC = location + '/contrib/src/stc'
|
||||
@ -472,193 +481,44 @@ if BUILD_STC:
|
||||
# Do the Setup/Build/Install/Whatever
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
setup(name = PKGDIR,
|
||||
version = VERSION,
|
||||
description = DESCRIPTION,
|
||||
long_description = LONG_DESCRIPTION,
|
||||
author = AUTHOR,
|
||||
author_email = AUTHOR_EMAIL,
|
||||
url = URL,
|
||||
licence = LICENCE,
|
||||
if __name__ == "__main__":
|
||||
if not GL_ONLY:
|
||||
setup(name = PKGDIR,
|
||||
version = VERSION,
|
||||
description = DESCRIPTION,
|
||||
long_description = LONG_DESCRIPTION,
|
||||
author = AUTHOR,
|
||||
author_email = AUTHOR_EMAIL,
|
||||
url = URL,
|
||||
licence = LICENCE,
|
||||
|
||||
packages = [PKGDIR,
|
||||
PKGDIR+'.lib',
|
||||
PKGDIR+'.lib.editor',
|
||||
],
|
||||
packages = [PKGDIR,
|
||||
PKGDIR+'.lib',
|
||||
PKGDIR+'.lib.editor',
|
||||
],
|
||||
|
||||
ext_package = PKGDIR,
|
||||
ext_modules = wxpExtensions,
|
||||
ext_package = PKGDIR,
|
||||
ext_modules = wxpExtensions,
|
||||
)
|
||||
|
||||
)
|
||||
else:
|
||||
|
||||
setup(name = "wxPython-gl",
|
||||
version = VERSION,
|
||||
description = "wxGLCanvas class for wxPython",
|
||||
author = AUTHOR,
|
||||
author_email = AUTHOR_EMAIL,
|
||||
url = URL,
|
||||
licence = LICENCE,
|
||||
|
||||
py_modules = [ "wxPython.glcanvas" ],
|
||||
|
||||
ext_package = PKGDIR,
|
||||
ext_modules = wxpExtensions,
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
#----------------------------------------------------------------------
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
# The pre-distutils binary distributions of wxPython included the demo
|
||||
# as a subdirectory of the package dir. This doesn't really make sense
|
||||
# for Linux/Unix platforms as it's not part of the package, and the user
|
||||
# may want to tweak and learn without having to become root first.
|
||||
#
|
||||
# For now I am going to start distributing the demo as a separate tarball,
|
||||
# but if I ever want to go back to the old way, this is how to do it the
|
||||
# distutils way:
|
||||
|
||||
|
||||
## from my_install_data import *
|
||||
|
||||
## Add this to the setup() call
|
||||
## # Overridden command classes
|
||||
## cmdclass = {'install_data': my_install_data},
|
||||
## # non python files of examples
|
||||
## data_files = [
|
||||
## Data_Files(
|
||||
## base_dir='install_lib',
|
||||
## copy_to = 'wxPython',
|
||||
## #strip_dirs = 2,
|
||||
## template=[ 'graft demo',
|
||||
## 'global-exclude CVS/*'
|
||||
## ],
|
||||
## preserve_path=1
|
||||
## )
|
||||
## ],
|
||||
|
||||
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
#----------------------------------------------------------------------
|
||||
#----------------------------------------------------------------------
|
||||
## if not BUILD_GLCANVAS:
|
||||
## wxext.sources = wxext.sources + ['contrib/glcanvas/stub.cpp']
|
||||
## else:
|
||||
## print 'Preparing GLCANVAS...'
|
||||
## location = 'contrib/glcanvas'
|
||||
## swig_files = ['glcanvas.i']
|
||||
|
||||
## swig_sources = run_swig(swig_files, location, GENDIR, PKGDIR,
|
||||
## USE_SWIG, swig_force, swig_args, swig_deps)
|
||||
|
||||
## gl_libs = []
|
||||
## if os.name == 'posix':
|
||||
## if '-D__WXDEBUG__' in cflags:
|
||||
## gl_libs = ['wx_gtkd_gl', 'GL', 'GLU']
|
||||
## else:
|
||||
## gl_libs = ['wx_gtk_gl', 'GL', 'GLU']
|
||||
|
||||
## wxext.sources = wxext.sources + swig_sources
|
||||
## wxext.libraries = wxext.libraries + gl_libs
|
||||
|
||||
|
||||
## if not BUILD_OGL:
|
||||
## wxext.sources = wxext.sources + ['contrib/ogl/stub.cpp']
|
||||
## else:
|
||||
## print 'Preparing OGL...'
|
||||
## location = 'contrib/ogl'
|
||||
## OGLLOC = location + '/contrib/src/ogl'
|
||||
## OGLINC = location + '/contrib/include'
|
||||
|
||||
## swig_files = ['ogl.i', 'oglbasic.i', 'oglshapes.i', 'oglshapes2.i',
|
||||
## 'oglcanvas.i']
|
||||
|
||||
## swig_sources = run_swig(swig_files, location, '', PKGDIR,
|
||||
## USE_SWIG, swig_force, swig_args, swig_deps)
|
||||
|
||||
## # make sure local copy of contrib files are up to date
|
||||
## if IN_CVS_TREE:
|
||||
## contrib_copy_tree(WXDIR + '/contrib/include/wx/ogl', OGLINC+'/wx/ogl')
|
||||
## contrib_copy_tree(WXDIR + '/contrib/src/ogl', OGLLOC)
|
||||
|
||||
## # add items to the core extension module definition
|
||||
## wxext.sources = wxext.sources + [location + '/oglhelpers.cpp',
|
||||
## '%s/basic.cpp' % OGLLOC,
|
||||
## '%s/bmpshape.cpp' % OGLLOC,
|
||||
## '%s/composit.cpp' % OGLLOC,
|
||||
## '%s/divided.cpp' % OGLLOC,
|
||||
## '%s/lines.cpp' % OGLLOC,
|
||||
## '%s/misc.cpp' % OGLLOC,
|
||||
## '%s/basic2.cpp' % OGLLOC,
|
||||
## '%s/canvas.cpp' % OGLLOC,
|
||||
## '%s/constrnt.cpp' % OGLLOC,
|
||||
## '%s/drawn.cpp' % OGLLOC,
|
||||
## '%s/mfutils.cpp' % OGLLOC,
|
||||
## '%s/ogldiag.cpp' % OGLLOC,
|
||||
## ] + swig_sources
|
||||
|
||||
## wxext.include_dirs = wxext.include_dirs + [OGLINC]
|
||||
|
||||
|
||||
|
||||
|
||||
## if not BUILD_STC:
|
||||
## wxext.sources = wxext.sources + ['contrib/stc/stub.cpp']
|
||||
## else:
|
||||
## print 'Preparing STC...'
|
||||
## location = 'contrib/stc'
|
||||
## STCLOC = location + '/contrib/src/stc'
|
||||
## STCINC = location + '/contrib/include'
|
||||
## STC_H = location + '/contrib/include/wx/stc'
|
||||
|
||||
## # make sure local copy of contrib files are up to date
|
||||
## if IN_CVS_TREE:
|
||||
## contrib_copy_tree(WXDIR + '/contrib/include/wx/stc', STCINC+'/wx/stc')
|
||||
## contrib_copy_tree(WXDIR + '/contrib/src/stc', STCLOC)
|
||||
|
||||
|
||||
## swig_files = ['stc_.i']
|
||||
## swig_sources = run_swig(swig_files, location, '', PKGDIR,
|
||||
## USE_SWIG, swig_force,
|
||||
## swig_args + ['-I'+STC_H, '-I'+location],
|
||||
## swig_deps + [STC_H+'/stc.h'])
|
||||
|
||||
## # copy a project specific py module to the main package dir
|
||||
## copy_file(location+'/stc.py', PKGDIR, update=1, verbose=1)
|
||||
|
||||
## # add some include dirs to the standard set
|
||||
## stc_includes = [ '%s/scintilla/include' % STCLOC,
|
||||
## '%s/scintilla/src' % STCLOC,
|
||||
## STCINC ]
|
||||
|
||||
## # and some macro definitions
|
||||
## stc_defines = [ ('__WX__', None),
|
||||
## ('SCI_LEXER', None) ]
|
||||
|
||||
|
||||
## # add items to the core extension module definition
|
||||
## wxext.sources = wxext.sources + [
|
||||
## '%s/scintilla/src/AutoComplete.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/CallTip.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/CellBuffer.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/ContractionState.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/Document.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/Editor.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/Indicator.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/KeyMap.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/KeyWords.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/LineMarker.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/PropSet.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/ScintillaBase.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/Style.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/ViewStyle.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/LexCPP.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/LexHTML.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/LexLua.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/LexOthers.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/LexPerl.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/LexPython.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/LexSQL.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/LexVB.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/DocumentAccessor.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/UniConversion.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/WindowAccessor.cxx' % STCLOC,
|
||||
## '%s/scintilla/src/PosRegExp.cxx' % STCLOC,
|
||||
|
||||
## '%s/PlatWX.cpp' % STCLOC,
|
||||
## '%s/ScintillaWX.cpp' % STCLOC,
|
||||
## '%s/stc.cpp' % STCLOC,
|
||||
## ] + swig_sources
|
||||
|
||||
## wxext.include_dirs = wxext.include_dirs + stc_includes
|
||||
## wxext.define_macros = wxext.define_macros + stc_defines
|
||||
|
@ -1 +1 @@
|
||||
ver = '2.3b2'
|
||||
ver = '2.3b3'
|
||||
|
@ -218,6 +218,8 @@ enum {
|
||||
wxFRAME_TOOL_WINDOW,
|
||||
wxFRAME_FLOAT_ON_PARENT,
|
||||
wxFRAME_NO_WINDOW_MENU,
|
||||
wxFRAME_NO_TASKBAR,
|
||||
wxFRAME_EX_CONTEXTHELP,
|
||||
wxED_CLIENT_MARGIN,
|
||||
wxED_BUTTONS_BOTTOM,
|
||||
wxED_BUTTONS_RIGHT,
|
||||
@ -246,6 +248,8 @@ enum {
|
||||
wxALIGN_CENTER,
|
||||
wxALIGN_CENTRE,
|
||||
wxSHAPED,
|
||||
wxADJUST_MINSIZE,
|
||||
|
||||
wxLB_NEEDED_SB,
|
||||
wxLB_ALWAYS_SB,
|
||||
wxLB_SORT,
|
||||
@ -316,12 +320,17 @@ enum {
|
||||
wxLC_MASK_TYPE,
|
||||
wxLC_MASK_ALIGN,
|
||||
wxLC_MASK_SORT,
|
||||
wxLC_HRULES,
|
||||
wxLC_VRULES,
|
||||
wxSP_VERTICAL,
|
||||
wxSP_HORIZONTAL,
|
||||
wxSP_ARROW_KEYS,
|
||||
wxSP_WRAP,
|
||||
wxSP_NOBORDER,
|
||||
wxSP_3D,
|
||||
wxSP_3DSASH,
|
||||
wxSP_3DBORDER,
|
||||
wxSP_FULLSASH,
|
||||
wxSP_BORDER,
|
||||
wxSP_LIVE_UPDATE,
|
||||
wxSP_PERMIT_UNSPLIT,
|
||||
@ -437,6 +446,7 @@ enum {
|
||||
wxOVERWRITE_PROMPT,
|
||||
wxFILE_MUST_EXIST,
|
||||
wxMULTIPLE,
|
||||
wxCHANGE_DIR,
|
||||
|
||||
wxACCEL_ALT,
|
||||
wxACCEL_CTRL,
|
||||
@ -910,62 +920,10 @@ enum wxEventType {
|
||||
wxEVT_COMMAND_KILL_FOCUS,
|
||||
wxEVT_COMMAND_ENTER,
|
||||
|
||||
/* Tree control event types */
|
||||
wxEVT_COMMAND_TREE_BEGIN_DRAG,
|
||||
wxEVT_COMMAND_TREE_BEGIN_RDRAG,
|
||||
wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT,
|
||||
wxEVT_COMMAND_TREE_END_LABEL_EDIT,
|
||||
wxEVT_COMMAND_TREE_DELETE_ITEM,
|
||||
wxEVT_COMMAND_TREE_GET_INFO,
|
||||
wxEVT_COMMAND_TREE_SET_INFO,
|
||||
wxEVT_COMMAND_TREE_ITEM_EXPANDED,
|
||||
wxEVT_COMMAND_TREE_ITEM_EXPANDING,
|
||||
wxEVT_COMMAND_TREE_ITEM_COLLAPSED,
|
||||
wxEVT_COMMAND_TREE_ITEM_COLLAPSING,
|
||||
wxEVT_COMMAND_TREE_SEL_CHANGED,
|
||||
wxEVT_COMMAND_TREE_SEL_CHANGING,
|
||||
wxEVT_COMMAND_TREE_KEY_DOWN,
|
||||
wxEVT_COMMAND_TREE_ITEM_ACTIVATED,
|
||||
wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK,
|
||||
wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK,
|
||||
|
||||
/* List control event types */
|
||||
wxEVT_COMMAND_LIST_BEGIN_DRAG,
|
||||
wxEVT_COMMAND_LIST_BEGIN_RDRAG,
|
||||
wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT,
|
||||
wxEVT_COMMAND_LIST_END_LABEL_EDIT,
|
||||
wxEVT_COMMAND_LIST_DELETE_ITEM,
|
||||
wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS,
|
||||
wxEVT_COMMAND_LIST_GET_INFO,
|
||||
wxEVT_COMMAND_LIST_SET_INFO,
|
||||
wxEVT_COMMAND_LIST_ITEM_SELECTED,
|
||||
wxEVT_COMMAND_LIST_ITEM_DESELECTED,
|
||||
wxEVT_COMMAND_LIST_KEY_DOWN,
|
||||
wxEVT_COMMAND_LIST_INSERT_ITEM,
|
||||
wxEVT_COMMAND_LIST_COL_CLICK,
|
||||
wxEVT_COMMAND_LIST_ITEM_ACTIVATED,
|
||||
wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK,
|
||||
wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK,
|
||||
|
||||
|
||||
/* Tab and notebook control event types */
|
||||
wxEVT_COMMAND_TAB_SEL_CHANGED,
|
||||
wxEVT_COMMAND_TAB_SEL_CHANGING,
|
||||
wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED,
|
||||
wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING,
|
||||
|
||||
/* splitter window */
|
||||
wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING,
|
||||
wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED,
|
||||
wxEVT_COMMAND_SPLITTER_UNSPLIT,
|
||||
wxEVT_COMMAND_SPLITTER_DOUBLECLICKED,
|
||||
|
||||
wxEVT_NAVIGATION_KEY,
|
||||
|
||||
wxEVT_TIMER,
|
||||
|
||||
wxEVT_END_PROCESS,
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
@ -91,6 +91,28 @@ enum wxListColumnFormat
|
||||
};
|
||||
|
||||
|
||||
enum {
|
||||
/* List control event types */
|
||||
wxEVT_COMMAND_LIST_BEGIN_DRAG,
|
||||
wxEVT_COMMAND_LIST_BEGIN_RDRAG,
|
||||
wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT,
|
||||
wxEVT_COMMAND_LIST_END_LABEL_EDIT,
|
||||
wxEVT_COMMAND_LIST_DELETE_ITEM,
|
||||
wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS,
|
||||
wxEVT_COMMAND_LIST_GET_INFO,
|
||||
wxEVT_COMMAND_LIST_SET_INFO,
|
||||
wxEVT_COMMAND_LIST_ITEM_SELECTED,
|
||||
wxEVT_COMMAND_LIST_ITEM_DESELECTED,
|
||||
wxEVT_COMMAND_LIST_KEY_DOWN,
|
||||
wxEVT_COMMAND_LIST_INSERT_ITEM,
|
||||
wxEVT_COMMAND_LIST_COL_CLICK,
|
||||
wxEVT_COMMAND_LIST_ITEM_ACTIVATED,
|
||||
wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK,
|
||||
wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK,
|
||||
};
|
||||
|
||||
|
||||
|
||||
class wxListItemAttr
|
||||
{
|
||||
public:
|
||||
@ -218,6 +240,7 @@ public:
|
||||
%pragma(python) addtomethod = "__init__:#wx._StdWindowCallbacks(self)"
|
||||
|
||||
bool Arrange(int flag = wxLIST_ALIGN_DEFAULT);
|
||||
void AssignImageList(wxImageList* imageList, int which);
|
||||
bool DeleteItem(long item);
|
||||
bool DeleteAllItems();
|
||||
bool DeleteColumn(int col);
|
||||
@ -367,6 +390,28 @@ enum {
|
||||
};
|
||||
|
||||
|
||||
enum {
|
||||
/* Tree control event types */
|
||||
wxEVT_COMMAND_TREE_BEGIN_DRAG,
|
||||
wxEVT_COMMAND_TREE_BEGIN_RDRAG,
|
||||
wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT,
|
||||
wxEVT_COMMAND_TREE_END_LABEL_EDIT,
|
||||
wxEVT_COMMAND_TREE_DELETE_ITEM,
|
||||
wxEVT_COMMAND_TREE_GET_INFO,
|
||||
wxEVT_COMMAND_TREE_SET_INFO,
|
||||
wxEVT_COMMAND_TREE_ITEM_EXPANDED,
|
||||
wxEVT_COMMAND_TREE_ITEM_EXPANDING,
|
||||
wxEVT_COMMAND_TREE_ITEM_COLLAPSED,
|
||||
wxEVT_COMMAND_TREE_ITEM_COLLAPSING,
|
||||
wxEVT_COMMAND_TREE_SEL_CHANGED,
|
||||
wxEVT_COMMAND_TREE_SEL_CHANGING,
|
||||
wxEVT_COMMAND_TREE_KEY_DOWN,
|
||||
wxEVT_COMMAND_TREE_ITEM_ACTIVATED,
|
||||
wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK,
|
||||
wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK,
|
||||
};
|
||||
|
||||
|
||||
class wxTreeItemId {
|
||||
public:
|
||||
wxTreeItemId();
|
||||
@ -491,12 +536,13 @@ public:
|
||||
%pragma(python) addtomethod = "__init__:#wx._StdWindowCallbacks(self)"
|
||||
%pragma(python) addtomethod = "__init__:self._setSelf(self, wxTreeCtrl)"
|
||||
|
||||
void AssignImageList(wxImageList* imageList);
|
||||
size_t GetCount();
|
||||
unsigned int GetIndent();
|
||||
void SetIndent(unsigned int indent);
|
||||
wxImageList *GetImageList();
|
||||
wxImageList *GetStateImageList();
|
||||
void SetImageList(wxImageList *imageList/*, int which = wxIMAGE_LIST_NORMAL*/);
|
||||
void SetImageList(wxImageList *imageList);
|
||||
void SetStateImageList(wxImageList *imageList);
|
||||
|
||||
unsigned int GetSpacing();
|
||||
@ -700,6 +746,15 @@ public:
|
||||
|
||||
#ifdef SKIPTHIS
|
||||
#ifdef __WXMSW__
|
||||
|
||||
|
||||
enum {
|
||||
/* tab control event types */
|
||||
wxEVT_COMMAND_TAB_SEL_CHANGED,
|
||||
wxEVT_COMMAND_TAB_SEL_CHANGING,
|
||||
};
|
||||
|
||||
|
||||
class wxTabEvent : public wxCommandEvent {
|
||||
public:
|
||||
};
|
||||
|
@ -21,9 +21,11 @@
|
||||
#include "helpers.h"
|
||||
|
||||
|
||||
#define wxPyCoreAPI_IMPORT() \
|
||||
wxPyCoreAPIPtr = (wxPyCoreAPI*)PyCObject_Import("wxPython.wxc", "wxPyCoreAPI")
|
||||
|
||||
static void wxPyCoreAPI_IMPORT() {
|
||||
wxPyCoreAPIPtr = (wxPyCoreAPI*)PyCObject_Import("wxPython.wxc", "wxPyCoreAPI");
|
||||
if (! wxPyCoreAPIPtr)
|
||||
wxPyCoreAPIPtr = (wxPyCoreAPI*)PyCObject_Import("wxc", "wxPyCoreAPI");
|
||||
}
|
||||
|
||||
#define SWIG_MakePtr(a, b, c) (wxPyCoreAPIPtr->p_SWIG_MakePtr(a, b, c))
|
||||
#define SWIG_GetPtr(a, b, c) (wxPyCoreAPIPtr->p_SWIG_GetPtr(a, b, c))
|
||||
|
@ -594,15 +594,6 @@ public:
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
#ifdef __WXMSW__
|
||||
class wxPrinterDC : public wxDC {
|
||||
public:
|
||||
wxPrinterDC(const wxString& driver, const wxString& device, const wxString& output,
|
||||
bool interactive = TRUE, int orientation = wxPORTRAIT);
|
||||
};
|
||||
#endif
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
#ifdef __WXMSW__
|
||||
class wxMetaFileDC : public wxDC {
|
||||
|
@ -361,6 +361,111 @@ static PyObject *_wrap_wxGetTextFromUser(PyObject *self, PyObject *args, PyObjec
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxGetPasswordFromUser(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxString * _result;
|
||||
wxString * _arg0;
|
||||
wxString * _arg1 = (wxString *) &wxPyEmptyStr;
|
||||
wxString * _arg2 = (wxString *) &wxPyEmptyStr;
|
||||
wxWindow * _arg3 = (wxWindow *) NULL;
|
||||
PyObject * _obj0 = 0;
|
||||
PyObject * _obj1 = 0;
|
||||
PyObject * _obj2 = 0;
|
||||
PyObject * _argo3 = 0;
|
||||
char *_kwnames[] = { "message","caption","default_value","parent", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|OOO:wxGetPasswordFromUser",_kwnames,&_obj0,&_obj1,&_obj2,&_argo3))
|
||||
return NULL;
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj0) && !PyUnicode_Check(_obj0)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj0, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg0 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj0)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg0 = new wxString(PyString_AS_STRING(_obj0), PyString_GET_SIZE(_obj0));
|
||||
#endif
|
||||
}
|
||||
if (_obj1)
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg1 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj1)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1));
|
||||
#endif
|
||||
}
|
||||
if (_obj2)
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg2 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj2)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2));
|
||||
#endif
|
||||
}
|
||||
if (_argo3) {
|
||||
if (_argo3 == Py_None) { _arg3 = NULL; }
|
||||
else if (SWIG_GetPtrObj(_argo3,(void **) &_arg3,"_wxWindow_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 4 of wxGetPasswordFromUser. Expected _wxWindow_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
{
|
||||
wxPy_BEGIN_ALLOW_THREADS;
|
||||
_result = new wxString (wxGetPasswordFromUser(*_arg0,*_arg1,*_arg2,_arg3));
|
||||
|
||||
wxPy_END_ALLOW_THREADS;
|
||||
}{
|
||||
_resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len());
|
||||
}
|
||||
{
|
||||
if (_obj0)
|
||||
delete _arg0;
|
||||
}
|
||||
{
|
||||
if (_obj1)
|
||||
delete _arg1;
|
||||
}
|
||||
{
|
||||
if (_obj2)
|
||||
delete _arg2;
|
||||
}
|
||||
{
|
||||
delete _result;
|
||||
}
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxGetSingleChoice(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxString * _result;
|
||||
@ -865,62 +970,6 @@ static PyObject *_wrap_wxGetDisplaySize(PyObject *self, PyObject *args, PyObject
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxDisplaySizeMM(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
int * _arg0;
|
||||
int temp;
|
||||
int * _arg1;
|
||||
int temp0;
|
||||
char *_kwnames[] = { NULL };
|
||||
|
||||
self = self;
|
||||
{
|
||||
_arg0 = &temp;
|
||||
}
|
||||
{
|
||||
_arg1 = &temp0;
|
||||
}
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,":wxDisplaySizeMM",_kwnames))
|
||||
return NULL;
|
||||
{
|
||||
wxPy_BEGIN_ALLOW_THREADS;
|
||||
wxDisplaySizeMM(_arg0,_arg1);
|
||||
|
||||
wxPy_END_ALLOW_THREADS;
|
||||
} Py_INCREF(Py_None);
|
||||
_resultobj = Py_None;
|
||||
{
|
||||
PyObject *o;
|
||||
o = PyInt_FromLong((long) (*_arg0));
|
||||
_resultobj = t_output_helper(_resultobj, o);
|
||||
}
|
||||
{
|
||||
PyObject *o;
|
||||
o = PyInt_FromLong((long) (*_arg1));
|
||||
_resultobj = t_output_helper(_resultobj, o);
|
||||
}
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxGetDisplaySizeMM(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxSize * _result;
|
||||
char *_kwnames[] = { NULL };
|
||||
char _ptemp[128];
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,":wxGetDisplaySizeMM",_kwnames))
|
||||
return NULL;
|
||||
{
|
||||
wxPy_BEGIN_ALLOW_THREADS;
|
||||
_result = new wxSize (wxGetDisplaySizeMM());
|
||||
|
||||
wxPy_END_ALLOW_THREADS;
|
||||
} SWIG_MakePtr(_ptemp, (void *) _result,"_wxSize_p");
|
||||
_resultobj = Py_BuildValue("s",_ptemp);
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxSetCursor(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxCursor * _arg0;
|
||||
@ -5362,8 +5411,6 @@ static PyMethodDef misc2cMethods[] = {
|
||||
{ "wxFindWindowByName", (PyCFunction) _wrap_wxFindWindowByName, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxFindWindowByLabel", (PyCFunction) _wrap_wxFindWindowByLabel, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxSetCursor", (PyCFunction) _wrap_wxSetCursor, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGetDisplaySizeMM", (PyCFunction) _wrap_wxGetDisplaySizeMM, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxDisplaySizeMM", (PyCFunction) _wrap_wxDisplaySizeMM, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGetDisplaySize", (PyCFunction) _wrap_wxGetDisplaySize, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxDisplaySize", (PyCFunction) _wrap_wxDisplaySize, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGetDisplayDepth", (PyCFunction) _wrap_wxGetDisplayDepth, METH_VARARGS | METH_KEYWORDS },
|
||||
@ -5373,6 +5420,7 @@ static PyMethodDef misc2cMethods[] = {
|
||||
{ "wxMessageBox", (PyCFunction) _wrap_wxMessageBox, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGetSingleChoiceIndex", (PyCFunction) _wrap_wxGetSingleChoiceIndex, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGetSingleChoice", (PyCFunction) _wrap_wxGetSingleChoice, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGetPasswordFromUser", (PyCFunction) _wrap_wxGetPasswordFromUser, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGetTextFromUser", (PyCFunction) _wrap_wxGetTextFromUser, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxFileSelector", (PyCFunction) _wrap_wxFileSelector, METH_VARARGS | METH_KEYWORDS },
|
||||
{ NULL, NULL }
|
||||
|
@ -479,6 +479,8 @@ wxFileSelector = misc2c.wxFileSelector
|
||||
|
||||
wxGetTextFromUser = misc2c.wxGetTextFromUser
|
||||
|
||||
wxGetPasswordFromUser = misc2c.wxGetPasswordFromUser
|
||||
|
||||
wxGetSingleChoice = misc2c.wxGetSingleChoice
|
||||
|
||||
wxGetSingleChoiceIndex = misc2c.wxGetSingleChoiceIndex
|
||||
@ -500,13 +502,6 @@ def wxGetDisplaySize(*_args, **_kwargs):
|
||||
if val: val = wxSizePtr(val); val.thisown = 1
|
||||
return val
|
||||
|
||||
wxDisplaySizeMM = misc2c.wxDisplaySizeMM
|
||||
|
||||
def wxGetDisplaySizeMM(*_args, **_kwargs):
|
||||
val = apply(misc2c.wxGetDisplaySizeMM,_args,_kwargs)
|
||||
if val: val = wxSizePtr(val); val.thisown = 1
|
||||
return val
|
||||
|
||||
wxSetCursor = misc2c.wxSetCursor
|
||||
|
||||
def wxFindWindowByLabel(*_args, **_kwargs):
|
||||
|
@ -2137,6 +2137,9 @@ SWIGEXPORT(void) initwindows3c() {
|
||||
PyDict_SetItemString(d,"wxSASH_NONE", PyInt_FromLong((long) wxSASH_NONE));
|
||||
PyDict_SetItemString(d,"wxEVT_SASH_DRAGGED", PyInt_FromLong((long) wxEVT_SASH_DRAGGED));
|
||||
PyDict_SetItemString(d,"wxSW_3D", PyInt_FromLong((long) wxSW_3D));
|
||||
PyDict_SetItemString(d,"wxSW_3DSASH", PyInt_FromLong((long) wxSW_3DSASH));
|
||||
PyDict_SetItemString(d,"wxSW_3DBORDER", PyInt_FromLong((long) wxSW_3DBORDER));
|
||||
PyDict_SetItemString(d,"wxSW_BORDER", PyInt_FromLong((long) wxSW_BORDER));
|
||||
PyDict_SetItemString(d,"wxSASH_STATUS_OK", PyInt_FromLong((long) wxSASH_STATUS_OK));
|
||||
PyDict_SetItemString(d,"wxSASH_STATUS_OUT_OF_RANGE", PyInt_FromLong((long) wxSASH_STATUS_OUT_OF_RANGE));
|
||||
PyDict_SetItemString(d,"wxLAYOUT_HORIZONTAL", PyInt_FromLong((long) wxLAYOUT_HORIZONTAL));
|
||||
|
@ -262,6 +262,9 @@ wxSASH_LEFT = windows3c.wxSASH_LEFT
|
||||
wxSASH_NONE = windows3c.wxSASH_NONE
|
||||
wxEVT_SASH_DRAGGED = windows3c.wxEVT_SASH_DRAGGED
|
||||
wxSW_3D = windows3c.wxSW_3D
|
||||
wxSW_3DSASH = windows3c.wxSW_3DSASH
|
||||
wxSW_3DBORDER = windows3c.wxSW_3DBORDER
|
||||
wxSW_BORDER = windows3c.wxSW_BORDER
|
||||
wxSASH_STATUS_OK = windows3c.wxSASH_STATUS_OK
|
||||
wxSASH_STATUS_OUT_OF_RANGE = windows3c.wxSASH_STATUS_OUT_OF_RANGE
|
||||
wxLAYOUT_HORIZONTAL = windows3c.wxLAYOUT_HORIZONTAL
|
||||
|
@ -2393,6 +2393,9 @@ SWIGEXPORT(void) initwxc() {
|
||||
PyDict_SetItemString(d,"wxSP_WRAP", PyInt_FromLong((long) wxSP_WRAP));
|
||||
PyDict_SetItemString(d,"wxSP_NOBORDER", PyInt_FromLong((long) wxSP_NOBORDER));
|
||||
PyDict_SetItemString(d,"wxSP_3D", PyInt_FromLong((long) wxSP_3D));
|
||||
PyDict_SetItemString(d,"wxSP_3DSASH", PyInt_FromLong((long) wxSP_3DSASH));
|
||||
PyDict_SetItemString(d,"wxSP_3DBORDER", PyInt_FromLong((long) wxSP_3DBORDER));
|
||||
PyDict_SetItemString(d,"wxSP_FULLSASH", PyInt_FromLong((long) wxSP_FULLSASH));
|
||||
PyDict_SetItemString(d,"wxSP_BORDER", PyInt_FromLong((long) wxSP_BORDER));
|
||||
PyDict_SetItemString(d,"wxSP_LIVE_UPDATE", PyInt_FromLong((long) wxSP_LIVE_UPDATE));
|
||||
PyDict_SetItemString(d,"wxSP_PERMIT_UNSPLIT", PyInt_FromLong((long) wxSP_PERMIT_UNSPLIT));
|
||||
|
@ -301,6 +301,9 @@ wxSP_ARROW_KEYS = wxc.wxSP_ARROW_KEYS
|
||||
wxSP_WRAP = wxc.wxSP_WRAP
|
||||
wxSP_NOBORDER = wxc.wxSP_NOBORDER
|
||||
wxSP_3D = wxc.wxSP_3D
|
||||
wxSP_3DSASH = wxc.wxSP_3DSASH
|
||||
wxSP_3DBORDER = wxc.wxSP_3DBORDER
|
||||
wxSP_FULLSASH = wxc.wxSP_FULLSASH
|
||||
wxSP_BORDER = wxc.wxSP_BORDER
|
||||
wxSP_LIVE_UPDATE = wxc.wxSP_LIVE_UPDATE
|
||||
wxSP_PERMIT_UNSPLIT = wxc.wxSP_PERMIT_UNSPLIT
|
||||
|
@ -37,9 +37,9 @@
|
||||
%extern controls2.i
|
||||
|
||||
%extern utils.i
|
||||
|
||||
%extern html.i
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
enum {
|
||||
|
@ -405,13 +405,32 @@ SWIG_GetPtrObj(PyObject *obj, void **ptr, char *type) {
|
||||
if (!PyString_Check(obj)) {
|
||||
if (!PyInstance_Check(obj) || !(sobj = PyObject_GetAttrString(obj,"this")))
|
||||
return "";
|
||||
// PyObject_GetAttrString increases sobj refcout !
|
||||
Py_DECREF(sobj);
|
||||
}
|
||||
str = PyString_AsString(sobj);
|
||||
return SWIG_GetPtr(str,ptr,type);
|
||||
}
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
@ -60,8 +60,17 @@ public:
|
||||
return tup;
|
||||
}
|
||||
}
|
||||
%pragma(python) addtoclass = "def __str__(self): return str(self.asTuple())"
|
||||
%pragma(python) addtoclass = "def __repr__(self): return str(self.asTuple())"
|
||||
|
||||
%pragma(python) addtoclass = "
|
||||
def __str__(self): return str(self.asTuple())
|
||||
def __repr__(self): return str(self.asTuple())
|
||||
def __len__(self): return len(self.asTuple()
|
||||
def __getitem__(self, index): return self.asTuple()[index]
|
||||
def __setitem__(self, index, val):
|
||||
if index == 0: self.width = val
|
||||
elif index == 1: self.height = val
|
||||
else: raise IndexError
|
||||
"
|
||||
|
||||
};
|
||||
|
||||
@ -101,8 +110,16 @@ public:
|
||||
return *self == *p;
|
||||
}
|
||||
}
|
||||
%pragma(python) addtoclass = "def __str__(self): return str(self.asTuple())"
|
||||
%pragma(python) addtoclass = "def __repr__(self): return str(self.asTuple())"
|
||||
%pragma(python) addtoclass = "
|
||||
def __str__(self): return str(self.asTuple())
|
||||
def __repr__(self): return str(self.asTuple())
|
||||
def __len__(self): return len(self.asTuple()
|
||||
def __getitem__(self, index): return self.asTuple()[index]
|
||||
def __setitem__(self, index, val):
|
||||
if index == 0: self.width = val
|
||||
elif index == 1: self.height = val
|
||||
else: raise IndexError
|
||||
"
|
||||
};
|
||||
|
||||
|
||||
@ -140,8 +157,16 @@ public:
|
||||
return *self == *p;
|
||||
}
|
||||
}
|
||||
%pragma(python) addtoclass = "def __str__(self): return str(self.asTuple())"
|
||||
%pragma(python) addtoclass = "def __repr__(self): return str(self.asTuple())"
|
||||
%pragma(python) addtoclass = "
|
||||
def __str__(self): return str(self.asTuple())
|
||||
def __repr__(self): return str(self.asTuple())
|
||||
def __len__(self): return len(self.asTuple()
|
||||
def __getitem__(self, index): return self.asTuple()[index]
|
||||
def __setitem__(self, index, val):
|
||||
if index == 0: self.x = val
|
||||
elif index == 1: self.y = val
|
||||
else: raise IndexError
|
||||
"
|
||||
};
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
@ -201,9 +226,18 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
%pragma(python) addtoclass = "def __str__(self): return str(self.asTuple())"
|
||||
%pragma(python) addtoclass = "def __repr__(self): return str(self.asTuple())"
|
||||
%pragma(python) addtoclass = "
|
||||
def __str__(self): return str(self.asTuple())
|
||||
def __repr__(self): return str(self.asTuple())
|
||||
def __len__(self): return len(self.asTuple()
|
||||
def __getitem__(self, index): return self.asTuple()[index]
|
||||
def __setitem__(self, index, val):
|
||||
if index == 0: self.x = val
|
||||
elif index == 1: self.y = val
|
||||
elif index == 2: self.width = val
|
||||
elif index == 3: self.height = val
|
||||
else: raise IndexError
|
||||
|
||||
# override the __getattr__ made by SWIG
|
||||
def __getattr__(self, name):
|
||||
d = {
|
||||
|
@ -61,6 +61,11 @@ wxString wxGetTextFromUser(const wxString& message,
|
||||
int x = -1, int y = -1,
|
||||
bool centre = TRUE);
|
||||
|
||||
wxString wxGetPasswordFromUser(const wxString& message,
|
||||
const wxString& caption = wxPyEmptyStr,
|
||||
const wxString& default_value = wxPyEmptyStr,
|
||||
wxWindow *parent = NULL);
|
||||
|
||||
|
||||
// TODO: Need to custom wrap this one...
|
||||
// int wxGetMultipleChoice(char* message, char* caption,
|
||||
@ -109,6 +114,7 @@ int wxGetDisplayDepth();
|
||||
|
||||
void wxDisplaySize(int* OUTPUT, int* OUTPUT);
|
||||
wxSize wxGetDisplaySize();
|
||||
|
||||
void wxDisplaySizeMM(int* OUTPUT, int* OUTPUT);
|
||||
wxSize wxGetDisplaySizeMM();
|
||||
|
||||
@ -625,6 +631,13 @@ void wxLogSysError(const char *szFormat);
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
|
||||
|
||||
enum {
|
||||
/* event type */
|
||||
wxEVT_END_PROCESS
|
||||
};
|
||||
|
||||
|
||||
class wxProcessEvent : public wxEvent {
|
||||
public:
|
||||
wxProcessEvent(int id = 0, int pid = 0, int exitcode = 0);
|
||||
|
@ -1729,7 +1729,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -1948,7 +1947,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxButton","_class_wxButton",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxTimeSpan","_wxTimeSpan",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
|
@ -3515,7 +3515,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_wxWindowID",0},
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxMask","_wxMask",0},
|
||||
{ "_wxTextDataObject","_class_wxPyTextDataObject",SwigwxPyTextDataObjectTowxTextDataObject},
|
||||
{ "_wxTextDataObject","_wxPyTextDataObject",SwigwxPyTextDataObjectTowxTextDataObject},
|
||||
@ -3680,7 +3679,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_time_t","_size_t",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxPyFileDropTarget","_wxPyFileDropTarget",0},
|
||||
|
@ -2966,7 +2966,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -3253,7 +3252,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxButton","_class_wxButton",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxSysColourChangedEvent","_wxSysColourChangedEvent",0},
|
||||
|
@ -8098,7 +8098,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -8384,7 +8383,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxButton","_class_wxButton",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxSysColourChangedEvent","_wxSysColourChangedEvent",0},
|
||||
|
@ -2930,6 +2930,43 @@ static PyObject *_wrap_wxListCtrl_Arrange(PyObject *self, PyObject *args, PyObje
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define wxListCtrl_AssignImageList(_swigobj,_swigarg0,_swigarg1) (_swigobj->AssignImageList(_swigarg0,_swigarg1))
|
||||
static PyObject *_wrap_wxListCtrl_AssignImageList(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxListCtrl * _arg0;
|
||||
wxImageList * _arg1;
|
||||
int _arg2;
|
||||
PyObject * _argo0 = 0;
|
||||
PyObject * _argo1 = 0;
|
||||
char *_kwnames[] = { "self","imageList","which", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOi:wxListCtrl_AssignImageList",_kwnames,&_argo0,&_argo1,&_arg2))
|
||||
return NULL;
|
||||
if (_argo0) {
|
||||
if (_argo0 == Py_None) { _arg0 = NULL; }
|
||||
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxListCtrl_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListCtrl_AssignImageList. Expected _wxListCtrl_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
if (_argo1) {
|
||||
if (_argo1 == Py_None) { _arg1 = NULL; }
|
||||
else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxImageList_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxListCtrl_AssignImageList. Expected _wxImageList_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
{
|
||||
wxPy_BEGIN_ALLOW_THREADS;
|
||||
wxListCtrl_AssignImageList(_arg0,_arg1,_arg2);
|
||||
|
||||
wxPy_END_ALLOW_THREADS;
|
||||
} Py_INCREF(Py_None);
|
||||
_resultobj = Py_None;
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define wxListCtrl_DeleteItem(_swigobj,_swigarg0) (_swigobj->DeleteItem(_swigarg0))
|
||||
static PyObject *_wrap_wxListCtrl_DeleteItem(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
@ -5269,6 +5306,42 @@ static PyObject *_wrap_wxTreeCtrl__setSelf(PyObject *self, PyObject *args, PyObj
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define wxTreeCtrl_AssignImageList(_swigobj,_swigarg0) (_swigobj->AssignImageList(_swigarg0))
|
||||
static PyObject *_wrap_wxTreeCtrl_AssignImageList(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxPyTreeCtrl * _arg0;
|
||||
wxImageList * _arg1;
|
||||
PyObject * _argo0 = 0;
|
||||
PyObject * _argo1 = 0;
|
||||
char *_kwnames[] = { "self","imageList", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTreeCtrl_AssignImageList",_kwnames,&_argo0,&_argo1))
|
||||
return NULL;
|
||||
if (_argo0) {
|
||||
if (_argo0 == Py_None) { _arg0 = NULL; }
|
||||
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyTreeCtrl_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTreeCtrl_AssignImageList. Expected _wxPyTreeCtrl_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
if (_argo1) {
|
||||
if (_argo1 == Py_None) { _arg1 = NULL; }
|
||||
else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxImageList_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTreeCtrl_AssignImageList. Expected _wxImageList_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
{
|
||||
wxPy_BEGIN_ALLOW_THREADS;
|
||||
wxTreeCtrl_AssignImageList(_arg0,_arg1);
|
||||
|
||||
wxPy_END_ALLOW_THREADS;
|
||||
} Py_INCREF(Py_None);
|
||||
_resultobj = Py_None;
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define wxTreeCtrl_GetCount(_swigobj) (_swigobj->GetCount())
|
||||
static PyObject *_wrap_wxTreeCtrl_GetCount(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
@ -7998,6 +8071,7 @@ static PyMethodDef controls2cMethods[] = {
|
||||
{ "wxTreeCtrl_SetIndent", (PyCFunction) _wrap_wxTreeCtrl_SetIndent, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxTreeCtrl_GetIndent", (PyCFunction) _wrap_wxTreeCtrl_GetIndent, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxTreeCtrl_GetCount", (PyCFunction) _wrap_wxTreeCtrl_GetCount, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxTreeCtrl_AssignImageList", (PyCFunction) _wrap_wxTreeCtrl_AssignImageList, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxTreeCtrl__setSelf", (PyCFunction) _wrap_wxTreeCtrl__setSelf, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "new_wxTreeCtrl", (PyCFunction) _wrap_new_wxTreeCtrl, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxTreeEvent_GetLabel", (PyCFunction) _wrap_wxTreeEvent_GetLabel, METH_VARARGS | METH_KEYWORDS },
|
||||
@ -8065,6 +8139,7 @@ static PyMethodDef controls2cMethods[] = {
|
||||
{ "wxListCtrl_DeleteColumn", (PyCFunction) _wrap_wxListCtrl_DeleteColumn, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxListCtrl_DeleteAllItems", (PyCFunction) _wrap_wxListCtrl_DeleteAllItems, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxListCtrl_DeleteItem", (PyCFunction) _wrap_wxListCtrl_DeleteItem, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxListCtrl_AssignImageList", (PyCFunction) _wrap_wxListCtrl_AssignImageList, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxListCtrl_Arrange", (PyCFunction) _wrap_wxListCtrl_Arrange, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "new_wxListCtrl", (PyCFunction) _wrap_new_wxListCtrl, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxListEvent_GetItem", (PyCFunction) _wrap_wxListEvent_GetItem, METH_VARARGS | METH_KEYWORDS },
|
||||
@ -8237,7 +8312,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -8459,7 +8533,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxButton","_class_wxButton",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_wxPyTreeItemData","_class_wxPyTreeItemData",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
@ -8592,6 +8665,22 @@ SWIGEXPORT(void) initcontrols2c() {
|
||||
PyDict_SetItemString(d,"wxLIST_FORMAT_RIGHT", PyInt_FromLong((long) wxLIST_FORMAT_RIGHT));
|
||||
PyDict_SetItemString(d,"wxLIST_FORMAT_CENTRE", PyInt_FromLong((long) wxLIST_FORMAT_CENTRE));
|
||||
PyDict_SetItemString(d,"wxLIST_FORMAT_CENTER", PyInt_FromLong((long) wxLIST_FORMAT_CENTER));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_BEGIN_DRAG", PyInt_FromLong((long) wxEVT_COMMAND_LIST_BEGIN_DRAG));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_BEGIN_RDRAG", PyInt_FromLong((long) wxEVT_COMMAND_LIST_BEGIN_RDRAG));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT", PyInt_FromLong((long) wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_END_LABEL_EDIT", PyInt_FromLong((long) wxEVT_COMMAND_LIST_END_LABEL_EDIT));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_DELETE_ITEM", PyInt_FromLong((long) wxEVT_COMMAND_LIST_DELETE_ITEM));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS", PyInt_FromLong((long) wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_GET_INFO", PyInt_FromLong((long) wxEVT_COMMAND_LIST_GET_INFO));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_SET_INFO", PyInt_FromLong((long) wxEVT_COMMAND_LIST_SET_INFO));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_ITEM_SELECTED", PyInt_FromLong((long) wxEVT_COMMAND_LIST_ITEM_SELECTED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_ITEM_DESELECTED", PyInt_FromLong((long) wxEVT_COMMAND_LIST_ITEM_DESELECTED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_KEY_DOWN", PyInt_FromLong((long) wxEVT_COMMAND_LIST_KEY_DOWN));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_INSERT_ITEM", PyInt_FromLong((long) wxEVT_COMMAND_LIST_INSERT_ITEM));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_COL_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_LIST_COL_CLICK));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_ITEM_ACTIVATED", PyInt_FromLong((long) wxEVT_COMMAND_LIST_ITEM_ACTIVATED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK));
|
||||
PyDict_SetItemString(d,"wxTreeItemIcon_Normal", PyInt_FromLong((long) wxTreeItemIcon_Normal));
|
||||
PyDict_SetItemString(d,"wxTreeItemIcon_Selected", PyInt_FromLong((long) wxTreeItemIcon_Selected));
|
||||
PyDict_SetItemString(d,"wxTreeItemIcon_Expanded", PyInt_FromLong((long) wxTreeItemIcon_Expanded));
|
||||
@ -8611,6 +8700,23 @@ SWIGEXPORT(void) initcontrols2c() {
|
||||
PyDict_SetItemString(d,"wxTREE_HITTEST_ONITEMUPPERPART", PyInt_FromLong((long) wxTREE_HITTEST_ONITEMUPPERPART));
|
||||
PyDict_SetItemString(d,"wxTREE_HITTEST_ONITEMLOWERPART", PyInt_FromLong((long) wxTREE_HITTEST_ONITEMLOWERPART));
|
||||
PyDict_SetItemString(d,"wxTREE_HITTEST_ONITEM", PyInt_FromLong((long) wxTREE_HITTEST_ONITEM));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_BEGIN_DRAG", PyInt_FromLong((long) wxEVT_COMMAND_TREE_BEGIN_DRAG));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_BEGIN_RDRAG", PyInt_FromLong((long) wxEVT_COMMAND_TREE_BEGIN_RDRAG));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT", PyInt_FromLong((long) wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_END_LABEL_EDIT", PyInt_FromLong((long) wxEVT_COMMAND_TREE_END_LABEL_EDIT));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_DELETE_ITEM", PyInt_FromLong((long) wxEVT_COMMAND_TREE_DELETE_ITEM));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_GET_INFO", PyInt_FromLong((long) wxEVT_COMMAND_TREE_GET_INFO));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_SET_INFO", PyInt_FromLong((long) wxEVT_COMMAND_TREE_SET_INFO));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_EXPANDED", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_EXPANDED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_EXPANDING", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_EXPANDING));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_COLLAPSED", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_COLLAPSED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_COLLAPSING", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_COLLAPSING));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_SEL_CHANGED", PyInt_FromLong((long) wxEVT_COMMAND_TREE_SEL_CHANGED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_SEL_CHANGING", PyInt_FromLong((long) wxEVT_COMMAND_TREE_SEL_CHANGING));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_KEY_DOWN", PyInt_FromLong((long) wxEVT_COMMAND_TREE_KEY_DOWN));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_ACTIVATED", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_ACTIVATED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK));
|
||||
{
|
||||
int i;
|
||||
for (i = 0; _swig_mapping[i].n1; i++)
|
||||
|
@ -319,6 +319,9 @@ class wxListCtrlPtr(wxControlPtr):
|
||||
def Arrange(self, *_args, **_kwargs):
|
||||
val = apply(controls2c.wxListCtrl_Arrange,(self,) + _args, _kwargs)
|
||||
return val
|
||||
def AssignImageList(self, *_args, **_kwargs):
|
||||
val = apply(controls2c.wxListCtrl_AssignImageList,(self,) + _args, _kwargs)
|
||||
return val
|
||||
def DeleteItem(self, *_args, **_kwargs):
|
||||
val = apply(controls2c.wxListCtrl_DeleteItem,(self,) + _args, _kwargs)
|
||||
return val
|
||||
@ -578,6 +581,9 @@ class wxTreeCtrlPtr(wxControlPtr):
|
||||
def _setSelf(self, *_args, **_kwargs):
|
||||
val = apply(controls2c.wxTreeCtrl__setSelf,(self,) + _args, _kwargs)
|
||||
return val
|
||||
def AssignImageList(self, *_args, **_kwargs):
|
||||
val = apply(controls2c.wxTreeCtrl_AssignImageList,(self,) + _args, _kwargs)
|
||||
return val
|
||||
def GetCount(self, *_args, **_kwargs):
|
||||
val = apply(controls2c.wxTreeCtrl_GetCount,(self,) + _args, _kwargs)
|
||||
return val
|
||||
@ -876,6 +882,22 @@ wxLIST_FORMAT_LEFT = controls2c.wxLIST_FORMAT_LEFT
|
||||
wxLIST_FORMAT_RIGHT = controls2c.wxLIST_FORMAT_RIGHT
|
||||
wxLIST_FORMAT_CENTRE = controls2c.wxLIST_FORMAT_CENTRE
|
||||
wxLIST_FORMAT_CENTER = controls2c.wxLIST_FORMAT_CENTER
|
||||
wxEVT_COMMAND_LIST_BEGIN_DRAG = controls2c.wxEVT_COMMAND_LIST_BEGIN_DRAG
|
||||
wxEVT_COMMAND_LIST_BEGIN_RDRAG = controls2c.wxEVT_COMMAND_LIST_BEGIN_RDRAG
|
||||
wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT = controls2c.wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT
|
||||
wxEVT_COMMAND_LIST_END_LABEL_EDIT = controls2c.wxEVT_COMMAND_LIST_END_LABEL_EDIT
|
||||
wxEVT_COMMAND_LIST_DELETE_ITEM = controls2c.wxEVT_COMMAND_LIST_DELETE_ITEM
|
||||
wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS = controls2c.wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS
|
||||
wxEVT_COMMAND_LIST_GET_INFO = controls2c.wxEVT_COMMAND_LIST_GET_INFO
|
||||
wxEVT_COMMAND_LIST_SET_INFO = controls2c.wxEVT_COMMAND_LIST_SET_INFO
|
||||
wxEVT_COMMAND_LIST_ITEM_SELECTED = controls2c.wxEVT_COMMAND_LIST_ITEM_SELECTED
|
||||
wxEVT_COMMAND_LIST_ITEM_DESELECTED = controls2c.wxEVT_COMMAND_LIST_ITEM_DESELECTED
|
||||
wxEVT_COMMAND_LIST_KEY_DOWN = controls2c.wxEVT_COMMAND_LIST_KEY_DOWN
|
||||
wxEVT_COMMAND_LIST_INSERT_ITEM = controls2c.wxEVT_COMMAND_LIST_INSERT_ITEM
|
||||
wxEVT_COMMAND_LIST_COL_CLICK = controls2c.wxEVT_COMMAND_LIST_COL_CLICK
|
||||
wxEVT_COMMAND_LIST_ITEM_ACTIVATED = controls2c.wxEVT_COMMAND_LIST_ITEM_ACTIVATED
|
||||
wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK = controls2c.wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK
|
||||
wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK = controls2c.wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK
|
||||
wxTreeItemIcon_Normal = controls2c.wxTreeItemIcon_Normal
|
||||
wxTreeItemIcon_Selected = controls2c.wxTreeItemIcon_Selected
|
||||
wxTreeItemIcon_Expanded = controls2c.wxTreeItemIcon_Expanded
|
||||
@ -895,3 +917,20 @@ wxTREE_HITTEST_TORIGHT = controls2c.wxTREE_HITTEST_TORIGHT
|
||||
wxTREE_HITTEST_ONITEMUPPERPART = controls2c.wxTREE_HITTEST_ONITEMUPPERPART
|
||||
wxTREE_HITTEST_ONITEMLOWERPART = controls2c.wxTREE_HITTEST_ONITEMLOWERPART
|
||||
wxTREE_HITTEST_ONITEM = controls2c.wxTREE_HITTEST_ONITEM
|
||||
wxEVT_COMMAND_TREE_BEGIN_DRAG = controls2c.wxEVT_COMMAND_TREE_BEGIN_DRAG
|
||||
wxEVT_COMMAND_TREE_BEGIN_RDRAG = controls2c.wxEVT_COMMAND_TREE_BEGIN_RDRAG
|
||||
wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT = controls2c.wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT
|
||||
wxEVT_COMMAND_TREE_END_LABEL_EDIT = controls2c.wxEVT_COMMAND_TREE_END_LABEL_EDIT
|
||||
wxEVT_COMMAND_TREE_DELETE_ITEM = controls2c.wxEVT_COMMAND_TREE_DELETE_ITEM
|
||||
wxEVT_COMMAND_TREE_GET_INFO = controls2c.wxEVT_COMMAND_TREE_GET_INFO
|
||||
wxEVT_COMMAND_TREE_SET_INFO = controls2c.wxEVT_COMMAND_TREE_SET_INFO
|
||||
wxEVT_COMMAND_TREE_ITEM_EXPANDED = controls2c.wxEVT_COMMAND_TREE_ITEM_EXPANDED
|
||||
wxEVT_COMMAND_TREE_ITEM_EXPANDING = controls2c.wxEVT_COMMAND_TREE_ITEM_EXPANDING
|
||||
wxEVT_COMMAND_TREE_ITEM_COLLAPSED = controls2c.wxEVT_COMMAND_TREE_ITEM_COLLAPSED
|
||||
wxEVT_COMMAND_TREE_ITEM_COLLAPSING = controls2c.wxEVT_COMMAND_TREE_ITEM_COLLAPSING
|
||||
wxEVT_COMMAND_TREE_SEL_CHANGED = controls2c.wxEVT_COMMAND_TREE_SEL_CHANGED
|
||||
wxEVT_COMMAND_TREE_SEL_CHANGING = controls2c.wxEVT_COMMAND_TREE_SEL_CHANGING
|
||||
wxEVT_COMMAND_TREE_KEY_DOWN = controls2c.wxEVT_COMMAND_TREE_KEY_DOWN
|
||||
wxEVT_COMMAND_TREE_ITEM_ACTIVATED = controls2c.wxEVT_COMMAND_TREE_ITEM_ACTIVATED
|
||||
wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK = controls2c.wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK
|
||||
wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK = controls2c.wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK
|
||||
|
@ -6395,7 +6395,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
{ "_wxSysColourChangedEvent","_class_wxSysColourChangedEvent",0},
|
||||
@ -6614,7 +6613,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxNavigationKeyEvent","_wxNavigationKeyEvent",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxSysColourChangedEvent","_wxSysColourChangedEvent",0},
|
||||
{ "_class_wxInitDialogEvent","_wxInitDialogEvent",0},
|
||||
|
@ -2243,7 +2243,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxPNMHandler","_class_wxPNMHandler",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxGIFHandler","_wxGIFHandler",0},
|
||||
{ "_wxFileConfig","_class_wxFileConfig",0},
|
||||
{ "_class_wxMask","_wxMask",0},
|
||||
@ -2379,7 +2378,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxTimeSpan","_wxTimeSpan",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyFileSystemHandler","_wxPyFileSystemHandler",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxLayoutConstraints","_wxLayoutConstraints",0},
|
||||
|
@ -1297,7 +1297,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -1506,7 +1505,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxButton","_class_wxButton",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxSysColourChangedEvent","_wxSysColourChangedEvent",0},
|
||||
|
@ -7520,115 +7520,6 @@ static PyObject *_wrap_new_wxWindowDC(PyObject *self, PyObject *args, PyObject *
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static void *SwigwxPrinterDCTowxDC(void *ptr) {
|
||||
wxPrinterDC *src;
|
||||
wxDC *dest;
|
||||
src = (wxPrinterDC *) ptr;
|
||||
dest = (wxDC *) src;
|
||||
return (void *) dest;
|
||||
}
|
||||
|
||||
#define new_wxPrinterDC(_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4) (new wxPrinterDC(_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4))
|
||||
static PyObject *_wrap_new_wxPrinterDC(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxPrinterDC * _result;
|
||||
wxString * _arg0;
|
||||
wxString * _arg1;
|
||||
wxString * _arg2;
|
||||
bool _arg3 = (bool ) TRUE;
|
||||
int _arg4 = (int ) wxPORTRAIT;
|
||||
PyObject * _obj0 = 0;
|
||||
PyObject * _obj1 = 0;
|
||||
PyObject * _obj2 = 0;
|
||||
int tempbool3 = (int) TRUE;
|
||||
char *_kwnames[] = { "driver","device","output","interactive","orientation", NULL };
|
||||
char _ptemp[128];
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO|ii:new_wxPrinterDC",_kwnames,&_obj0,&_obj1,&_obj2,&tempbool3,&_arg4))
|
||||
return NULL;
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj0) && !PyUnicode_Check(_obj0)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj0, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg0 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj0)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg0 = new wxString(PyString_AS_STRING(_obj0), PyString_GET_SIZE(_obj0));
|
||||
#endif
|
||||
}
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg1 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj1)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1));
|
||||
#endif
|
||||
}
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg2 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj2)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2));
|
||||
#endif
|
||||
}
|
||||
_arg3 = (bool ) tempbool3;
|
||||
{
|
||||
wxPy_BEGIN_ALLOW_THREADS;
|
||||
_result = (wxPrinterDC *)new_wxPrinterDC(*_arg0,*_arg1,*_arg2,_arg3,_arg4);
|
||||
|
||||
wxPy_END_ALLOW_THREADS;
|
||||
} if (_result) {
|
||||
SWIG_MakePtr(_ptemp, (char *) _result,"_wxPrinterDC_p");
|
||||
_resultobj = Py_BuildValue("s",_ptemp);
|
||||
} else {
|
||||
Py_INCREF(Py_None);
|
||||
_resultobj = Py_None;
|
||||
}
|
||||
{
|
||||
if (_obj0)
|
||||
delete _arg0;
|
||||
}
|
||||
{
|
||||
if (_obj1)
|
||||
delete _arg1;
|
||||
}
|
||||
{
|
||||
if (_obj2)
|
||||
delete _arg2;
|
||||
}
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static void *SwigwxMetaFileDCTowxDC(void *ptr) {
|
||||
wxMetaFileDC *src;
|
||||
wxDC *dest;
|
||||
@ -8347,7 +8238,6 @@ static PyMethodDef gdicMethods[] = {
|
||||
{ "new_wxPalette", (PyCFunction) _wrap_new_wxPalette, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxMetaFileDC_Close", (PyCFunction) _wrap_wxMetaFileDC_Close, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "new_wxMetaFileDC", (PyCFunction) _wrap_new_wxMetaFileDC, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "new_wxPrinterDC", (PyCFunction) _wrap_new_wxPrinterDC, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "new_wxWindowDC", (PyCFunction) _wrap_new_wxWindowDC, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "new_wxPaintDC", (PyCFunction) _wrap_new_wxPaintDC, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "new_wxClientDC", (PyCFunction) _wrap_new_wxClientDC, METH_VARARGS | METH_KEYWORDS },
|
||||
@ -8583,8 +8473,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxAcceleratorTable","_wxAcceleratorTable",0},
|
||||
{ "_wxDC","_class_wxMetaFileDC",SwigwxMetaFileDCTowxDC},
|
||||
{ "_wxDC","_wxMetaFileDC",SwigwxMetaFileDCTowxDC},
|
||||
{ "_wxDC","_class_wxPrinterDC",SwigwxPrinterDCTowxDC},
|
||||
{ "_wxDC","_wxPrinterDC",SwigwxPrinterDCTowxDC},
|
||||
{ "_wxDC","_class_wxWindowDC",SwigwxWindowDCTowxDC},
|
||||
{ "_wxDC","_wxWindowDC",SwigwxWindowDCTowxDC},
|
||||
{ "_wxDC","_class_wxPaintDC",SwigwxPaintDCTowxDC},
|
||||
@ -8604,7 +8492,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_wxWindowID",0},
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxMask","_wxMask",0},
|
||||
{ "_wxColour","_class_wxColour",0},
|
||||
{ "_wxBrush","_class_wxBrush",0},
|
||||
@ -8633,8 +8520,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxRect","_wxRect",0},
|
||||
{ "_class_wxDC","_class_wxMetaFileDC",SwigwxMetaFileDCTowxDC},
|
||||
{ "_class_wxDC","_wxMetaFileDC",SwigwxMetaFileDCTowxDC},
|
||||
{ "_class_wxDC","_class_wxPrinterDC",SwigwxPrinterDCTowxDC},
|
||||
{ "_class_wxDC","_wxPrinterDC",SwigwxPrinterDCTowxDC},
|
||||
{ "_class_wxDC","_class_wxWindowDC",SwigwxWindowDCTowxDC},
|
||||
{ "_class_wxDC","_wxWindowDC",SwigwxWindowDCTowxDC},
|
||||
{ "_class_wxDC","_class_wxPaintDC",SwigwxPaintDCTowxDC},
|
||||
@ -8715,7 +8600,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_time_t","_size_t",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxLayoutConstraints","_wxLayoutConstraints",0},
|
||||
{ "_class_wxIcon","_wxIcon",0},
|
||||
|
@ -779,20 +779,6 @@ class wxWindowDC(wxWindowDCPtr):
|
||||
|
||||
|
||||
|
||||
class wxPrinterDCPtr(wxDCPtr):
|
||||
def __init__(self,this):
|
||||
self.this = this
|
||||
self.thisown = 0
|
||||
def __repr__(self):
|
||||
return "<C wxPrinterDC instance at %s>" % (self.this,)
|
||||
class wxPrinterDC(wxPrinterDCPtr):
|
||||
def __init__(self,*_args,**_kwargs):
|
||||
self.this = apply(gdic.new_wxPrinterDC,_args,_kwargs)
|
||||
self.thisown = 1
|
||||
|
||||
|
||||
|
||||
|
||||
class wxMetaFileDCPtr(wxDCPtr):
|
||||
def __init__(self,this):
|
||||
self.this = this
|
||||
|
@ -13174,7 +13174,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_class_wxGridRangeSelectEvent","_wxGridRangeSelectEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -13471,7 +13470,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxButton","_class_wxButton",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxSysColourChangedEvent","_wxSysColourChangedEvent",0},
|
||||
|
@ -6051,9 +6051,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPNMHandler","_class_wxPNMHandler",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_wxLogGui","_class_wxLogGui",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
{ "_wxSysColourChangedEvent","_class_wxSysColourChangedEvent",0},
|
||||
@ -6403,12 +6403,12 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxPyApp","_wxPyApp",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxLogTextCtrl","_wxLogTextCtrl",0},
|
||||
{ "_class_wxLogGui","_wxLogGui",0},
|
||||
{ "_class_wxMDIParentFrame","_wxMDIParentFrame",0},
|
||||
{ "_wxPyTreeItemData","_class_wxPyTreeItemData",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_wxStaticBoxSizer","_class_wxStaticBoxSizer",0},
|
||||
{ "_class_wxTimeSpan","_wxTimeSpan",0},
|
||||
{ "_class_wxPyFileSystemHandler","_wxPyFileSystemHandler",0},
|
||||
|
@ -2981,9 +2981,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPNMHandler","_class_wxPNMHandler",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_wxLogGui","_class_wxLogGui",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
{ "_wxSysColourChangedEvent","_class_wxSysColourChangedEvent",0},
|
||||
@ -3320,12 +3320,12 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxPyApp","_wxPyApp",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxLogTextCtrl","_wxLogTextCtrl",0},
|
||||
{ "_class_wxLogGui","_wxLogGui",0},
|
||||
{ "_class_wxMDIParentFrame","_wxMDIParentFrame",0},
|
||||
{ "_wxPyTreeItemData","_class_wxPyTreeItemData",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_wxStaticBoxSizer","_class_wxStaticBoxSizer",0},
|
||||
{ "_class_wxTimeSpan","_wxTimeSpan",0},
|
||||
{ "_class_wxPyFileSystemHandler","_wxPyFileSystemHandler",0},
|
||||
|
@ -2187,7 +2187,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxPNMHandler","_class_wxPNMHandler",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxGIFHandler","_wxGIFHandler",0},
|
||||
{ "_class_wxMask","_wxMask",0},
|
||||
{ "_class_wxPNGHandler","_wxPNGHandler",0},
|
||||
@ -2305,7 +2304,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_time_t","_size_t",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxLayoutConstraints","_wxLayoutConstraints",0},
|
||||
{ "_class_wxIcon","_wxIcon",0},
|
||||
|
@ -883,7 +883,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -1100,7 +1099,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxButton","_class_wxButton",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxMDIParentFrame","_wxMDIParentFrame",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
|
@ -361,6 +361,111 @@ static PyObject *_wrap_wxGetTextFromUser(PyObject *self, PyObject *args, PyObjec
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxGetPasswordFromUser(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxString * _result;
|
||||
wxString * _arg0;
|
||||
wxString * _arg1 = (wxString *) &wxPyEmptyStr;
|
||||
wxString * _arg2 = (wxString *) &wxPyEmptyStr;
|
||||
wxWindow * _arg3 = (wxWindow *) NULL;
|
||||
PyObject * _obj0 = 0;
|
||||
PyObject * _obj1 = 0;
|
||||
PyObject * _obj2 = 0;
|
||||
PyObject * _argo3 = 0;
|
||||
char *_kwnames[] = { "message","caption","default_value","parent", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|OOO:wxGetPasswordFromUser",_kwnames,&_obj0,&_obj1,&_obj2,&_argo3))
|
||||
return NULL;
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj0) && !PyUnicode_Check(_obj0)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj0, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg0 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj0)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg0 = new wxString(PyString_AS_STRING(_obj0), PyString_GET_SIZE(_obj0));
|
||||
#endif
|
||||
}
|
||||
if (_obj1)
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg1 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj1)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1));
|
||||
#endif
|
||||
}
|
||||
if (_obj2)
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg2 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj2)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2));
|
||||
#endif
|
||||
}
|
||||
if (_argo3) {
|
||||
if (_argo3 == Py_None) { _arg3 = NULL; }
|
||||
else if (SWIG_GetPtrObj(_argo3,(void **) &_arg3,"_wxWindow_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 4 of wxGetPasswordFromUser. Expected _wxWindow_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
{
|
||||
wxPy_BEGIN_ALLOW_THREADS;
|
||||
_result = new wxString (wxGetPasswordFromUser(*_arg0,*_arg1,*_arg2,_arg3));
|
||||
|
||||
wxPy_END_ALLOW_THREADS;
|
||||
}{
|
||||
_resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len());
|
||||
}
|
||||
{
|
||||
if (_obj0)
|
||||
delete _arg0;
|
||||
}
|
||||
{
|
||||
if (_obj1)
|
||||
delete _arg1;
|
||||
}
|
||||
{
|
||||
if (_obj2)
|
||||
delete _arg2;
|
||||
}
|
||||
{
|
||||
delete _result;
|
||||
}
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxGetSingleChoice(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxString * _result;
|
||||
@ -6594,6 +6699,7 @@ static PyMethodDef misc2cMethods[] = {
|
||||
{ "wxMessageBox", (PyCFunction) _wrap_wxMessageBox, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGetSingleChoiceIndex", (PyCFunction) _wrap_wxGetSingleChoiceIndex, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGetSingleChoice", (PyCFunction) _wrap_wxGetSingleChoice, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGetPasswordFromUser", (PyCFunction) _wrap_wxGetPasswordFromUser, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGetTextFromUser", (PyCFunction) _wrap_wxGetTextFromUser, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxFileSelector", (PyCFunction) _wrap_wxFileSelector, METH_VARARGS | METH_KEYWORDS },
|
||||
{ NULL, NULL }
|
||||
@ -6675,7 +6781,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_wxLogGui","_class_wxLogGui",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
@ -6879,7 +6984,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxLogNull","_class_wxLogNull",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxLogTextCtrl","_wxLogTextCtrl",0},
|
||||
{ "_class_wxLogGui","_wxLogGui",0},
|
||||
@ -7050,6 +7154,7 @@ SWIGEXPORT(void) initmisc2c() {
|
||||
PyDict_SetItemString(d,"wxLOG_Trace", PyInt_FromLong((long) wxLOG_Trace));
|
||||
PyDict_SetItemString(d,"wxLOG_Progress", PyInt_FromLong((long) wxLOG_Progress));
|
||||
PyDict_SetItemString(d,"wxLOG_User", PyInt_FromLong((long) wxLOG_User));
|
||||
PyDict_SetItemString(d,"wxEVT_END_PROCESS", PyInt_FromLong((long) wxEVT_END_PROCESS));
|
||||
{
|
||||
int i;
|
||||
for (i = 0; _swig_mapping[i].n1; i++)
|
||||
|
@ -620,6 +620,8 @@ wxFileSelector = misc2c.wxFileSelector
|
||||
|
||||
wxGetTextFromUser = misc2c.wxGetTextFromUser
|
||||
|
||||
wxGetPasswordFromUser = misc2c.wxGetPasswordFromUser
|
||||
|
||||
wxGetSingleChoice = misc2c.wxGetSingleChoice
|
||||
|
||||
wxGetSingleChoiceIndex = misc2c.wxGetSingleChoiceIndex
|
||||
@ -905,3 +907,4 @@ wxLOG_Debug = misc2c.wxLOG_Debug
|
||||
wxLOG_Trace = misc2c.wxLOG_Trace
|
||||
wxLOG_Progress = misc2c.wxLOG_Progress
|
||||
wxLOG_User = misc2c.wxLOG_User
|
||||
wxEVT_END_PROCESS = misc2c.wxEVT_END_PROCESS
|
||||
|
@ -761,6 +761,149 @@ static PyObject *_wrap_wxPrintData_SetQuality(PyObject *self, PyObject *args, Py
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static void *SwigwxPrinterDCTowxDC(void *ptr) {
|
||||
wxPrinterDC *src;
|
||||
wxDC *dest;
|
||||
src = (wxPrinterDC *) ptr;
|
||||
dest = (wxDC *) src;
|
||||
return (void *) dest;
|
||||
}
|
||||
|
||||
#define new_wxPrinterDC(_swigarg0) (new wxPrinterDC(_swigarg0))
|
||||
static PyObject *_wrap_new_wxPrinterDC(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxPrinterDC * _result;
|
||||
wxPrintData * _arg0;
|
||||
PyObject * _argo0 = 0;
|
||||
char *_kwnames[] = { "printData", NULL };
|
||||
char _ptemp[128];
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:new_wxPrinterDC",_kwnames,&_argo0))
|
||||
return NULL;
|
||||
if (_argo0) {
|
||||
if (_argo0 == Py_None) { _arg0 = NULL; }
|
||||
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPrintData_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of new_wxPrinterDC. Expected _wxPrintData_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
{
|
||||
wxPy_BEGIN_ALLOW_THREADS;
|
||||
_result = (wxPrinterDC *)new_wxPrinterDC(*_arg0);
|
||||
|
||||
wxPy_END_ALLOW_THREADS;
|
||||
} if (_result) {
|
||||
SWIG_MakePtr(_ptemp, (char *) _result,"_wxPrinterDC_p");
|
||||
_resultobj = Py_BuildValue("s",_ptemp);
|
||||
} else {
|
||||
Py_INCREF(Py_None);
|
||||
_resultobj = Py_None;
|
||||
}
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define new_wxPrinterDC2(_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4) (new wxPrinterDC(_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4))
|
||||
static PyObject *_wrap_new_wxPrinterDC2(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxPrinterDC * _result;
|
||||
wxString * _arg0;
|
||||
wxString * _arg1;
|
||||
wxString * _arg2;
|
||||
bool _arg3 = (bool ) TRUE;
|
||||
int _arg4 = (int ) wxPORTRAIT;
|
||||
PyObject * _obj0 = 0;
|
||||
PyObject * _obj1 = 0;
|
||||
PyObject * _obj2 = 0;
|
||||
int tempbool3 = (int) TRUE;
|
||||
char *_kwnames[] = { "driver","device","output","interactive","orientation", NULL };
|
||||
char _ptemp[128];
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO|ii:new_wxPrinterDC2",_kwnames,&_obj0,&_obj1,&_obj2,&tempbool3,&_arg4))
|
||||
return NULL;
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj0) && !PyUnicode_Check(_obj0)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj0, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg0 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj0)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg0 = new wxString(PyString_AS_STRING(_obj0), PyString_GET_SIZE(_obj0));
|
||||
#endif
|
||||
}
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj1) && !PyUnicode_Check(_obj1)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj1, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg1 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj1)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg1 = new wxString(PyString_AS_STRING(_obj1), PyString_GET_SIZE(_obj1));
|
||||
#endif
|
||||
}
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj2) && !PyUnicode_Check(_obj2)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj2, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg2 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj2)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg2 = new wxString(PyString_AS_STRING(_obj2), PyString_GET_SIZE(_obj2));
|
||||
#endif
|
||||
}
|
||||
_arg3 = (bool ) tempbool3;
|
||||
{
|
||||
wxPy_BEGIN_ALLOW_THREADS;
|
||||
_result = (wxPrinterDC *)new_wxPrinterDC2(*_arg0,*_arg1,*_arg2,_arg3,_arg4);
|
||||
|
||||
wxPy_END_ALLOW_THREADS;
|
||||
} if (_result) {
|
||||
SWIG_MakePtr(_ptemp, (char *) _result,"_wxPrinterDC_p");
|
||||
_resultobj = Py_BuildValue("s",_ptemp);
|
||||
} else {
|
||||
Py_INCREF(Py_None);
|
||||
_resultobj = Py_None;
|
||||
}
|
||||
{
|
||||
if (_obj0)
|
||||
delete _arg0;
|
||||
}
|
||||
{
|
||||
if (_obj1)
|
||||
delete _arg1;
|
||||
}
|
||||
{
|
||||
if (_obj2)
|
||||
delete _arg2;
|
||||
}
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define new_wxPageSetupDialogData() (new wxPageSetupDialogData())
|
||||
static PyObject *_wrap_new_wxPageSetupDialogData(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
@ -4335,6 +4478,8 @@ static PyMethodDef printfwcMethods[] = {
|
||||
{ "wxPageSetupDialogData_EnableHelp", (PyCFunction) _wrap_wxPageSetupDialogData_EnableHelp, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "delete_wxPageSetupDialogData", (PyCFunction) _wrap_delete_wxPageSetupDialogData, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "new_wxPageSetupDialogData", (PyCFunction) _wrap_new_wxPageSetupDialogData, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "new_wxPrinterDC2", (PyCFunction) _wrap_new_wxPrinterDC2, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "new_wxPrinterDC", (PyCFunction) _wrap_new_wxPrinterDC, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPrintData_SetQuality", (PyCFunction) _wrap_wxPrintData_SetQuality, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPrintData_SetPaperSize", (PyCFunction) _wrap_wxPrintData_SetPaperSize, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPrintData_SetPaperId", (PyCFunction) _wrap_wxPrintData_SetPaperId, METH_VARARGS | METH_KEYWORDS },
|
||||
@ -4423,6 +4568,8 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxAcceleratorTable","_wxAcceleratorTable",0},
|
||||
{ "_class_wxClipboard","_wxClipboard",0},
|
||||
{ "_class_wxGauge","_wxGauge",0},
|
||||
{ "_wxDC","_class_wxPrinterDC",SwigwxPrinterDCTowxDC},
|
||||
{ "_wxDC","_wxPrinterDC",SwigwxPrinterDCTowxDC},
|
||||
{ "_wxDC","_class_wxDC",0},
|
||||
{ "_class_wxBitmapDataObject","_wxBitmapDataObject",0},
|
||||
{ "_class_wxSingleChoiceDialog","_wxSingleChoiceDialog",0},
|
||||
@ -4438,8 +4585,8 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
{ "_wxSysColourChangedEvent","_class_wxSysColourChangedEvent",0},
|
||||
@ -4534,6 +4681,8 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxCloseEvent","_class_wxCloseEvent",0},
|
||||
{ "_unsigned_long","_long",0},
|
||||
{ "_class_wxRect","_wxRect",0},
|
||||
{ "_class_wxDC","_class_wxPrinterDC",SwigwxPrinterDCTowxDC},
|
||||
{ "_class_wxDC","_wxPrinterDC",SwigwxPrinterDCTowxDC},
|
||||
{ "_class_wxDC","_wxDC",0},
|
||||
{ "_wxScrollWinEvent","_class_wxScrollWinEvent",0},
|
||||
{ "_class_wxProgressDialog","_wxProgressDialog",0},
|
||||
@ -4684,8 +4833,8 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxButton","_class_wxButton",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxSysColourChangedEvent","_wxSysColourChangedEvent",0},
|
||||
{ "_class_wxPyFileDropTarget","_wxPyFileDropTarget",0},
|
||||
|
@ -91,6 +91,25 @@ class wxPrintData(wxPrintDataPtr):
|
||||
|
||||
|
||||
|
||||
class wxPrinterDCPtr(wxDCPtr):
|
||||
def __init__(self,this):
|
||||
self.this = this
|
||||
self.thisown = 0
|
||||
def __repr__(self):
|
||||
return "<C wxPrinterDC instance at %s>" % (self.this,)
|
||||
class wxPrinterDC(wxPrinterDCPtr):
|
||||
def __init__(self,*_args,**_kwargs):
|
||||
self.this = apply(printfwc.new_wxPrinterDC,_args,_kwargs)
|
||||
self.thisown = 1
|
||||
|
||||
|
||||
|
||||
def wxPrinterDC2(*_args,**_kwargs):
|
||||
val = wxPrinterDCPtr(apply(printfwc.new_wxPrinterDC2,_args,_kwargs))
|
||||
val.thisown = 1
|
||||
return val
|
||||
|
||||
|
||||
class wxPageSetupDialogDataPtr :
|
||||
def __init__(self,this):
|
||||
self.this = this
|
||||
|
@ -2891,7 +2891,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -3096,7 +3095,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxButton","_class_wxButton",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_wxStaticBoxSizer","_class_wxStaticBoxSizer",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
|
@ -3331,7 +3331,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -3546,7 +3545,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxButton","_class_wxButton",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxSysColourChangedEvent","_wxSysColourChangedEvent",0},
|
||||
|
@ -9462,7 +9462,54 @@ static PyObject *_wrap_wxMenuItem_SetAccel(PyObject *self, PyObject *args, PyObj
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxMenuItem_GetLabelFromText(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxString * _result;
|
||||
wxString * _arg0;
|
||||
PyObject * _obj0 = 0;
|
||||
char *_kwnames[] = { "text", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxMenuItem_GetLabelFromText",_kwnames,&_obj0))
|
||||
return NULL;
|
||||
{
|
||||
#if PYTHON_API_VERSION >= 1009
|
||||
char* tmpPtr; int tmpSize;
|
||||
if (!PyString_Check(_obj0) && !PyUnicode_Check(_obj0)) {
|
||||
PyErr_SetString(PyExc_TypeError, "String or Unicode type required");
|
||||
return NULL;
|
||||
}
|
||||
if (PyString_AsStringAndSize(_obj0, &tmpPtr, &tmpSize) == -1)
|
||||
return NULL;
|
||||
_arg0 = new wxString(tmpPtr, tmpSize);
|
||||
#else
|
||||
if (!PyString_Check(_obj0)) {
|
||||
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
|
||||
return NULL;
|
||||
}
|
||||
_arg0 = new wxString(PyString_AS_STRING(_obj0), PyString_GET_SIZE(_obj0));
|
||||
#endif
|
||||
}
|
||||
{
|
||||
wxPy_BEGIN_ALLOW_THREADS;
|
||||
_result = new wxString (wxMenuItem::GetLabelFromText(*_arg0));
|
||||
|
||||
wxPy_END_ALLOW_THREADS;
|
||||
}{
|
||||
_resultobj = PyString_FromStringAndSize(_result->c_str(), _result->Len());
|
||||
}
|
||||
{
|
||||
if (_obj0)
|
||||
delete _arg0;
|
||||
}
|
||||
{
|
||||
delete _result;
|
||||
}
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyMethodDef windowscMethods[] = {
|
||||
{ "wxMenuItem_GetLabelFromText", (PyCFunction) _wrap_wxMenuItem_GetLabelFromText, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxMenuItem_SetAccel", (PyCFunction) _wrap_wxMenuItem_SetAccel, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxMenuItem_GetAccel", (PyCFunction) _wrap_wxMenuItem_GetAccel, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxMenuItem_GetHelp", (PyCFunction) _wrap_wxMenuItem_GetHelp, METH_VARARGS | METH_KEYWORDS },
|
||||
@ -9791,7 +9838,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_wxWindowID",0},
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_wxPanel","_class_wxScrolledWindow",SwigwxScrolledWindowTowxPanel},
|
||||
{ "_wxPanel","_wxScrolledWindow",SwigwxScrolledWindowTowxPanel},
|
||||
@ -9934,7 +9980,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_time_t","_size_t",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxPyFileDropTarget","_wxPyFileDropTarget",0},
|
||||
|
@ -1000,6 +1000,8 @@ wxWindow_NextControlId = windowsc.wxWindow_NextControlId
|
||||
|
||||
wxWindow_PrevControlId = windowsc.wxWindow_PrevControlId
|
||||
|
||||
wxMenuItem_GetLabelFromText = windowsc.wxMenuItem_GetLabelFromText
|
||||
|
||||
|
||||
|
||||
#-------------- VARIABLE WRAPPERS ------------------
|
||||
|
@ -2185,7 +2185,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -2403,7 +2402,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxButton","_class_wxButton",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
{ "_class_wxSysColourChangedEvent","_wxSysColourChangedEvent",0},
|
||||
@ -2489,6 +2487,12 @@ SWIGEXPORT(void) initwindows2c() {
|
||||
SWIG_globals = SWIG_newvarlink();
|
||||
m = Py_InitModule("windows2c", windows2cMethods);
|
||||
d = PyModule_GetDict(m);
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED", PyInt_FromLong((long) wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING", PyInt_FromLong((long) wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING", PyInt_FromLong((long) wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED", PyInt_FromLong((long) wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_SPLITTER_UNSPLIT", PyInt_FromLong((long) wxEVT_COMMAND_SPLITTER_UNSPLIT));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_SPLITTER_DOUBLECLICKED", PyInt_FromLong((long) wxEVT_COMMAND_SPLITTER_DOUBLECLICKED));
|
||||
PyDict_SetItemString(d,"wxSPLIT_HORIZONTAL", PyInt_FromLong((long) wxSPLIT_HORIZONTAL));
|
||||
PyDict_SetItemString(d,"wxSPLIT_VERTICAL", PyInt_FromLong((long) wxSPLIT_VERTICAL));
|
||||
PyDict_SetItemString(d,"wxSPLIT_DRAG_NONE", PyInt_FromLong((long) wxSPLIT_DRAG_NONE));
|
||||
|
@ -262,6 +262,12 @@ class wxTaskBarIcon(wxTaskBarIconPtr):
|
||||
|
||||
#-------------- VARIABLE WRAPPERS ------------------
|
||||
|
||||
wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED = windows2c.wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED
|
||||
wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING = windows2c.wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING
|
||||
wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING = windows2c.wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING
|
||||
wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED = windows2c.wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED
|
||||
wxEVT_COMMAND_SPLITTER_UNSPLIT = windows2c.wxEVT_COMMAND_SPLITTER_UNSPLIT
|
||||
wxEVT_COMMAND_SPLITTER_DOUBLECLICKED = windows2c.wxEVT_COMMAND_SPLITTER_DOUBLECLICKED
|
||||
wxSPLIT_HORIZONTAL = windows2c.wxSPLIT_HORIZONTAL
|
||||
wxSPLIT_VERTICAL = windows2c.wxSPLIT_VERTICAL
|
||||
wxSPLIT_DRAG_NONE = windows2c.wxSPLIT_DRAG_NONE
|
||||
|
@ -1810,7 +1810,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_size_t","_uint",0},
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
@ -2047,7 +2046,6 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_wxButton","_class_wxButton",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxMDIParentFrame","_wxMDIParentFrame",0},
|
||||
{ "_class_wxPaintDC","_wxPaintDC",0},
|
||||
@ -2141,6 +2139,9 @@ SWIGEXPORT(void) initwindows3c() {
|
||||
PyDict_SetItemString(d,"wxSASH_NONE", PyInt_FromLong((long) wxSASH_NONE));
|
||||
PyDict_SetItemString(d,"wxEVT_SASH_DRAGGED", PyInt_FromLong((long) wxEVT_SASH_DRAGGED));
|
||||
PyDict_SetItemString(d,"wxSW_3D", PyInt_FromLong((long) wxSW_3D));
|
||||
PyDict_SetItemString(d,"wxSW_3DSASH", PyInt_FromLong((long) wxSW_3DSASH));
|
||||
PyDict_SetItemString(d,"wxSW_3DBORDER", PyInt_FromLong((long) wxSW_3DBORDER));
|
||||
PyDict_SetItemString(d,"wxSW_BORDER", PyInt_FromLong((long) wxSW_BORDER));
|
||||
PyDict_SetItemString(d,"wxSASH_STATUS_OK", PyInt_FromLong((long) wxSASH_STATUS_OK));
|
||||
PyDict_SetItemString(d,"wxSASH_STATUS_OUT_OF_RANGE", PyInt_FromLong((long) wxSASH_STATUS_OUT_OF_RANGE));
|
||||
PyDict_SetItemString(d,"wxLAYOUT_HORIZONTAL", PyInt_FromLong((long) wxLAYOUT_HORIZONTAL));
|
||||
|
@ -262,6 +262,9 @@ wxSASH_LEFT = windows3c.wxSASH_LEFT
|
||||
wxSASH_NONE = windows3c.wxSASH_NONE
|
||||
wxEVT_SASH_DRAGGED = windows3c.wxEVT_SASH_DRAGGED
|
||||
wxSW_3D = windows3c.wxSW_3D
|
||||
wxSW_3DSASH = windows3c.wxSW_3DSASH
|
||||
wxSW_3DBORDER = windows3c.wxSW_3DBORDER
|
||||
wxSW_BORDER = windows3c.wxSW_BORDER
|
||||
wxSASH_STATUS_OK = windows3c.wxSASH_STATUS_OK
|
||||
wxSASH_STATUS_OUT_OF_RANGE = windows3c.wxSASH_STATUS_OUT_OF_RANGE
|
||||
wxLAYOUT_HORIZONTAL = windows3c.wxLAYOUT_HORIZONTAL
|
||||
|
@ -1886,9 +1886,9 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxRealPoint","_wxRealPoint",0},
|
||||
{ "_wxNavigationKeyEvent","_class_wxNavigationKeyEvent",0},
|
||||
{ "_wxPNMHandler","_class_wxPNMHandler",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_wxWindowCreateEvent","_class_wxWindowCreateEvent",0},
|
||||
{ "_wxLogGui","_class_wxLogGui",0},
|
||||
{ "_wxPrinterDC","_class_wxPrinterDC",0},
|
||||
{ "_class_wxMenuItem","_wxMenuItem",0},
|
||||
{ "_class_wxPaintEvent","_wxPaintEvent",0},
|
||||
{ "_wxSysColourChangedEvent","_class_wxSysColourChangedEvent",0},
|
||||
@ -2195,12 +2195,12 @@ static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
|
||||
{ "_class_wxPyApp","_wxPyApp",0},
|
||||
{ "_wxSize","_class_wxSize",0},
|
||||
{ "_wxRegionIterator","_class_wxRegionIterator",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_class_wxPyTextDataObject","_wxPyTextDataObject",0},
|
||||
{ "_class_wxLogTextCtrl","_wxLogTextCtrl",0},
|
||||
{ "_class_wxLogGui","_wxLogGui",0},
|
||||
{ "_class_wxMDIParentFrame","_wxMDIParentFrame",0},
|
||||
{ "_wxPyTreeItemData","_class_wxPyTreeItemData",0},
|
||||
{ "_class_wxPrinterDC","_wxPrinterDC",0},
|
||||
{ "_wxStaticBoxSizer","_class_wxStaticBoxSizer",0},
|
||||
{ "_class_wxTimeSpan","_wxTimeSpan",0},
|
||||
{ "_class_wxPyFileSystemHandler","_wxPyFileSystemHandler",0},
|
||||
@ -2356,6 +2356,8 @@ SWIGEXPORT(void) initwxc() {
|
||||
PyDict_SetItemString(d,"wxFRAME_TOOL_WINDOW", PyInt_FromLong((long) wxFRAME_TOOL_WINDOW));
|
||||
PyDict_SetItemString(d,"wxFRAME_FLOAT_ON_PARENT", PyInt_FromLong((long) wxFRAME_FLOAT_ON_PARENT));
|
||||
PyDict_SetItemString(d,"wxFRAME_NO_WINDOW_MENU", PyInt_FromLong((long) wxFRAME_NO_WINDOW_MENU));
|
||||
PyDict_SetItemString(d,"wxFRAME_NO_TASKBAR", PyInt_FromLong((long) wxFRAME_NO_TASKBAR));
|
||||
PyDict_SetItemString(d,"wxFRAME_EX_CONTEXTHELP", PyInt_FromLong((long) wxFRAME_EX_CONTEXTHELP));
|
||||
PyDict_SetItemString(d,"wxED_CLIENT_MARGIN", PyInt_FromLong((long) wxED_CLIENT_MARGIN));
|
||||
PyDict_SetItemString(d,"wxED_BUTTONS_BOTTOM", PyInt_FromLong((long) wxED_BUTTONS_BOTTOM));
|
||||
PyDict_SetItemString(d,"wxED_BUTTONS_RIGHT", PyInt_FromLong((long) wxED_BUTTONS_RIGHT));
|
||||
@ -2382,6 +2384,7 @@ SWIGEXPORT(void) initwxc() {
|
||||
PyDict_SetItemString(d,"wxALIGN_CENTER", PyInt_FromLong((long) wxALIGN_CENTER));
|
||||
PyDict_SetItemString(d,"wxALIGN_CENTRE", PyInt_FromLong((long) wxALIGN_CENTRE));
|
||||
PyDict_SetItemString(d,"wxSHAPED", PyInt_FromLong((long) wxSHAPED));
|
||||
PyDict_SetItemString(d,"wxADJUST_MINSIZE", PyInt_FromLong((long) wxADJUST_MINSIZE));
|
||||
PyDict_SetItemString(d,"wxLB_NEEDED_SB", PyInt_FromLong((long) wxLB_NEEDED_SB));
|
||||
PyDict_SetItemString(d,"wxLB_ALWAYS_SB", PyInt_FromLong((long) wxLB_ALWAYS_SB));
|
||||
PyDict_SetItemString(d,"wxLB_SORT", PyInt_FromLong((long) wxLB_SORT));
|
||||
@ -2452,12 +2455,17 @@ SWIGEXPORT(void) initwxc() {
|
||||
PyDict_SetItemString(d,"wxLC_MASK_TYPE", PyInt_FromLong((long) wxLC_MASK_TYPE));
|
||||
PyDict_SetItemString(d,"wxLC_MASK_ALIGN", PyInt_FromLong((long) wxLC_MASK_ALIGN));
|
||||
PyDict_SetItemString(d,"wxLC_MASK_SORT", PyInt_FromLong((long) wxLC_MASK_SORT));
|
||||
PyDict_SetItemString(d,"wxLC_HRULES", PyInt_FromLong((long) wxLC_HRULES));
|
||||
PyDict_SetItemString(d,"wxLC_VRULES", PyInt_FromLong((long) wxLC_VRULES));
|
||||
PyDict_SetItemString(d,"wxSP_VERTICAL", PyInt_FromLong((long) wxSP_VERTICAL));
|
||||
PyDict_SetItemString(d,"wxSP_HORIZONTAL", PyInt_FromLong((long) wxSP_HORIZONTAL));
|
||||
PyDict_SetItemString(d,"wxSP_ARROW_KEYS", PyInt_FromLong((long) wxSP_ARROW_KEYS));
|
||||
PyDict_SetItemString(d,"wxSP_WRAP", PyInt_FromLong((long) wxSP_WRAP));
|
||||
PyDict_SetItemString(d,"wxSP_NOBORDER", PyInt_FromLong((long) wxSP_NOBORDER));
|
||||
PyDict_SetItemString(d,"wxSP_3D", PyInt_FromLong((long) wxSP_3D));
|
||||
PyDict_SetItemString(d,"wxSP_3DSASH", PyInt_FromLong((long) wxSP_3DSASH));
|
||||
PyDict_SetItemString(d,"wxSP_3DBORDER", PyInt_FromLong((long) wxSP_3DBORDER));
|
||||
PyDict_SetItemString(d,"wxSP_FULLSASH", PyInt_FromLong((long) wxSP_FULLSASH));
|
||||
PyDict_SetItemString(d,"wxSP_BORDER", PyInt_FromLong((long) wxSP_BORDER));
|
||||
PyDict_SetItemString(d,"wxSP_LIVE_UPDATE", PyInt_FromLong((long) wxSP_LIVE_UPDATE));
|
||||
PyDict_SetItemString(d,"wxSP_PERMIT_UNSPLIT", PyInt_FromLong((long) wxSP_PERMIT_UNSPLIT));
|
||||
@ -2569,6 +2577,7 @@ SWIGEXPORT(void) initwxc() {
|
||||
PyDict_SetItemString(d,"wxOVERWRITE_PROMPT", PyInt_FromLong((long) wxOVERWRITE_PROMPT));
|
||||
PyDict_SetItemString(d,"wxFILE_MUST_EXIST", PyInt_FromLong((long) wxFILE_MUST_EXIST));
|
||||
PyDict_SetItemString(d,"wxMULTIPLE", PyInt_FromLong((long) wxMULTIPLE));
|
||||
PyDict_SetItemString(d,"wxCHANGE_DIR", PyInt_FromLong((long) wxCHANGE_DIR));
|
||||
PyDict_SetItemString(d,"wxACCEL_ALT", PyInt_FromLong((long) wxACCEL_ALT));
|
||||
PyDict_SetItemString(d,"wxACCEL_CTRL", PyInt_FromLong((long) wxACCEL_CTRL));
|
||||
PyDict_SetItemString(d,"wxACCEL_SHIFT", PyInt_FromLong((long) wxACCEL_SHIFT));
|
||||
@ -2950,50 +2959,8 @@ SWIGEXPORT(void) initwxc() {
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_SET_FOCUS", PyInt_FromLong((long) wxEVT_COMMAND_SET_FOCUS));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_KILL_FOCUS", PyInt_FromLong((long) wxEVT_COMMAND_KILL_FOCUS));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_ENTER", PyInt_FromLong((long) wxEVT_COMMAND_ENTER));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_BEGIN_DRAG", PyInt_FromLong((long) wxEVT_COMMAND_TREE_BEGIN_DRAG));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_BEGIN_RDRAG", PyInt_FromLong((long) wxEVT_COMMAND_TREE_BEGIN_RDRAG));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT", PyInt_FromLong((long) wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_END_LABEL_EDIT", PyInt_FromLong((long) wxEVT_COMMAND_TREE_END_LABEL_EDIT));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_DELETE_ITEM", PyInt_FromLong((long) wxEVT_COMMAND_TREE_DELETE_ITEM));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_GET_INFO", PyInt_FromLong((long) wxEVT_COMMAND_TREE_GET_INFO));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_SET_INFO", PyInt_FromLong((long) wxEVT_COMMAND_TREE_SET_INFO));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_EXPANDED", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_EXPANDED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_EXPANDING", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_EXPANDING));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_COLLAPSED", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_COLLAPSED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_COLLAPSING", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_COLLAPSING));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_SEL_CHANGED", PyInt_FromLong((long) wxEVT_COMMAND_TREE_SEL_CHANGED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_SEL_CHANGING", PyInt_FromLong((long) wxEVT_COMMAND_TREE_SEL_CHANGING));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_KEY_DOWN", PyInt_FromLong((long) wxEVT_COMMAND_TREE_KEY_DOWN));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_ACTIVATED", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_ACTIVATED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_BEGIN_DRAG", PyInt_FromLong((long) wxEVT_COMMAND_LIST_BEGIN_DRAG));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_BEGIN_RDRAG", PyInt_FromLong((long) wxEVT_COMMAND_LIST_BEGIN_RDRAG));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT", PyInt_FromLong((long) wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_END_LABEL_EDIT", PyInt_FromLong((long) wxEVT_COMMAND_LIST_END_LABEL_EDIT));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_DELETE_ITEM", PyInt_FromLong((long) wxEVT_COMMAND_LIST_DELETE_ITEM));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS", PyInt_FromLong((long) wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_GET_INFO", PyInt_FromLong((long) wxEVT_COMMAND_LIST_GET_INFO));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_SET_INFO", PyInt_FromLong((long) wxEVT_COMMAND_LIST_SET_INFO));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_ITEM_SELECTED", PyInt_FromLong((long) wxEVT_COMMAND_LIST_ITEM_SELECTED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_ITEM_DESELECTED", PyInt_FromLong((long) wxEVT_COMMAND_LIST_ITEM_DESELECTED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_KEY_DOWN", PyInt_FromLong((long) wxEVT_COMMAND_LIST_KEY_DOWN));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_INSERT_ITEM", PyInt_FromLong((long) wxEVT_COMMAND_LIST_INSERT_ITEM));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_COL_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_LIST_COL_CLICK));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_ITEM_ACTIVATED", PyInt_FromLong((long) wxEVT_COMMAND_LIST_ITEM_ACTIVATED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK", PyInt_FromLong((long) wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TAB_SEL_CHANGED", PyInt_FromLong((long) wxEVT_COMMAND_TAB_SEL_CHANGED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_TAB_SEL_CHANGING", PyInt_FromLong((long) wxEVT_COMMAND_TAB_SEL_CHANGING));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED", PyInt_FromLong((long) wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING", PyInt_FromLong((long) wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING", PyInt_FromLong((long) wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED", PyInt_FromLong((long) wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_SPLITTER_UNSPLIT", PyInt_FromLong((long) wxEVT_COMMAND_SPLITTER_UNSPLIT));
|
||||
PyDict_SetItemString(d,"wxEVT_COMMAND_SPLITTER_DOUBLECLICKED", PyInt_FromLong((long) wxEVT_COMMAND_SPLITTER_DOUBLECLICKED));
|
||||
PyDict_SetItemString(d,"wxEVT_NAVIGATION_KEY", PyInt_FromLong((long) wxEVT_NAVIGATION_KEY));
|
||||
PyDict_SetItemString(d,"wxEVT_TIMER", PyInt_FromLong((long) wxEVT_TIMER));
|
||||
PyDict_SetItemString(d,"wxEVT_END_PROCESS", PyInt_FromLong((long) wxEVT_END_PROCESS));
|
||||
PyDict_SetItemString(d,"__version__", PyString_FromString("0.0.0"));
|
||||
PyDict_SetItemString(d,"cvar", SWIG_globals);
|
||||
SWIG_addvarlink(SWIG_globals,"wxDefaultPosition",_wrap_wxDefaultPosition_get, _wrap_wxDefaultPosition_set);
|
||||
|
@ -205,6 +205,8 @@ wxDEFAULT_DIALOG_STYLE = wxc.wxDEFAULT_DIALOG_STYLE
|
||||
wxFRAME_TOOL_WINDOW = wxc.wxFRAME_TOOL_WINDOW
|
||||
wxFRAME_FLOAT_ON_PARENT = wxc.wxFRAME_FLOAT_ON_PARENT
|
||||
wxFRAME_NO_WINDOW_MENU = wxc.wxFRAME_NO_WINDOW_MENU
|
||||
wxFRAME_NO_TASKBAR = wxc.wxFRAME_NO_TASKBAR
|
||||
wxFRAME_EX_CONTEXTHELP = wxc.wxFRAME_EX_CONTEXTHELP
|
||||
wxED_CLIENT_MARGIN = wxc.wxED_CLIENT_MARGIN
|
||||
wxED_BUTTONS_BOTTOM = wxc.wxED_BUTTONS_BOTTOM
|
||||
wxED_BUTTONS_RIGHT = wxc.wxED_BUTTONS_RIGHT
|
||||
@ -231,6 +233,7 @@ wxALIGN_TOP = wxc.wxALIGN_TOP
|
||||
wxALIGN_CENTER = wxc.wxALIGN_CENTER
|
||||
wxALIGN_CENTRE = wxc.wxALIGN_CENTRE
|
||||
wxSHAPED = wxc.wxSHAPED
|
||||
wxADJUST_MINSIZE = wxc.wxADJUST_MINSIZE
|
||||
wxLB_NEEDED_SB = wxc.wxLB_NEEDED_SB
|
||||
wxLB_ALWAYS_SB = wxc.wxLB_ALWAYS_SB
|
||||
wxLB_SORT = wxc.wxLB_SORT
|
||||
@ -301,12 +304,17 @@ wxLC_SORT_DESCENDING = wxc.wxLC_SORT_DESCENDING
|
||||
wxLC_MASK_TYPE = wxc.wxLC_MASK_TYPE
|
||||
wxLC_MASK_ALIGN = wxc.wxLC_MASK_ALIGN
|
||||
wxLC_MASK_SORT = wxc.wxLC_MASK_SORT
|
||||
wxLC_HRULES = wxc.wxLC_HRULES
|
||||
wxLC_VRULES = wxc.wxLC_VRULES
|
||||
wxSP_VERTICAL = wxc.wxSP_VERTICAL
|
||||
wxSP_HORIZONTAL = wxc.wxSP_HORIZONTAL
|
||||
wxSP_ARROW_KEYS = wxc.wxSP_ARROW_KEYS
|
||||
wxSP_WRAP = wxc.wxSP_WRAP
|
||||
wxSP_NOBORDER = wxc.wxSP_NOBORDER
|
||||
wxSP_3D = wxc.wxSP_3D
|
||||
wxSP_3DSASH = wxc.wxSP_3DSASH
|
||||
wxSP_3DBORDER = wxc.wxSP_3DBORDER
|
||||
wxSP_FULLSASH = wxc.wxSP_FULLSASH
|
||||
wxSP_BORDER = wxc.wxSP_BORDER
|
||||
wxSP_LIVE_UPDATE = wxc.wxSP_LIVE_UPDATE
|
||||
wxSP_PERMIT_UNSPLIT = wxc.wxSP_PERMIT_UNSPLIT
|
||||
@ -418,6 +426,7 @@ wxHIDE_READONLY = wxc.wxHIDE_READONLY
|
||||
wxOVERWRITE_PROMPT = wxc.wxOVERWRITE_PROMPT
|
||||
wxFILE_MUST_EXIST = wxc.wxFILE_MUST_EXIST
|
||||
wxMULTIPLE = wxc.wxMULTIPLE
|
||||
wxCHANGE_DIR = wxc.wxCHANGE_DIR
|
||||
wxACCEL_ALT = wxc.wxACCEL_ALT
|
||||
wxACCEL_CTRL = wxc.wxACCEL_CTRL
|
||||
wxACCEL_SHIFT = wxc.wxACCEL_SHIFT
|
||||
@ -799,50 +808,8 @@ wxEVT_COMMAND_RIGHT_DCLICK = wxc.wxEVT_COMMAND_RIGHT_DCLICK
|
||||
wxEVT_COMMAND_SET_FOCUS = wxc.wxEVT_COMMAND_SET_FOCUS
|
||||
wxEVT_COMMAND_KILL_FOCUS = wxc.wxEVT_COMMAND_KILL_FOCUS
|
||||
wxEVT_COMMAND_ENTER = wxc.wxEVT_COMMAND_ENTER
|
||||
wxEVT_COMMAND_TREE_BEGIN_DRAG = wxc.wxEVT_COMMAND_TREE_BEGIN_DRAG
|
||||
wxEVT_COMMAND_TREE_BEGIN_RDRAG = wxc.wxEVT_COMMAND_TREE_BEGIN_RDRAG
|
||||
wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT = wxc.wxEVT_COMMAND_TREE_BEGIN_LABEL_EDIT
|
||||
wxEVT_COMMAND_TREE_END_LABEL_EDIT = wxc.wxEVT_COMMAND_TREE_END_LABEL_EDIT
|
||||
wxEVT_COMMAND_TREE_DELETE_ITEM = wxc.wxEVT_COMMAND_TREE_DELETE_ITEM
|
||||
wxEVT_COMMAND_TREE_GET_INFO = wxc.wxEVT_COMMAND_TREE_GET_INFO
|
||||
wxEVT_COMMAND_TREE_SET_INFO = wxc.wxEVT_COMMAND_TREE_SET_INFO
|
||||
wxEVT_COMMAND_TREE_ITEM_EXPANDED = wxc.wxEVT_COMMAND_TREE_ITEM_EXPANDED
|
||||
wxEVT_COMMAND_TREE_ITEM_EXPANDING = wxc.wxEVT_COMMAND_TREE_ITEM_EXPANDING
|
||||
wxEVT_COMMAND_TREE_ITEM_COLLAPSED = wxc.wxEVT_COMMAND_TREE_ITEM_COLLAPSED
|
||||
wxEVT_COMMAND_TREE_ITEM_COLLAPSING = wxc.wxEVT_COMMAND_TREE_ITEM_COLLAPSING
|
||||
wxEVT_COMMAND_TREE_SEL_CHANGED = wxc.wxEVT_COMMAND_TREE_SEL_CHANGED
|
||||
wxEVT_COMMAND_TREE_SEL_CHANGING = wxc.wxEVT_COMMAND_TREE_SEL_CHANGING
|
||||
wxEVT_COMMAND_TREE_KEY_DOWN = wxc.wxEVT_COMMAND_TREE_KEY_DOWN
|
||||
wxEVT_COMMAND_TREE_ITEM_ACTIVATED = wxc.wxEVT_COMMAND_TREE_ITEM_ACTIVATED
|
||||
wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK = wxc.wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK
|
||||
wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK = wxc.wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK
|
||||
wxEVT_COMMAND_LIST_BEGIN_DRAG = wxc.wxEVT_COMMAND_LIST_BEGIN_DRAG
|
||||
wxEVT_COMMAND_LIST_BEGIN_RDRAG = wxc.wxEVT_COMMAND_LIST_BEGIN_RDRAG
|
||||
wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT = wxc.wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT
|
||||
wxEVT_COMMAND_LIST_END_LABEL_EDIT = wxc.wxEVT_COMMAND_LIST_END_LABEL_EDIT
|
||||
wxEVT_COMMAND_LIST_DELETE_ITEM = wxc.wxEVT_COMMAND_LIST_DELETE_ITEM
|
||||
wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS = wxc.wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS
|
||||
wxEVT_COMMAND_LIST_GET_INFO = wxc.wxEVT_COMMAND_LIST_GET_INFO
|
||||
wxEVT_COMMAND_LIST_SET_INFO = wxc.wxEVT_COMMAND_LIST_SET_INFO
|
||||
wxEVT_COMMAND_LIST_ITEM_SELECTED = wxc.wxEVT_COMMAND_LIST_ITEM_SELECTED
|
||||
wxEVT_COMMAND_LIST_ITEM_DESELECTED = wxc.wxEVT_COMMAND_LIST_ITEM_DESELECTED
|
||||
wxEVT_COMMAND_LIST_KEY_DOWN = wxc.wxEVT_COMMAND_LIST_KEY_DOWN
|
||||
wxEVT_COMMAND_LIST_INSERT_ITEM = wxc.wxEVT_COMMAND_LIST_INSERT_ITEM
|
||||
wxEVT_COMMAND_LIST_COL_CLICK = wxc.wxEVT_COMMAND_LIST_COL_CLICK
|
||||
wxEVT_COMMAND_LIST_ITEM_ACTIVATED = wxc.wxEVT_COMMAND_LIST_ITEM_ACTIVATED
|
||||
wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK = wxc.wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK
|
||||
wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK = wxc.wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK
|
||||
wxEVT_COMMAND_TAB_SEL_CHANGED = wxc.wxEVT_COMMAND_TAB_SEL_CHANGED
|
||||
wxEVT_COMMAND_TAB_SEL_CHANGING = wxc.wxEVT_COMMAND_TAB_SEL_CHANGING
|
||||
wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED = wxc.wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED
|
||||
wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING = wxc.wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING
|
||||
wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING = wxc.wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING
|
||||
wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED = wxc.wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED
|
||||
wxEVT_COMMAND_SPLITTER_UNSPLIT = wxc.wxEVT_COMMAND_SPLITTER_UNSPLIT
|
||||
wxEVT_COMMAND_SPLITTER_DOUBLECLICKED = wxc.wxEVT_COMMAND_SPLITTER_DOUBLECLICKED
|
||||
wxEVT_NAVIGATION_KEY = wxc.wxEVT_NAVIGATION_KEY
|
||||
wxEVT_TIMER = wxc.wxEVT_TIMER
|
||||
wxEVT_END_PROCESS = wxc.wxEVT_END_PROCESS
|
||||
__version__ = wxc.__version__
|
||||
cvar = wxc.cvar
|
||||
wxDefaultPosition = wxPointPtr(wxc.cvar.wxDefaultPosition)
|
||||
|
@ -98,6 +98,20 @@ public:
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
|
||||
#ifdef __WXMSW__
|
||||
class wxPrinterDC : public wxDC {
|
||||
public:
|
||||
wxPrinterDC(const wxPrintData& printData);
|
||||
%name(wxPrinterDC2) wxPrinterDC(const wxString& driver,
|
||||
const wxString& device,
|
||||
const wxString& output,
|
||||
bool interactive = TRUE,
|
||||
int orientation = wxPORTRAIT);
|
||||
};
|
||||
#endif
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
class wxPageSetupDialogData {
|
||||
public:
|
||||
wxPageSetupDialogData();
|
||||
|
@ -709,6 +709,10 @@ public:
|
||||
wxAcceleratorEntry *GetAccel();
|
||||
void SetAccel(wxAcceleratorEntry *accel);
|
||||
|
||||
static wxString GetLabelFromText(const wxString& text);
|
||||
|
||||
// TODO: Add wxOwnerDrawn methods, also look at other ownerdrawn classes...
|
||||
|
||||
};
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
|
@ -242,6 +242,13 @@ enum {
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
enum {
|
||||
/* notebook control event types */
|
||||
wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED,
|
||||
wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING,
|
||||
};
|
||||
|
||||
|
||||
class wxNotebookEvent : public wxNotifyEvent {
|
||||
public:
|
||||
int GetSelection();
|
||||
@ -304,6 +311,15 @@ public:
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
|
||||
enum {
|
||||
/* splitter window events */
|
||||
wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING,
|
||||
wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED,
|
||||
wxEVT_COMMAND_SPLITTER_UNSPLIT,
|
||||
wxEVT_COMMAND_SPLITTER_DOUBLECLICKED,
|
||||
};
|
||||
|
||||
|
||||
enum
|
||||
{
|
||||
wxSPLIT_HORIZONTAL,
|
||||
@ -311,7 +327,6 @@ enum
|
||||
wxSPLIT_DRAG_NONE,
|
||||
wxSPLIT_DRAG_DRAGGING,
|
||||
wxSPLIT_DRAG_LEFT_DOWN
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
@ -47,6 +47,9 @@ enum wxSashEdgePosition {
|
||||
enum {
|
||||
wxEVT_SASH_DRAGGED,
|
||||
wxSW_3D,
|
||||
wxSW_3DSASH,
|
||||
wxSW_3DBORDER,
|
||||
wxSW_BORDER
|
||||
};
|
||||
|
||||
enum wxSashDragStatus
|
||||
|
62
wxPython/tests/dynamicform.py
Normal file
62
wxPython/tests/dynamicform.py
Normal file
@ -0,0 +1,62 @@
|
||||
|
||||
|
||||
from wxPython.wx import *
|
||||
|
||||
class FieldData:
|
||||
def __init__(self, name, label, shortHelp="", defValue="",
|
||||
size=(-1, -1), style=0, ID=-1):
|
||||
self.name = name
|
||||
self.label = label
|
||||
self.shortHelp = shortHelp
|
||||
self.defValue = defValue
|
||||
self.size = size
|
||||
self.style = style
|
||||
self.ID = ID
|
||||
|
||||
|
||||
class DynamicForm(wxPanel):
|
||||
def __init__(self, parent, ID, fieldData):
|
||||
wxPanel.__init__(self, parent, ID)
|
||||
|
||||
sizer = wxFlexGridSizer(cols=2, vgap=5, hgap=5)
|
||||
for field in fieldData:
|
||||
label = wxStaticText(self, -1, field.label)
|
||||
sizer.Add(label, 0, wxALIGN_RIGHT)
|
||||
text = wxTextCtrl(self, field.ID, field.defValue,
|
||||
size=field.size, style=field.style)
|
||||
if field.shortHelp:
|
||||
text.SetToolTip(wxToolTip(field.shortHelp))
|
||||
self.__dict__["get_"+field.name] = text.GetValue
|
||||
self.__dict__["set_"+field.name] = text.SetValue
|
||||
sizer.Add(text, 0, wxEXPAND)
|
||||
|
||||
sizer.Fit(self)
|
||||
self.SetAutoLayout(true)
|
||||
self.SetSizer(sizer)
|
||||
|
||||
|
||||
class TestFrame(wxFrame):
|
||||
testFields = [
|
||||
FieldData("fname", "First name:", "Enter someone's first name"),
|
||||
FieldData("lname", "Last name:", "Enter someone's last name"),
|
||||
FieldData("email", "Email address:", "just figure it out..."),
|
||||
]
|
||||
def __init__(self):
|
||||
wxFrame.__init__(self, None, -1, "This is a test")
|
||||
form = DynamicForm(self, -1, self.testFields)
|
||||
form.set_fname("Robin")
|
||||
form.set_lname("Dunn")
|
||||
self.form = form
|
||||
self.Fit()
|
||||
EVT_CLOSE(self, self.OnCloseWindow)
|
||||
|
||||
def OnCloseWindow(self, evt):
|
||||
print self.form.get_email()
|
||||
self.Destroy()
|
||||
|
||||
|
||||
app = wxPySimpleApp()
|
||||
frame = TestFrame()
|
||||
frame.Show(true)
|
||||
app.MainLoop()
|
||||
|
@ -154,7 +154,18 @@ if __name__ == '__main__':
|
||||
#----------------------------------------------------------------------------
|
||||
#
|
||||
# $Log$
|
||||
# Revision 1.4 2001/02/16 08:19:38 robind
|
||||
# Copied/merged from the 2.2 branch.
|
||||
#
|
||||
# Changes needed to build with new event system
|
||||
#
|
||||
# Revision 1.1.2.2 2001/01/30 20:54:16 robind
|
||||
#
|
||||
# Gobs of changes move from the main trunk to the 2.2 branch in
|
||||
# preparataion for 2.2.5 release. See CHANGES.txt for details.
|
||||
#
|
||||
# Revision 1.3 2000/10/30 21:05:22 robind
|
||||
#
|
||||
# Merged wxPython 2.2.2 over to the main branch
|
||||
#
|
||||
# Revision 1.1.2.1 2000/05/16 02:07:01 RD
|
||||
|
@ -146,7 +146,18 @@ if __name__ == '__main__':
|
||||
#----------------------------------------------------------------------------
|
||||
#
|
||||
# $Log$
|
||||
# Revision 1.4 2001/02/16 08:19:38 robind
|
||||
# Copied/merged from the 2.2 branch.
|
||||
#
|
||||
# Changes needed to build with new event system
|
||||
#
|
||||
# Revision 1.1.2.2 2001/01/30 20:54:16 robind
|
||||
#
|
||||
# Gobs of changes move from the main trunk to the 2.2 branch in
|
||||
# preparataion for 2.2.5 release. See CHANGES.txt for details.
|
||||
#
|
||||
# Revision 1.3 2000/10/30 21:05:22 robind
|
||||
#
|
||||
# Merged wxPython 2.2.2 over to the main branch
|
||||
#
|
||||
# Revision 1.1.2.1 2000/05/16 02:07:01 RD
|
||||
|
@ -998,7 +998,18 @@ if __name__ == '__main__':
|
||||
#----------------------------------------------------------------------------
|
||||
#
|
||||
# $Log$
|
||||
# Revision 1.4 2001/02/16 08:19:38 robind
|
||||
# Copied/merged from the 2.2 branch.
|
||||
#
|
||||
# Changes needed to build with new event system
|
||||
#
|
||||
# Revision 1.1.2.2 2001/01/30 20:54:16 robind
|
||||
#
|
||||
# Gobs of changes move from the main trunk to the 2.2 branch in
|
||||
# preparataion for 2.2.5 release. See CHANGES.txt for details.
|
||||
#
|
||||
# Revision 1.3 2000/10/30 21:05:22 robind
|
||||
#
|
||||
# Merged wxPython 2.2.2 over to the main branch
|
||||
#
|
||||
# Revision 1.1.2.1 2000/05/16 02:07:02 RD
|
||||
|
91
wxPython/wxPython/lib/anchors.py
Normal file
91
wxPython/wxPython/lib/anchors.py
Normal file
@ -0,0 +1,91 @@
|
||||
#----------------------------------------------------------------------
|
||||
# Name: wxPython.lib.anchors
|
||||
# Purpose: A class that provides an easy to use interface over layout
|
||||
# constraints for anchored layout.
|
||||
#
|
||||
# Author: Riaan Booysen
|
||||
#
|
||||
# Created: 15-Dec-2000
|
||||
# RCS-ID: $Id$
|
||||
# Copyright: (c) 2000 by Total Control Software
|
||||
# Licence: wxWindows license
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
from wxPython.wx import wxLayoutConstraints, wxTop, wxLeft, wxBottom, wxRight, \
|
||||
wxHeight, wxWidth
|
||||
|
||||
class LayoutAnchors(wxLayoutConstraints):
|
||||
""" A class that implements Delphi's Anchors with wxLayoutConstraints.
|
||||
|
||||
Anchored sides maintain the distance from the edge of the
|
||||
control to the same edge of the parent.
|
||||
When neither side is selected, the control keeps the same
|
||||
relative position to both sides.
|
||||
|
||||
The current position and size of the control and it's parent
|
||||
is used when setting up the constraints. To change the size or
|
||||
position of an already anchored control, set the constraints to
|
||||
None, reposition or resize and reapply the anchors.
|
||||
|
||||
Examples:
|
||||
|
||||
Let's anchor the right and bottom edge of a control and
|
||||
resize it's parent.
|
||||
|
||||
ctrl.SetConstraints(LayoutAnchors(ctrl, left=0, top=0, right=1, bottom=1))
|
||||
|
||||
+=========+ +===================+
|
||||
| +-----+ | | |
|
||||
| | * | -> | |
|
||||
| +--*--+ | | +-----+ |
|
||||
+---------+ | | * |
|
||||
| +--*--+ |
|
||||
+-------------------+
|
||||
* = anchored edge
|
||||
|
||||
When anchored on both sides the control will stretch horizontally.
|
||||
|
||||
ctrl.SetConstraints(LayoutAnchors(ctrl, 1, 0, 1, 1))
|
||||
|
||||
+=========+ +===================+
|
||||
| +-----+ | | |
|
||||
| * * | -> | |
|
||||
| +--*--+ | | +---------------+ |
|
||||
+---------+ | * ctrl * |
|
||||
| +-------*-------+ |
|
||||
+-------------------+
|
||||
* = anchored edge
|
||||
"""
|
||||
def __init__(self, control, left = 1, top = 1, right = 0, bottom = 0):
|
||||
wxLayoutConstraints.__init__(self)
|
||||
parent = control.GetParent()
|
||||
if not parent: return
|
||||
|
||||
pPos, pSize = parent.GetPosition(), parent.GetClientSize()
|
||||
cPos, cSize = control.GetPosition(), control.GetSize()
|
||||
|
||||
self.setConstraintSides(self.left, wxLeft, left,
|
||||
self.right, wxRight, right,
|
||||
self.width, wxWidth, self.centreX,
|
||||
cPos.x, cSize.x, pSize.x, parent)
|
||||
|
||||
self.setConstraintSides(self.top, wxTop, top,
|
||||
self.bottom, wxBottom, bottom,
|
||||
self.height, wxHeight, self.centreY,
|
||||
cPos.y, cSize.y, pSize.y, parent)
|
||||
|
||||
def setConstraintSides(self, side1, side1Edge, side1Anchor,
|
||||
side2, side2Edge, side2Anchor,
|
||||
size, sizeEdge, centre,
|
||||
cPos, cSize, pSize, parent):
|
||||
if side2Anchor:
|
||||
side2.SameAs(parent, side2Edge, pSize - (cPos + cSize))
|
||||
if side1Anchor:
|
||||
side1.SameAs(parent, side1Edge, cPos)
|
||||
if not side2Anchor:
|
||||
size.AsIs()
|
||||
else:
|
||||
size.AsIs()
|
||||
if not side2Anchor:
|
||||
centre.PercentOf(parent, sizeEdge,
|
||||
int(((cPos + cSize / 2.0) / pSize)*100))
|
@ -67,6 +67,7 @@ class wxGenButton(wxControl):
|
||||
self.bezelWidth = 2
|
||||
self.hasFocus = false
|
||||
self.useFocusInd = true
|
||||
self.evtToSend = []
|
||||
|
||||
self.SetLabel(label)
|
||||
self.SetPosition(pos)
|
||||
@ -86,6 +87,7 @@ class wxGenButton(wxControl):
|
||||
EVT_KEY_UP(self, self.OnKeyUp)
|
||||
EVT_ERASE_BACKGROUND(self, self.OnEraseBackground)
|
||||
EVT_PAINT(self, self.OnPaint)
|
||||
EVT_IDLE(self, self.OnIdle)
|
||||
|
||||
|
||||
def SetBestSize(self, size=None):
|
||||
@ -174,7 +176,14 @@ class wxGenButton(wxControl):
|
||||
evt = wxGenButtonEvent(wxEVT_COMMAND_BUTTON_CLICKED, self.GetId())
|
||||
evt.SetIsDown(not self.up)
|
||||
evt.SetButtonObj(self)
|
||||
self.GetEventHandler().ProcessEvent(evt)
|
||||
self.evtToSend.append(evt)
|
||||
|
||||
|
||||
def OnIdle(self, evt):
|
||||
while self.evtToSend:
|
||||
evt = self.evtToSend[0]
|
||||
del self.evtToSend[0]
|
||||
self.GetEventHandler().ProcessEvent(evt)
|
||||
|
||||
|
||||
def DrawBezel(self, dc, x1, y1, x2, y2):
|
||||
|
249
wxPython/wxPython/lib/fancytext.py
Normal file
249
wxPython/wxPython/lib/fancytext.py
Normal file
@ -0,0 +1,249 @@
|
||||
"""wxFancyText -- methods for rendering XML specified text
|
||||
|
||||
This module has four main methods:
|
||||
|
||||
def getExtent(str, dc=None, enclose=1):
|
||||
def renderToBitmap(str, background=None, enclose=1)
|
||||
def renderToDC(str, dc, x, y, enclose=1)
|
||||
|
||||
In all cases, 'str' is an XML string. The tags in the string can
|
||||
currently specify the font, subscripts, superscripts, and the angle
|
||||
sign. The allowable properties of font are size, family, style, weght,
|
||||
encoding, and color. See the example on the bottom for a better idea
|
||||
of how this works.
|
||||
|
||||
Note that start and end tags for the string are provided if enclose is
|
||||
true, so for instance, renderToBitmap("X<sub>1</sub>") will work.
|
||||
|
||||
"""
|
||||
# Copyright 2001 Timothy Hochberg
|
||||
# Use as you see fit. No warantees, I cannot be held responsible, etc.
|
||||
|
||||
|
||||
|
||||
# TODO: Make a wxFancyTextCtrl class that derives from wxControl.
|
||||
# Add support for line breaks
|
||||
# etc.
|
||||
# - Robin
|
||||
|
||||
|
||||
|
||||
from wxPython.wx import *
|
||||
import xml.parsers.expat, copy
|
||||
|
||||
_families = {"default" : wxDEFAULT, "decorative" : wxDECORATIVE, "roman" : wxROMAN,
|
||||
"swiss" : wxSWISS, "modern" : wxMODERN}
|
||||
_styles = {"normal" : wxNORMAL, "slant" : wxSLANT, "italic" : wxITALIC}
|
||||
_weights = {"normal" : wxNORMAL, "light" : wxLIGHT, "bold" : wxBOLD}
|
||||
|
||||
# The next three classes: Renderer, SizeRenderer and DCRenderer are
|
||||
# what you will need to override to extend the XML language. All of
|
||||
# the font stuff as well as the subscript and superscript stuff are in
|
||||
# Renderer.
|
||||
|
||||
class Renderer:
|
||||
|
||||
defaultSize = wxNORMAL_FONT.GetPointSize()
|
||||
defaultFamily = wxDEFAULT
|
||||
defaultStyle = wxNORMAL
|
||||
defaultWeight = wxNORMAL
|
||||
defaultEncoding = wxFont_GetDefaultEncoding()
|
||||
defaultColor = "black"
|
||||
|
||||
def __init__(self, dc=None):
|
||||
if dc == None:
|
||||
dc = wxMemoryDC()
|
||||
self.dc = dc
|
||||
self.offsets = [0]
|
||||
self.fonts = [{}]
|
||||
|
||||
def startElement(self, name, attrs):
|
||||
method = "start_" + name
|
||||
if not hasattr(self, method):
|
||||
raise ValueError("XML tag '%s' not supported" % name)
|
||||
getattr(self, method)(attrs)
|
||||
|
||||
def endElement(self, name):
|
||||
method = "end_" + name
|
||||
if not hasattr(self, method):
|
||||
raise ValueError("XML tag '%s' not supported" % name)
|
||||
getattr(self, method)()
|
||||
|
||||
def start_wxFancyString(self, attrs):
|
||||
pass
|
||||
|
||||
def end_wxFancyString(self):
|
||||
pass
|
||||
|
||||
def start_font(self, attrs):
|
||||
for key, value in attrs.items():
|
||||
if key == "size":
|
||||
value = int(value)
|
||||
elif key == "family":
|
||||
value = _families[value]
|
||||
elif key == "style":
|
||||
value = _styles[value]
|
||||
elif key == "weight":
|
||||
value = _weights[value]
|
||||
elif key == "encoding":
|
||||
pass
|
||||
elif key == "color":
|
||||
pass
|
||||
else:
|
||||
raise ValueError("unknown font attribute '%s'" % key)
|
||||
attrs[key] = value
|
||||
font = copy.copy(self.fonts[-1])
|
||||
font.update(attrs)
|
||||
self.fonts.append(font)
|
||||
|
||||
def end_font(self):
|
||||
self.fonts.pop()
|
||||
|
||||
def start_sub(self, attrs):
|
||||
if attrs.keys():
|
||||
raise ValueError("<sub> does not take attributes")
|
||||
font = self.getCurrentFont()
|
||||
self.offsets.append(self.offsets[-1] + self.dc.GetFullTextExtent("M", font)[1]*0.5)
|
||||
self.start_font({"size" : font.GetPointSize() * 0.8})
|
||||
|
||||
def end_sub(self):
|
||||
self.fonts.pop()
|
||||
self.offsets.pop()
|
||||
|
||||
def start_sup(self, attrs):
|
||||
if attrs.keys():
|
||||
raise ValueError("<sup> does not take attributes")
|
||||
font = self.getCurrentFont()
|
||||
self.offsets.append(self.offsets[-1] - self.dc.GetFullTextExtent("M", font)[1]*0.3)
|
||||
self.start_font({"size" : font.GetPointSize() * 0.8})
|
||||
|
||||
def end_sup(self):
|
||||
self.fonts.pop()
|
||||
self.offsets.pop()
|
||||
|
||||
def getCurrentFont(self):
|
||||
font = self.fonts[-1]
|
||||
return wxFont(font.get("size", self.defaultSize),
|
||||
font.get("family", self.defaultFamily),
|
||||
font.get("style", self.defaultStyle),
|
||||
font.get("weight", self.defaultWeight),
|
||||
encoding = font.get("encoding", self.defaultEncoding))
|
||||
|
||||
def getCurrentColor(self):
|
||||
font = self.fonts[-1]
|
||||
return wxNamedColour(font.get("color", self.defaultColor))
|
||||
|
||||
|
||||
class SizeRenderer(Renderer):
|
||||
|
||||
def __init__(self, dc=None):
|
||||
Renderer.__init__(self, dc)
|
||||
self.width = self.height = 0
|
||||
self.minY = self.maxY = 0
|
||||
|
||||
def characterData(self, data):
|
||||
self.dc.SetFont(self.getCurrentFont())
|
||||
width, height = self.dc.GetTextExtent(data)
|
||||
self.width = self.width + width
|
||||
self.minY = min(self.minY, self.offsets[-1])
|
||||
self.maxY = max(self.maxY, self.offsets[-1] + height)
|
||||
self.height = self.maxY - self.minY
|
||||
|
||||
def start_angle(self, attrs):
|
||||
self.characterData("M")
|
||||
|
||||
def end_angle(self):
|
||||
pass
|
||||
|
||||
class DCRenderer(Renderer):
|
||||
|
||||
def __init__(self, dc=None, x=0, y=0):
|
||||
Renderer.__init__(self, dc)
|
||||
self.x = x
|
||||
self.y = y
|
||||
|
||||
def characterData(self, data):
|
||||
self.dc.SetFont(self.getCurrentFont())
|
||||
self.dc.SetTextForeground(self.getCurrentColor())
|
||||
width, height = self.dc.GetTextExtent(data)
|
||||
self.dc.DrawText(data, self.x, self.y + self.offsets[-1])
|
||||
self.x = self.x + width
|
||||
|
||||
def start_angle(self, attrs):
|
||||
self.dc.SetFont(self.getCurrentFont())
|
||||
self.dc.SetPen(wxPen(self.getCurrentColor(), 1))
|
||||
width, height, descent, leading = self.dc.GetFullTextExtent("M")
|
||||
y = self.y + self.offsets[-1] + height - descent
|
||||
self.dc.DrawLine(self.x, y, self.x+width, y)
|
||||
self.dc.DrawLine(self.x, y, self.x+width, y-width)
|
||||
self.x = self.x + width
|
||||
|
||||
def end_angle(self):
|
||||
pass
|
||||
|
||||
# This is a rendering function that is primarily used internally,
|
||||
# although it could be used externally if one had overridden the
|
||||
# Renderer classes.
|
||||
|
||||
def renderToRenderer(str, renderer, enclose=1):
|
||||
if enclose:
|
||||
str = '<?xml version="1.0"?><wxFancyString>%s</wxFancyString>' % str
|
||||
p = xml.parsers.expat.ParserCreate()
|
||||
p.returns_unicode = 0
|
||||
p.StartElementHandler = renderer.startElement
|
||||
p.EndElementHandler = renderer.endElement
|
||||
p.CharacterDataHandler = renderer.characterData
|
||||
p.Parse(str, 1)
|
||||
|
||||
|
||||
def getExtent(str, dc=None, enclose=1):
|
||||
"Return the extent of str"
|
||||
renderer = SizeRenderer(dc)
|
||||
renderToRenderer(str, renderer, enclose)
|
||||
return wxSize(renderer.width, renderer.height)
|
||||
|
||||
# This should probably only be used internally....
|
||||
|
||||
def getFullExtent(str, dc=None, enclose=1):
|
||||
renderer = SizeRenderer(dc)
|
||||
renderToRenderer(str, renderer, enclose)
|
||||
return renderer.width, renderer.height, -renderer.minY
|
||||
|
||||
def renderToBitmap(str, background=None, enclose=1):
|
||||
"Return str rendered on a minumum size bitmap"
|
||||
dc = wxMemoryDC()
|
||||
width, height, dy = getFullExtent(str, dc)
|
||||
bmp = wxEmptyBitmap(width, height)
|
||||
dc.SelectObject(bmp)
|
||||
if background is not None:
|
||||
dc.SetBackground(background)
|
||||
dc.Clear()
|
||||
renderer = DCRenderer(dc, y=dy)
|
||||
dc.BeginDrawing()
|
||||
renderToRenderer(str, renderer, enclose)
|
||||
dc.EndDrawing()
|
||||
dc.SelectObject(wxNullBitmap)
|
||||
return bmp
|
||||
|
||||
def renderToDC(str, dc, x, y, enclose=1):
|
||||
"Render str onto a wxDC at (x,y)"
|
||||
width, height, dy = getFullExtent(str, dc)
|
||||
renderer = DCRenderer(dc, x, y+dy)
|
||||
renderToRenderer(str, renderer, enclose)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
str = ('<font style="italic" family="swiss" color="red" weight="bold" >some |<sup>23</sup> <angle/>text<sub>with <angle/> subscript</sub> </font> some other text'
|
||||
'<font family="swiss" color="green" size="40">big green text</font>')
|
||||
ID_EXIT = 102
|
||||
class myApp(wxApp):
|
||||
def OnInit(self):
|
||||
return 1
|
||||
app = myApp()
|
||||
frame = wxFrame(NULL, -1, "wxFancyText demo", wxDefaultPosition)
|
||||
frame.SetClientSize(getExtent(str))
|
||||
bmp = renderToBitmap(str, wxCYAN_BRUSH)
|
||||
sb = wxStaticBitmap(frame, -1, bmp)
|
||||
EVT_MENU(frame, ID_EXIT, frame.Destroy)
|
||||
frame.Show(1)
|
||||
app.MainLoop()
|
@ -31,7 +31,7 @@ class FileBrowseButton(wxPanel):
|
||||
startDirectory -- Default directory for file dialog startup
|
||||
fileMask -- File mask (glob pattern, such as *.*) to use in file dialog
|
||||
fileMode -- wxOPEN or wxSAVE, indicates type of file dialog to use
|
||||
changeCallback -- callback receives all changes in value of control
|
||||
changeCallback -- callback receives all > > changes in value of control
|
||||
)
|
||||
GetValue() -- retrieve current value of text control
|
||||
SetValue(string) -- set current value of text control
|
||||
|
236
wxPython/wxPython/lib/rpcMixin.py
Normal file
236
wxPython/wxPython/lib/rpcMixin.py
Normal file
@ -0,0 +1,236 @@
|
||||
#----------------------------------------------------------------------
|
||||
# Name: rpcMixin
|
||||
# Version: 0.1
|
||||
# Purpose: provides xmlrpc server functionality for wxPython
|
||||
# applications via a mixin class
|
||||
#
|
||||
# Requires: (1) Python with threading enabled.
|
||||
# (2) xmlrpclib from PythonWare
|
||||
# (http://www.pythonware.com/products/xmlrpc/)
|
||||
# the code was developed and tested using version 0.9.8
|
||||
#
|
||||
# Author: greg Landrum (Landrum@RationalDiscovery.com)
|
||||
#
|
||||
# Copyright: (c) 2000 by Greg Landrum and Rational Discovery LLC
|
||||
# Licence: wxWindows license
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
"""
|
||||
Some Notes:
|
||||
|
||||
1) The xmlrpc server runs in a separate thread from the main GUI
|
||||
application, communication between the two threads using a custom
|
||||
event (see the Threads demo in the wxPython docs for more info).
|
||||
|
||||
2) Neither the server nor the client are particularly smart about
|
||||
checking method names. So it's easy to shoot yourself in the foot
|
||||
by calling improper methods. It would be pretty easy to add
|
||||
either a list of allowed methods or a list of forbidden methods.
|
||||
|
||||
3) Authentication of xmlrpc clients is *not* performed. I think it
|
||||
would be pretty easy to do this in a hacky way, but I haven't done
|
||||
it yet.
|
||||
|
||||
4) The default port number is 800, it's a windows thing... at least
|
||||
it seems like a windows thing to me. Since I'm not being smart
|
||||
about port numbers, you can probably hork yourself arbitrarily by
|
||||
firing up more than one xmlrpc-active frame at the same time, but
|
||||
I haven't tried that.
|
||||
|
||||
5) See the bottom of this file for an example of using the class.
|
||||
|
||||
Obligatory disclaimer:
|
||||
This is my first crack at both using xmlrpc and multi-threaded
|
||||
programming, so there could be huge horrible bugs or design
|
||||
flaws. If you see one, I'd love to hear about them.
|
||||
|
||||
"""
|
||||
|
||||
from wxPython.wx import *
|
||||
import xmlrpcserver
|
||||
import Threading
|
||||
import SocketServer
|
||||
|
||||
rpcPENDING = 0
|
||||
rpcDONE = 1
|
||||
rpcEXCEPT = 2
|
||||
class RPCRequest:
|
||||
"""A wrapper to use for handling requests and their responses"""
|
||||
status = rpcPENDING
|
||||
result = None
|
||||
|
||||
# here's the ID for external events
|
||||
wxEVT_EXTERNAL_EVENT = 25015
|
||||
class ExternalEvent(wxPyEvent):
|
||||
"""The custom event class used to pass xmlrpc calls from
|
||||
the server thread into the GUI thread
|
||||
"""
|
||||
def __init__(self,method,args):
|
||||
wxPyEvent.__init__(self)
|
||||
self.SetEventType(wxEVT_EXTERNAL_EVENT)
|
||||
self.method = method
|
||||
self.args = args
|
||||
self.rpcStatus = RPCRequest()
|
||||
self.rpcStatusLock = Threading.Lock()
|
||||
self.rpcCondVar = Threading.Condition()
|
||||
|
||||
def EVT_EXTERNAL_EVENT(win,func):
|
||||
win.Connect(-1,-1,wxEVT_EXTERNAL_EVENT,func)
|
||||
|
||||
class Handler(xmlrpcserver.RequestHandler):
|
||||
"""The handler class that the xmlrpcserver actually calls
|
||||
when a request comes in.
|
||||
"""
|
||||
def call(self,method,params):
|
||||
"""When an xmlrpc request comes in, this is the method that
|
||||
gets called.
|
||||
"""
|
||||
# construct the event
|
||||
evt = ExternalEvent(method,params)
|
||||
|
||||
# update the status variable
|
||||
evt.rpcStatusLock.acquire()
|
||||
evt.rpcStatus.status = rpcPENDING
|
||||
evt.rpcStatusLock.release()
|
||||
|
||||
# acquire the condition lock
|
||||
evt.rpcCondVar.acquire()
|
||||
# dispatch the event to the GUI
|
||||
wxPostEvent(self._app,evt)
|
||||
# wait for the GUI to finish
|
||||
while evt.rpcStatus.status == rpcPENDING:
|
||||
evt.rpcCondVar.wait()
|
||||
evt.rpcCondVar.release()
|
||||
evt.rpcStatusLock.acquire()
|
||||
if evt.rpcStatus.status == rpcEXCEPT:
|
||||
# The GUI threw an exception, release the status lock
|
||||
# and re-raise the exception
|
||||
evt.rpcStatusLock.release()
|
||||
raise evt.rpcStatus.result[0],evt.rpcStatus.result[1]
|
||||
else:
|
||||
# everything went through without problems
|
||||
s = evt.rpcStatus.result
|
||||
evt.rpcStatusLock.release()
|
||||
return s
|
||||
|
||||
class rpcMixin:
|
||||
"""A mixin class to provide xmlrpc server functionality to wxPython
|
||||
frames/windows
|
||||
|
||||
If you want to customize this, probably the best idea is to
|
||||
override the OnExternal method, which is what's invoked when an
|
||||
RPC is handled.
|
||||
|
||||
"""
|
||||
def __init__(self,host='',port=800):
|
||||
"""
|
||||
Arguments:
|
||||
host: (optional) the hostname for the server
|
||||
port: (optional) the port the server will use
|
||||
"""
|
||||
EVT_EXTERNAL_EVENT(self,self.OnExternal)
|
||||
if hasattr(self,'OnClose'):
|
||||
self._origOnClose = self.OnClose
|
||||
else:
|
||||
self._origOnClose = None
|
||||
EVT_CLOSE(self,self.OnClose)
|
||||
|
||||
exec('class Handler%d(Handler): pass'%(port))
|
||||
exec('tClass= Handler%d'%(port))
|
||||
tClass._app = self
|
||||
self._xmlServ = SocketServer.TCPServer((host,port),tClass)
|
||||
self.servThread = Threading.Thread(target=self._xmlServ.serve_forever)
|
||||
self.servThread.setDaemon(1)
|
||||
self.servThread.start()
|
||||
|
||||
def OnClose(self,event):
|
||||
""" be sure to shutdown the server and the server thread before
|
||||
leaving
|
||||
"""
|
||||
self._xmlServ = None
|
||||
self.servThread = None
|
||||
if self._origOnClose is not None:
|
||||
self._origOnClose(event)
|
||||
|
||||
def OnExternal(self,event):
|
||||
""" this is the callback used to handle RPCs
|
||||
|
||||
Exceptions are caught and returned in the global _rpcStatus
|
||||
structure. This allows the xmlrpc server to report the
|
||||
exception to the client without mucking up any of the delicate
|
||||
thread stuff.
|
||||
"""
|
||||
event.rpcStatusLock.acquire()
|
||||
try:
|
||||
res = eval('apply(self.%s,event.args)'%event.method)
|
||||
except:
|
||||
import sys,traceback
|
||||
traceback.print_exc()
|
||||
event.rpcStatus.result = sys.exc_info()[:2]
|
||||
event.rpcStatus.status = rpcEXCEPT
|
||||
else:
|
||||
if res is None:
|
||||
event.rpcStatus.result = []
|
||||
else:
|
||||
event.rpcStatus.result = res
|
||||
event.rpcStatus.status = rpcDONE
|
||||
event.rpcStatusLock.release()
|
||||
event.rpcCondVar.acquire()
|
||||
event.rpcCondVar.notify()
|
||||
event.rpcCondVar.release()
|
||||
|
||||
if __name__ == '__main__':
|
||||
import sys
|
||||
port = 800
|
||||
if len(sys.argv)>1:
|
||||
port = int(sys.argv[1])
|
||||
|
||||
class rpcFrame(wxFrame,rpcMixin):
|
||||
"""A simple wxFrame with the rpcMixin functionality added
|
||||
"""
|
||||
def __init__(self,*args,**kwargs):
|
||||
""" rpcHost or rpcPort keyword arguments will be passed along to
|
||||
the xmlrpc server.
|
||||
"""
|
||||
mixinArgs = {}
|
||||
if kwargs.has_key('rpcHost'):
|
||||
mixinArgs['host'] = kwargs['rpcHost']
|
||||
del kwargs['rpcHost']
|
||||
if kwargs.has_key('rpcPort'):
|
||||
mixinArgs['port'] = kwargs['rpcPort']
|
||||
del kwargs['rpcPort']
|
||||
|
||||
apply(wxFrame.__init__,(self,)+args,kwargs)
|
||||
apply(rpcMixin.__init__,(self,),mixinArgs)
|
||||
|
||||
EVT_CHAR(self,self.OnChar)
|
||||
|
||||
def TestFunc(self,args):
|
||||
"""a demo method"""
|
||||
return args
|
||||
|
||||
def OnChar(self,event):
|
||||
key = event.GetKeyCode()
|
||||
if key == ord('q'):
|
||||
self.OnQuit(event)
|
||||
|
||||
def OnQuit(self,event):
|
||||
self.OnClose(event)
|
||||
|
||||
def OnClose(self,event):
|
||||
self.Destroy()
|
||||
|
||||
class MyApp(wxApp):
|
||||
def OnInit(self):
|
||||
frame = rpcFrame(NULL, -1, "wxPython RPCDemo", wxDefaultPosition, wxSize(300,300),rpcHost='localhost',rpcPort=port)
|
||||
frame.Show(TRUE)
|
||||
import time
|
||||
|
||||
#self.SetTopWindow(frame)
|
||||
frame2 = rpcFrame(NULL, -1, "wxPython RPCDemo2", wxDefaultPosition, wxSize(300,300),rpcHost='localhost',rpcPort=port+1)
|
||||
frame2.Show(TRUE)
|
||||
|
||||
return TRUE
|
||||
app = MyApp(0)
|
||||
app.MainLoop()
|
||||
|
Loading…
Reference in New Issue
Block a user