Fix BUG #1091 - "PixmapFragment and drawPixmapFragments are not bound"
See http://bugs.pyside.org/show_bug.cgi?id=1091. Also minor coding style fixes in QtGui's typesystem. Signed-off-by: Paulo Alcantara <pcacjr@gmail.com> Reviewed-by: Marcelo Lira <marcelo.lira@openbossa.org>
This commit is contained in:
parent
481ba5aa3e
commit
b2b14fe9b7
4 changed files with 100 additions and 74 deletions
|
|
@ -15,7 +15,6 @@ if(ENABLE_X11)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
|
||||||
if (${QT_VERSION_MAJOR} EQUAL 4 AND ${QT_VERSION_MINOR} LESS 6)
|
if (${QT_VERSION_MAJOR} EQUAL 4 AND ${QT_VERSION_MINOR} LESS 6)
|
||||||
set(QtGui_46_SRC "")
|
set(QtGui_46_SRC "")
|
||||||
else()
|
else()
|
||||||
|
|
@ -60,6 +59,14 @@ else()
|
||||||
)
|
)
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
|
if (${QT_VERSION_MAJOR} EQUAL 4 AND ${QT_VERSION_MINOR} LESS 7)
|
||||||
|
set(QtGui_47_SRC "")
|
||||||
|
else()
|
||||||
|
set(QtGui_47_SRC
|
||||||
|
${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qpainter_pixmapfragment_wrapper.cpp
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
|
||||||
set(QtGui_OPTIONAL_SRC )
|
set(QtGui_OPTIONAL_SRC )
|
||||||
set(QtGui_DROPPED_ENTRIES )
|
set(QtGui_DROPPED_ENTRIES )
|
||||||
check_qt_class(QtGui QAbstractPageSetupDialog QtGui_OPTIONAL_SRC QtGui_DROPPED_ENTRIES)
|
check_qt_class(QtGui QAbstractPageSetupDialog QtGui_OPTIONAL_SRC QtGui_DROPPED_ENTRIES)
|
||||||
|
|
@ -398,6 +405,7 @@ ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtGui/qworkspace_wrapper.cpp
|
||||||
${SPECIFIC_OS_FILES}
|
${SPECIFIC_OS_FILES}
|
||||||
${QPYTEXTOBJECT_MOC}
|
${QPYTEXTOBJECT_MOC}
|
||||||
${QtGui_46_SRC}
|
${QtGui_46_SRC}
|
||||||
|
${QtGui_47_SRC}
|
||||||
${QtGui_OPTIONAL_SRC}
|
${QtGui_OPTIONAL_SRC}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -5425,6 +5425,9 @@
|
||||||
<enum-type name="CompositionMode"/>
|
<enum-type name="CompositionMode"/>
|
||||||
<enum-type name="PixmapFragmentHint" flags="PixmapFragmentHints" since="4.7"/>
|
<enum-type name="PixmapFragmentHint" flags="PixmapFragmentHints" since="4.7"/>
|
||||||
<enum-type name="RenderHint" flags="RenderHints"/>
|
<enum-type name="RenderHint" flags="RenderHints"/>
|
||||||
|
<value-type name="PixmapFragment" since="4.7">
|
||||||
|
<include file-name="QPainter" location="global"/>
|
||||||
|
</value-type>
|
||||||
|
|
||||||
<!-- ### "drawText(...)" is an internal method. -->
|
<!-- ### "drawText(...)" is an internal method. -->
|
||||||
<modify-function signature="drawText(const QPointF&, const QString&, int, int)" remove="all"/>
|
<modify-function signature="drawText(const QPointF&, const QString&, int, int)" remove="all"/>
|
||||||
|
|
|
||||||
|
|
@ -164,6 +164,9 @@ PYSIDE_TEST(virtual_protected_inheritance_test.py)
|
||||||
PYSIDE_TEST(virtual_pure_override_test.py)
|
PYSIDE_TEST(virtual_pure_override_test.py)
|
||||||
PYSIDE_TEST(wrong_return_test.py)
|
PYSIDE_TEST(wrong_return_test.py)
|
||||||
|
|
||||||
|
if (${QTVERSION} VERSION_GREATER 4.6.9)
|
||||||
|
PYSIDE_TEST(bug_1091.py)
|
||||||
|
endif()
|
||||||
|
|
||||||
if(Q_WS_X11)
|
if(Q_WS_X11)
|
||||||
PYSIDE_TEST(x11_symbols_test.py)
|
PYSIDE_TEST(x11_symbols_test.py)
|
||||||
|
|
|
||||||
12
tests/QtGui/bug_1091.py
Normal file
12
tests/QtGui/bug_1091.py
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
''' unit test for BUG #1091 '''
|
||||||
|
|
||||||
|
import unittest
|
||||||
|
from PySide import QtGui
|
||||||
|
|
||||||
|
class QPainterTestCase(unittest.TestCase):
|
||||||
|
def testIt(self):
|
||||||
|
self.assertTrue("PixmapFragment" in dir(QtGui.QPainter))
|
||||||
|
self.assertTrue("drawPixmapFragments" in dir(QtGui.QPainter))
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
unittest.main()
|
||||||
Loading…
Add table
Add a link
Reference in a new issue