reSWIGged

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@33033 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2005-03-24 17:51:57 +00:00
parent ddc80eb4eb
commit 3837a853c9
7 changed files with 78 additions and 21 deletions

View File

@@ -11238,18 +11238,21 @@ if RELEASE_VERSION != _core_.RELEASE_VERSION:
# different on different platforms. For example, please see
# http://www.alanwood.net/demos/charsetdiffs.html for differences
# between the common latin/roman encodings.
import locale
import codecs
try:
default = locale.getdefaultlocale()[1]
codecs.lookup(default)
except (ValueError, LookupError):
default = _sys.getdefaultencoding()
default = _sys.getdefaultencoding()
if default == 'ascii':
import locale
import codecs
try:
default = locale.getdefaultlocale()[1]
codecs.lookup(default)
except (ValueError, LookupError):
default = _sys.getdefaultencoding()
del locale
del codecs
if default:
wx.SetDefaultPyEncoding(default)
del default
del locale
del codecs
#----------------------------------------------------------------------------

View File

@@ -241,6 +241,11 @@ class SystemOptions(_core.Object):
return _misc_.SystemOptions_HasOption(*args, **kwargs)
HasOption = staticmethod(HasOption)
def IsFalse(*args, **kwargs):
"""IsFalse(String name) -> bool"""
return _misc_.SystemOptions_IsFalse(*args, **kwargs)
IsFalse = staticmethod(IsFalse)
class SystemOptionsPtr(SystemOptions):
def __init__(self, this):
@@ -271,6 +276,10 @@ def SystemOptions_HasOption(*args, **kwargs):
"""SystemOptions_HasOption(String name) -> bool"""
return _misc_.SystemOptions_HasOption(*args, **kwargs)
def SystemOptions_IsFalse(*args, **kwargs):
"""SystemOptions_IsFalse(String name) -> bool"""
return _misc_.SystemOptions_IsFalse(*args, **kwargs)
#---------------------------------------------------------------------------

View File

@@ -3434,6 +3434,46 @@ static PyObject *_wrap_SystemOptions_HasOption(PyObject *, PyObject *args, PyObj
}
static PyObject *_wrap_SystemOptions_IsFalse(PyObject *, PyObject *args, PyObject *kwargs) {
PyObject *resultobj;
wxString *arg1 = 0 ;
bool result;
bool temp1 = false ;
PyObject * obj0 = 0 ;
char *kwnames[] = {
(char *) "name", NULL
};
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:SystemOptions_IsFalse",kwnames,&obj0)) goto fail;
{
arg1 = wxString_in_helper(obj0);
if (arg1 == NULL) SWIG_fail;
temp1 = true;
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
result = (bool)wxSystemOptions::IsFalse((wxString const &)*arg1);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) SWIG_fail;
}
{
resultobj = result ? Py_True : Py_False; Py_INCREF(resultobj);
}
{
if (temp1)
delete arg1;
}
return resultobj;
fail:
{
if (temp1)
delete arg1;
}
return NULL;
}
static PyObject * SystemOptions_swigregister(PyObject *, PyObject *args) {
PyObject *obj;
if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
@@ -31455,6 +31495,7 @@ static PyMethodDef SwigMethods[] = {
{ (char *)"SystemOptions_GetOption", (PyCFunction) _wrap_SystemOptions_GetOption, METH_VARARGS | METH_KEYWORDS, NULL},
{ (char *)"SystemOptions_GetOptionInt", (PyCFunction) _wrap_SystemOptions_GetOptionInt, METH_VARARGS | METH_KEYWORDS, NULL},
{ (char *)"SystemOptions_HasOption", (PyCFunction) _wrap_SystemOptions_HasOption, METH_VARARGS | METH_KEYWORDS, NULL},
{ (char *)"SystemOptions_IsFalse", (PyCFunction) _wrap_SystemOptions_IsFalse, METH_VARARGS | METH_KEYWORDS, NULL},
{ (char *)"SystemOptions_swigregister", SystemOptions_swigregister, METH_VARARGS, NULL},
{ (char *)"NewId", (PyCFunction) _wrap_NewId, METH_VARARGS | METH_KEYWORDS, NULL},
{ (char *)"RegisterId", (PyCFunction) _wrap_RegisterId, METH_VARARGS | METH_KEYWORDS, NULL},

View File

@@ -3357,7 +3357,7 @@ class MDIParentFrame(Frame):
return _windows_.MDIParentFrame_GetToolBar(*args, **kwargs)
def Tile(*args, **kwargs):
"""Tile(self)"""
"""Tile(self, int orient=HORIZONTAL)"""
return _windows_.MDIParentFrame_Tile(*args, **kwargs)

View File

@@ -17051,17 +17051,25 @@ static PyObject *_wrap_MDIParentFrame_GetToolBar(PyObject *, PyObject *args, PyO
static PyObject *_wrap_MDIParentFrame_Tile(PyObject *, PyObject *args, PyObject *kwargs) {
PyObject *resultobj;
wxMDIParentFrame *arg1 = (wxMDIParentFrame *) 0 ;
wxOrientation arg2 = (wxOrientation) wxHORIZONTAL ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
char *kwnames[] = {
(char *) "self", NULL
(char *) "self",(char *) "orient", NULL
};
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:MDIParentFrame_Tile",kwnames,&obj0)) goto fail;
if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:MDIParentFrame_Tile",kwnames,&obj0,&obj1)) goto fail;
SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxMDIParentFrame, SWIG_POINTER_EXCEPTION | 0);
if (SWIG_arg_fail(1)) SWIG_fail;
if (obj1) {
{
arg2 = (wxOrientation)(SWIG_As_int(obj1));
if (SWIG_arg_fail(2)) SWIG_fail;
}
}
{
PyThreadState* __tstate = wxPyBeginAllowThreads();
(arg1)->Tile();
(arg1)->Tile((wxOrientation )arg2);
wxPyEndAllowThreads(__tstate);
if (PyErr_Occurred()) SWIG_fail;