]> git.saurik.com Git - wxWidgets.git/blobdiff - utils/wxPython/src/gtk/wx.py
Compilation fixes
[wxWidgets.git] / utils / wxPython / src / gtk / wx.py
index d761711eebf55e4fcae14503ee5b15340bfa0aff..8358922e900184b515ed6b72443d6a9404050b47 100644 (file)
@@ -3,10 +3,14 @@ import wxc
 
 from misc import *
 
+from misc2 import *
+
 from windows import *
 
 from gdi import *
 
+from clip_dnd import *
+
 from events import *
 
 from mdi import *
@@ -23,71 +27,84 @@ from windows2 import *
 
 from cmndlgs import *
 
-from utils import *
+from windows3 import *
+
+from image import *
+
+from printfw import *
+
+from sizers import *
 class wxPyAppPtr(wxEvtHandlerPtr):
     def __init__(self,this):
         self.this = this
         self.thisown = 0
-    def GetAppName(self):
-        val = wxc.wxPyApp_GetAppName(self.this)
+    def __del__(self,wxc=wxc):
+        if self.thisown == 1 :
+            wxc.delete_wxPyApp(self)
+    def GetAppName(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_GetAppName,(self,) + _args, _kwargs)
         return val
-    def GetClassName(self):
-        val = wxc.wxPyApp_GetClassName(self.this)
+    def GetClassName(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_GetClassName,(self,) + _args, _kwargs)
         return val
-    def GetExitOnFrameDelete(self):
-        val = wxc.wxPyApp_GetExitOnFrameDelete(self.this)
+    def GetExitOnFrameDelete(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_GetExitOnFrameDelete,(self,) + _args, _kwargs)
         return val
-    def GetPrintMode(self):
-        val = wxc.wxPyApp_GetPrintMode(self.this)
+    def GetPrintMode(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_GetPrintMode,(self,) + _args, _kwargs)
         return val
-    def GetTopWindow(self):
-        val = wxc.wxPyApp_GetTopWindow(self.this)
-        val = wxWindowPtr(val)
+    def GetTopWindow(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_GetTopWindow,(self,) + _args, _kwargs)
+        if val: val = wxWindowPtr(val) 
         return val
-    def GetVendorName(self):
-        val = wxc.wxPyApp_GetVendorName(self.this)
+    def GetVendorName(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_GetVendorName,(self,) + _args, _kwargs)
         return val
-    def Dispatch(self):
-        val = wxc.wxPyApp_Dispatch(self.this)
+    def Dispatch(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_Dispatch,(self,) + _args, _kwargs)
         return val
-    def ExitMainLoop(self):
-        val = wxc.wxPyApp_ExitMainLoop(self.this)
+    def ExitMainLoop(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_ExitMainLoop,(self,) + _args, _kwargs)
         return val
-    def Initialized(self):
-        val = wxc.wxPyApp_Initialized(self.this)
+    def Initialized(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_Initialized,(self,) + _args, _kwargs)
         return val
-    def MainLoop(self):
-        val = wxc.wxPyApp_MainLoop(self.this)
+    def MainLoop(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_MainLoop,(self,) + _args, _kwargs)
+        return val
+    def Pending(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_Pending,(self,) + _args, _kwargs)
         return val
-    def Pending(self):
-        val = wxc.wxPyApp_Pending(self.this)
+    def ProcessIdle(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_ProcessIdle,(self,) + _args, _kwargs)
         return val
-    def SetAppName(self,arg0):
-        val = wxc.wxPyApp_SetAppName(self.this,arg0)
+    def SetAppName(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_SetAppName,(self,) + _args, _kwargs)
         return val
-    def SetClassName(self,arg0):
-        val = wxc.wxPyApp_SetClassName(self.this,arg0)
+    def SetClassName(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_SetClassName,(self,) + _args, _kwargs)
         return val
-    def SetExitOnFrameDelete(self,arg0):
-        val = wxc.wxPyApp_SetExitOnFrameDelete(self.this,arg0)
+    def SetExitOnFrameDelete(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_SetExitOnFrameDelete,(self,) + _args, _kwargs)
         return val
-    def SetPrintMode(self,arg0):
-        val = wxc.wxPyApp_SetPrintMode(self.this,arg0)
+    def SetPrintMode(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_SetPrintMode,(self,) + _args, _kwargs)
         return val
-    def SetTopWindow(self,arg0):
-        val = wxc.wxPyApp_SetTopWindow(self.this,arg0.this)
+    def SetTopWindow(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_SetTopWindow,(self,) + _args, _kwargs)
         return val
-    def SetVendorName(self,arg0):
-        val = wxc.wxPyApp_SetVendorName(self.this,arg0)
+    def SetVendorName(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_SetVendorName,(self,) + _args, _kwargs)
         return val
-    def AfterMainLoop(self):
-        val = wxc.wxPyApp_AfterMainLoop(self.this)
+    def GetStdIcon(self, *_args, **_kwargs):
+        val = apply(wxc.wxPyApp_GetStdIcon,(self,) + _args, _kwargs)
+        if val: val = wxIconPtr(val) ; val.thisown = 1
         return val
     def __repr__(self):
-        return "<C wxPyApp instance>"
+        return "<C wxPyApp instance at %s>" % (self.this,)
 class wxPyApp(wxPyAppPtr):
-    def __init__(self:
-        self.this = wxc.new_wxPyApp()
+    def __init__(self,*_args,**_kwargs):
+        self.this = apply(wxc.new_wxPyApp,_args,_kwargs)
         self.thisown = 1
 
 
@@ -97,10 +114,26 @@ class wxPyApp(wxPyAppPtr):
 
 #-------------- FUNCTION WRAPPERS ------------------
 
+ptrcast = wxc.ptrcast
+
+ptrvalue = wxc.ptrvalue
+
+ptrset = wxc.ptrset
+
+ptrcreate = wxc.ptrcreate
+
+ptrfree = wxc.ptrfree
+
+ptradd = wxc.ptradd
+
+ptrmap = wxc.ptrmap
+
 _wxStart = wxc._wxStart
 
 _wxSetDictionary = wxc._wxSetDictionary
 
+wxApp_CleanUp = wxc.wxApp_CleanUp
+
 
 
 #-------------- VARIABLE WRAPPERS ------------------
@@ -108,7 +141,7 @@ _wxSetDictionary = wxc._wxSetDictionary
 wxMAJOR_VERSION = wxc.wxMAJOR_VERSION
 wxMINOR_VERSION = wxc.wxMINOR_VERSION
 wxRELEASE_NUMBER = wxc.wxRELEASE_NUMBER
-NOT_FOUND = wxc.NOT_FOUND
+wxNOT_FOUND = wxc.wxNOT_FOUND
 wxVSCROLL = wxc.wxVSCROLL
 wxHSCROLL = wxc.wxHSCROLL
 wxCAPTION = wxc.wxCAPTION
@@ -123,10 +156,13 @@ wxNO_BORDER = wxc.wxNO_BORDER
 wxUSER_COLOURS = wxc.wxUSER_COLOURS
 wxNO_3D = wxc.wxNO_3D
 wxTAB_TRAVERSAL = wxc.wxTAB_TRAVERSAL
+wxWANTS_CHARS = wxc.wxWANTS_CHARS
 wxHORIZONTAL = wxc.wxHORIZONTAL
 wxVERTICAL = wxc.wxVERTICAL
 wxBOTH = wxc.wxBOTH
 wxCENTER_FRAME = wxc.wxCENTER_FRAME
+wxCENTRE_ON_SCREEN = wxc.wxCENTRE_ON_SCREEN
+wxCENTER_ON_SCREEN = wxc.wxCENTER_ON_SCREEN
 wxSTAY_ON_TOP = wxc.wxSTAY_ON_TOP
 wxICONIZE = wxc.wxICONIZE
 wxMINIMIZE = wxc.wxMINIMIZE
@@ -144,18 +180,33 @@ wxDIALOG_MODELESS = wxc.wxDIALOG_MODELESS
 wxDEFAULT_FRAME_STYLE = wxc.wxDEFAULT_FRAME_STYLE
 wxDEFAULT_DIALOG_STYLE = wxc.wxDEFAULT_DIALOG_STYLE
 wxFRAME_TOOL_WINDOW = wxc.wxFRAME_TOOL_WINDOW
+wxFRAME_FLOAT_ON_PARENT = wxc.wxFRAME_FLOAT_ON_PARENT
+wxED_CLIENT_MARGIN = wxc.wxED_CLIENT_MARGIN
+wxED_BUTTONS_BOTTOM = wxc.wxED_BUTTONS_BOTTOM
+wxED_BUTTONS_RIGHT = wxc.wxED_BUTTONS_RIGHT
+wxED_STATIC_LINE = wxc.wxED_STATIC_LINE
+wxEXT_DIALOG_STYLE = wxc.wxEXT_DIALOG_STYLE
+wxCLIP_CHILDREN = wxc.wxCLIP_CHILDREN
 wxRETAINED = wxc.wxRETAINED
 wxBACKINGSTORE = wxc.wxBACKINGSTORE
 wxTB_3DBUTTONS = wxc.wxTB_3DBUTTONS
 wxTB_HORIZONTAL = wxc.wxTB_HORIZONTAL
 wxTB_VERTICAL = wxc.wxTB_VERTICAL
 wxTB_FLAT = wxc.wxTB_FLAT
+wxTB_DOCKABLE = wxc.wxTB_DOCKABLE
 wxCOLOURED = wxc.wxCOLOURED
 wxFIXED_LENGTH = wxc.wxFIXED_LENGTH
 wxALIGN_LEFT = wxc.wxALIGN_LEFT
+wxALIGN_CENTER_HORIZONTAL = wxc.wxALIGN_CENTER_HORIZONTAL
+wxALIGN_CENTRE_HORIZONTAL = wxc.wxALIGN_CENTRE_HORIZONTAL
+wxALIGN_RIGHT = wxc.wxALIGN_RIGHT
+wxALIGN_BOTTOM = wxc.wxALIGN_BOTTOM
+wxALIGN_CENTER_VERTICAL = wxc.wxALIGN_CENTER_VERTICAL
+wxALIGN_CENTRE_VERTICAL = wxc.wxALIGN_CENTRE_VERTICAL
+wxALIGN_TOP = wxc.wxALIGN_TOP
 wxALIGN_CENTER = wxc.wxALIGN_CENTER
 wxALIGN_CENTRE = wxc.wxALIGN_CENTRE
-wxALIGN_RIGHT = wxc.wxALIGN_RIGHT
+wxSHAPED = wxc.wxSHAPED
 wxLB_NEEDED_SB = wxc.wxLB_NEEDED_SB
 wxLB_ALWAYS_SB = wxc.wxLB_ALWAYS_SB
 wxLB_SORT = wxc.wxLB_SORT
@@ -169,17 +220,23 @@ wxPASSWORD = wxc.wxPASSWORD
 wxTE_PROCESS_ENTER = wxc.wxTE_PROCESS_ENTER
 wxTE_PASSWORD = wxc.wxTE_PASSWORD
 wxTE_READONLY = wxc.wxTE_READONLY
+wxTE_RICH = wxc.wxTE_RICH
 wxTE_MULTILINE = wxc.wxTE_MULTILINE
+wxTE_AUTO_SCROLL = wxc.wxTE_AUTO_SCROLL
+wxTE_NO_VSCROLL = wxc.wxTE_NO_VSCROLL
 wxCB_SIMPLE = wxc.wxCB_SIMPLE
 wxCB_DROPDOWN = wxc.wxCB_DROPDOWN
 wxCB_SORT = wxc.wxCB_SORT
 wxCB_READONLY = wxc.wxCB_READONLY
 wxRA_HORIZONTAL = wxc.wxRA_HORIZONTAL
 wxRA_VERTICAL = wxc.wxRA_VERTICAL
+wxRA_SPECIFY_ROWS = wxc.wxRA_SPECIFY_ROWS
+wxRA_SPECIFY_COLS = wxc.wxRA_SPECIFY_COLS
 wxRB_GROUP = wxc.wxRB_GROUP
 wxGA_PROGRESSBAR = wxc.wxGA_PROGRESSBAR
 wxGA_HORIZONTAL = wxc.wxGA_HORIZONTAL
 wxGA_VERTICAL = wxc.wxGA_VERTICAL
+wxGA_SMOOTH = wxc.wxGA_SMOOTH
 wxSL_HORIZONTAL = wxc.wxSL_HORIZONTAL
 wxSL_VERTICAL = wxc.wxSL_VERTICAL
 wxSL_AUTOTICKS = wxc.wxSL_AUTOTICKS
@@ -192,11 +249,16 @@ wxSL_BOTH = wxc.wxSL_BOTH
 wxSL_SELRANGE = wxc.wxSL_SELRANGE
 wxSB_HORIZONTAL = wxc.wxSB_HORIZONTAL
 wxSB_VERTICAL = wxc.wxSB_VERTICAL
+wxST_SIZEGRIP = wxc.wxST_SIZEGRIP
+wxST_NO_AUTORESIZE = wxc.wxST_NO_AUTORESIZE
 wxBU_AUTODRAW = wxc.wxBU_AUTODRAW
 wxBU_NOAUTODRAW = wxc.wxBU_NOAUTODRAW
 wxTR_HAS_BUTTONS = wxc.wxTR_HAS_BUTTONS
 wxTR_EDIT_LABELS = wxc.wxTR_EDIT_LABELS
 wxTR_LINES_AT_ROOT = wxc.wxTR_LINES_AT_ROOT
+wxTR_MULTIPLE = wxc.wxTR_MULTIPLE
+wxTR_SINGLE = wxc.wxTR_SINGLE
+wxTR_HAS_VARIABLE_ROW_HEIGHT = wxc.wxTR_HAS_VARIABLE_ROW_HEIGHT
 wxLC_ICON = wxc.wxLC_ICON
 wxLC_SMALL_ICON = wxc.wxLC_SMALL_ICON
 wxLC_LIST = wxc.wxLC_LIST
@@ -221,10 +283,8 @@ wxSP_WRAP = wxc.wxSP_WRAP
 wxSP_NOBORDER = wxc.wxSP_NOBORDER
 wxSP_3D = wxc.wxSP_3D
 wxSP_BORDER = wxc.wxSP_BORDER
-wxTAB_MULTILINE = wxc.wxTAB_MULTILINE
-wxTAB_RIGHTJUSTIFY = wxc.wxTAB_RIGHTJUSTIFY
-wxTAB_FIXEDWIDTH = wxc.wxTAB_FIXEDWIDTH
-wxTAB_OWNERDRAW = wxc.wxTAB_OWNERDRAW
+wxSP_LIVE_UPDATE = wxc.wxSP_LIVE_UPDATE
+wxSP_PERMIT_UNSPLIT = wxc.wxSP_PERMIT_UNSPLIT
 wxFLOOD_SURFACE = wxc.wxFLOOD_SURFACE
 wxFLOOD_BORDER = wxc.wxFLOOD_BORDER
 wxODDEVEN_RULE = wxc.wxODDEVEN_RULE
@@ -238,6 +298,8 @@ wxYES_NO = wxc.wxYES_NO
 wxCANCEL = wxc.wxCANCEL
 wxYES = wxc.wxYES
 wxNO = wxc.wxNO
+wxNO_DEFAULT = wxc.wxNO_DEFAULT
+wxYES_DEFAULT = wxc.wxYES_DEFAULT
 wxICON_EXCLAMATION = wxc.wxICON_EXCLAMATION
 wxICON_HAND = wxc.wxICON_HAND
 wxICON_QUESTION = wxc.wxICON_QUESTION
@@ -245,6 +307,14 @@ wxICON_INFORMATION = wxc.wxICON_INFORMATION
 wxICON_STOP = wxc.wxICON_STOP
 wxICON_ASTERISK = wxc.wxICON_ASTERISK
 wxICON_MASK = wxc.wxICON_MASK
+wxICON_WARNING = wxc.wxICON_WARNING
+wxICON_ERROR = wxc.wxICON_ERROR
+wxFORWARD = wxc.wxFORWARD
+wxBACKWARD = wxc.wxBACKWARD
+wxRESET = wxc.wxRESET
+wxHELP = wxc.wxHELP
+wxMORE = wxc.wxMORE
+wxSETUP = wxc.wxSETUP
 wxCENTRE = wxc.wxCENTRE
 wxCENTER = wxc.wxCENTER
 wxSIZE_AUTO_WIDTH = wxc.wxSIZE_AUTO_WIDTH
@@ -252,14 +322,12 @@ wxSIZE_AUTO_HEIGHT = wxc.wxSIZE_AUTO_HEIGHT
 wxSIZE_AUTO = wxc.wxSIZE_AUTO
 wxSIZE_USE_EXISTING = wxc.wxSIZE_USE_EXISTING
 wxSIZE_ALLOW_MINUS_ONE = wxc.wxSIZE_ALLOW_MINUS_ONE
-wxDF_TEXT = wxc.wxDF_TEXT
-wxDF_BITMAP = wxc.wxDF_BITMAP
-wxDF_METAFILE = wxc.wxDF_METAFILE
-wxDF_DIB = wxc.wxDF_DIB
-wxDF_OEMTEXT = wxc.wxDF_OEMTEXT
-wxDF_FILENAME = wxc.wxDF_FILENAME
 wxPORTRAIT = wxc.wxPORTRAIT
 wxLANDSCAPE = wxc.wxLANDSCAPE
+wxPRINT_QUALITY_HIGH = wxc.wxPRINT_QUALITY_HIGH
+wxPRINT_QUALITY_MEDIUM = wxc.wxPRINT_QUALITY_MEDIUM
+wxPRINT_QUALITY_LOW = wxc.wxPRINT_QUALITY_LOW
+wxPRINT_QUALITY_DRAFT = wxc.wxPRINT_QUALITY_DRAFT
 wxID_OPEN = wxc.wxID_OPEN
 wxID_CLOSE = wxc.wxID_CLOSE
 wxID_NEW = wxc.wxID_NEW
@@ -297,6 +365,7 @@ wxID_CANCEL = wxc.wxID_CANCEL
 wxID_APPLY = wxc.wxID_APPLY
 wxID_YES = wxc.wxID_YES
 wxID_NO = wxc.wxID_NO
+wxID_STATIC = wxc.wxID_STATIC
 wxBITMAP_TYPE_BMP = wxc.wxBITMAP_TYPE_BMP
 wxBITMAP_TYPE_BMP_RESOURCE = wxc.wxBITMAP_TYPE_BMP_RESOURCE
 wxBITMAP_TYPE_ICO = wxc.wxBITMAP_TYPE_ICO
@@ -315,17 +384,48 @@ wxBITMAP_TYPE_PNG = wxc.wxBITMAP_TYPE_PNG
 wxBITMAP_TYPE_PNG_RESOURCE = wxc.wxBITMAP_TYPE_PNG_RESOURCE
 wxBITMAP_TYPE_ANY = wxc.wxBITMAP_TYPE_ANY
 wxBITMAP_TYPE_RESOURCE = wxc.wxBITMAP_TYPE_RESOURCE
+wxBITMAP_TYPE_JPEG = wxc.wxBITMAP_TYPE_JPEG
+wxBITMAP_TYPE_PCX = wxc.wxBITMAP_TYPE_PCX
 wxOPEN = wxc.wxOPEN
 wxSAVE = wxc.wxSAVE
 wxHIDE_READONLY = wxc.wxHIDE_READONLY
 wxOVERWRITE_PROMPT = wxc.wxOVERWRITE_PROMPT
+wxFILE_MUST_EXIST = wxc.wxFILE_MUST_EXIST
 wxACCEL_ALT = wxc.wxACCEL_ALT
 wxACCEL_CTRL = wxc.wxACCEL_CTRL
 wxACCEL_SHIFT = wxc.wxACCEL_SHIFT
-ERR_PARAM = wxc.ERR_PARAM
-ERR_NODATA = wxc.ERR_NODATA
-ERR_CANCEL = wxc.ERR_CANCEL
-ERR_SUCCESS = wxc.ERR_SUCCESS
+wxPD_AUTO_HIDE = wxc.wxPD_AUTO_HIDE
+wxPD_APP_MODAL = wxc.wxPD_APP_MODAL
+wxPD_CAN_ABORT = wxc.wxPD_CAN_ABORT
+wxPD_ELAPSED_TIME = wxc.wxPD_ELAPSED_TIME
+wxPD_ESTIMATED_TIME = wxc.wxPD_ESTIMATED_TIME
+wxPD_REMAINING_TIME = wxc.wxPD_REMAINING_TIME
+wxMENU_TEAROFF = wxc.wxMENU_TEAROFF
+wxMB_DOCKABLE = wxc.wxMB_DOCKABLE
+wxNO_FULL_REPAINT_ON_RESIZE = wxc.wxNO_FULL_REPAINT_ON_RESIZE
+wxLEFT = wxc.wxLEFT
+wxRIGHT = wxc.wxRIGHT
+wxUP = wxc.wxUP
+wxDOWN = wxc.wxDOWN
+wxALL = wxc.wxALL
+wxTOP = wxc.wxTOP
+wxBOTTOM = wxc.wxBOTTOM
+wxNORTH = wxc.wxNORTH
+wxSOUTH = wxc.wxSOUTH
+wxEAST = wxc.wxEAST
+wxWEST = wxc.wxWEST
+wxSTRETCH_NOT = wxc.wxSTRETCH_NOT
+wxSHRINK = wxc.wxSHRINK
+wxGROW = wxc.wxGROW
+wxEXPAND = wxc.wxEXPAND
+wxNB_FIXEDWIDTH = wxc.wxNB_FIXEDWIDTH
+wxNB_LEFT = wxc.wxNB_LEFT
+wxNB_RIGHT = wxc.wxNB_RIGHT
+wxNB_BOTTOM = wxc.wxNB_BOTTOM
+wxLI_HORIZONTAL = wxc.wxLI_HORIZONTAL
+wxLI_VERTICAL = wxc.wxLI_VERTICAL
+wxHW_SCROLLBAR_NEVER = wxc.wxHW_SCROLLBAR_NEVER
+wxHW_SCROLLBAR_AUTO = wxc.wxHW_SCROLLBAR_AUTO
 wxDEFAULT = wxc.wxDEFAULT
 wxDECORATIVE = wxc.wxDECORATIVE
 wxROMAN = wxc.wxROMAN
@@ -376,8 +476,6 @@ wxOR_INVERT = wxc.wxOR_INVERT
 wxNAND = wxc.wxNAND
 wxOR = wxc.wxOR
 wxSET = wxc.wxSET
-wxSRC_OR = wxc.wxSRC_OR
-wxSRC_AND = wxc.wxSRC_AND
 WXK_BACK = wxc.WXK_BACK
 WXK_TAB = wxc.WXK_TAB
 WXK_RETURN = wxc.WXK_RETURN
@@ -479,10 +577,81 @@ wxCURSOR_SPRAYCAN = wxc.wxCURSOR_SPRAYCAN
 wxCURSOR_WAIT = wxc.wxCURSOR_WAIT
 wxCURSOR_WATCH = wxc.wxCURSOR_WATCH
 wxCURSOR_BLANK = wxc.wxCURSOR_BLANK
+wxPAPER_NONE = wxc.wxPAPER_NONE
+wxPAPER_LETTER = wxc.wxPAPER_LETTER
+wxPAPER_LEGAL = wxc.wxPAPER_LEGAL
+wxPAPER_A4 = wxc.wxPAPER_A4
+wxPAPER_CSHEET = wxc.wxPAPER_CSHEET
+wxPAPER_DSHEET = wxc.wxPAPER_DSHEET
+wxPAPER_ESHEET = wxc.wxPAPER_ESHEET
+wxPAPER_LETTERSMALL = wxc.wxPAPER_LETTERSMALL
+wxPAPER_TABLOID = wxc.wxPAPER_TABLOID
+wxPAPER_LEDGER = wxc.wxPAPER_LEDGER
+wxPAPER_STATEMENT = wxc.wxPAPER_STATEMENT
+wxPAPER_EXECUTIVE = wxc.wxPAPER_EXECUTIVE
+wxPAPER_A3 = wxc.wxPAPER_A3
+wxPAPER_A4SMALL = wxc.wxPAPER_A4SMALL
+wxPAPER_A5 = wxc.wxPAPER_A5
+wxPAPER_B4 = wxc.wxPAPER_B4
+wxPAPER_B5 = wxc.wxPAPER_B5
+wxPAPER_FOLIO = wxc.wxPAPER_FOLIO
+wxPAPER_QUARTO = wxc.wxPAPER_QUARTO
+wxPAPER_10X14 = wxc.wxPAPER_10X14
+wxPAPER_11X17 = wxc.wxPAPER_11X17
+wxPAPER_NOTE = wxc.wxPAPER_NOTE
+wxPAPER_ENV_9 = wxc.wxPAPER_ENV_9
+wxPAPER_ENV_10 = wxc.wxPAPER_ENV_10
+wxPAPER_ENV_11 = wxc.wxPAPER_ENV_11
+wxPAPER_ENV_12 = wxc.wxPAPER_ENV_12
+wxPAPER_ENV_14 = wxc.wxPAPER_ENV_14
+wxPAPER_ENV_DL = wxc.wxPAPER_ENV_DL
+wxPAPER_ENV_C5 = wxc.wxPAPER_ENV_C5
+wxPAPER_ENV_C3 = wxc.wxPAPER_ENV_C3
+wxPAPER_ENV_C4 = wxc.wxPAPER_ENV_C4
+wxPAPER_ENV_C6 = wxc.wxPAPER_ENV_C6
+wxPAPER_ENV_C65 = wxc.wxPAPER_ENV_C65
+wxPAPER_ENV_B4 = wxc.wxPAPER_ENV_B4
+wxPAPER_ENV_B5 = wxc.wxPAPER_ENV_B5
+wxPAPER_ENV_B6 = wxc.wxPAPER_ENV_B6
+wxPAPER_ENV_ITALY = wxc.wxPAPER_ENV_ITALY
+wxPAPER_ENV_MONARCH = wxc.wxPAPER_ENV_MONARCH
+wxPAPER_ENV_PERSONAL = wxc.wxPAPER_ENV_PERSONAL
+wxPAPER_FANFOLD_US = wxc.wxPAPER_FANFOLD_US
+wxPAPER_FANFOLD_STD_GERMAN = wxc.wxPAPER_FANFOLD_STD_GERMAN
+wxPAPER_FANFOLD_LGL_GERMAN = wxc.wxPAPER_FANFOLD_LGL_GERMAN
+wxPAPER_ISO_B4 = wxc.wxPAPER_ISO_B4
+wxPAPER_JAPANESE_POSTCARD = wxc.wxPAPER_JAPANESE_POSTCARD
+wxPAPER_9X11 = wxc.wxPAPER_9X11
+wxPAPER_10X11 = wxc.wxPAPER_10X11
+wxPAPER_15X11 = wxc.wxPAPER_15X11
+wxPAPER_ENV_INVITE = wxc.wxPAPER_ENV_INVITE
+wxPAPER_LETTER_EXTRA = wxc.wxPAPER_LETTER_EXTRA
+wxPAPER_LEGAL_EXTRA = wxc.wxPAPER_LEGAL_EXTRA
+wxPAPER_TABLOID_EXTRA = wxc.wxPAPER_TABLOID_EXTRA
+wxPAPER_A4_EXTRA = wxc.wxPAPER_A4_EXTRA
+wxPAPER_LETTER_TRANSVERSE = wxc.wxPAPER_LETTER_TRANSVERSE
+wxPAPER_A4_TRANSVERSE = wxc.wxPAPER_A4_TRANSVERSE
+wxPAPER_LETTER_EXTRA_TRANSVERSE = wxc.wxPAPER_LETTER_EXTRA_TRANSVERSE
+wxPAPER_A_PLUS = wxc.wxPAPER_A_PLUS
+wxPAPER_B_PLUS = wxc.wxPAPER_B_PLUS
+wxPAPER_LETTER_PLUS = wxc.wxPAPER_LETTER_PLUS
+wxPAPER_A4_PLUS = wxc.wxPAPER_A4_PLUS
+wxPAPER_A5_TRANSVERSE = wxc.wxPAPER_A5_TRANSVERSE
+wxPAPER_B5_TRANSVERSE = wxc.wxPAPER_B5_TRANSVERSE
+wxPAPER_A3_EXTRA = wxc.wxPAPER_A3_EXTRA
+wxPAPER_A5_EXTRA = wxc.wxPAPER_A5_EXTRA
+wxPAPER_B5_EXTRA = wxc.wxPAPER_B5_EXTRA
+wxPAPER_A2 = wxc.wxPAPER_A2
+wxPAPER_A3_TRANSVERSE = wxc.wxPAPER_A3_TRANSVERSE
+wxPAPER_A3_EXTRA_TRANSVERSE = wxc.wxPAPER_A3_EXTRA_TRANSVERSE
+wxDUPLEX_SIMPLEX = wxc.wxDUPLEX_SIMPLEX
+wxDUPLEX_HORIZONTAL = wxc.wxDUPLEX_HORIZONTAL
+wxDUPLEX_VERTICAL = wxc.wxDUPLEX_VERTICAL
 FALSE = wxc.FALSE
 false = wxc.false
 TRUE = wxc.TRUE
 true = wxc.true
+wxVERSION_STRING = wxc.wxVERSION_STRING
 wxEVT_NULL = wxc.wxEVT_NULL
 wxEVT_FIRST = wxc.wxEVT_FIRST
 wxEVT_COMMAND_BUTTON_CLICKED = wxc.wxEVT_COMMAND_BUTTON_CLICKED
@@ -491,6 +660,7 @@ wxEVT_COMMAND_CHOICE_SELECTED = wxc.wxEVT_COMMAND_CHOICE_SELECTED
 wxEVT_COMMAND_LISTBOX_SELECTED = wxc.wxEVT_COMMAND_LISTBOX_SELECTED
 wxEVT_COMMAND_LISTBOX_DOUBLECLICKED = wxc.wxEVT_COMMAND_LISTBOX_DOUBLECLICKED
 wxEVT_COMMAND_CHECKLISTBOX_TOGGLED = wxc.wxEVT_COMMAND_CHECKLISTBOX_TOGGLED
+wxEVT_COMMAND_SPINCTRL_UPDATED = wxc.wxEVT_COMMAND_SPINCTRL_UPDATED
 wxEVT_COMMAND_TEXT_UPDATED = wxc.wxEVT_COMMAND_TEXT_UPDATED
 wxEVT_COMMAND_TEXT_ENTER = wxc.wxEVT_COMMAND_TEXT_ENTER
 wxEVT_COMMAND_MENU_SELECTED = wxc.wxEVT_COMMAND_MENU_SELECTED
@@ -530,6 +700,9 @@ wxEVT_NC_LEFT_DCLICK = wxc.wxEVT_NC_LEFT_DCLICK
 wxEVT_NC_MIDDLE_DCLICK = wxc.wxEVT_NC_MIDDLE_DCLICK
 wxEVT_NC_RIGHT_DCLICK = wxc.wxEVT_NC_RIGHT_DCLICK
 wxEVT_CHAR = wxc.wxEVT_CHAR
+wxEVT_KEY_DOWN = wxc.wxEVT_KEY_DOWN
+wxEVT_KEY_UP = wxc.wxEVT_KEY_UP
+wxEVT_CHAR_HOOK = wxc.wxEVT_CHAR_HOOK
 wxEVT_SCROLL_TOP = wxc.wxEVT_SCROLL_TOP
 wxEVT_SCROLL_BOTTOM = wxc.wxEVT_SCROLL_BOTTOM
 wxEVT_SCROLL_LINEUP = wxc.wxEVT_SCROLL_LINEUP
@@ -537,6 +710,15 @@ wxEVT_SCROLL_LINEDOWN = wxc.wxEVT_SCROLL_LINEDOWN
 wxEVT_SCROLL_PAGEUP = wxc.wxEVT_SCROLL_PAGEUP
 wxEVT_SCROLL_PAGEDOWN = wxc.wxEVT_SCROLL_PAGEDOWN
 wxEVT_SCROLL_THUMBTRACK = wxc.wxEVT_SCROLL_THUMBTRACK
+wxEVT_SCROLL_THUMBRELEASE = wxc.wxEVT_SCROLL_THUMBRELEASE
+wxEVT_SCROLLWIN_TOP = wxc.wxEVT_SCROLLWIN_TOP
+wxEVT_SCROLLWIN_BOTTOM = wxc.wxEVT_SCROLLWIN_BOTTOM
+wxEVT_SCROLLWIN_LINEUP = wxc.wxEVT_SCROLLWIN_LINEUP
+wxEVT_SCROLLWIN_LINEDOWN = wxc.wxEVT_SCROLLWIN_LINEDOWN
+wxEVT_SCROLLWIN_PAGEUP = wxc.wxEVT_SCROLLWIN_PAGEUP
+wxEVT_SCROLLWIN_PAGEDOWN = wxc.wxEVT_SCROLLWIN_PAGEDOWN
+wxEVT_SCROLLWIN_THUMBTRACK = wxc.wxEVT_SCROLLWIN_THUMBTRACK
+wxEVT_SCROLLWIN_THUMBRELEASE = wxc.wxEVT_SCROLLWIN_THUMBRELEASE
 wxEVT_SIZE = wxc.wxEVT_SIZE
 wxEVT_MOVE = wxc.wxEVT_MOVE
 wxEVT_CLOSE_WINDOW = wxc.wxEVT_CLOSE_WINDOW
@@ -544,8 +726,6 @@ wxEVT_END_SESSION = wxc.wxEVT_END_SESSION
 wxEVT_QUERY_END_SESSION = wxc.wxEVT_QUERY_END_SESSION
 wxEVT_ACTIVATE_APP = wxc.wxEVT_ACTIVATE_APP
 wxEVT_POWER = wxc.wxEVT_POWER
-wxEVT_CHAR_HOOK = wxc.wxEVT_CHAR_HOOK
-wxEVT_KEY_UP = wxc.wxEVT_KEY_UP
 wxEVT_ACTIVATE = wxc.wxEVT_ACTIVATE
 wxEVT_CREATE = wxc.wxEVT_CREATE
 wxEVT_DESTROY = wxc.wxEVT_DESTROY
@@ -598,6 +778,9 @@ 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
@@ -611,10 +794,18 @@ 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
 __version__ = wxc.__version__
 cvar = wxc.cvar
 wxPyDefaultPosition = wxPointPtr(wxc.cvar.wxPyDefaultPosition)
@@ -660,8 +851,9 @@ def _StdWindowCallbacks(win):
     _checkForCallback(win, "OnEraseBackground",    wxEVT_ERASE_BACKGROUND)
     _checkForCallback(win, "OnSysColourChanged",   wxEVT_SYS_COLOUR_CHANGED)
     _checkForCallback(win, "OnInitDialog",         wxEVT_INIT_DIALOG)
-    _checkForCallback(win, "OnIdle",               wxEVT_IDLE)
     _checkForCallback(win, "OnPaint",              wxEVT_PAINT)
+    _checkForCallback(win, "OnIdle",               wxEVT_IDLE)
+
 
 def _StdFrameCallbacks(win):
     _StdWindowCallbacks(win)
@@ -679,7 +871,7 @@ def _StdDialogCallbacks(win):
     _checkForCallback(win, "OnCharHook",    wxEVT_CHAR_HOOK)
 
 
-def _StdOnScrollCallback(win):
+def _StdOnScrollCallbacks(win):
     try:    cb = getattr(win, "OnScroll")
     except: pass
     else:   EVT_SCROLL(win, cb)
@@ -713,6 +905,12 @@ def EVT_CHAR(win, func):
 def EVT_CHAR_HOOK(win, func):
     win.Connect(-1, -1, wxEVT_CHAR_HOOK, func)
 
+def EVT_KEY_DOWN(win, func):
+    win.Connect(-1, -1, wxEVT_KEY_DOWN, func)
+
+def EVT_KEY_UP(win, func):
+    win.Connect(-1, -1, wxEVT_KEY_UP, func)
+
 def EVT_MENU_HIGHLIGHT(win, id, func):
     win.Connect(id, -1, wxEVT_MENU_HIGHLIGHT, func)
 
@@ -758,6 +956,29 @@ def EVT_ICONIZE(win, func):
 def EVT_NAVIGATION_KEY(win, func):
     win.Connect(-1, -1, wxEVT_NAVIGATION_KEY, func)
 
+def EVT_PALETTE_CHANGED(win, func):
+    win.Connect(-1, -1, wxEVT_PALETTE_CHANGED, func)
+
+def EVT_QUERY_NEW_PALETTE(win, func):
+    win.Connect(-1, -1, wxEVT_QUERY_NEW_PALETTE, func)
+
+def EVT_WINDOW_CREATE(win, func):
+    win.Connect(-1, -1, wxEVT_CREATE, func)
+
+def EVT_WINDOW_DESTROY(win, func):
+    win.Connect(-1, -1, wxEVT_DESTROY, func)
+
+
+
+def EVT_IDLE(win, func):
+    win.Connect(-1, -1, wxEVT_IDLE, func)
+
+def EVT_UPDATE_UI(win, id, func):
+    win.Connect(id, -1, wxEVT_UPDATE_UI, func)
+
+def EVT_UPDATE_UI_RANGE(win, id, id2, func):
+    win.Connect(id, id2, wxEVT_UPDATE_UI, func)
+
 
 # Mouse Events
 def EVT_LEFT_DOWN(win, func):
@@ -819,6 +1040,7 @@ def EVT_COMMAND(win, id, cmd, func):
 def EVT_COMMAND_RANGE(win, id1, id2, cmd, func):
     win.Connect(id1, id2, cmd, func)
 
+
 # Scrolling
 def EVT_SCROLL(win, func):
     win.Connect(-1, -1, wxEVT_SCROLL_TOP,       func)
@@ -828,6 +1050,7 @@ def EVT_SCROLL(win, func):
     win.Connect(-1, -1, wxEVT_SCROLL_PAGEUP,    func)
     win.Connect(-1, -1, wxEVT_SCROLL_PAGEDOWN,  func)
     win.Connect(-1, -1, wxEVT_SCROLL_THUMBTRACK,func)
+    win.Connect(-1, -1, wxEVT_SCROLL_THUMBRELEASE,func)
 
 def EVT_SCROLL_TOP(win, func):
     win.Connect(-1, -1, wxEVT_SCROLL_TOP, func)
@@ -850,6 +1073,9 @@ def EVT_SCROLL_PAGEDOWN(win, func):
 def EVT_SCROLL_THUMBTRACK(win, func):
     win.Connect(-1, -1, wxEVT_SCROLL_THUMBTRACK, func)
 
+def EVT_SCROLL_THUMBRELEASE(win, func):
+    win.Connect(-1, -1, wxEVT_SCROLL_THUMBRELEASE, func)
+
 
 
 # Scrolling, with an id
@@ -861,6 +1087,7 @@ def EVT_COMMAND_SCROLL(win, id, func):
     win.Connect(id, -1, wxEVT_SCROLL_PAGEUP,    func)
     win.Connect(id, -1, wxEVT_SCROLL_PAGEDOWN,  func)
     win.Connect(id, -1, wxEVT_SCROLL_THUMBTRACK,func)
+    win.Connect(id, -1, wxEVT_SCROLL_THUMBRELEASE,func)
 
 def EVT_COMMAND_SCROLL_TOP(win, id, func):
     win.Connect(id, -1, wxEVT_SCROLL_TOP, func)
@@ -883,6 +1110,81 @@ def EVT_COMMAND_SCROLL_PAGEDOWN(win, id, func):
 def EVT_COMMAND_SCROLL_THUMBTRACK(win, id, func):
     win.Connect(id, -1, wxEVT_SCROLL_THUMBTRACK, func)
 
+def EVT_COMMAND_SCROLL_THUMBRELEASE(win, id, func):
+    win.Connect(id, -1, wxEVT_SCROLL_THUMBRELEASE, func)
+
+#---
+def EVT_SCROLLWIN(win, func):
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_TOP,         func)
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_BOTTOM,      func)
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_LINEUP,      func)
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_LINEDOWN,    func)
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_PAGEUP,      func)
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_PAGEDOWN,    func)
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_THUMBTRACK,  func)
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_THUMBRELEASE,func)
+
+def EVT_SCROLLWIN_TOP(win, func):
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_TOP, func)
+
+def EVT_SCROLLWIN_BOTTOM(win, func):
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_BOTTOM, func)
+
+def EVT_SCROLLWIN_LINEUP(win, func):
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_LINEUP, func)
+
+def EVT_SCROLLWIN_LINEDOWN(win, func):
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_LINEDOWN, func)
+
+def EVT_SCROLLWIN_PAGEUP(win, func):
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_PAGEUP, func)
+
+def EVT_SCROLLWIN_PAGEDOWN(win, func):
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_PAGEDOWN, func)
+
+def EVT_SCROLLWIN_THUMBTRACK(win, func):
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_THUMBTRACK, func)
+
+def EVT_SCROLLWIN_THUMBRELEASE(win, func):
+    win.Connect(-1, -1, wxEVT_SCROLLWIN_THUMBRELEASE, func)
+
+
+
+# Scrolling, with an id
+def EVT_COMMAND_SCROLLWIN(win, id, func):
+    win.Connect(id, -1, wxEVT_SCROLLWIN_TOP,         func)
+    win.Connect(id, -1, wxEVT_SCROLLWIN_BOTTOM,      func)
+    win.Connect(id, -1, wxEVT_SCROLLWIN_LINEUP,      func)
+    win.Connect(id, -1, wxEVT_SCROLLWIN_LINEDOWN,    func)
+    win.Connect(id, -1, wxEVT_SCROLLWIN_PAGEUP,      func)
+    win.Connect(id, -1, wxEVT_SCROLLWIN_PAGEDOWN,    func)
+    win.Connect(id, -1, wxEVT_SCROLLWIN_THUMBTRACK,  func)
+    win.Connect(id, -1, wxEVT_SCROLLWIN_THUMBRELEASE,func)
+
+def EVT_COMMAND_SCROLLWIN_TOP(win, id, func):
+    win.Connect(id, -1, wxEVT_SCROLLWIN_TOP, func)
+
+def EVT_COMMAND_SCROLLWIN_BOTTOM(win, id, func):
+    win.Connect(id, -1, wxEVT_SCROLLWIN_BOTTOM, func)
+
+def EVT_COMMAND_SCROLLWIN_LINEUP(win, id, func):
+    win.Connect(id, -1, wxEVT_SCROLLWIN_LINEUP, func)
+
+def EVT_COMMAND_SCROLLWIN_LINEDOWN(win, id, func):
+    win.Connect(id, -1, wxEVT_SCROLLWIN_LINEDOWN, func)
+
+def EVT_COMMAND_SCROLLWIN_PAGEUP(win, id, func):
+    win.Connect(id, -1, wxEVT_SCROLLWIN_PAGEUP, func)
+
+def EVT_COMMAND_SCROLLWIN_PAGEDOWN(win, id, func):
+    win.Connect(id, -1, wxEVT_SCROLLWIN_PAGEDOWN, func)
+
+def EVT_COMMAND_SCROLLWIN_THUMBTRACK(win, id, func):
+    win.Connect(id, -1, wxEVT_SCROLLWIN_THUMBTRACK, func)
+
+def EVT_COMMAND_SCROLLWIN_THUMBRELEASE(win, id, func):
+    win.Connect(id, -1, wxEVT_SCROLLWIN_THUMBRELEASE, func)
+
 
 # Convenience commands
 def EVT_BUTTON(win, id, func):
@@ -930,15 +1232,25 @@ def EVT_COMBOBOX(win, id, func):
 def EVT_TOOL(win, id, func):
     win.Connect(id, -1, wxEVT_COMMAND_TOOL_CLICKED, func)
 
+def EVT_TOOL_RANGE(win, id, id2, func):
+    win.Connect(id, id2, wxEVT_COMMAND_TOOL_CLICKED, func)
+
 def EVT_TOOL_RCLICKED(win, id, func):
     win.Connect(id, -1, wxEVT_COMMAND_TOOL_RCLICKED, func)
 
+def EVT_TOOL_RCLICKED_RANGE(win, id, id2, func):
+    win.Connect(id, id2, wxEVT_COMMAND_TOOL_RCLICKED, func)
+
 def EVT_TOOL_ENTER(win, id, func):
     win.Connect(id, -1, wxEVT_COMMAND_TOOL_ENTER, func)
 
 def EVT_CHECKLISTBOX(win, id, func):
     win.Connect(id, -1, wxEVT_COMMAND_CHECKLISTBOX_TOGGLED, func)
 
+def EVT_SPINCTRL(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_SPINCTRL_UPDATED, func)
+
+
 
 # Generic command events
 
@@ -1015,6 +1327,15 @@ def EVT_TREE_KEY_DOWN(win, id, func):
 def EVT_TREE_DELETE_ITEM(win, id, func):
     win.Connect(id, -1, wxEVT_COMMAND_TREE_DELETE_ITEM, func)
 
+def EVT_TREE_ITEM_ACTIVATED(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_TREE_ITEM_ACTIVATED, func)
+
+def EVT_TREE_ITEM_RIGHT_CLICK(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK, func)
+
+def EVT_TREE_ITEM_MIDDLE_CLICK(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK, func)
+
 
 # wxSpinButton
 def EVT_SPIN_UP(win, id, func):
@@ -1087,6 +1408,83 @@ def EVT_GRID_LABEL_RCLICK(win, fn):
     win.Connect(-1, -1, wxEVT_GRID_LABEL_RCLICK, fn)
 
 
+# wxSashWindow
+def EVT_SASH_DRAGGED(win, id, func):
+    win.Connect(id, -1, wxEVT_SASH_DRAGGED, func)
+
+def EVT_SASH_DRAGGED_RANGE(win, id1, id2, func):
+    win.Connect(id1, id2, wxEVT_SASH_DRAGGED, func)
+
+def EVT_QUERY_LAYOUT_INFO(win, func):
+    win.Connect(-1, -1, wxEVT_EVT_QUERY_LAYOUT_INFO, func)
+
+def EVT_CALCULATE_LAYOUT(win, func):
+    win.Connect(-1, -1, wxEVT_EVT_CALCULATE_LAYOUT, func)
+
+
+# wxListCtrl
+def EVT_LIST_BEGIN_DRAG(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_BEGIN_DRAG, func)
+
+def EVT_LIST_BEGIN_RDRAG(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_BEGIN_RDRAG, func)
+
+def EVT_LIST_BEGIN_LABEL_EDIT(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT, func)
+
+def EVT_LIST_END_LABEL_EDIT(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_END_LABEL_EDIT, func)
+
+def EVT_LIST_DELETE_ITEM(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_DELETE_ITEM, func)
+
+def EVT_LIST_DELETE_ALL_ITEMS(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS, func)
+
+def EVT_LIST_GET_INFO(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_GET_INFO, func)
+
+def EVT_LIST_SET_INFO(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_SET_INFO, func)
+
+def EVT_LIST_ITEM_SELECTED(win, id, func):
+    win.Connect(id, -1,  wxEVT_COMMAND_LIST_ITEM_SELECTED, func)
+
+def EVT_LIST_ITEM_ACTIVATED(win, id, func):
+    win.Connect(id, -1,  wxEVT_COMMAND_LIST_ITEM_ACTIVATED, func)
+
+def EVT_LIST_ITEM_DESELECTED(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_ITEM_DESELECTED, func)
+
+def EVT_LIST_KEY_DOWN(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_KEY_DOWN, func)
+
+def EVT_LIST_INSERT_ITEM(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_INSERT_ITEM, func)
+
+def EVT_LIST_COL_CLICK(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_COL_CLICK, func)
+
+def EVT_LIST_ITEM_RIGHT_CLICK(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK, func)
+
+def EVT_LIST_ITEM_MIDDLE_CLICK(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK, func)
+
+
+
+#wxSplitterWindow
+def EVT_SPLITTER_SASH_POS_CHANGING(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING, func)
+
+def EVT_SPLITTER_SASH_POS_CHANGED(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED, func)
+
+def EVT_SPLITTER_UNSPLIT(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_SPLITTER_UNSPLIT, func)
+
+def EVT_SPLITTER_DOUBLECLICKED(win, id, func):
+    win.Connect(id, -1, wxEVT_COMMAND_SPLITTER_DOUBLECLICKED, func)
 
 
 #----------------------------------------------------------------------
@@ -1116,27 +1514,83 @@ wxNamedColor = wxNamedColour
 wxPyDefaultPosition.Set(-1,-1)
 wxPyDefaultSize.Set(-1,-1)
 
+# aliases so that C++ documentation applies:
+wxDefaultPosition  = wxPyDefaultPosition
+wxDefaultSize      = wxPyDefaultSize
+
+# backwards compatibility
+wxNoRefBitmap      = wxBitmap
+
+#----------------------------------------------------------------------
+# This helper function will take a wxPython object and convert it to
+# another wxPython object type.  This will not be able to create objects
+# that are derived from wxPython classes by the user, only those that are
+# actually part of wxPython and directly corespond to C++ objects.
+#
+# This is useful in situations where some method returns a generic
+# type such as wxWindow, but you know that it is actually some
+# derived type such as a wxTextCtrl.  You can't call wxTextCtrl specific
+# methods on a wxWindow object, but you can use this function to
+# create a wxTextCtrl object that will pass the same pointer to
+# the C++ code.  You use it like this:
+#
+#    textCtrl = wxPyTypeCast(window, "wxTextCtrl")
+#
+#
+# WARNING:  Using this function to type cast objects into types that
+#           they are not is not recommended and is likely to cause your
+#           program to crash...  Hard.
+#
+
+def wxPyTypeCast(obj, typeStr):
+    if hasattr(obj, "this"):
+        newPtr = ptrcast(obj.this, typeStr+"_p")
+    else:
+        newPtr = ptrcast(obj, typeStr+"_p")
+    theClass = globals()[typeStr+"Ptr"]
+    theObj = theClass(newPtr)
+    if hasattr(obj, "this"):
+        theObj.thisown = obj.thisown
+    return theObj
+
+
 #----------------------------------------------------------------------
 
-## class wxPyStdOutWindow(wxFrame):
-##     def __init__(self, title = "wxPython: stdout/stderr"):
-##         wxFrame.__init__(self, NULL, title)
-##         self.title = title
-##         self.text = wxTextWindow(self)
-##         self.text.SetFont(wxFont(10, wxMODERN, wxNORMAL, wxBOLD))
-##         self.SetSize(-1,-1,400,200)
-##         self.Show(false)
-##         self.isShown = false
+class wxPyOnDemandOutputWindow:
+    def __init__(self, title = "wxPython: stdout/stderr"):
+        self.frame  = None
+        self.title  = title
+
+
+    def SetParent(self, parent):
+        self.parent = parent
+
+
+    def OnCloseWindow(self, event):
+        if self.frame != None:
+            self.frame.Destroy()
+        self.frame = None
+        self.text  = None
 
-##     def write(self, str):  # with this method,
-##         if not self.isShown:
-##             self.Show(true)
-##             self.isShown = true
-##         self.text.WriteText(str)
 
-##     def OnCloseWindow(self, event): # doesn't allow the window to close, just hides it
-##         self.Show(false)
-##         self.isShown = false
+    # this provides the file-like behaviour
+    def write(self, str):
+        if not self.frame:
+            self.frame = wxFrame(self.parent, -1, self.title)
+            self.text  = wxTextCtrl(self.frame, -1, "",
+                                    style = wxTE_MULTILINE|wxTE_READONLY)
+            self.frame.SetSize(wxSize(450, 300))
+            self.frame.Show(true)
+            EVT_CLOSE(self.frame, self.OnCloseWindow)
+        self.text.AppendText(str)
+
+
+    def close(self):
+        if self.frame != None:
+            self.frame.Destroy()
+        self.frame = None
+        self.text  = None
+
 
 
 _defRedirect = (wxPlatform == '__WXMSW__')
@@ -1147,6 +1601,7 @@ _defRedirect = (wxPlatform == '__WXMSW__')
 
 class wxApp(wxPyApp):
     error = 'wxApp.error'
+    outputWindowClass = wxPyOnDemandOutputWindow
 
     def __init__(self, redirect=_defRedirect, filename=None):
         wxPyApp.__init__(self)
@@ -1154,7 +1609,6 @@ class wxApp(wxPyApp):
         self.saveStdio = (sys.stdout, sys.stderr)
         if redirect:
             self.RedirectStdio(filename)
-
         # this initializes wxWindows and then calls our OnInit
         _wxStart(self.OnInit)
 
@@ -1165,55 +1619,54 @@ class wxApp(wxPyApp):
         except:
             pass
 
+
+    def SetTopWindow(self, frame):
+        if self.stdioWin:
+            self.stdioWin.SetParent(frame)
+            sys.stderr = sys.stdout = self.stdioWin
+        wxPyApp.SetTopWindow(self, frame)
+
+
+    def MainLoop(self):
+        wxPyApp.MainLoop(self)
+        self.RestoreStdio()
+
+
     def RedirectStdio(self, filename):
         if filename:
             sys.stdout = sys.stderr = open(filename, 'a')
         else:
-            raise self.error, 'wxPyStdOutWindow not yet implemented.'
-            #self.stdioWin = sys.stdout = sys.stderr = wxPyStdOutWindow()
+            self.stdioWin = self.outputWindowClass() # wxPyOnDemandOutputWindow
+
 
     def RestoreStdio(self):
         sys.stdout, sys.stderr = self.saveStdio
         if self.stdioWin != None:
-            self.stdioWin.Show(false)
-            self.stdioWin.Destroy()
-            self.stdioWin = None
+            self.stdioWin.close()
+
+#----------------------------------------------------------------------------
+
+class wxPySimpleApp(wxApp):
+    def __init__(self):
+        wxApp.__init__(self, 0)
+    def OnInit(self):
+        return true
 
 
 #----------------------------------------------------------------------------
-#
-# $Log$
-# Revision 1.2  1998/12/16 22:12:22  RD
-# Tweaks needed to be able to build wxPython with wxGTK.
-#
-# Revision 1.7  1998/11/25 08:45:21  RD
-#
-# Added wxPalette, wxRegion, wxRegionIterator, wxTaskbarIcon
-# Added events for wxGrid
-# Other various fixes and additions
-#
-# Revision 1.6  1998/11/16 00:00:52  RD
-# Generic treectrl for wxPython/GTK compiles...
-#
-# Revision 1.5  1998/10/20 07:38:02  RD
-# bug fix
-#
-# Revision 1.4  1998/10/20 06:43:54  RD
-# New wxTreeCtrl wrappers (untested)
-# some changes in helpers
-# etc.
-#
-# Revision 1.3  1998/10/02 06:40:33  RD
-#
-# Version 0.4 of wxPython for MSW.
-#
-# Revision 1.2  1998/08/18 19:48:12  RD
-# more wxGTK compatibility things.
-#
-# It builds now but there are serious runtime problems...
-#
-# Revision 1.1  1998/08/09 08:25:49  RD
-# Initial version
-#
-#
+# DO NOT hold any other references to this object.  This is how we know when
+# to cleanup system resources that wxWin is holding.  When this module is
+# unloaded, the refcount on __cleanMeUp goes to zero and it calls the
+# wxApp_CleanUp function.
+
+class __wxPyCleanup:
+    def __init__(self):
+        self.cleanup = wxc.wxApp_CleanUp
+    def __del__(self):
+        self.cleanup()
+
+__cleanMeUp = __wxPyCleanup()
+#----------------------------------------------------------------------------
+
+