#define SWIG_name "gdic"
#include "helpers.h"
-#include <wx/metafile.h>
#include <wx/imaglist.h>
-#ifndef __WXMSW__
-#include <wx/dcps.h>
-#endif
#include <wx/fontmap.h>
#include <wx/fontenc.h>
#include <wx/fontmap.h>
#if PYTHON_API_VERSION >= 1009
static char* wxStringErrorMsg = "String or Unicode type required";
#else
- static char* wxStringErrorMsg = "string type is required for parameter";
+ static char* wxStringErrorMsg = "String type required";
#endif
static wxString wxPyEmptyStr("");
wxColour* wxNamedColour(const wxString& colorName) {
return new wxColour(colorName);
}
+
+class wxPyPen : public wxPen {
+public:
+ wxPyPen(wxColour& colour, int width=1, int style=wxSOLID)
+ : wxPen(colour, width, style)
+ { m_dash = NULL; }
+ ~wxPyPen() {
+ if (m_dash)
+ delete [] m_dash;
+ }
+
+ void SetDashes(int nb_dashes, const wxDash *dash) {
+ if (m_dash)
+ delete [] m_dash;
+ m_dash = new wxDash[nb_dashes];
+ for (int i=0; i<nb_dashes; i++) {
+ m_dash[i] = dash[i];
+ }
+ wxPen::SetDashes(nb_dashes, m_dash);
+ }
+
+private:
+ wxDash* m_dash;
+};
+
+static void wxDC_GetBoundingBox(wxDC* dc, int* x1, int* y1, int* x2, int* y2) {
+ *x1 = dc->MinX();
+ *y1 = dc->MinY();
+ *x2 = dc->MaxX();
+ *y2 = dc->MaxY();
+}
// Alternate 'constructor'
wxMemoryDC* wxMemoryDCFromDC(wxDC* oldDC) {
return new wxMemoryDC(oldDC);
extern wxColour wxNullColour;
extern wxFontList * wxTheFontList;
extern wxPenList * wxThePenList;
-extern wxBrushlist * wxTheBrushList;
+extern wxBrushList * wxTheBrushList;
extern wxColourDatabase * wxTheColourDatabase;
#endif
PyObject * pyobj;
char ptemp[128];
- SWIG_MakePtr(ptemp, (char *) wxTheBrushList,"_wxBrushlist_p");
+ SWIG_MakePtr(ptemp, (char *) wxTheBrushList,"_wxBrushList_p");
pyobj = PyString_FromString(ptemp);
return pyobj;
}
PyObject * _resultobj;
wxBitmap * _result;
wxString * _arg0;
- wxBitmapType _arg1;
+ wxBitmapType _arg1 = (wxBitmapType ) wxBITMAP_TYPE_BMP;
PyObject * _obj0 = 0;
char *_kwnames[] = { "name","type", NULL };
char _ptemp[128];
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:new_wxBitmap",_kwnames,&_obj0,&_arg1))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:new_wxBitmap",_kwnames,&_obj0,&_arg1))
return NULL;
{
#if PYTHON_API_VERSION >= 1009
bool _result;
wxBitmap * _arg0;
wxString * _arg1;
- long _arg2;
+ wxBitmapType _arg2 = (wxBitmapType ) wxBITMAP_TYPE_BMP;
PyObject * _argo0 = 0;
PyObject * _obj1 = 0;
- char *_kwnames[] = { "self","name","flags", NULL };
+ char *_kwnames[] = { "self","name","type", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOl:wxBitmap_LoadFile",_kwnames,&_argo0,&_obj1,&_arg2))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO|i:wxBitmap_LoadFile",_kwnames,&_argo0,&_obj1,&_arg2))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
bool _result;
wxBitmap * _arg0;
wxString * _arg1;
- int _arg2;
+ wxBitmapType _arg2;
wxPalette * _arg3 = (wxPalette *) NULL;
PyObject * _argo0 = 0;
PyObject * _obj1 = 0;
return _resultobj;
}
+#define wxBitmap_CopyFromIcon(_swigobj,_swigarg0) (_swigobj->CopyFromIcon(_swigarg0))
+static PyObject *_wrap_wxBitmap_CopyFromIcon(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ bool _result;
+ wxBitmap * _arg0;
+ wxIcon * _arg1;
+ PyObject * _argo0 = 0;
+ PyObject * _argo1 = 0;
+ char *_kwnames[] = { "self","icon", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxBitmap_CopyFromIcon",_kwnames,&_argo0,&_argo1))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_CopyFromIcon. Expected _wxBitmap_p.");
+ return NULL;
+ }
+ }
+ if (_argo1) {
+ if (_argo1 == Py_None) { _arg1 = NULL; }
+ else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxIcon_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxBitmap_CopyFromIcon. Expected _wxIcon_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = (bool )wxBitmap_CopyFromIcon(_arg0,*_arg1);
+
+ wxPy_END_ALLOW_THREADS;
+ if (PyErr_Occurred()) return NULL;
+} _resultobj = Py_BuildValue("i",_result);
+ return _resultobj;
+}
+
static void *SwigwxMaskTowxObject(void *ptr) {
wxMask *src;
wxObject *dest;
return _resultobj;
}
-#define wxPen_GetDashes(_swigobj,_swigarg0) (_swigobj->GetDashes(_swigarg0))
-static PyObject *_wrap_wxPen_GetDashes(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxPen_SetDashes(_swigobj,_swigarg0,_swigarg1) (_swigobj->SetDashes(_swigarg0,_swigarg1))
+static PyObject *_wrap_wxPen_SetDashes(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- int _result;
wxPen * _arg0;
- wxDash ** _arg1;
+ int _arg1;
+ wxDash * _arg2;
PyObject * _argo0 = 0;
- PyObject * _argo1 = 0;
- char *_kwnames[] = { "self","dashes", NULL };
+ PyObject * _obj2 = 0;
+ char *_kwnames[] = { "self","choices", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPen_GetDashes",_kwnames,&_argo0,&_argo1))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPen_SetDashes",_kwnames,&_argo0,&_obj2))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPen_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxPen_GetDashes. Expected _wxPen_p.");
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxPen_SetDashes. Expected _wxPen_p.");
return NULL;
}
}
- if (_argo1) {
- if (_argo1 == Py_None) { _arg1 = NULL; }
- else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxDash_pp")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxPen_GetDashes. Expected _wxDash_pp.");
+ if (_obj2)
+{
+ _arg2 = (wxDash*)byte_LIST_helper(_obj2);
+ if (_arg2 == NULL) {
+ return NULL;
+ }
+}
+{
+ if (_obj2) {
+ _arg1 = PyList_Size(_obj2);
+ }
+ else {
+ _arg1 = 0;
+ }
+}
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ wxPen_SetDashes(_arg0,_arg1,_arg2);
+
+ wxPy_END_ALLOW_THREADS;
+ if (PyErr_Occurred()) return NULL;
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
+{
+ delete [] _arg2;
+}
+ return _resultobj;
+}
+
+static void *SwigwxPyPenTowxPen(void *ptr) {
+ wxPyPen *src;
+ wxPen *dest;
+ src = (wxPyPen *) ptr;
+ dest = (wxPen *) src;
+ return (void *) dest;
+}
+
+static void *SwigwxPyPenTowxGDIObject(void *ptr) {
+ wxPyPen *src;
+ wxGDIObject *dest;
+ src = (wxPyPen *) ptr;
+ dest = (wxGDIObject *) src;
+ return (void *) dest;
+}
+
+static void *SwigwxPyPenTowxObject(void *ptr) {
+ wxPyPen *src;
+ wxObject *dest;
+ src = (wxPyPen *) ptr;
+ dest = (wxObject *) src;
+ return (void *) dest;
+}
+
+#define new_wxPyPen(_swigarg0,_swigarg1,_swigarg2) (new wxPyPen(_swigarg0,_swigarg1,_swigarg2))
+static PyObject *_wrap_new_wxPyPen(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxPyPen * _result;
+ wxColour * _arg0;
+ int _arg1 = (int ) 1;
+ int _arg2 = (int ) wxSOLID;
+ wxColour temp;
+ PyObject * _obj0 = 0;
+ char *_kwnames[] = { "colour","width","style", NULL };
+ char _ptemp[128];
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|ii:new_wxPyPen",_kwnames,&_obj0,&_arg1,&_arg2))
+ return NULL;
+{
+ _arg0 = &temp;
+ if (! wxColour_helper(_obj0, &_arg0))
+ return NULL;
+}
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = (wxPyPen *)new_wxPyPen(*_arg0,_arg1,_arg2);
+
+ wxPy_END_ALLOW_THREADS;
+ if (PyErr_Occurred()) return NULL;
+} if (_result) {
+ SWIG_MakePtr(_ptemp, (char *) _result,"_wxPyPen_p");
+ _resultobj = Py_BuildValue("s",_ptemp);
+ } else {
+ Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ }
+ return _resultobj;
+}
+
+#define delete_wxPyPen(_swigobj) (delete _swigobj)
+static PyObject *_wrap_delete_wxPyPen(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxPyPen * _arg0;
+ PyObject * _argo0 = 0;
+ char *_kwnames[] = { "self", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxPyPen",_kwnames,&_argo0))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyPen_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of delete_wxPyPen. Expected _wxPyPen_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (int )wxPen_GetDashes(_arg0,_arg1);
+ delete_wxPyPen(_arg0);
wxPy_END_ALLOW_THREADS;
if (PyErr_Occurred()) return NULL;
-} _resultobj = Py_BuildValue("i",_result);
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
return _resultobj;
}
-#define wxPen_SetDashes(_swigobj,_swigarg0,_swigarg1) (_swigobj->SetDashes(_swigarg0,_swigarg1))
-static PyObject *_wrap_wxPen_SetDashes(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxPyPen_SetDashes(_swigobj,_swigarg0,_swigarg1) (_swigobj->SetDashes(_swigarg0,_swigarg1))
+static PyObject *_wrap_wxPyPen_SetDashes(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- wxPen * _arg0;
+ wxPyPen * _arg0;
int _arg1;
wxDash * _arg2;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self","choices", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPen_SetDashes",_kwnames,&_argo0,&_obj2))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxPyPen_SetDashes",_kwnames,&_argo0,&_obj2))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPen_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxPen_SetDashes. Expected _wxPen_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPyPen_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxPyPen_SetDashes. Expected _wxPyPen_p.");
return NULL;
}
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- wxPen_SetDashes(_arg0,_arg1,_arg2);
+ wxPyPen_SetDashes(_arg0,_arg1,_arg2);
wxPy_END_ALLOW_THREADS;
if (PyErr_Occurred()) return NULL;
return _resultobj;
}
+static void *SwigwxBrushListTowxObject(void *ptr) {
+ wxBrushList *src;
+ wxObject *dest;
+ src = (wxBrushList *) ptr;
+ dest = (wxObject *) src;
+ return (void *) dest;
+}
+
#define wxBrushList_AddBrush(_swigobj,_swigarg0) (_swigobj->AddBrush(_swigarg0))
static PyObject *_wrap_wxBrushList_AddBrush(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
return _resultobj;
}
+static PyObject *_wrap_wxDC_GetBoundingBox(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxDC * _arg0;
+ int * _arg1;
+ int temp;
+ int * _arg2;
+ int temp0;
+ int * _arg3;
+ int temp1;
+ int * _arg4;
+ int temp2;
+ PyObject * _argo0 = 0;
+ char *_kwnames[] = { "self", NULL };
+
+ self = self;
+{
+ _arg1 = &temp;
+}
+{
+ _arg2 = &temp0;
+}
+{
+ _arg3 = &temp1;
+}
+{
+ _arg4 = &temp2;
+}
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxDC_GetBoundingBox",_kwnames,&_argo0))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxDC_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxDC_GetBoundingBox. Expected _wxDC_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ wxDC_GetBoundingBox(_arg0,_arg1,_arg2,_arg3,_arg4);
+
+ wxPy_END_ALLOW_THREADS;
+ if (PyErr_Occurred()) return NULL;
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
+{
+ 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);
+}
+{
+ PyObject *o;
+ o = PyInt_FromLong((long) (*_arg4));
+ _resultobj = t_output_helper(_resultobj, o);
+}
+ return _resultobj;
+}
+
+static PyObject * wxDC__DrawPointList(wxDC *self,PyObject * pyPoints,PyObject * pyPens) {
+ bool isFastSeq = PyList_Check(pyPoints) || PyTuple_Check(pyPoints);
+ bool isFastPens = PyList_Check(pyPens) || PyTuple_Check(pyPens);
+ int numObjs = 0;
+ int numPens = 0;
+ wxPen* pen;
+ PyObject* obj;
+ int x1, y1;
+ int i = 0;
+
+ if (!PySequence_Check(pyPoints)) {
+ goto err0;
+ }
+ if (!PySequence_Check(pyPens)) {
+ goto err1;
+ }
+ numObjs = PySequence_Length(pyPoints);
+ numPens = PySequence_Length(pyPens);
+
+ for (i = 0; i < numObjs; i++) {
+ // Use a new pen?
+ if (i < numPens) {
+ if (isFastPens) {
+ obj = PySequence_Fast_GET_ITEM(pyPens, i);
+ }
+ else {
+ obj = PySequence_GetItem(pyPens, i);
+ }
+ if (SWIG_GetPtrObj(obj, (void **) &pen, "_wxPen_p")) {
+ if (!isFastPens)
+ Py_DECREF(obj);
+ goto err1;
+ }
+
+ self->SetPen(*pen);
+ if (!isFastPens)
+ Py_DECREF(obj);
+ }
+
+ // Get the point coordinants
+ if (isFastSeq) {
+ obj = PySequence_Fast_GET_ITEM(pyPoints, i);
+ }
+ else {
+ obj = PySequence_GetItem(pyPoints, i);
+ }
+ if (! _2int_seq_helper(obj, &x1, &y1)) {
+ if (!isFastPens)
+ Py_DECREF(obj);
+ goto err0;
+ }
+
+ // Now draw the point
+ self->DrawPoint(x1, y1);
+
+ if (!isFastSeq)
+ Py_DECREF(obj);
+ }
+
+ Py_INCREF(Py_None);
+ return Py_None;
+
+ err1:
+ PyErr_SetString(PyExc_TypeError, "Expected a sequence of wxPens");
+ return NULL;
+ err0:
+ PyErr_SetString(PyExc_TypeError, "Expected a sequence of (x,y) sequences.");
+ return NULL;
+ }
+static PyObject *_wrap_wxDC__DrawPointList(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ PyObject * _result;
+ wxDC * _arg0;
+ PyObject * _arg1;
+ PyObject * _arg2;
+ PyObject * _argo0 = 0;
+ PyObject * _obj1 = 0;
+ PyObject * _obj2 = 0;
+ char *_kwnames[] = { "self","pyPoints","pyPens", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxDC__DrawPointList",_kwnames,&_argo0,&_obj1,&_obj2))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxDC_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxDC__DrawPointList. Expected _wxDC_p.");
+ return NULL;
+ }
+ }
+{
+ _arg1 = _obj1;
+}
+{
+ _arg2 = _obj2;
+}
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = (PyObject *)wxDC__DrawPointList(_arg0,_arg1,_arg2);
+
+ wxPy_END_ALLOW_THREADS;
+ if (PyErr_Occurred()) return NULL;
+}{
+ _resultobj = _result;
+}
+ return _resultobj;
+}
+
+static PyObject * wxDC__DrawLineList(wxDC *self,PyObject * pyLines,PyObject * pyPens) {
+ bool isFastSeq = PyList_Check(pyLines) || PyTuple_Check(pyLines);
+ bool isFastPens = PyList_Check(pyPens) || PyTuple_Check(pyPens);
+ int numObjs = 0;
+ int numPens = 0;
+ wxPen* pen;
+ PyObject* obj;
+ int x1, y1, x2, y2;
+ int i = 0;
+
+ if (!PySequence_Check(pyLines)) {
+ goto err0;
+ }
+ if (!PySequence_Check(pyPens)) {
+ goto err1;
+ }
+ numObjs = PySequence_Length(pyLines);
+ numPens = PySequence_Length(pyPens);
+
+ for (i = 0; i < numObjs; i++) {
+ // Use a new pen?
+ if (i < numPens) {
+ if (isFastPens) {
+ obj = PySequence_Fast_GET_ITEM(pyPens, i);
+ }
+ else {
+ obj = PySequence_GetItem(pyPens, i);
+ }
+ if (SWIG_GetPtrObj(obj, (void **) &pen, "_wxPen_p")) {
+ if (!isFastPens)
+ Py_DECREF(obj);
+ goto err1;
+ }
+
+ self->SetPen(*pen);
+ if (!isFastPens)
+ Py_DECREF(obj);
+ }
+
+ // Get the line coordinants
+ if (isFastSeq) {
+ obj = PySequence_Fast_GET_ITEM(pyLines, i);
+ }
+ else {
+ obj = PySequence_GetItem(pyLines, i);
+ }
+ if (! _4int_seq_helper(obj, &x1, &y1, &x2, &y2)) {
+ if (!isFastPens)
+ Py_DECREF(obj);
+ goto err0;
+ }
+
+ // Now draw the line
+ self->DrawLine(x1, y1, x2, y2);
+
+ if (!isFastSeq)
+ Py_DECREF(obj);
+ }
+
+ Py_INCREF(Py_None);
+ return Py_None;
+
+ err1:
+ PyErr_SetString(PyExc_TypeError, "Expected a sequence of wxPens");
+ return NULL;
+ err0:
+ PyErr_SetString(PyExc_TypeError, "Expected a sequence of (x1,y1, x2,y2) sequences.");
+ return NULL;
+ }
+static PyObject *_wrap_wxDC__DrawLineList(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ PyObject * _result;
+ wxDC * _arg0;
+ PyObject * _arg1;
+ PyObject * _arg2;
+ PyObject * _argo0 = 0;
+ PyObject * _obj1 = 0;
+ PyObject * _obj2 = 0;
+ char *_kwnames[] = { "self","pyLines","pyPens", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxDC__DrawLineList",_kwnames,&_argo0,&_obj1,&_obj2))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxDC_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxDC__DrawLineList. Expected _wxDC_p.");
+ return NULL;
+ }
+ }
+{
+ _arg1 = _obj1;
+}
+{
+ _arg2 = _obj2;
+}
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = (PyObject *)wxDC__DrawLineList(_arg0,_arg1,_arg2);
+
+ wxPy_END_ALLOW_THREADS;
+ if (PyErr_Occurred()) return NULL;
+}{
+ _resultobj = _result;
+}
+ return _resultobj;
+}
+
static void *SwigwxMemoryDCTowxDC(void *ptr) {
wxMemoryDC *src;
wxDC *dest;
return _resultobj;
}
-static void *SwigwxPostScriptDCTowxDC(void *ptr) {
- wxPostScriptDC *src;
- wxDC *dest;
- src = (wxPostScriptDC *) ptr;
- dest = (wxDC *) src;
- return (void *) dest;
-}
-
-static void *SwigwxPostScriptDCTowxObject(void *ptr) {
- wxPostScriptDC *src;
- wxObject *dest;
- src = (wxPostScriptDC *) ptr;
- dest = (wxObject *) src;
- return (void *) dest;
-}
-
-#define new_wxPostScriptDC(_swigarg0,_swigarg1,_swigarg2) (new wxPostScriptDC(_swigarg0,_swigarg1,_swigarg2))
-static PyObject *_wrap_new_wxPostScriptDC(PyObject *self, PyObject *args, PyObject *kwargs) {
- PyObject * _resultobj;
- wxPostScriptDC * _result;
- wxString * _arg0;
- bool _arg1 = (bool ) TRUE;
- wxWindow * _arg2 = (wxWindow *) NULL;
- PyObject * _obj0 = 0;
- int tempbool1 = (int) TRUE;
- PyObject * _argo2 = 0;
- char *_kwnames[] = { "output","interactive","win", NULL };
- char _ptemp[128];
-
- self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|iO:new_wxPostScriptDC",_kwnames,&_obj0,&tempbool1,&_argo2))
- return NULL;
-{
-#if PYTHON_API_VERSION >= 1009
- char* tmpPtr; int tmpSize;
- if (!PyString_Check(_obj0) && !PyUnicode_Check(_obj0)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
- return NULL;
- }
- if (PyString_AsStringAndSize(_obj0, &tmpPtr, &tmpSize) == -1)
- return NULL;
- _arg0 = new wxString(tmpPtr, tmpSize);
-#else
- if (!PyString_Check(_obj0)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
- return NULL;
- }
- _arg0 = new wxString(PyString_AS_STRING(_obj0), PyString_GET_SIZE(_obj0));
-#endif
-}
- _arg1 = (bool ) tempbool1;
- if (_argo2) {
- if (_argo2 == Py_None) { _arg2 = NULL; }
- else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxWindow_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of new_wxPostScriptDC. Expected _wxWindow_p.");
- return NULL;
- }
- }
-{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxPostScriptDC *)new_wxPostScriptDC(*_arg0,_arg1,_arg2);
-
- wxPy_END_ALLOW_THREADS;
- if (PyErr_Occurred()) return NULL;
-} if (_result) {
- SWIG_MakePtr(_ptemp, (char *) _result,"_wxPostScriptDC_p");
- _resultobj = Py_BuildValue("s",_ptemp);
- } else {
- Py_INCREF(Py_None);
- _resultobj = Py_None;
- }
-{
- if (_obj0)
- delete _arg0;
-}
- return _resultobj;
-}
-
static void *SwigwxPaletteTowxGDIObject(void *ptr) {
wxPalette *src;
wxGDIObject *dest;
{ "wxPalette_GetPixel", (PyCFunction) _wrap_wxPalette_GetPixel, METH_VARARGS | METH_KEYWORDS },
{ "delete_wxPalette", (PyCFunction) _wrap_delete_wxPalette, METH_VARARGS | METH_KEYWORDS },
{ "new_wxPalette", (PyCFunction) _wrap_new_wxPalette, METH_VARARGS | METH_KEYWORDS },
- { "new_wxPostScriptDC", (PyCFunction) _wrap_new_wxPostScriptDC, METH_VARARGS | METH_KEYWORDS },
{ "new_wxWindowDC", (PyCFunction) _wrap_new_wxWindowDC, METH_VARARGS | METH_KEYWORDS },
{ "new_wxPaintDC", (PyCFunction) _wrap_new_wxPaintDC, METH_VARARGS | METH_KEYWORDS },
{ "new_wxClientDC", (PyCFunction) _wrap_new_wxClientDC, METH_VARARGS | METH_KEYWORDS },
{ "new_wxScreenDC", (PyCFunction) _wrap_new_wxScreenDC, METH_VARARGS | METH_KEYWORDS },
{ "wxMemoryDC_SelectObject", (PyCFunction) _wrap_wxMemoryDC_SelectObject, METH_VARARGS | METH_KEYWORDS },
{ "new_wxMemoryDC", (PyCFunction) _wrap_new_wxMemoryDC, METH_VARARGS | METH_KEYWORDS },
+ { "wxDC__DrawLineList", (PyCFunction) _wrap_wxDC__DrawLineList, METH_VARARGS | METH_KEYWORDS },
+ { "wxDC__DrawPointList", (PyCFunction) _wrap_wxDC__DrawPointList, METH_VARARGS | METH_KEYWORDS },
+ { "wxDC_GetBoundingBox", (PyCFunction) _wrap_wxDC_GetBoundingBox, METH_VARARGS | METH_KEYWORDS },
{ "wxDC_ResetBoundingBox", (PyCFunction) _wrap_wxDC_ResetBoundingBox, METH_VARARGS | METH_KEYWORDS },
{ "wxDC_CalcBoundingBox", (PyCFunction) _wrap_wxDC_CalcBoundingBox, METH_VARARGS | METH_KEYWORDS },
{ "wxDC_SetAxisOrientation", (PyCFunction) _wrap_wxDC_SetAxisOrientation, METH_VARARGS | METH_KEYWORDS },
{ "wxPenList_RemovePen", (PyCFunction) _wrap_wxPenList_RemovePen, METH_VARARGS | METH_KEYWORDS },
{ "wxPenList_FindOrCreatePen", (PyCFunction) _wrap_wxPenList_FindOrCreatePen, METH_VARARGS | METH_KEYWORDS },
{ "wxPenList_AddPen", (PyCFunction) _wrap_wxPenList_AddPen, METH_VARARGS | METH_KEYWORDS },
+ { "wxPyPen_SetDashes", (PyCFunction) _wrap_wxPyPen_SetDashes, METH_VARARGS | METH_KEYWORDS },
+ { "delete_wxPyPen", (PyCFunction) _wrap_delete_wxPyPen, METH_VARARGS | METH_KEYWORDS },
+ { "new_wxPyPen", (PyCFunction) _wrap_new_wxPyPen, METH_VARARGS | METH_KEYWORDS },
{ "wxPen_SetDashes", (PyCFunction) _wrap_wxPen_SetDashes, METH_VARARGS | METH_KEYWORDS },
- { "wxPen_GetDashes", (PyCFunction) _wrap_wxPen_GetDashes, METH_VARARGS | METH_KEYWORDS },
{ "wxPen_SetWidth", (PyCFunction) _wrap_wxPen_SetWidth, METH_VARARGS | METH_KEYWORDS },
{ "wxPen_SetStyle", (PyCFunction) _wrap_wxPen_SetStyle, METH_VARARGS | METH_KEYWORDS },
{ "wxPen_SetJoin", (PyCFunction) _wrap_wxPen_SetJoin, METH_VARARGS | METH_KEYWORDS },
{ "new_wxIcon", (PyCFunction) _wrap_new_wxIcon, METH_VARARGS | METH_KEYWORDS },
{ "wxMask_Destroy", (PyCFunction) _wrap_wxMask_Destroy, METH_VARARGS | METH_KEYWORDS },
{ "new_wxMask", (PyCFunction) _wrap_new_wxMask, METH_VARARGS | METH_KEYWORDS },
+ { "wxBitmap_CopyFromIcon", (PyCFunction) _wrap_wxBitmap_CopyFromIcon, METH_VARARGS | METH_KEYWORDS },
{ "wxBitmap_GetSubBitmap", (PyCFunction) _wrap_wxBitmap_GetSubBitmap, METH_VARARGS | METH_KEYWORDS },
{ "wxBitmap_SetDepth", (PyCFunction) _wrap_wxBitmap_SetDepth, METH_VARARGS | METH_KEYWORDS },
{ "wxBitmap_SetHeight", (PyCFunction) _wrap_wxBitmap_SetHeight, METH_VARARGS | METH_KEYWORDS },
{ "_wxPrintQuality","_EBool",0},
{ "_wxPrintQuality","_size_t",0},
{ "_wxPrintQuality","_time_t",0},
+ { "_wxPen","_wxPyPen",SwigwxPyPenTowxPen},
{ "_byte","_unsigned_char",0},
{ "_long","_unsigned_long",0},
{ "_long","_signed_long",0},
- { "_wxGDIObject","_class_wxRegion",SwigwxRegionTowxGDIObject},
{ "_wxGDIObject","_wxRegion",SwigwxRegionTowxGDIObject},
- { "_wxGDIObject","_class_wxPalette",SwigwxPaletteTowxGDIObject},
{ "_wxGDIObject","_wxPalette",SwigwxPaletteTowxGDIObject},
- { "_wxGDIObject","_class_wxBrush",SwigwxBrushTowxGDIObject},
{ "_wxGDIObject","_wxBrush",SwigwxBrushTowxGDIObject},
- { "_wxGDIObject","_class_wxPen",SwigwxPenTowxGDIObject},
+ { "_wxGDIObject","_wxPyPen",SwigwxPyPenTowxGDIObject},
{ "_wxGDIObject","_wxPen",SwigwxPenTowxGDIObject},
- { "_wxGDIObject","_class_wxFont",SwigwxFontTowxGDIObject},
{ "_wxGDIObject","_wxFont",SwigwxFontTowxGDIObject},
- { "_wxGDIObject","_class_wxCursor",SwigwxCursorTowxGDIObject},
{ "_wxGDIObject","_wxCursor",SwigwxCursorTowxGDIObject},
- { "_wxGDIObject","_class_wxIcon",SwigwxIconTowxGDIObject},
{ "_wxGDIObject","_wxIcon",SwigwxIconTowxGDIObject},
- { "_wxGDIObject","_class_wxBitmap",SwigwxBitmapTowxGDIObject},
{ "_wxGDIObject","_wxBitmap",SwigwxBitmapTowxGDIObject},
- { "_wxDC","_class_wxPostScriptDC",SwigwxPostScriptDCTowxDC},
- { "_wxDC","_wxPostScriptDC",SwigwxPostScriptDCTowxDC},
- { "_wxDC","_class_wxWindowDC",SwigwxWindowDCTowxDC},
{ "_wxDC","_wxWindowDC",SwigwxWindowDCTowxDC},
- { "_wxDC","_class_wxPaintDC",SwigwxPaintDCTowxDC},
{ "_wxDC","_wxPaintDC",SwigwxPaintDCTowxDC},
- { "_wxDC","_class_wxClientDC",SwigwxClientDCTowxDC},
{ "_wxDC","_wxClientDC",SwigwxClientDCTowxDC},
- { "_wxDC","_class_wxScreenDC",SwigwxScreenDCTowxDC},
{ "_wxDC","_wxScreenDC",SwigwxScreenDCTowxDC},
- { "_wxDC","_class_wxMemoryDC",SwigwxMemoryDCTowxDC},
{ "_wxDC","_wxMemoryDC",SwigwxMemoryDCTowxDC},
- { "_class_wxObject","_class_wxRegionIterator",SwigwxRegionIteratorTowxObject},
- { "_class_wxObject","_wxRegionIterator",SwigwxRegionIteratorTowxObject},
- { "_class_wxObject","_class_wxRegion",SwigwxRegionTowxObject},
- { "_class_wxObject","_wxRegion",SwigwxRegionTowxObject},
- { "_class_wxObject","_class_wxImageList",SwigwxImageListTowxObject},
- { "_class_wxObject","_wxImageList",SwigwxImageListTowxObject},
- { "_class_wxObject","_class_wxPalette",SwigwxPaletteTowxObject},
- { "_class_wxObject","_wxPalette",SwigwxPaletteTowxObject},
- { "_class_wxObject","_class_wxPostScriptDC",SwigwxPostScriptDCTowxObject},
- { "_class_wxObject","_wxPostScriptDC",SwigwxPostScriptDCTowxObject},
- { "_class_wxObject","_class_wxWindowDC",SwigwxWindowDCTowxObject},
- { "_class_wxObject","_wxWindowDC",SwigwxWindowDCTowxObject},
- { "_class_wxObject","_class_wxPaintDC",SwigwxPaintDCTowxObject},
- { "_class_wxObject","_wxPaintDC",SwigwxPaintDCTowxObject},
- { "_class_wxObject","_class_wxClientDC",SwigwxClientDCTowxObject},
- { "_class_wxObject","_wxClientDC",SwigwxClientDCTowxObject},
- { "_class_wxObject","_class_wxScreenDC",SwigwxScreenDCTowxObject},
- { "_class_wxObject","_wxScreenDC",SwigwxScreenDCTowxObject},
- { "_class_wxObject","_class_wxMemoryDC",SwigwxMemoryDCTowxObject},
- { "_class_wxObject","_wxMemoryDC",SwigwxMemoryDCTowxObject},
- { "_class_wxObject","_class_wxDC",SwigwxDCTowxObject},
- { "_class_wxObject","_wxDC",SwigwxDCTowxObject},
- { "_class_wxObject","_class_wxBrush",SwigwxBrushTowxObject},
- { "_class_wxObject","_wxBrush",SwigwxBrushTowxObject},
- { "_class_wxObject","_class_wxPenList",SwigwxPenListTowxObject},
- { "_class_wxObject","_wxPenList",SwigwxPenListTowxObject},
- { "_class_wxObject","_class_wxPen",SwigwxPenTowxObject},
- { "_class_wxObject","_wxPen",SwigwxPenTowxObject},
- { "_class_wxObject","_class_wxColourDatabase",SwigwxColourDatabaseTowxObject},
- { "_class_wxObject","_wxColourDatabase",SwigwxColourDatabaseTowxObject},
- { "_class_wxObject","_class_wxColour",SwigwxColourTowxObject},
- { "_class_wxObject","_wxColour",SwigwxColourTowxObject},
- { "_class_wxObject","_class_wxFontList",SwigwxFontListTowxObject},
- { "_class_wxObject","_wxFontList",SwigwxFontListTowxObject},
- { "_class_wxObject","_class_wxFont",SwigwxFontTowxObject},
- { "_class_wxObject","_wxFont",SwigwxFontTowxObject},
- { "_class_wxObject","_class_wxCursor",SwigwxCursorTowxObject},
- { "_class_wxObject","_wxCursor",SwigwxCursorTowxObject},
- { "_class_wxObject","_class_wxIcon",SwigwxIconTowxObject},
- { "_class_wxObject","_wxIcon",SwigwxIconTowxObject},
- { "_class_wxObject","_class_wxMask",SwigwxMaskTowxObject},
- { "_class_wxObject","_wxMask",SwigwxMaskTowxObject},
- { "_class_wxObject","_class_wxBitmap",SwigwxBitmapTowxObject},
- { "_class_wxObject","_wxBitmap",SwigwxBitmapTowxObject},
- { "_class_wxObject","_class_wxGDIObject",SwigwxGDIObjectTowxObject},
- { "_class_wxObject","_wxGDIObject",SwigwxGDIObjectTowxObject},
{ "_size_t","_wxCoord",0},
{ "_size_t","_wxPrintQuality",0},
{ "_size_t","_time_t",0},
{ "_EBool","_int",0},
{ "_EBool","_wxWindowID",0},
{ "_unsigned_long","_long",0},
- { "_class_wxDC","_class_wxPostScriptDC",SwigwxPostScriptDCTowxDC},
- { "_class_wxDC","_wxPostScriptDC",SwigwxPostScriptDCTowxDC},
- { "_class_wxDC","_class_wxWindowDC",SwigwxWindowDCTowxDC},
- { "_class_wxDC","_wxWindowDC",SwigwxWindowDCTowxDC},
- { "_class_wxDC","_class_wxPaintDC",SwigwxPaintDCTowxDC},
- { "_class_wxDC","_wxPaintDC",SwigwxPaintDCTowxDC},
- { "_class_wxDC","_class_wxClientDC",SwigwxClientDCTowxDC},
- { "_class_wxDC","_wxClientDC",SwigwxClientDCTowxDC},
- { "_class_wxDC","_class_wxScreenDC",SwigwxScreenDCTowxDC},
- { "_class_wxDC","_wxScreenDC",SwigwxScreenDCTowxDC},
- { "_class_wxDC","_class_wxMemoryDC",SwigwxMemoryDCTowxDC},
- { "_class_wxDC","_wxMemoryDC",SwigwxMemoryDCTowxDC},
{ "_wxNativeFontInfo","_struct_wxNativeFontInfo",0},
{ "_signed_int","_wxCoord",0},
{ "_signed_int","_wxPrintQuality",0},
{ "_WXTYPE","_unsigned_short",0},
{ "_unsigned_short","_WXTYPE",0},
{ "_unsigned_short","_short",0},
- { "_wxObject","_class_wxRegionIterator",SwigwxRegionIteratorTowxObject},
{ "_wxObject","_wxRegionIterator",SwigwxRegionIteratorTowxObject},
- { "_wxObject","_class_wxRegion",SwigwxRegionTowxObject},
{ "_wxObject","_wxRegion",SwigwxRegionTowxObject},
- { "_wxObject","_class_wxImageList",SwigwxImageListTowxObject},
{ "_wxObject","_wxImageList",SwigwxImageListTowxObject},
- { "_wxObject","_class_wxPalette",SwigwxPaletteTowxObject},
{ "_wxObject","_wxPalette",SwigwxPaletteTowxObject},
- { "_wxObject","_class_wxPostScriptDC",SwigwxPostScriptDCTowxObject},
- { "_wxObject","_wxPostScriptDC",SwigwxPostScriptDCTowxObject},
- { "_wxObject","_class_wxWindowDC",SwigwxWindowDCTowxObject},
{ "_wxObject","_wxWindowDC",SwigwxWindowDCTowxObject},
- { "_wxObject","_class_wxPaintDC",SwigwxPaintDCTowxObject},
{ "_wxObject","_wxPaintDC",SwigwxPaintDCTowxObject},
- { "_wxObject","_class_wxClientDC",SwigwxClientDCTowxObject},
{ "_wxObject","_wxClientDC",SwigwxClientDCTowxObject},
- { "_wxObject","_class_wxScreenDC",SwigwxScreenDCTowxObject},
{ "_wxObject","_wxScreenDC",SwigwxScreenDCTowxObject},
- { "_wxObject","_class_wxMemoryDC",SwigwxMemoryDCTowxObject},
{ "_wxObject","_wxMemoryDC",SwigwxMemoryDCTowxObject},
- { "_wxObject","_class_wxDC",SwigwxDCTowxObject},
{ "_wxObject","_wxDC",SwigwxDCTowxObject},
- { "_wxObject","_class_wxBrush",SwigwxBrushTowxObject},
+ { "_wxObject","_wxBrushList",SwigwxBrushListTowxObject},
{ "_wxObject","_wxBrush",SwigwxBrushTowxObject},
- { "_wxObject","_class_wxPenList",SwigwxPenListTowxObject},
{ "_wxObject","_wxPenList",SwigwxPenListTowxObject},
- { "_wxObject","_class_wxPen",SwigwxPenTowxObject},
+ { "_wxObject","_wxPyPen",SwigwxPyPenTowxObject},
{ "_wxObject","_wxPen",SwigwxPenTowxObject},
- { "_wxObject","_class_wxColourDatabase",SwigwxColourDatabaseTowxObject},
{ "_wxObject","_wxColourDatabase",SwigwxColourDatabaseTowxObject},
- { "_wxObject","_class_wxColour",SwigwxColourTowxObject},
{ "_wxObject","_wxColour",SwigwxColourTowxObject},
- { "_wxObject","_class_wxFontList",SwigwxFontListTowxObject},
{ "_wxObject","_wxFontList",SwigwxFontListTowxObject},
- { "_wxObject","_class_wxFont",SwigwxFontTowxObject},
{ "_wxObject","_wxFont",SwigwxFontTowxObject},
- { "_wxObject","_class_wxCursor",SwigwxCursorTowxObject},
{ "_wxObject","_wxCursor",SwigwxCursorTowxObject},
- { "_wxObject","_class_wxIcon",SwigwxIconTowxObject},
{ "_wxObject","_wxIcon",SwigwxIconTowxObject},
- { "_wxObject","_class_wxMask",SwigwxMaskTowxObject},
{ "_wxObject","_wxMask",SwigwxMaskTowxObject},
- { "_wxObject","_class_wxBitmap",SwigwxBitmapTowxObject},
{ "_wxObject","_wxBitmap",SwigwxBitmapTowxObject},
- { "_wxObject","_class_wxGDIObject",SwigwxGDIObjectTowxObject},
{ "_wxObject","_wxGDIObject",SwigwxGDIObjectTowxObject},
{ "_signed_short","_WXTYPE",0},
{ "_signed_short","_short",0},
{ "_wxWindowID","_int",0},
{ "_wxWindowID","_signed_int",0},
{ "_wxWindowID","_unsigned_int",0},
- { "_class_wxGDIObject","_class_wxRegion",SwigwxRegionTowxGDIObject},
- { "_class_wxGDIObject","_wxRegion",SwigwxRegionTowxGDIObject},
- { "_class_wxGDIObject","_class_wxPalette",SwigwxPaletteTowxGDIObject},
- { "_class_wxGDIObject","_wxPalette",SwigwxPaletteTowxGDIObject},
- { "_class_wxGDIObject","_class_wxBrush",SwigwxBrushTowxGDIObject},
- { "_class_wxGDIObject","_wxBrush",SwigwxBrushTowxGDIObject},
- { "_class_wxGDIObject","_class_wxPen",SwigwxPenTowxGDIObject},
- { "_class_wxGDIObject","_wxPen",SwigwxPenTowxGDIObject},
- { "_class_wxGDIObject","_class_wxFont",SwigwxFontTowxGDIObject},
- { "_class_wxGDIObject","_wxFont",SwigwxFontTowxGDIObject},
- { "_class_wxGDIObject","_class_wxCursor",SwigwxCursorTowxGDIObject},
- { "_class_wxGDIObject","_wxCursor",SwigwxCursorTowxGDIObject},
- { "_class_wxGDIObject","_class_wxIcon",SwigwxIconTowxGDIObject},
- { "_class_wxGDIObject","_wxIcon",SwigwxIconTowxGDIObject},
- { "_class_wxGDIObject","_class_wxBitmap",SwigwxBitmapTowxGDIObject},
- { "_class_wxGDIObject","_wxBitmap",SwigwxBitmapTowxGDIObject},
{ "_int","_wxCoord",0},
{ "_int","_wxPrintQuality",0},
{ "_int","_time_t",0},
PyDict_SetItemString(d,"wxFONTENCODING_CP855", PyInt_FromLong((long) wxFONTENCODING_CP855));
PyDict_SetItemString(d,"wxFONTENCODING_CP866", PyInt_FromLong((long) wxFONTENCODING_CP866));
PyDict_SetItemString(d,"wxFONTENCODING_CP874", PyInt_FromLong((long) wxFONTENCODING_CP874));
+ PyDict_SetItemString(d,"wxFONTENCODING_CP932", PyInt_FromLong((long) wxFONTENCODING_CP932));
+ PyDict_SetItemString(d,"wxFONTENCODING_CP936", PyInt_FromLong((long) wxFONTENCODING_CP936));
+ PyDict_SetItemString(d,"wxFONTENCODING_CP949", PyInt_FromLong((long) wxFONTENCODING_CP949));
+ PyDict_SetItemString(d,"wxFONTENCODING_CP950", PyInt_FromLong((long) wxFONTENCODING_CP950));
PyDict_SetItemString(d,"wxFONTENCODING_CP1250", PyInt_FromLong((long) wxFONTENCODING_CP1250));
PyDict_SetItemString(d,"wxFONTENCODING_CP1251", PyInt_FromLong((long) wxFONTENCODING_CP1251));
PyDict_SetItemString(d,"wxFONTENCODING_CP1252", PyInt_FromLong((long) wxFONTENCODING_CP1252));