diff --git a/utils/wxPython/modules/stc/build.cfg b/utils/wxPython/modules/stc/build.cfg index 7e237e31c7..cd645dd9c0 100644 --- a/utils/wxPython/modules/stc/build.cfg +++ b/utils/wxPython/modules/stc/build.cfg @@ -19,7 +19,6 @@ else: '-Icontrib/src/stc/scintilla/include -Icontrib/include ' + \ '-Icontrib/src/stc/scintilla/src' SOURCES = SOURCES + [ - 'contrib/src/stc/scintilla/src/Accessor.cxx', 'contrib/src/stc/scintilla/src/AutoComplete.cxx', 'contrib/src/stc/scintilla/src/CallTip.cxx', 'contrib/src/stc/scintilla/src/CellBuffer.cxx', @@ -41,6 +40,9 @@ else: 'contrib/src/stc/scintilla/src/LexPython.cxx', 'contrib/src/stc/scintilla/src/LexSQL.cxx', 'contrib/src/stc/scintilla/src/LexVB.cxx', + 'contrib/src/stc/scintilla/src/DocumentAccessor.cxx', + 'contrib/src/stc/scintilla/src/UniConversion.cxx', + 'contrib/src/stc/scintilla/src/WindowAccessor.cxx', 'contrib/src/stc/PlatWX.cpp', 'contrib/src/stc/ScintillaWX.cpp', diff --git a/utils/wxPython/modules/stc/stc_.cpp b/utils/wxPython/modules/stc/stc_.cpp index f8c99eec2e..b30016b1c2 100644 --- a/utils/wxPython/modules/stc/stc_.cpp +++ b/utils/wxPython/modules/stc/stc_.cpp @@ -1,5 +1,5 @@ /* - * FILE : ./stc_.cpp + * FILE : stc_.cpp * * This file was automatically generated by : * Simplified Wrapper and Interface Generator (SWIG) diff --git a/utils/wxPython/src/build.cfg b/utils/wxPython/src/build.cfg index c77d9cfa96..29d58af10b 100644 --- a/utils/wxPython/src/build.cfg +++ b/utils/wxPython/src/build.cfg @@ -40,7 +40,7 @@ else: OTHERINSTALLTARGETS = 'installLibDemo installHelpers ' OTHERUNINSTALLTARGETS = 'uninstallLibDemo uninstallHelpers ' - + OTHERLFLAGS = '-L. ' OTHERRULES = """ lib$(HELPERLIB)$(SO) : helpers.o libpy.o $(LDSHARED) helpers.o libpy.o $(LFLAGS) -o $@ diff --git a/utils/wxPython/src/gtk/gdi.py b/utils/wxPython/src/gtk/gdi.py index 178575bd5a..b701d83a66 100644 --- a/utils/wxPython/src/gtk/gdi.py +++ b/utils/wxPython/src/gtk/gdi.py @@ -53,6 +53,14 @@ class wxBitmapPtr : return val def __repr__(self): return "" % (self.this,) + + def __del__(self,gdic=gdic): + try: + if self.thisown == 1 : + gdic.delete_wxBitmap(self) + except: + pass + class wxBitmap(wxBitmapPtr): def __init__(self,*_args,**_kwargs): self.this = apply(gdic.new_wxBitmap,_args,_kwargs) @@ -108,6 +116,14 @@ class wxIconPtr : return val def __repr__(self): return "" % (self.this,) + + def __del__(self,gdic=gdic): + try: + if self.thisown == 1 : + gdic.delete_wxIcon(self) + except: + pass + class wxIcon(wxIconPtr): def __init__(self,*_args,**_kwargs): self.this = apply(gdic.new_wxIcon,_args,_kwargs) diff --git a/utils/wxPython/src/gtk/grid.cpp b/utils/wxPython/src/gtk/grid.cpp index f81a1b7249..c32062f364 100644 --- a/utils/wxPython/src/gtk/grid.cpp +++ b/utils/wxPython/src/gtk/grid.cpp @@ -1454,6 +1454,76 @@ static PyObject *_wrap_wxGridCellEditor_IsCreated(PyObject *self, PyObject *args return _resultobj; } +#define wxGridCellEditor_GetControl(_swigobj) (_swigobj->GetControl()) +static PyObject *_wrap_wxGridCellEditor_GetControl(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxControl * _result; + wxGridCellEditor * _arg0; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self", NULL }; + char _ptemp[128]; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxGridCellEditor_GetControl",_kwnames,&_argo0)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGridCellEditor_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGridCellEditor_GetControl. Expected _wxGridCellEditor_p."); + return NULL; + } + } +{ + wxPy_BEGIN_ALLOW_THREADS; + _result = (wxControl *)wxGridCellEditor_GetControl(_arg0); + + wxPy_END_ALLOW_THREADS; +} if (_result) { + SWIG_MakePtr(_ptemp, (char *) _result,"_wxControl_p"); + _resultobj = Py_BuildValue("s",_ptemp); + } else { + Py_INCREF(Py_None); + _resultobj = Py_None; + } + return _resultobj; +} + +#define wxGridCellEditor_SetControl(_swigobj,_swigarg0) (_swigobj->SetControl(_swigarg0)) +static PyObject *_wrap_wxGridCellEditor_SetControl(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + wxGridCellEditor * _arg0; + wxControl * _arg1; + PyObject * _argo0 = 0; + PyObject * _argo1 = 0; + char *_kwnames[] = { "self","control", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxGridCellEditor_SetControl",_kwnames,&_argo0,&_argo1)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGridCellEditor_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGridCellEditor_SetControl. Expected _wxGridCellEditor_p."); + return NULL; + } + } + if (_argo1) { + if (_argo1 == Py_None) { _arg1 = NULL; } + else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxControl_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxGridCellEditor_SetControl. Expected _wxControl_p."); + return NULL; + } + } +{ + wxPy_BEGIN_ALLOW_THREADS; + wxGridCellEditor_SetControl(_arg0,_arg1); + + wxPy_END_ALLOW_THREADS; +} Py_INCREF(Py_None); + _resultobj = Py_None; + return _resultobj; +} + #define wxGridCellEditor_SetParameters(_swigobj,_swigarg0) (_swigobj->SetParameters(_swigarg0)) static PyObject *_wrap_wxGridCellEditor_SetParameters(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -2433,39 +2503,40 @@ static void *SwigwxGridCellChoiceEditorTowxGridCellEditor(void *ptr) { return (void *) dest; } -static wxGridCellChoiceEditor *new_wxGridCellChoiceEditor(PyObject *choices,bool allowOthers) { - - const char** temp = string_LIST_helper(choices); - if (temp) { - int count = PyList_Size(choices); - wxGridCellChoiceEditor* ret; - ret = new wxGridCellChoiceEditor(count, temp, allowOthers); - delete [] temp; - return ret; - } - return NULL; - } - +#define new_wxGridCellChoiceEditor(_swigarg0,_swigarg1,_swigarg2) (new wxGridCellChoiceEditor(_swigarg0,_swigarg1,_swigarg2)) static PyObject *_wrap_new_wxGridCellChoiceEditor(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; wxGridCellChoiceEditor * _result; - PyObject * _arg0; - bool _arg1 = (bool ) FALSE; - PyObject * _obj0 = 0; - int tempbool1 = (int) FALSE; + int _arg0 = (int ) 0; + wxString * _arg1 = (wxString *) NULL; + bool _arg2 = (bool ) FALSE; + PyObject * _obj1 = 0; + int tempbool2 = (int) FALSE; char *_kwnames[] = { "choices","allowOthers", NULL }; char _ptemp[128]; self = self; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:new_wxGridCellChoiceEditor",_kwnames,&_obj0,&tempbool1)) + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|Oi:new_wxGridCellChoiceEditor",_kwnames,&_obj1,&tempbool2)) return NULL; + if (_obj1) { - _arg0 = _obj0; + _arg1 = wxString_LIST_helper(_obj1); + if (_arg1 == NULL) { + return NULL; + } +} + _arg2 = (bool ) tempbool2; +{ + if (_obj1) { + _arg0 = PyList_Size(_obj1); + } + else { + _arg0 = 0; + } } - _arg1 = (bool ) tempbool1; { wxPy_BEGIN_ALLOW_THREADS; - _result = (wxGridCellChoiceEditor *)new_wxGridCellChoiceEditor(_arg0,_arg1); + _result = (wxGridCellChoiceEditor *)new_wxGridCellChoiceEditor(_arg0,_arg1,_arg2); wxPy_END_ALLOW_THREADS; } if (_result) { @@ -2475,6 +2546,9 @@ static PyObject *_wrap_new_wxGridCellChoiceEditor(PyObject *self, PyObject *args Py_INCREF(Py_None); _resultobj = Py_None; } +{ + delete [] _arg1; +} return _resultobj; } @@ -7297,6 +7371,33 @@ static PyObject *_wrap_wxGrid_IsCellEditControlEnabled(PyObject *self, PyObject return _resultobj; } +#define wxGrid_IsCellEditControlShown(_swigobj) (_swigobj->IsCellEditControlShown()) +static PyObject *_wrap_wxGrid_IsCellEditControlShown(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject * _resultobj; + bool _result; + wxGrid * _arg0; + PyObject * _argo0 = 0; + char *_kwnames[] = { "self", NULL }; + + self = self; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxGrid_IsCellEditControlShown",_kwnames,&_argo0)) + return NULL; + if (_argo0) { + if (_argo0 == Py_None) { _arg0 = NULL; } + else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGrid_p")) { + PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGrid_IsCellEditControlShown. Expected _wxGrid_p."); + return NULL; + } + } +{ + wxPy_BEGIN_ALLOW_THREADS; + _result = (bool )wxGrid_IsCellEditControlShown(_arg0); + + wxPy_END_ALLOW_THREADS; +} _resultobj = Py_BuildValue("i",_result); + return _resultobj; +} + #define wxGrid_IsCurrentCellReadOnly(_swigobj) (_swigobj->IsCurrentCellReadOnly()) static PyObject *_wrap_wxGrid_IsCurrentCellReadOnly(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject * _resultobj; @@ -12410,6 +12511,7 @@ static PyMethodDef gridcMethods[] = { { "wxGrid_HideCellEditControl", (PyCFunction) _wrap_wxGrid_HideCellEditControl, METH_VARARGS | METH_KEYWORDS }, { "wxGrid_ShowCellEditControl", (PyCFunction) _wrap_wxGrid_ShowCellEditControl, METH_VARARGS | METH_KEYWORDS }, { "wxGrid_IsCurrentCellReadOnly", (PyCFunction) _wrap_wxGrid_IsCurrentCellReadOnly, METH_VARARGS | METH_KEYWORDS }, + { "wxGrid_IsCellEditControlShown", (PyCFunction) _wrap_wxGrid_IsCellEditControlShown, METH_VARARGS | METH_KEYWORDS }, { "wxGrid_IsCellEditControlEnabled", (PyCFunction) _wrap_wxGrid_IsCellEditControlEnabled, METH_VARARGS | METH_KEYWORDS }, { "wxGrid_CanEnableCellControl", (PyCFunction) _wrap_wxGrid_CanEnableCellControl, METH_VARARGS | METH_KEYWORDS }, { "wxGrid_DisableCellEditControl", (PyCFunction) _wrap_wxGrid_DisableCellEditControl, METH_VARARGS | METH_KEYWORDS }, @@ -12583,6 +12685,8 @@ static PyMethodDef gridcMethods[] = { { "wxGridCellEditor_BeginEdit", (PyCFunction) _wrap_wxGridCellEditor_BeginEdit, METH_VARARGS | METH_KEYWORDS }, { "wxGridCellEditor_Create", (PyCFunction) _wrap_wxGridCellEditor_Create, METH_VARARGS | METH_KEYWORDS }, { "wxGridCellEditor_SetParameters", (PyCFunction) _wrap_wxGridCellEditor_SetParameters, METH_VARARGS | METH_KEYWORDS }, + { "wxGridCellEditor_SetControl", (PyCFunction) _wrap_wxGridCellEditor_SetControl, METH_VARARGS | METH_KEYWORDS }, + { "wxGridCellEditor_GetControl", (PyCFunction) _wrap_wxGridCellEditor_GetControl, METH_VARARGS | METH_KEYWORDS }, { "wxGridCellEditor_IsCreated", (PyCFunction) _wrap_wxGridCellEditor_IsCreated, METH_VARARGS | METH_KEYWORDS }, { "new_wxGridCellBoolRenderer", (PyCFunction) _wrap_new_wxGridCellBoolRenderer, METH_VARARGS | METH_KEYWORDS }, { "wxGridCellFloatRenderer_SetPrecision", (PyCFunction) _wrap_wxGridCellFloatRenderer_SetPrecision, METH_VARARGS | METH_KEYWORDS }, diff --git a/utils/wxPython/src/gtk/grid.py b/utils/wxPython/src/gtk/grid.py index aba47bc405..d94382d479 100644 --- a/utils/wxPython/src/gtk/grid.py +++ b/utils/wxPython/src/gtk/grid.py @@ -183,6 +183,13 @@ class wxGridCellEditorPtr : def IsCreated(self, *_args, **_kwargs): val = apply(gridc.wxGridCellEditor_IsCreated,(self,) + _args, _kwargs) return val + def GetControl(self, *_args, **_kwargs): + val = apply(gridc.wxGridCellEditor_GetControl,(self,) + _args, _kwargs) + if val: val = wxControlPtr(val) + return val + def SetControl(self, *_args, **_kwargs): + val = apply(gridc.wxGridCellEditor_SetControl,(self,) + _args, _kwargs) + return val def SetParameters(self, *_args, **_kwargs): val = apply(gridc.wxGridCellEditor_SetParameters,(self,) + _args, _kwargs) return val @@ -891,6 +898,9 @@ class wxGridPtr(wxScrolledWindowPtr): def IsCellEditControlEnabled(self, *_args, **_kwargs): val = apply(gridc.wxGrid_IsCellEditControlEnabled,(self,) + _args, _kwargs) return val + def IsCellEditControlShown(self, *_args, **_kwargs): + val = apply(gridc.wxGrid_IsCellEditControlShown,(self,) + _args, _kwargs) + return val def IsCurrentCellReadOnly(self, *_args, **_kwargs): val = apply(gridc.wxGrid_IsCurrentCellReadOnly,(self,) + _args, _kwargs) return val