]> git.saurik.com Git - wxWidgets.git/blame - wxPython/src/pyrun.swg
Use a local copy of the old wxBufferedDC classes until the ones in the
[wxWidgets.git] / wxPython / src / pyrun.swg
CommitLineData
d14a1e28
RD
1/***********************************************************************
2 * pyrun.swg for wxPython
3 *
4 * Include only the function prototypes and such from SWIG's pyrun.swg,
5 * but not the runtime functions themselves. This helps keep the
6 * wrapper files clean of unnecessary stuff that is in the libpy.c file
7 * anyway.
8 *
9 ************************************************************************/
10
d14a1e28
RD
11#include "Python.h"
12
13#ifdef __cplusplus
14extern "C" {
15#endif
16
17#define SWIG_PY_INT 1
18#define SWIG_PY_FLOAT 2
19#define SWIG_PY_STRING 3
20#define SWIG_PY_POINTER 4
21#define SWIG_PY_BINARY 5
22
23/* Flags for pointer conversion */
24
25#define SWIG_POINTER_EXCEPTION 0x1
26#define SWIG_POINTER_DISOWN 0x2
27
28/* Exception handling in wrappers */
29#define SWIG_fail goto fail
30
31/* Constant information structure */
32typedef struct swig_const_info {
33 int type;
34 char *name;
35 long lvalue;
36 double dvalue;
37 void *pvalue;
38 swig_type_info **ptype;
39} swig_const_info;
40
d14a1e28
RD
41/* Common SWIG API */
42#define SWIG_ConvertPtr(obj, pp, type, flags) \
43 SWIG_Python_ConvertPtr(obj, pp, type, flags)
44#define SWIG_NewPointerObj(p, type, flags) \
45 SWIG_Python_NewPointerObj(p, type, flags)
46#define SWIG_MustGetPtr(p, type, argnum, flags) \
47 SWIG_Python_MustGetPtr(p, type, argnum, flags)
1de47c7c 48
d14a1e28
RD
49/* Python-specific SWIG API */
50#define SWIG_newvarlink() \
51 SWIG_Python_newvarlink()
52#define SWIG_addvarlink(p, name, get_attr, set_attr) \
53 SWIG_Python_addvarlink(p, name, get_attr, set_attr)
54#define SWIG_ConvertPacked(obj, ptr, sz, ty, flags) \
55 SWIG_Python_ConvertPacked(obj, ptr, sz, ty, flags)
d14a1e28
RD
56#define SWIG_NewPackedObj(ptr, sz, type) \
57 SWIG_Python_NewPackedObj(ptr, sz, type)
58#define SWIG_InstallConstants(d, constants) \
59 SWIG_Python_InstallConstants(d, constants)
60
d7f82584 61typedef double (*py_objasdbl_conv)(PyObject *obj);
d14a1e28 62
98fb9b71
RD
63SWIGIMPORT(int) SWIG_Python_ConvertPtr(PyObject *, void **, swig_type_info *, int);
64SWIGIMPORT(PyObject *) SWIG_Python_NewPointerObj(void *, swig_type_info *,int own);
65SWIGIMPORT(void *) SWIG_Python_MustGetPtr(PyObject *, swig_type_info *, int, int);
66SWIGIMPORT(PyObject *) SWIG_Python_newvarlink(void);
67SWIGIMPORT(void) SWIG_Python_addvarlink(PyObject *, char *, PyObject *(*)(void), int (*)(PyObject *));
68SWIGIMPORT(int) SWIG_Python_ConvertPacked(PyObject *, void *, int sz, swig_type_info *, int);
69SWIGIMPORT(PyObject *) SWIG_Python_NewPackedObj(void *, int sz, swig_type_info *);
70SWIGIMPORT(void) SWIG_Python_InstallConstants(PyObject *d, swig_const_info constants[]);
d14a1e28 71
d7f82584
RD
72/* -----------------------------------------------------------------------------
73 * the needed conversions between C++ and python
74 * ----------------------------------------------------------------------------- */
75/* basic types */
76/*
77 utilities
78*/
79SWIGIMPORT(char* ) SWIG_PyObj_AsCharPtr(PyObject *obj, swig_type_info* pchar_info);
80SWIGIMPORT(PyObject *) SWIG_PyObj_FromCharPtr(const char* cptr);
81SWIGIMPORT(unsigned long) SWIG_PyObj_AsUnsignedLong(PyObject * obj);
82SWIGIMPORT(long) SWIG_PyObj_AsLongInRange(PyObject * obj, const char* type,
83 long min_value, long max_value);
84SWIGIMPORT(unsigned long) SWIG_PyObj_AsUnsignedLongInRange(PyObject *obj, const char* type,
85 unsigned long max_value);
86SWIGIMPORT(char *) SWIG_PyObj_AsNewCharPtr(PyObject *obj, swig_type_info* pchar_info);
87SWIGIMPORT(void) SWIG_PyObj_AsCharPtrAndSize(PyObject *obj, swig_type_info* pchar_info,
88 char** cptr, size_t* size);
89SWIGIMPORT(void) SWIG_PyObj_AsCharArray(PyObject *obj, swig_type_info* pchar_info,
90 char* carray, size_t size);
91SWIGIMPORT(PyObject *) SWIG_PyObj_FromCharArray(const char* carray, size_t size);
92SWIGIMPORT(float) SWIG_PyObj_AsFloatConv(PyObject *obj, py_objasdbl_conv pyconv);
d14a1e28
RD
93
94
95/* Contract support */
96
11188b02 97#define SWIG_contract_assert(expr, msg) if (!(expr)) { PyErr_SetString(PyExc_RuntimeError, (char *) msg ); goto fail; } else
d14a1e28 98
d14a1e28
RD
99#ifdef __cplusplus
100}
101#endif
102