Skip to content

Commit

Permalink
Add classes that have been added to existing interface headers
Browse files Browse the repository at this point in the history
  • Loading branch information
RobinD42 committed Feb 9, 2018
1 parent 6b56f8e commit f1a24d4
Show file tree
Hide file tree
Showing 15 changed files with 77 additions and 5 deletions.
8 changes: 7 additions & 1 deletion etg/_glcanvas.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,10 @@

# The classes and/or the basename of the Doxygen XML files to be processed by
# this script.
ITEMS = [ 'wxGLContext',
ITEMS = [ 'wxGLAttribsBase',
'wxGLAttributes',
'wxGLContextAttrs',
'wxGLContext',
'wxGLCanvas',
]

Expand Down Expand Up @@ -67,6 +70,9 @@ def run():
c.addPrivateCopyCtor()


c = module.find('wxGLAttribsBase')
assert isinstance(c, etgtools.ClassDef)
c.find('GetGLAttrs').ignore()

c = module.find('wxGLCanvas')
tools.fixWindowClass(c)
Expand Down
1 change: 1 addition & 0 deletions etg/_xml.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
ITEMS = [ 'wxXmlNode',
'wxXmlAttribute',
'wxXmlDocument',
'wxXmlDoctype',
]


Expand Down
1 change: 1 addition & 0 deletions etg/auiframemanager.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
'wxAuiDockInfo',
'wxAuiDockUIPart',
'wxAuiPaneButton',
'wxAuiFloatingFrame'
]

#---------------------------------------------------------------------------
Expand Down
1 change: 1 addition & 0 deletions etg/busyinfo.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
# The classes and/or the basename of the Doxygen XML files to be processed by
# this script.
ITEMS = [ "wxBusyInfo",
"wxBusyInfoFlags",
]

#---------------------------------------------------------------------------
Expand Down
2 changes: 2 additions & 0 deletions etg/dataview.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
'wxDataViewCustomRenderer',
'wxDataViewTextRenderer',
'wxDataViewIconTextRenderer',
'wxDataViewCheckIconTextRenderer',
'wxDataViewProgressRenderer',
'wxDataViewSpinRenderer',
'wxDataViewToggleRenderer',
Expand All @@ -46,6 +47,7 @@
'wxDataViewColumn',
'wxDataViewCtrl',
'wxDataViewEvent',
'wxDataViewValueAdjuster',

'wxDataViewListCtrl',
'wxDataViewListStore',
Expand Down
7 changes: 6 additions & 1 deletion etg/dcsvg.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,12 @@

# The classes and/or the basename of the Doxygen XML files to be processed by
# this script.
ITEMS = [ 'wxSVGFileDC' ]
ITEMS = [ 'wxSVGFileDC',
'wxSVGBitmapHandler',
'wxSVGBitmapEmbedHandler',
'wxSVGBitmapFileHandler',

]

#---------------------------------------------------------------------------

Expand Down
9 changes: 9 additions & 0 deletions etg/event.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,15 @@
'wxWindowCreateEvent',
'wxWindowDestroyEvent',

'wxGestureEvent',
'wxPanGestureEvent',
'wxZoomGestureEvent',
'wxRotateGestureEvent',
'wxTwoFingerTapEvent',
'wxLongPressEvent',
'wxPressAndTapEvent',


#'wxThreadEvent',

]
Expand Down
10 changes: 10 additions & 0 deletions etg/graphics.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
'wxGraphicsBitmap',
'wxGraphicsBrush',
'wxGraphicsFont',
'wxGraphicsPenInfo',
'wxGraphicsPen',
'wxGraphicsContext',
'wxGraphicsGradientStop',
Expand Down Expand Up @@ -225,6 +226,15 @@ def markFactories(klass):
factory=True)


#---------------------------------------------
c = module.find('wxGraphicsPenInfo')
# Ignore Dashes for now
# TODO: we need to do something like wx.Pen.SetDashes, but since
# GraphicsPenInfo is transitory we can't save the reference in it to the
# holder, and the pen will not have been created yet...
c.find('Dashes').ignore()


#---------------------------------------------
# Use the pyNames we set for these classes in geometry.py so the old
# names do not show up in the docstrings, etc.
Expand Down
2 changes: 1 addition & 1 deletion etg/listctrl.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

# The classes and/or the basename of the Doxygen XML files to be processed by
# this script.
ITEMS = [ "wxListItemAttr",
ITEMS = [ "wxItemAttr", # TODO: technically this should be in its own etg script...
"wxListItem",
"wxListCtrl",
"wxListView",
Expand Down
13 changes: 11 additions & 2 deletions etg/pen.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@

# The classes and/or the basename of the Doxygen XML files to be processed by
# this script.
ITEMS = [ 'wxPen', 'wxPenList', ]
ITEMS = [ 'wxPenInfo',
'wxPen',
'wxPenList', ]

#---------------------------------------------------------------------------

Expand Down Expand Up @@ -103,11 +105,18 @@ def run():
module.addPyCode(pycode)


c = module.find('wxPenInfo')
# Ignore Dashes for now
# TODO: we need to do something like SetDashes above, but since PenInfo is
# transitory we can't save the reference in it to the holder, and the pen
# will not have been created yet...
c.find('Dashes').ignore()


# it is delay-initialized, see stockgdi.sip
module.find('wxThePenList').ignore()



# Some aliases that should be phased out eventually, (sooner rather than
# later.) They are already gone (or wrapped by an #if) in the C++ code,
# and so are not found in the documentation...
Expand Down
7 changes: 7 additions & 0 deletions etg/power.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
# The classes and/or the basename of the Doxygen XML files to be processed by
# this script.
ITEMS = [ "wxPowerEvent",
'wxPowerResource',
'wxPowerResourceBlocker',
]

#---------------------------------------------------------------------------
Expand Down Expand Up @@ -68,6 +70,11 @@ class wxPowerEvent : public wxEvent
EVT_POWER_RESUME = wx.PyEventBinder( wxEVT_POWER_RESUME , 1 )
""")


c = module.find('wxPowerResourceBlocker')
c.addPrivateCopyCtor()
c.addPrivateAssignOp()

#-----------------------------------------------------------------
tools.doCommonTweaks(module)
tools.runGenerators(module)
Expand Down
5 changes: 5 additions & 0 deletions etg/propgrid.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
'wxPGValidationInfo',
'wxPropertyGrid',
'wxPropertyGridEvent',
'wxPropertyGridPopulator',
]

#---------------------------------------------------------------------------
Expand Down Expand Up @@ -116,6 +117,10 @@ def _PropertyGrid__init__(self, *args, **kw):
if hasattr(item, 'type') and 'wxVariant' in item.type:
item.type = item.type.replace('wxVariant', 'wxPGVariant')


c = module.find('wxPropertyGridPopulator')
tools.ignoreConstOverloads(c)

#-----------------------------------------------------------------
tools.doCommonTweaks(module)
tools.runGenerators(module)
Expand Down
1 change: 1 addition & 0 deletions etg/propgridproperty.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
'wxPGDefaultRenderer',
'wxPGCellData',
'wxPGCell',
'wxPGAttributeStorage',

'wxPGProperty',
'wxPropertyCategory',
Expand Down
6 changes: 6 additions & 0 deletions etg/richtextbuffer.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
"wxTextAttrDimensionConverter",
"wxTextAttrBorder",
"wxTextAttrBorders",
"wxTextAttrShadow",
"wxTextBoxAttr",
"wxRichTextAttr",
"wxRichTextProperties",
Expand Down Expand Up @@ -134,6 +135,11 @@ class wxRichTextFloatCollector;
c.addCppMethod('int', '__nonzero__', '()', "return self->IsValid();")


#-------------------------------------------------------
c = module.find('wxTextAttrShadow')
tools.ignoreConstOverloads(c)


#-------------------------------------------------------
c = module.find('wxTextBoxAttr')
tools.ignoreConstOverloads(c)
Expand Down
9 changes: 9 additions & 0 deletions src/event_ex.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@
wxEVT_AUX2_UP,
wxEVT_AUX2_DCLICK,
])
EVT_MAGNIFY = wx.PyEventBinder( wxEVT_MAGNIFY )


# Scrolling from wxWindow (sent to wxScrolledWindow)
Expand Down Expand Up @@ -208,6 +209,14 @@
wxEVT_JOY_ZMOVE,
])

EVT_GESTURE_PAN = wx.PyEventBinder( wxEVT_GESTURE_PAN )
EVT_GESTURE_ZOOM = wx.PyEventBinder( wxEVT_GESTURE_ZOOM )
EVT_GESTURE_ROTATE = wx.PyEventBinder( wxEVT_GESTURE_ROTATE )
EVT_TWO_FINGER_TAP = wx.PyEventBinder( wxEVT_TWO_FINGER_TAP )
EVT_LONG_PRESS = wx.PyEventBinder( wxEVT_LONG_PRESS )
EVT_PRESS_AND_TAP = wx.PyEventBinder( wxEVT_PRESS_AND_TAP )


# deprecated wxEVT aliases
wxEVT_COMMAND_BUTTON_CLICKED = wxEVT_BUTTON
wxEVT_COMMAND_CHECKBOX_CLICKED = wxEVT_CHECKBOX
Expand Down

0 comments on commit f1a24d4

Please sign in to comment.