reSWIGged
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@29008 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
41d1d7e34b
commit
0f63ec68f6
@ -241,18 +241,6 @@ def GetCurrentId(*args, **kwargs):
|
||||
"""GetCurrentId() -> long"""
|
||||
return _misc_.GetCurrentId(*args, **kwargs)
|
||||
|
||||
def IsStockID(*args, **kwargs):
|
||||
"""IsStockID(int id) -> bool"""
|
||||
return _misc_.IsStockID(*args, **kwargs)
|
||||
|
||||
def IsStockLabel(*args, **kwargs):
|
||||
"""IsStockLabel(int id, String label) -> bool"""
|
||||
return _misc_.IsStockLabel(*args, **kwargs)
|
||||
|
||||
def GetStockLabel(*args, **kwargs):
|
||||
"""GetStockLabel(int id) -> String"""
|
||||
return _misc_.GetStockLabel(*args, **kwargs)
|
||||
|
||||
def Bell(*args, **kwargs):
|
||||
"""Bell()"""
|
||||
return _misc_.Bell(*args, **kwargs)
|
||||
|
@ -2177,110 +2177,6 @@ static PyObject *_wrap_GetCurrentId(PyObject *self, PyObject *args, PyObject *kw
|
||||
}
|
||||
|
||||
|
||||
static PyObject *_wrap_IsStockID(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
int arg1 ;
|
||||
bool result;
|
||||
PyObject * obj0 = 0 ;
|
||||
char *kwnames[] = {
|
||||
(char *) "id", NULL
|
||||
};
|
||||
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:IsStockID",kwnames,&obj0)) goto fail;
|
||||
arg1 = (int) SWIG_AsInt(obj0);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
result = (bool)wxIsStockID(arg1);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
}
|
||||
{
|
||||
resultobj = result ? Py_True : Py_False; Py_INCREF(resultobj);
|
||||
}
|
||||
return resultobj;
|
||||
fail:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
static PyObject *_wrap_IsStockLabel(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
int arg1 ;
|
||||
wxString *arg2 = 0 ;
|
||||
bool result;
|
||||
bool temp2 = False ;
|
||||
PyObject * obj0 = 0 ;
|
||||
PyObject * obj1 = 0 ;
|
||||
char *kwnames[] = {
|
||||
(char *) "id",(char *) "label", NULL
|
||||
};
|
||||
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:IsStockLabel",kwnames,&obj0,&obj1)) goto fail;
|
||||
arg1 = (int) SWIG_AsInt(obj0);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
{
|
||||
arg2 = wxString_in_helper(obj1);
|
||||
if (arg2 == NULL) SWIG_fail;
|
||||
temp2 = True;
|
||||
}
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
result = (bool)wxIsStockLabel(arg1,(wxString const &)*arg2);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
}
|
||||
{
|
||||
resultobj = result ? Py_True : Py_False; Py_INCREF(resultobj);
|
||||
}
|
||||
{
|
||||
if (temp2)
|
||||
delete arg2;
|
||||
}
|
||||
return resultobj;
|
||||
fail:
|
||||
{
|
||||
if (temp2)
|
||||
delete arg2;
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
static PyObject *_wrap_GetStockLabel(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
int arg1 ;
|
||||
wxString result;
|
||||
PyObject * obj0 = 0 ;
|
||||
char *kwnames[] = {
|
||||
(char *) "id", NULL
|
||||
};
|
||||
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:GetStockLabel",kwnames,&obj0)) goto fail;
|
||||
arg1 = (int) SWIG_AsInt(obj0);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
result = wxGetStockLabel(arg1);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
}
|
||||
{
|
||||
#if wxUSE_UNICODE
|
||||
resultobj = PyUnicode_FromWideChar((&result)->c_str(), (&result)->Len());
|
||||
#else
|
||||
resultobj = PyString_FromStringAndSize((&result)->c_str(), (&result)->Len());
|
||||
#endif
|
||||
}
|
||||
return resultobj;
|
||||
fail:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
static PyObject *_wrap_Bell(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
char *kwnames[] = {
|
||||
@ -28364,9 +28260,6 @@ static PyMethodDef SwigMethods[] = {
|
||||
{ (char *)"NewId", (PyCFunction) _wrap_NewId, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"RegisterId", (PyCFunction) _wrap_RegisterId, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"GetCurrentId", (PyCFunction) _wrap_GetCurrentId, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"IsStockID", (PyCFunction) _wrap_IsStockID, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"IsStockLabel", (PyCFunction) _wrap_IsStockLabel, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"GetStockLabel", (PyCFunction) _wrap_GetStockLabel, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Bell", (PyCFunction) _wrap_Bell, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"EndBusyCursor", (PyCFunction) _wrap_EndBusyCursor, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"GetElapsedTime", (PyCFunction) _wrap_GetElapsedTime, METH_VARARGS | METH_KEYWORDS },
|
||||
|
@ -28,7 +28,11 @@ class Button(_core.Control):
|
||||
long style=0, Validator validator=DefaultValidator,
|
||||
String name=ButtonNameStr) -> Button
|
||||
|
||||
Create and show a button.
|
||||
Create and show a button. The preferred way to create standard
|
||||
buttons is to use a standard ID and an empty label. In this case
|
||||
wxWigets will automatically use a stock label that coresponds to the
|
||||
ID given. In additon, the button will be decorated with stock icons
|
||||
under GTK+ 2.
|
||||
"""
|
||||
newobj = _controls_.new_Button(*args, **kwargs)
|
||||
self.this = newobj.this
|
||||
|
@ -206,6 +206,29 @@ ID_NOTOALL = _core_.ID_NOTOALL
|
||||
ID_ABORT = _core_.ID_ABORT
|
||||
ID_RETRY = _core_.ID_RETRY
|
||||
ID_IGNORE = _core_.ID_IGNORE
|
||||
ID_ADD = _core_.ID_ADD
|
||||
ID_REMOVE = _core_.ID_REMOVE
|
||||
ID_UP = _core_.ID_UP
|
||||
ID_DOWN = _core_.ID_DOWN
|
||||
ID_HOME = _core_.ID_HOME
|
||||
ID_REFRESH = _core_.ID_REFRESH
|
||||
ID_STOP = _core_.ID_STOP
|
||||
ID_INDEX = _core_.ID_INDEX
|
||||
ID_BOLD = _core_.ID_BOLD
|
||||
ID_ITALIC = _core_.ID_ITALIC
|
||||
ID_JUSTIFY_CENTER = _core_.ID_JUSTIFY_CENTER
|
||||
ID_JUSTIFY_FILL = _core_.ID_JUSTIFY_FILL
|
||||
ID_JUSTIFY_RIGHT = _core_.ID_JUSTIFY_RIGHT
|
||||
ID_JUSTIFY_LEFT = _core_.ID_JUSTIFY_LEFT
|
||||
ID_UNDERLINE = _core_.ID_UNDERLINE
|
||||
ID_INDENT = _core_.ID_INDENT
|
||||
ID_UNINDENT = _core_.ID_UNINDENT
|
||||
ID_ZOOM_100 = _core_.ID_ZOOM_100
|
||||
ID_ZOOM_FIT = _core_.ID_ZOOM_FIT
|
||||
ID_ZOOM_IN = _core_.ID_ZOOM_IN
|
||||
ID_ZOOM_OUT = _core_.ID_ZOOM_OUT
|
||||
ID_UNDELETE = _core_.ID_UNDELETE
|
||||
ID_REVERT_TO_SAVED = _core_.ID_REVERT_TO_SAVED
|
||||
ID_HIGHEST = _core_.ID_HIGHEST
|
||||
OPEN = _core_.OPEN
|
||||
SAVE = _core_.SAVE
|
||||
@ -292,6 +315,9 @@ BORDER_RAISED = _core_.BORDER_RAISED
|
||||
BORDER_SUNKEN = _core_.BORDER_SUNKEN
|
||||
BORDER_DOUBLE = _core_.BORDER_DOUBLE
|
||||
BORDER_MASK = _core_.BORDER_MASK
|
||||
BG_STYLE_SYSTEM = _core_.BG_STYLE_SYSTEM
|
||||
BG_STYLE_COLOUR = _core_.BG_STYLE_COLOUR
|
||||
BG_STYLE_CUSTOM = _core_.BG_STYLE_CUSTOM
|
||||
DEFAULT = _core_.DEFAULT
|
||||
DECORATIVE = _core_.DECORATIVE
|
||||
ROMAN = _core_.ROMAN
|
||||
@ -7003,6 +7029,39 @@ class Window(EvtHandler):
|
||||
"""
|
||||
return _core_.Window_GetForegroundColour(*args, **kwargs)
|
||||
|
||||
def SetBackgroundStyle(*args, **kwargs):
|
||||
"""
|
||||
SetBackgroundStyle(self, int style) -> bool
|
||||
|
||||
Returns the background style of the window. The background style
|
||||
indicates how the background of the window is drawn.
|
||||
|
||||
====================== ========================================
|
||||
wx.BG_STYLE_SYSTEM The background colour or pattern should
|
||||
be determined by the system
|
||||
wx.BG_STYLE_COLOUR The background should be a solid colour
|
||||
wx.BG_STYLE_CUSTOM The background will be implemented by the
|
||||
application.
|
||||
====================== ========================================
|
||||
|
||||
On GTK+, use of wx.BG_STYLE_CUSTOM allows the flicker-free drawing of
|
||||
a custom background, such as a tiled bitmap. Currently the style has
|
||||
no effect on other platforms.
|
||||
|
||||
:see: `GetBackgroundStyle`, `SetBackgroundColour`
|
||||
"""
|
||||
return _core_.Window_SetBackgroundStyle(*args, **kwargs)
|
||||
|
||||
def GetBackgroundStyle(*args, **kwargs):
|
||||
"""
|
||||
GetBackgroundStyle(self) -> int
|
||||
|
||||
Returns the background style of the window.
|
||||
|
||||
:see: `SetBackgroundStyle`
|
||||
"""
|
||||
return _core_.Window_GetBackgroundStyle(*args, **kwargs)
|
||||
|
||||
def SetCursor(*args, **kwargs):
|
||||
"""
|
||||
SetCursor(self, Cursor cursor) -> bool
|
||||
@ -10512,16 +10571,16 @@ __wxPyPtrTypeMap['wxStatusBar95'] = 'wxStatusBar'
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
# Load version numbers from __version__... Ensure that major and minor
|
||||
# versions are the same for both wxPython and wxWindows.
|
||||
# versions are the same for both wxPython and wxWidgets.
|
||||
|
||||
from __version__ import *
|
||||
__version__ = VERSION_STRING
|
||||
|
||||
assert MAJOR_VERSION == _core_.MAJOR_VERSION, "wxPython/wxWindows version mismatch"
|
||||
assert MINOR_VERSION == _core_.MINOR_VERSION, "wxPython/wxWindows version mismatch"
|
||||
assert MAJOR_VERSION == _core_.MAJOR_VERSION, "wxPython/wxWidgets version mismatch"
|
||||
assert MINOR_VERSION == _core_.MINOR_VERSION, "wxPython/wxWidgets version mismatch"
|
||||
if RELEASE_VERSION != _core_.RELEASE_VERSION:
|
||||
import warnings
|
||||
warnings.warn("wxPython/wxWindows release number mismatch")
|
||||
warnings.warn("wxPython/wxWidgets release number mismatch")
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
|
||||
|
@ -26332,6 +26332,64 @@ static PyObject *_wrap_Window_GetForegroundColour(PyObject *self, PyObject *args
|
||||
}
|
||||
|
||||
|
||||
static PyObject *_wrap_Window_SetBackgroundStyle(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
wxWindow *arg1 = (wxWindow *) 0 ;
|
||||
int arg2 ;
|
||||
bool result;
|
||||
PyObject * obj0 = 0 ;
|
||||
PyObject * obj1 = 0 ;
|
||||
char *kwnames[] = {
|
||||
(char *) "self",(char *) "style", NULL
|
||||
};
|
||||
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:Window_SetBackgroundStyle",kwnames,&obj0,&obj1)) goto fail;
|
||||
if ((SWIG_ConvertPtr(obj0,(void **)(&arg1),SWIGTYPE_p_wxWindow,
|
||||
SWIG_POINTER_EXCEPTION | 0)) == -1) SWIG_fail;
|
||||
arg2 = (wxBackgroundStyle) SWIG_AsInt(obj1);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
result = (bool)(arg1)->SetBackgroundStyle((wxBackgroundStyle )arg2);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
}
|
||||
{
|
||||
resultobj = result ? Py_True : Py_False; Py_INCREF(resultobj);
|
||||
}
|
||||
return resultobj;
|
||||
fail:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
static PyObject *_wrap_Window_GetBackgroundStyle(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
wxWindow *arg1 = (wxWindow *) 0 ;
|
||||
int result;
|
||||
PyObject * obj0 = 0 ;
|
||||
char *kwnames[] = {
|
||||
(char *) "self", NULL
|
||||
};
|
||||
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:Window_GetBackgroundStyle",kwnames,&obj0)) goto fail;
|
||||
if ((SWIG_ConvertPtr(obj0,(void **)(&arg1),SWIGTYPE_p_wxWindow,
|
||||
SWIG_POINTER_EXCEPTION | 0)) == -1) SWIG_fail;
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
result = (int)((wxWindow const *)arg1)->GetBackgroundStyle();
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
}
|
||||
resultobj = SWIG_FromInt((int)result);
|
||||
return resultobj;
|
||||
fail:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
static PyObject *_wrap_Window_SetCursor(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
wxWindow *arg1 = (wxWindow *) 0 ;
|
||||
@ -40873,6 +40931,8 @@ static PyMethodDef SwigMethods[] = {
|
||||
{ (char *)"Window_SetOwnForegroundColour", (PyCFunction) _wrap_Window_SetOwnForegroundColour, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_GetBackgroundColour", (PyCFunction) _wrap_Window_GetBackgroundColour, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_GetForegroundColour", (PyCFunction) _wrap_Window_GetForegroundColour, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_SetBackgroundStyle", (PyCFunction) _wrap_Window_SetBackgroundStyle, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_GetBackgroundStyle", (PyCFunction) _wrap_Window_GetBackgroundStyle, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_SetCursor", (PyCFunction) _wrap_Window_SetCursor, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_GetCursor", (PyCFunction) _wrap_Window_GetCursor, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_SetFont", (PyCFunction) _wrap_Window_SetFont, METH_VARARGS | METH_KEYWORDS },
|
||||
@ -42211,6 +42271,29 @@ SWIGEXPORT(void) SWIG_init(void) {
|
||||
PyDict_SetItemString(d,"ID_ABORT", SWIG_FromInt((int)wxID_ABORT));
|
||||
PyDict_SetItemString(d,"ID_RETRY", SWIG_FromInt((int)wxID_RETRY));
|
||||
PyDict_SetItemString(d,"ID_IGNORE", SWIG_FromInt((int)wxID_IGNORE));
|
||||
PyDict_SetItemString(d,"ID_ADD", SWIG_FromInt((int)wxID_ADD));
|
||||
PyDict_SetItemString(d,"ID_REMOVE", SWIG_FromInt((int)wxID_REMOVE));
|
||||
PyDict_SetItemString(d,"ID_UP", SWIG_FromInt((int)wxID_UP));
|
||||
PyDict_SetItemString(d,"ID_DOWN", SWIG_FromInt((int)wxID_DOWN));
|
||||
PyDict_SetItemString(d,"ID_HOME", SWIG_FromInt((int)wxID_HOME));
|
||||
PyDict_SetItemString(d,"ID_REFRESH", SWIG_FromInt((int)wxID_REFRESH));
|
||||
PyDict_SetItemString(d,"ID_STOP", SWIG_FromInt((int)wxID_STOP));
|
||||
PyDict_SetItemString(d,"ID_INDEX", SWIG_FromInt((int)wxID_INDEX));
|
||||
PyDict_SetItemString(d,"ID_BOLD", SWIG_FromInt((int)wxID_BOLD));
|
||||
PyDict_SetItemString(d,"ID_ITALIC", SWIG_FromInt((int)wxID_ITALIC));
|
||||
PyDict_SetItemString(d,"ID_JUSTIFY_CENTER", SWIG_FromInt((int)wxID_JUSTIFY_CENTER));
|
||||
PyDict_SetItemString(d,"ID_JUSTIFY_FILL", SWIG_FromInt((int)wxID_JUSTIFY_FILL));
|
||||
PyDict_SetItemString(d,"ID_JUSTIFY_RIGHT", SWIG_FromInt((int)wxID_JUSTIFY_RIGHT));
|
||||
PyDict_SetItemString(d,"ID_JUSTIFY_LEFT", SWIG_FromInt((int)wxID_JUSTIFY_LEFT));
|
||||
PyDict_SetItemString(d,"ID_UNDERLINE", SWIG_FromInt((int)wxID_UNDERLINE));
|
||||
PyDict_SetItemString(d,"ID_INDENT", SWIG_FromInt((int)wxID_INDENT));
|
||||
PyDict_SetItemString(d,"ID_UNINDENT", SWIG_FromInt((int)wxID_UNINDENT));
|
||||
PyDict_SetItemString(d,"ID_ZOOM_100", SWIG_FromInt((int)wxID_ZOOM_100));
|
||||
PyDict_SetItemString(d,"ID_ZOOM_FIT", SWIG_FromInt((int)wxID_ZOOM_FIT));
|
||||
PyDict_SetItemString(d,"ID_ZOOM_IN", SWIG_FromInt((int)wxID_ZOOM_IN));
|
||||
PyDict_SetItemString(d,"ID_ZOOM_OUT", SWIG_FromInt((int)wxID_ZOOM_OUT));
|
||||
PyDict_SetItemString(d,"ID_UNDELETE", SWIG_FromInt((int)wxID_UNDELETE));
|
||||
PyDict_SetItemString(d,"ID_REVERT_TO_SAVED", SWIG_FromInt((int)wxID_REVERT_TO_SAVED));
|
||||
PyDict_SetItemString(d,"ID_HIGHEST", SWIG_FromInt((int)wxID_HIGHEST));
|
||||
PyDict_SetItemString(d,"OPEN", SWIG_FromInt((int)wxOPEN));
|
||||
PyDict_SetItemString(d,"SAVE", SWIG_FromInt((int)wxSAVE));
|
||||
@ -42297,6 +42380,9 @@ SWIGEXPORT(void) SWIG_init(void) {
|
||||
PyDict_SetItemString(d,"BORDER_SUNKEN", SWIG_FromInt((int)wxBORDER_SUNKEN));
|
||||
PyDict_SetItemString(d,"BORDER_DOUBLE", SWIG_FromInt((int)wxBORDER_DOUBLE));
|
||||
PyDict_SetItemString(d,"BORDER_MASK", SWIG_FromInt((int)wxBORDER_MASK));
|
||||
PyDict_SetItemString(d,"BG_STYLE_SYSTEM", SWIG_FromInt((int)wxBG_STYLE_SYSTEM));
|
||||
PyDict_SetItemString(d,"BG_STYLE_COLOUR", SWIG_FromInt((int)wxBG_STYLE_COLOUR));
|
||||
PyDict_SetItemString(d,"BG_STYLE_CUSTOM", SWIG_FromInt((int)wxBG_STYLE_CUSTOM));
|
||||
PyDict_SetItemString(d,"DEFAULT", SWIG_FromInt((int)wxDEFAULT));
|
||||
PyDict_SetItemString(d,"DECORATIVE", SWIG_FromInt((int)wxDECORATIVE));
|
||||
PyDict_SetItemString(d,"ROMAN", SWIG_FromInt((int)wxROMAN));
|
||||
|
@ -422,6 +422,9 @@ SWIG_CheckInt(PyObject* obj)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#include <wx/stockitem.h>
|
||||
|
||||
static const wxString wxPyFileSelectorPromptStr(wxFileSelectorPromptStr);
|
||||
static const wxString wxPyFileSelectorDefaultWildcardStr(wxFileSelectorDefaultWildcardStr);
|
||||
static const wxString wxPyDirSelectorPromptStr(wxDirSelectorPromptStr);
|
||||
|
@ -28,7 +28,11 @@ class Button(_core.Control):
|
||||
long style=0, Validator validator=DefaultValidator,
|
||||
String name=ButtonNameStr) -> Button
|
||||
|
||||
Create and show a button.
|
||||
Create and show a button. The preferred way to create standard
|
||||
buttons is to use a standard ID and an empty label. In this case
|
||||
wxWigets will automatically use a stock label that coresponds to the
|
||||
ID given. In additon, the button will be decorated with stock icons
|
||||
under GTK+ 2.
|
||||
"""
|
||||
newobj = _controls_.new_Button(*args, **kwargs)
|
||||
self.this = newobj.this
|
||||
|
@ -206,6 +206,29 @@ ID_NOTOALL = _core_.ID_NOTOALL
|
||||
ID_ABORT = _core_.ID_ABORT
|
||||
ID_RETRY = _core_.ID_RETRY
|
||||
ID_IGNORE = _core_.ID_IGNORE
|
||||
ID_ADD = _core_.ID_ADD
|
||||
ID_REMOVE = _core_.ID_REMOVE
|
||||
ID_UP = _core_.ID_UP
|
||||
ID_DOWN = _core_.ID_DOWN
|
||||
ID_HOME = _core_.ID_HOME
|
||||
ID_REFRESH = _core_.ID_REFRESH
|
||||
ID_STOP = _core_.ID_STOP
|
||||
ID_INDEX = _core_.ID_INDEX
|
||||
ID_BOLD = _core_.ID_BOLD
|
||||
ID_ITALIC = _core_.ID_ITALIC
|
||||
ID_JUSTIFY_CENTER = _core_.ID_JUSTIFY_CENTER
|
||||
ID_JUSTIFY_FILL = _core_.ID_JUSTIFY_FILL
|
||||
ID_JUSTIFY_RIGHT = _core_.ID_JUSTIFY_RIGHT
|
||||
ID_JUSTIFY_LEFT = _core_.ID_JUSTIFY_LEFT
|
||||
ID_UNDERLINE = _core_.ID_UNDERLINE
|
||||
ID_INDENT = _core_.ID_INDENT
|
||||
ID_UNINDENT = _core_.ID_UNINDENT
|
||||
ID_ZOOM_100 = _core_.ID_ZOOM_100
|
||||
ID_ZOOM_FIT = _core_.ID_ZOOM_FIT
|
||||
ID_ZOOM_IN = _core_.ID_ZOOM_IN
|
||||
ID_ZOOM_OUT = _core_.ID_ZOOM_OUT
|
||||
ID_UNDELETE = _core_.ID_UNDELETE
|
||||
ID_REVERT_TO_SAVED = _core_.ID_REVERT_TO_SAVED
|
||||
ID_HIGHEST = _core_.ID_HIGHEST
|
||||
OPEN = _core_.OPEN
|
||||
SAVE = _core_.SAVE
|
||||
@ -292,6 +315,9 @@ BORDER_RAISED = _core_.BORDER_RAISED
|
||||
BORDER_SUNKEN = _core_.BORDER_SUNKEN
|
||||
BORDER_DOUBLE = _core_.BORDER_DOUBLE
|
||||
BORDER_MASK = _core_.BORDER_MASK
|
||||
BG_STYLE_SYSTEM = _core_.BG_STYLE_SYSTEM
|
||||
BG_STYLE_COLOUR = _core_.BG_STYLE_COLOUR
|
||||
BG_STYLE_CUSTOM = _core_.BG_STYLE_CUSTOM
|
||||
DEFAULT = _core_.DEFAULT
|
||||
DECORATIVE = _core_.DECORATIVE
|
||||
ROMAN = _core_.ROMAN
|
||||
@ -7003,6 +7029,39 @@ class Window(EvtHandler):
|
||||
"""
|
||||
return _core_.Window_GetForegroundColour(*args, **kwargs)
|
||||
|
||||
def SetBackgroundStyle(*args, **kwargs):
|
||||
"""
|
||||
SetBackgroundStyle(self, int style) -> bool
|
||||
|
||||
Returns the background style of the window. The background style
|
||||
indicates how the background of the window is drawn.
|
||||
|
||||
====================== ========================================
|
||||
wx.BG_STYLE_SYSTEM The background colour or pattern should
|
||||
be determined by the system
|
||||
wx.BG_STYLE_COLOUR The background should be a solid colour
|
||||
wx.BG_STYLE_CUSTOM The background will be implemented by the
|
||||
application.
|
||||
====================== ========================================
|
||||
|
||||
On GTK+, use of wx.BG_STYLE_CUSTOM allows the flicker-free drawing of
|
||||
a custom background, such as a tiled bitmap. Currently the style has
|
||||
no effect on other platforms.
|
||||
|
||||
:see: `GetBackgroundStyle`, `SetBackgroundColour`
|
||||
"""
|
||||
return _core_.Window_SetBackgroundStyle(*args, **kwargs)
|
||||
|
||||
def GetBackgroundStyle(*args, **kwargs):
|
||||
"""
|
||||
GetBackgroundStyle(self) -> int
|
||||
|
||||
Returns the background style of the window.
|
||||
|
||||
:see: `SetBackgroundStyle`
|
||||
"""
|
||||
return _core_.Window_GetBackgroundStyle(*args, **kwargs)
|
||||
|
||||
def SetCursor(*args, **kwargs):
|
||||
"""
|
||||
SetCursor(self, Cursor cursor) -> bool
|
||||
@ -10581,16 +10640,16 @@ __wxPyPtrTypeMap['wxStatusBar95'] = 'wxStatusBar'
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
# Load version numbers from __version__... Ensure that major and minor
|
||||
# versions are the same for both wxPython and wxWindows.
|
||||
# versions are the same for both wxPython and wxWidgets.
|
||||
|
||||
from __version__ import *
|
||||
__version__ = VERSION_STRING
|
||||
|
||||
assert MAJOR_VERSION == _core_.MAJOR_VERSION, "wxPython/wxWindows version mismatch"
|
||||
assert MINOR_VERSION == _core_.MINOR_VERSION, "wxPython/wxWindows version mismatch"
|
||||
assert MAJOR_VERSION == _core_.MAJOR_VERSION, "wxPython/wxWidgets version mismatch"
|
||||
assert MINOR_VERSION == _core_.MINOR_VERSION, "wxPython/wxWidgets version mismatch"
|
||||
if RELEASE_VERSION != _core_.RELEASE_VERSION:
|
||||
import warnings
|
||||
warnings.warn("wxPython/wxWindows release number mismatch")
|
||||
warnings.warn("wxPython/wxWidgets release number mismatch")
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
|
||||
|
@ -26330,6 +26330,64 @@ static PyObject *_wrap_Window_GetForegroundColour(PyObject *self, PyObject *args
|
||||
}
|
||||
|
||||
|
||||
static PyObject *_wrap_Window_SetBackgroundStyle(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
wxWindow *arg1 = (wxWindow *) 0 ;
|
||||
int arg2 ;
|
||||
bool result;
|
||||
PyObject * obj0 = 0 ;
|
||||
PyObject * obj1 = 0 ;
|
||||
char *kwnames[] = {
|
||||
(char *) "self",(char *) "style", NULL
|
||||
};
|
||||
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:Window_SetBackgroundStyle",kwnames,&obj0,&obj1)) goto fail;
|
||||
if ((SWIG_ConvertPtr(obj0,(void **)(&arg1),SWIGTYPE_p_wxWindow,
|
||||
SWIG_POINTER_EXCEPTION | 0)) == -1) SWIG_fail;
|
||||
arg2 = (wxBackgroundStyle) SWIG_AsInt(obj1);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
result = (bool)(arg1)->SetBackgroundStyle((wxBackgroundStyle )arg2);
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
}
|
||||
{
|
||||
resultobj = result ? Py_True : Py_False; Py_INCREF(resultobj);
|
||||
}
|
||||
return resultobj;
|
||||
fail:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
static PyObject *_wrap_Window_GetBackgroundStyle(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
wxWindow *arg1 = (wxWindow *) 0 ;
|
||||
int result;
|
||||
PyObject * obj0 = 0 ;
|
||||
char *kwnames[] = {
|
||||
(char *) "self", NULL
|
||||
};
|
||||
|
||||
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:Window_GetBackgroundStyle",kwnames,&obj0)) goto fail;
|
||||
if ((SWIG_ConvertPtr(obj0,(void **)(&arg1),SWIGTYPE_p_wxWindow,
|
||||
SWIG_POINTER_EXCEPTION | 0)) == -1) SWIG_fail;
|
||||
{
|
||||
PyThreadState* __tstate = wxPyBeginAllowThreads();
|
||||
result = (int)((wxWindow const *)arg1)->GetBackgroundStyle();
|
||||
|
||||
wxPyEndAllowThreads(__tstate);
|
||||
if (PyErr_Occurred()) SWIG_fail;
|
||||
}
|
||||
resultobj = SWIG_FromInt((int)result);
|
||||
return resultobj;
|
||||
fail:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
static PyObject *_wrap_Window_SetCursor(PyObject *self, PyObject *args, PyObject *kwargs) {
|
||||
PyObject *resultobj;
|
||||
wxWindow *arg1 = (wxWindow *) 0 ;
|
||||
@ -41373,6 +41431,8 @@ static PyMethodDef SwigMethods[] = {
|
||||
{ (char *)"Window_SetOwnForegroundColour", (PyCFunction) _wrap_Window_SetOwnForegroundColour, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_GetBackgroundColour", (PyCFunction) _wrap_Window_GetBackgroundColour, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_GetForegroundColour", (PyCFunction) _wrap_Window_GetForegroundColour, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_SetBackgroundStyle", (PyCFunction) _wrap_Window_SetBackgroundStyle, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_GetBackgroundStyle", (PyCFunction) _wrap_Window_GetBackgroundStyle, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_SetCursor", (PyCFunction) _wrap_Window_SetCursor, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_GetCursor", (PyCFunction) _wrap_Window_GetCursor, METH_VARARGS | METH_KEYWORDS },
|
||||
{ (char *)"Window_SetFont", (PyCFunction) _wrap_Window_SetFont, METH_VARARGS | METH_KEYWORDS },
|
||||
@ -42727,6 +42787,29 @@ SWIGEXPORT(void) SWIG_init(void) {
|
||||
PyDict_SetItemString(d,"ID_ABORT", SWIG_FromInt((int)wxID_ABORT));
|
||||
PyDict_SetItemString(d,"ID_RETRY", SWIG_FromInt((int)wxID_RETRY));
|
||||
PyDict_SetItemString(d,"ID_IGNORE", SWIG_FromInt((int)wxID_IGNORE));
|
||||
PyDict_SetItemString(d,"ID_ADD", SWIG_FromInt((int)wxID_ADD));
|
||||
PyDict_SetItemString(d,"ID_REMOVE", SWIG_FromInt((int)wxID_REMOVE));
|
||||
PyDict_SetItemString(d,"ID_UP", SWIG_FromInt((int)wxID_UP));
|
||||
PyDict_SetItemString(d,"ID_DOWN", SWIG_FromInt((int)wxID_DOWN));
|
||||
PyDict_SetItemString(d,"ID_HOME", SWIG_FromInt((int)wxID_HOME));
|
||||
PyDict_SetItemString(d,"ID_REFRESH", SWIG_FromInt((int)wxID_REFRESH));
|
||||
PyDict_SetItemString(d,"ID_STOP", SWIG_FromInt((int)wxID_STOP));
|
||||
PyDict_SetItemString(d,"ID_INDEX", SWIG_FromInt((int)wxID_INDEX));
|
||||
PyDict_SetItemString(d,"ID_BOLD", SWIG_FromInt((int)wxID_BOLD));
|
||||
PyDict_SetItemString(d,"ID_ITALIC", SWIG_FromInt((int)wxID_ITALIC));
|
||||
PyDict_SetItemString(d,"ID_JUSTIFY_CENTER", SWIG_FromInt((int)wxID_JUSTIFY_CENTER));
|
||||
PyDict_SetItemString(d,"ID_JUSTIFY_FILL", SWIG_FromInt((int)wxID_JUSTIFY_FILL));
|
||||
PyDict_SetItemString(d,"ID_JUSTIFY_RIGHT", SWIG_FromInt((int)wxID_JUSTIFY_RIGHT));
|
||||
PyDict_SetItemString(d,"ID_JUSTIFY_LEFT", SWIG_FromInt((int)wxID_JUSTIFY_LEFT));
|
||||
PyDict_SetItemString(d,"ID_UNDERLINE", SWIG_FromInt((int)wxID_UNDERLINE));
|
||||
PyDict_SetItemString(d,"ID_INDENT", SWIG_FromInt((int)wxID_INDENT));
|
||||
PyDict_SetItemString(d,"ID_UNINDENT", SWIG_FromInt((int)wxID_UNINDENT));
|
||||
PyDict_SetItemString(d,"ID_ZOOM_100", SWIG_FromInt((int)wxID_ZOOM_100));
|
||||
PyDict_SetItemString(d,"ID_ZOOM_FIT", SWIG_FromInt((int)wxID_ZOOM_FIT));
|
||||
PyDict_SetItemString(d,"ID_ZOOM_IN", SWIG_FromInt((int)wxID_ZOOM_IN));
|
||||
PyDict_SetItemString(d,"ID_ZOOM_OUT", SWIG_FromInt((int)wxID_ZOOM_OUT));
|
||||
PyDict_SetItemString(d,"ID_UNDELETE", SWIG_FromInt((int)wxID_UNDELETE));
|
||||
PyDict_SetItemString(d,"ID_REVERT_TO_SAVED", SWIG_FromInt((int)wxID_REVERT_TO_SAVED));
|
||||
PyDict_SetItemString(d,"ID_HIGHEST", SWIG_FromInt((int)wxID_HIGHEST));
|
||||
PyDict_SetItemString(d,"OPEN", SWIG_FromInt((int)wxOPEN));
|
||||
PyDict_SetItemString(d,"SAVE", SWIG_FromInt((int)wxSAVE));
|
||||
@ -42813,6 +42896,9 @@ SWIGEXPORT(void) SWIG_init(void) {
|
||||
PyDict_SetItemString(d,"BORDER_SUNKEN", SWIG_FromInt((int)wxBORDER_SUNKEN));
|
||||
PyDict_SetItemString(d,"BORDER_DOUBLE", SWIG_FromInt((int)wxBORDER_DOUBLE));
|
||||
PyDict_SetItemString(d,"BORDER_MASK", SWIG_FromInt((int)wxBORDER_MASK));
|
||||
PyDict_SetItemString(d,"BG_STYLE_SYSTEM", SWIG_FromInt((int)wxBG_STYLE_SYSTEM));
|
||||
PyDict_SetItemString(d,"BG_STYLE_COLOUR", SWIG_FromInt((int)wxBG_STYLE_COLOUR));
|
||||
PyDict_SetItemString(d,"BG_STYLE_CUSTOM", SWIG_FromInt((int)wxBG_STYLE_CUSTOM));
|
||||
PyDict_SetItemString(d,"DEFAULT", SWIG_FromInt((int)wxDEFAULT));
|
||||
PyDict_SetItemString(d,"DECORATIVE", SWIG_FromInt((int)wxDECORATIVE));
|
||||
PyDict_SetItemString(d,"ROMAN", SWIG_FromInt((int)wxROMAN));
|
||||
|
@ -422,6 +422,9 @@ SWIG_CheckInt(PyObject* obj)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#include <wx/stockitem.h>
|
||||
|
||||
static const wxString wxPyFileSelectorPromptStr(wxFileSelectorPromptStr);
|
||||
static const wxString wxPyFileSelectorDefaultWildcardStr(wxFileSelectorDefaultWildcardStr);
|
||||
static const wxString wxPyDirSelectorPromptStr(wxDirSelectorPromptStr);
|
||||
|
@ -131,9 +131,6 @@ wxDirSelectorPromptStr = wx._misc.DirSelectorPromptStr
|
||||
wxNewId = wx._misc.NewId
|
||||
wxRegisterId = wx._misc.RegisterId
|
||||
wxGetCurrentId = wx._misc.GetCurrentId
|
||||
wxIsStockID = wx._misc.IsStockID
|
||||
wxIsStockLabel = wx._misc.IsStockLabel
|
||||
wxGetStockLabel = wx._misc.GetStockLabel
|
||||
wxBell = wx._misc.Bell
|
||||
wxEndBusyCursor = wx._misc.EndBusyCursor
|
||||
wxGetElapsedTime = wx._misc.GetElapsedTime
|
||||
|
Loading…
Reference in New Issue
Block a user