From: Robin Dunn Date: Sat, 16 Apr 2005 05:56:07 +0000 (+0000) Subject: wxCharBuffer typemap X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/1110f5ced0fe6230b4021b3ac49bdf03f4b4a267 wxCharBuffer typemap git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@33643 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/wxPython/src/my_typemaps.i b/wxPython/src/my_typemaps.i index 19d2fe76f0..46d7bfb7d2 100644 --- a/wxPython/src/my_typemaps.i +++ b/wxPython/src/my_typemaps.i @@ -124,6 +124,11 @@ MAKE_INT_ARRAY_TYPEMAPS(styles, styles_field) +%typemap(out) wxCharBuffer { + $result = PyString_FromString((char*)$1.data()); +} + + //--------------------------------------------------------------------------- // Typemaps to convert Python sequence objects (tuples, etc.) to // wxSize, wxPoint, wxRealPoint, and wxRect.