]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/contrib/stc/msw/stc_.cpp
Fixed bug with SetValue on read-only combobox; don't call ::SetWindowText,
[wxWidgets.git] / wxPython / contrib / stc / msw / stc_.cpp
index 87c57954e846f917712c4e30c61e2103d54d7ae3..0a222b63ab95a7c485f60dcd81b87e1722d0fb28 100644 (file)
@@ -55,7 +55,7 @@ extern PyObject *SWIG_newvarlink(void);
 
 #define SWIG_name    "stc_c"
 
-#include "export.h"
+#include "wxPython.h"
 #include "wx/stc/stc.h"
 
 
@@ -4562,7 +4562,7 @@ static PyObject *_wrap_wxStyledTextCtrl_GetPrintColourMode(PyObject *self, PyObj
     return _resultobj;
 }
 
-#define wxStyledTextCtrl_FindText(_swigobj,_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4)  (_swigobj->FindText(_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4))
+#define wxStyledTextCtrl_FindText(_swigobj,_swigarg0,_swigarg1,_swigarg2,_swigarg3)  (_swigobj->FindText(_swigarg0,_swigarg1,_swigarg2,_swigarg3))
 static PyObject *_wrap_wxStyledTextCtrl_FindText(PyObject *self, PyObject *args, PyObject *kwargs) {
     PyObject * _resultobj;
     int  _result;
@@ -4570,16 +4570,13 @@ static PyObject *_wrap_wxStyledTextCtrl_FindText(PyObject *self, PyObject *args,
     int  _arg1;
     int  _arg2;
     wxString * _arg3;
-    bool  _arg4;
-    bool  _arg5;
+    int  _arg4 = (int ) 0;
     PyObject * _argo0 = 0;
     PyObject * _obj3 = 0;
-    int tempbool4;
-    int tempbool5;
-    char *_kwnames[] = { "self","minPos","maxPos","text","caseSensitive","wholeWord", NULL };
+    char *_kwnames[] = { "self","minPos","maxPos","text","flags", NULL };
 
     self = self;
-    if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OiiOii:wxStyledTextCtrl_FindText",_kwnames,&_argo0,&_arg1,&_arg2,&_obj3,&tempbool4,&tempbool5)) 
+    if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OiiO|i:wxStyledTextCtrl_FindText",_kwnames,&_argo0,&_arg1,&_arg2,&_obj3,&_arg4)) 
         return NULL;
     if (_argo0) {
         if (_argo0 == Py_None) { _arg0 = NULL; }
@@ -4593,11 +4590,9 @@ static PyObject *_wrap_wxStyledTextCtrl_FindText(PyObject *self, PyObject *args,
     if (_arg3 == NULL)
         return NULL;
 }
-    _arg4 = (bool ) tempbool4;
-    _arg5 = (bool ) tempbool5;
 {
     PyThreadState* __tstate = wxPyBeginAllowThreads();
-    _result = (int )wxStyledTextCtrl_FindText(_arg0,_arg1,_arg2,*_arg3,_arg4,_arg5);
+    _result = (int )wxStyledTextCtrl_FindText(_arg0,_arg1,_arg2,*_arg3,_arg4);
 
     wxPyEndAllowThreads(__tstate);
     if (PyErr_Occurred()) return NULL;
@@ -9129,6 +9124,65 @@ static PyObject *_wrap_wxStyledTextCtrl_SetHScrollBar(PyObject *self, PyObject *
     return _resultobj;
 }
 
+#define wxStyledTextCtrl_GetLastKeydownProcessed(_swigobj)  (_swigobj->GetLastKeydownProcessed())
+static PyObject *_wrap_wxStyledTextCtrl_GetLastKeydownProcessed(PyObject *self, PyObject *args, PyObject *kwargs) {
+    PyObject * _resultobj;
+    bool  _result;
+    wxStyledTextCtrl * _arg0;
+    PyObject * _argo0 = 0;
+    char *_kwnames[] = { "self", NULL };
+
+    self = self;
+    if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxStyledTextCtrl_GetLastKeydownProcessed",_kwnames,&_argo0)) 
+        return NULL;
+    if (_argo0) {
+        if (_argo0 == Py_None) { _arg0 = NULL; }
+        else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxStyledTextCtrl_p")) {
+            PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxStyledTextCtrl_GetLastKeydownProcessed. Expected _wxStyledTextCtrl_p.");
+        return NULL;
+        }
+    }
+{
+    PyThreadState* __tstate = wxPyBeginAllowThreads();
+    _result = (bool )wxStyledTextCtrl_GetLastKeydownProcessed(_arg0);
+
+    wxPyEndAllowThreads(__tstate);
+    if (PyErr_Occurred()) return NULL;
+}    _resultobj = Py_BuildValue("i",_result);
+    return _resultobj;
+}
+
+#define wxStyledTextCtrl_SetLastKeydownProcessed(_swigobj,_swigarg0)  (_swigobj->SetLastKeydownProcessed(_swigarg0))
+static PyObject *_wrap_wxStyledTextCtrl_SetLastKeydownProcessed(PyObject *self, PyObject *args, PyObject *kwargs) {
+    PyObject * _resultobj;
+    wxStyledTextCtrl * _arg0;
+    bool  _arg1;
+    PyObject * _argo0 = 0;
+    int tempbool1;
+    char *_kwnames[] = { "self","val", NULL };
+
+    self = self;
+    if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxStyledTextCtrl_SetLastKeydownProcessed",_kwnames,&_argo0,&tempbool1)) 
+        return NULL;
+    if (_argo0) {
+        if (_argo0 == Py_None) { _arg0 = NULL; }
+        else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxStyledTextCtrl_p")) {
+            PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxStyledTextCtrl_SetLastKeydownProcessed. Expected _wxStyledTextCtrl_p.");
+        return NULL;
+        }
+    }
+    _arg1 = (bool ) tempbool1;
+{
+    PyThreadState* __tstate = wxPyBeginAllowThreads();
+    wxStyledTextCtrl_SetLastKeydownProcessed(_arg0,_arg1);
+
+    wxPyEndAllowThreads(__tstate);
+    if (PyErr_Occurred()) return NULL;
+}    Py_INCREF(Py_None);
+    _resultobj = Py_None;
+    return _resultobj;
+}
+
 static void *SwigwxStyledTextEventTowxCommandEvent(void *ptr) {
     wxStyledTextEvent *src;
     wxCommandEvent *dest;
@@ -10555,6 +10609,8 @@ static PyMethodDef stc_cMethods[] = {
         { "wxStyledTextEvent_SetPosition", (PyCFunction) _wrap_wxStyledTextEvent_SetPosition, METH_VARARGS | METH_KEYWORDS },
         { "delete_wxStyledTextEvent", (PyCFunction) _wrap_delete_wxStyledTextEvent, METH_VARARGS | METH_KEYWORDS },
         { "new_wxStyledTextEvent", (PyCFunction) _wrap_new_wxStyledTextEvent, METH_VARARGS | METH_KEYWORDS },
+        { "wxStyledTextCtrl_SetLastKeydownProcessed", (PyCFunction) _wrap_wxStyledTextCtrl_SetLastKeydownProcessed, METH_VARARGS | METH_KEYWORDS },
+        { "wxStyledTextCtrl_GetLastKeydownProcessed", (PyCFunction) _wrap_wxStyledTextCtrl_GetLastKeydownProcessed, METH_VARARGS | METH_KEYWORDS },
         { "wxStyledTextCtrl_SetHScrollBar", (PyCFunction) _wrap_wxStyledTextCtrl_SetHScrollBar, METH_VARARGS | METH_KEYWORDS },
         { "wxStyledTextCtrl_SetVScrollBar", (PyCFunction) _wrap_wxStyledTextCtrl_SetVScrollBar, METH_VARARGS | METH_KEYWORDS },
         { "wxStyledTextCtrl_SendMsg", (PyCFunction) _wrap_wxStyledTextCtrl_SendMsg, METH_VARARGS | METH_KEYWORDS },
@@ -10971,6 +11027,7 @@ SWIGEXPORT(void) initstc_c() {
         SWIG_globals = SWIG_newvarlink();
         m = Py_InitModule("stc_c", stc_cMethods);
         d = PyModule_GetDict(m);
+        PyDict_SetItemString(d,"wxSTC_USE_POPUP", PyInt_FromLong((long) 1));
         PyDict_SetItemString(d,"wxSTC_INVALID_POSITION", PyInt_FromLong((long) -1));
         PyDict_SetItemString(d,"wxSTC_START", PyInt_FromLong((long) 2000));
         PyDict_SetItemString(d,"wxSTC_OPTIONAL_START", PyInt_FromLong((long) 3000));
@@ -11517,6 +11574,7 @@ SWIGEXPORT(void) initstc_c() {
         PyDict_SetItemString(d,"wxSTC_MATLAB_OPERATOR", PyInt_FromLong((long) 6));
         PyDict_SetItemString(d,"wxSTC_MATLAB_IDENTIFIER", PyInt_FromLong((long) 7));
         PyDict_SetItemString(d,"wxSTCNameStr", PyString_FromString("wxSTCNameStr"));
+        PyDict_SetItemString(d,"STC_USE_DND", PyInt_FromLong((long) 1));
         PyDict_SetItemString(d,"wxEVT_STC_CHANGE", PyInt_FromLong((long) wxEVT_STC_CHANGE));
         PyDict_SetItemString(d,"wxEVT_STC_STYLENEEDED", PyInt_FromLong((long) wxEVT_STC_STYLENEEDED));
         PyDict_SetItemString(d,"wxEVT_STC_CHARADDED", PyInt_FromLong((long) wxEVT_STC_CHARADDED));