reSWIGged
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@23901 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -4041,6 +4041,34 @@ static PyObject *_wrap_wxGauge_GetValue(PyObject *self, PyObject *args, PyObject
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define wxGauge_IsVertical(_swigobj) (_swigobj->IsVertical())
|
||||
static PyObject *_wrap_wxGauge_IsVertical(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
bool _result;
|
||||
wxGauge * _arg0;
|
||||
PyObject * _argo0 = 0;
|
||||
char *_kwnames[] = { "self", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxGauge_IsVertical",_kwnames,&_argo0))
|
||||
return NULL;
|
||||
if (_argo0) {
|
||||
if (_argo0 == Py_None) { _arg0 = NULL; }
|
||||
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGauge_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGauge_IsVertical. Expected _wxGauge_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
_result = (bool )wxGauge_IsVertical(_arg0);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
} _resultobj = Py_BuildValue("i",_result);
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define wxGauge_SetBezelFace(_swigobj,_swigarg0) (_swigobj->SetBezelFace(_swigarg0))
|
||||
static PyObject *_wrap_wxGauge_SetBezelFace(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
@@ -7704,6 +7732,34 @@ static PyObject *_wrap_wxTextCtrl_SaveFile(PyObject *self, PyObject *args, PyObj
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define wxTextCtrl_MarkDirty(_swigobj) (_swigobj->MarkDirty())
|
||||
static PyObject *_wrap_wxTextCtrl_MarkDirty(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxTextCtrl * _arg0;
|
||||
PyObject * _argo0 = 0;
|
||||
char *_kwnames[] = { "self", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxTextCtrl_MarkDirty",_kwnames,&_argo0))
|
||||
return NULL;
|
||||
if (_argo0) {
|
||||
if (_argo0 == Py_None) { _arg0 = NULL; }
|
||||
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxTextCtrl_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTextCtrl_MarkDirty. Expected _wxTextCtrl_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
wxTextCtrl_MarkDirty(_arg0);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
} Py_INCREF(Py_None);
|
||||
_resultobj = Py_None;
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define wxTextCtrl_DiscardEdits(_swigobj) (_swigobj->DiscardEdits())
|
||||
static PyObject *_wrap_wxTextCtrl_DiscardEdits(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
@@ -12395,6 +12451,7 @@ static PyMethodDef controlscMethods[] = {
|
||||
{ "wxTextCtrl_WriteText", (PyCFunction) _wrap_wxTextCtrl_WriteText, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxTextCtrl_SetMaxLength", (PyCFunction) _wrap_wxTextCtrl_SetMaxLength, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxTextCtrl_DiscardEdits", (PyCFunction) _wrap_wxTextCtrl_DiscardEdits, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxTextCtrl_MarkDirty", (PyCFunction) _wrap_wxTextCtrl_MarkDirty, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxTextCtrl_SaveFile", (PyCFunction) _wrap_wxTextCtrl_SaveFile, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxTextCtrl_LoadFile", (PyCFunction) _wrap_wxTextCtrl_LoadFile, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxTextCtrl_Remove", (PyCFunction) _wrap_wxTextCtrl_Remove, METH_VARARGS | METH_KEYWORDS },
|
||||
@@ -12481,6 +12538,7 @@ static PyMethodDef controlscMethods[] = {
|
||||
{ "wxGauge_SetShadowWidth", (PyCFunction) _wrap_wxGauge_SetShadowWidth, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGauge_SetRange", (PyCFunction) _wrap_wxGauge_SetRange, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGauge_SetBezelFace", (PyCFunction) _wrap_wxGauge_SetBezelFace, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGauge_IsVertical", (PyCFunction) _wrap_wxGauge_IsVertical, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGauge_GetValue", (PyCFunction) _wrap_wxGauge_GetValue, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGauge_GetShadowWidth", (PyCFunction) _wrap_wxGauge_GetShadowWidth, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGauge_GetRange", (PyCFunction) _wrap_wxGauge_GetRange, METH_VARARGS | METH_KEYWORDS },
|
||||
|
@@ -385,6 +385,9 @@ class wxGaugePtr(wxControlPtr):
|
||||
def GetValue(self, *_args, **_kwargs):
|
||||
val = controlsc.wxGauge_GetValue(self, *_args, **_kwargs)
|
||||
return val
|
||||
def IsVertical(self, *_args, **_kwargs):
|
||||
val = controlsc.wxGauge_IsVertical(self, *_args, **_kwargs)
|
||||
return val
|
||||
def SetBezelFace(self, *_args, **_kwargs):
|
||||
val = controlsc.wxGauge_SetBezelFace(self, *_args, **_kwargs)
|
||||
return val
|
||||
@@ -747,6 +750,9 @@ class wxTextCtrlPtr(wxControlPtr):
|
||||
def SaveFile(self, *_args, **_kwargs):
|
||||
val = controlsc.wxTextCtrl_SaveFile(self, *_args, **_kwargs)
|
||||
return val
|
||||
def MarkDirty(self, *_args, **_kwargs):
|
||||
val = controlsc.wxTextCtrl_MarkDirty(self, *_args, **_kwargs)
|
||||
return val
|
||||
def DiscardEdits(self, *_args, **_kwargs):
|
||||
val = controlsc.wxTextCtrl_DiscardEdits(self, *_args, **_kwargs)
|
||||
return val
|
||||
|
@@ -3135,6 +3135,36 @@ static PyObject *_wrap_wxListCtrl_GetCountPerPage(PyObject *self, PyObject *args
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define wxListCtrl_GetViewRect(_swigobj) (_swigobj->GetViewRect())
|
||||
static PyObject *_wrap_wxListCtrl_GetViewRect(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxRect * _result;
|
||||
wxPyListCtrl * _arg0;
|
||||
PyObject * _argo0 = 0;
|
||||
char *_kwnames[] = { "self", NULL };
|
||||
char _ptemp[128];
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxListCtrl_GetViewRect",_kwnames,&_argo0))
|
||||
return NULL;
|
||||
if (_argo0) {
|
||||
if (_argo0 == Py_None) { _arg0 = NULL; }
|
||||
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyListCtrl_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxListCtrl_GetViewRect. Expected _wxPyListCtrl_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
_result = new wxRect (wxListCtrl_GetViewRect(_arg0));
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
} SWIG_MakePtr(_ptemp, (void *) _result,"_wxRect_p");
|
||||
_resultobj = Py_BuildValue("s",_ptemp);
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static wxListItem * wxPyListCtrl_GetItem(wxPyListCtrl *self,long itemId,int col) {
|
||||
wxListItem* info = new wxListItem;
|
||||
info->m_itemId = itemId;
|
||||
@@ -3653,18 +3683,17 @@ static PyObject *_wrap_wxListCtrl_GetColumnCount(PyObject *self, PyObject *args,
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define wxListCtrl_GetItemSpacing(_swigobj,_swigarg0) (_swigobj->GetItemSpacing(_swigarg0))
|
||||
#define wxListCtrl_GetItemSpacing(_swigobj) (_swigobj->GetItemSpacing())
|
||||
static PyObject *_wrap_wxListCtrl_GetItemSpacing(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
int _result;
|
||||
wxSize * _result;
|
||||
wxPyListCtrl * _arg0;
|
||||
bool _arg1;
|
||||
PyObject * _argo0 = 0;
|
||||
int tempbool1;
|
||||
char *_kwnames[] = { "self","isSmall", NULL };
|
||||
char *_kwnames[] = { "self", NULL };
|
||||
char _ptemp[128];
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxListCtrl_GetItemSpacing",_kwnames,&_argo0,&tempbool1))
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxListCtrl_GetItemSpacing",_kwnames,&_argo0))
|
||||
return NULL;
|
||||
if (_argo0) {
|
||||
if (_argo0 == Py_None) { _arg0 = NULL; }
|
||||
@@ -3673,14 +3702,14 @@ static PyObject *_wrap_wxListCtrl_GetItemSpacing(PyObject *self, PyObject *args,
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
_arg1 = (bool ) tempbool1;
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
_result = (int )wxListCtrl_GetItemSpacing(_arg0,_arg1);
|
||||
_result = new wxSize (wxListCtrl_GetItemSpacing(_arg0));
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
} _resultobj = Py_BuildValue("i",_result);
|
||||
} SWIG_MakePtr(_ptemp, (void *) _result,"_wxSize_p");
|
||||
_resultobj = Py_BuildValue("s",_ptemp);
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
@@ -11296,6 +11325,7 @@ static PyMethodDef controls2cMethods[] = {
|
||||
{ "wxListCtrl_SetStringItem", (PyCFunction) _wrap_wxListCtrl_SetStringItem, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxListCtrl_SetItem", (PyCFunction) _wrap_wxListCtrl_SetItem, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxListCtrl_GetItem", (PyCFunction) _wrap_wxListCtrl_GetItem, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxListCtrl_GetViewRect", (PyCFunction) _wrap_wxListCtrl_GetViewRect, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxListCtrl_GetCountPerPage", (PyCFunction) _wrap_wxListCtrl_GetCountPerPage, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxListCtrl_SetColumnWidth", (PyCFunction) _wrap_wxListCtrl_SetColumnWidth, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxListCtrl_GetColumnWidth", (PyCFunction) _wrap_wxListCtrl_GetColumnWidth, METH_VARARGS | METH_KEYWORDS },
|
||||
|
@@ -468,6 +468,10 @@ class wxListCtrlPtr(wxControlPtr):
|
||||
def GetCountPerPage(self, *_args, **_kwargs):
|
||||
val = controls2c.wxListCtrl_GetCountPerPage(self, *_args, **_kwargs)
|
||||
return val
|
||||
def GetViewRect(self, *_args, **_kwargs):
|
||||
val = controls2c.wxListCtrl_GetViewRect(self, *_args, **_kwargs)
|
||||
if val: val = wxRectPtr(val) ; val.thisown = 1
|
||||
return val
|
||||
def GetItem(self, *_args, **_kwargs):
|
||||
val = controls2c.wxListCtrl_GetItem(self, *_args, **_kwargs)
|
||||
return val
|
||||
@@ -517,6 +521,7 @@ class wxListCtrlPtr(wxControlPtr):
|
||||
return val
|
||||
def GetItemSpacing(self, *_args, **_kwargs):
|
||||
val = controls2c.wxListCtrl_GetItemSpacing(self, *_args, **_kwargs)
|
||||
if val: val = wxSizePtr(val) ; val.thisown = 1
|
||||
return val
|
||||
def SetItemSpacing(self, *_args, **_kwargs):
|
||||
val = controls2c.wxListCtrl_SetItemSpacing(self, *_args, **_kwargs)
|
||||
|
@@ -93,30 +93,30 @@ static PyObject* t_output_helper(PyObject* target, PyObject* o) {
|
||||
static const wxString wxPyEmptyString(wxT(""));
|
||||
|
||||
// Fix some link errors... Remove this when these methods get real implementations...
|
||||
#if defined(__WXGTK__) || defined(__WXX11__)
|
||||
#if wxUSE_PANGO
|
||||
void wxNativeFontInfo::SetPointSize(int pointsize)
|
||||
{ wxFAIL_MSG( _T("not implemented") ); }
|
||||
// #if defined(__WXGTK__) || defined(__WXX11__)
|
||||
// #if wxUSE_PANGO
|
||||
// void wxNativeFontInfo::SetPointSize(int pointsize)
|
||||
// { wxFAIL_MSG( _T("not implemented") ); }
|
||||
|
||||
void wxNativeFontInfo::SetStyle(wxFontStyle style)
|
||||
{ wxFAIL_MSG( _T("not implemented") ); }
|
||||
// void wxNativeFontInfo::SetStyle(wxFontStyle style)
|
||||
// { wxFAIL_MSG( _T("not implemented") ); }
|
||||
|
||||
void wxNativeFontInfo::SetWeight(wxFontWeight weight)
|
||||
{ wxFAIL_MSG( _T("not implemented") ); }
|
||||
// void wxNativeFontInfo::SetWeight(wxFontWeight weight)
|
||||
// { wxFAIL_MSG( _T("not implemented") ); }
|
||||
|
||||
void wxNativeFontInfo::SetUnderlined(bool WXUNUSED(underlined))
|
||||
{ wxFAIL_MSG( _T("not implemented") ); }
|
||||
// void wxNativeFontInfo::SetUnderlined(bool WXUNUSED(underlined))
|
||||
// { wxFAIL_MSG( _T("not implemented") ); }
|
||||
|
||||
void wxNativeFontInfo::SetFaceName(wxString facename)
|
||||
{ wxFAIL_MSG( _T("not implemented") ); }
|
||||
// void wxNativeFontInfo::SetFaceName(wxString facename)
|
||||
// { wxFAIL_MSG( _T("not implemented") ); }
|
||||
|
||||
void wxNativeFontInfo::SetFamily(wxFontFamily family)
|
||||
{ wxFAIL_MSG( _T("not implemented") ); }
|
||||
// void wxNativeFontInfo::SetFamily(wxFontFamily family)
|
||||
// { wxFAIL_MSG( _T("not implemented") ); }
|
||||
|
||||
void wxNativeFontInfo::SetEncoding(wxFontEncoding encoding)
|
||||
{ wxFAIL_MSG( _T("not implemented") ); }
|
||||
#endif
|
||||
#endif
|
||||
// void wxNativeFontInfo::SetEncoding(wxFontEncoding encoding)
|
||||
// { wxFAIL_MSG( _T("not implemented") ); }
|
||||
// #endif
|
||||
// #endif
|
||||
|
||||
class wxPyFontEnumerator : public wxFontEnumerator {
|
||||
public:
|
||||
@@ -252,6 +252,42 @@ static PyObject *_wrap_wxNativeFontInfo_Init(PyObject *self, PyObject *args, PyO
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define wxNativeFontInfo_InitFromFont(_swigobj,_swigarg0) (_swigobj->InitFromFont(_swigarg0))
|
||||
static PyObject *_wrap_wxNativeFontInfo_InitFromFont(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
wxNativeFontInfo * _arg0;
|
||||
wxFont * _arg1;
|
||||
PyObject * _argo0 = 0;
|
||||
PyObject * _argo1 = 0;
|
||||
char *_kwnames[] = { "self","font", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxNativeFontInfo_InitFromFont",_kwnames,&_argo0,&_argo1))
|
||||
return NULL;
|
||||
if (_argo0) {
|
||||
if (_argo0 == Py_None) { _arg0 = NULL; }
|
||||
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxNativeFontInfo_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxNativeFontInfo_InitFromFont. Expected _wxNativeFontInfo_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
if (_argo1) {
|
||||
if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxFont_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxNativeFontInfo_InitFromFont. Expected _wxFont_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
wxNativeFontInfo_InitFromFont(_arg0,*_arg1);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
} Py_INCREF(Py_None);
|
||||
_resultobj = Py_None;
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
#define wxNativeFontInfo_GetPointSize(_swigobj) (_swigobj->GetPointSize())
|
||||
static PyObject *_wrap_wxNativeFontInfo_GetPointSize(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
@@ -4029,6 +4065,7 @@ static PyMethodDef fontscMethods[] = {
|
||||
{ "wxNativeFontInfo_GetWeight", (PyCFunction) _wrap_wxNativeFontInfo_GetWeight, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxNativeFontInfo_GetStyle", (PyCFunction) _wrap_wxNativeFontInfo_GetStyle, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxNativeFontInfo_GetPointSize", (PyCFunction) _wrap_wxNativeFontInfo_GetPointSize, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxNativeFontInfo_InitFromFont", (PyCFunction) _wrap_wxNativeFontInfo_InitFromFont, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxNativeFontInfo_Init", (PyCFunction) _wrap_wxNativeFontInfo_Init, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "new_wxNativeFontInfo", (PyCFunction) _wrap_new_wxNativeFontInfo, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxGetTranslation", (PyCFunction) _wrap_wxGetTranslation, METH_VARARGS | METH_KEYWORDS },
|
||||
@@ -4209,6 +4246,12 @@ SWIGEXPORT(void) initfontsc() {
|
||||
PyDict_SetItemString(d,"wxFONTENCODING_CP12_MAX", PyInt_FromLong((long) wxFONTENCODING_CP12_MAX));
|
||||
PyDict_SetItemString(d,"wxFONTENCODING_UTF7", PyInt_FromLong((long) wxFONTENCODING_UTF7));
|
||||
PyDict_SetItemString(d,"wxFONTENCODING_UTF8", PyInt_FromLong((long) wxFONTENCODING_UTF8));
|
||||
PyDict_SetItemString(d,"wxFONTENCODING_UTF16", PyInt_FromLong((long) wxFONTENCODING_UTF16));
|
||||
PyDict_SetItemString(d,"wxFONTENCODING_UTF16BE", PyInt_FromLong((long) wxFONTENCODING_UTF16BE));
|
||||
PyDict_SetItemString(d,"wxFONTENCODING_UTF16LE", PyInt_FromLong((long) wxFONTENCODING_UTF16LE));
|
||||
PyDict_SetItemString(d,"wxFONTENCODING_UTF32", PyInt_FromLong((long) wxFONTENCODING_UTF32));
|
||||
PyDict_SetItemString(d,"wxFONTENCODING_UTF32BE", PyInt_FromLong((long) wxFONTENCODING_UTF32BE));
|
||||
PyDict_SetItemString(d,"wxFONTENCODING_UTF32LE", PyInt_FromLong((long) wxFONTENCODING_UTF32LE));
|
||||
PyDict_SetItemString(d,"wxFONTENCODING_GB2312", PyInt_FromLong((long) wxFONTENCODING_GB2312));
|
||||
PyDict_SetItemString(d,"wxFONTENCODING_BIG5", PyInt_FromLong((long) wxFONTENCODING_BIG5));
|
||||
PyDict_SetItemString(d,"wxFONTENCODING_SHIFT_JIS", PyInt_FromLong((long) wxFONTENCODING_SHIFT_JIS));
|
||||
|
@@ -9,6 +9,9 @@ class wxNativeFontInfoPtr :
|
||||
def Init(self, *_args, **_kwargs):
|
||||
val = fontsc.wxNativeFontInfo_Init(self, *_args, **_kwargs)
|
||||
return val
|
||||
def InitFromFont(self, *_args, **_kwargs):
|
||||
val = fontsc.wxNativeFontInfo_InitFromFont(self, *_args, **_kwargs)
|
||||
return val
|
||||
def GetPointSize(self, *_args, **_kwargs):
|
||||
val = fontsc.wxNativeFontInfo_GetPointSize(self, *_args, **_kwargs)
|
||||
return val
|
||||
@@ -532,6 +535,12 @@ wxFONTENCODING_CP1257 = fontsc.wxFONTENCODING_CP1257
|
||||
wxFONTENCODING_CP12_MAX = fontsc.wxFONTENCODING_CP12_MAX
|
||||
wxFONTENCODING_UTF7 = fontsc.wxFONTENCODING_UTF7
|
||||
wxFONTENCODING_UTF8 = fontsc.wxFONTENCODING_UTF8
|
||||
wxFONTENCODING_UTF16 = fontsc.wxFONTENCODING_UTF16
|
||||
wxFONTENCODING_UTF16BE = fontsc.wxFONTENCODING_UTF16BE
|
||||
wxFONTENCODING_UTF16LE = fontsc.wxFONTENCODING_UTF16LE
|
||||
wxFONTENCODING_UTF32 = fontsc.wxFONTENCODING_UTF32
|
||||
wxFONTENCODING_UTF32BE = fontsc.wxFONTENCODING_UTF32BE
|
||||
wxFONTENCODING_UTF32LE = fontsc.wxFONTENCODING_UTF32LE
|
||||
wxFONTENCODING_GB2312 = fontsc.wxFONTENCODING_GB2312
|
||||
wxFONTENCODING_BIG5 = fontsc.wxFONTENCODING_BIG5
|
||||
wxFONTENCODING_SHIFT_JIS = fontsc.wxFONTENCODING_SHIFT_JIS
|
||||
|
@@ -11088,7 +11088,38 @@ static PyObject *_wrap_wxRegionIterator_Next(PyObject *self, PyObject *args, PyO
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static bool wxRegionIterator___nonzero__(wxRegionIterator *self) {
|
||||
return self->operator bool();
|
||||
}
|
||||
static PyObject *_wrap_wxRegionIterator___nonzero__(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
bool _result;
|
||||
wxRegionIterator * _arg0;
|
||||
PyObject * _argo0 = 0;
|
||||
char *_kwnames[] = { "self", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxRegionIterator___nonzero__",_kwnames,&_argo0))
|
||||
return NULL;
|
||||
if (_argo0) {
|
||||
if (_argo0 == Py_None) { _arg0 = NULL; }
|
||||
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxRegionIterator_p")) {
|
||||
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxRegionIterator___nonzero__. Expected _wxRegionIterator_p.");
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
_result = (bool )wxRegionIterator___nonzero__(_arg0);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
} _resultobj = Py_BuildValue("i",_result);
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyMethodDef gdicMethods[] = {
|
||||
{ "wxRegionIterator___nonzero__", (PyCFunction) _wrap_wxRegionIterator___nonzero__, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxRegionIterator_Next", (PyCFunction) _wrap_wxRegionIterator_Next, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxRegionIterator_Reset", (PyCFunction) _wrap_wxRegionIterator_Reset, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxRegionIterator_HaveRects", (PyCFunction) _wrap_wxRegionIterator_HaveRects, METH_VARARGS | METH_KEYWORDS },
|
||||
|
@@ -307,7 +307,7 @@ class wxColourPtr(wxObjectPtr):
|
||||
return "<%s.%s instance; proxy of C++ wxColour instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
|
||||
asTuple = Get
|
||||
def __str__(self): return str(self.asTuple())
|
||||
def __repr__(self): return 'wxColour:' + str(self.asTuple())
|
||||
def __repr__(self): return 'wxColour' + str(self.asTuple())
|
||||
def __nonzero__(self): return self.Ok()
|
||||
def __getinitargs__(self): return ()
|
||||
def __getstate__(self): return self.asTuple()
|
||||
@@ -1299,6 +1299,9 @@ class wxRegionIteratorPtr(wxObjectPtr):
|
||||
def Next(self, *_args, **_kwargs):
|
||||
val = gdic.wxRegionIterator_Next(self, *_args, **_kwargs)
|
||||
return val
|
||||
def __nonzero__(self, *_args, **_kwargs):
|
||||
val = gdic.wxRegionIterator___nonzero__(self, *_args, **_kwargs)
|
||||
return val
|
||||
def __repr__(self):
|
||||
return "<%s.%s instance; proxy of C++ wxRegionIterator instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
|
||||
class wxRegionIterator(wxRegionIteratorPtr):
|
||||
|
@@ -318,15 +318,80 @@ public:
|
||||
|
||||
#ifdef __WXMSW__
|
||||
#include <wx/msw/private.h>
|
||||
#include <wx/dynload.h>
|
||||
#endif
|
||||
|
||||
|
||||
void wxDrawWindowOnDC(wxWindow* window, const wxDC& dc)
|
||||
void wxDrawWindowOnDC(wxWindow* window, const wxDC& dc, int method)
|
||||
{
|
||||
#ifdef __WXMSW__
|
||||
::SendMessage(GetHwndOf(window), WM_PAINT, (long)GetHdcOf(dc), 0);
|
||||
// ::SendMessage(GetHwndOf(window), WM_PRINTCLIENT, (long)GetHdcOf(dc),
|
||||
// PRF_CLIENT | PRF_NONCLIENT | PRF_CHILDREN );
|
||||
|
||||
switch (method)
|
||||
{
|
||||
case 1:
|
||||
// This one only partially works. Appears to be an undocumented
|
||||
// "standard" convention that not all widgets adhear to. For
|
||||
// example, for some widgets backgrounds or non-client areas may
|
||||
// not be painted.
|
||||
::SendMessage(GetHwndOf(window), WM_PAINT, (long)GetHdcOf(dc), 0);
|
||||
break;
|
||||
|
||||
case 2:
|
||||
// This one works much better, except for on XP. On Win2k nearly
|
||||
// all widgets and their children are captured correctly[**]. On
|
||||
// XP with Themes activated most native widgets draw only
|
||||
// partially, if at all. Without themes it works just like on
|
||||
// Win2k.
|
||||
//
|
||||
// ** For example the radio buttons in a wxRadioBox are not its
|
||||
// children by default, but you can capture it via the panel
|
||||
// instead, or change RADIOBTN_PARENT_IS_RADIOBOX in radiobox.cpp.
|
||||
::SendMessage(GetHwndOf(window), WM_PRINT, (long)GetHdcOf(dc),
|
||||
PRF_CLIENT | PRF_NONCLIENT | PRF_CHILDREN |
|
||||
PRF_ERASEBKGND | PRF_OWNED );
|
||||
break;
|
||||
|
||||
case 3:
|
||||
// This one is only defined in the latest SDK and is only
|
||||
// available on XP. MSDN says it is similar to sending WM_PRINT
|
||||
// so I expect that it will work similar to the above. Since it
|
||||
// is avaialble only on XP, it can't be compiled like this and
|
||||
// will have to be loaded dynamically.
|
||||
// //::PrintWindow(GetHwndOf(window), GetHdcOf(dc), 0); //break;
|
||||
|
||||
// fall through
|
||||
|
||||
case 4:
|
||||
// Use PrintWindow if available, or fallback to WM_PRINT
|
||||
// otherwise. Unfortunately using PrintWindow is even worse than
|
||||
// WM_PRINT. For most native widgets nothing is drawn to the dc
|
||||
// at all, with or without Themes.
|
||||
typedef BOOL (WINAPI *PrintWindow_t)(HWND, HDC, UINT);
|
||||
static bool s_triedToLoad = false;
|
||||
static PrintWindow_t pfnPrintWindow = NULL;
|
||||
if ( !s_triedToLoad )
|
||||
{
|
||||
|
||||
s_triedToLoad = true;
|
||||
wxDynamicLibrary dllUser32(_T("user32.dll"));
|
||||
if ( dllUser32.IsLoaded() )
|
||||
{
|
||||
wxLogNull nolog; // Don't report errors here
|
||||
pfnPrintWindow = (PrintWindow_t)dllUser32.GetSymbol(_T("PrintWindow"));
|
||||
}
|
||||
}
|
||||
if (pfnPrintWindow)
|
||||
{
|
||||
printf("Using PrintWindow\n");
|
||||
pfnPrintWindow(GetHwndOf(window), GetHdcOf(dc), 0);
|
||||
}
|
||||
else
|
||||
{
|
||||
printf("Using WM_PRINT\n");
|
||||
::SendMessage(GetHwndOf(window), WM_PRINT, (long)GetHdcOf(dc),
|
||||
PRF_CLIENT | PRF_NONCLIENT | PRF_CHILDREN | PRF_ERASEBKGND | PRF_OWNED );
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -2303,12 +2368,13 @@ static PyObject *_wrap_wxDrawWindowOnDC(PyObject *self, PyObject *args, PyObject
|
||||
PyObject * _resultobj;
|
||||
wxWindow * _arg0;
|
||||
wxDC * _arg1;
|
||||
int _arg2;
|
||||
PyObject * _argo0 = 0;
|
||||
PyObject * _argo1 = 0;
|
||||
char *_kwnames[] = { "window","dc", NULL };
|
||||
char *_kwnames[] = { "window","dc","method", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxDrawWindowOnDC",_kwnames,&_argo0,&_argo1))
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOi:wxDrawWindowOnDC",_kwnames,&_argo0,&_argo1,&_arg2))
|
||||
return NULL;
|
||||
if (_argo0) {
|
||||
if (_argo0 == Py_None) { _arg0 = NULL; }
|
||||
@@ -2325,7 +2391,7 @@ static PyObject *_wrap_wxDrawWindowOnDC(PyObject *self, PyObject *args, PyObject
|
||||
}
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
wxDrawWindowOnDC(_arg0,*_arg1);
|
||||
wxDrawWindowOnDC(_arg0,*_arg1,_arg2);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
|
@@ -832,7 +832,7 @@ static PyObject *_wrap_wxBookCtrl_AddPage(PyObject *self, PyObject *args, PyObje
|
||||
PyObject * _argo1 = 0;
|
||||
PyObject * _obj2 = 0;
|
||||
int tempbool3 = (int) false;
|
||||
char *_kwnames[] = { "self","page","text","bSelect","imageId", NULL };
|
||||
char *_kwnames[] = { "self","page","text","select","imageId", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO|ii:wxBookCtrl_AddPage",_kwnames,&_argo0,&_argo1,&_obj2,&tempbool3,&_arg4))
|
||||
@@ -885,7 +885,7 @@ static PyObject *_wrap_wxBookCtrl_InsertPage(PyObject *self, PyObject *args, PyO
|
||||
PyObject * _argo2 = 0;
|
||||
PyObject * _obj3 = 0;
|
||||
int tempbool4 = (int) false;
|
||||
char *_kwnames[] = { "self","n","page","text","bSelect","imageId", NULL };
|
||||
char *_kwnames[] = { "self","n","page","text","select","imageId", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OiOO|ii:wxBookCtrl_InsertPage",_kwnames,&_argo0,&_arg1,&_argo2,&_obj3,&tempbool4,&_arg5))
|
||||
|
@@ -1789,24 +1789,6 @@ static PyObject *_wrap_wxPyApp_SetAssertMode(PyObject *self, PyObject *args, PyO
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxPyApp_GetMacDefaultEncodingIsPC(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
bool _result;
|
||||
char *_kwnames[] = { NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,":wxPyApp_GetMacDefaultEncodingIsPC",_kwnames))
|
||||
return NULL;
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
_result = (bool )wxPyApp::GetMacDefaultEncodingIsPC();
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
} _resultobj = Py_BuildValue("i",_result);
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxPyApp_GetMacSupportPCMenuShortcuts(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
bool _result;
|
||||
@@ -1906,27 +1888,6 @@ static PyObject *_wrap_wxPyApp_GetMacHelpMenuTitleName(PyObject *self, PyObject
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxPyApp_SetMacDefaultEncodingIsPC(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
bool _arg0;
|
||||
int tempbool0;
|
||||
char *_kwnames[] = { "val", NULL };
|
||||
|
||||
self = self;
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"i:wxPyApp_SetMacDefaultEncodingIsPC",_kwnames,&tempbool0))
|
||||
return NULL;
|
||||
_arg0 = (bool ) tempbool0;
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
wxPyApp::SetMacDefaultEncodingIsPC(_arg0);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) return NULL;
|
||||
} Py_INCREF(Py_None);
|
||||
_resultobj = Py_None;
|
||||
return _resultobj;
|
||||
}
|
||||
|
||||
static PyObject *_wrap_wxPyApp_SetMacSupportPCMenuShortcuts(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject * _resultobj;
|
||||
bool _arg0;
|
||||
@@ -2040,13 +2001,11 @@ static PyMethodDef wxcMethods[] = {
|
||||
{ "wxPyApp_SetMacPreferencesMenuItemId", (PyCFunction) _wrap_wxPyApp_SetMacPreferencesMenuItemId, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPyApp_SetMacAboutMenuItemId", (PyCFunction) _wrap_wxPyApp_SetMacAboutMenuItemId, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPyApp_SetMacSupportPCMenuShortcuts", (PyCFunction) _wrap_wxPyApp_SetMacSupportPCMenuShortcuts, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPyApp_SetMacDefaultEncodingIsPC", (PyCFunction) _wrap_wxPyApp_SetMacDefaultEncodingIsPC, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPyApp_GetMacHelpMenuTitleName", (PyCFunction) _wrap_wxPyApp_GetMacHelpMenuTitleName, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPyApp_GetMacExitMenuItemId", (PyCFunction) _wrap_wxPyApp_GetMacExitMenuItemId, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPyApp_GetMacPreferencesMenuItemId", (PyCFunction) _wrap_wxPyApp_GetMacPreferencesMenuItemId, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPyApp_GetMacAboutMenuItemId", (PyCFunction) _wrap_wxPyApp_GetMacAboutMenuItemId, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPyApp_GetMacSupportPCMenuShortcuts", (PyCFunction) _wrap_wxPyApp_GetMacSupportPCMenuShortcuts, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPyApp_GetMacDefaultEncodingIsPC", (PyCFunction) _wrap_wxPyApp_GetMacDefaultEncodingIsPC, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPyApp_SetAssertMode", (PyCFunction) _wrap_wxPyApp_SetAssertMode, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPyApp_GetAssertMode", (PyCFunction) _wrap_wxPyApp_GetAssertMode, METH_VARARGS | METH_KEYWORDS },
|
||||
{ "wxPyApp_SetUseBestVisual", (PyCFunction) _wrap_wxPyApp_SetUseBestVisual, METH_VARARGS | METH_KEYWORDS },
|
||||
@@ -2387,6 +2346,7 @@ SWIGEXPORT(void) initwxc() {
|
||||
PyDict_SetItemString(d,"wxID_HELP_PROCEDURES", PyInt_FromLong((long) wxID_HELP_PROCEDURES));
|
||||
PyDict_SetItemString(d,"wxID_HELP_CONTEXT", PyInt_FromLong((long) wxID_HELP_CONTEXT));
|
||||
PyDict_SetItemString(d,"wxID_CLOSE_ALL", PyInt_FromLong((long) wxID_CLOSE_ALL));
|
||||
PyDict_SetItemString(d,"wxID_PREFERENCES", PyInt_FromLong((long) wxID_PREFERENCES));
|
||||
PyDict_SetItemString(d,"wxID_CUT", PyInt_FromLong((long) wxID_CUT));
|
||||
PyDict_SetItemString(d,"wxID_COPY", PyInt_FromLong((long) wxID_COPY));
|
||||
PyDict_SetItemString(d,"wxID_PASTE", PyInt_FromLong((long) wxID_PASTE));
|
||||
|
@@ -164,8 +164,6 @@ def wxGetApp(*_args, **_kwargs):
|
||||
|
||||
wxApp_CleanUp = wxc.wxApp_CleanUp
|
||||
|
||||
wxPyApp_GetMacDefaultEncodingIsPC = wxc.wxPyApp_GetMacDefaultEncodingIsPC
|
||||
|
||||
wxPyApp_GetMacSupportPCMenuShortcuts = wxc.wxPyApp_GetMacSupportPCMenuShortcuts
|
||||
|
||||
wxPyApp_GetMacAboutMenuItemId = wxc.wxPyApp_GetMacAboutMenuItemId
|
||||
@@ -176,8 +174,6 @@ wxPyApp_GetMacExitMenuItemId = wxc.wxPyApp_GetMacExitMenuItemId
|
||||
|
||||
wxPyApp_GetMacHelpMenuTitleName = wxc.wxPyApp_GetMacHelpMenuTitleName
|
||||
|
||||
wxPyApp_SetMacDefaultEncodingIsPC = wxc.wxPyApp_SetMacDefaultEncodingIsPC
|
||||
|
||||
wxPyApp_SetMacSupportPCMenuShortcuts = wxc.wxPyApp_SetMacSupportPCMenuShortcuts
|
||||
|
||||
wxPyApp_SetMacAboutMenuItemId = wxc.wxPyApp_SetMacAboutMenuItemId
|
||||
@@ -373,6 +369,7 @@ wxID_HELP_COMMANDS = wxc.wxID_HELP_COMMANDS
|
||||
wxID_HELP_PROCEDURES = wxc.wxID_HELP_PROCEDURES
|
||||
wxID_HELP_CONTEXT = wxc.wxID_HELP_CONTEXT
|
||||
wxID_CLOSE_ALL = wxc.wxID_CLOSE_ALL
|
||||
wxID_PREFERENCES = wxc.wxID_PREFERENCES
|
||||
wxID_CUT = wxc.wxID_CUT
|
||||
wxID_COPY = wxc.wxID_COPY
|
||||
wxID_PASTE = wxc.wxID_PASTE
|
||||
@@ -1942,13 +1939,11 @@ of your Mac."""
|
||||
|
||||
|
||||
# change from wxPyApp_ to wxApp_
|
||||
wxApp_GetMacDefaultEncodingIsPC = wxc.wxPyApp_GetMacDefaultEncodingIsPC
|
||||
wxApp_GetMacSupportPCMenuShortcuts = wxc.wxPyApp_GetMacSupportPCMenuShortcuts
|
||||
wxApp_GetMacAboutMenuItemId = wxc.wxPyApp_GetMacAboutMenuItemId
|
||||
wxApp_GetMacPreferencesMenuItemId = wxc.wxPyApp_GetMacPreferencesMenuItemId
|
||||
wxApp_GetMacExitMenuItemId = wxc.wxPyApp_GetMacExitMenuItemId
|
||||
wxApp_GetMacHelpMenuTitleName = wxc.wxPyApp_GetMacHelpMenuTitleName
|
||||
wxApp_SetMacDefaultEncodingIsPC = wxc.wxPyApp_SetMacDefaultEncodingIsPC
|
||||
wxApp_SetMacSupportPCMenuShortcuts = wxc.wxPyApp_SetMacSupportPCMenuShortcuts
|
||||
wxApp_SetMacAboutMenuItemId = wxc.wxPyApp_SetMacAboutMenuItemId
|
||||
wxApp_SetMacPreferencesMenuItemId = wxc.wxPyApp_SetMacPreferencesMenuItemId
|
||||
|
Reference in New Issue
Block a user