Added function __str__ to QString.
Note: You will need the latest versions of APIExtractor and Shiboken to be able to compile it.
This commit is contained in:
parent
9966943b66
commit
fe0a66367f
1 changed files with 7 additions and 0 deletions
|
|
@ -927,6 +927,13 @@
|
||||||
<modify-function signature="arg(uint, int, int, const QChar&) const" remove="all"/>
|
<modify-function signature="arg(uint, int, int, const QChar&) const" remove="all"/>
|
||||||
<modify-function signature="arg(ulong, int, int, const QChar&) const" remove="all"/>
|
<modify-function signature="arg(ulong, int, int, const QChar&) const" remove="all"/>
|
||||||
<modify-function signature="arg(ushort, int, int, const QChar&) const" remove="all"/>
|
<modify-function signature="arg(ushort, int, int, const QChar&) const" remove="all"/>
|
||||||
|
|
||||||
|
<add-function signature="__str__()" return-type="PyObject*">
|
||||||
|
<inject-code class="target" position="beginning">
|
||||||
|
QByteArray utf8 = %SELF.toUtf8();
|
||||||
|
%0 = PyUnicode_DecodeUTF8(utf8.data(), utf8.count(), 0);
|
||||||
|
</inject-code>
|
||||||
|
</add-function>
|
||||||
</value-type>
|
</value-type>
|
||||||
<value-type name="QLatin1String" />
|
<value-type name="QLatin1String" />
|
||||||
<value-type name="QStringRef">
|
<value-type name="QStringRef">
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue