SWIGged updates for wxMac

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@14935 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2002-04-04 05:44:55 +00:00
parent cce8089628
commit 4069916857
32 changed files with 968 additions and 3217 deletions

View File

@@ -7,6 +7,8 @@ from windows import *
from gdi import *
from fonts import *
from clip_dnd import *
from controls import *

View File

@@ -5,6 +5,8 @@ from misc import *
from gdi import *
from fonts import *
from windows import *
from clip_dnd import *

View File

@@ -7,6 +7,8 @@ from windows import *
from gdi import *
from fonts import *
from clip_dnd import *
from events import *

View File

@@ -7,6 +7,8 @@ from windows import *
from gdi import *
from fonts import *
from clip_dnd import *
from events import *

View File

@@ -4,6 +4,8 @@ import eventsc
from misc import *
from gdi import *
from fonts import *
class wxEventPtr(wxObjectPtr):
def __init__(self,this):
self.this = this

View File

@@ -9,6 +9,8 @@ from misc import *
from gdi import *
from fonts import *
from streams import *
import wx
import string

View File

@@ -515,6 +515,43 @@ static PyObject *_wrap_wxTopLevelWindow_SetIcon(PyObject *self, PyObject *args,
return _resultobj;
}
#define wxTopLevelWindow_SetIcons(_swigobj,_swigarg0) (_swigobj->SetIcons(_swigarg0))
static PyObject *_wrap_wxTopLevelWindow_SetIcons(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxTopLevelWindow * _arg0;
wxIconBundle * _arg1;
PyObject * _argo0 = 0;
PyObject * _argo1 = 0;
char *_kwnames[] = { "self","icons", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxTopLevelWindow_SetIcons",_kwnames,&_argo0,&_argo1))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxTopLevelWindow_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxTopLevelWindow_SetIcons. Expected _wxTopLevelWindow_p.");
return NULL;
}
}
if (_argo1) {
if (_argo1 == Py_None) { _arg1 = NULL; }
else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxIconBundle_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxTopLevelWindow_SetIcons. Expected _wxIconBundle_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
wxTopLevelWindow_SetIcons(_arg0,*_arg1);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} Py_INCREF(Py_None);
_resultobj = Py_None;
return _resultobj;
}
#define wxTopLevelWindow_ShowFullScreen(_swigobj,_swigarg0,_swigarg1) (_swigobj->ShowFullScreen(_swigarg0,_swigarg1))
static PyObject *_wrap_wxTopLevelWindow_ShowFullScreen(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
@@ -2435,6 +2472,7 @@ static PyMethodDef framescMethods[] = {
{ "wxTopLevelWindow_SetTitle", (PyCFunction) _wrap_wxTopLevelWindow_SetTitle, METH_VARARGS | METH_KEYWORDS },
{ "wxTopLevelWindow_IsFullScreen", (PyCFunction) _wrap_wxTopLevelWindow_IsFullScreen, METH_VARARGS | METH_KEYWORDS },
{ "wxTopLevelWindow_ShowFullScreen", (PyCFunction) _wrap_wxTopLevelWindow_ShowFullScreen, METH_VARARGS | METH_KEYWORDS },
{ "wxTopLevelWindow_SetIcons", (PyCFunction) _wrap_wxTopLevelWindow_SetIcons, METH_VARARGS | METH_KEYWORDS },
{ "wxTopLevelWindow_SetIcon", (PyCFunction) _wrap_wxTopLevelWindow_SetIcon, METH_VARARGS | METH_KEYWORDS },
{ "wxTopLevelWindow_GetIcon", (PyCFunction) _wrap_wxTopLevelWindow_GetIcon, METH_VARARGS | METH_KEYWORDS },
{ "wxTopLevelWindow_IsIconized", (PyCFunction) _wrap_wxTopLevelWindow_IsIconized, METH_VARARGS | METH_KEYWORDS },

View File

@@ -5,6 +5,8 @@ from misc import *
from gdi import *
from fonts import *
from windows import *
from clip_dnd import *
@@ -44,6 +46,9 @@ class wxTopLevelWindowPtr(wxWindowPtr):
def SetIcon(self, *_args, **_kwargs):
val = apply(framesc.wxTopLevelWindow_SetIcon,(self,) + _args, _kwargs)
return val
def SetIcons(self, *_args, **_kwargs):
val = apply(framesc.wxTopLevelWindow_SetIcons,(self,) + _args, _kwargs)
return val
def ShowFullScreen(self, *_args, **_kwargs):
val = apply(framesc.wxTopLevelWindow_ShowFullScreen,(self,) + _args, _kwargs)
return val

File diff suppressed because it is too large Load Diff

View File

@@ -2,6 +2,8 @@
import gdic
from misc import *
from fonts import *
class wxGDIObjectPtr(wxObjectPtr):
def __init__(self,this):
self.this = this
@@ -164,6 +166,43 @@ class wxIcon(wxIconPtr):
class wxIconBundlePtr :
def __init__(self,this):
self.this = this
self.thisown = 0
def __del__(self,gdic=gdic):
if self.thisown == 1 :
gdic.delete_wxIconBundle(self)
def AddIcon(self, *_args, **_kwargs):
val = apply(gdic.wxIconBundle_AddIcon,(self,) + _args, _kwargs)
return val
def AddIconFromFile(self, *_args, **_kwargs):
val = apply(gdic.wxIconBundle_AddIconFromFile,(self,) + _args, _kwargs)
return val
def GetIcon(self, *_args, **_kwargs):
val = apply(gdic.wxIconBundle_GetIcon,(self,) + _args, _kwargs)
if val: val = wxIconPtr(val)
return val
def __repr__(self):
return "<C wxIconBundle instance at %s>" % (self.this,)
class wxIconBundle(wxIconBundlePtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gdic.new_wxIconBundle,_args,_kwargs)
self.thisown = 1
def wxIconBundleFromFile(*_args,**_kwargs):
val = wxIconBundlePtr(apply(gdic.new_wxIconBundleFromFile,_args,_kwargs))
val.thisown = 1
return val
def wxIconBundleFromIcon(*_args,**_kwargs):
val = wxIconBundlePtr(apply(gdic.new_wxIconBundleFromIcon,_args,_kwargs))
val.thisown = 1
return val
class wxCursorPtr(wxGDIObjectPtr):
def __init__(self,this):
self.this = this
@@ -183,239 +222,6 @@ class wxCursor(wxCursorPtr):
class wxNativeFontInfoPtr :
def __init__(self,this):
self.this = this
self.thisown = 0
def Init(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_Init,(self,) + _args, _kwargs)
return val
def GetPointSize(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_GetPointSize,(self,) + _args, _kwargs)
return val
def GetStyle(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_GetStyle,(self,) + _args, _kwargs)
return val
def GetWeight(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_GetWeight,(self,) + _args, _kwargs)
return val
def GetUnderlined(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_GetUnderlined,(self,) + _args, _kwargs)
return val
def GetFaceName(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_GetFaceName,(self,) + _args, _kwargs)
return val
def GetFamily(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_GetFamily,(self,) + _args, _kwargs)
return val
def GetEncoding(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_GetEncoding,(self,) + _args, _kwargs)
return val
def SetPointSize(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_SetPointSize,(self,) + _args, _kwargs)
return val
def SetStyle(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_SetStyle,(self,) + _args, _kwargs)
return val
def SetWeight(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_SetWeight,(self,) + _args, _kwargs)
return val
def SetUnderlined(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_SetUnderlined,(self,) + _args, _kwargs)
return val
def SetFaceName(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_SetFaceName,(self,) + _args, _kwargs)
return val
def SetFamily(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_SetFamily,(self,) + _args, _kwargs)
return val
def SetEncoding(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_SetEncoding,(self,) + _args, _kwargs)
return val
def FromString(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_FromString,(self,) + _args, _kwargs)
return val
def ToString(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_ToString,(self,) + _args, _kwargs)
return val
def __str__(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo___str__,(self,) + _args, _kwargs)
return val
def FromUserString(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_FromUserString,(self,) + _args, _kwargs)
return val
def ToUserString(self, *_args, **_kwargs):
val = apply(gdic.wxNativeFontInfo_ToUserString,(self,) + _args, _kwargs)
return val
def __repr__(self):
return "<C wxNativeFontInfo instance at %s>" % (self.this,)
class wxNativeFontInfo(wxNativeFontInfoPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gdic.new_wxNativeFontInfo,_args,_kwargs)
self.thisown = 1
class wxFontMapperPtr :
def __init__(self,this):
self.this = this
self.thisown = 0
def __del__(self,gdic=gdic):
if self.thisown == 1 :
gdic.delete_wxFontMapper(self)
def GetAltForEncoding(self, *_args, **_kwargs):
val = apply(gdic.wxFontMapper_GetAltForEncoding,(self,) + _args, _kwargs)
return val
def IsEncodingAvailable(self, *_args, **_kwargs):
val = apply(gdic.wxFontMapper_IsEncodingAvailable,(self,) + _args, _kwargs)
return val
def CharsetToEncoding(self, *_args, **_kwargs):
val = apply(gdic.wxFontMapper_CharsetToEncoding,(self,) + _args, _kwargs)
return val
def SetDialogParent(self, *_args, **_kwargs):
val = apply(gdic.wxFontMapper_SetDialogParent,(self,) + _args, _kwargs)
return val
def SetDialogTitle(self, *_args, **_kwargs):
val = apply(gdic.wxFontMapper_SetDialogTitle,(self,) + _args, _kwargs)
return val
def SetConfig(self, *_args, **_kwargs):
val = apply(gdic.wxFontMapper_SetConfig,(self,) + _args, _kwargs)
return val
def SetConfigPath(self, *_args, **_kwargs):
val = apply(gdic.wxFontMapper_SetConfigPath,(self,) + _args, _kwargs)
return val
def __repr__(self):
return "<C wxFontMapper instance at %s>" % (self.this,)
class wxFontMapper(wxFontMapperPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gdic.new_wxFontMapper,_args,_kwargs)
self.thisown = 1
class wxFontPtr(wxGDIObjectPtr):
def __init__(self,this):
self.this = this
self.thisown = 0
def __del__(self,gdic=gdic):
if self.thisown == 1 :
gdic.delete_wxFont(self)
def Ok(self, *_args, **_kwargs):
val = apply(gdic.wxFont_Ok,(self,) + _args, _kwargs)
return val
def GetPointSize(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetPointSize,(self,) + _args, _kwargs)
return val
def GetFamily(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetFamily,(self,) + _args, _kwargs)
return val
def GetStyle(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetStyle,(self,) + _args, _kwargs)
return val
def GetWeight(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetWeight,(self,) + _args, _kwargs)
return val
def GetUnderlined(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetUnderlined,(self,) + _args, _kwargs)
return val
def GetFaceName(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetFaceName,(self,) + _args, _kwargs)
return val
def GetEncoding(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetEncoding,(self,) + _args, _kwargs)
return val
def IsFixedWidth(self, *_args, **_kwargs):
val = apply(gdic.wxFont_IsFixedWidth,(self,) + _args, _kwargs)
return val
def GetNativeFontInfo(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetNativeFontInfo,(self,) + _args, _kwargs)
if val: val = wxNativeFontInfoPtr(val)
return val
def GetNativeFontInfoDesc(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetNativeFontInfoDesc,(self,) + _args, _kwargs)
return val
def GetNativeFontInfoUserDesc(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetNativeFontInfoUserDesc,(self,) + _args, _kwargs)
return val
def SetPointSize(self, *_args, **_kwargs):
val = apply(gdic.wxFont_SetPointSize,(self,) + _args, _kwargs)
return val
def SetFamily(self, *_args, **_kwargs):
val = apply(gdic.wxFont_SetFamily,(self,) + _args, _kwargs)
return val
def SetStyle(self, *_args, **_kwargs):
val = apply(gdic.wxFont_SetStyle,(self,) + _args, _kwargs)
return val
def SetWeight(self, *_args, **_kwargs):
val = apply(gdic.wxFont_SetWeight,(self,) + _args, _kwargs)
return val
def SetFaceName(self, *_args, **_kwargs):
val = apply(gdic.wxFont_SetFaceName,(self,) + _args, _kwargs)
return val
def SetUnderlined(self, *_args, **_kwargs):
val = apply(gdic.wxFont_SetUnderlined,(self,) + _args, _kwargs)
return val
def SetEncoding(self, *_args, **_kwargs):
val = apply(gdic.wxFont_SetEncoding,(self,) + _args, _kwargs)
return val
def SetNativeFontInfo(self, *_args, **_kwargs):
val = apply(gdic.wxFont_SetNativeFontInfo,(self,) + _args, _kwargs)
return val
def SetNativeFontInfoUserDesc(self, *_args, **_kwargs):
val = apply(gdic.wxFont_SetNativeFontInfoUserDesc,(self,) + _args, _kwargs)
return val
def GetFamilyString(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetFamilyString,(self,) + _args, _kwargs)
return val
def GetStyleString(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetStyleString,(self,) + _args, _kwargs)
return val
def GetWeightString(self, *_args, **_kwargs):
val = apply(gdic.wxFont_GetWeightString,(self,) + _args, _kwargs)
return val
def __repr__(self):
return "<C wxFont instance at %s>" % (self.this,)
class wxFont(wxFontPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gdic.new_wxFont,_args,_kwargs)
self.thisown = 1
def wxFontFromNativeInfo(*_args,**_kwargs):
val = wxFontPtr(apply(gdic.new_wxFontFromNativeInfo,_args,_kwargs))
val.thisown = 1
return val
class wxFontListPtr(wxObjectPtr):
def __init__(self,this):
self.this = this
self.thisown = 0
def AddFont(self, *_args, **_kwargs):
val = apply(gdic.wxFontList_AddFont,(self,) + _args, _kwargs)
return val
def FindOrCreateFont(self, *_args, **_kwargs):
val = apply(gdic.wxFontList_FindOrCreateFont,(self,) + _args, _kwargs)
if val: val = wxFontPtr(val)
return val
def RemoveFont(self, *_args, **_kwargs):
val = apply(gdic.wxFontList_RemoveFont,(self,) + _args, _kwargs)
return val
def GetCount(self, *_args, **_kwargs):
val = apply(gdic.wxFontList_GetCount,(self,) + _args, _kwargs)
return val
def __repr__(self):
return "<C wxFontList instance at %s>" % (self.this,)
class wxFontList(wxFontListPtr):
def __init__(self,this):
self.this = this
class wxColourPtr(wxObjectPtr):
def __init__(self,this):
self.this = this
@@ -1326,81 +1132,10 @@ def wxMemoryDCFromDC(*_args, **_kwargs):
if val: val = wxMemoryDCPtr(val); val.thisown = 1
return val
wxFontMapper_GetEncodingName = gdic.wxFontMapper_GetEncodingName
wxFontMapper_GetEncodingDescription = gdic.wxFontMapper_GetEncodingDescription
wxFontMapper_GetDefaultConfigPath = gdic.wxFontMapper_GetDefaultConfigPath
wxFont_GetDefaultEncoding = gdic.wxFont_GetDefaultEncoding
wxFont_SetDefaultEncoding = gdic.wxFont_SetDefaultEncoding
#-------------- VARIABLE WRAPPERS ------------------
wxFONTFAMILY_DEFAULT = gdic.wxFONTFAMILY_DEFAULT
wxFONTFAMILY_DECORATIVE = gdic.wxFONTFAMILY_DECORATIVE
wxFONTFAMILY_ROMAN = gdic.wxFONTFAMILY_ROMAN
wxFONTFAMILY_SCRIPT = gdic.wxFONTFAMILY_SCRIPT
wxFONTFAMILY_SWISS = gdic.wxFONTFAMILY_SWISS
wxFONTFAMILY_MODERN = gdic.wxFONTFAMILY_MODERN
wxFONTFAMILY_TELETYPE = gdic.wxFONTFAMILY_TELETYPE
wxFONTFAMILY_MAX = gdic.wxFONTFAMILY_MAX
wxFONTFAMILY_UNKNOWN = gdic.wxFONTFAMILY_UNKNOWN
wxFONTSTYLE_NORMAL = gdic.wxFONTSTYLE_NORMAL
wxFONTSTYLE_ITALIC = gdic.wxFONTSTYLE_ITALIC
wxFONTSTYLE_SLANT = gdic.wxFONTSTYLE_SLANT
wxFONTSTYLE_MAX = gdic.wxFONTSTYLE_MAX
wxFONTWEIGHT_NORMAL = gdic.wxFONTWEIGHT_NORMAL
wxFONTWEIGHT_LIGHT = gdic.wxFONTWEIGHT_LIGHT
wxFONTWEIGHT_BOLD = gdic.wxFONTWEIGHT_BOLD
wxFONTWEIGHT_MAX = gdic.wxFONTWEIGHT_MAX
wxFONTENCODING_SYSTEM = gdic.wxFONTENCODING_SYSTEM
wxFONTENCODING_DEFAULT = gdic.wxFONTENCODING_DEFAULT
wxFONTENCODING_ISO8859_1 = gdic.wxFONTENCODING_ISO8859_1
wxFONTENCODING_ISO8859_2 = gdic.wxFONTENCODING_ISO8859_2
wxFONTENCODING_ISO8859_3 = gdic.wxFONTENCODING_ISO8859_3
wxFONTENCODING_ISO8859_4 = gdic.wxFONTENCODING_ISO8859_4
wxFONTENCODING_ISO8859_5 = gdic.wxFONTENCODING_ISO8859_5
wxFONTENCODING_ISO8859_6 = gdic.wxFONTENCODING_ISO8859_6
wxFONTENCODING_ISO8859_7 = gdic.wxFONTENCODING_ISO8859_7
wxFONTENCODING_ISO8859_8 = gdic.wxFONTENCODING_ISO8859_8
wxFONTENCODING_ISO8859_9 = gdic.wxFONTENCODING_ISO8859_9
wxFONTENCODING_ISO8859_10 = gdic.wxFONTENCODING_ISO8859_10
wxFONTENCODING_ISO8859_11 = gdic.wxFONTENCODING_ISO8859_11
wxFONTENCODING_ISO8859_12 = gdic.wxFONTENCODING_ISO8859_12
wxFONTENCODING_ISO8859_13 = gdic.wxFONTENCODING_ISO8859_13
wxFONTENCODING_ISO8859_14 = gdic.wxFONTENCODING_ISO8859_14
wxFONTENCODING_ISO8859_15 = gdic.wxFONTENCODING_ISO8859_15
wxFONTENCODING_ISO8859_MAX = gdic.wxFONTENCODING_ISO8859_MAX
wxFONTENCODING_KOI8 = gdic.wxFONTENCODING_KOI8
wxFONTENCODING_ALTERNATIVE = gdic.wxFONTENCODING_ALTERNATIVE
wxFONTENCODING_BULGARIAN = gdic.wxFONTENCODING_BULGARIAN
wxFONTENCODING_CP437 = gdic.wxFONTENCODING_CP437
wxFONTENCODING_CP850 = gdic.wxFONTENCODING_CP850
wxFONTENCODING_CP852 = gdic.wxFONTENCODING_CP852
wxFONTENCODING_CP855 = gdic.wxFONTENCODING_CP855
wxFONTENCODING_CP866 = gdic.wxFONTENCODING_CP866
wxFONTENCODING_CP874 = gdic.wxFONTENCODING_CP874
wxFONTENCODING_CP932 = gdic.wxFONTENCODING_CP932
wxFONTENCODING_CP936 = gdic.wxFONTENCODING_CP936
wxFONTENCODING_CP949 = gdic.wxFONTENCODING_CP949
wxFONTENCODING_CP950 = gdic.wxFONTENCODING_CP950
wxFONTENCODING_CP1250 = gdic.wxFONTENCODING_CP1250
wxFONTENCODING_CP1251 = gdic.wxFONTENCODING_CP1251
wxFONTENCODING_CP1252 = gdic.wxFONTENCODING_CP1252
wxFONTENCODING_CP1253 = gdic.wxFONTENCODING_CP1253
wxFONTENCODING_CP1254 = gdic.wxFONTENCODING_CP1254
wxFONTENCODING_CP1255 = gdic.wxFONTENCODING_CP1255
wxFONTENCODING_CP1256 = gdic.wxFONTENCODING_CP1256
wxFONTENCODING_CP1257 = gdic.wxFONTENCODING_CP1257
wxFONTENCODING_CP12_MAX = gdic.wxFONTENCODING_CP12_MAX
wxFONTENCODING_UTF7 = gdic.wxFONTENCODING_UTF7
wxFONTENCODING_UTF8 = gdic.wxFONTENCODING_UTF8
wxFONTENCODING_UNICODE = gdic.wxFONTENCODING_UNICODE
wxFONTENCODING_MAX = gdic.wxFONTENCODING_MAX
wxIMAGELIST_DRAW_NORMAL = gdic.wxIMAGELIST_DRAW_NORMAL
wxIMAGELIST_DRAW_TRANSPARENT = gdic.wxIMAGELIST_DRAW_TRANSPARENT
wxIMAGELIST_DRAW_SELECTED = gdic.wxIMAGELIST_DRAW_SELECTED

View File

@@ -5,6 +5,8 @@ from misc import *
from gdi import *
from fonts import *
from windows import *
from clip_dnd import *

View File

@@ -7,6 +7,8 @@ from misc import *
from gdi import *
from fonts import *
from clip_dnd import *
from controls import *

View File

@@ -9,6 +9,8 @@ from windows import *
from gdi import *
from fonts import *
from clip_dnd import *
from events import *

View File

@@ -9,6 +9,8 @@ from windows import *
from gdi import *
from fonts import *
from clip_dnd import *
from events import *

View File

@@ -100,7 +100,7 @@ static PyObject* t_output_helper(PyObject* target, PyObject* o) {
wxImage* wxImageFromBitmap(const wxBitmap &bitmap) {
return new wxImage(bitmap);
return new wxImage(bitmap.ConvertToImage());
}
@@ -1333,36 +1333,6 @@ static PyObject *_wrap_delete_wxImage(PyObject *self, PyObject *args, PyObject *
return _resultobj;
}
#define wxImage_ConvertToBitmap(_swigobj) (_swigobj->ConvertToBitmap())
static PyObject *_wrap_wxImage_ConvertToBitmap(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxBitmap * _result;
wxImage * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
char _ptemp[128];
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxImage_ConvertToBitmap",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxImage_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxImage_ConvertToBitmap. Expected _wxImage_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = new wxBitmap (wxImage_ConvertToBitmap(_arg0));
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} SWIG_MakePtr(_ptemp, (void *) _result,"_wxBitmap_p");
_resultobj = Py_BuildValue("s",_ptemp);
return _resultobj;
}
#define wxImage_Create(_swigobj,_swigarg0,_swigarg1) (_swigobj->Create(_swigarg0,_swigarg1))
static PyObject *_wrap_wxImage_Create(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
@@ -1614,6 +1584,156 @@ static PyObject *_wrap_wxImage_GetBlue(PyObject *self, PyObject *args, PyObject
return _resultobj;
}
#define wxImage_FindFirstUnusedColour(_swigobj,_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4,_swigarg5) (_swigobj->FindFirstUnusedColour(_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4,_swigarg5))
static PyObject *_wrap_wxImage_FindFirstUnusedColour(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
bool _result;
wxImage * _arg0;
byte * _arg1;
int temp;
byte * _arg2;
int temp0;
byte * _arg3;
int temp1;
byte _arg4 = (byte ) 0;
byte _arg5 = (byte ) 0;
byte _arg6 = (byte ) 0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self","startR","startG","startB", NULL };
self = self;
{
_arg1 = (byte*)&temp;
}
{
_arg2 = (byte*)&temp0;
}
{
_arg3 = (byte*)&temp1;
}
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|bbb:wxImage_FindFirstUnusedColour",_kwnames,&_argo0,&_arg4,&_arg5,&_arg6))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxImage_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxImage_FindFirstUnusedColour. Expected _wxImage_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (bool )wxImage_FindFirstUnusedColour(_arg0,_arg1,_arg2,_arg3,_arg4,_arg5,_arg6);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} _resultobj = Py_BuildValue("i",_result);
{
PyObject *o;
o = PyInt_FromLong((long) (*_arg1));
_resultobj = t_output_helper(_resultobj, o);
}
{
PyObject *o;
o = PyInt_FromLong((long) (*_arg2));
_resultobj = t_output_helper(_resultobj, o);
}
{
PyObject *o;
o = PyInt_FromLong((long) (*_arg3));
_resultobj = t_output_helper(_resultobj, o);
}
return _resultobj;
}
#define wxImage_SetMaskFromImage(_swigobj,_swigarg0,_swigarg1,_swigarg2,_swigarg3) (_swigobj->SetMaskFromImage(_swigarg0,_swigarg1,_swigarg2,_swigarg3))
static PyObject *_wrap_wxImage_SetMaskFromImage(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
bool _result;
wxImage * _arg0;
wxImage * _arg1;
byte _arg2;
byte _arg3;
byte _arg4;
PyObject * _argo0 = 0;
PyObject * _argo1 = 0;
char *_kwnames[] = { "self","mask","mr","mg","mb", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OObbb:wxImage_SetMaskFromImage",_kwnames,&_argo0,&_argo1,&_arg2,&_arg3,&_arg4))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxImage_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxImage_SetMaskFromImage. Expected _wxImage_p.");
return NULL;
}
}
if (_argo1) {
if (_argo1 == Py_None) { _arg1 = NULL; }
else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxImage_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxImage_SetMaskFromImage. Expected _wxImage_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (bool )wxImage_SetMaskFromImage(_arg0,*_arg1,_arg2,_arg3,_arg4);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} _resultobj = Py_BuildValue("i",_result);
return _resultobj;
}
#define wxImage_DoFloodFill(_swigobj,_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4,_swigarg5) (_swigobj->DoFloodFill(_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4,_swigarg5))
static PyObject *_wrap_wxImage_DoFloodFill(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxImage * _arg0;
wxCoord _arg1;
wxCoord _arg2;
wxBrush * _arg3;
wxColour * _arg4;
int _arg5 = (int ) wxFLOOD_SURFACE;
int _arg6 = (int ) wxCOPY;
PyObject * _argo0 = 0;
PyObject * _argo3 = 0;
wxColour temp;
PyObject * _obj4 = 0;
char *_kwnames[] = { "self","x","y","fillBrush","testColour","style","LogicalFunction", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OiiOO|ii:wxImage_DoFloodFill",_kwnames,&_argo0,&_arg1,&_arg2,&_argo3,&_obj4,&_arg5,&_arg6))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxImage_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxImage_DoFloodFill. Expected _wxImage_p.");
return NULL;
}
}
if (_argo3) {
if (_argo3 == Py_None) { _arg3 = NULL; }
else if (SWIG_GetPtrObj(_argo3,(void **) &_arg3,"_wxBrush_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 4 of wxImage_DoFloodFill. Expected _wxBrush_p.");
return NULL;
}
}
{
_arg4 = &temp;
if (! wxColour_helper(_obj4, &_arg4))
return NULL;
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
wxImage_DoFloodFill(_arg0,_arg1,_arg2,*_arg3,*_arg4,_arg5,_arg6);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} Py_INCREF(Py_None);
_resultobj = Py_None;
return _resultobj;
}
static PyObject *_wrap_wxImage_CanRead(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
bool _result;
@@ -2962,7 +3082,79 @@ static PyObject *_wrap_wxImage_RemoveHandler(PyObject *self, PyObject *args, PyO
return _resultobj;
}
static wxBitmap wxImage_ConvertToBitmap(wxImage *self) {
wxBitmap bitmap(*self);
return bitmap;
}
static PyObject *_wrap_wxImage_ConvertToBitmap(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxBitmap * _result;
wxImage * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
char _ptemp[128];
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxImage_ConvertToBitmap",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxImage_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxImage_ConvertToBitmap. Expected _wxImage_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = new wxBitmap (wxImage_ConvertToBitmap(_arg0));
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} SWIG_MakePtr(_ptemp, (void *) _result,"_wxBitmap_p");
_resultobj = Py_BuildValue("s",_ptemp);
return _resultobj;
}
static wxBitmap wxImage_ConvertToMonoBitmap(wxImage *self,unsigned char red,unsigned char green,unsigned char blue) {
wxImage mono = self->ConvertToMono( red, green, blue );
wxBitmap bitmap( mono, 1 );
return bitmap;
}
static PyObject *_wrap_wxImage_ConvertToMonoBitmap(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxBitmap * _result;
wxImage * _arg0;
unsigned char _arg1;
unsigned char _arg2;
unsigned char _arg3;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self","red","green","blue", NULL };
char _ptemp[128];
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Obbb:wxImage_ConvertToMonoBitmap",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxImage_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxImage_ConvertToMonoBitmap. Expected _wxImage_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = new wxBitmap (wxImage_ConvertToMonoBitmap(_arg0,_arg1,_arg2,_arg3));
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} SWIG_MakePtr(_ptemp, (void *) _result,"_wxBitmap_p");
_resultobj = Py_BuildValue("s",_ptemp);
return _resultobj;
}
static PyMethodDef imagecMethods[] = {
{ "wxImage_ConvertToMonoBitmap", (PyCFunction) _wrap_wxImage_ConvertToMonoBitmap, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_ConvertToBitmap", (PyCFunction) _wrap_wxImage_ConvertToBitmap, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_RemoveHandler", (PyCFunction) _wrap_wxImage_RemoveHandler, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_InsertHandler", (PyCFunction) _wrap_wxImage_InsertHandler, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_AddHandler", (PyCFunction) _wrap_wxImage_AddHandler, METH_VARARGS | METH_KEYWORDS },
@@ -3000,6 +3192,9 @@ static PyMethodDef imagecMethods[] = {
{ "wxImage_LoadFile", (PyCFunction) _wrap_wxImage_LoadFile, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_GetImageCount", (PyCFunction) _wrap_wxImage_GetImageCount, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_CanRead", (PyCFunction) _wrap_wxImage_CanRead, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_DoFloodFill", (PyCFunction) _wrap_wxImage_DoFloodFill, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_SetMaskFromImage", (PyCFunction) _wrap_wxImage_SetMaskFromImage, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_FindFirstUnusedColour", (PyCFunction) _wrap_wxImage_FindFirstUnusedColour, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_GetBlue", (PyCFunction) _wrap_wxImage_GetBlue, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_GetGreen", (PyCFunction) _wrap_wxImage_GetGreen, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_GetRed", (PyCFunction) _wrap_wxImage_GetRed, METH_VARARGS | METH_KEYWORDS },
@@ -3008,7 +3203,6 @@ static PyMethodDef imagecMethods[] = {
{ "wxImage_Scale", (PyCFunction) _wrap_wxImage_Scale, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_Destroy", (PyCFunction) _wrap_wxImage_Destroy, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_Create", (PyCFunction) _wrap_wxImage_Create, METH_VARARGS | METH_KEYWORDS },
{ "wxImage_ConvertToBitmap", (PyCFunction) _wrap_wxImage_ConvertToBitmap, METH_VARARGS | METH_KEYWORDS },
{ "delete_wxImage", (PyCFunction) _wrap_delete_wxImage, METH_VARARGS | METH_KEYWORDS },
{ "new_wxImage", (PyCFunction) _wrap_new_wxImage, METH_VARARGS | METH_KEYWORDS },
{ "new_wxTIFFHandler", (PyCFunction) _wrap_new_wxTIFFHandler, METH_VARARGS | METH_KEYWORDS },

View File

@@ -5,6 +5,8 @@ from misc import *
from gdi import *
from fonts import *
from streams import *
class wxImageHandlerPtr(wxObjectPtr):
def __init__(self,this):
@@ -193,10 +195,6 @@ class wxImagePtr(wxObjectPtr):
def __del__(self,imagec=imagec):
if self.thisown == 1 :
imagec.delete_wxImage(self)
def ConvertToBitmap(self, *_args, **_kwargs):
val = apply(imagec.wxImage_ConvertToBitmap,(self,) + _args, _kwargs)
if val: val = wxBitmapPtr(val) ; val.thisown = 1
return val
def Create(self, *_args, **_kwargs):
val = apply(imagec.wxImage_Create,(self,) + _args, _kwargs)
return val
@@ -223,6 +221,15 @@ class wxImagePtr(wxObjectPtr):
def GetBlue(self, *_args, **_kwargs):
val = apply(imagec.wxImage_GetBlue,(self,) + _args, _kwargs)
return val
def FindFirstUnusedColour(self, *_args, **_kwargs):
val = apply(imagec.wxImage_FindFirstUnusedColour,(self,) + _args, _kwargs)
return val
def SetMaskFromImage(self, *_args, **_kwargs):
val = apply(imagec.wxImage_SetMaskFromImage,(self,) + _args, _kwargs)
return val
def DoFloodFill(self, *_args, **_kwargs):
val = apply(imagec.wxImage_DoFloodFill,(self,) + _args, _kwargs)
return val
def LoadFile(self, *_args, **_kwargs):
val = apply(imagec.wxImage_LoadFile,(self,) + _args, _kwargs)
return val
@@ -322,6 +329,14 @@ class wxImagePtr(wxObjectPtr):
def CountColours(self, *_args, **_kwargs):
val = apply(imagec.wxImage_CountColours,(self,) + _args, _kwargs)
return val
def ConvertToBitmap(self, *_args, **_kwargs):
val = apply(imagec.wxImage_ConvertToBitmap,(self,) + _args, _kwargs)
if val: val = wxBitmapPtr(val) ; val.thisown = 1
return val
def ConvertToMonoBitmap(self, *_args, **_kwargs):
val = apply(imagec.wxImage_ConvertToMonoBitmap,(self,) + _args, _kwargs)
if val: val = wxBitmapPtr(val) ; val.thisown = 1
return val
def __repr__(self):
return "<C wxImage instance at %s>" % (self.this,)
class wxImage(wxImagePtr):

View File

@@ -7,6 +7,8 @@ from windows import *
from gdi import *
from fonts import *
from clip_dnd import *
from frames import *

View File

@@ -60,7 +60,6 @@ extern PyObject *SWIG_newvarlink(void);
#include <wx/resource.h>
#include <wx/tooltip.h>
#include <wx/caret.h>
#include <wx/fontenum.h>
#include <wx/tipdlg.h>
#include <wx/process.h>
@@ -115,21 +114,6 @@ static PyObject* t_output_helper(PyObject* target, PyObject* o) {
wxCaret::SetBlinkTime(milliseconds);
}
class wxPyFontEnumerator : public wxFontEnumerator {
public:
wxPyFontEnumerator() {}
~wxPyFontEnumerator() {}
DEC_PYCALLBACK_BOOL_STRING(OnFacename);
DEC_PYCALLBACK_BOOL_STRINGSTRING(OnFontEncoding);
PYPRIVATE;
};
IMP_PYCALLBACK_BOOL_STRING(wxPyFontEnumerator, wxFontEnumerator, OnFacename);
IMP_PYCALLBACK_BOOL_STRINGSTRING(wxPyFontEnumerator, wxFontEnumerator, OnFontEncoding);
bool wxThread_IsMain() {
#ifdef WXP_WITH_THREAD
return wxThread::IsMain();
@@ -2184,11 +2168,11 @@ static PyObject *_wrap_wxExecute(PyObject *self, PyObject *args, PyObject *kwarg
PyObject * _resultobj;
long _result;
wxString * _arg0;
int _arg1 = (int ) FALSE;
int _arg1 = (int ) (wxEXEC_ASYNC);
wxPyProcess * _arg2 = (wxPyProcess *) NULL;
PyObject * _obj0 = 0;
PyObject * _argo2 = 0;
char *_kwnames[] = { "command","sync","process", NULL };
char *_kwnames[] = { "command","flags","process", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|iO:wxExecute",_kwnames,&_obj0,&_arg1,&_argo2))
@@ -3039,239 +3023,6 @@ static PyObject *_wrap_wxCaret_Hide(PyObject *self, PyObject *args, PyObject *kw
return _resultobj;
}
#define new_wxFontEnumerator() (new wxPyFontEnumerator())
static PyObject *_wrap_new_wxFontEnumerator(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxPyFontEnumerator * _result;
char *_kwnames[] = { NULL };
char _ptemp[128];
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxFontEnumerator",_kwnames))
return NULL;
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (wxPyFontEnumerator *)new_wxFontEnumerator();
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} if (_result) {
SWIG_MakePtr(_ptemp, (char *) _result,"_wxPyFontEnumerator_p");
_resultobj = Py_BuildValue("s",_ptemp);
} else {
Py_INCREF(Py_None);
_resultobj = Py_None;
}
return _resultobj;
}
#define delete_wxPyFontEnumerator(_swigobj) (delete _swigobj)
static PyObject *_wrap_delete_wxFontEnumerator(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxPyFontEnumerator * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxFontEnumerator",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyFontEnumerator_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of delete_wxFontEnumerator. Expected _wxPyFontEnumerator_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
delete_wxPyFontEnumerator(_arg0);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} Py_INCREF(Py_None);
_resultobj = Py_None;
return _resultobj;
}
#define wxFontEnumerator__setCallbackInfo(_swigobj,_swigarg0,_swigarg1,_swigarg2) (_swigobj->_setCallbackInfo(_swigarg0,_swigarg1,_swigarg2))
static PyObject *_wrap_wxFontEnumerator__setCallbackInfo(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxPyFontEnumerator * _arg0;
PyObject * _arg1;
PyObject * _arg2;
bool _arg3;
PyObject * _argo0 = 0;
PyObject * _obj1 = 0;
PyObject * _obj2 = 0;
int tempbool3;
char *_kwnames[] = { "self","self","_class","incref", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOOi:wxFontEnumerator__setCallbackInfo",_kwnames,&_argo0,&_obj1,&_obj2,&tempbool3))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyFontEnumerator_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxFontEnumerator__setCallbackInfo. Expected _wxPyFontEnumerator_p.");
return NULL;
}
}
{
_arg1 = _obj1;
}
{
_arg2 = _obj2;
}
_arg3 = (bool ) tempbool3;
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
wxFontEnumerator__setCallbackInfo(_arg0,_arg1,_arg2,_arg3);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} Py_INCREF(Py_None);
_resultobj = Py_None;
return _resultobj;
}
#define wxFontEnumerator_EnumerateFacenames(_swigobj,_swigarg0,_swigarg1) (_swigobj->EnumerateFacenames(_swigarg0,_swigarg1))
static PyObject *_wrap_wxFontEnumerator_EnumerateFacenames(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
bool _result;
wxPyFontEnumerator * _arg0;
wxFontEncoding _arg1 = (wxFontEncoding ) wxFONTENCODING_SYSTEM;
bool _arg2 = (bool ) FALSE;
PyObject * _argo0 = 0;
int tempbool2 = (int) FALSE;
char *_kwnames[] = { "self","encoding","fixedWidthOnly", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|ii:wxFontEnumerator_EnumerateFacenames",_kwnames,&_argo0,&_arg1,&tempbool2))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyFontEnumerator_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxFontEnumerator_EnumerateFacenames. Expected _wxPyFontEnumerator_p.");
return NULL;
}
}
_arg2 = (bool ) tempbool2;
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (bool )wxFontEnumerator_EnumerateFacenames(_arg0,_arg1,_arg2);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} _resultobj = Py_BuildValue("i",_result);
return _resultobj;
}
#define wxFontEnumerator_EnumerateEncodings(_swigobj,_swigarg0) (_swigobj->EnumerateEncodings(_swigarg0))
static PyObject *_wrap_wxFontEnumerator_EnumerateEncodings(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
bool _result;
wxPyFontEnumerator * _arg0;
wxString * _arg1 = (wxString *) &wxPyEmptyString;
PyObject * _argo0 = 0;
PyObject * _obj1 = 0;
char *_kwnames[] = { "self","facename", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|O:wxFontEnumerator_EnumerateEncodings",_kwnames,&_argo0,&_obj1))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyFontEnumerator_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxFontEnumerator_EnumerateEncodings. Expected _wxPyFontEnumerator_p.");
return NULL;
}
}
if (_obj1)
{
_arg1 = wxString_in_helper(_obj1);
if (_arg1 == NULL)
return NULL;
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (bool )wxFontEnumerator_EnumerateEncodings(_arg0,*_arg1);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} _resultobj = Py_BuildValue("i",_result);
{
if (_obj1)
delete _arg1;
}
return _resultobj;
}
static PyObject * wxPyFontEnumerator_GetEncodings(wxPyFontEnumerator *self) {
wxArrayString* arr = self->GetEncodings();
return wxArrayString2PyList_helper(*arr);
}
static PyObject *_wrap_wxFontEnumerator_GetEncodings(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
PyObject * _result;
wxPyFontEnumerator * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxFontEnumerator_GetEncodings",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyFontEnumerator_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxFontEnumerator_GetEncodings. Expected _wxPyFontEnumerator_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (PyObject *)wxPyFontEnumerator_GetEncodings(_arg0);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
}{
_resultobj = _result;
}
return _resultobj;
}
static PyObject * wxPyFontEnumerator_GetFacenames(wxPyFontEnumerator *self) {
wxArrayString* arr = self->GetFacenames();
return wxArrayString2PyList_helper(*arr);
}
static PyObject *_wrap_wxFontEnumerator_GetFacenames(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
PyObject * _result;
wxPyFontEnumerator * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxFontEnumerator_GetFacenames",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyFontEnumerator_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxFontEnumerator_GetFacenames. Expected _wxPyFontEnumerator_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (PyObject *)wxPyFontEnumerator_GetFacenames(_arg0);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
}{
_resultobj = _result;
}
return _resultobj;
}
#define new_wxBusyCursor(_swigarg0) (new wxBusyCursor(_swigarg0))
static PyObject *_wrap_new_wxBusyCursor(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
@@ -4873,29 +4624,19 @@ static PyObject *_wrap_wxLog_Resume(PyObject *self, PyObject *args, PyObject *kw
return _resultobj;
}
#define wxLog_SetVerbose(_swigobj,_swigarg0) (_swigobj->SetVerbose(_swigarg0))
static PyObject *_wrap_wxLog_SetVerbose(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxLog * _arg0;
bool _arg1 = (bool ) TRUE;
PyObject * _argo0 = 0;
int tempbool1 = (int) TRUE;
char *_kwnames[] = { "self","bVerbose", NULL };
bool _arg0 = (bool ) TRUE;
int tempbool0 = (int) TRUE;
char *_kwnames[] = { "bVerbose", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:wxLog_SetVerbose",_kwnames,&_argo0,&tempbool1))
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|i:wxLog_SetVerbose",_kwnames,&tempbool0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxLog_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxLog_SetVerbose. Expected _wxLog_p.");
return NULL;
}
}
_arg1 = (bool ) tempbool1;
_arg0 = (bool ) tempbool0;
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
wxLog_SetVerbose(_arg0,_arg1);
wxLog::SetVerbose(_arg0);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
@@ -9834,8 +9575,8 @@ static PyObject *_wrap_wxFileHistory_AddFilesToMenu(PyObject *self, PyObject *ar
return _resultobj;
}
#define wxFileHistory_AddFilesToSingleMenu(_swigobj,_swigarg0) (_swigobj->AddFilesToMenu(_swigarg0))
static PyObject *_wrap_wxFileHistory_AddFilesToSingleMenu(PyObject *self, PyObject *args, PyObject *kwargs) {
#define wxFileHistory_AddFilesToThisMenu(_swigobj,_swigarg0) (_swigobj->AddFilesToMenu(_swigarg0))
static PyObject *_wrap_wxFileHistory_AddFilesToThisMenu(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxFileHistory * _arg0;
wxMenu * _arg1;
@@ -9844,25 +9585,25 @@ static PyObject *_wrap_wxFileHistory_AddFilesToSingleMenu(PyObject *self, PyObje
char *_kwnames[] = { "self","menu", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxFileHistory_AddFilesToSingleMenu",_kwnames,&_argo0,&_argo1))
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxFileHistory_AddFilesToThisMenu",_kwnames,&_argo0,&_argo1))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxFileHistory_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxFileHistory_AddFilesToSingleMenu. Expected _wxFileHistory_p.");
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxFileHistory_AddFilesToThisMenu. Expected _wxFileHistory_p.");
return NULL;
}
}
if (_argo1) {
if (_argo1 == Py_None) { _arg1 = NULL; }
else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxMenu_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxFileHistory_AddFilesToSingleMenu. Expected _wxMenu_p.");
PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxFileHistory_AddFilesToThisMenu. Expected _wxMenu_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
wxFileHistory_AddFilesToSingleMenu(_arg0,_arg1);
wxFileHistory_AddFilesToThisMenu(_arg0,_arg1);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
@@ -9969,7 +9710,7 @@ static PyMethodDef misc2cMethods[] = {
{ "wxFileHistory_GetNoHistoryFiles", (PyCFunction) _wrap_wxFileHistory_GetNoHistoryFiles, METH_VARARGS | METH_KEYWORDS },
{ "wxFileHistory_GetCount", (PyCFunction) _wrap_wxFileHistory_GetCount, METH_VARARGS | METH_KEYWORDS },
{ "wxFileHistory_GetHistoryFile", (PyCFunction) _wrap_wxFileHistory_GetHistoryFile, METH_VARARGS | METH_KEYWORDS },
{ "wxFileHistory_AddFilesToSingleMenu", (PyCFunction) _wrap_wxFileHistory_AddFilesToSingleMenu, METH_VARARGS | METH_KEYWORDS },
{ "wxFileHistory_AddFilesToThisMenu", (PyCFunction) _wrap_wxFileHistory_AddFilesToThisMenu, METH_VARARGS | METH_KEYWORDS },
{ "wxFileHistory_AddFilesToMenu", (PyCFunction) _wrap_wxFileHistory_AddFilesToMenu, METH_VARARGS | METH_KEYWORDS },
{ "wxFileHistory_Save", (PyCFunction) _wrap_wxFileHistory_Save, METH_VARARGS | METH_KEYWORDS },
{ "wxFileHistory_Load", (PyCFunction) _wrap_wxFileHistory_Load, METH_VARARGS | METH_KEYWORDS },
@@ -10170,13 +9911,6 @@ static PyMethodDef misc2cMethods[] = {
{ "new_wxWindowDisabler", (PyCFunction) _wrap_new_wxWindowDisabler, METH_VARARGS | METH_KEYWORDS },
{ "delete_wxBusyCursor", (PyCFunction) _wrap_delete_wxBusyCursor, METH_VARARGS | METH_KEYWORDS },
{ "new_wxBusyCursor", (PyCFunction) _wrap_new_wxBusyCursor, METH_VARARGS | METH_KEYWORDS },
{ "wxFontEnumerator_GetFacenames", (PyCFunction) _wrap_wxFontEnumerator_GetFacenames, METH_VARARGS | METH_KEYWORDS },
{ "wxFontEnumerator_GetEncodings", (PyCFunction) _wrap_wxFontEnumerator_GetEncodings, METH_VARARGS | METH_KEYWORDS },
{ "wxFontEnumerator_EnumerateEncodings", (PyCFunction) _wrap_wxFontEnumerator_EnumerateEncodings, METH_VARARGS | METH_KEYWORDS },
{ "wxFontEnumerator_EnumerateFacenames", (PyCFunction) _wrap_wxFontEnumerator_EnumerateFacenames, METH_VARARGS | METH_KEYWORDS },
{ "wxFontEnumerator__setCallbackInfo", (PyCFunction) _wrap_wxFontEnumerator__setCallbackInfo, METH_VARARGS | METH_KEYWORDS },
{ "delete_wxFontEnumerator", (PyCFunction) _wrap_delete_wxFontEnumerator, METH_VARARGS | METH_KEYWORDS },
{ "new_wxFontEnumerator", (PyCFunction) _wrap_new_wxFontEnumerator, METH_VARARGS | METH_KEYWORDS },
{ "wxCaret_Hide", (PyCFunction) _wrap_wxCaret_Hide, METH_VARARGS | METH_KEYWORDS },
{ "wxCaret_Show", (PyCFunction) _wrap_wxCaret_Show, METH_VARARGS | METH_KEYWORDS },
{ "wxCaret_SetSize", (PyCFunction) _wrap_wxCaret_SetSize, METH_VARARGS | METH_KEYWORDS },
@@ -10492,6 +10226,10 @@ SWIGEXPORT(void) initmisc2c() {
PyDict_SetItemString(d,"wxLOG_Progress", PyInt_FromLong((long) wxLOG_Progress));
PyDict_SetItemString(d,"wxLOG_User", PyInt_FromLong((long) wxLOG_User));
PyDict_SetItemString(d,"wxEVT_END_PROCESS", PyInt_FromLong((long) wxEVT_END_PROCESS));
PyDict_SetItemString(d,"wxEXEC_ASYNC", PyInt_FromLong((long) wxEXEC_ASYNC));
PyDict_SetItemString(d,"wxEXEC_SYNC", PyInt_FromLong((long) wxEXEC_SYNC));
PyDict_SetItemString(d,"wxEXEC_NOHIDE", PyInt_FromLong((long) wxEXEC_NOHIDE));
PyDict_SetItemString(d,"wxEXEC_MAKE_GROUP_LEADER", PyInt_FromLong((long) wxEXEC_MAKE_GROUP_LEADER));
PyDict_SetItemString(d,"wxMAILCAP_STANDARD", PyInt_FromLong((long) wxMAILCAP_STANDARD));
PyDict_SetItemString(d,"wxMAILCAP_NETSCAPE", PyInt_FromLong((long) wxMAILCAP_NETSCAPE));
PyDict_SetItemString(d,"wxMAILCAP_KDE", PyInt_FromLong((long) wxMAILCAP_KDE));
@@ -10500,7 +10238,6 @@ SWIGEXPORT(void) initmisc2c() {
PyDict_SetItemString(d,"cvar", SWIG_globals);
SWIG_addvarlink(SWIG_globals,"wxTheMimeTypesManager",_wrap_wxTheMimeTypesManager_get, _wrap_wxTheMimeTypesManager_set);
wxPyPtrTypeMap_Add("wxFontEnumerator", "wxPyFontEnumerator");
wxPyPtrTypeMap_Add("wxDragImage", "wxGenericDragImage");
wxPyPtrTypeMap_Add("wxProcess", "wxPyProcess");
{

View File

@@ -7,6 +7,8 @@ from misc import *
from gdi import *
from fonts import *
from clip_dnd import *
from events import *
@@ -108,39 +110,6 @@ class wxCaret(wxCaretPtr):
class wxFontEnumeratorPtr :
def __init__(self,this):
self.this = this
self.thisown = 0
def __del__(self,misc2c=misc2c):
if self.thisown == 1 :
misc2c.delete_wxFontEnumerator(self)
def _setCallbackInfo(self, *_args, **_kwargs):
val = apply(misc2c.wxFontEnumerator__setCallbackInfo,(self,) + _args, _kwargs)
return val
def EnumerateFacenames(self, *_args, **_kwargs):
val = apply(misc2c.wxFontEnumerator_EnumerateFacenames,(self,) + _args, _kwargs)
return val
def EnumerateEncodings(self, *_args, **_kwargs):
val = apply(misc2c.wxFontEnumerator_EnumerateEncodings,(self,) + _args, _kwargs)
return val
def GetEncodings(self, *_args, **_kwargs):
val = apply(misc2c.wxFontEnumerator_GetEncodings,(self,) + _args, _kwargs)
return val
def GetFacenames(self, *_args, **_kwargs):
val = apply(misc2c.wxFontEnumerator_GetFacenames,(self,) + _args, _kwargs)
return val
def __repr__(self):
return "<C wxFontEnumerator instance at %s>" % (self.this,)
class wxFontEnumerator(wxFontEnumeratorPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(misc2c.new_wxFontEnumerator,_args,_kwargs)
self.thisown = 1
self._setCallbackInfo(self, wxFontEnumerator, 0)
class wxBusyCursorPtr :
def __init__(self,this):
self.this = this
@@ -367,9 +336,6 @@ class wxLogPtr :
def HasPendingMessages(self, *_args, **_kwargs):
val = apply(misc2c.wxLog_HasPendingMessages,(self,) + _args, _kwargs)
return val
def SetVerbose(self, *_args, **_kwargs):
val = apply(misc2c.wxLog_SetVerbose,(self,) + _args, _kwargs)
return val
def GetVerbose(self, *_args, **_kwargs):
val = apply(misc2c.wxLog_GetVerbose,(self,) + _args, _kwargs)
return val
@@ -965,8 +931,8 @@ class wxFileHistoryPtr(wxObjectPtr):
def AddFilesToMenu(self, *_args, **_kwargs):
val = apply(misc2c.wxFileHistory_AddFilesToMenu,(self,) + _args, _kwargs)
return val
def AddFilesToSingleMenu(self, *_args, **_kwargs):
val = apply(misc2c.wxFileHistory_AddFilesToSingleMenu,(self,) + _args, _kwargs)
def AddFilesToThisMenu(self, *_args, **_kwargs):
val = apply(misc2c.wxFileHistory_AddFilesToThisMenu,(self,) + _args, _kwargs)
return val
def GetHistoryFile(self, *_args, **_kwargs):
val = apply(misc2c.wxFileHistory_GetHistoryFile,(self,) + _args, _kwargs)
@@ -1178,6 +1144,8 @@ wxLog_Suspend = misc2c.wxLog_Suspend
wxLog_Resume = misc2c.wxLog_Resume
wxLog_SetVerbose = misc2c.wxLog_SetVerbose
wxLog_DontCreateOnDemand = misc2c.wxLog_DontCreateOnDemand
wxLog_SetTraceMask = misc2c.wxLog_SetTraceMask
@@ -1300,6 +1268,10 @@ wxLOG_Trace = misc2c.wxLOG_Trace
wxLOG_Progress = misc2c.wxLOG_Progress
wxLOG_User = misc2c.wxLOG_User
wxEVT_END_PROCESS = misc2c.wxEVT_END_PROCESS
wxEXEC_ASYNC = misc2c.wxEXEC_ASYNC
wxEXEC_SYNC = misc2c.wxEXEC_SYNC
wxEXEC_NOHIDE = misc2c.wxEXEC_NOHIDE
wxEXEC_MAKE_GROUP_LEADER = misc2c.wxEXEC_MAKE_GROUP_LEADER
wxMAILCAP_STANDARD = misc2c.wxMAILCAP_STANDARD
wxMAILCAP_NETSCAPE = misc2c.wxMAILCAP_NETSCAPE
wxMAILCAP_KDE = misc2c.wxMAILCAP_KDE

View File

@@ -7,6 +7,8 @@ from windows import *
from gdi import *
from fonts import *
from clip_dnd import *
from cmndlgs import *

View File

@@ -7,6 +7,8 @@ from windows import *
from gdi import *
from fonts import *
from clip_dnd import *
from controls import *

View File

@@ -784,6 +784,34 @@ static PyObject *_wrap_wxToolBarToolBase_GetStyle(PyObject *self, PyObject *args
return _resultobj;
}
#define wxToolBarToolBase_GetKind(_swigobj) (_swigobj->GetKind())
static PyObject *_wrap_wxToolBarToolBase_GetKind(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxItemKind _result;
wxToolBarToolBase * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxToolBarToolBase_GetKind",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxToolBarToolBase_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBarToolBase_GetKind. Expected _wxToolBarToolBase_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (wxItemKind )wxToolBarToolBase_GetKind(_arg0);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} _resultobj = Py_BuildValue("i",_result);
return _resultobj;
}
#define wxToolBarToolBase_IsEnabled(_swigobj) (_swigobj->IsEnabled())
static PyObject *_wrap_wxToolBarToolBase_IsEnabled(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
@@ -1533,60 +1561,63 @@ static void *SwigwxToolBarBaseTowxObject(void *ptr) {
return (void *) dest;
}
static wxToolBarToolBase * wxToolBarBase_AddTool(wxToolBarBase *self,int id,const wxBitmap & bitmap,const wxBitmap & pushedBitmap,int isToggle,PyObject * clientData,const wxString & shortHelpString,const wxString & longHelpString) {
static wxToolBarToolBase * wxToolBarBase_DoAddTool(wxToolBarBase *self,int id,const wxString & label,const wxBitmap & bitmap,const wxBitmap & bmpDisabled,wxItemKind kind,const wxString & shortHelp,const wxString & longHelp,PyObject * clientData) {
wxPyUserData* udata = NULL;
if (clientData)
if (clientData && clientData != Py_None)
udata = new wxPyUserData(clientData);
return self->AddTool(id, bitmap, pushedBitmap, (bool)isToggle,
udata, shortHelpString, longHelpString);
return self->AddTool(id, label, bitmap, bmpDisabled, kind,
shortHelp, longHelp, udata);
}
static PyObject *_wrap_wxToolBarBase_AddTool(PyObject *self, PyObject *args, PyObject *kwargs) {
static PyObject *_wrap_wxToolBarBase_DoAddTool(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxToolBarToolBase * _result;
wxToolBarBase * _arg0;
int _arg1;
wxBitmap * _arg2;
wxBitmap * _arg3 = (wxBitmap *) &wxNullBitmap;
int _arg4 = (int ) FALSE;
PyObject * _arg5 = (PyObject *) NULL;
wxString * _arg2;
wxBitmap * _arg3;
wxBitmap * _arg4 = (wxBitmap *) &wxNullBitmap;
wxItemKind _arg5 = (wxItemKind ) wxITEM_NORMAL;
wxString * _arg6 = (wxString *) &wxPyEmptyString;
wxString * _arg7 = (wxString *) &wxPyEmptyString;
PyObject * _arg8 = (PyObject *) NULL;
PyObject * _argo0 = 0;
PyObject * _argo2 = 0;
PyObject * _obj2 = 0;
PyObject * _argo3 = 0;
PyObject * _obj5 = 0;
PyObject * _argo4 = 0;
PyObject * _obj6 = 0;
PyObject * _obj7 = 0;
char *_kwnames[] = { "self","id","bitmap","pushedBitmap","isToggle","clientData","shortHelpString","longHelpString", NULL };
PyObject * _obj8 = 0;
char *_kwnames[] = { "self","id","label","bitmap","bmpDisabled","kind","shortHelp","longHelp","clientData", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OiO|OiOOO:wxToolBarBase_AddTool",_kwnames,&_argo0,&_arg1,&_argo2,&_argo3,&_arg4,&_obj5,&_obj6,&_obj7))
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OiOO|OiOOO:wxToolBarBase_DoAddTool",_kwnames,&_argo0,&_arg1,&_obj2,&_argo3,&_argo4,&_arg5,&_obj6,&_obj7,&_obj8))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxToolBarBase_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBarBase_AddTool. Expected _wxToolBarBase_p.");
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBarBase_DoAddTool. Expected _wxToolBarBase_p.");
return NULL;
}
}
if (_argo2) {
if (_argo2 == Py_None) { _arg2 = NULL; }
else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxBitmap_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxToolBarBase_AddTool. Expected _wxBitmap_p.");
{
_arg2 = wxString_in_helper(_obj2);
if (_arg2 == NULL)
return NULL;
}
}
}
if (_argo3) {
if (_argo3 == Py_None) { _arg3 = NULL; }
else if (SWIG_GetPtrObj(_argo3,(void **) &_arg3,"_wxBitmap_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 4 of wxToolBarBase_AddTool. Expected _wxBitmap_p.");
PyErr_SetString(PyExc_TypeError,"Type error in argument 4 of wxToolBarBase_DoAddTool. Expected _wxBitmap_p.");
return NULL;
}
}
if (_argo4) {
if (_argo4 == Py_None) { _arg4 = NULL; }
else if (SWIG_GetPtrObj(_argo4,(void **) &_arg4,"_wxBitmap_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 5 of wxToolBarBase_DoAddTool. Expected _wxBitmap_p.");
return NULL;
}
}
if (_obj5)
{
_arg5 = _obj5;
}
if (_obj6)
{
_arg6 = wxString_in_helper(_obj6);
@@ -1598,14 +1629,22 @@ static PyObject *_wrap_wxToolBarBase_AddTool(PyObject *self, PyObject *args, PyO
_arg7 = wxString_in_helper(_obj7);
if (_arg7 == NULL)
return NULL;
}
if (_obj8)
{
_arg8 = _obj8;
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (wxToolBarToolBase *)wxToolBarBase_AddTool(_arg0,_arg1,*_arg2,*_arg3,_arg4,_arg5,*_arg6,*_arg7);
_result = (wxToolBarToolBase *)wxToolBarBase_DoAddTool(_arg0,_arg1,*_arg2,*_arg3,*_arg4,_arg5,*_arg6,*_arg7,_arg8);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
}{ _resultobj = wxPyMake_wxObject(_result); }
{
if (_obj2)
delete _arg2;
}
{
if (_obj6)
delete _arg6;
@@ -1617,78 +1656,12 @@ static PyObject *_wrap_wxToolBarBase_AddTool(PyObject *self, PyObject *args, PyO
return _resultobj;
}
static wxToolBarToolBase * wxToolBarBase_AddSimpleTool(wxToolBarBase *self,int id,const wxBitmap & bitmap,const wxString & shortHelpString,const wxString & longHelpString,int isToggle) {
return self->AddTool(id, bitmap, wxNullBitmap, isToggle, NULL,
shortHelpString, longHelpString);
}
static PyObject *_wrap_wxToolBarBase_AddSimpleTool(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxToolBarToolBase * _result;
wxToolBarBase * _arg0;
int _arg1;
wxBitmap * _arg2;
wxString * _arg3 = (wxString *) &wxPyEmptyString;
wxString * _arg4 = (wxString *) &wxPyEmptyString;
int _arg5 = (int ) FALSE;
PyObject * _argo0 = 0;
PyObject * _argo2 = 0;
PyObject * _obj3 = 0;
PyObject * _obj4 = 0;
char *_kwnames[] = { "self","id","bitmap","shortHelpString","longHelpString","isToggle", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OiO|OOi:wxToolBarBase_AddSimpleTool",_kwnames,&_argo0,&_arg1,&_argo2,&_obj3,&_obj4,&_arg5))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxToolBarBase_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBarBase_AddSimpleTool. Expected _wxToolBarBase_p.");
return NULL;
}
}
if (_argo2) {
if (_argo2 == Py_None) { _arg2 = NULL; }
else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxBitmap_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxToolBarBase_AddSimpleTool. Expected _wxBitmap_p.");
return NULL;
}
}
if (_obj3)
{
_arg3 = wxString_in_helper(_obj3);
if (_arg3 == NULL)
return NULL;
}
if (_obj4)
{
_arg4 = wxString_in_helper(_obj4);
if (_arg4 == NULL)
return NULL;
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (wxToolBarToolBase *)wxToolBarBase_AddSimpleTool(_arg0,_arg1,*_arg2,*_arg3,*_arg4,_arg5);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
}{ _resultobj = wxPyMake_wxObject(_result); }
{
if (_obj3)
delete _arg3;
}
{
if (_obj4)
delete _arg4;
}
return _resultobj;
}
static wxToolBarToolBase * wxToolBarBase_InsertTool(wxToolBarBase *self,size_t pos,int id,const wxBitmap & bitmap,const wxBitmap & pushedBitmap,int isToggle,PyObject * clientData,const wxString & shortHelpString,const wxString & longHelpString) {
static wxToolBarToolBase * wxToolBarBase_InsertTool(wxToolBarBase *self,size_t pos,int id,const wxString & label,const wxBitmap & bitmap,const wxBitmap & bmpDisabled,wxItemKind kind,const wxString & shortHelp,const wxString & longHelp,PyObject * clientData) {
wxPyUserData* udata = NULL;
if (clientData)
if (clientData && clientData != Py_None)
udata = new wxPyUserData(clientData);
return self->InsertTool(pos, id, bitmap, pushedBitmap, (bool)isToggle,
udata, shortHelpString, longHelpString);
return self->InsertTool(pos, id, label, bitmap, bmpDisabled, kind,
shortHelp, longHelp, udata);
}
static PyObject *_wrap_wxToolBarBase_InsertTool(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
@@ -1696,22 +1669,24 @@ static PyObject *_wrap_wxToolBarBase_InsertTool(PyObject *self, PyObject *args,
wxToolBarBase * _arg0;
size_t _arg1;
int _arg2;
wxBitmap * _arg3;
wxBitmap * _arg4 = (wxBitmap *) &wxNullBitmap;
int _arg5 = (int ) FALSE;
PyObject * _arg6 = (PyObject *) NULL;
wxString * _arg3;
wxBitmap * _arg4;
wxBitmap * _arg5 = (wxBitmap *) &wxNullBitmap;
wxItemKind _arg6 = (wxItemKind ) wxITEM_NORMAL;
wxString * _arg7 = (wxString *) &wxPyEmptyString;
wxString * _arg8 = (wxString *) &wxPyEmptyString;
PyObject * _arg9 = (PyObject *) NULL;
PyObject * _argo0 = 0;
PyObject * _argo3 = 0;
PyObject * _obj3 = 0;
PyObject * _argo4 = 0;
PyObject * _obj6 = 0;
PyObject * _argo5 = 0;
PyObject * _obj7 = 0;
PyObject * _obj8 = 0;
char *_kwnames[] = { "self","pos","id","bitmap","pushedBitmap","isToggle","clientData","shortHelpString","longHelpString", NULL };
PyObject * _obj9 = 0;
char *_kwnames[] = { "self","pos","id","label","bitmap","bmpDisabled","kind","shortHelp","longHelp","clientData", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OiiO|OiOOO:wxToolBarBase_InsertTool",_kwnames,&_argo0,&_arg1,&_arg2,&_argo3,&_argo4,&_arg5,&_obj6,&_obj7,&_obj8))
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OiiOO|OiOOO:wxToolBarBase_InsertTool",_kwnames,&_argo0,&_arg1,&_arg2,&_obj3,&_argo4,&_argo5,&_arg6,&_obj7,&_obj8,&_obj9))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
@@ -1720,13 +1695,11 @@ static PyObject *_wrap_wxToolBarBase_InsertTool(PyObject *self, PyObject *args,
return NULL;
}
}
if (_argo3) {
if (_argo3 == Py_None) { _arg3 = NULL; }
else if (SWIG_GetPtrObj(_argo3,(void **) &_arg3,"_wxBitmap_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 4 of wxToolBarBase_InsertTool. Expected _wxBitmap_p.");
{
_arg3 = wxString_in_helper(_obj3);
if (_arg3 == NULL)
return NULL;
}
}
}
if (_argo4) {
if (_argo4 == Py_None) { _arg4 = NULL; }
else if (SWIG_GetPtrObj(_argo4,(void **) &_arg4,"_wxBitmap_p")) {
@@ -1734,10 +1707,13 @@ static PyObject *_wrap_wxToolBarBase_InsertTool(PyObject *self, PyObject *args,
return NULL;
}
}
if (_obj6)
{
_arg6 = _obj6;
}
if (_argo5) {
if (_argo5 == Py_None) { _arg5 = NULL; }
else if (SWIG_GetPtrObj(_argo5,(void **) &_arg5,"_wxBitmap_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 6 of wxToolBarBase_InsertTool. Expected _wxBitmap_p.");
return NULL;
}
}
if (_obj7)
{
_arg7 = wxString_in_helper(_obj7);
@@ -1749,14 +1725,22 @@ static PyObject *_wrap_wxToolBarBase_InsertTool(PyObject *self, PyObject *args,
_arg8 = wxString_in_helper(_obj8);
if (_arg8 == NULL)
return NULL;
}
if (_obj9)
{
_arg9 = _obj9;
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (wxToolBarToolBase *)wxToolBarBase_InsertTool(_arg0,_arg1,_arg2,*_arg3,*_arg4,_arg5,_arg6,*_arg7,*_arg8);
_result = (wxToolBarToolBase *)wxToolBarBase_InsertTool(_arg0,_arg1,_arg2,*_arg3,*_arg4,*_arg5,_arg6,*_arg7,*_arg8,_arg9);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
}{ _resultobj = wxPyMake_wxObject(_result); }
{
if (_obj3)
delete _arg3;
}
{
if (_obj7)
delete _arg7;
@@ -1768,73 +1752,6 @@ static PyObject *_wrap_wxToolBarBase_InsertTool(PyObject *self, PyObject *args,
return _resultobj;
}
static wxToolBarToolBase * wxToolBarBase_InsertSimpleTool(wxToolBarBase *self,size_t pos,int id,const wxBitmap & bitmap,const wxString & shortHelpString,const wxString & longHelpString,int isToggle) {
return self->InsertTool(pos, id, bitmap, wxNullBitmap, isToggle, NULL,
shortHelpString, longHelpString);
}
static PyObject *_wrap_wxToolBarBase_InsertSimpleTool(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxToolBarToolBase * _result;
wxToolBarBase * _arg0;
size_t _arg1;
int _arg2;
wxBitmap * _arg3;
wxString * _arg4 = (wxString *) &wxPyEmptyString;
wxString * _arg5 = (wxString *) &wxPyEmptyString;
int _arg6 = (int ) FALSE;
PyObject * _argo0 = 0;
PyObject * _argo3 = 0;
PyObject * _obj4 = 0;
PyObject * _obj5 = 0;
char *_kwnames[] = { "self","pos","id","bitmap","shortHelpString","longHelpString","isToggle", NULL };
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OiiO|OOi:wxToolBarBase_InsertSimpleTool",_kwnames,&_argo0,&_arg1,&_arg2,&_argo3,&_obj4,&_obj5,&_arg6))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxToolBarBase_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBarBase_InsertSimpleTool. Expected _wxToolBarBase_p.");
return NULL;
}
}
if (_argo3) {
if (_argo3 == Py_None) { _arg3 = NULL; }
else if (SWIG_GetPtrObj(_argo3,(void **) &_arg3,"_wxBitmap_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 4 of wxToolBarBase_InsertSimpleTool. Expected _wxBitmap_p.");
return NULL;
}
}
if (_obj4)
{
_arg4 = wxString_in_helper(_obj4);
if (_arg4 == NULL)
return NULL;
}
if (_obj5)
{
_arg5 = wxString_in_helper(_obj5);
if (_arg5 == NULL)
return NULL;
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (wxToolBarToolBase *)wxToolBarBase_InsertSimpleTool(_arg0,_arg1,_arg2,*_arg3,*_arg4,*_arg5,_arg6);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
}{ _resultobj = wxPyMake_wxObject(_result); }
{
if (_obj4)
delete _arg4;
}
{
if (_obj5)
delete _arg5;
}
return _resultobj;
}
#define wxToolBarBase_AddControl(_swigobj,_swigarg0) (_swigobj->AddControl(_swigarg0))
static PyObject *_wrap_wxToolBarBase_AddControl(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
@@ -3515,10 +3432,8 @@ static PyMethodDef stattoolcMethods[] = {
{ "wxToolBarBase_AddSeparator", (PyCFunction) _wrap_wxToolBarBase_AddSeparator, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarBase_InsertControl", (PyCFunction) _wrap_wxToolBarBase_InsertControl, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarBase_AddControl", (PyCFunction) _wrap_wxToolBarBase_AddControl, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarBase_InsertSimpleTool", (PyCFunction) _wrap_wxToolBarBase_InsertSimpleTool, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarBase_InsertTool", (PyCFunction) _wrap_wxToolBarBase_InsertTool, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarBase_AddSimpleTool", (PyCFunction) _wrap_wxToolBarBase_AddSimpleTool, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarBase_AddTool", (PyCFunction) _wrap_wxToolBarBase_AddTool, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarBase_DoAddTool", (PyCFunction) _wrap_wxToolBarBase_DoAddTool, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarToolBase_SetClientData", (PyCFunction) _wrap_wxToolBarToolBase_SetClientData, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarToolBase_GetClientData", (PyCFunction) _wrap_wxToolBarToolBase_GetClientData, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarToolBase_Attach", (PyCFunction) _wrap_wxToolBarToolBase_Attach, METH_VARARGS | METH_KEYWORDS },
@@ -3540,6 +3455,7 @@ static PyMethodDef stattoolcMethods[] = {
{ "wxToolBarToolBase_CanBeToggled", (PyCFunction) _wrap_wxToolBarToolBase_CanBeToggled, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarToolBase_IsToggled", (PyCFunction) _wrap_wxToolBarToolBase_IsToggled, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarToolBase_IsEnabled", (PyCFunction) _wrap_wxToolBarToolBase_IsEnabled, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarToolBase_GetKind", (PyCFunction) _wrap_wxToolBarToolBase_GetKind, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarToolBase_GetStyle", (PyCFunction) _wrap_wxToolBarToolBase_GetStyle, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarToolBase_IsSeparator", (PyCFunction) _wrap_wxToolBarToolBase_IsSeparator, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarToolBase_IsControl", (PyCFunction) _wrap_wxToolBarToolBase_IsControl, METH_VARARGS | METH_KEYWORDS },

View File

@@ -7,12 +7,15 @@ from windows import *
from gdi import *
from fonts import *
from clip_dnd import *
from controls import *
from events import *
import wx
wxITEM_NORMAL = 0 # predeclare this since wx isn't fully imported yet
class wxStatusBarPtr(wxWindowPtr):
def __init__(self,this):
self.this = this
@@ -93,6 +96,9 @@ class wxToolBarToolBasePtr(wxObjectPtr):
def GetStyle(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBarToolBase_GetStyle,(self,) + _args, _kwargs)
return val
def GetKind(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBarToolBase_GetKind,(self,) + _args, _kwargs)
return val
def IsEnabled(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBarToolBase_IsEnabled,(self,) + _args, _kwargs)
return val
@@ -178,18 +184,12 @@ class wxToolBarBasePtr(wxControlPtr):
def __init__(self,this):
self.this = this
self.thisown = 0
def AddTool(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBarBase_AddTool,(self,) + _args, _kwargs)
return val
def AddSimpleTool(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBarBase_AddSimpleTool,(self,) + _args, _kwargs)
def DoAddTool(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBarBase_DoAddTool,(self,) + _args, _kwargs)
return val
def InsertTool(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBarBase_InsertTool,(self,) + _args, _kwargs)
return val
def InsertSimpleTool(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBarBase_InsertSimpleTool,(self,) + _args, _kwargs)
return val
def AddControl(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBarBase_AddControl,(self,) + _args, _kwargs)
return val
@@ -307,6 +307,130 @@ class wxToolBarBasePtr(wxControlPtr):
return val
def __repr__(self):
return "<C wxToolBarBase instance at %s>" % (self.this,)
# These match the original Add methods for this class, kept for
# backwards compatibility with versions < 2.3.3.
def AddTool(self, id, bitmap,
pushedBitmap = wxNullBitmap,
isToggle = 0,
clientData = None,
shortHelpString = '',
longHelpString = '') :
'''Old style method to add a tool to the toolbar.'''
kind = wx.wxITEM_NORMAL
if isToggle: kind = wx.wxITEM_CHECK
return self.DoAddTool(id, '', bitmap, pushedBitmap, kind,
shortHelpString, longHelpString, clientData)
def AddSimpleTool(self, id, bitmap,
shortHelpString = '',
longHelpString = '',
isToggle = 0):
'''Old style method to add a tool to the toolbar.'''
kind = wx.wxITEM_NORMAL
if isToggle: kind = wx.wxITEM_CHECK
return self.DoAddTool(id, '', bitmap, wxNullBitmap, kind,
shortHelpString, longHelpString, None)
def InsertTool(self, pos, id, bitmap,
pushedBitmap = wxNullBitmap,
isToggle = 0,
clientData = None,
shortHelpString = '',
longHelpString = ''):
'''Old style method to insert a tool in the toolbar.'''
kind = wx.wxITEM_NORMAL
if isToggle: kind = wx.wxITEM_CHECK
return self.DoInsertTool(pos, id, '', bitmap, pushedBitmap, kind,
shortHelpString, longHelpString, clientData)
def InsertSimpleTool(self, pos, id, bitmap,
shortHelpString = '',
longHelpString = '',
isToggle = 0):
'''Old style method to insert a tool in the toolbar.'''
kind = wx.wxITEM_NORMAL
if isToggle: kind = wx.wxITEM_CHECK
return self.DoInsertTool(pos, id, '', bitmap, wxNullBitmap, kind,
shortHelpString, longHelpString, None)
# The following are the new toolbar Add methods starting with
# 2.3.3. They are renamed to have 'Label' in the name so as to be
# able to keep backwards compatibility with using the above
# methods. Eventually these should migrate to be the methods used
# primarily and loose the 'Label' in the name...
def AddLabelTool(self, id, label, bitmap,
bmpDisabled = wxNullBitmap,
kind = wxITEM_NORMAL,
shortHelp = '', longHelp = '',
clientData = None):
'''
The full AddTool() function.
If bmpDisabled is wxNullBitmap, a shadowed version of the normal bitmap
is created and used as the disabled image.
'''
return self.DoAddTool(id, label, bitmap, bmpDisabled, kind,
shortHelp, longHelp, clientData)
def InsertLabelTool(self, pos, id, label, bitmap,
bmpDisabled = wxNullBitmap,
kind = wxITEM_NORMAL,
shortHelp = '', longHelp = '',
clientData = None):
'''
Insert the new tool at the given position, if pos == GetToolsCount(), it
is equivalent to AddTool()
'''
return self.DoInsertTool(pos, id, label, bitmap, bmpDisabled, kind,
shortHelp, longHelp, clientData)
def AddCheckLabelTool(self, id, label, bitmap,
bmpDisabled = wxNullBitmap,
shortHelp = '', longHelp = '',
clientData = None):
'''Add a check tool, i.e. a tool which can be toggled'''
return self.DoAddTool(id, label, bitmap, bmpDisabled, wx.wxITEM_CHECK,
shortHelp, longHelp, clientData)
def AddRadioLabelTool(self, id, label, bitmap,
bmpDisabled = wxNullBitmap,
shortHelp = '', longHelp = '',
clientData = None):
'''
Add a radio tool, i.e. a tool which can be toggled and releases any
other toggled radio tools in the same group when it happens
'''
return self.DoAddTool(id, label, bitmap, bmpDisabled, wx.wxITEM_RADIO,
shortHelp, longHelp, clientData)
# For consistency with the backwards compatible methods above, here are
# some non-'Label' versions of the Check and Radio methods
def AddCheckTool(self, id, bitmap,
bmpDisabled = wxNullBitmap,
shortHelp = '', longHelp = '',
clientData = None):
'''Add a check tool, i.e. a tool which can be toggled'''
return self.DoAddTool(id, '', bitmap, bmpDisabled, wx.wxITEM_CHECK,
shortHelp, longHelp, clientData)
def AddRadioTool(self, id, bitmap,
bmpDisabled = wxNullBitmap,
shortHelp = '', longHelp = '',
clientData = None):
'''
Add a radio tool, i.e. a tool which can be toggled and releases any
other toggled radio tools in the same group when it happens
'''
return self.DoAddTool(id, '', bitmap, bmpDisabled, wx.wxITEM_RADIO,
shortHelp, longHelp, clientData)
class wxToolBarBase(wxToolBarBasePtr):
def __init__(self,this):
self.this = this

View File

@@ -5086,9 +5086,10 @@ static PyObject *_wrap_wxDateTime___sub__DS(PyObject *self, PyObject *args, PyOb
return _resultobj;
}
static int wxDateTime___cmp__(wxDateTime *self,const wxDateTime & other) {
if (*self < other) return -1;
if (*self == other) return 0;
static int wxDateTime___cmp__(wxDateTime *self,const wxDateTime * other) {
if (! other) return -1;
if (*self < *other) return -1;
if (*self == *other) return 0;
return 1;
}
static PyObject *_wrap_wxDateTime___cmp__(PyObject *self, PyObject *args, PyObject *kwargs) {
@@ -5119,7 +5120,7 @@ static PyObject *_wrap_wxDateTime___cmp__(PyObject *self, PyObject *args, PyObje
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (int )wxDateTime___cmp__(_arg0,*_arg1);
_result = (int )wxDateTime___cmp__(_arg0,_arg1);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
@@ -6220,9 +6221,10 @@ static PyObject *_wrap_wxTimeSpan___neg__(PyObject *self, PyObject *args, PyObje
return _resultobj;
}
static int wxTimeSpan___cmp__(wxTimeSpan *self,const wxTimeSpan & other) {
if (*self < other) return -1;
if (*self == other) return 0;
static int wxTimeSpan___cmp__(wxTimeSpan *self,const wxTimeSpan * other) {
if (! other) return -1;
if (*self < *other) return -1;
if (*self == *other) return 0;
return 1;
}
static PyObject *_wrap_wxTimeSpan___cmp__(PyObject *self, PyObject *args, PyObject *kwargs) {
@@ -6253,7 +6255,7 @@ static PyObject *_wrap_wxTimeSpan___cmp__(PyObject *self, PyObject *args, PyObje
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = (int )wxTimeSpan___cmp__(_arg0,*_arg1);
_result = (int )wxTimeSpan___cmp__(_arg0,_arg1);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;

View File

@@ -5,6 +5,8 @@ from misc import *
from gdi import *
from fonts import *
from clip_dnd import *
import wx

View File

@@ -5,6 +5,8 @@ from misc import *
from gdi import *
from fonts import *
from windows import *
from clip_dnd import *

View File

@@ -5,6 +5,8 @@ from misc import *
from gdi import *
from fonts import *
from windows import *
from clip_dnd import *

View File

@@ -624,6 +624,7 @@ extern "C" SWIGEXPORT(void) initclip_dndc();
extern "C" SWIGEXPORT(void) initstreamsc();
extern "C" SWIGEXPORT(void) initfilesysc();
extern "C" SWIGEXPORT(void) initutilsc();
extern "C" SWIGEXPORT(void) initfontsc();
@@ -1650,39 +1651,7 @@ static PyObject *_wrap_wxPyApp_SetUseBestVisual(PyObject *self, PyObject *args,
return _resultobj;
}
#define wxPyApp_GetStdIcon(_swigobj,_swigarg0) (_swigobj->GetStdIcon(_swigarg0))
static PyObject *_wrap_wxPyApp_GetStdIcon(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxIcon * _result;
wxPyApp * _arg0;
int _arg1;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self","which", NULL };
char _ptemp[128];
self = self;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxPyApp_GetStdIcon",_kwnames,&_argo0,&_arg1))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyApp_p")) {
PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxPyApp_GetStdIcon. Expected _wxPyApp_p.");
return NULL;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
_result = new wxIcon (wxPyApp_GetStdIcon(_arg0,_arg1));
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) return NULL;
} SWIG_MakePtr(_ptemp, (void *) _result,"_wxIcon_p");
_resultobj = Py_BuildValue("s",_ptemp);
return _resultobj;
}
static PyMethodDef wxcMethods[] = {
{ "wxPyApp_GetStdIcon", (PyCFunction) _wrap_wxPyApp_GetStdIcon, METH_VARARGS | METH_KEYWORDS },
{ "wxPyApp_SetUseBestVisual", (PyCFunction) _wrap_wxPyApp_SetUseBestVisual, METH_VARARGS | METH_KEYWORDS },
{ "wxPyApp_SetVendorName", (PyCFunction) _wrap_wxPyApp_SetVendorName, METH_VARARGS | METH_KEYWORDS },
{ "wxPyApp_SetTopWindow", (PyCFunction) _wrap_wxPyApp_SetTopWindow, METH_VARARGS | METH_KEYWORDS },
@@ -1894,11 +1863,13 @@ SWIGEXPORT(void) initwxc() {
PyDict_SetItemString(d,"wxCLIP_SIBLINGS", PyInt_FromLong((long) wxCLIP_SIBLINGS));
PyDict_SetItemString(d,"wxRETAINED", PyInt_FromLong((long) wxRETAINED));
PyDict_SetItemString(d,"wxBACKINGSTORE", PyInt_FromLong((long) wxBACKINGSTORE));
PyDict_SetItemString(d,"wxTB_3DBUTTONS", PyInt_FromLong((long) wxTB_3DBUTTONS));
PyDict_SetItemString(d,"wxTB_HORIZONTAL", PyInt_FromLong((long) wxTB_HORIZONTAL));
PyDict_SetItemString(d,"wxTB_VERTICAL", PyInt_FromLong((long) wxTB_VERTICAL));
PyDict_SetItemString(d,"wxTB_3DBUTTONS", PyInt_FromLong((long) wxTB_3DBUTTONS));
PyDict_SetItemString(d,"wxTB_FLAT", PyInt_FromLong((long) wxTB_FLAT));
PyDict_SetItemString(d,"wxTB_DOCKABLE", PyInt_FromLong((long) wxTB_DOCKABLE));
PyDict_SetItemString(d,"wxTB_NOICONS", PyInt_FromLong((long) wxTB_NOICONS));
PyDict_SetItemString(d,"wxTB_TEXT", PyInt_FromLong((long) wxTB_TEXT));
PyDict_SetItemString(d,"wxCOLOURED", PyInt_FromLong((long) wxCOLOURED));
PyDict_SetItemString(d,"wxFIXED_LENGTH", PyInt_FromLong((long) wxFIXED_LENGTH));
PyDict_SetItemString(d,"wxALIGN_LEFT", PyInt_FromLong((long) wxALIGN_LEFT));
@@ -2611,6 +2582,7 @@ SWIGEXPORT(void) initwxc() {
initstreamsc();
initfilesysc();
initutilsc();
initfontsc();
PyDict_SetItemString(d,"wxMAJOR_VERSION", PyInt_FromLong((long)wxMAJOR_VERSION ));

View File

@@ -9,6 +9,8 @@ from windows import *
from gdi import *
from fonts import *
from clip_dnd import *
from events import *
@@ -107,10 +109,6 @@ class wxPyAppPtr(wxEvtHandlerPtr):
def SetUseBestVisual(self, *_args, **_kwargs):
val = apply(wxc.wxPyApp_SetUseBestVisual,(self,) + _args, _kwargs)
return val
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 at %s>" % (self.this,)
class wxPyApp(wxPyAppPtr):
@@ -210,11 +208,13 @@ wxCLIP_CHILDREN = wxc.wxCLIP_CHILDREN
wxCLIP_SIBLINGS = wxc.wxCLIP_SIBLINGS
wxRETAINED = wxc.wxRETAINED
wxBACKINGSTORE = wxc.wxBACKINGSTORE
wxTB_3DBUTTONS = wxc.wxTB_3DBUTTONS
wxTB_HORIZONTAL = wxc.wxTB_HORIZONTAL
wxTB_VERTICAL = wxc.wxTB_VERTICAL
wxTB_3DBUTTONS = wxc.wxTB_3DBUTTONS
wxTB_FLAT = wxc.wxTB_FLAT
wxTB_DOCKABLE = wxc.wxTB_DOCKABLE
wxTB_NOICONS = wxc.wxTB_NOICONS
wxTB_TEXT = wxc.wxTB_TEXT
wxCOLOURED = wxc.wxCOLOURED
wxFIXED_LENGTH = wxc.wxFIXED_LENGTH
wxALIGN_LEFT = wxc.wxALIGN_LEFT