##// END OF EJS Templates
Start Python 3.x Port...
Orochimarufan -
r206:316b4928f53f
parent child
Show More
@@ -1,139 +1,138
1 project(PythonQt)
1 project(PythonQt)
2 cmake_minimum_required(VERSION 2.8.10)
2 cmake_minimum_required(VERSION 2.8.10)
3
3
4 include(CTestUseLaunchers OPTIONAL)
4 include(CTestUseLaunchers OPTIONAL)
5
5
6 set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake ${CMAKE_MODULE_PATH})
6 set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake ${CMAKE_MODULE_PATH})
7
7
8 #-----------------------------------------------------------------------------
8 #-----------------------------------------------------------------------------
9 # Debug
9 # Debug
10 option(PythonQt_DEBUG "Enable/Disable PythonQt debug output" OFF)
10 option(PythonQt_DEBUG "Enable/Disable PythonQt debug output" OFF)
11 if(PythonQt_DEBUG)
11 if(PythonQt_DEBUG)
12 add_definitions(-DPYTHONQT_DEBUG)
12 add_definitions(-DPYTHONQT_DEBUG)
13 else()
13 else()
14 remove_definitions(-DPYTHONQT_DEBUG)
14 remove_definitions(-DPYTHONQT_DEBUG)
15 endif()
15 endif()
16
16
17 #-----------------------------------------------------------------------------
17 #-----------------------------------------------------------------------------
18 # Qt
18 # Qt
19 option(PythonQt_Qt5 "Use Qt 5.x (5.1+)" OFF)
19 option(PythonQt_Qt5 "Use Qt 5.x (5.1+)" OFF)
20 if(PythonQt_Qt5)
20 if(PythonQt_Qt5)
21 include(PythonQt_Qt_5x)
21 include(PythonQt_Qt_5x)
22 else(PythonQt_Qt5)
22 else(PythonQt_Qt5)
23 include(PythonQt_Qt_4x)
23 include(PythonQt_Qt_4x)
24 endif(PythonQt_Qt5)
24 endif(PythonQt_Qt5)
25
25
26 #-----------------------------------------------------------------------------
26 #-----------------------------------------------------------------------------
27 # The variable "generated_cpp_suffix" allows to conditionnally compile the generated wrappers
27 # The variable "generated_cpp_suffix" allows to conditionnally compile the generated wrappers
28 # associated with the Qt version being used.
28 # associated with the Qt version being used.
29 if(PythonQt_Qt5)
29 if(PythonQt_Qt5)
30 set(generated_cpp_suffix "_${Qt5Core_VERSION_MAJOR}${Qt5Core_VERSION_MINOR}")
30 set(generated_cpp_suffix "_${Qt5Core_VERSION_MAJOR}${Qt5Core_VERSION_MINOR}")
31 else()
31 else()
32 set(generated_cpp_suffix "_${QT_VERSION_MAJOR}${QT_VERSION_MINOR}")
32 set(generated_cpp_suffix "_${QT_VERSION_MAJOR}${QT_VERSION_MINOR}")
33 endif()
33 endif()
34
34
35 if("${generated_cpp_suffix}" STREQUAL "_48")
35 if("${generated_cpp_suffix}" STREQUAL "_48")
36 set(generated_cpp_suffix "")
36 set(generated_cpp_suffix "")
37 endif()
37 endif()
38 if("${generated_cpp_suffix}" STREQUAL "_46")
38 if("${generated_cpp_suffix}" STREQUAL "_46")
39 set(generated_cpp_suffix "_47") # Also use 4.7 wrappers for 4.6.x version
39 set(generated_cpp_suffix "_47") # Also use 4.7 wrappers for 4.6.x version
40 endif()
40 endif()
41 if("${generated_cpp_suffix}" STREQUAL "_51")
41 if("${generated_cpp_suffix}" STREQUAL "_51")
42 set(generated_cpp_suffix "_50")
42 set(generated_cpp_suffix "_50")
43 endif()
43 endif()
44
44
45 #-----------------------------------------------------------------------------
45 #-----------------------------------------------------------------------------
46 # Generator
46 # Generator
47 #if(PythonQt_Qt5)
47 if(PythonQt_Qt5)
48 # add_subdirectory(generator_50 EXCLUDE_FROM_ALL)
48 add_subdirectory(generator_50 EXCLUDE_FROM_ALL)
49 # add_custom_target(generator)
49 add_custom_target(generator)
50 # add_dependencies(generator pythonqt_generator)
50 add_dependencies(generator pythonqt_generator)
51 #endif()
51 endif()
52
52
53 # TODO
53 # TODO
54
54
55 #-----------------------------------------------------------------------------
55 #-----------------------------------------------------------------------------
56 # Build options
56 # Build options
57
57
58 #option(PythonQt_Wrap_QtAll "Make all Qt components available in python" OFF)
58 #option(PythonQt_Wrap_QtAll "Make all Qt components available in python" OFF)
59 #
59 #
60 #set(qtlibs core gui network opengl sql svg uitools webkit xml xmlpatterns)
60 #set(qtlibs core gui network opengl sql svg uitools webkit xml xmlpatterns)
61 #foreach(qtlib ${qtlibs})
61 #foreach(qtlib ${qtlibs})
62 # OPTION(PythonQt_Wrap_Qt${qtlib} "Make all of Qt${qtlib} available in python" OFF)
62 # OPTION(PythonQt_Wrap_Qt${qtlib} "Make all of Qt${qtlib} available in python" OFF)
63 #endforeach()
63 #endforeach()
64
64
65 # Force option if it applies
65 # Force option if it applies
66 #if(PythonQt_Wrap_QtAll)
66 #if(PythonQt_Wrap_QtAll)
67 # list(REMOVE_ITEM qtlibs xmlpatterns) # xmlpatterns wrapper does *NOT* build at all :(
67 # list(REMOVE_ITEM qtlibs xmlpatterns) # xmlpatterns wrapper does *NOT* build at all :(
68 # foreach(qtlib ${qtlibs})
68 # foreach(qtlib ${qtlibs})
69 # if(NOT ${PythonQt_Wrap_Qt${qtlib}})
69 # if(NOT ${PythonQt_Wrap_Qt${qtlib}})
70 # set(PythonQt_Wrap_Qt${qtlib} ON CACHE BOOL "Make all of Qt${qtlib} available in python" FORCE)
70 # set(PythonQt_Wrap_Qt${qtlib} ON CACHE BOOL "Make all of Qt${qtlib} available in python" FORCE)
71 # message(STATUS "Enabling [PythonQt_Wrap_Qt${qtlib}] because of [PythonQt_Wrap_QtAll] evaluates to True")
71 # message(STATUS "Enabling [PythonQt_Wrap_Qt${qtlib}] because of [PythonQt_Wrap_QtAll] evaluates to True")
72 # endif()
72 # endif()
73 # endforeach()
73 # endforeach()
74 #endif()
74 #endif()
75
75
76 #-----------------------------------------------------------------------------
76 #-----------------------------------------------------------------------------
77 # Add extra sources
77 # Add extra sources
78 #foreach(qtlib core gui network opengl sql svg uitools webkit xml xmlpatterns)
78 #foreach(qtlib core gui network opengl sql svg uitools webkit xml xmlpatterns)
79 #
79 #
80 # if (${PythonQt_Wrap_Qt${qtlib}})
80 # if (${PythonQt_Wrap_Qt${qtlib}})
81 #
81 #
82 # ADD_DEFINITIONS(-DPYTHONQT_WRAP_Qt${qtlib})
82 # ADD_DEFINITIONS(-DPYTHONQT_WRAP_Qt${qtlib})
83 #
83 #
84 # set(file_prefix generated_cpp${generated_cpp_suffix}/com_trolltech_qt_${qtlib}/com_trolltech_qt_${qtlib})
84 # set(file_prefix generated_cpp${generated_cpp_suffix}/com_trolltech_qt_${qtlib}/com_trolltech_qt_${qtlib})
85 #
85 #
86 # foreach(index RANGE 0 11)
86 # foreach(index RANGE 0 11)
87 #
87 #
88 # # Source files
88 # # Source files
89 # if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${file_prefix}${index}.cpp)
89 # if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${file_prefix}${index}.cpp)
90 # list(APPEND sources ${file_prefix}${index}.cpp)
90 # list(APPEND sources ${file_prefix}${index}.cpp)
91 # endif()
91 # endif()
92 #
92 #
93 # # Headers that should run through moc
93 # # Headers that should run through moc
94 # if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${file_prefix}${index}.h)
94 # if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${file_prefix}${index}.h)
95 # list(APPEND moc_sources ${file_prefix}${index}.h)
95 # list(APPEND moc_sources ${file_prefix}${index}.h)
96 # endif()
96 # endif()
97 #
97 #
98 # endforeach()
98 # endforeach()
99 #
99 #
100 # list(APPEND sources ${file_prefix}_init.cpp)
100 # list(APPEND sources ${file_prefix}_init.cpp)
101 #
101 #
102 # endif()
102 # endif()
103 #endforeach()
103 #endforeach()
104
104
105 #-----------------------------------------------------------------------------
105 #-----------------------------------------------------------------------------
106 # Find Python
106 # Find Python
107 option(PythonQt_Python3 "Use Python 3.x (3.3+)" OFF)
107 option(PythonQt_Python3 "Use Python 3.x (3.3+)" OFF)
108 if(PythonQt_Python3)
108 if(PythonQt_Python3)
109 set(PythonQt_PythonMin 3.3)
109 set(PythonQt_PythonMin 3.3)
110 add_definitions(PYTHON3K)
111 else(PythonQt_Python3)
110 else(PythonQt_Python3)
112 set(PythonQt_PythonMin 2.6)
111 set(PythonQt_PythonMin 2.6)
113 endif()
112 endif()
114
113
115 find_package(Python ${PythonQt_PythonMin} REQUIRED)
114 find_package(Python ${PythonQt_PythonMin} REQUIRED)
116 include_directories(${PYTHON_INCLUDE_DIRS})
115 include_directories(${PYTHON_INCLUDE_DIRS})
117 add_definitions(-DPYTHONQT_USE_RELEASE_PYTHON_FALLBACK)
116 add_definitions(-DPYTHONQT_USE_RELEASE_PYTHON_FALLBACK)
118
117
119 add_subdirectory(src)
118 add_subdirectory(src)
120
119
121 #-----------------------------------------------------------------------------
120 #-----------------------------------------------------------------------------
122 # Tests
121 # Tests
123 add_subdirectory(tests EXCLUDE_FROM_ALL)
122 add_subdirectory(tests EXCLUDE_FROM_ALL)
124 # test alias
123 # test alias
125 add_custom_target(test COMMAND tests/PythonQtTest WORKING_DIRECTORY ${CURRENT_BINARY_DIR})
124 add_custom_target(test COMMAND tests/PythonQtTest WORKING_DIRECTORY ${CURRENT_BINARY_DIR})
126 add_dependencies(test PythonQtTest)
125 add_dependencies(test PythonQtTest)
127
126
128 #-----------------------------------------------------------------------------
127 #-----------------------------------------------------------------------------
129 # Extenseions (QtAll)
128 # Extenseions (QtAll)
130 add_subdirectory(extensions EXCLUDE_FROM_ALL)
129 add_subdirectory(extensions EXCLUDE_FROM_ALL)
131 # QtAll alias
130 # QtAll alias
132 add_custom_target(QtAll)
131 add_custom_target(QtAll)
133 add_dependencies(QtAll PythonQt_QtAll)
132 add_dependencies(QtAll PythonQt_QtAll)
134
133
135 #-----------------------------------------------------------------------------
134 #-----------------------------------------------------------------------------
136 # Examples
135 # Examples
137 include_directories(src)
136 include_directories(src)
138 include_directories(extensions/PythonQt_QtAll)
137 include_directories(extensions/PythonQt_QtAll)
139 add_subdirectory(examples EXCLUDE_FROM_ALL)
138 add_subdirectory(examples EXCLUDE_FROM_ALL)
@@ -1,1063 +1,1067
1 #include <PythonQt.h>
1 #include <PythonQt.h>
2 #include <QDate>
2 #include <QDate>
3 #include <QGesture>
3 #include <QGesture>
4 #include <QNoImplicitBoolCast>
4 #include <QNoImplicitBoolCast>
5 #include <QObject>
5 #include <QObject>
6 #include <QStringList>
6 #include <QStringList>
7 #include <QTextDocument>
7 #include <QTextDocument>
8 #include <QVariant>
8 #include <QVariant>
9 #include <qbitarray.h>
9 #include <qbitarray.h>
10 #include <qbytearray.h>
10 #include <qbytearray.h>
11 #include <qdatetime.h>
11 #include <qdatetime.h>
12 #include <qlist.h>
12 #include <qlist.h>
13 #include <qlocale.h>
13 #include <qlocale.h>
14 #include <qmatrix.h>
14 #include <qmatrix.h>
15 #include <qmatrix4x4.h>
15 #include <qmatrix4x4.h>
16 #include <qnamespace.h>
16 #include <qnamespace.h>
17 #include <qpoint.h>
17 #include <qpoint.h>
18 #include <qrect.h>
18 #include <qrect.h>
19 #include <qregexp.h>
19 #include <qregexp.h>
20 #include <qsize.h>
20 #include <qsize.h>
21 #include <qstringlist.h>
21 #include <qstringlist.h>
22 #include <qtransform.h>
22 #include <qtransform.h>
23 #include <qurl.h>
23 #include <qurl.h>
24
24
25
25
26
26
27 class PythonQtWrapper_QBitArray : public QObject
27 class PythonQtWrapper_QBitArray : public QObject
28 { Q_OBJECT
28 { Q_OBJECT
29 public:
29 public:
30 public slots:
30 public slots:
31 QBitArray* new_QBitArray();
31 QBitArray* new_QBitArray();
32 QBitArray* new_QBitArray(const QBitArray& other);
32 QBitArray* new_QBitArray(const QBitArray& other);
33 QBitArray* new_QBitArray(int size, bool val = false);
33 QBitArray* new_QBitArray(int size, bool val = false);
34 void delete_QBitArray(QBitArray* obj) { delete obj; }
34 void delete_QBitArray(QBitArray* obj) { delete obj; }
35 bool at(QBitArray* theWrappedObject, int i) const;
35 bool at(QBitArray* theWrappedObject, int i) const;
36 void clear(QBitArray* theWrappedObject);
36 void clear(QBitArray* theWrappedObject);
37 void clearBit(QBitArray* theWrappedObject, int i);
37 void clearBit(QBitArray* theWrappedObject, int i);
38 int count(QBitArray* theWrappedObject) const;
38 int count(QBitArray* theWrappedObject) const;
39 int count(QBitArray* theWrappedObject, bool on) const;
39 int count(QBitArray* theWrappedObject, bool on) const;
40 void fill(QBitArray* theWrappedObject, bool val, int first, int last);
40 void fill(QBitArray* theWrappedObject, bool val, int first, int last);
41 bool fill(QBitArray* theWrappedObject, bool val, int size = -1);
41 bool fill(QBitArray* theWrappedObject, bool val, int size = -1);
42 bool isEmpty(QBitArray* theWrappedObject) const;
42 bool isEmpty(QBitArray* theWrappedObject) const;
43 bool isNull(QBitArray* theWrappedObject) const;
43 bool isNull(QBitArray* theWrappedObject) const;
44 bool __ne__(QBitArray* theWrappedObject, const QBitArray& other) const;
44 bool __ne__(QBitArray* theWrappedObject, const QBitArray& other) const;
45 QBitArray __and__(QBitArray* theWrappedObject, const QBitArray& arg__2);
45 QBitArray __and__(QBitArray* theWrappedObject, const QBitArray& arg__2);
46 QBitArray* __iand__(QBitArray* theWrappedObject, const QBitArray& arg__1);
46 QBitArray* __iand__(QBitArray* theWrappedObject, const QBitArray& arg__1);
47 QBitArray* operator_assign(QBitArray* theWrappedObject, const QBitArray& other);
47 QBitArray* operator_assign(QBitArray* theWrappedObject, const QBitArray& other);
48 bool __eq__(QBitArray* theWrappedObject, const QBitArray& other) const;
48 bool __eq__(QBitArray* theWrappedObject, const QBitArray& other) const;
49 QBitArray __xor__(QBitArray* theWrappedObject, const QBitArray& arg__2);
49 QBitArray __xor__(QBitArray* theWrappedObject, const QBitArray& arg__2);
50 QBitArray* __ixor__(QBitArray* theWrappedObject, const QBitArray& arg__1);
50 QBitArray* __ixor__(QBitArray* theWrappedObject, const QBitArray& arg__1);
51 QBitArray __or__(QBitArray* theWrappedObject, const QBitArray& arg__2);
51 QBitArray __or__(QBitArray* theWrappedObject, const QBitArray& arg__2);
52 QBitArray* __ior__(QBitArray* theWrappedObject, const QBitArray& arg__1);
52 QBitArray* __ior__(QBitArray* theWrappedObject, const QBitArray& arg__1);
53 QBitArray __invert__(QBitArray* theWrappedObject) const;
53 QBitArray __invert__(QBitArray* theWrappedObject) const;
54 void resize(QBitArray* theWrappedObject, int size);
54 void resize(QBitArray* theWrappedObject, int size);
55 void setBit(QBitArray* theWrappedObject, int i);
55 void setBit(QBitArray* theWrappedObject, int i);
56 void setBit(QBitArray* theWrappedObject, int i, bool val);
56 void setBit(QBitArray* theWrappedObject, int i, bool val);
57 int size(QBitArray* theWrappedObject) const;
57 int size(QBitArray* theWrappedObject) const;
58 void swap(QBitArray* theWrappedObject, QBitArray& other);
58 void swap(QBitArray* theWrappedObject, QBitArray& other);
59 bool testBit(QBitArray* theWrappedObject, int i) const;
59 bool testBit(QBitArray* theWrappedObject, int i) const;
60 bool toggleBit(QBitArray* theWrappedObject, int i);
60 bool toggleBit(QBitArray* theWrappedObject, int i);
61 void truncate(QBitArray* theWrappedObject, int pos);
61 void truncate(QBitArray* theWrappedObject, int pos);
62 QString py_toString(QBitArray*);
62 QString py_toString(QBitArray*);
63 bool __nonzero__(QBitArray* obj) { return !obj->isNull(); }
63 bool __nonzero__(QBitArray* obj) { return !obj->isNull(); }
64 };
64 };
65
65
66
66
67
67
68
68
69
69
70 class PythonQtWrapper_QByteArray : public QObject
70 class PythonQtWrapper_QByteArray : public QObject
71 { Q_OBJECT
71 { Q_OBJECT
72 public:
72 public:
73 public slots:
73 public slots:
74 QByteArray* new_QByteArray();
74 QByteArray* new_QByteArray();
75 QByteArray* new_QByteArray(const QByteArray& arg__1);
75 QByteArray* new_QByteArray(const QByteArray& arg__1);
76 QByteArray* new_QByteArray(int size, char c);
76 QByteArray* new_QByteArray(int size, char c);
77 void delete_QByteArray(QByteArray* obj) { delete obj; }
77 void delete_QByteArray(QByteArray* obj) { delete obj; }
78 QByteArray* append(QByteArray* theWrappedObject, char c);
78 QByteArray* append(QByteArray* theWrappedObject, char c);
79 QByteArray* append(QByteArray* theWrappedObject, const QByteArray& a);
79 QByteArray* append(QByteArray* theWrappedObject, const QByteArray& a);
80 QByteArray* append(QByteArray* theWrappedObject, const QString& s);
80 QByteArray* append(QByteArray* theWrappedObject, const QString& s);
81 QByteArray* append(QByteArray* theWrappedObject, const char* s, int len);
81 QByteArray* append(QByteArray* theWrappedObject, const char* s, int len);
82 char at(QByteArray* theWrappedObject, int i) const;
82 char at(QByteArray* theWrappedObject, int i) const;
83 int capacity(QByteArray* theWrappedObject) const;
83 int capacity(QByteArray* theWrappedObject) const;
84 const char* cbegin(QByteArray* theWrappedObject) const;
84 const char* cbegin(QByteArray* theWrappedObject) const;
85 const char* cend(QByteArray* theWrappedObject) const;
85 const char* cend(QByteArray* theWrappedObject) const;
86 void chop(QByteArray* theWrappedObject, int n);
86 void chop(QByteArray* theWrappedObject, int n);
87 void clear(QByteArray* theWrappedObject);
87 void clear(QByteArray* theWrappedObject);
88 int count(QByteArray* theWrappedObject, char c) const;
88 int count(QByteArray* theWrappedObject, char c) const;
89 int count(QByteArray* theWrappedObject, const QByteArray& a) const;
89 int count(QByteArray* theWrappedObject, const QByteArray& a) const;
90 bool endsWith(QByteArray* theWrappedObject, char c) const;
90 bool endsWith(QByteArray* theWrappedObject, char c) const;
91 bool endsWith(QByteArray* theWrappedObject, const QByteArray& a) const;
91 bool endsWith(QByteArray* theWrappedObject, const QByteArray& a) const;
92 QByteArray* fill(QByteArray* theWrappedObject, char c, int size = -1);
92 QByteArray* fill(QByteArray* theWrappedObject, char c, int size = -1);
93 QByteArray static_QByteArray_fromBase64(const QByteArray& base64);
93 QByteArray static_QByteArray_fromBase64(const QByteArray& base64);
94 QByteArray static_QByteArray_fromHex(const QByteArray& hexEncoded);
94 QByteArray static_QByteArray_fromHex(const QByteArray& hexEncoded);
95 QByteArray static_QByteArray_fromPercentEncoding(const QByteArray& pctEncoded, char percent = '%');
95 QByteArray static_QByteArray_fromPercentEncoding(const QByteArray& pctEncoded, char percent = '%');
96 int indexOf(QByteArray* theWrappedObject, char c, int from = 0) const;
96 int indexOf(QByteArray* theWrappedObject, char c, int from = 0) const;
97 int indexOf(QByteArray* theWrappedObject, const QByteArray& a, int from = 0) const;
97 int indexOf(QByteArray* theWrappedObject, const QByteArray& a, int from = 0) const;
98 int indexOf(QByteArray* theWrappedObject, const QString& s, int from = 0) const;
98 int indexOf(QByteArray* theWrappedObject, const QString& s, int from = 0) const;
99 QByteArray* insert(QByteArray* theWrappedObject, int i, char c);
99 QByteArray* insert(QByteArray* theWrappedObject, int i, char c);
100 QByteArray* insert(QByteArray* theWrappedObject, int i, const QByteArray& a);
100 QByteArray* insert(QByteArray* theWrappedObject, int i, const QByteArray& a);
101 QByteArray* insert(QByteArray* theWrappedObject, int i, const QString& s);
101 QByteArray* insert(QByteArray* theWrappedObject, int i, const QString& s);
102 QByteArray* insert(QByteArray* theWrappedObject, int i, const char* s, int len);
102 QByteArray* insert(QByteArray* theWrappedObject, int i, const char* s, int len);
103 bool isEmpty(QByteArray* theWrappedObject) const;
103 bool isEmpty(QByteArray* theWrappedObject) const;
104 bool isNull(QByteArray* theWrappedObject) const;
104 bool isNull(QByteArray* theWrappedObject) const;
105 bool isSharedWith(QByteArray* theWrappedObject, const QByteArray& other) const;
105 bool isSharedWith(QByteArray* theWrappedObject, const QByteArray& other) const;
106 int lastIndexOf(QByteArray* theWrappedObject, char c, int from = -1) const;
106 int lastIndexOf(QByteArray* theWrappedObject, char c, int from = -1) const;
107 int lastIndexOf(QByteArray* theWrappedObject, const QByteArray& a, int from = -1) const;
107 int lastIndexOf(QByteArray* theWrappedObject, const QByteArray& a, int from = -1) const;
108 int lastIndexOf(QByteArray* theWrappedObject, const QString& s, int from = -1) const;
108 int lastIndexOf(QByteArray* theWrappedObject, const QString& s, int from = -1) const;
109 QByteArray left(QByteArray* theWrappedObject, int len) const;
109 QByteArray left(QByteArray* theWrappedObject, int len) const;
110 QByteArray leftJustified(QByteArray* theWrappedObject, int width, char fill = ' ', bool truncate = false) const;
110 QByteArray leftJustified(QByteArray* theWrappedObject, int width, char fill = ' ', bool truncate = false) const;
111 int length(QByteArray* theWrappedObject) const;
111 int length(QByteArray* theWrappedObject) const;
112 QByteArray mid(QByteArray* theWrappedObject, int index, int len = -1) const;
112 QByteArray mid(QByteArray* theWrappedObject, int index, int len = -1) const;
113 QByteArray static_QByteArray_number(double arg__1, char f = 'g', int prec = 6);
113 QByteArray static_QByteArray_number(double arg__1, char f = 'g', int prec = 6);
114 QByteArray static_QByteArray_number(int arg__1, int base = 10);
114 QByteArray static_QByteArray_number(int arg__1, int base = 10);
115 QByteArray static_QByteArray_number(qlonglong arg__1, int base = 10);
115 QByteArray static_QByteArray_number(qlonglong arg__1, int base = 10);
116 bool __ne__(QByteArray* theWrappedObject, const QString& s2) const;
116 bool __ne__(QByteArray* theWrappedObject, const QString& s2) const;
117 const QByteArray __add__(QByteArray* theWrappedObject, char a2);
117 const QByteArray __add__(QByteArray* theWrappedObject, char a2);
118 const QByteArray __add__(QByteArray* theWrappedObject, const QByteArray& a2);
118 const QByteArray __add__(QByteArray* theWrappedObject, const QByteArray& a2);
119 const QString __add__(QByteArray* theWrappedObject, const QString& s);
119 const QString __add__(QByteArray* theWrappedObject, const QString& s);
120 const QByteArray __add__(QByteArray* theWrappedObject, const char* a2);
120 const QByteArray __add__(QByteArray* theWrappedObject, const char* a2);
121 bool __lt__(QByteArray* theWrappedObject, const QByteArray& a2);
121 bool __lt__(QByteArray* theWrappedObject, const QByteArray& a2);
122 bool __lt__(QByteArray* theWrappedObject, const QString& s2) const;
122 bool __lt__(QByteArray* theWrappedObject, const QString& s2) const;
123 bool __le__(QByteArray* theWrappedObject, const QByteArray& a2);
123 bool __le__(QByteArray* theWrappedObject, const QByteArray& a2);
124 bool __le__(QByteArray* theWrappedObject, const QString& s2) const;
124 bool __le__(QByteArray* theWrappedObject, const QString& s2) const;
125 QByteArray* operator_assign(QByteArray* theWrappedObject, const QByteArray& arg__1);
125 QByteArray* operator_assign(QByteArray* theWrappedObject, const QByteArray& arg__1);
126 bool __eq__(QByteArray* theWrappedObject, const QByteArray& a2);
126 bool __eq__(QByteArray* theWrappedObject, const QByteArray& a2);
127 bool __eq__(QByteArray* theWrappedObject, const QString& s2) const;
127 bool __eq__(QByteArray* theWrappedObject, const QString& s2) const;
128 bool __gt__(QByteArray* theWrappedObject, const QByteArray& a2);
128 bool __gt__(QByteArray* theWrappedObject, const QByteArray& a2);
129 bool __gt__(QByteArray* theWrappedObject, const QString& s2) const;
129 bool __gt__(QByteArray* theWrappedObject, const QString& s2) const;
130 bool __ge__(QByteArray* theWrappedObject, const QByteArray& a2);
130 bool __ge__(QByteArray* theWrappedObject, const QByteArray& a2);
131 bool __ge__(QByteArray* theWrappedObject, const QString& s2) const;
131 bool __ge__(QByteArray* theWrappedObject, const QString& s2) const;
132 QByteArray* prepend(QByteArray* theWrappedObject, char c);
132 QByteArray* prepend(QByteArray* theWrappedObject, char c);
133 QByteArray* prepend(QByteArray* theWrappedObject, const QByteArray& a);
133 QByteArray* prepend(QByteArray* theWrappedObject, const QByteArray& a);
134 QByteArray* prepend(QByteArray* theWrappedObject, const char* s, int len);
134 QByteArray* prepend(QByteArray* theWrappedObject, const char* s, int len);
135 QByteArray* remove(QByteArray* theWrappedObject, int index, int len);
135 QByteArray* remove(QByteArray* theWrappedObject, int index, int len);
136 QByteArray repeated(QByteArray* theWrappedObject, int times) const;
136 QByteArray repeated(QByteArray* theWrappedObject, int times) const;
137 QByteArray* replace(QByteArray* theWrappedObject, char before, char after);
137 QByteArray* replace(QByteArray* theWrappedObject, char before, char after);
138 QByteArray* replace(QByteArray* theWrappedObject, char before, const QByteArray& after);
138 QByteArray* replace(QByteArray* theWrappedObject, char before, const QByteArray& after);
139 QByteArray* replace(QByteArray* theWrappedObject, char c, const QString& after);
139 QByteArray* replace(QByteArray* theWrappedObject, char c, const QString& after);
140 QByteArray* replace(QByteArray* theWrappedObject, const QByteArray& before, const QByteArray& after);
140 QByteArray* replace(QByteArray* theWrappedObject, const QByteArray& before, const QByteArray& after);
141 QByteArray* replace(QByteArray* theWrappedObject, const QString& before, const QByteArray& after);
141 QByteArray* replace(QByteArray* theWrappedObject, const QString& before, const QByteArray& after);
142 QByteArray* replace(QByteArray* theWrappedObject, const char* before, int bsize, const char* after, int asize);
142 QByteArray* replace(QByteArray* theWrappedObject, const char* before, int bsize, const char* after, int asize);
143 QByteArray* replace(QByteArray* theWrappedObject, int index, int len, const QByteArray& s);
143 QByteArray* replace(QByteArray* theWrappedObject, int index, int len, const QByteArray& s);
144 QByteArray* replace(QByteArray* theWrappedObject, int index, int len, const char* s, int alen);
144 QByteArray* replace(QByteArray* theWrappedObject, int index, int len, const char* s, int alen);
145 void reserve(QByteArray* theWrappedObject, int size);
145 void reserve(QByteArray* theWrappedObject, int size);
146 void resize(QByteArray* theWrappedObject, int size);
146 void resize(QByteArray* theWrappedObject, int size);
147 QByteArray right(QByteArray* theWrappedObject, int len) const;
147 QByteArray right(QByteArray* theWrappedObject, int len) const;
148 QByteArray rightJustified(QByteArray* theWrappedObject, int width, char fill = ' ', bool truncate = false) const;
148 QByteArray rightJustified(QByteArray* theWrappedObject, int width, char fill = ' ', bool truncate = false) const;
149 QByteArray* setNum(QByteArray* theWrappedObject, double arg__1, char f = 'g', int prec = 6);
149 QByteArray* setNum(QByteArray* theWrappedObject, double arg__1, char f = 'g', int prec = 6);
150 QByteArray* setNum(QByteArray* theWrappedObject, float arg__1, char f = 'g', int prec = 6);
150 QByteArray* setNum(QByteArray* theWrappedObject, float arg__1, char f = 'g', int prec = 6);
151 QByteArray* setNum(QByteArray* theWrappedObject, int arg__1, int base = 10);
151 QByteArray* setNum(QByteArray* theWrappedObject, int arg__1, int base = 10);
152 QByteArray* setNum(QByteArray* theWrappedObject, qlonglong arg__1, int base = 10);
152 QByteArray* setNum(QByteArray* theWrappedObject, qlonglong arg__1, int base = 10);
153 QByteArray* setNum(QByteArray* theWrappedObject, short arg__1, int base = 10);
153 QByteArray* setNum(QByteArray* theWrappedObject, short arg__1, int base = 10);
154 QByteArray* setRawData(QByteArray* theWrappedObject, const char* a, uint n);
154 QByteArray* setRawData(QByteArray* theWrappedObject, const char* a, uint n);
155 QByteArray simplified(QByteArray* theWrappedObject) const;
155 QByteArray simplified(QByteArray* theWrappedObject) const;
156 int size(QByteArray* theWrappedObject) const;
156 int size(QByteArray* theWrappedObject) const;
157 QList<QByteArray > split(QByteArray* theWrappedObject, char sep) const;
157 QList<QByteArray > split(QByteArray* theWrappedObject, char sep) const;
158 void squeeze(QByteArray* theWrappedObject);
158 void squeeze(QByteArray* theWrappedObject);
159 bool startsWith(QByteArray* theWrappedObject, char c) const;
159 bool startsWith(QByteArray* theWrappedObject, char c) const;
160 bool startsWith(QByteArray* theWrappedObject, const QByteArray& a) const;
160 bool startsWith(QByteArray* theWrappedObject, const QByteArray& a) const;
161 void swap(QByteArray* theWrappedObject, QByteArray& other);
161 void swap(QByteArray* theWrappedObject, QByteArray& other);
162 QByteArray toBase64(QByteArray* theWrappedObject) const;
162 QByteArray toBase64(QByteArray* theWrappedObject) const;
163 double toDouble(QByteArray* theWrappedObject, bool* ok = 0) const;
163 double toDouble(QByteArray* theWrappedObject, bool* ok = 0) const;
164 float toFloat(QByteArray* theWrappedObject, bool* ok = 0) const;
164 float toFloat(QByteArray* theWrappedObject, bool* ok = 0) const;
165 QByteArray toHex(QByteArray* theWrappedObject) const;
165 QByteArray toHex(QByteArray* theWrappedObject) const;
166 int toInt(QByteArray* theWrappedObject, bool* ok = 0, int base = 10) const;
166 int toInt(QByteArray* theWrappedObject, bool* ok = 0, int base = 10) const;
167 QByteArray toLower(QByteArray* theWrappedObject) const;
167 QByteArray toLower(QByteArray* theWrappedObject) const;
168 QByteArray toPercentEncoding(QByteArray* theWrappedObject, const QByteArray& exclude = QByteArray(), const QByteArray& include = QByteArray(), char percent = '%') const;
168 QByteArray toPercentEncoding(QByteArray* theWrappedObject, const QByteArray& exclude = QByteArray(), const QByteArray& include = QByteArray(), char percent = '%') const;
169 ushort toUShort(QByteArray* theWrappedObject, bool* ok = 0, int base = 10) const;
169 ushort toUShort(QByteArray* theWrappedObject, bool* ok = 0, int base = 10) const;
170 QByteArray toUpper(QByteArray* theWrappedObject) const;
170 QByteArray toUpper(QByteArray* theWrappedObject) const;
171 QByteArray trimmed(QByteArray* theWrappedObject) const;
171 QByteArray trimmed(QByteArray* theWrappedObject) const;
172 void truncate(QByteArray* theWrappedObject, int pos);
172 void truncate(QByteArray* theWrappedObject, int pos);
173 bool __nonzero__(QByteArray* obj) { return !obj->isNull(); }
173 bool __nonzero__(QByteArray* obj) { return !obj->isNull(); }
174
174
175 PyObject* data(QByteArray* b) {
175 PyObject* data(QByteArray* b) {
176 if (b->data()) {
176 if (b->data()) {
177 #ifdef PY3K
178 return PyUnicode_FromStringAndSize(b->data(), b->size());
179 #else
177 return PyString_FromStringAndSize(b->data(), b->size());
180 return PyString_FromStringAndSize(b->data(), b->size());
181 #endif
178 } else {
182 } else {
179 Py_INCREF(Py_None);
183 Py_INCREF(Py_None);
180 return Py_None;
184 return Py_None;
181 }
185 }
182 }
186 }
183
187
184 };
188 };
185
189
186
190
187
191
188
192
189
193
190 class PythonQtWrapper_QDate : public QObject
194 class PythonQtWrapper_QDate : public QObject
191 { Q_OBJECT
195 { Q_OBJECT
192 public:
196 public:
193 Q_ENUMS(MonthNameType )
197 Q_ENUMS(MonthNameType )
194 enum MonthNameType{
198 enum MonthNameType{
195 DateFormat = QDate::DateFormat, StandaloneFormat = QDate::StandaloneFormat};
199 DateFormat = QDate::DateFormat, StandaloneFormat = QDate::StandaloneFormat};
196 public slots:
200 public slots:
197 QDate* new_QDate();
201 QDate* new_QDate();
198 QDate* new_QDate(int y, int m, int d);
202 QDate* new_QDate(int y, int m, int d);
199 QDate* new_QDate(const QDate& other) {
203 QDate* new_QDate(const QDate& other) {
200 QDate* a = new QDate();
204 QDate* a = new QDate();
201 *((QDate*)a) = other;
205 *((QDate*)a) = other;
202 return a; }
206 return a; }
203 void delete_QDate(QDate* obj) { delete obj; }
207 void delete_QDate(QDate* obj) { delete obj; }
204 QDate addDays(QDate* theWrappedObject, qint64 days) const;
208 QDate addDays(QDate* theWrappedObject, qint64 days) const;
205 QDate addMonths(QDate* theWrappedObject, int months) const;
209 QDate addMonths(QDate* theWrappedObject, int months) const;
206 QDate addYears(QDate* theWrappedObject, int years) const;
210 QDate addYears(QDate* theWrappedObject, int years) const;
207 QDate static_QDate_currentDate();
211 QDate static_QDate_currentDate();
208 int day(QDate* theWrappedObject) const;
212 int day(QDate* theWrappedObject) const;
209 int dayOfWeek(QDate* theWrappedObject) const;
213 int dayOfWeek(QDate* theWrappedObject) const;
210 int dayOfYear(QDate* theWrappedObject) const;
214 int dayOfYear(QDate* theWrappedObject) const;
211 int daysInMonth(QDate* theWrappedObject) const;
215 int daysInMonth(QDate* theWrappedObject) const;
212 int daysInYear(QDate* theWrappedObject) const;
216 int daysInYear(QDate* theWrappedObject) const;
213 qint64 daysTo(QDate* theWrappedObject, const QDate& arg__1) const;
217 qint64 daysTo(QDate* theWrappedObject, const QDate& arg__1) const;
214 QDate static_QDate_fromJulianDay(qint64 jd);
218 QDate static_QDate_fromJulianDay(qint64 jd);
215 QDate static_QDate_fromString(const QString& s, Qt::DateFormat f = Qt::TextDate);
219 QDate static_QDate_fromString(const QString& s, Qt::DateFormat f = Qt::TextDate);
216 QDate static_QDate_fromString(const QString& s, const QString& format);
220 QDate static_QDate_fromString(const QString& s, const QString& format);
217 void getDate(QDate* theWrappedObject, int* year, int* month, int* day);
221 void getDate(QDate* theWrappedObject, int* year, int* month, int* day);
218 bool static_QDate_isLeapYear(int year);
222 bool static_QDate_isLeapYear(int year);
219 bool isNull(QDate* theWrappedObject) const;
223 bool isNull(QDate* theWrappedObject) const;
220 bool isValid(QDate* theWrappedObject) const;
224 bool isValid(QDate* theWrappedObject) const;
221 bool static_QDate_isValid(int y, int m, int d);
225 bool static_QDate_isValid(int y, int m, int d);
222 QString static_QDate_longDayName(int weekday, QDate::MonthNameType type = QDate::DateFormat);
226 QString static_QDate_longDayName(int weekday, QDate::MonthNameType type = QDate::DateFormat);
223 QString static_QDate_longMonthName(int month, QDate::MonthNameType type = QDate::DateFormat);
227 QString static_QDate_longMonthName(int month, QDate::MonthNameType type = QDate::DateFormat);
224 int month(QDate* theWrappedObject) const;
228 int month(QDate* theWrappedObject) const;
225 bool __ne__(QDate* theWrappedObject, const QDate& other) const;
229 bool __ne__(QDate* theWrappedObject, const QDate& other) const;
226 bool __lt__(QDate* theWrappedObject, const QDate& other) const;
230 bool __lt__(QDate* theWrappedObject, const QDate& other) const;
227 bool __le__(QDate* theWrappedObject, const QDate& other) const;
231 bool __le__(QDate* theWrappedObject, const QDate& other) const;
228 bool __eq__(QDate* theWrappedObject, const QDate& other) const;
232 bool __eq__(QDate* theWrappedObject, const QDate& other) const;
229 bool __gt__(QDate* theWrappedObject, const QDate& other) const;
233 bool __gt__(QDate* theWrappedObject, const QDate& other) const;
230 bool __ge__(QDate* theWrappedObject, const QDate& other) const;
234 bool __ge__(QDate* theWrappedObject, const QDate& other) const;
231 bool setDate(QDate* theWrappedObject, int year, int month, int day);
235 bool setDate(QDate* theWrappedObject, int year, int month, int day);
232 QString static_QDate_shortDayName(int weekday, QDate::MonthNameType type = QDate::DateFormat);
236 QString static_QDate_shortDayName(int weekday, QDate::MonthNameType type = QDate::DateFormat);
233 QString static_QDate_shortMonthName(int month, QDate::MonthNameType type = QDate::DateFormat);
237 QString static_QDate_shortMonthName(int month, QDate::MonthNameType type = QDate::DateFormat);
234 qint64 toJulianDay(QDate* theWrappedObject) const;
238 qint64 toJulianDay(QDate* theWrappedObject) const;
235 QString toString(QDate* theWrappedObject, Qt::DateFormat f = Qt::TextDate) const;
239 QString toString(QDate* theWrappedObject, Qt::DateFormat f = Qt::TextDate) const;
236 QString toString(QDate* theWrappedObject, const QString& format) const;
240 QString toString(QDate* theWrappedObject, const QString& format) const;
237 int weekNumber(QDate* theWrappedObject, int* yearNum = 0) const;
241 int weekNumber(QDate* theWrappedObject, int* yearNum = 0) const;
238 int year(QDate* theWrappedObject) const;
242 int year(QDate* theWrappedObject) const;
239 QString py_toString(QDate*);
243 QString py_toString(QDate*);
240 bool __nonzero__(QDate* obj) { return !obj->isNull(); }
244 bool __nonzero__(QDate* obj) { return !obj->isNull(); }
241 };
245 };
242
246
243
247
244
248
245
249
246
250
247 class PythonQtWrapper_QDateTime : public QObject
251 class PythonQtWrapper_QDateTime : public QObject
248 { Q_OBJECT
252 { Q_OBJECT
249 public:
253 public:
250 public slots:
254 public slots:
251 QDateTime* new_QDateTime();
255 QDateTime* new_QDateTime();
252 QDateTime* new_QDateTime(const QDate& arg__1);
256 QDateTime* new_QDateTime(const QDate& arg__1);
253 QDateTime* new_QDateTime(const QDate& arg__1, const QTime& arg__2, Qt::TimeSpec spec = Qt::LocalTime);
257 QDateTime* new_QDateTime(const QDate& arg__1, const QTime& arg__2, Qt::TimeSpec spec = Qt::LocalTime);
254 QDateTime* new_QDateTime(const QDateTime& other);
258 QDateTime* new_QDateTime(const QDateTime& other);
255 void delete_QDateTime(QDateTime* obj) { delete obj; }
259 void delete_QDateTime(QDateTime* obj) { delete obj; }
256 QDateTime addDays(QDateTime* theWrappedObject, qint64 days) const;
260 QDateTime addDays(QDateTime* theWrappedObject, qint64 days) const;
257 QDateTime addMSecs(QDateTime* theWrappedObject, qint64 msecs) const;
261 QDateTime addMSecs(QDateTime* theWrappedObject, qint64 msecs) const;
258 QDateTime addMonths(QDateTime* theWrappedObject, int months) const;
262 QDateTime addMonths(QDateTime* theWrappedObject, int months) const;
259 QDateTime addSecs(QDateTime* theWrappedObject, qint64 secs) const;
263 QDateTime addSecs(QDateTime* theWrappedObject, qint64 secs) const;
260 QDateTime addYears(QDateTime* theWrappedObject, int years) const;
264 QDateTime addYears(QDateTime* theWrappedObject, int years) const;
261 QDateTime static_QDateTime_currentDateTime();
265 QDateTime static_QDateTime_currentDateTime();
262 QDateTime static_QDateTime_currentDateTimeUtc();
266 QDateTime static_QDateTime_currentDateTimeUtc();
263 qint64 static_QDateTime_currentMSecsSinceEpoch();
267 qint64 static_QDateTime_currentMSecsSinceEpoch();
264 QDate date(QDateTime* theWrappedObject) const;
268 QDate date(QDateTime* theWrappedObject) const;
265 qint64 daysTo(QDateTime* theWrappedObject, const QDateTime& arg__1) const;
269 qint64 daysTo(QDateTime* theWrappedObject, const QDateTime& arg__1) const;
266 QDateTime static_QDateTime_fromMSecsSinceEpoch(qint64 msecs);
270 QDateTime static_QDateTime_fromMSecsSinceEpoch(qint64 msecs);
267 QDateTime static_QDateTime_fromString(const QString& s, Qt::DateFormat f = Qt::TextDate);
271 QDateTime static_QDateTime_fromString(const QString& s, Qt::DateFormat f = Qt::TextDate);
268 QDateTime static_QDateTime_fromString(const QString& s, const QString& format);
272 QDateTime static_QDateTime_fromString(const QString& s, const QString& format);
269 QDateTime static_QDateTime_fromTime_t(uint secsSince1Jan1970UTC);
273 QDateTime static_QDateTime_fromTime_t(uint secsSince1Jan1970UTC);
270 bool isNull(QDateTime* theWrappedObject) const;
274 bool isNull(QDateTime* theWrappedObject) const;
271 bool isValid(QDateTime* theWrappedObject) const;
275 bool isValid(QDateTime* theWrappedObject) const;
272 qint64 msecsTo(QDateTime* theWrappedObject, const QDateTime& arg__1) const;
276 qint64 msecsTo(QDateTime* theWrappedObject, const QDateTime& arg__1) const;
273 bool __ne__(QDateTime* theWrappedObject, const QDateTime& other) const;
277 bool __ne__(QDateTime* theWrappedObject, const QDateTime& other) const;
274 bool __lt__(QDateTime* theWrappedObject, const QDateTime& other) const;
278 bool __lt__(QDateTime* theWrappedObject, const QDateTime& other) const;
275 bool __le__(QDateTime* theWrappedObject, const QDateTime& other) const;
279 bool __le__(QDateTime* theWrappedObject, const QDateTime& other) const;
276 bool __eq__(QDateTime* theWrappedObject, const QDateTime& other) const;
280 bool __eq__(QDateTime* theWrappedObject, const QDateTime& other) const;
277 bool __gt__(QDateTime* theWrappedObject, const QDateTime& other) const;
281 bool __gt__(QDateTime* theWrappedObject, const QDateTime& other) const;
278 bool __ge__(QDateTime* theWrappedObject, const QDateTime& other) const;
282 bool __ge__(QDateTime* theWrappedObject, const QDateTime& other) const;
279 qint64 secsTo(QDateTime* theWrappedObject, const QDateTime& arg__1) const;
283 qint64 secsTo(QDateTime* theWrappedObject, const QDateTime& arg__1) const;
280 void setDate(QDateTime* theWrappedObject, const QDate& date);
284 void setDate(QDateTime* theWrappedObject, const QDate& date);
281 void setMSecsSinceEpoch(QDateTime* theWrappedObject, qint64 msecs);
285 void setMSecsSinceEpoch(QDateTime* theWrappedObject, qint64 msecs);
282 void setTime(QDateTime* theWrappedObject, const QTime& time);
286 void setTime(QDateTime* theWrappedObject, const QTime& time);
283 void setTimeSpec(QDateTime* theWrappedObject, Qt::TimeSpec spec);
287 void setTimeSpec(QDateTime* theWrappedObject, Qt::TimeSpec spec);
284 void setTime_t(QDateTime* theWrappedObject, uint secsSince1Jan1970UTC);
288 void setTime_t(QDateTime* theWrappedObject, uint secsSince1Jan1970UTC);
285 void setUtcOffset(QDateTime* theWrappedObject, int seconds);
289 void setUtcOffset(QDateTime* theWrappedObject, int seconds);
286 void swap(QDateTime* theWrappedObject, QDateTime& other);
290 void swap(QDateTime* theWrappedObject, QDateTime& other);
287 QTime time(QDateTime* theWrappedObject) const;
291 QTime time(QDateTime* theWrappedObject) const;
288 Qt::TimeSpec timeSpec(QDateTime* theWrappedObject) const;
292 Qt::TimeSpec timeSpec(QDateTime* theWrappedObject) const;
289 QDateTime toLocalTime(QDateTime* theWrappedObject) const;
293 QDateTime toLocalTime(QDateTime* theWrappedObject) const;
290 qint64 toMSecsSinceEpoch(QDateTime* theWrappedObject) const;
294 qint64 toMSecsSinceEpoch(QDateTime* theWrappedObject) const;
291 QString toString(QDateTime* theWrappedObject, Qt::DateFormat f = Qt::TextDate) const;
295 QString toString(QDateTime* theWrappedObject, Qt::DateFormat f = Qt::TextDate) const;
292 QString toString(QDateTime* theWrappedObject, const QString& format) const;
296 QString toString(QDateTime* theWrappedObject, const QString& format) const;
293 QDateTime toTimeSpec(QDateTime* theWrappedObject, Qt::TimeSpec spec) const;
297 QDateTime toTimeSpec(QDateTime* theWrappedObject, Qt::TimeSpec spec) const;
294 uint toTime_t(QDateTime* theWrappedObject) const;
298 uint toTime_t(QDateTime* theWrappedObject) const;
295 QDateTime toUTC(QDateTime* theWrappedObject) const;
299 QDateTime toUTC(QDateTime* theWrappedObject) const;
296 int utcOffset(QDateTime* theWrappedObject) const;
300 int utcOffset(QDateTime* theWrappedObject) const;
297 QString py_toString(QDateTime*);
301 QString py_toString(QDateTime*);
298 bool __nonzero__(QDateTime* obj) { return !obj->isNull(); }
302 bool __nonzero__(QDateTime* obj) { return !obj->isNull(); }
299 };
303 };
300
304
301
305
302
306
303
307
304
308
305 class PythonQtWrapper_QLocale : public QObject
309 class PythonQtWrapper_QLocale : public QObject
306 { Q_OBJECT
310 { Q_OBJECT
307 public:
311 public:
308 Q_ENUMS(FormatType CurrencySymbolFormat QuotationStyle Language Script NumberOption Country MeasurementSystem )
312 Q_ENUMS(FormatType CurrencySymbolFormat QuotationStyle Language Script NumberOption Country MeasurementSystem )
309 Q_FLAGS(NumberOptions )
313 Q_FLAGS(NumberOptions )
310 enum FormatType{
314 enum FormatType{
311 LongFormat = QLocale::LongFormat, ShortFormat = QLocale::ShortFormat, NarrowFormat = QLocale::NarrowFormat};
315 LongFormat = QLocale::LongFormat, ShortFormat = QLocale::ShortFormat, NarrowFormat = QLocale::NarrowFormat};
312 enum CurrencySymbolFormat{
316 enum CurrencySymbolFormat{
313 CurrencyIsoCode = QLocale::CurrencyIsoCode, CurrencySymbol = QLocale::CurrencySymbol, CurrencyDisplayName = QLocale::CurrencyDisplayName};
317 CurrencyIsoCode = QLocale::CurrencyIsoCode, CurrencySymbol = QLocale::CurrencySymbol, CurrencyDisplayName = QLocale::CurrencyDisplayName};
314 enum QuotationStyle{
318 enum QuotationStyle{
315 StandardQuotation = QLocale::StandardQuotation, AlternateQuotation = QLocale::AlternateQuotation};
319 StandardQuotation = QLocale::StandardQuotation, AlternateQuotation = QLocale::AlternateQuotation};
316 enum Language{
320 enum Language{
317 AnyLanguage = QLocale::AnyLanguage, C = QLocale::C, Abkhazian = QLocale::Abkhazian, Oromo = QLocale::Oromo, Afar = QLocale::Afar, Afrikaans = QLocale::Afrikaans, Albanian = QLocale::Albanian, Amharic = QLocale::Amharic, Arabic = QLocale::Arabic, Armenian = QLocale::Armenian, Assamese = QLocale::Assamese, Aymara = QLocale::Aymara, Azerbaijani = QLocale::Azerbaijani, Bashkir = QLocale::Bashkir, Basque = QLocale::Basque, Bengali = QLocale::Bengali, Dzongkha = QLocale::Dzongkha, Bihari = QLocale::Bihari, Bislama = QLocale::Bislama, Breton = QLocale::Breton, Bulgarian = QLocale::Bulgarian, Burmese = QLocale::Burmese, Belarusian = QLocale::Belarusian, Khmer = QLocale::Khmer, Catalan = QLocale::Catalan, Chinese = QLocale::Chinese, Corsican = QLocale::Corsican, Croatian = QLocale::Croatian, Czech = QLocale::Czech, Danish = QLocale::Danish, Dutch = QLocale::Dutch, English = QLocale::English, Esperanto = QLocale::Esperanto, Estonian = QLocale::Estonian, Faroese = QLocale::Faroese, Fijian = QLocale::Fijian, Finnish = QLocale::Finnish, French = QLocale::French, WesternFrisian = QLocale::WesternFrisian, Gaelic = QLocale::Gaelic, Galician = QLocale::Galician, Georgian = QLocale::Georgian, German = QLocale::German, Greek = QLocale::Greek, Greenlandic = QLocale::Greenlandic, Guarani = QLocale::Guarani, Gujarati = QLocale::Gujarati, Hausa = QLocale::Hausa, Hebrew = QLocale::Hebrew, Hindi = QLocale::Hindi, Hungarian = QLocale::Hungarian, Icelandic = QLocale::Icelandic, Indonesian = QLocale::Indonesian, Interlingua = QLocale::Interlingua, Interlingue = QLocale::Interlingue, Inuktitut = QLocale::Inuktitut, Inupiak = QLocale::Inupiak, Irish = QLocale::Irish, Italian = QLocale::Italian, Japanese = QLocale::Japanese, Javanese = QLocale::Javanese, Kannada = QLocale::Kannada, Kashmiri = QLocale::Kashmiri, Kazakh = QLocale::Kazakh, Kinyarwanda = QLocale::Kinyarwanda, Kirghiz = QLocale::Kirghiz, Korean = QLocale::Korean, Kurdish = QLocale::Kurdish, Rundi = QLocale::Rundi, Lao = QLocale::Lao, Latin = QLocale::Latin, Latvian = QLocale::Latvian, Lingala = QLocale::Lingala, Lithuanian = QLocale::Lithuanian, Macedonian = QLocale::Macedonian, Malagasy = QLocale::Malagasy, Malay = QLocale::Malay, Malayalam = QLocale::Malayalam, Maltese = QLocale::Maltese, Maori = QLocale::Maori, Marathi = QLocale::Marathi, Marshallese = QLocale::Marshallese, Mongolian = QLocale::Mongolian, NauruLanguage = QLocale::NauruLanguage, Nepali = QLocale::Nepali, NorwegianBokmal = QLocale::NorwegianBokmal, Occitan = QLocale::Occitan, Oriya = QLocale::Oriya, Pashto = QLocale::Pashto, Persian = QLocale::Persian, Polish = QLocale::Polish, Portuguese = QLocale::Portuguese, Punjabi = QLocale::Punjabi, Quechua = QLocale::Quechua, Romansh = QLocale::Romansh, Romanian = QLocale::Romanian, Russian = QLocale::Russian, Samoan = QLocale::Samoan, Sango = QLocale::Sango, Sanskrit = QLocale::Sanskrit, Serbian = QLocale::Serbian, Ossetic = QLocale::Ossetic, SouthernSotho = QLocale::SouthernSotho, Tswana = QLocale::Tswana, Shona = QLocale::Shona, Sindhi = QLocale::Sindhi, Sinhala = QLocale::Sinhala, Swati = QLocale::Swati, Slovak = QLocale::Slovak, Slovenian = QLocale::Slovenian, Somali = QLocale::Somali, Spanish = QLocale::Spanish, Sundanese = QLocale::Sundanese, Swahili = QLocale::Swahili, Swedish = QLocale::Swedish, Sardinian = QLocale::Sardinian, Tajik = QLocale::Tajik, Tamil = QLocale::Tamil, Tatar = QLocale::Tatar, Telugu = QLocale::Telugu, Thai = QLocale::Thai, Tibetan = QLocale::Tibetan, Tigrinya = QLocale::Tigrinya, Tongan = QLocale::Tongan, Tsonga = QLocale::Tsonga, Turkish = QLocale::Turkish, Turkmen = QLocale::Turkmen, Tahitian = QLocale::Tahitian, Uigur = QLocale::Uigur, Ukrainian = QLocale::Ukrainian, Urdu = QLocale::Urdu, Uzbek = QLocale::Uzbek, Vietnamese = QLocale::Vietnamese, Volapuk = QLocale::Volapuk, Welsh = QLocale::Welsh, Wolof = QLocale::Wolof, Xhosa = QLocale::Xhosa, Yiddish = QLocale::Yiddish, Yoruba = QLocale::Yoruba, Zhuang = QLocale::Zhuang, Zulu = QLocale::Zulu, NorwegianNynorsk = QLocale::NorwegianNynorsk, Bosnian = QLocale::Bosnian, Divehi = QLocale::Divehi, Manx = QLocale::Manx, Cornish = QLocale::Cornish, Akan = QLocale::Akan, Konkani = QLocale::Konkani, Ga = QLocale::Ga, Igbo = QLocale::Igbo, Kamba = QLocale::Kamba, Syriac = QLocale::Syriac, Blin = QLocale::Blin, Geez = QLocale::Geez, Koro = QLocale::Koro, Sidamo = QLocale::Sidamo, Atsam = QLocale::Atsam, Tigre = QLocale::Tigre, Jju = QLocale::Jju, Friulian = QLocale::Friulian, Venda = QLocale::Venda, Ewe = QLocale::Ewe, Walamo = QLocale::Walamo, Hawaiian = QLocale::Hawaiian, Tyap = QLocale::Tyap, Nyanja = QLocale::Nyanja, Filipino = QLocale::Filipino, SwissGerman = QLocale::SwissGerman, SichuanYi = QLocale::SichuanYi, Kpelle = QLocale::Kpelle, LowGerman = QLocale::LowGerman, SouthNdebele = QLocale::SouthNdebele, NorthernSotho = QLocale::NorthernSotho, NorthernSami = QLocale::NorthernSami, Taroko = QLocale::Taroko, Gusii = QLocale::Gusii, Taita = QLocale::Taita, Fulah = QLocale::Fulah, Kikuyu = QLocale::Kikuyu, Samburu = QLocale::Samburu, Sena = QLocale::Sena, NorthNdebele = QLocale::NorthNdebele, Rombo = QLocale::Rombo, Tachelhit = QLocale::Tachelhit, Kabyle = QLocale::Kabyle, Nyankole = QLocale::Nyankole, Bena = QLocale::Bena, Vunjo = QLocale::Vunjo, Bambara = QLocale::Bambara, Embu = QLocale::Embu, Cherokee = QLocale::Cherokee, Morisyen = QLocale::Morisyen, Makonde = QLocale::Makonde, Langi = QLocale::Langi, Ganda = QLocale::Ganda, Bemba = QLocale::Bemba, Kabuverdianu = QLocale::Kabuverdianu, Meru = QLocale::Meru, Kalenjin = QLocale::Kalenjin, Nama = QLocale::Nama, Machame = QLocale::Machame, Colognian = QLocale::Colognian, Masai = QLocale::Masai, Soga = QLocale::Soga, Luyia = QLocale::Luyia, Asu = QLocale::Asu, Teso = QLocale::Teso, Saho = QLocale::Saho, KoyraChiini = QLocale::KoyraChiini, Rwa = QLocale::Rwa, Luo = QLocale::Luo, Chiga = QLocale::Chiga, CentralMoroccoTamazight = QLocale::CentralMoroccoTamazight, KoyraboroSenni = QLocale::KoyraboroSenni, Shambala = QLocale::Shambala, Bodo = QLocale::Bodo, Avaric = QLocale::Avaric, Chamorro = QLocale::Chamorro, Chechen = QLocale::Chechen, Church = QLocale::Church, Chuvash = QLocale::Chuvash, Cree = QLocale::Cree, Haitian = QLocale::Haitian, Herero = QLocale::Herero, HiriMotu = QLocale::HiriMotu, Kanuri = QLocale::Kanuri, Komi = QLocale::Komi, Kongo = QLocale::Kongo, Kwanyama = QLocale::Kwanyama, Limburgish = QLocale::Limburgish, LubaKatanga = QLocale::LubaKatanga, Luxembourgish = QLocale::Luxembourgish, Navaho = QLocale::Navaho, Ndonga = QLocale::Ndonga, Ojibwa = QLocale::Ojibwa, Pali = QLocale::Pali, Walloon = QLocale::Walloon, Aghem = QLocale::Aghem, Basaa = QLocale::Basaa, Zarma = QLocale::Zarma, Duala = QLocale::Duala, JolaFonyi = QLocale::JolaFonyi, Ewondo = QLocale::Ewondo, Bafia = QLocale::Bafia, MakhuwaMeetto = QLocale::MakhuwaMeetto, Mundang = QLocale::Mundang, Kwasio = QLocale::Kwasio, Nuer = QLocale::Nuer, Sakha = QLocale::Sakha, Sangu = QLocale::Sangu, CongoSwahili = QLocale::CongoSwahili, Tasawaq = QLocale::Tasawaq, Vai = QLocale::Vai, Walser = QLocale::Walser, Yangben = QLocale::Yangben, Avestan = QLocale::Avestan, Asturian = QLocale::Asturian, Ngomba = QLocale::Ngomba, Kako = QLocale::Kako, Meta = QLocale::Meta, Ngiemboon = QLocale::Ngiemboon, Norwegian = QLocale::Norwegian, Moldavian = QLocale::Moldavian, SerboCroatian = QLocale::SerboCroatian, Tagalog = QLocale::Tagalog, Twi = QLocale::Twi, Afan = QLocale::Afan, Byelorussian = QLocale::Byelorussian, Bhutani = QLocale::Bhutani, Cambodian = QLocale::Cambodian, Kurundi = QLocale::Kurundi, RhaetoRomance = QLocale::RhaetoRomance, Chewa = QLocale::Chewa, Frisian = QLocale::Frisian, LastLanguage = QLocale::LastLanguage};
321 AnyLanguage = QLocale::AnyLanguage, C = QLocale::C, Abkhazian = QLocale::Abkhazian, Oromo = QLocale::Oromo, Afar = QLocale::Afar, Afrikaans = QLocale::Afrikaans, Albanian = QLocale::Albanian, Amharic = QLocale::Amharic, Arabic = QLocale::Arabic, Armenian = QLocale::Armenian, Assamese = QLocale::Assamese, Aymara = QLocale::Aymara, Azerbaijani = QLocale::Azerbaijani, Bashkir = QLocale::Bashkir, Basque = QLocale::Basque, Bengali = QLocale::Bengali, Dzongkha = QLocale::Dzongkha, Bihari = QLocale::Bihari, Bislama = QLocale::Bislama, Breton = QLocale::Breton, Bulgarian = QLocale::Bulgarian, Burmese = QLocale::Burmese, Belarusian = QLocale::Belarusian, Khmer = QLocale::Khmer, Catalan = QLocale::Catalan, Chinese = QLocale::Chinese, Corsican = QLocale::Corsican, Croatian = QLocale::Croatian, Czech = QLocale::Czech, Danish = QLocale::Danish, Dutch = QLocale::Dutch, English = QLocale::English, Esperanto = QLocale::Esperanto, Estonian = QLocale::Estonian, Faroese = QLocale::Faroese, Fijian = QLocale::Fijian, Finnish = QLocale::Finnish, French = QLocale::French, WesternFrisian = QLocale::WesternFrisian, Gaelic = QLocale::Gaelic, Galician = QLocale::Galician, Georgian = QLocale::Georgian, German = QLocale::German, Greek = QLocale::Greek, Greenlandic = QLocale::Greenlandic, Guarani = QLocale::Guarani, Gujarati = QLocale::Gujarati, Hausa = QLocale::Hausa, Hebrew = QLocale::Hebrew, Hindi = QLocale::Hindi, Hungarian = QLocale::Hungarian, Icelandic = QLocale::Icelandic, Indonesian = QLocale::Indonesian, Interlingua = QLocale::Interlingua, Interlingue = QLocale::Interlingue, Inuktitut = QLocale::Inuktitut, Inupiak = QLocale::Inupiak, Irish = QLocale::Irish, Italian = QLocale::Italian, Japanese = QLocale::Japanese, Javanese = QLocale::Javanese, Kannada = QLocale::Kannada, Kashmiri = QLocale::Kashmiri, Kazakh = QLocale::Kazakh, Kinyarwanda = QLocale::Kinyarwanda, Kirghiz = QLocale::Kirghiz, Korean = QLocale::Korean, Kurdish = QLocale::Kurdish, Rundi = QLocale::Rundi, Lao = QLocale::Lao, Latin = QLocale::Latin, Latvian = QLocale::Latvian, Lingala = QLocale::Lingala, Lithuanian = QLocale::Lithuanian, Macedonian = QLocale::Macedonian, Malagasy = QLocale::Malagasy, Malay = QLocale::Malay, Malayalam = QLocale::Malayalam, Maltese = QLocale::Maltese, Maori = QLocale::Maori, Marathi = QLocale::Marathi, Marshallese = QLocale::Marshallese, Mongolian = QLocale::Mongolian, NauruLanguage = QLocale::NauruLanguage, Nepali = QLocale::Nepali, NorwegianBokmal = QLocale::NorwegianBokmal, Occitan = QLocale::Occitan, Oriya = QLocale::Oriya, Pashto = QLocale::Pashto, Persian = QLocale::Persian, Polish = QLocale::Polish, Portuguese = QLocale::Portuguese, Punjabi = QLocale::Punjabi, Quechua = QLocale::Quechua, Romansh = QLocale::Romansh, Romanian = QLocale::Romanian, Russian = QLocale::Russian, Samoan = QLocale::Samoan, Sango = QLocale::Sango, Sanskrit = QLocale::Sanskrit, Serbian = QLocale::Serbian, Ossetic = QLocale::Ossetic, SouthernSotho = QLocale::SouthernSotho, Tswana = QLocale::Tswana, Shona = QLocale::Shona, Sindhi = QLocale::Sindhi, Sinhala = QLocale::Sinhala, Swati = QLocale::Swati, Slovak = QLocale::Slovak, Slovenian = QLocale::Slovenian, Somali = QLocale::Somali, Spanish = QLocale::Spanish, Sundanese = QLocale::Sundanese, Swahili = QLocale::Swahili, Swedish = QLocale::Swedish, Sardinian = QLocale::Sardinian, Tajik = QLocale::Tajik, Tamil = QLocale::Tamil, Tatar = QLocale::Tatar, Telugu = QLocale::Telugu, Thai = QLocale::Thai, Tibetan = QLocale::Tibetan, Tigrinya = QLocale::Tigrinya, Tongan = QLocale::Tongan, Tsonga = QLocale::Tsonga, Turkish = QLocale::Turkish, Turkmen = QLocale::Turkmen, Tahitian = QLocale::Tahitian, Uigur = QLocale::Uigur, Ukrainian = QLocale::Ukrainian, Urdu = QLocale::Urdu, Uzbek = QLocale::Uzbek, Vietnamese = QLocale::Vietnamese, Volapuk = QLocale::Volapuk, Welsh = QLocale::Welsh, Wolof = QLocale::Wolof, Xhosa = QLocale::Xhosa, Yiddish = QLocale::Yiddish, Yoruba = QLocale::Yoruba, Zhuang = QLocale::Zhuang, Zulu = QLocale::Zulu, NorwegianNynorsk = QLocale::NorwegianNynorsk, Bosnian = QLocale::Bosnian, Divehi = QLocale::Divehi, Manx = QLocale::Manx, Cornish = QLocale::Cornish, Akan = QLocale::Akan, Konkani = QLocale::Konkani, Ga = QLocale::Ga, Igbo = QLocale::Igbo, Kamba = QLocale::Kamba, Syriac = QLocale::Syriac, Blin = QLocale::Blin, Geez = QLocale::Geez, Koro = QLocale::Koro, Sidamo = QLocale::Sidamo, Atsam = QLocale::Atsam, Tigre = QLocale::Tigre, Jju = QLocale::Jju, Friulian = QLocale::Friulian, Venda = QLocale::Venda, Ewe = QLocale::Ewe, Walamo = QLocale::Walamo, Hawaiian = QLocale::Hawaiian, Tyap = QLocale::Tyap, Nyanja = QLocale::Nyanja, Filipino = QLocale::Filipino, SwissGerman = QLocale::SwissGerman, SichuanYi = QLocale::SichuanYi, Kpelle = QLocale::Kpelle, LowGerman = QLocale::LowGerman, SouthNdebele = QLocale::SouthNdebele, NorthernSotho = QLocale::NorthernSotho, NorthernSami = QLocale::NorthernSami, Taroko = QLocale::Taroko, Gusii = QLocale::Gusii, Taita = QLocale::Taita, Fulah = QLocale::Fulah, Kikuyu = QLocale::Kikuyu, Samburu = QLocale::Samburu, Sena = QLocale::Sena, NorthNdebele = QLocale::NorthNdebele, Rombo = QLocale::Rombo, Tachelhit = QLocale::Tachelhit, Kabyle = QLocale::Kabyle, Nyankole = QLocale::Nyankole, Bena = QLocale::Bena, Vunjo = QLocale::Vunjo, Bambara = QLocale::Bambara, Embu = QLocale::Embu, Cherokee = QLocale::Cherokee, Morisyen = QLocale::Morisyen, Makonde = QLocale::Makonde, Langi = QLocale::Langi, Ganda = QLocale::Ganda, Bemba = QLocale::Bemba, Kabuverdianu = QLocale::Kabuverdianu, Meru = QLocale::Meru, Kalenjin = QLocale::Kalenjin, Nama = QLocale::Nama, Machame = QLocale::Machame, Colognian = QLocale::Colognian, Masai = QLocale::Masai, Soga = QLocale::Soga, Luyia = QLocale::Luyia, Asu = QLocale::Asu, Teso = QLocale::Teso, Saho = QLocale::Saho, KoyraChiini = QLocale::KoyraChiini, Rwa = QLocale::Rwa, Luo = QLocale::Luo, Chiga = QLocale::Chiga, CentralMoroccoTamazight = QLocale::CentralMoroccoTamazight, KoyraboroSenni = QLocale::KoyraboroSenni, Shambala = QLocale::Shambala, Bodo = QLocale::Bodo, Avaric = QLocale::Avaric, Chamorro = QLocale::Chamorro, Chechen = QLocale::Chechen, Church = QLocale::Church, Chuvash = QLocale::Chuvash, Cree = QLocale::Cree, Haitian = QLocale::Haitian, Herero = QLocale::Herero, HiriMotu = QLocale::HiriMotu, Kanuri = QLocale::Kanuri, Komi = QLocale::Komi, Kongo = QLocale::Kongo, Kwanyama = QLocale::Kwanyama, Limburgish = QLocale::Limburgish, LubaKatanga = QLocale::LubaKatanga, Luxembourgish = QLocale::Luxembourgish, Navaho = QLocale::Navaho, Ndonga = QLocale::Ndonga, Ojibwa = QLocale::Ojibwa, Pali = QLocale::Pali, Walloon = QLocale::Walloon, Aghem = QLocale::Aghem, Basaa = QLocale::Basaa, Zarma = QLocale::Zarma, Duala = QLocale::Duala, JolaFonyi = QLocale::JolaFonyi, Ewondo = QLocale::Ewondo, Bafia = QLocale::Bafia, MakhuwaMeetto = QLocale::MakhuwaMeetto, Mundang = QLocale::Mundang, Kwasio = QLocale::Kwasio, Nuer = QLocale::Nuer, Sakha = QLocale::Sakha, Sangu = QLocale::Sangu, CongoSwahili = QLocale::CongoSwahili, Tasawaq = QLocale::Tasawaq, Vai = QLocale::Vai, Walser = QLocale::Walser, Yangben = QLocale::Yangben, Avestan = QLocale::Avestan, Asturian = QLocale::Asturian, Ngomba = QLocale::Ngomba, Kako = QLocale::Kako, Meta = QLocale::Meta, Ngiemboon = QLocale::Ngiemboon, Norwegian = QLocale::Norwegian, Moldavian = QLocale::Moldavian, SerboCroatian = QLocale::SerboCroatian, Tagalog = QLocale::Tagalog, Twi = QLocale::Twi, Afan = QLocale::Afan, Byelorussian = QLocale::Byelorussian, Bhutani = QLocale::Bhutani, Cambodian = QLocale::Cambodian, Kurundi = QLocale::Kurundi, RhaetoRomance = QLocale::RhaetoRomance, Chewa = QLocale::Chewa, Frisian = QLocale::Frisian, LastLanguage = QLocale::LastLanguage};
318 enum Script{
322 enum Script{
319 AnyScript = QLocale::AnyScript, ArabicScript = QLocale::ArabicScript, CyrillicScript = QLocale::CyrillicScript, DeseretScript = QLocale::DeseretScript, GurmukhiScript = QLocale::GurmukhiScript, SimplifiedHanScript = QLocale::SimplifiedHanScript, TraditionalHanScript = QLocale::TraditionalHanScript, LatinScript = QLocale::LatinScript, MongolianScript = QLocale::MongolianScript, TifinaghScript = QLocale::TifinaghScript, ArmenianScript = QLocale::ArmenianScript, BengaliScript = QLocale::BengaliScript, CherokeeScript = QLocale::CherokeeScript, DevanagariScript = QLocale::DevanagariScript, EthiopicScript = QLocale::EthiopicScript, GeorgianScript = QLocale::GeorgianScript, GreekScript = QLocale::GreekScript, GujaratiScript = QLocale::GujaratiScript, HebrewScript = QLocale::HebrewScript, JapaneseScript = QLocale::JapaneseScript, KhmerScript = QLocale::KhmerScript, KannadaScript = QLocale::KannadaScript, KoreanScript = QLocale::KoreanScript, LaoScript = QLocale::LaoScript, MalayalamScript = QLocale::MalayalamScript, MyanmarScript = QLocale::MyanmarScript, OriyaScript = QLocale::OriyaScript, TamilScript = QLocale::TamilScript, TeluguScript = QLocale::TeluguScript, ThaanaScript = QLocale::ThaanaScript, ThaiScript = QLocale::ThaiScript, TibetanScript = QLocale::TibetanScript, SinhalaScript = QLocale::SinhalaScript, SyriacScript = QLocale::SyriacScript, YiScript = QLocale::YiScript, VaiScript = QLocale::VaiScript, SimplifiedChineseScript = QLocale::SimplifiedChineseScript, TraditionalChineseScript = QLocale::TraditionalChineseScript, LastScript = QLocale::LastScript};
323 AnyScript = QLocale::AnyScript, ArabicScript = QLocale::ArabicScript, CyrillicScript = QLocale::CyrillicScript, DeseretScript = QLocale::DeseretScript, GurmukhiScript = QLocale::GurmukhiScript, SimplifiedHanScript = QLocale::SimplifiedHanScript, TraditionalHanScript = QLocale::TraditionalHanScript, LatinScript = QLocale::LatinScript, MongolianScript = QLocale::MongolianScript, TifinaghScript = QLocale::TifinaghScript, ArmenianScript = QLocale::ArmenianScript, BengaliScript = QLocale::BengaliScript, CherokeeScript = QLocale::CherokeeScript, DevanagariScript = QLocale::DevanagariScript, EthiopicScript = QLocale::EthiopicScript, GeorgianScript = QLocale::GeorgianScript, GreekScript = QLocale::GreekScript, GujaratiScript = QLocale::GujaratiScript, HebrewScript = QLocale::HebrewScript, JapaneseScript = QLocale::JapaneseScript, KhmerScript = QLocale::KhmerScript, KannadaScript = QLocale::KannadaScript, KoreanScript = QLocale::KoreanScript, LaoScript = QLocale::LaoScript, MalayalamScript = QLocale::MalayalamScript, MyanmarScript = QLocale::MyanmarScript, OriyaScript = QLocale::OriyaScript, TamilScript = QLocale::TamilScript, TeluguScript = QLocale::TeluguScript, ThaanaScript = QLocale::ThaanaScript, ThaiScript = QLocale::ThaiScript, TibetanScript = QLocale::TibetanScript, SinhalaScript = QLocale::SinhalaScript, SyriacScript = QLocale::SyriacScript, YiScript = QLocale::YiScript, VaiScript = QLocale::VaiScript, SimplifiedChineseScript = QLocale::SimplifiedChineseScript, TraditionalChineseScript = QLocale::TraditionalChineseScript, LastScript = QLocale::LastScript};
320 enum NumberOption{
324 enum NumberOption{
321 OmitGroupSeparator = QLocale::OmitGroupSeparator, RejectGroupSeparator = QLocale::RejectGroupSeparator};
325 OmitGroupSeparator = QLocale::OmitGroupSeparator, RejectGroupSeparator = QLocale::RejectGroupSeparator};
322 enum Country{
326 enum Country{
323 AnyCountry = QLocale::AnyCountry, Afghanistan = QLocale::Afghanistan, Albania = QLocale::Albania, Algeria = QLocale::Algeria, AmericanSamoa = QLocale::AmericanSamoa, Andorra = QLocale::Andorra, Angola = QLocale::Angola, Anguilla = QLocale::Anguilla, Antarctica = QLocale::Antarctica, AntiguaAndBarbuda = QLocale::AntiguaAndBarbuda, Argentina = QLocale::Argentina, Armenia = QLocale::Armenia, Aruba = QLocale::Aruba, Australia = QLocale::Australia, Austria = QLocale::Austria, Azerbaijan = QLocale::Azerbaijan, Bahamas = QLocale::Bahamas, Bahrain = QLocale::Bahrain, Bangladesh = QLocale::Bangladesh, Barbados = QLocale::Barbados, Belarus = QLocale::Belarus, Belgium = QLocale::Belgium, Belize = QLocale::Belize, Benin = QLocale::Benin, Bermuda = QLocale::Bermuda, Bhutan = QLocale::Bhutan, Bolivia = QLocale::Bolivia, BosniaAndHerzegowina = QLocale::BosniaAndHerzegowina, Botswana = QLocale::Botswana, BouvetIsland = QLocale::BouvetIsland, Brazil = QLocale::Brazil, BritishIndianOceanTerritory = QLocale::BritishIndianOceanTerritory, Brunei = QLocale::Brunei, Bulgaria = QLocale::Bulgaria, BurkinaFaso = QLocale::BurkinaFaso, Burundi = QLocale::Burundi, Cambodia = QLocale::Cambodia, Cameroon = QLocale::Cameroon, Canada = QLocale::Canada, CapeVerde = QLocale::CapeVerde, CaymanIslands = QLocale::CaymanIslands, CentralAfricanRepublic = QLocale::CentralAfricanRepublic, Chad = QLocale::Chad, Chile = QLocale::Chile, China = QLocale::China, ChristmasIsland = QLocale::ChristmasIsland, CocosIslands = QLocale::CocosIslands, Colombia = QLocale::Colombia, Comoros = QLocale::Comoros, CongoKinshasa = QLocale::CongoKinshasa, CongoBrazzaville = QLocale::CongoBrazzaville, CookIslands = QLocale::CookIslands, CostaRica = QLocale::CostaRica, IvoryCoast = QLocale::IvoryCoast, Croatia = QLocale::Croatia, Cuba = QLocale::Cuba, Cyprus = QLocale::Cyprus, CzechRepublic = QLocale::CzechRepublic, Denmark = QLocale::Denmark, Djibouti = QLocale::Djibouti, Dominica = QLocale::Dominica, DominicanRepublic = QLocale::DominicanRepublic, EastTimor = QLocale::EastTimor, Ecuador = QLocale::Ecuador, Egypt = QLocale::Egypt, ElSalvador = QLocale::ElSalvador, EquatorialGuinea = QLocale::EquatorialGuinea, Eritrea = QLocale::Eritrea, Estonia = QLocale::Estonia, Ethiopia = QLocale::Ethiopia, FalklandIslands = QLocale::FalklandIslands, FaroeIslands = QLocale::FaroeIslands, Fiji = QLocale::Fiji, Finland = QLocale::Finland, France = QLocale::France, Guernsey = QLocale::Guernsey, FrenchGuiana = QLocale::FrenchGuiana, FrenchPolynesia = QLocale::FrenchPolynesia, FrenchSouthernTerritories = QLocale::FrenchSouthernTerritories, Gabon = QLocale::Gabon, Gambia = QLocale::Gambia, Georgia = QLocale::Georgia, Germany = QLocale::Germany, Ghana = QLocale::Ghana, Gibraltar = QLocale::Gibraltar, Greece = QLocale::Greece, Greenland = QLocale::Greenland, Grenada = QLocale::Grenada, Guadeloupe = QLocale::Guadeloupe, Guam = QLocale::Guam, Guatemala = QLocale::Guatemala, Guinea = QLocale::Guinea, GuineaBissau = QLocale::GuineaBissau, Guyana = QLocale::Guyana, Haiti = QLocale::Haiti, HeardAndMcDonaldIslands = QLocale::HeardAndMcDonaldIslands, Honduras = QLocale::Honduras, HongKong = QLocale::HongKong, Hungary = QLocale::Hungary, Iceland = QLocale::Iceland, India = QLocale::India, Indonesia = QLocale::Indonesia, Iran = QLocale::Iran, Iraq = QLocale::Iraq, Ireland = QLocale::Ireland, Israel = QLocale::Israel, Italy = QLocale::Italy, Jamaica = QLocale::Jamaica, Japan = QLocale::Japan, Jordan = QLocale::Jordan, Kazakhstan = QLocale::Kazakhstan, Kenya = QLocale::Kenya, Kiribati = QLocale::Kiribati, NorthKorea = QLocale::NorthKorea, SouthKorea = QLocale::SouthKorea, Kuwait = QLocale::Kuwait, Kyrgyzstan = QLocale::Kyrgyzstan, Laos = QLocale::Laos, Latvia = QLocale::Latvia, Lebanon = QLocale::Lebanon, Lesotho = QLocale::Lesotho, Liberia = QLocale::Liberia, Libya = QLocale::Libya, Liechtenstein = QLocale::Liechtenstein, Lithuania = QLocale::Lithuania, Luxembourg = QLocale::Luxembourg, Macau = QLocale::Macau, Macedonia = QLocale::Macedonia, Madagascar = QLocale::Madagascar, Malawi = QLocale::Malawi, Malaysia = QLocale::Malaysia, Maldives = QLocale::Maldives, Mali = QLocale::Mali, Malta = QLocale::Malta, MarshallIslands = QLocale::MarshallIslands, Martinique = QLocale::Martinique, Mauritania = QLocale::Mauritania, Mauritius = QLocale::Mauritius, Mayotte = QLocale::Mayotte, Mexico = QLocale::Mexico, Micronesia = QLocale::Micronesia, Moldova = QLocale::Moldova, Monaco = QLocale::Monaco, Mongolia = QLocale::Mongolia, Montserrat = QLocale::Montserrat, Morocco = QLocale::Morocco, Mozambique = QLocale::Mozambique, Myanmar = QLocale::Myanmar, Namibia = QLocale::Namibia, NauruCountry = QLocale::NauruCountry, Nepal = QLocale::Nepal, Netherlands = QLocale::Netherlands, CuraSao = QLocale::CuraSao, NewCaledonia = QLocale::NewCaledonia, NewZealand = QLocale::NewZealand, Nicaragua = QLocale::Nicaragua, Niger = QLocale::Niger, Nigeria = QLocale::Nigeria, Niue = QLocale::Niue, NorfolkIsland = QLocale::NorfolkIsland, NorthernMarianaIslands = QLocale::NorthernMarianaIslands, Norway = QLocale::Norway, Oman = QLocale::Oman, Pakistan = QLocale::Pakistan, Palau = QLocale::Palau, PalestinianTerritories = QLocale::PalestinianTerritories, Panama = QLocale::Panama, PapuaNewGuinea = QLocale::PapuaNewGuinea, Paraguay = QLocale::Paraguay, Peru = QLocale::Peru, Philippines = QLocale::Philippines, Pitcairn = QLocale::Pitcairn, Poland = QLocale::Poland, Portugal = QLocale::Portugal, PuertoRico = QLocale::PuertoRico, Qatar = QLocale::Qatar, Reunion = QLocale::Reunion, Romania = QLocale::Romania, Russia = QLocale::Russia, Rwanda = QLocale::Rwanda, SaintKittsAndNevis = QLocale::SaintKittsAndNevis, SaintLucia = QLocale::SaintLucia, SaintVincentAndTheGrenadines = QLocale::SaintVincentAndTheGrenadines, Samoa = QLocale::Samoa, SanMarino = QLocale::SanMarino, SaoTomeAndPrincipe = QLocale::SaoTomeAndPrincipe, SaudiArabia = QLocale::SaudiArabia, Senegal = QLocale::Senegal, Seychelles = QLocale::Seychelles, SierraLeone = QLocale::SierraLeone, Singapore = QLocale::Singapore, Slovakia = QLocale::Slovakia, Slovenia = QLocale::Slovenia, SolomonIslands = QLocale::SolomonIslands, Somalia = QLocale::Somalia, SouthAfrica = QLocale::SouthAfrica, SouthGeorgiaAndTheSouthSandwichIslands = QLocale::SouthGeorgiaAndTheSouthSandwichIslands, Spain = QLocale::Spain, SriLanka = QLocale::SriLanka, SaintHelena = QLocale::SaintHelena, SaintPierreAndMiquelon = QLocale::SaintPierreAndMiquelon, Sudan = QLocale::Sudan, Suriname = QLocale::Suriname, SvalbardAndJanMayenIslands = QLocale::SvalbardAndJanMayenIslands, Swaziland = QLocale::Swaziland, Sweden = QLocale::Sweden, Switzerland = QLocale::Switzerland, Syria = QLocale::Syria, Taiwan = QLocale::Taiwan, Tajikistan = QLocale::Tajikistan, Tanzania = QLocale::Tanzania, Thailand = QLocale::Thailand, Togo = QLocale::Togo, Tokelau = QLocale::Tokelau, Tonga = QLocale::Tonga, TrinidadAndTobago = QLocale::TrinidadAndTobago, Tunisia = QLocale::Tunisia, Turkey = QLocale::Turkey, Turkmenistan = QLocale::Turkmenistan, TurksAndCaicosIslands = QLocale::TurksAndCaicosIslands, Tuvalu = QLocale::Tuvalu, Uganda = QLocale::Uganda, Ukraine = QLocale::Ukraine, UnitedArabEmirates = QLocale::UnitedArabEmirates, UnitedKingdom = QLocale::UnitedKingdom, UnitedStates = QLocale::UnitedStates, UnitedStatesMinorOutlyingIslands = QLocale::UnitedStatesMinorOutlyingIslands, Uruguay = QLocale::Uruguay, Uzbekistan = QLocale::Uzbekistan, Vanuatu = QLocale::Vanuatu, VaticanCityState = QLocale::VaticanCityState, Venezuela = QLocale::Venezuela, Vietnam = QLocale::Vietnam, BritishVirginIslands = QLocale::BritishVirginIslands, UnitedStatesVirginIslands = QLocale::UnitedStatesVirginIslands, WallisAndFutunaIslands = QLocale::WallisAndFutunaIslands, WesternSahara = QLocale::WesternSahara, Yemen = QLocale::Yemen, CanaryIslands = QLocale::CanaryIslands, Zambia = QLocale::Zambia, Zimbabwe = QLocale::Zimbabwe, ClippertonIsland = QLocale::ClippertonIsland, Montenegro = QLocale::Montenegro, Serbia = QLocale::Serbia, SaintBarthelemy = QLocale::SaintBarthelemy, SaintMartin = QLocale::SaintMartin, LatinAmericaAndTheCaribbean = QLocale::LatinAmericaAndTheCaribbean, AscensionIsland = QLocale::AscensionIsland, AlandIslands = QLocale::AlandIslands, DiegoGarcia = QLocale::DiegoGarcia, CeutaAndMelilla = QLocale::CeutaAndMelilla, IsleOfMan = QLocale::IsleOfMan, Jersey = QLocale::Jersey, TristanDaCunha = QLocale::TristanDaCunha, SouthSudan = QLocale::SouthSudan, Bonaire = QLocale::Bonaire, SintMaarten = QLocale::SintMaarten, DemocraticRepublicOfCongo = QLocale::DemocraticRepublicOfCongo, PeoplesRepublicOfCongo = QLocale::PeoplesRepublicOfCongo, DemocraticRepublicOfKorea = QLocale::DemocraticRepublicOfKorea, RepublicOfKorea = QLocale::RepublicOfKorea, RussianFederation = QLocale::RussianFederation, SyrianArabRepublic = QLocale::SyrianArabRepublic, LastCountry = QLocale::LastCountry};
327 AnyCountry = QLocale::AnyCountry, Afghanistan = QLocale::Afghanistan, Albania = QLocale::Albania, Algeria = QLocale::Algeria, AmericanSamoa = QLocale::AmericanSamoa, Andorra = QLocale::Andorra, Angola = QLocale::Angola, Anguilla = QLocale::Anguilla, Antarctica = QLocale::Antarctica, AntiguaAndBarbuda = QLocale::AntiguaAndBarbuda, Argentina = QLocale::Argentina, Armenia = QLocale::Armenia, Aruba = QLocale::Aruba, Australia = QLocale::Australia, Austria = QLocale::Austria, Azerbaijan = QLocale::Azerbaijan, Bahamas = QLocale::Bahamas, Bahrain = QLocale::Bahrain, Bangladesh = QLocale::Bangladesh, Barbados = QLocale::Barbados, Belarus = QLocale::Belarus, Belgium = QLocale::Belgium, Belize = QLocale::Belize, Benin = QLocale::Benin, Bermuda = QLocale::Bermuda, Bhutan = QLocale::Bhutan, Bolivia = QLocale::Bolivia, BosniaAndHerzegowina = QLocale::BosniaAndHerzegowina, Botswana = QLocale::Botswana, BouvetIsland = QLocale::BouvetIsland, Brazil = QLocale::Brazil, BritishIndianOceanTerritory = QLocale::BritishIndianOceanTerritory, Brunei = QLocale::Brunei, Bulgaria = QLocale::Bulgaria, BurkinaFaso = QLocale::BurkinaFaso, Burundi = QLocale::Burundi, Cambodia = QLocale::Cambodia, Cameroon = QLocale::Cameroon, Canada = QLocale::Canada, CapeVerde = QLocale::CapeVerde, CaymanIslands = QLocale::CaymanIslands, CentralAfricanRepublic = QLocale::CentralAfricanRepublic, Chad = QLocale::Chad, Chile = QLocale::Chile, China = QLocale::China, ChristmasIsland = QLocale::ChristmasIsland, CocosIslands = QLocale::CocosIslands, Colombia = QLocale::Colombia, Comoros = QLocale::Comoros, CongoKinshasa = QLocale::CongoKinshasa, CongoBrazzaville = QLocale::CongoBrazzaville, CookIslands = QLocale::CookIslands, CostaRica = QLocale::CostaRica, IvoryCoast = QLocale::IvoryCoast, Croatia = QLocale::Croatia, Cuba = QLocale::Cuba, Cyprus = QLocale::Cyprus, CzechRepublic = QLocale::CzechRepublic, Denmark = QLocale::Denmark, Djibouti = QLocale::Djibouti, Dominica = QLocale::Dominica, DominicanRepublic = QLocale::DominicanRepublic, EastTimor = QLocale::EastTimor, Ecuador = QLocale::Ecuador, Egypt = QLocale::Egypt, ElSalvador = QLocale::ElSalvador, EquatorialGuinea = QLocale::EquatorialGuinea, Eritrea = QLocale::Eritrea, Estonia = QLocale::Estonia, Ethiopia = QLocale::Ethiopia, FalklandIslands = QLocale::FalklandIslands, FaroeIslands = QLocale::FaroeIslands, Fiji = QLocale::Fiji, Finland = QLocale::Finland, France = QLocale::France, Guernsey = QLocale::Guernsey, FrenchGuiana = QLocale::FrenchGuiana, FrenchPolynesia = QLocale::FrenchPolynesia, FrenchSouthernTerritories = QLocale::FrenchSouthernTerritories, Gabon = QLocale::Gabon, Gambia = QLocale::Gambia, Georgia = QLocale::Georgia, Germany = QLocale::Germany, Ghana = QLocale::Ghana, Gibraltar = QLocale::Gibraltar, Greece = QLocale::Greece, Greenland = QLocale::Greenland, Grenada = QLocale::Grenada, Guadeloupe = QLocale::Guadeloupe, Guam = QLocale::Guam, Guatemala = QLocale::Guatemala, Guinea = QLocale::Guinea, GuineaBissau = QLocale::GuineaBissau, Guyana = QLocale::Guyana, Haiti = QLocale::Haiti, HeardAndMcDonaldIslands = QLocale::HeardAndMcDonaldIslands, Honduras = QLocale::Honduras, HongKong = QLocale::HongKong, Hungary = QLocale::Hungary, Iceland = QLocale::Iceland, India = QLocale::India, Indonesia = QLocale::Indonesia, Iran = QLocale::Iran, Iraq = QLocale::Iraq, Ireland = QLocale::Ireland, Israel = QLocale::Israel, Italy = QLocale::Italy, Jamaica = QLocale::Jamaica, Japan = QLocale::Japan, Jordan = QLocale::Jordan, Kazakhstan = QLocale::Kazakhstan, Kenya = QLocale::Kenya, Kiribati = QLocale::Kiribati, NorthKorea = QLocale::NorthKorea, SouthKorea = QLocale::SouthKorea, Kuwait = QLocale::Kuwait, Kyrgyzstan = QLocale::Kyrgyzstan, Laos = QLocale::Laos, Latvia = QLocale::Latvia, Lebanon = QLocale::Lebanon, Lesotho = QLocale::Lesotho, Liberia = QLocale::Liberia, Libya = QLocale::Libya, Liechtenstein = QLocale::Liechtenstein, Lithuania = QLocale::Lithuania, Luxembourg = QLocale::Luxembourg, Macau = QLocale::Macau, Macedonia = QLocale::Macedonia, Madagascar = QLocale::Madagascar, Malawi = QLocale::Malawi, Malaysia = QLocale::Malaysia, Maldives = QLocale::Maldives, Mali = QLocale::Mali, Malta = QLocale::Malta, MarshallIslands = QLocale::MarshallIslands, Martinique = QLocale::Martinique, Mauritania = QLocale::Mauritania, Mauritius = QLocale::Mauritius, Mayotte = QLocale::Mayotte, Mexico = QLocale::Mexico, Micronesia = QLocale::Micronesia, Moldova = QLocale::Moldova, Monaco = QLocale::Monaco, Mongolia = QLocale::Mongolia, Montserrat = QLocale::Montserrat, Morocco = QLocale::Morocco, Mozambique = QLocale::Mozambique, Myanmar = QLocale::Myanmar, Namibia = QLocale::Namibia, NauruCountry = QLocale::NauruCountry, Nepal = QLocale::Nepal, Netherlands = QLocale::Netherlands, CuraSao = QLocale::CuraSao, NewCaledonia = QLocale::NewCaledonia, NewZealand = QLocale::NewZealand, Nicaragua = QLocale::Nicaragua, Niger = QLocale::Niger, Nigeria = QLocale::Nigeria, Niue = QLocale::Niue, NorfolkIsland = QLocale::NorfolkIsland, NorthernMarianaIslands = QLocale::NorthernMarianaIslands, Norway = QLocale::Norway, Oman = QLocale::Oman, Pakistan = QLocale::Pakistan, Palau = QLocale::Palau, PalestinianTerritories = QLocale::PalestinianTerritories, Panama = QLocale::Panama, PapuaNewGuinea = QLocale::PapuaNewGuinea, Paraguay = QLocale::Paraguay, Peru = QLocale::Peru, Philippines = QLocale::Philippines, Pitcairn = QLocale::Pitcairn, Poland = QLocale::Poland, Portugal = QLocale::Portugal, PuertoRico = QLocale::PuertoRico, Qatar = QLocale::Qatar, Reunion = QLocale::Reunion, Romania = QLocale::Romania, Russia = QLocale::Russia, Rwanda = QLocale::Rwanda, SaintKittsAndNevis = QLocale::SaintKittsAndNevis, SaintLucia = QLocale::SaintLucia, SaintVincentAndTheGrenadines = QLocale::SaintVincentAndTheGrenadines, Samoa = QLocale::Samoa, SanMarino = QLocale::SanMarino, SaoTomeAndPrincipe = QLocale::SaoTomeAndPrincipe, SaudiArabia = QLocale::SaudiArabia, Senegal = QLocale::Senegal, Seychelles = QLocale::Seychelles, SierraLeone = QLocale::SierraLeone, Singapore = QLocale::Singapore, Slovakia = QLocale::Slovakia, Slovenia = QLocale::Slovenia, SolomonIslands = QLocale::SolomonIslands, Somalia = QLocale::Somalia, SouthAfrica = QLocale::SouthAfrica, SouthGeorgiaAndTheSouthSandwichIslands = QLocale::SouthGeorgiaAndTheSouthSandwichIslands, Spain = QLocale::Spain, SriLanka = QLocale::SriLanka, SaintHelena = QLocale::SaintHelena, SaintPierreAndMiquelon = QLocale::SaintPierreAndMiquelon, Sudan = QLocale::Sudan, Suriname = QLocale::Suriname, SvalbardAndJanMayenIslands = QLocale::SvalbardAndJanMayenIslands, Swaziland = QLocale::Swaziland, Sweden = QLocale::Sweden, Switzerland = QLocale::Switzerland, Syria = QLocale::Syria, Taiwan = QLocale::Taiwan, Tajikistan = QLocale::Tajikistan, Tanzania = QLocale::Tanzania, Thailand = QLocale::Thailand, Togo = QLocale::Togo, Tokelau = QLocale::Tokelau, Tonga = QLocale::Tonga, TrinidadAndTobago = QLocale::TrinidadAndTobago, Tunisia = QLocale::Tunisia, Turkey = QLocale::Turkey, Turkmenistan = QLocale::Turkmenistan, TurksAndCaicosIslands = QLocale::TurksAndCaicosIslands, Tuvalu = QLocale::Tuvalu, Uganda = QLocale::Uganda, Ukraine = QLocale::Ukraine, UnitedArabEmirates = QLocale::UnitedArabEmirates, UnitedKingdom = QLocale::UnitedKingdom, UnitedStates = QLocale::UnitedStates, UnitedStatesMinorOutlyingIslands = QLocale::UnitedStatesMinorOutlyingIslands, Uruguay = QLocale::Uruguay, Uzbekistan = QLocale::Uzbekistan, Vanuatu = QLocale::Vanuatu, VaticanCityState = QLocale::VaticanCityState, Venezuela = QLocale::Venezuela, Vietnam = QLocale::Vietnam, BritishVirginIslands = QLocale::BritishVirginIslands, UnitedStatesVirginIslands = QLocale::UnitedStatesVirginIslands, WallisAndFutunaIslands = QLocale::WallisAndFutunaIslands, WesternSahara = QLocale::WesternSahara, Yemen = QLocale::Yemen, CanaryIslands = QLocale::CanaryIslands, Zambia = QLocale::Zambia, Zimbabwe = QLocale::Zimbabwe, ClippertonIsland = QLocale::ClippertonIsland, Montenegro = QLocale::Montenegro, Serbia = QLocale::Serbia, SaintBarthelemy = QLocale::SaintBarthelemy, SaintMartin = QLocale::SaintMartin, LatinAmericaAndTheCaribbean = QLocale::LatinAmericaAndTheCaribbean, AscensionIsland = QLocale::AscensionIsland, AlandIslands = QLocale::AlandIslands, DiegoGarcia = QLocale::DiegoGarcia, CeutaAndMelilla = QLocale::CeutaAndMelilla, IsleOfMan = QLocale::IsleOfMan, Jersey = QLocale::Jersey, TristanDaCunha = QLocale::TristanDaCunha, SouthSudan = QLocale::SouthSudan, Bonaire = QLocale::Bonaire, SintMaarten = QLocale::SintMaarten, DemocraticRepublicOfCongo = QLocale::DemocraticRepublicOfCongo, PeoplesRepublicOfCongo = QLocale::PeoplesRepublicOfCongo, DemocraticRepublicOfKorea = QLocale::DemocraticRepublicOfKorea, RepublicOfKorea = QLocale::RepublicOfKorea, RussianFederation = QLocale::RussianFederation, SyrianArabRepublic = QLocale::SyrianArabRepublic, LastCountry = QLocale::LastCountry};
324 enum MeasurementSystem{
328 enum MeasurementSystem{
325 MetricSystem = QLocale::MetricSystem, ImperialUSSystem = QLocale::ImperialUSSystem, ImperialUKSystem = QLocale::ImperialUKSystem, ImperialSystem = QLocale::ImperialSystem};
329 MetricSystem = QLocale::MetricSystem, ImperialUSSystem = QLocale::ImperialUSSystem, ImperialUKSystem = QLocale::ImperialUKSystem, ImperialSystem = QLocale::ImperialSystem};
326 Q_DECLARE_FLAGS(NumberOptions, NumberOption)
330 Q_DECLARE_FLAGS(NumberOptions, NumberOption)
327 public slots:
331 public slots:
328 QLocale* new_QLocale();
332 QLocale* new_QLocale();
329 QLocale* new_QLocale(QLocale::Language language, QLocale::Country country = QLocale::AnyCountry);
333 QLocale* new_QLocale(QLocale::Language language, QLocale::Country country = QLocale::AnyCountry);
330 QLocale* new_QLocale(QLocale::Language language, QLocale::Script script, QLocale::Country country);
334 QLocale* new_QLocale(QLocale::Language language, QLocale::Script script, QLocale::Country country);
331 QLocale* new_QLocale(const QLocale& other);
335 QLocale* new_QLocale(const QLocale& other);
332 QLocale* new_QLocale(const QString& name);
336 QLocale* new_QLocale(const QString& name);
333 void delete_QLocale(QLocale* obj) { delete obj; }
337 void delete_QLocale(QLocale* obj) { delete obj; }
334 QString amText(QLocale* theWrappedObject) const;
338 QString amText(QLocale* theWrappedObject) const;
335 QString bcp47Name(QLocale* theWrappedObject) const;
339 QString bcp47Name(QLocale* theWrappedObject) const;
336 QLocale static_QLocale_c();
340 QLocale static_QLocale_c();
337 QList<QLocale::Country > static_QLocale_countriesForLanguage(QLocale::Language lang);
341 QList<QLocale::Country > static_QLocale_countriesForLanguage(QLocale::Language lang);
338 QLocale::Country country(QLocale* theWrappedObject) const;
342 QLocale::Country country(QLocale* theWrappedObject) const;
339 QString static_QLocale_countryToString(QLocale::Country country);
343 QString static_QLocale_countryToString(QLocale::Country country);
340 QString createSeparatedList(QLocale* theWrappedObject, const QStringList& strl) const;
344 QString createSeparatedList(QLocale* theWrappedObject, const QStringList& strl) const;
341 QString currencySymbol(QLocale* theWrappedObject, QLocale::CurrencySymbolFormat arg__1 = QLocale::CurrencySymbol) const;
345 QString currencySymbol(QLocale* theWrappedObject, QLocale::CurrencySymbolFormat arg__1 = QLocale::CurrencySymbol) const;
342 QString dateFormat(QLocale* theWrappedObject, QLocale::FormatType format = QLocale::LongFormat) const;
346 QString dateFormat(QLocale* theWrappedObject, QLocale::FormatType format = QLocale::LongFormat) const;
343 QString dateTimeFormat(QLocale* theWrappedObject, QLocale::FormatType format = QLocale::LongFormat) const;
347 QString dateTimeFormat(QLocale* theWrappedObject, QLocale::FormatType format = QLocale::LongFormat) const;
344 QString dayName(QLocale* theWrappedObject, int arg__1, QLocale::FormatType format = QLocale::LongFormat) const;
348 QString dayName(QLocale* theWrappedObject, int arg__1, QLocale::FormatType format = QLocale::LongFormat) const;
345 QChar decimalPoint(QLocale* theWrappedObject) const;
349 QChar decimalPoint(QLocale* theWrappedObject) const;
346 QChar exponential(QLocale* theWrappedObject) const;
350 QChar exponential(QLocale* theWrappedObject) const;
347 Qt::DayOfWeek firstDayOfWeek(QLocale* theWrappedObject) const;
351 Qt::DayOfWeek firstDayOfWeek(QLocale* theWrappedObject) const;
348 QChar groupSeparator(QLocale* theWrappedObject) const;
352 QChar groupSeparator(QLocale* theWrappedObject) const;
349 QLocale::Language language(QLocale* theWrappedObject) const;
353 QLocale::Language language(QLocale* theWrappedObject) const;
350 QString static_QLocale_languageToString(QLocale::Language language);
354 QString static_QLocale_languageToString(QLocale::Language language);
351 QList<QLocale > static_QLocale_matchingLocales(QLocale::Language language, QLocale::Script script, QLocale::Country country);
355 QList<QLocale > static_QLocale_matchingLocales(QLocale::Language language, QLocale::Script script, QLocale::Country country);
352 QLocale::MeasurementSystem measurementSystem(QLocale* theWrappedObject) const;
356 QLocale::MeasurementSystem measurementSystem(QLocale* theWrappedObject) const;
353 QString monthName(QLocale* theWrappedObject, int arg__1, QLocale::FormatType format = QLocale::LongFormat) const;
357 QString monthName(QLocale* theWrappedObject, int arg__1, QLocale::FormatType format = QLocale::LongFormat) const;
354 QString name(QLocale* theWrappedObject) const;
358 QString name(QLocale* theWrappedObject) const;
355 QString nativeCountryName(QLocale* theWrappedObject) const;
359 QString nativeCountryName(QLocale* theWrappedObject) const;
356 QString nativeLanguageName(QLocale* theWrappedObject) const;
360 QString nativeLanguageName(QLocale* theWrappedObject) const;
357 QChar negativeSign(QLocale* theWrappedObject) const;
361 QChar negativeSign(QLocale* theWrappedObject) const;
358 QLocale::NumberOptions numberOptions(QLocale* theWrappedObject) const;
362 QLocale::NumberOptions numberOptions(QLocale* theWrappedObject) const;
359 bool __ne__(QLocale* theWrappedObject, const QLocale& other) const;
363 bool __ne__(QLocale* theWrappedObject, const QLocale& other) const;
360 bool __eq__(QLocale* theWrappedObject, const QLocale& other) const;
364 bool __eq__(QLocale* theWrappedObject, const QLocale& other) const;
361 QChar percent(QLocale* theWrappedObject) const;
365 QChar percent(QLocale* theWrappedObject) const;
362 QString pmText(QLocale* theWrappedObject) const;
366 QString pmText(QLocale* theWrappedObject) const;
363 QChar positiveSign(QLocale* theWrappedObject) const;
367 QChar positiveSign(QLocale* theWrappedObject) const;
364 QString quoteString(QLocale* theWrappedObject, const QString& str, QLocale::QuotationStyle style = QLocale::StandardQuotation) const;
368 QString quoteString(QLocale* theWrappedObject, const QString& str, QLocale::QuotationStyle style = QLocale::StandardQuotation) const;
365 QString quoteString(QLocale* theWrappedObject, const QStringRef& str, QLocale::QuotationStyle style = QLocale::StandardQuotation) const;
369 QString quoteString(QLocale* theWrappedObject, const QStringRef& str, QLocale::QuotationStyle style = QLocale::StandardQuotation) const;
366 QLocale::Script script(QLocale* theWrappedObject) const;
370 QLocale::Script script(QLocale* theWrappedObject) const;
367 QString static_QLocale_scriptToString(QLocale::Script script);
371 QString static_QLocale_scriptToString(QLocale::Script script);
368 void static_QLocale_setDefault(const QLocale& locale);
372 void static_QLocale_setDefault(const QLocale& locale);
369 void setNumberOptions(QLocale* theWrappedObject, QLocale::NumberOptions options);
373 void setNumberOptions(QLocale* theWrappedObject, QLocale::NumberOptions options);
370 QString standaloneDayName(QLocale* theWrappedObject, int arg__1, QLocale::FormatType format = QLocale::LongFormat) const;
374 QString standaloneDayName(QLocale* theWrappedObject, int arg__1, QLocale::FormatType format = QLocale::LongFormat) const;
371 QString standaloneMonthName(QLocale* theWrappedObject, int arg__1, QLocale::FormatType format = QLocale::LongFormat) const;
375 QString standaloneMonthName(QLocale* theWrappedObject, int arg__1, QLocale::FormatType format = QLocale::LongFormat) const;
372 QLocale static_QLocale_system();
376 QLocale static_QLocale_system();
373 Qt::LayoutDirection textDirection(QLocale* theWrappedObject) const;
377 Qt::LayoutDirection textDirection(QLocale* theWrappedObject) const;
374 QString timeFormat(QLocale* theWrappedObject, QLocale::FormatType format = QLocale::LongFormat) const;
378 QString timeFormat(QLocale* theWrappedObject, QLocale::FormatType format = QLocale::LongFormat) const;
375 QString toCurrencyString(QLocale* theWrappedObject, double arg__1, const QString& symbol = QString()) const;
379 QString toCurrencyString(QLocale* theWrappedObject, double arg__1, const QString& symbol = QString()) const;
376 QString toCurrencyString(QLocale* theWrappedObject, float arg__1, const QString& symbol = QString()) const;
380 QString toCurrencyString(QLocale* theWrappedObject, float arg__1, const QString& symbol = QString()) const;
377 QString toCurrencyString(QLocale* theWrappedObject, int arg__1, const QString& symbol = QString()) const;
381 QString toCurrencyString(QLocale* theWrappedObject, int arg__1, const QString& symbol = QString()) const;
378 QString toCurrencyString(QLocale* theWrappedObject, qlonglong arg__1, const QString& symbol = QString()) const;
382 QString toCurrencyString(QLocale* theWrappedObject, qlonglong arg__1, const QString& symbol = QString()) const;
379 QString toCurrencyString(QLocale* theWrappedObject, qulonglong arg__1, const QString& symbol = QString()) const;
383 QString toCurrencyString(QLocale* theWrappedObject, qulonglong arg__1, const QString& symbol = QString()) const;
380 QString toCurrencyString(QLocale* theWrappedObject, short arg__1, const QString& symbol = QString()) const;
384 QString toCurrencyString(QLocale* theWrappedObject, short arg__1, const QString& symbol = QString()) const;
381 QString toCurrencyString(QLocale* theWrappedObject, uint arg__1, const QString& symbol = QString()) const;
385 QString toCurrencyString(QLocale* theWrappedObject, uint arg__1, const QString& symbol = QString()) const;
382 QString toCurrencyString(QLocale* theWrappedObject, ushort arg__1, const QString& symbol = QString()) const;
386 QString toCurrencyString(QLocale* theWrappedObject, ushort arg__1, const QString& symbol = QString()) const;
383 QDate toDate(QLocale* theWrappedObject, const QString& string, QLocale::FormatType arg__2 = QLocale::LongFormat) const;
387 QDate toDate(QLocale* theWrappedObject, const QString& string, QLocale::FormatType arg__2 = QLocale::LongFormat) const;
384 QDate toDate(QLocale* theWrappedObject, const QString& string, const QString& format) const;
388 QDate toDate(QLocale* theWrappedObject, const QString& string, const QString& format) const;
385 QDateTime toDateTime(QLocale* theWrappedObject, const QString& string, QLocale::FormatType format = QLocale::LongFormat) const;
389 QDateTime toDateTime(QLocale* theWrappedObject, const QString& string, QLocale::FormatType format = QLocale::LongFormat) const;
386 QDateTime toDateTime(QLocale* theWrappedObject, const QString& string, const QString& format) const;
390 QDateTime toDateTime(QLocale* theWrappedObject, const QString& string, const QString& format) const;
387 double toDouble(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
391 double toDouble(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
388 float toFloat(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
392 float toFloat(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
389 int toInt(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
393 int toInt(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
390 qlonglong toLongLong(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
394 qlonglong toLongLong(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
391 QString toLower(QLocale* theWrappedObject, const QString& str) const;
395 QString toLower(QLocale* theWrappedObject, const QString& str) const;
392 short toShort(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
396 short toShort(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
393 QString toString(QLocale* theWrappedObject, const QDate& date, QLocale::FormatType format = QLocale::LongFormat) const;
397 QString toString(QLocale* theWrappedObject, const QDate& date, QLocale::FormatType format = QLocale::LongFormat) const;
394 QString toString(QLocale* theWrappedObject, const QDate& date, const QString& formatStr) const;
398 QString toString(QLocale* theWrappedObject, const QDate& date, const QString& formatStr) const;
395 QString toString(QLocale* theWrappedObject, const QDateTime& dateTime, QLocale::FormatType format = QLocale::LongFormat) const;
399 QString toString(QLocale* theWrappedObject, const QDateTime& dateTime, QLocale::FormatType format = QLocale::LongFormat) const;
396 QString toString(QLocale* theWrappedObject, const QDateTime& dateTime, const QString& format) const;
400 QString toString(QLocale* theWrappedObject, const QDateTime& dateTime, const QString& format) const;
397 QString toString(QLocale* theWrappedObject, const QTime& time, QLocale::FormatType format = QLocale::LongFormat) const;
401 QString toString(QLocale* theWrappedObject, const QTime& time, QLocale::FormatType format = QLocale::LongFormat) const;
398 QString toString(QLocale* theWrappedObject, const QTime& time, const QString& formatStr) const;
402 QString toString(QLocale* theWrappedObject, const QTime& time, const QString& formatStr) const;
399 QString toString(QLocale* theWrappedObject, double i, char f = 'g', int prec = 6) const;
403 QString toString(QLocale* theWrappedObject, double i, char f = 'g', int prec = 6) const;
400 QString toString(QLocale* theWrappedObject, float i, char f = 'g', int prec = 6) const;
404 QString toString(QLocale* theWrappedObject, float i, char f = 'g', int prec = 6) const;
401 QString toString(QLocale* theWrappedObject, int i) const;
405 QString toString(QLocale* theWrappedObject, int i) const;
402 QString toString(QLocale* theWrappedObject, qulonglong i) const;
406 QString toString(QLocale* theWrappedObject, qulonglong i) const;
403 QString toString(QLocale* theWrappedObject, short i) const;
407 QString toString(QLocale* theWrappedObject, short i) const;
404 QTime toTime(QLocale* theWrappedObject, const QString& string, QLocale::FormatType arg__2 = QLocale::LongFormat) const;
408 QTime toTime(QLocale* theWrappedObject, const QString& string, QLocale::FormatType arg__2 = QLocale::LongFormat) const;
405 QTime toTime(QLocale* theWrappedObject, const QString& string, const QString& format) const;
409 QTime toTime(QLocale* theWrappedObject, const QString& string, const QString& format) const;
406 uint toUInt(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
410 uint toUInt(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
407 qulonglong toULongLong(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
411 qulonglong toULongLong(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
408 ushort toUShort(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
412 ushort toUShort(QLocale* theWrappedObject, const QString& s, bool* ok = 0) const;
409 QString toUpper(QLocale* theWrappedObject, const QString& str) const;
413 QString toUpper(QLocale* theWrappedObject, const QString& str) const;
410 QStringList uiLanguages(QLocale* theWrappedObject) const;
414 QStringList uiLanguages(QLocale* theWrappedObject) const;
411 QList<Qt::DayOfWeek > weekdays(QLocale* theWrappedObject) const;
415 QList<Qt::DayOfWeek > weekdays(QLocale* theWrappedObject) const;
412 QChar zeroDigit(QLocale* theWrappedObject) const;
416 QChar zeroDigit(QLocale* theWrappedObject) const;
413 QString py_toString(QLocale*);
417 QString py_toString(QLocale*);
414 };
418 };
415
419
416
420
417
421
418
422
419
423
420 class PythonQtWrapper_QPoint : public QObject
424 class PythonQtWrapper_QPoint : public QObject
421 { Q_OBJECT
425 { Q_OBJECT
422 public:
426 public:
423 public slots:
427 public slots:
424 QPoint* new_QPoint();
428 QPoint* new_QPoint();
425 QPoint* new_QPoint(int xpos, int ypos);
429 QPoint* new_QPoint(int xpos, int ypos);
426 QPoint* new_QPoint(const QPoint& other) {
430 QPoint* new_QPoint(const QPoint& other) {
427 QPoint* a = new QPoint();
431 QPoint* a = new QPoint();
428 *((QPoint*)a) = other;
432 *((QPoint*)a) = other;
429 return a; }
433 return a; }
430 void delete_QPoint(QPoint* obj) { delete obj; }
434 void delete_QPoint(QPoint* obj) { delete obj; }
431 bool isNull(QPoint* theWrappedObject) const;
435 bool isNull(QPoint* theWrappedObject) const;
432 int manhattanLength(QPoint* theWrappedObject) const;
436 int manhattanLength(QPoint* theWrappedObject) const;
433 QPoint __mul__(QPoint* theWrappedObject, const QMatrix& m);
437 QPoint __mul__(QPoint* theWrappedObject, const QMatrix& m);
434 QPoint __mul__(QPoint* theWrappedObject, const QMatrix4x4& matrix);
438 QPoint __mul__(QPoint* theWrappedObject, const QMatrix4x4& matrix);
435 QPoint __mul__(QPoint* theWrappedObject, const QTransform& m);
439 QPoint __mul__(QPoint* theWrappedObject, const QTransform& m);
436 const QPoint __mul__(QPoint* theWrappedObject, double factor);
440 const QPoint __mul__(QPoint* theWrappedObject, double factor);
437 const QPoint __mul__(QPoint* theWrappedObject, float factor);
441 const QPoint __mul__(QPoint* theWrappedObject, float factor);
438 const QPoint __mul__(QPoint* theWrappedObject, int factor);
442 const QPoint __mul__(QPoint* theWrappedObject, int factor);
439 QPoint* __imul__(QPoint* theWrappedObject, double factor);
443 QPoint* __imul__(QPoint* theWrappedObject, double factor);
440 QPoint* __imul__(QPoint* theWrappedObject, float factor);
444 QPoint* __imul__(QPoint* theWrappedObject, float factor);
441 QPoint* __imul__(QPoint* theWrappedObject, int factor);
445 QPoint* __imul__(QPoint* theWrappedObject, int factor);
442 const QPoint __add__(QPoint* theWrappedObject, const QPoint& p2);
446 const QPoint __add__(QPoint* theWrappedObject, const QPoint& p2);
443 QPoint* __iadd__(QPoint* theWrappedObject, const QPoint& p);
447 QPoint* __iadd__(QPoint* theWrappedObject, const QPoint& p);
444 const QPoint __sub__(QPoint* theWrappedObject, const QPoint& p2);
448 const QPoint __sub__(QPoint* theWrappedObject, const QPoint& p2);
445 QPoint* __isub__(QPoint* theWrappedObject, const QPoint& p);
449 QPoint* __isub__(QPoint* theWrappedObject, const QPoint& p);
446 const QPoint __div__(QPoint* theWrappedObject, qreal c);
450 const QPoint __div__(QPoint* theWrappedObject, qreal c);
447 QPoint* __idiv__(QPoint* theWrappedObject, qreal divisor);
451 QPoint* __idiv__(QPoint* theWrappedObject, qreal divisor);
448 bool __eq__(QPoint* theWrappedObject, const QPoint& p2);
452 bool __eq__(QPoint* theWrappedObject, const QPoint& p2);
449 void setX(QPoint* theWrappedObject, int x);
453 void setX(QPoint* theWrappedObject, int x);
450 void setY(QPoint* theWrappedObject, int y);
454 void setY(QPoint* theWrappedObject, int y);
451 int x(QPoint* theWrappedObject) const;
455 int x(QPoint* theWrappedObject) const;
452 int y(QPoint* theWrappedObject) const;
456 int y(QPoint* theWrappedObject) const;
453 QString py_toString(QPoint*);
457 QString py_toString(QPoint*);
454 bool __nonzero__(QPoint* obj) { return !obj->isNull(); }
458 bool __nonzero__(QPoint* obj) { return !obj->isNull(); }
455 };
459 };
456
460
457
461
458
462
459
463
460
464
461 class PythonQtWrapper_QPointF : public QObject
465 class PythonQtWrapper_QPointF : public QObject
462 { Q_OBJECT
466 { Q_OBJECT
463 public:
467 public:
464 public slots:
468 public slots:
465 QPointF* new_QPointF();
469 QPointF* new_QPointF();
466 QPointF* new_QPointF(const QPoint& p);
470 QPointF* new_QPointF(const QPoint& p);
467 QPointF* new_QPointF(qreal xpos, qreal ypos);
471 QPointF* new_QPointF(qreal xpos, qreal ypos);
468 QPointF* new_QPointF(const QPointF& other) {
472 QPointF* new_QPointF(const QPointF& other) {
469 QPointF* a = new QPointF();
473 QPointF* a = new QPointF();
470 *((QPointF*)a) = other;
474 *((QPointF*)a) = other;
471 return a; }
475 return a; }
472 void delete_QPointF(QPointF* obj) { delete obj; }
476 void delete_QPointF(QPointF* obj) { delete obj; }
473 bool isNull(QPointF* theWrappedObject) const;
477 bool isNull(QPointF* theWrappedObject) const;
474 qreal manhattanLength(QPointF* theWrappedObject) const;
478 qreal manhattanLength(QPointF* theWrappedObject) const;
475 QPointF __mul__(QPointF* theWrappedObject, const QMatrix& m);
479 QPointF __mul__(QPointF* theWrappedObject, const QMatrix& m);
476 QPointF __mul__(QPointF* theWrappedObject, const QMatrix4x4& matrix);
480 QPointF __mul__(QPointF* theWrappedObject, const QMatrix4x4& matrix);
477 QPointF __mul__(QPointF* theWrappedObject, const QTransform& m);
481 QPointF __mul__(QPointF* theWrappedObject, const QTransform& m);
478 const QPointF __mul__(QPointF* theWrappedObject, qreal c);
482 const QPointF __mul__(QPointF* theWrappedObject, qreal c);
479 QPointF* __imul__(QPointF* theWrappedObject, qreal c);
483 QPointF* __imul__(QPointF* theWrappedObject, qreal c);
480 const QPointF __add__(QPointF* theWrappedObject, const QPointF& p2);
484 const QPointF __add__(QPointF* theWrappedObject, const QPointF& p2);
481 QPointF* __iadd__(QPointF* theWrappedObject, const QPointF& p);
485 QPointF* __iadd__(QPointF* theWrappedObject, const QPointF& p);
482 const QPointF __sub__(QPointF* theWrappedObject, const QPointF& p2);
486 const QPointF __sub__(QPointF* theWrappedObject, const QPointF& p2);
483 QPointF* __isub__(QPointF* theWrappedObject, const QPointF& p);
487 QPointF* __isub__(QPointF* theWrappedObject, const QPointF& p);
484 const QPointF __div__(QPointF* theWrappedObject, qreal divisor);
488 const QPointF __div__(QPointF* theWrappedObject, qreal divisor);
485 QPointF* __idiv__(QPointF* theWrappedObject, qreal c);
489 QPointF* __idiv__(QPointF* theWrappedObject, qreal c);
486 bool __eq__(QPointF* theWrappedObject, const QPointF& p2);
490 bool __eq__(QPointF* theWrappedObject, const QPointF& p2);
487 void setX(QPointF* theWrappedObject, qreal x);
491 void setX(QPointF* theWrappedObject, qreal x);
488 void setY(QPointF* theWrappedObject, qreal y);
492 void setY(QPointF* theWrappedObject, qreal y);
489 QPoint toPoint(QPointF* theWrappedObject) const;
493 QPoint toPoint(QPointF* theWrappedObject) const;
490 qreal x(QPointF* theWrappedObject) const;
494 qreal x(QPointF* theWrappedObject) const;
491 qreal y(QPointF* theWrappedObject) const;
495 qreal y(QPointF* theWrappedObject) const;
492 QString py_toString(QPointF*);
496 QString py_toString(QPointF*);
493 bool __nonzero__(QPointF* obj) { return !obj->isNull(); }
497 bool __nonzero__(QPointF* obj) { return !obj->isNull(); }
494 };
498 };
495
499
496
500
497
501
498
502
499
503
500 class PythonQtWrapper_QRect : public QObject
504 class PythonQtWrapper_QRect : public QObject
501 { Q_OBJECT
505 { Q_OBJECT
502 public:
506 public:
503 public slots:
507 public slots:
504 QRect* new_QRect();
508 QRect* new_QRect();
505 QRect* new_QRect(const QPoint& topleft, const QPoint& bottomright);
509 QRect* new_QRect(const QPoint& topleft, const QPoint& bottomright);
506 QRect* new_QRect(const QPoint& topleft, const QSize& size);
510 QRect* new_QRect(const QPoint& topleft, const QSize& size);
507 QRect* new_QRect(int left, int top, int width, int height);
511 QRect* new_QRect(int left, int top, int width, int height);
508 QRect* new_QRect(const QRect& other) {
512 QRect* new_QRect(const QRect& other) {
509 QRect* a = new QRect();
513 QRect* a = new QRect();
510 *((QRect*)a) = other;
514 *((QRect*)a) = other;
511 return a; }
515 return a; }
512 void delete_QRect(QRect* obj) { delete obj; }
516 void delete_QRect(QRect* obj) { delete obj; }
513 void adjust(QRect* theWrappedObject, int x1, int y1, int x2, int y2);
517 void adjust(QRect* theWrappedObject, int x1, int y1, int x2, int y2);
514 QRect adjusted(QRect* theWrappedObject, int x1, int y1, int x2, int y2) const;
518 QRect adjusted(QRect* theWrappedObject, int x1, int y1, int x2, int y2) const;
515 int bottom(QRect* theWrappedObject) const;
519 int bottom(QRect* theWrappedObject) const;
516 QPoint bottomLeft(QRect* theWrappedObject) const;
520 QPoint bottomLeft(QRect* theWrappedObject) const;
517 QPoint bottomRight(QRect* theWrappedObject) const;
521 QPoint bottomRight(QRect* theWrappedObject) const;
518 QPoint center(QRect* theWrappedObject) const;
522 QPoint center(QRect* theWrappedObject) const;
519 bool contains(QRect* theWrappedObject, const QPoint& p, bool proper = false) const;
523 bool contains(QRect* theWrappedObject, const QPoint& p, bool proper = false) const;
520 bool contains(QRect* theWrappedObject, const QRect& r, bool proper = false) const;
524 bool contains(QRect* theWrappedObject, const QRect& r, bool proper = false) const;
521 bool contains(QRect* theWrappedObject, int x, int y) const;
525 bool contains(QRect* theWrappedObject, int x, int y) const;
522 bool contains(QRect* theWrappedObject, int x, int y, bool proper) const;
526 bool contains(QRect* theWrappedObject, int x, int y, bool proper) const;
523 int height(QRect* theWrappedObject) const;
527 int height(QRect* theWrappedObject) const;
524 QRect intersected(QRect* theWrappedObject, const QRect& other) const;
528 QRect intersected(QRect* theWrappedObject, const QRect& other) const;
525 bool intersects(QRect* theWrappedObject, const QRect& r) const;
529 bool intersects(QRect* theWrappedObject, const QRect& r) const;
526 bool isEmpty(QRect* theWrappedObject) const;
530 bool isEmpty(QRect* theWrappedObject) const;
527 bool isNull(QRect* theWrappedObject) const;
531 bool isNull(QRect* theWrappedObject) const;
528 bool isValid(QRect* theWrappedObject) const;
532 bool isValid(QRect* theWrappedObject) const;
529 int left(QRect* theWrappedObject) const;
533 int left(QRect* theWrappedObject) const;
530 void moveBottom(QRect* theWrappedObject, int pos);
534 void moveBottom(QRect* theWrappedObject, int pos);
531 void moveBottomLeft(QRect* theWrappedObject, const QPoint& p);
535 void moveBottomLeft(QRect* theWrappedObject, const QPoint& p);
532 void moveBottomRight(QRect* theWrappedObject, const QPoint& p);
536 void moveBottomRight(QRect* theWrappedObject, const QPoint& p);
533 void moveCenter(QRect* theWrappedObject, const QPoint& p);
537 void moveCenter(QRect* theWrappedObject, const QPoint& p);
534 void moveLeft(QRect* theWrappedObject, int pos);
538 void moveLeft(QRect* theWrappedObject, int pos);
535 void moveRight(QRect* theWrappedObject, int pos);
539 void moveRight(QRect* theWrappedObject, int pos);
536 void moveTo(QRect* theWrappedObject, const QPoint& p);
540 void moveTo(QRect* theWrappedObject, const QPoint& p);
537 void moveTo(QRect* theWrappedObject, int x, int t);
541 void moveTo(QRect* theWrappedObject, int x, int t);
538 void moveTop(QRect* theWrappedObject, int pos);
542 void moveTop(QRect* theWrappedObject, int pos);
539 void moveTopLeft(QRect* theWrappedObject, const QPoint& p);
543 void moveTopLeft(QRect* theWrappedObject, const QPoint& p);
540 void moveTopRight(QRect* theWrappedObject, const QPoint& p);
544 void moveTopRight(QRect* theWrappedObject, const QPoint& p);
541 QRect normalized(QRect* theWrappedObject) const;
545 QRect normalized(QRect* theWrappedObject) const;
542 bool __eq__(QRect* theWrappedObject, const QRect& arg__2);
546 bool __eq__(QRect* theWrappedObject, const QRect& arg__2);
543 int right(QRect* theWrappedObject) const;
547 int right(QRect* theWrappedObject) const;
544 void setBottom(QRect* theWrappedObject, int pos);
548 void setBottom(QRect* theWrappedObject, int pos);
545 void setBottomLeft(QRect* theWrappedObject, const QPoint& p);
549 void setBottomLeft(QRect* theWrappedObject, const QPoint& p);
546 void setBottomRight(QRect* theWrappedObject, const QPoint& p);
550 void setBottomRight(QRect* theWrappedObject, const QPoint& p);
547 void setCoords(QRect* theWrappedObject, int x1, int y1, int x2, int y2);
551 void setCoords(QRect* theWrappedObject, int x1, int y1, int x2, int y2);
548 void setHeight(QRect* theWrappedObject, int h);
552 void setHeight(QRect* theWrappedObject, int h);
549 void setLeft(QRect* theWrappedObject, int pos);
553 void setLeft(QRect* theWrappedObject, int pos);
550 void setRect(QRect* theWrappedObject, int x, int y, int w, int h);
554 void setRect(QRect* theWrappedObject, int x, int y, int w, int h);
551 void setRight(QRect* theWrappedObject, int pos);
555 void setRight(QRect* theWrappedObject, int pos);
552 void setSize(QRect* theWrappedObject, const QSize& s);
556 void setSize(QRect* theWrappedObject, const QSize& s);
553 void setTop(QRect* theWrappedObject, int pos);
557 void setTop(QRect* theWrappedObject, int pos);
554 void setTopLeft(QRect* theWrappedObject, const QPoint& p);
558 void setTopLeft(QRect* theWrappedObject, const QPoint& p);
555 void setTopRight(QRect* theWrappedObject, const QPoint& p);
559 void setTopRight(QRect* theWrappedObject, const QPoint& p);
556 void setWidth(QRect* theWrappedObject, int w);
560 void setWidth(QRect* theWrappedObject, int w);
557 void setX(QRect* theWrappedObject, int x);
561 void setX(QRect* theWrappedObject, int x);
558 void setY(QRect* theWrappedObject, int y);
562 void setY(QRect* theWrappedObject, int y);
559 QSize size(QRect* theWrappedObject) const;
563 QSize size(QRect* theWrappedObject) const;
560 int top(QRect* theWrappedObject) const;
564 int top(QRect* theWrappedObject) const;
561 QPoint topLeft(QRect* theWrappedObject) const;
565 QPoint topLeft(QRect* theWrappedObject) const;
562 QPoint topRight(QRect* theWrappedObject) const;
566 QPoint topRight(QRect* theWrappedObject) const;
563 void translate(QRect* theWrappedObject, const QPoint& p);
567 void translate(QRect* theWrappedObject, const QPoint& p);
564 void translate(QRect* theWrappedObject, int dx, int dy);
568 void translate(QRect* theWrappedObject, int dx, int dy);
565 QRect translated(QRect* theWrappedObject, const QPoint& p) const;
569 QRect translated(QRect* theWrappedObject, const QPoint& p) const;
566 QRect translated(QRect* theWrappedObject, int dx, int dy) const;
570 QRect translated(QRect* theWrappedObject, int dx, int dy) const;
567 QRect united(QRect* theWrappedObject, const QRect& other) const;
571 QRect united(QRect* theWrappedObject, const QRect& other) const;
568 int width(QRect* theWrappedObject) const;
572 int width(QRect* theWrappedObject) const;
569 int x(QRect* theWrappedObject) const;
573 int x(QRect* theWrappedObject) const;
570 int y(QRect* theWrappedObject) const;
574 int y(QRect* theWrappedObject) const;
571 QString py_toString(QRect*);
575 QString py_toString(QRect*);
572 bool __nonzero__(QRect* obj) { return !obj->isNull(); }
576 bool __nonzero__(QRect* obj) { return !obj->isNull(); }
573 };
577 };
574
578
575
579
576
580
577
581
578
582
579 class PythonQtWrapper_QRectF : public QObject
583 class PythonQtWrapper_QRectF : public QObject
580 { Q_OBJECT
584 { Q_OBJECT
581 public:
585 public:
582 public slots:
586 public slots:
583 QRectF* new_QRectF();
587 QRectF* new_QRectF();
584 QRectF* new_QRectF(const QPointF& topleft, const QPointF& bottomRight);
588 QRectF* new_QRectF(const QPointF& topleft, const QPointF& bottomRight);
585 QRectF* new_QRectF(const QPointF& topleft, const QSizeF& size);
589 QRectF* new_QRectF(const QPointF& topleft, const QSizeF& size);
586 QRectF* new_QRectF(const QRect& rect);
590 QRectF* new_QRectF(const QRect& rect);
587 QRectF* new_QRectF(qreal left, qreal top, qreal width, qreal height);
591 QRectF* new_QRectF(qreal left, qreal top, qreal width, qreal height);
588 QRectF* new_QRectF(const QRectF& other) {
592 QRectF* new_QRectF(const QRectF& other) {
589 QRectF* a = new QRectF();
593 QRectF* a = new QRectF();
590 *((QRectF*)a) = other;
594 *((QRectF*)a) = other;
591 return a; }
595 return a; }
592 void delete_QRectF(QRectF* obj) { delete obj; }
596 void delete_QRectF(QRectF* obj) { delete obj; }
593 void adjust(QRectF* theWrappedObject, qreal x1, qreal y1, qreal x2, qreal y2);
597 void adjust(QRectF* theWrappedObject, qreal x1, qreal y1, qreal x2, qreal y2);
594 QRectF adjusted(QRectF* theWrappedObject, qreal x1, qreal y1, qreal x2, qreal y2) const;
598 QRectF adjusted(QRectF* theWrappedObject, qreal x1, qreal y1, qreal x2, qreal y2) const;
595 qreal bottom(QRectF* theWrappedObject) const;
599 qreal bottom(QRectF* theWrappedObject) const;
596 QPointF bottomLeft(QRectF* theWrappedObject) const;
600 QPointF bottomLeft(QRectF* theWrappedObject) const;
597 QPointF bottomRight(QRectF* theWrappedObject) const;
601 QPointF bottomRight(QRectF* theWrappedObject) const;
598 QPointF center(QRectF* theWrappedObject) const;
602 QPointF center(QRectF* theWrappedObject) const;
599 bool contains(QRectF* theWrappedObject, const QPointF& p) const;
603 bool contains(QRectF* theWrappedObject, const QPointF& p) const;
600 bool contains(QRectF* theWrappedObject, const QRectF& r) const;
604 bool contains(QRectF* theWrappedObject, const QRectF& r) const;
601 bool contains(QRectF* theWrappedObject, qreal x, qreal y) const;
605 bool contains(QRectF* theWrappedObject, qreal x, qreal y) const;
602 qreal height(QRectF* theWrappedObject) const;
606 qreal height(QRectF* theWrappedObject) const;
603 QRectF intersected(QRectF* theWrappedObject, const QRectF& other) const;
607 QRectF intersected(QRectF* theWrappedObject, const QRectF& other) const;
604 bool intersects(QRectF* theWrappedObject, const QRectF& r) const;
608 bool intersects(QRectF* theWrappedObject, const QRectF& r) const;
605 bool isEmpty(QRectF* theWrappedObject) const;
609 bool isEmpty(QRectF* theWrappedObject) const;
606 bool isNull(QRectF* theWrappedObject) const;
610 bool isNull(QRectF* theWrappedObject) const;
607 bool isValid(QRectF* theWrappedObject) const;
611 bool isValid(QRectF* theWrappedObject) const;
608 qreal left(QRectF* theWrappedObject) const;
612 qreal left(QRectF* theWrappedObject) const;
609 void moveBottom(QRectF* theWrappedObject, qreal pos);
613 void moveBottom(QRectF* theWrappedObject, qreal pos);
610 void moveBottomLeft(QRectF* theWrappedObject, const QPointF& p);
614 void moveBottomLeft(QRectF* theWrappedObject, const QPointF& p);
611 void moveBottomRight(QRectF* theWrappedObject, const QPointF& p);
615 void moveBottomRight(QRectF* theWrappedObject, const QPointF& p);
612 void moveCenter(QRectF* theWrappedObject, const QPointF& p);
616 void moveCenter(QRectF* theWrappedObject, const QPointF& p);
613 void moveLeft(QRectF* theWrappedObject, qreal pos);
617 void moveLeft(QRectF* theWrappedObject, qreal pos);
614 void moveRight(QRectF* theWrappedObject, qreal pos);
618 void moveRight(QRectF* theWrappedObject, qreal pos);
615 void moveTo(QRectF* theWrappedObject, const QPointF& p);
619 void moveTo(QRectF* theWrappedObject, const QPointF& p);
616 void moveTo(QRectF* theWrappedObject, qreal x, qreal t);
620 void moveTo(QRectF* theWrappedObject, qreal x, qreal t);
617 void moveTop(QRectF* theWrappedObject, qreal pos);
621 void moveTop(QRectF* theWrappedObject, qreal pos);
618 void moveTopLeft(QRectF* theWrappedObject, const QPointF& p);
622 void moveTopLeft(QRectF* theWrappedObject, const QPointF& p);
619 void moveTopRight(QRectF* theWrappedObject, const QPointF& p);
623 void moveTopRight(QRectF* theWrappedObject, const QPointF& p);
620 QRectF normalized(QRectF* theWrappedObject) const;
624 QRectF normalized(QRectF* theWrappedObject) const;
621 bool __eq__(QRectF* theWrappedObject, const QRectF& arg__2);
625 bool __eq__(QRectF* theWrappedObject, const QRectF& arg__2);
622 qreal right(QRectF* theWrappedObject) const;
626 qreal right(QRectF* theWrappedObject) const;
623 void setBottom(QRectF* theWrappedObject, qreal pos);
627 void setBottom(QRectF* theWrappedObject, qreal pos);
624 void setBottomLeft(QRectF* theWrappedObject, const QPointF& p);
628 void setBottomLeft(QRectF* theWrappedObject, const QPointF& p);
625 void setBottomRight(QRectF* theWrappedObject, const QPointF& p);
629 void setBottomRight(QRectF* theWrappedObject, const QPointF& p);
626 void setCoords(QRectF* theWrappedObject, qreal x1, qreal y1, qreal x2, qreal y2);
630 void setCoords(QRectF* theWrappedObject, qreal x1, qreal y1, qreal x2, qreal y2);
627 void setHeight(QRectF* theWrappedObject, qreal h);
631 void setHeight(QRectF* theWrappedObject, qreal h);
628 void setLeft(QRectF* theWrappedObject, qreal pos);
632 void setLeft(QRectF* theWrappedObject, qreal pos);
629 void setRect(QRectF* theWrappedObject, qreal x, qreal y, qreal w, qreal h);
633 void setRect(QRectF* theWrappedObject, qreal x, qreal y, qreal w, qreal h);
630 void setRight(QRectF* theWrappedObject, qreal pos);
634 void setRight(QRectF* theWrappedObject, qreal pos);
631 void setSize(QRectF* theWrappedObject, const QSizeF& s);
635 void setSize(QRectF* theWrappedObject, const QSizeF& s);
632 void setTop(QRectF* theWrappedObject, qreal pos);
636 void setTop(QRectF* theWrappedObject, qreal pos);
633 void setTopLeft(QRectF* theWrappedObject, const QPointF& p);
637 void setTopLeft(QRectF* theWrappedObject, const QPointF& p);
634 void setTopRight(QRectF* theWrappedObject, const QPointF& p);
638 void setTopRight(QRectF* theWrappedObject, const QPointF& p);
635 void setWidth(QRectF* theWrappedObject, qreal w);
639 void setWidth(QRectF* theWrappedObject, qreal w);
636 void setX(QRectF* theWrappedObject, qreal pos);
640 void setX(QRectF* theWrappedObject, qreal pos);
637 void setY(QRectF* theWrappedObject, qreal pos);
641 void setY(QRectF* theWrappedObject, qreal pos);
638 QSizeF size(QRectF* theWrappedObject) const;
642 QSizeF size(QRectF* theWrappedObject) const;
639 QRect toAlignedRect(QRectF* theWrappedObject) const;
643 QRect toAlignedRect(QRectF* theWrappedObject) const;
640 QRect toRect(QRectF* theWrappedObject) const;
644 QRect toRect(QRectF* theWrappedObject) const;
641 qreal top(QRectF* theWrappedObject) const;
645 qreal top(QRectF* theWrappedObject) const;
642 QPointF topLeft(QRectF* theWrappedObject) const;
646 QPointF topLeft(QRectF* theWrappedObject) const;
643 QPointF topRight(QRectF* theWrappedObject) const;
647 QPointF topRight(QRectF* theWrappedObject) const;
644 void translate(QRectF* theWrappedObject, const QPointF& p);
648 void translate(QRectF* theWrappedObject, const QPointF& p);
645 void translate(QRectF* theWrappedObject, qreal dx, qreal dy);
649 void translate(QRectF* theWrappedObject, qreal dx, qreal dy);
646 QRectF translated(QRectF* theWrappedObject, const QPointF& p) const;
650 QRectF translated(QRectF* theWrappedObject, const QPointF& p) const;
647 QRectF translated(QRectF* theWrappedObject, qreal dx, qreal dy) const;
651 QRectF translated(QRectF* theWrappedObject, qreal dx, qreal dy) const;
648 QRectF united(QRectF* theWrappedObject, const QRectF& other) const;
652 QRectF united(QRectF* theWrappedObject, const QRectF& other) const;
649 qreal width(QRectF* theWrappedObject) const;
653 qreal width(QRectF* theWrappedObject) const;
650 qreal x(QRectF* theWrappedObject) const;
654 qreal x(QRectF* theWrappedObject) const;
651 qreal y(QRectF* theWrappedObject) const;
655 qreal y(QRectF* theWrappedObject) const;
652 QString py_toString(QRectF*);
656 QString py_toString(QRectF*);
653 bool __nonzero__(QRectF* obj) { return !obj->isNull(); }
657 bool __nonzero__(QRectF* obj) { return !obj->isNull(); }
654 };
658 };
655
659
656
660
657
661
658
662
659
663
660 class PythonQtWrapper_QRegExp : public QObject
664 class PythonQtWrapper_QRegExp : public QObject
661 { Q_OBJECT
665 { Q_OBJECT
662 public:
666 public:
663 Q_ENUMS(PatternSyntax CaretMode )
667 Q_ENUMS(PatternSyntax CaretMode )
664 enum PatternSyntax{
668 enum PatternSyntax{
665 RegExp = QRegExp::RegExp, Wildcard = QRegExp::Wildcard, FixedString = QRegExp::FixedString, RegExp2 = QRegExp::RegExp2, WildcardUnix = QRegExp::WildcardUnix, W3CXmlSchema11 = QRegExp::W3CXmlSchema11};
669 RegExp = QRegExp::RegExp, Wildcard = QRegExp::Wildcard, FixedString = QRegExp::FixedString, RegExp2 = QRegExp::RegExp2, WildcardUnix = QRegExp::WildcardUnix, W3CXmlSchema11 = QRegExp::W3CXmlSchema11};
666 enum CaretMode{
670 enum CaretMode{
667 CaretAtZero = QRegExp::CaretAtZero, CaretAtOffset = QRegExp::CaretAtOffset, CaretWontMatch = QRegExp::CaretWontMatch};
671 CaretAtZero = QRegExp::CaretAtZero, CaretAtOffset = QRegExp::CaretAtOffset, CaretWontMatch = QRegExp::CaretWontMatch};
668 public slots:
672 public slots:
669 QRegExp* new_QRegExp();
673 QRegExp* new_QRegExp();
670 QRegExp* new_QRegExp(const QRegExp& rx);
674 QRegExp* new_QRegExp(const QRegExp& rx);
671 QRegExp* new_QRegExp(const QString& pattern, Qt::CaseSensitivity cs = Qt::CaseSensitive, QRegExp::PatternSyntax syntax = QRegExp::RegExp);
675 QRegExp* new_QRegExp(const QString& pattern, Qt::CaseSensitivity cs = Qt::CaseSensitive, QRegExp::PatternSyntax syntax = QRegExp::RegExp);
672 void delete_QRegExp(QRegExp* obj) { delete obj; }
676 void delete_QRegExp(QRegExp* obj) { delete obj; }
673 QString cap(QRegExp* theWrappedObject, int nth = 0) const;
677 QString cap(QRegExp* theWrappedObject, int nth = 0) const;
674 int captureCount(QRegExp* theWrappedObject) const;
678 int captureCount(QRegExp* theWrappedObject) const;
675 QStringList capturedTexts(QRegExp* theWrappedObject) const;
679 QStringList capturedTexts(QRegExp* theWrappedObject) const;
676 Qt::CaseSensitivity caseSensitivity(QRegExp* theWrappedObject) const;
680 Qt::CaseSensitivity caseSensitivity(QRegExp* theWrappedObject) const;
677 QString errorString(QRegExp* theWrappedObject) const;
681 QString errorString(QRegExp* theWrappedObject) const;
678 QString static_QRegExp_escape(const QString& str);
682 QString static_QRegExp_escape(const QString& str);
679 bool exactMatch(QRegExp* theWrappedObject, const QString& str) const;
683 bool exactMatch(QRegExp* theWrappedObject, const QString& str) const;
680 int indexIn(QRegExp* theWrappedObject, const QString& str, int offset = 0, QRegExp::CaretMode caretMode = QRegExp::CaretAtZero) const;
684 int indexIn(QRegExp* theWrappedObject, const QString& str, int offset = 0, QRegExp::CaretMode caretMode = QRegExp::CaretAtZero) const;
681 bool isEmpty(QRegExp* theWrappedObject) const;
685 bool isEmpty(QRegExp* theWrappedObject) const;
682 bool isMinimal(QRegExp* theWrappedObject) const;
686 bool isMinimal(QRegExp* theWrappedObject) const;
683 bool isValid(QRegExp* theWrappedObject) const;
687 bool isValid(QRegExp* theWrappedObject) const;
684 int lastIndexIn(QRegExp* theWrappedObject, const QString& str, int offset = -1, QRegExp::CaretMode caretMode = QRegExp::CaretAtZero) const;
688 int lastIndexIn(QRegExp* theWrappedObject, const QString& str, int offset = -1, QRegExp::CaretMode caretMode = QRegExp::CaretAtZero) const;
685 int matchedLength(QRegExp* theWrappedObject) const;
689 int matchedLength(QRegExp* theWrappedObject) const;
686 bool __ne__(QRegExp* theWrappedObject, const QRegExp& rx) const;
690 bool __ne__(QRegExp* theWrappedObject, const QRegExp& rx) const;
687 bool __eq__(QRegExp* theWrappedObject, const QRegExp& rx) const;
691 bool __eq__(QRegExp* theWrappedObject, const QRegExp& rx) const;
688 QString pattern(QRegExp* theWrappedObject) const;
692 QString pattern(QRegExp* theWrappedObject) const;
689 QRegExp::PatternSyntax patternSyntax(QRegExp* theWrappedObject) const;
693 QRegExp::PatternSyntax patternSyntax(QRegExp* theWrappedObject) const;
690 int pos(QRegExp* theWrappedObject, int nth = 0) const;
694 int pos(QRegExp* theWrappedObject, int nth = 0) const;
691 void setCaseSensitivity(QRegExp* theWrappedObject, Qt::CaseSensitivity cs);
695 void setCaseSensitivity(QRegExp* theWrappedObject, Qt::CaseSensitivity cs);
692 void setMinimal(QRegExp* theWrappedObject, bool minimal);
696 void setMinimal(QRegExp* theWrappedObject, bool minimal);
693 void setPattern(QRegExp* theWrappedObject, const QString& pattern);
697 void setPattern(QRegExp* theWrappedObject, const QString& pattern);
694 void setPatternSyntax(QRegExp* theWrappedObject, QRegExp::PatternSyntax syntax);
698 void setPatternSyntax(QRegExp* theWrappedObject, QRegExp::PatternSyntax syntax);
695 void swap(QRegExp* theWrappedObject, QRegExp& other);
699 void swap(QRegExp* theWrappedObject, QRegExp& other);
696 QString py_toString(QRegExp*);
700 QString py_toString(QRegExp*);
697 };
701 };
698
702
699
703
700
704
701
705
702
706
703 class PythonQtWrapper_QSize : public QObject
707 class PythonQtWrapper_QSize : public QObject
704 { Q_OBJECT
708 { Q_OBJECT
705 public:
709 public:
706 public slots:
710 public slots:
707 QSize* new_QSize();
711 QSize* new_QSize();
708 QSize* new_QSize(int w, int h);
712 QSize* new_QSize(int w, int h);
709 QSize* new_QSize(const QSize& other) {
713 QSize* new_QSize(const QSize& other) {
710 QSize* a = new QSize();
714 QSize* a = new QSize();
711 *((QSize*)a) = other;
715 *((QSize*)a) = other;
712 return a; }
716 return a; }
713 void delete_QSize(QSize* obj) { delete obj; }
717 void delete_QSize(QSize* obj) { delete obj; }
714 QSize boundedTo(QSize* theWrappedObject, const QSize& arg__1) const;
718 QSize boundedTo(QSize* theWrappedObject, const QSize& arg__1) const;
715 QSize expandedTo(QSize* theWrappedObject, const QSize& arg__1) const;
719 QSize expandedTo(QSize* theWrappedObject, const QSize& arg__1) const;
716 int height(QSize* theWrappedObject) const;
720 int height(QSize* theWrappedObject) const;
717 bool isEmpty(QSize* theWrappedObject) const;
721 bool isEmpty(QSize* theWrappedObject) const;
718 bool isNull(QSize* theWrappedObject) const;
722 bool isNull(QSize* theWrappedObject) const;
719 bool isValid(QSize* theWrappedObject) const;
723 bool isValid(QSize* theWrappedObject) const;
720 const QSize __mul__(QSize* theWrappedObject, qreal c);
724 const QSize __mul__(QSize* theWrappedObject, qreal c);
721 QSize* __imul__(QSize* theWrappedObject, qreal c);
725 QSize* __imul__(QSize* theWrappedObject, qreal c);
722 const QSize __add__(QSize* theWrappedObject, const QSize& s2);
726 const QSize __add__(QSize* theWrappedObject, const QSize& s2);
723 QSize* __iadd__(QSize* theWrappedObject, const QSize& arg__1);
727 QSize* __iadd__(QSize* theWrappedObject, const QSize& arg__1);
724 const QSize __sub__(QSize* theWrappedObject, const QSize& s2);
728 const QSize __sub__(QSize* theWrappedObject, const QSize& s2);
725 QSize* __isub__(QSize* theWrappedObject, const QSize& arg__1);
729 QSize* __isub__(QSize* theWrappedObject, const QSize& arg__1);
726 const QSize __div__(QSize* theWrappedObject, qreal c);
730 const QSize __div__(QSize* theWrappedObject, qreal c);
727 QSize* __idiv__(QSize* theWrappedObject, qreal c);
731 QSize* __idiv__(QSize* theWrappedObject, qreal c);
728 bool __eq__(QSize* theWrappedObject, const QSize& s2);
732 bool __eq__(QSize* theWrappedObject, const QSize& s2);
729 void scale(QSize* theWrappedObject, const QSize& s, Qt::AspectRatioMode mode);
733 void scale(QSize* theWrappedObject, const QSize& s, Qt::AspectRatioMode mode);
730 void scale(QSize* theWrappedObject, int w, int h, Qt::AspectRatioMode mode);
734 void scale(QSize* theWrappedObject, int w, int h, Qt::AspectRatioMode mode);
731 QSize scaled(QSize* theWrappedObject, const QSize& s, Qt::AspectRatioMode mode) const;
735 QSize scaled(QSize* theWrappedObject, const QSize& s, Qt::AspectRatioMode mode) const;
732 QSize scaled(QSize* theWrappedObject, int w, int h, Qt::AspectRatioMode mode) const;
736 QSize scaled(QSize* theWrappedObject, int w, int h, Qt::AspectRatioMode mode) const;
733 void setHeight(QSize* theWrappedObject, int h);
737 void setHeight(QSize* theWrappedObject, int h);
734 void setWidth(QSize* theWrappedObject, int w);
738 void setWidth(QSize* theWrappedObject, int w);
735 void transpose(QSize* theWrappedObject);
739 void transpose(QSize* theWrappedObject);
736 QSize transposed(QSize* theWrappedObject) const;
740 QSize transposed(QSize* theWrappedObject) const;
737 int width(QSize* theWrappedObject) const;
741 int width(QSize* theWrappedObject) const;
738 QString py_toString(QSize*);
742 QString py_toString(QSize*);
739 bool __nonzero__(QSize* obj) { return !obj->isNull(); }
743 bool __nonzero__(QSize* obj) { return !obj->isNull(); }
740 };
744 };
741
745
742
746
743
747
744
748
745
749
746 class PythonQtWrapper_QSizeF : public QObject
750 class PythonQtWrapper_QSizeF : public QObject
747 { Q_OBJECT
751 { Q_OBJECT
748 public:
752 public:
749 public slots:
753 public slots:
750 QSizeF* new_QSizeF();
754 QSizeF* new_QSizeF();
751 QSizeF* new_QSizeF(const QSize& sz);
755 QSizeF* new_QSizeF(const QSize& sz);
752 QSizeF* new_QSizeF(qreal w, qreal h);
756 QSizeF* new_QSizeF(qreal w, qreal h);
753 QSizeF* new_QSizeF(const QSizeF& other) {
757 QSizeF* new_QSizeF(const QSizeF& other) {
754 QSizeF* a = new QSizeF();
758 QSizeF* a = new QSizeF();
755 *((QSizeF*)a) = other;
759 *((QSizeF*)a) = other;
756 return a; }
760 return a; }
757 void delete_QSizeF(QSizeF* obj) { delete obj; }
761 void delete_QSizeF(QSizeF* obj) { delete obj; }
758 QSizeF boundedTo(QSizeF* theWrappedObject, const QSizeF& arg__1) const;
762 QSizeF boundedTo(QSizeF* theWrappedObject, const QSizeF& arg__1) const;
759 QSizeF expandedTo(QSizeF* theWrappedObject, const QSizeF& arg__1) const;
763 QSizeF expandedTo(QSizeF* theWrappedObject, const QSizeF& arg__1) const;
760 qreal height(QSizeF* theWrappedObject) const;
764 qreal height(QSizeF* theWrappedObject) const;
761 bool isEmpty(QSizeF* theWrappedObject) const;
765 bool isEmpty(QSizeF* theWrappedObject) const;
762 bool isNull(QSizeF* theWrappedObject) const;
766 bool isNull(QSizeF* theWrappedObject) const;
763 bool isValid(QSizeF* theWrappedObject) const;
767 bool isValid(QSizeF* theWrappedObject) const;
764 const QSizeF __mul__(QSizeF* theWrappedObject, qreal c);
768 const QSizeF __mul__(QSizeF* theWrappedObject, qreal c);
765 QSizeF* __imul__(QSizeF* theWrappedObject, qreal c);
769 QSizeF* __imul__(QSizeF* theWrappedObject, qreal c);
766 const QSizeF __add__(QSizeF* theWrappedObject, const QSizeF& s2);
770 const QSizeF __add__(QSizeF* theWrappedObject, const QSizeF& s2);
767 QSizeF* __iadd__(QSizeF* theWrappedObject, const QSizeF& arg__1);
771 QSizeF* __iadd__(QSizeF* theWrappedObject, const QSizeF& arg__1);
768 const QSizeF __sub__(QSizeF* theWrappedObject, const QSizeF& s2);
772 const QSizeF __sub__(QSizeF* theWrappedObject, const QSizeF& s2);
769 QSizeF* __isub__(QSizeF* theWrappedObject, const QSizeF& arg__1);
773 QSizeF* __isub__(QSizeF* theWrappedObject, const QSizeF& arg__1);
770 const QSizeF __div__(QSizeF* theWrappedObject, qreal c);
774 const QSizeF __div__(QSizeF* theWrappedObject, qreal c);
771 QSizeF* __idiv__(QSizeF* theWrappedObject, qreal c);
775 QSizeF* __idiv__(QSizeF* theWrappedObject, qreal c);
772 bool __eq__(QSizeF* theWrappedObject, const QSizeF& s2);
776 bool __eq__(QSizeF* theWrappedObject, const QSizeF& s2);
773 void scale(QSizeF* theWrappedObject, const QSizeF& s, Qt::AspectRatioMode mode);
777 void scale(QSizeF* theWrappedObject, const QSizeF& s, Qt::AspectRatioMode mode);
774 void scale(QSizeF* theWrappedObject, qreal w, qreal h, Qt::AspectRatioMode mode);
778 void scale(QSizeF* theWrappedObject, qreal w, qreal h, Qt::AspectRatioMode mode);
775 QSizeF scaled(QSizeF* theWrappedObject, const QSizeF& s, Qt::AspectRatioMode mode) const;
779 QSizeF scaled(QSizeF* theWrappedObject, const QSizeF& s, Qt::AspectRatioMode mode) const;
776 QSizeF scaled(QSizeF* theWrappedObject, qreal w, qreal h, Qt::AspectRatioMode mode) const;
780 QSizeF scaled(QSizeF* theWrappedObject, qreal w, qreal h, Qt::AspectRatioMode mode) const;
777 void setHeight(QSizeF* theWrappedObject, qreal h);
781 void setHeight(QSizeF* theWrappedObject, qreal h);
778 void setWidth(QSizeF* theWrappedObject, qreal w);
782 void setWidth(QSizeF* theWrappedObject, qreal w);
779 QSize toSize(QSizeF* theWrappedObject) const;
783 QSize toSize(QSizeF* theWrappedObject) const;
780 void transpose(QSizeF* theWrappedObject);
784 void transpose(QSizeF* theWrappedObject);
781 QSizeF transposed(QSizeF* theWrappedObject) const;
785 QSizeF transposed(QSizeF* theWrappedObject) const;
782 qreal width(QSizeF* theWrappedObject) const;
786 qreal width(QSizeF* theWrappedObject) const;
783 QString py_toString(QSizeF*);
787 QString py_toString(QSizeF*);
784 bool __nonzero__(QSizeF* obj) { return !obj->isNull(); }
788 bool __nonzero__(QSizeF* obj) { return !obj->isNull(); }
785 };
789 };
786
790
787
791
788
792
789
793
790
794
791 class PythonQtWrapper_QTime : public QObject
795 class PythonQtWrapper_QTime : public QObject
792 { Q_OBJECT
796 { Q_OBJECT
793 public:
797 public:
794 public slots:
798 public slots:
795 QTime* new_QTime();
799 QTime* new_QTime();
796 QTime* new_QTime(int h, int m, int s = 0, int ms = 0);
800 QTime* new_QTime(int h, int m, int s = 0, int ms = 0);
797 QTime* new_QTime(const QTime& other) {
801 QTime* new_QTime(const QTime& other) {
798 QTime* a = new QTime();
802 QTime* a = new QTime();
799 *((QTime*)a) = other;
803 *((QTime*)a) = other;
800 return a; }
804 return a; }
801 void delete_QTime(QTime* obj) { delete obj; }
805 void delete_QTime(QTime* obj) { delete obj; }
802 QTime addMSecs(QTime* theWrappedObject, int ms) const;
806 QTime addMSecs(QTime* theWrappedObject, int ms) const;
803 QTime addSecs(QTime* theWrappedObject, int secs) const;
807 QTime addSecs(QTime* theWrappedObject, int secs) const;
804 QTime static_QTime_currentTime();
808 QTime static_QTime_currentTime();
805 int elapsed(QTime* theWrappedObject) const;
809 int elapsed(QTime* theWrappedObject) const;
806 QTime static_QTime_fromString(const QString& s, Qt::DateFormat f = Qt::TextDate);
810 QTime static_QTime_fromString(const QString& s, Qt::DateFormat f = Qt::TextDate);
807 QTime static_QTime_fromString(const QString& s, const QString& format);
811 QTime static_QTime_fromString(const QString& s, const QString& format);
808 int hour(QTime* theWrappedObject) const;
812 int hour(QTime* theWrappedObject) const;
809 bool isNull(QTime* theWrappedObject) const;
813 bool isNull(QTime* theWrappedObject) const;
810 bool isValid(QTime* theWrappedObject) const;
814 bool isValid(QTime* theWrappedObject) const;
811 bool static_QTime_isValid(int h, int m, int s, int ms = 0);
815 bool static_QTime_isValid(int h, int m, int s, int ms = 0);
812 int minute(QTime* theWrappedObject) const;
816 int minute(QTime* theWrappedObject) const;
813 int msec(QTime* theWrappedObject) const;
817 int msec(QTime* theWrappedObject) const;
814 int msecsTo(QTime* theWrappedObject, const QTime& arg__1) const;
818 int msecsTo(QTime* theWrappedObject, const QTime& arg__1) const;
815 bool __ne__(QTime* theWrappedObject, const QTime& other) const;
819 bool __ne__(QTime* theWrappedObject, const QTime& other) const;
816 bool __lt__(QTime* theWrappedObject, const QTime& other) const;
820 bool __lt__(QTime* theWrappedObject, const QTime& other) const;
817 bool __le__(QTime* theWrappedObject, const QTime& other) const;
821 bool __le__(QTime* theWrappedObject, const QTime& other) const;
818 bool __eq__(QTime* theWrappedObject, const QTime& other) const;
822 bool __eq__(QTime* theWrappedObject, const QTime& other) const;
819 bool __gt__(QTime* theWrappedObject, const QTime& other) const;
823 bool __gt__(QTime* theWrappedObject, const QTime& other) const;
820 bool __ge__(QTime* theWrappedObject, const QTime& other) const;
824 bool __ge__(QTime* theWrappedObject, const QTime& other) const;
821 int restart(QTime* theWrappedObject);
825 int restart(QTime* theWrappedObject);
822 int second(QTime* theWrappedObject) const;
826 int second(QTime* theWrappedObject) const;
823 int secsTo(QTime* theWrappedObject, const QTime& arg__1) const;
827 int secsTo(QTime* theWrappedObject, const QTime& arg__1) const;
824 bool setHMS(QTime* theWrappedObject, int h, int m, int s, int ms = 0);
828 bool setHMS(QTime* theWrappedObject, int h, int m, int s, int ms = 0);
825 void start(QTime* theWrappedObject);
829 void start(QTime* theWrappedObject);
826 QString toString(QTime* theWrappedObject, Qt::DateFormat f = Qt::TextDate) const;
830 QString toString(QTime* theWrappedObject, Qt::DateFormat f = Qt::TextDate) const;
827 QString toString(QTime* theWrappedObject, const QString& format) const;
831 QString toString(QTime* theWrappedObject, const QString& format) const;
828 QString py_toString(QTime*);
832 QString py_toString(QTime*);
829 bool __nonzero__(QTime* obj) { return !obj->isNull(); }
833 bool __nonzero__(QTime* obj) { return !obj->isNull(); }
830 };
834 };
831
835
832
836
833
837
834
838
835
839
836 class PythonQtWrapper_QUrl : public QObject
840 class PythonQtWrapper_QUrl : public QObject
837 { Q_OBJECT
841 { Q_OBJECT
838 public:
842 public:
839 Q_ENUMS(ParsingMode )
843 Q_ENUMS(ParsingMode )
840 enum ParsingMode{
844 enum ParsingMode{
841 TolerantMode = QUrl::TolerantMode, StrictMode = QUrl::StrictMode, DecodedMode = QUrl::DecodedMode};
845 TolerantMode = QUrl::TolerantMode, StrictMode = QUrl::StrictMode, DecodedMode = QUrl::DecodedMode};
842 public slots:
846 public slots:
843 QUrl* new_QUrl();
847 QUrl* new_QUrl();
844 QUrl* new_QUrl(const QString& url, QUrl::ParsingMode mode = QUrl::TolerantMode);
848 QUrl* new_QUrl(const QString& url, QUrl::ParsingMode mode = QUrl::TolerantMode);
845 QUrl* new_QUrl(const QUrl& copy);
849 QUrl* new_QUrl(const QUrl& copy);
846 void delete_QUrl(QUrl* obj) { delete obj; }
850 void delete_QUrl(QUrl* obj) { delete obj; }
847 void clear(QUrl* theWrappedObject);
851 void clear(QUrl* theWrappedObject);
848 QString errorString(QUrl* theWrappedObject) const;
852 QString errorString(QUrl* theWrappedObject) const;
849 QString static_QUrl_fromAce(const QByteArray& arg__1);
853 QString static_QUrl_fromAce(const QByteArray& arg__1);
850 QUrl static_QUrl_fromEncoded(const QByteArray& url, QUrl::ParsingMode mode = QUrl::TolerantMode);
854 QUrl static_QUrl_fromEncoded(const QByteArray& url, QUrl::ParsingMode mode = QUrl::TolerantMode);
851 QUrl static_QUrl_fromLocalFile(const QString& localfile);
855 QUrl static_QUrl_fromLocalFile(const QString& localfile);
852 QString static_QUrl_fromPercentEncoding(const QByteArray& arg__1);
856 QString static_QUrl_fromPercentEncoding(const QByteArray& arg__1);
853 QUrl static_QUrl_fromUserInput(const QString& userInput);
857 QUrl static_QUrl_fromUserInput(const QString& userInput);
854 bool hasFragment(QUrl* theWrappedObject) const;
858 bool hasFragment(QUrl* theWrappedObject) const;
855 bool hasQuery(QUrl* theWrappedObject) const;
859 bool hasQuery(QUrl* theWrappedObject) const;
856 QStringList static_QUrl_idnWhitelist();
860 QStringList static_QUrl_idnWhitelist();
857 bool isEmpty(QUrl* theWrappedObject) const;
861 bool isEmpty(QUrl* theWrappedObject) const;
858 bool isLocalFile(QUrl* theWrappedObject) const;
862 bool isLocalFile(QUrl* theWrappedObject) const;
859 bool isParentOf(QUrl* theWrappedObject, const QUrl& url) const;
863 bool isParentOf(QUrl* theWrappedObject, const QUrl& url) const;
860 bool isRelative(QUrl* theWrappedObject) const;
864 bool isRelative(QUrl* theWrappedObject) const;
861 bool isValid(QUrl* theWrappedObject) const;
865 bool isValid(QUrl* theWrappedObject) const;
862 bool __ne__(QUrl* theWrappedObject, const QUrl& url) const;
866 bool __ne__(QUrl* theWrappedObject, const QUrl& url) const;
863 bool __lt__(QUrl* theWrappedObject, const QUrl& url) const;
867 bool __lt__(QUrl* theWrappedObject, const QUrl& url) const;
864 bool __eq__(QUrl* theWrappedObject, const QUrl& url) const;
868 bool __eq__(QUrl* theWrappedObject, const QUrl& url) const;
865 int port(QUrl* theWrappedObject, int defaultPort = -1) const;
869 int port(QUrl* theWrappedObject, int defaultPort = -1) const;
866 QUrl resolved(QUrl* theWrappedObject, const QUrl& relative) const;
870 QUrl resolved(QUrl* theWrappedObject, const QUrl& relative) const;
867 QString scheme(QUrl* theWrappedObject) const;
871 QString scheme(QUrl* theWrappedObject) const;
868 void setAuthority(QUrl* theWrappedObject, const QString& authority, QUrl::ParsingMode mode = QUrl::TolerantMode);
872 void setAuthority(QUrl* theWrappedObject, const QString& authority, QUrl::ParsingMode mode = QUrl::TolerantMode);
869 void setFragment(QUrl* theWrappedObject, const QString& fragment, QUrl::ParsingMode mode = QUrl::TolerantMode);
873 void setFragment(QUrl* theWrappedObject, const QString& fragment, QUrl::ParsingMode mode = QUrl::TolerantMode);
870 void setHost(QUrl* theWrappedObject, const QString& host, QUrl::ParsingMode mode = QUrl::TolerantMode);
874 void setHost(QUrl* theWrappedObject, const QString& host, QUrl::ParsingMode mode = QUrl::TolerantMode);
871 void static_QUrl_setIdnWhitelist(const QStringList& arg__1);
875 void static_QUrl_setIdnWhitelist(const QStringList& arg__1);
872 void setPassword(QUrl* theWrappedObject, const QString& password, QUrl::ParsingMode mode = QUrl::TolerantMode);
876 void setPassword(QUrl* theWrappedObject, const QString& password, QUrl::ParsingMode mode = QUrl::TolerantMode);
873 void setPath(QUrl* theWrappedObject, const QString& path, QUrl::ParsingMode mode = QUrl::TolerantMode);
877 void setPath(QUrl* theWrappedObject, const QString& path, QUrl::ParsingMode mode = QUrl::TolerantMode);
874 void setPort(QUrl* theWrappedObject, int port);
878 void setPort(QUrl* theWrappedObject, int port);
875 void setQuery(QUrl* theWrappedObject, const QString& query, QUrl::ParsingMode mode = QUrl::TolerantMode);
879 void setQuery(QUrl* theWrappedObject, const QString& query, QUrl::ParsingMode mode = QUrl::TolerantMode);
876 void setScheme(QUrl* theWrappedObject, const QString& scheme);
880 void setScheme(QUrl* theWrappedObject, const QString& scheme);
877 void setUrl(QUrl* theWrappedObject, const QString& url, QUrl::ParsingMode mode = QUrl::TolerantMode);
881 void setUrl(QUrl* theWrappedObject, const QString& url, QUrl::ParsingMode mode = QUrl::TolerantMode);
878 void setUserInfo(QUrl* theWrappedObject, const QString& userInfo, QUrl::ParsingMode mode = QUrl::TolerantMode);
882 void setUserInfo(QUrl* theWrappedObject, const QString& userInfo, QUrl::ParsingMode mode = QUrl::TolerantMode);
879 void setUserName(QUrl* theWrappedObject, const QString& userName, QUrl::ParsingMode mode = QUrl::TolerantMode);
883 void setUserName(QUrl* theWrappedObject, const QString& userName, QUrl::ParsingMode mode = QUrl::TolerantMode);
880 void swap(QUrl* theWrappedObject, QUrl& other);
884 void swap(QUrl* theWrappedObject, QUrl& other);
881 QByteArray static_QUrl_toAce(const QString& arg__1);
885 QByteArray static_QUrl_toAce(const QString& arg__1);
882 QString toLocalFile(QUrl* theWrappedObject) const;
886 QString toLocalFile(QUrl* theWrappedObject) const;
883 QByteArray static_QUrl_toPercentEncoding(const QString& arg__1, const QByteArray& exclude = QByteArray(), const QByteArray& include = QByteArray());
887 QByteArray static_QUrl_toPercentEncoding(const QString& arg__1, const QByteArray& exclude = QByteArray(), const QByteArray& include = QByteArray());
884 QString py_toString(QUrl*);
888 QString py_toString(QUrl*);
885 };
889 };
886
890
887
891
888
892
889
893
890
894
891 class PythonQtWrapper_Qt : public QObject
895 class PythonQtWrapper_Qt : public QObject
892 { Q_OBJECT
896 { Q_OBJECT
893 public:
897 public:
894 Q_ENUMS(AspectRatioMode BGMode MouseButton SortOrder Orientation WidgetAttribute GestureState GlobalColor PenStyle NavigationMode GestureFlag ToolBarArea WindowFrameSection PenCapStyle SizeHint DayOfWeek WindowModality MatchFlag DockWidgetAreaSizes FindChildOption AnchorPoint CaseSensitivity TextFlag BrushStyle ItemSelectionMode DateFormat ApplicationAttribute ItemFlag ScrollBarPolicy WhiteSpaceMode TimerType DropAction FocusPolicy CursorShape TouchPointState CursorMoveStyle InputMethodHint ArrowType TextFormat HitTestAccuracy ToolButtonStyle FocusReason TextElideMode CoordinateSystem KeyboardModifier UIEffect ScreenOrientation ImageConversionFlag TransformationMode PenJoinStyle EventPriority LayoutDirection TextInteractionFlag Corner TileRule ConnectionType AlignmentFlag Key WindowState CheckState ToolBarAreaSizes SizeMode Axis FillRule GestureType ClipOperation InputMethodQuery TimeSpec ItemDataRole ShortcutContext MaskMode WindowType DockWidgetArea ContextMenuPolicy )
898 Q_ENUMS(AspectRatioMode BGMode MouseButton SortOrder Orientation WidgetAttribute GestureState GlobalColor PenStyle NavigationMode GestureFlag ToolBarArea WindowFrameSection PenCapStyle SizeHint DayOfWeek WindowModality MatchFlag DockWidgetAreaSizes FindChildOption AnchorPoint CaseSensitivity TextFlag BrushStyle ItemSelectionMode DateFormat ApplicationAttribute ItemFlag ScrollBarPolicy WhiteSpaceMode TimerType DropAction FocusPolicy CursorShape TouchPointState CursorMoveStyle InputMethodHint ArrowType TextFormat HitTestAccuracy ToolButtonStyle FocusReason TextElideMode CoordinateSystem KeyboardModifier UIEffect ScreenOrientation ImageConversionFlag TransformationMode PenJoinStyle EventPriority LayoutDirection TextInteractionFlag Corner TileRule ConnectionType AlignmentFlag Key WindowState CheckState ToolBarAreaSizes SizeMode Axis FillRule GestureType ClipOperation InputMethodQuery TimeSpec ItemDataRole ShortcutContext MaskMode WindowType DockWidgetArea ContextMenuPolicy )
895 Q_FLAGS(MouseButtons Orientations GestureFlags ToolBarAreas MatchFlags ItemFlags DropActions TouchPointStates InputMethodHints KeyboardModifiers ImageConversionFlags TextInteractionFlags Alignment WindowStates WindowFlags DockWidgetAreas )
899 Q_FLAGS(MouseButtons Orientations GestureFlags ToolBarAreas MatchFlags ItemFlags DropActions TouchPointStates InputMethodHints KeyboardModifiers ImageConversionFlags TextInteractionFlags Alignment WindowStates WindowFlags DockWidgetAreas )
896 enum AspectRatioMode{
900 enum AspectRatioMode{
897 IgnoreAspectRatio = Qt::IgnoreAspectRatio, KeepAspectRatio = Qt::KeepAspectRatio, KeepAspectRatioByExpanding = Qt::KeepAspectRatioByExpanding};
901 IgnoreAspectRatio = Qt::IgnoreAspectRatio, KeepAspectRatio = Qt::KeepAspectRatio, KeepAspectRatioByExpanding = Qt::KeepAspectRatioByExpanding};
898 enum BGMode{
902 enum BGMode{
899 TransparentMode = Qt::TransparentMode, OpaqueMode = Qt::OpaqueMode};
903 TransparentMode = Qt::TransparentMode, OpaqueMode = Qt::OpaqueMode};
900 enum MouseButton{
904 enum MouseButton{
901 NoButton = Qt::NoButton, LeftButton = Qt::LeftButton, RightButton = Qt::RightButton, MidButton = Qt::MidButton, MiddleButton = Qt::MiddleButton, BackButton = Qt::BackButton, XButton1 = Qt::XButton1, ExtraButton1 = Qt::ExtraButton1, ForwardButton = Qt::ForwardButton, XButton2 = Qt::XButton2, ExtraButton2 = Qt::ExtraButton2, TaskButton = Qt::TaskButton, ExtraButton3 = Qt::ExtraButton3, ExtraButton4 = Qt::ExtraButton4, ExtraButton5 = Qt::ExtraButton5, ExtraButton6 = Qt::ExtraButton6, ExtraButton7 = Qt::ExtraButton7, ExtraButton8 = Qt::ExtraButton8, ExtraButton9 = Qt::ExtraButton9, ExtraButton10 = Qt::ExtraButton10, ExtraButton11 = Qt::ExtraButton11, ExtraButton12 = Qt::ExtraButton12, ExtraButton13 = Qt::ExtraButton13, ExtraButton14 = Qt::ExtraButton14, ExtraButton15 = Qt::ExtraButton15, ExtraButton16 = Qt::ExtraButton16, ExtraButton17 = Qt::ExtraButton17, ExtraButton18 = Qt::ExtraButton18, ExtraButton19 = Qt::ExtraButton19, ExtraButton20 = Qt::ExtraButton20, ExtraButton21 = Qt::ExtraButton21, ExtraButton22 = Qt::ExtraButton22, ExtraButton23 = Qt::ExtraButton23, ExtraButton24 = Qt::ExtraButton24, AllButtons = Qt::AllButtons, MaxMouseButton = Qt::MaxMouseButton, MouseButtonMask = Qt::MouseButtonMask};
905 NoButton = Qt::NoButton, LeftButton = Qt::LeftButton, RightButton = Qt::RightButton, MidButton = Qt::MidButton, MiddleButton = Qt::MiddleButton, BackButton = Qt::BackButton, XButton1 = Qt::XButton1, ExtraButton1 = Qt::ExtraButton1, ForwardButton = Qt::ForwardButton, XButton2 = Qt::XButton2, ExtraButton2 = Qt::ExtraButton2, TaskButton = Qt::TaskButton, ExtraButton3 = Qt::ExtraButton3, ExtraButton4 = Qt::ExtraButton4, ExtraButton5 = Qt::ExtraButton5, ExtraButton6 = Qt::ExtraButton6, ExtraButton7 = Qt::ExtraButton7, ExtraButton8 = Qt::ExtraButton8, ExtraButton9 = Qt::ExtraButton9, ExtraButton10 = Qt::ExtraButton10, ExtraButton11 = Qt::ExtraButton11, ExtraButton12 = Qt::ExtraButton12, ExtraButton13 = Qt::ExtraButton13, ExtraButton14 = Qt::ExtraButton14, ExtraButton15 = Qt::ExtraButton15, ExtraButton16 = Qt::ExtraButton16, ExtraButton17 = Qt::ExtraButton17, ExtraButton18 = Qt::ExtraButton18, ExtraButton19 = Qt::ExtraButton19, ExtraButton20 = Qt::ExtraButton20, ExtraButton21 = Qt::ExtraButton21, ExtraButton22 = Qt::ExtraButton22, ExtraButton23 = Qt::ExtraButton23, ExtraButton24 = Qt::ExtraButton24, AllButtons = Qt::AllButtons, MaxMouseButton = Qt::MaxMouseButton, MouseButtonMask = Qt::MouseButtonMask};
902 enum SortOrder{
906 enum SortOrder{
903 AscendingOrder = Qt::AscendingOrder, DescendingOrder = Qt::DescendingOrder};
907 AscendingOrder = Qt::AscendingOrder, DescendingOrder = Qt::DescendingOrder};
904 enum Orientation{
908 enum Orientation{
905 Horizontal = Qt::Horizontal, Vertical = Qt::Vertical};
909 Horizontal = Qt::Horizontal, Vertical = Qt::Vertical};
906 enum WidgetAttribute{
910 enum WidgetAttribute{
907 WA_Disabled = Qt::WA_Disabled, WA_UnderMouse = Qt::WA_UnderMouse, WA_MouseTracking = Qt::WA_MouseTracking, WA_ContentsPropagated = Qt::WA_ContentsPropagated, WA_OpaquePaintEvent = Qt::WA_OpaquePaintEvent, WA_NoBackground = Qt::WA_NoBackground, WA_StaticContents = Qt::WA_StaticContents, WA_LaidOut = Qt::WA_LaidOut, WA_PaintOnScreen = Qt::WA_PaintOnScreen, WA_NoSystemBackground = Qt::WA_NoSystemBackground, WA_UpdatesDisabled = Qt::WA_UpdatesDisabled, WA_Mapped = Qt::WA_Mapped, WA_MacNoClickThrough = Qt::WA_MacNoClickThrough, WA_InputMethodEnabled = Qt::WA_InputMethodEnabled, WA_WState_Visible = Qt::WA_WState_Visible, WA_WState_Hidden = Qt::WA_WState_Hidden, WA_ForceDisabled = Qt::WA_ForceDisabled, WA_KeyCompression = Qt::WA_KeyCompression, WA_PendingMoveEvent = Qt::WA_PendingMoveEvent, WA_PendingResizeEvent = Qt::WA_PendingResizeEvent, WA_SetPalette = Qt::WA_SetPalette, WA_SetFont = Qt::WA_SetFont, WA_SetCursor = Qt::WA_SetCursor, WA_NoChildEventsFromChildren = Qt::WA_NoChildEventsFromChildren, WA_WindowModified = Qt::WA_WindowModified, WA_Resized = Qt::WA_Resized, WA_Moved = Qt::WA_Moved, WA_PendingUpdate = Qt::WA_PendingUpdate, WA_InvalidSize = Qt::WA_InvalidSize, WA_MacBrushedMetal = Qt::WA_MacBrushedMetal, WA_MacMetalStyle = Qt::WA_MacMetalStyle, WA_CustomWhatsThis = Qt::WA_CustomWhatsThis, WA_LayoutOnEntireRect = Qt::WA_LayoutOnEntireRect, WA_OutsideWSRange = Qt::WA_OutsideWSRange, WA_GrabbedShortcut = Qt::WA_GrabbedShortcut, WA_TransparentForMouseEvents = Qt::WA_TransparentForMouseEvents, WA_PaintUnclipped = Qt::WA_PaintUnclipped, WA_SetWindowIcon = Qt::WA_SetWindowIcon, WA_NoMouseReplay = Qt::WA_NoMouseReplay, WA_DeleteOnClose = Qt::WA_DeleteOnClose, WA_RightToLeft = Qt::WA_RightToLeft, WA_SetLayoutDirection = Qt::WA_SetLayoutDirection, WA_NoChildEventsForParent = Qt::WA_NoChildEventsForParent, WA_ForceUpdatesDisabled = Qt::WA_ForceUpdatesDisabled, WA_WState_Created = Qt::WA_WState_Created, WA_WState_CompressKeys = Qt::WA_WState_CompressKeys, WA_WState_InPaintEvent = Qt::WA_WState_InPaintEvent, WA_WState_Reparented = Qt::WA_WState_Reparented, WA_WState_ConfigPending = Qt::WA_WState_ConfigPending, WA_WState_Polished = Qt::WA_WState_Polished, WA_WState_DND = Qt::WA_WState_DND, WA_WState_OwnSizePolicy = Qt::WA_WState_OwnSizePolicy, WA_WState_ExplicitShowHide = Qt::WA_WState_ExplicitShowHide, WA_ShowModal = Qt::WA_ShowModal, WA_MouseNoMask = Qt::WA_MouseNoMask, WA_GroupLeader = Qt::WA_GroupLeader, WA_NoMousePropagation = Qt::WA_NoMousePropagation, WA_Hover = Qt::WA_Hover, WA_InputMethodTransparent = Qt::WA_InputMethodTransparent, WA_QuitOnClose = Qt::WA_QuitOnClose, WA_KeyboardFocusChange = Qt::WA_KeyboardFocusChange, WA_AcceptDrops = Qt::WA_AcceptDrops, WA_DropSiteRegistered = Qt::WA_DropSiteRegistered, WA_ForceAcceptDrops = Qt::WA_ForceAcceptDrops, WA_WindowPropagation = Qt::WA_WindowPropagation, WA_NoX11EventCompression = Qt::WA_NoX11EventCompression, WA_TintedBackground = Qt::WA_TintedBackground, WA_X11OpenGLOverlay = Qt::WA_X11OpenGLOverlay, WA_AlwaysShowToolTips = Qt::WA_AlwaysShowToolTips, WA_MacOpaqueSizeGrip = Qt::WA_MacOpaqueSizeGrip, WA_SetStyle = Qt::WA_SetStyle, WA_SetLocale = Qt::WA_SetLocale, WA_MacShowFocusRect = Qt::WA_MacShowFocusRect, WA_MacNormalSize = Qt::WA_MacNormalSize, WA_MacSmallSize = Qt::WA_MacSmallSize, WA_MacMiniSize = Qt::WA_MacMiniSize, WA_LayoutUsesWidgetRect = Qt::WA_LayoutUsesWidgetRect, WA_StyledBackground = Qt::WA_StyledBackground, WA_MSWindowsUseDirect3D = Qt::WA_MSWindowsUseDirect3D, WA_CanHostQMdiSubWindowTitleBar = Qt::WA_CanHostQMdiSubWindowTitleBar, WA_MacAlwaysShowToolWindow = Qt::WA_MacAlwaysShowToolWindow, WA_StyleSheet = Qt::WA_StyleSheet, WA_ShowWithoutActivating = Qt::WA_ShowWithoutActivating, WA_X11BypassTransientForHint = Qt::WA_X11BypassTransientForHint, WA_NativeWindow = Qt::WA_NativeWindow, WA_DontCreateNativeAncestors = Qt::WA_DontCreateNativeAncestors, WA_MacVariableSize = Qt::WA_MacVariableSize, WA_DontShowOnScreen = Qt::WA_DontShowOnScreen, WA_X11NetWmWindowTypeDesktop = Qt::WA_X11NetWmWindowTypeDesktop, WA_X11NetWmWindowTypeDock = Qt::WA_X11NetWmWindowTypeDock, WA_X11NetWmWindowTypeToolBar = Qt::WA_X11NetWmWindowTypeToolBar, WA_X11NetWmWindowTypeMenu = Qt::WA_X11NetWmWindowTypeMenu, WA_X11NetWmWindowTypeUtility = Qt::WA_X11NetWmWindowTypeUtility, WA_X11NetWmWindowTypeSplash = Qt::WA_X11NetWmWindowTypeSplash, WA_X11NetWmWindowTypeDialog = Qt::WA_X11NetWmWindowTypeDialog, WA_X11NetWmWindowTypeDropDownMenu = Qt::WA_X11NetWmWindowTypeDropDownMenu, WA_X11NetWmWindowTypePopupMenu = Qt::WA_X11NetWmWindowTypePopupMenu, WA_X11NetWmWindowTypeToolTip = Qt::WA_X11NetWmWindowTypeToolTip, WA_X11NetWmWindowTypeNotification = Qt::WA_X11NetWmWindowTypeNotification, WA_X11NetWmWindowTypeCombo = Qt::WA_X11NetWmWindowTypeCombo, WA_X11NetWmWindowTypeDND = Qt::WA_X11NetWmWindowTypeDND, WA_MacFrameworkScaled = Qt::WA_MacFrameworkScaled, WA_SetWindowModality = Qt::WA_SetWindowModality, WA_WState_WindowOpacitySet = Qt::WA_WState_WindowOpacitySet, WA_TranslucentBackground = Qt::WA_TranslucentBackground, WA_AcceptTouchEvents = Qt::WA_AcceptTouchEvents, WA_WState_AcceptedTouchBeginEvent = Qt::WA_WState_AcceptedTouchBeginEvent, WA_TouchPadAcceptSingleTouchEvents = Qt::WA_TouchPadAcceptSingleTouchEvents, WA_X11DoNotAcceptFocus = Qt::WA_X11DoNotAcceptFocus, WA_MacNoShadow = Qt::WA_MacNoShadow, WA_AttributeCount = Qt::WA_AttributeCount};
911 WA_Disabled = Qt::WA_Disabled, WA_UnderMouse = Qt::WA_UnderMouse, WA_MouseTracking = Qt::WA_MouseTracking, WA_ContentsPropagated = Qt::WA_ContentsPropagated, WA_OpaquePaintEvent = Qt::WA_OpaquePaintEvent, WA_NoBackground = Qt::WA_NoBackground, WA_StaticContents = Qt::WA_StaticContents, WA_LaidOut = Qt::WA_LaidOut, WA_PaintOnScreen = Qt::WA_PaintOnScreen, WA_NoSystemBackground = Qt::WA_NoSystemBackground, WA_UpdatesDisabled = Qt::WA_UpdatesDisabled, WA_Mapped = Qt::WA_Mapped, WA_MacNoClickThrough = Qt::WA_MacNoClickThrough, WA_InputMethodEnabled = Qt::WA_InputMethodEnabled, WA_WState_Visible = Qt::WA_WState_Visible, WA_WState_Hidden = Qt::WA_WState_Hidden, WA_ForceDisabled = Qt::WA_ForceDisabled, WA_KeyCompression = Qt::WA_KeyCompression, WA_PendingMoveEvent = Qt::WA_PendingMoveEvent, WA_PendingResizeEvent = Qt::WA_PendingResizeEvent, WA_SetPalette = Qt::WA_SetPalette, WA_SetFont = Qt::WA_SetFont, WA_SetCursor = Qt::WA_SetCursor, WA_NoChildEventsFromChildren = Qt::WA_NoChildEventsFromChildren, WA_WindowModified = Qt::WA_WindowModified, WA_Resized = Qt::WA_Resized, WA_Moved = Qt::WA_Moved, WA_PendingUpdate = Qt::WA_PendingUpdate, WA_InvalidSize = Qt::WA_InvalidSize, WA_MacBrushedMetal = Qt::WA_MacBrushedMetal, WA_MacMetalStyle = Qt::WA_MacMetalStyle, WA_CustomWhatsThis = Qt::WA_CustomWhatsThis, WA_LayoutOnEntireRect = Qt::WA_LayoutOnEntireRect, WA_OutsideWSRange = Qt::WA_OutsideWSRange, WA_GrabbedShortcut = Qt::WA_GrabbedShortcut, WA_TransparentForMouseEvents = Qt::WA_TransparentForMouseEvents, WA_PaintUnclipped = Qt::WA_PaintUnclipped, WA_SetWindowIcon = Qt::WA_SetWindowIcon, WA_NoMouseReplay = Qt::WA_NoMouseReplay, WA_DeleteOnClose = Qt::WA_DeleteOnClose, WA_RightToLeft = Qt::WA_RightToLeft, WA_SetLayoutDirection = Qt::WA_SetLayoutDirection, WA_NoChildEventsForParent = Qt::WA_NoChildEventsForParent, WA_ForceUpdatesDisabled = Qt::WA_ForceUpdatesDisabled, WA_WState_Created = Qt::WA_WState_Created, WA_WState_CompressKeys = Qt::WA_WState_CompressKeys, WA_WState_InPaintEvent = Qt::WA_WState_InPaintEvent, WA_WState_Reparented = Qt::WA_WState_Reparented, WA_WState_ConfigPending = Qt::WA_WState_ConfigPending, WA_WState_Polished = Qt::WA_WState_Polished, WA_WState_DND = Qt::WA_WState_DND, WA_WState_OwnSizePolicy = Qt::WA_WState_OwnSizePolicy, WA_WState_ExplicitShowHide = Qt::WA_WState_ExplicitShowHide, WA_ShowModal = Qt::WA_ShowModal, WA_MouseNoMask = Qt::WA_MouseNoMask, WA_GroupLeader = Qt::WA_GroupLeader, WA_NoMousePropagation = Qt::WA_NoMousePropagation, WA_Hover = Qt::WA_Hover, WA_InputMethodTransparent = Qt::WA_InputMethodTransparent, WA_QuitOnClose = Qt::WA_QuitOnClose, WA_KeyboardFocusChange = Qt::WA_KeyboardFocusChange, WA_AcceptDrops = Qt::WA_AcceptDrops, WA_DropSiteRegistered = Qt::WA_DropSiteRegistered, WA_ForceAcceptDrops = Qt::WA_ForceAcceptDrops, WA_WindowPropagation = Qt::WA_WindowPropagation, WA_NoX11EventCompression = Qt::WA_NoX11EventCompression, WA_TintedBackground = Qt::WA_TintedBackground, WA_X11OpenGLOverlay = Qt::WA_X11OpenGLOverlay, WA_AlwaysShowToolTips = Qt::WA_AlwaysShowToolTips, WA_MacOpaqueSizeGrip = Qt::WA_MacOpaqueSizeGrip, WA_SetStyle = Qt::WA_SetStyle, WA_SetLocale = Qt::WA_SetLocale, WA_MacShowFocusRect = Qt::WA_MacShowFocusRect, WA_MacNormalSize = Qt::WA_MacNormalSize, WA_MacSmallSize = Qt::WA_MacSmallSize, WA_MacMiniSize = Qt::WA_MacMiniSize, WA_LayoutUsesWidgetRect = Qt::WA_LayoutUsesWidgetRect, WA_StyledBackground = Qt::WA_StyledBackground, WA_MSWindowsUseDirect3D = Qt::WA_MSWindowsUseDirect3D, WA_CanHostQMdiSubWindowTitleBar = Qt::WA_CanHostQMdiSubWindowTitleBar, WA_MacAlwaysShowToolWindow = Qt::WA_MacAlwaysShowToolWindow, WA_StyleSheet = Qt::WA_StyleSheet, WA_ShowWithoutActivating = Qt::WA_ShowWithoutActivating, WA_X11BypassTransientForHint = Qt::WA_X11BypassTransientForHint, WA_NativeWindow = Qt::WA_NativeWindow, WA_DontCreateNativeAncestors = Qt::WA_DontCreateNativeAncestors, WA_MacVariableSize = Qt::WA_MacVariableSize, WA_DontShowOnScreen = Qt::WA_DontShowOnScreen, WA_X11NetWmWindowTypeDesktop = Qt::WA_X11NetWmWindowTypeDesktop, WA_X11NetWmWindowTypeDock = Qt::WA_X11NetWmWindowTypeDock, WA_X11NetWmWindowTypeToolBar = Qt::WA_X11NetWmWindowTypeToolBar, WA_X11NetWmWindowTypeMenu = Qt::WA_X11NetWmWindowTypeMenu, WA_X11NetWmWindowTypeUtility = Qt::WA_X11NetWmWindowTypeUtility, WA_X11NetWmWindowTypeSplash = Qt::WA_X11NetWmWindowTypeSplash, WA_X11NetWmWindowTypeDialog = Qt::WA_X11NetWmWindowTypeDialog, WA_X11NetWmWindowTypeDropDownMenu = Qt::WA_X11NetWmWindowTypeDropDownMenu, WA_X11NetWmWindowTypePopupMenu = Qt::WA_X11NetWmWindowTypePopupMenu, WA_X11NetWmWindowTypeToolTip = Qt::WA_X11NetWmWindowTypeToolTip, WA_X11NetWmWindowTypeNotification = Qt::WA_X11NetWmWindowTypeNotification, WA_X11NetWmWindowTypeCombo = Qt::WA_X11NetWmWindowTypeCombo, WA_X11NetWmWindowTypeDND = Qt::WA_X11NetWmWindowTypeDND, WA_MacFrameworkScaled = Qt::WA_MacFrameworkScaled, WA_SetWindowModality = Qt::WA_SetWindowModality, WA_WState_WindowOpacitySet = Qt::WA_WState_WindowOpacitySet, WA_TranslucentBackground = Qt::WA_TranslucentBackground, WA_AcceptTouchEvents = Qt::WA_AcceptTouchEvents, WA_WState_AcceptedTouchBeginEvent = Qt::WA_WState_AcceptedTouchBeginEvent, WA_TouchPadAcceptSingleTouchEvents = Qt::WA_TouchPadAcceptSingleTouchEvents, WA_X11DoNotAcceptFocus = Qt::WA_X11DoNotAcceptFocus, WA_MacNoShadow = Qt::WA_MacNoShadow, WA_AttributeCount = Qt::WA_AttributeCount};
908 enum GestureState{
912 enum GestureState{
909 NoGesture = Qt::NoGesture, GestureStarted = Qt::GestureStarted, GestureUpdated = Qt::GestureUpdated, GestureFinished = Qt::GestureFinished, GestureCanceled = Qt::GestureCanceled};
913 NoGesture = Qt::NoGesture, GestureStarted = Qt::GestureStarted, GestureUpdated = Qt::GestureUpdated, GestureFinished = Qt::GestureFinished, GestureCanceled = Qt::GestureCanceled};
910 enum GlobalColor{
914 enum GlobalColor{
911 color0 = Qt::color0, color1 = Qt::color1, black = Qt::black, white = Qt::white, darkGray = Qt::darkGray, gray = Qt::gray, lightGray = Qt::lightGray, red = Qt::red, green = Qt::green, blue = Qt::blue, cyan = Qt::cyan, magenta = Qt::magenta, yellow = Qt::yellow, darkRed = Qt::darkRed, darkGreen = Qt::darkGreen, darkBlue = Qt::darkBlue, darkCyan = Qt::darkCyan, darkMagenta = Qt::darkMagenta, darkYellow = Qt::darkYellow, transparent = Qt::transparent};
915 color0 = Qt::color0, color1 = Qt::color1, black = Qt::black, white = Qt::white, darkGray = Qt::darkGray, gray = Qt::gray, lightGray = Qt::lightGray, red = Qt::red, green = Qt::green, blue = Qt::blue, cyan = Qt::cyan, magenta = Qt::magenta, yellow = Qt::yellow, darkRed = Qt::darkRed, darkGreen = Qt::darkGreen, darkBlue = Qt::darkBlue, darkCyan = Qt::darkCyan, darkMagenta = Qt::darkMagenta, darkYellow = Qt::darkYellow, transparent = Qt::transparent};
912 enum PenStyle{
916 enum PenStyle{
913 NoPen = Qt::NoPen, SolidLine = Qt::SolidLine, DashLine = Qt::DashLine, DotLine = Qt::DotLine, DashDotLine = Qt::DashDotLine, DashDotDotLine = Qt::DashDotDotLine, CustomDashLine = Qt::CustomDashLine, MPenStyle = Qt::MPenStyle};
917 NoPen = Qt::NoPen, SolidLine = Qt::SolidLine, DashLine = Qt::DashLine, DotLine = Qt::DotLine, DashDotLine = Qt::DashDotLine, DashDotDotLine = Qt::DashDotDotLine, CustomDashLine = Qt::CustomDashLine, MPenStyle = Qt::MPenStyle};
914 enum NavigationMode{
918 enum NavigationMode{
915 NavigationModeNone = Qt::NavigationModeNone, NavigationModeKeypadTabOrder = Qt::NavigationModeKeypadTabOrder, NavigationModeKeypadDirectional = Qt::NavigationModeKeypadDirectional, NavigationModeCursorAuto = Qt::NavigationModeCursorAuto, NavigationModeCursorForceVisible = Qt::NavigationModeCursorForceVisible};
919 NavigationModeNone = Qt::NavigationModeNone, NavigationModeKeypadTabOrder = Qt::NavigationModeKeypadTabOrder, NavigationModeKeypadDirectional = Qt::NavigationModeKeypadDirectional, NavigationModeCursorAuto = Qt::NavigationModeCursorAuto, NavigationModeCursorForceVisible = Qt::NavigationModeCursorForceVisible};
916 enum GestureFlag{
920 enum GestureFlag{
917 DontStartGestureOnChildren = Qt::DontStartGestureOnChildren, ReceivePartialGestures = Qt::ReceivePartialGestures, IgnoredGesturesPropagateToParent = Qt::IgnoredGesturesPropagateToParent};
921 DontStartGestureOnChildren = Qt::DontStartGestureOnChildren, ReceivePartialGestures = Qt::ReceivePartialGestures, IgnoredGesturesPropagateToParent = Qt::IgnoredGesturesPropagateToParent};
918 enum ToolBarArea{
922 enum ToolBarArea{
919 LeftToolBarArea = Qt::LeftToolBarArea, RightToolBarArea = Qt::RightToolBarArea, TopToolBarArea = Qt::TopToolBarArea, BottomToolBarArea = Qt::BottomToolBarArea, ToolBarArea_Mask = Qt::ToolBarArea_Mask, AllToolBarAreas = Qt::AllToolBarAreas, NoToolBarArea = Qt::NoToolBarArea};
923 LeftToolBarArea = Qt::LeftToolBarArea, RightToolBarArea = Qt::RightToolBarArea, TopToolBarArea = Qt::TopToolBarArea, BottomToolBarArea = Qt::BottomToolBarArea, ToolBarArea_Mask = Qt::ToolBarArea_Mask, AllToolBarAreas = Qt::AllToolBarAreas, NoToolBarArea = Qt::NoToolBarArea};
920 enum WindowFrameSection{
924 enum WindowFrameSection{
921 NoSection = Qt::NoSection, LeftSection = Qt::LeftSection, TopLeftSection = Qt::TopLeftSection, TopSection = Qt::TopSection, TopRightSection = Qt::TopRightSection, RightSection = Qt::RightSection, BottomRightSection = Qt::BottomRightSection, BottomSection = Qt::BottomSection, BottomLeftSection = Qt::BottomLeftSection, TitleBarArea = Qt::TitleBarArea};
925 NoSection = Qt::NoSection, LeftSection = Qt::LeftSection, TopLeftSection = Qt::TopLeftSection, TopSection = Qt::TopSection, TopRightSection = Qt::TopRightSection, RightSection = Qt::RightSection, BottomRightSection = Qt::BottomRightSection, BottomSection = Qt::BottomSection, BottomLeftSection = Qt::BottomLeftSection, TitleBarArea = Qt::TitleBarArea};
922 enum PenCapStyle{
926 enum PenCapStyle{
923 FlatCap = Qt::FlatCap, SquareCap = Qt::SquareCap, RoundCap = Qt::RoundCap, MPenCapStyle = Qt::MPenCapStyle};
927 FlatCap = Qt::FlatCap, SquareCap = Qt::SquareCap, RoundCap = Qt::RoundCap, MPenCapStyle = Qt::MPenCapStyle};
924 enum SizeHint{
928 enum SizeHint{
925 MinimumSize = Qt::MinimumSize, PreferredSize = Qt::PreferredSize, MaximumSize = Qt::MaximumSize, MinimumDescent = Qt::MinimumDescent, NSizeHints = Qt::NSizeHints};
929 MinimumSize = Qt::MinimumSize, PreferredSize = Qt::PreferredSize, MaximumSize = Qt::MaximumSize, MinimumDescent = Qt::MinimumDescent, NSizeHints = Qt::NSizeHints};
926 enum DayOfWeek{
930 enum DayOfWeek{
927 Monday = Qt::Monday, Tuesday = Qt::Tuesday, Wednesday = Qt::Wednesday, Thursday = Qt::Thursday, Friday = Qt::Friday, Saturday = Qt::Saturday, Sunday = Qt::Sunday};
931 Monday = Qt::Monday, Tuesday = Qt::Tuesday, Wednesday = Qt::Wednesday, Thursday = Qt::Thursday, Friday = Qt::Friday, Saturday = Qt::Saturday, Sunday = Qt::Sunday};
928 enum WindowModality{
932 enum WindowModality{
929 NonModal = Qt::NonModal, WindowModal = Qt::WindowModal, ApplicationModal = Qt::ApplicationModal};
933 NonModal = Qt::NonModal, WindowModal = Qt::WindowModal, ApplicationModal = Qt::ApplicationModal};
930 enum MatchFlag{
934 enum MatchFlag{
931 MatchExactly = Qt::MatchExactly, MatchContains = Qt::MatchContains, MatchStartsWith = Qt::MatchStartsWith, MatchEndsWith = Qt::MatchEndsWith, MatchRegExp = Qt::MatchRegExp, MatchWildcard = Qt::MatchWildcard, MatchFixedString = Qt::MatchFixedString, MatchCaseSensitive = Qt::MatchCaseSensitive, MatchWrap = Qt::MatchWrap, MatchRecursive = Qt::MatchRecursive};
935 MatchExactly = Qt::MatchExactly, MatchContains = Qt::MatchContains, MatchStartsWith = Qt::MatchStartsWith, MatchEndsWith = Qt::MatchEndsWith, MatchRegExp = Qt::MatchRegExp, MatchWildcard = Qt::MatchWildcard, MatchFixedString = Qt::MatchFixedString, MatchCaseSensitive = Qt::MatchCaseSensitive, MatchWrap = Qt::MatchWrap, MatchRecursive = Qt::MatchRecursive};
932 enum DockWidgetAreaSizes{
936 enum DockWidgetAreaSizes{
933 NDockWidgetAreas = Qt::NDockWidgetAreas};
937 NDockWidgetAreas = Qt::NDockWidgetAreas};
934 enum FindChildOption{
938 enum FindChildOption{
935 FindDirectChildrenOnly = Qt::FindDirectChildrenOnly, FindChildrenRecursively = Qt::FindChildrenRecursively};
939 FindDirectChildrenOnly = Qt::FindDirectChildrenOnly, FindChildrenRecursively = Qt::FindChildrenRecursively};
936 enum AnchorPoint{
940 enum AnchorPoint{
937 AnchorLeft = Qt::AnchorLeft, AnchorHorizontalCenter = Qt::AnchorHorizontalCenter, AnchorRight = Qt::AnchorRight, AnchorTop = Qt::AnchorTop, AnchorVerticalCenter = Qt::AnchorVerticalCenter, AnchorBottom = Qt::AnchorBottom};
941 AnchorLeft = Qt::AnchorLeft, AnchorHorizontalCenter = Qt::AnchorHorizontalCenter, AnchorRight = Qt::AnchorRight, AnchorTop = Qt::AnchorTop, AnchorVerticalCenter = Qt::AnchorVerticalCenter, AnchorBottom = Qt::AnchorBottom};
938 enum CaseSensitivity{
942 enum CaseSensitivity{
939 CaseInsensitive = Qt::CaseInsensitive, CaseSensitive = Qt::CaseSensitive};
943 CaseInsensitive = Qt::CaseInsensitive, CaseSensitive = Qt::CaseSensitive};
940 enum TextFlag{
944 enum TextFlag{
941 TextSingleLine = Qt::TextSingleLine, TextDontClip = Qt::TextDontClip, TextExpandTabs = Qt::TextExpandTabs, TextShowMnemonic = Qt::TextShowMnemonic, TextWordWrap = Qt::TextWordWrap, TextWrapAnywhere = Qt::TextWrapAnywhere, TextDontPrint = Qt::TextDontPrint, TextIncludeTrailingSpaces = Qt::TextIncludeTrailingSpaces, TextHideMnemonic = Qt::TextHideMnemonic, TextJustificationForced = Qt::TextJustificationForced, TextForceLeftToRight = Qt::TextForceLeftToRight, TextForceRightToLeft = Qt::TextForceRightToLeft, TextLongestVariant = Qt::TextLongestVariant, TextBypassShaping = Qt::TextBypassShaping};
945 TextSingleLine = Qt::TextSingleLine, TextDontClip = Qt::TextDontClip, TextExpandTabs = Qt::TextExpandTabs, TextShowMnemonic = Qt::TextShowMnemonic, TextWordWrap = Qt::TextWordWrap, TextWrapAnywhere = Qt::TextWrapAnywhere, TextDontPrint = Qt::TextDontPrint, TextIncludeTrailingSpaces = Qt::TextIncludeTrailingSpaces, TextHideMnemonic = Qt::TextHideMnemonic, TextJustificationForced = Qt::TextJustificationForced, TextForceLeftToRight = Qt::TextForceLeftToRight, TextForceRightToLeft = Qt::TextForceRightToLeft, TextLongestVariant = Qt::TextLongestVariant, TextBypassShaping = Qt::TextBypassShaping};
942 enum BrushStyle{
946 enum BrushStyle{
943 NoBrush = Qt::NoBrush, SolidPattern = Qt::SolidPattern, Dense1Pattern = Qt::Dense1Pattern, Dense2Pattern = Qt::Dense2Pattern, Dense3Pattern = Qt::Dense3Pattern, Dense4Pattern = Qt::Dense4Pattern, Dense5Pattern = Qt::Dense5Pattern, Dense6Pattern = Qt::Dense6Pattern, Dense7Pattern = Qt::Dense7Pattern, HorPattern = Qt::HorPattern, VerPattern = Qt::VerPattern, CrossPattern = Qt::CrossPattern, BDiagPattern = Qt::BDiagPattern, FDiagPattern = Qt::FDiagPattern, DiagCrossPattern = Qt::DiagCrossPattern, LinearGradientPattern = Qt::LinearGradientPattern, RadialGradientPattern = Qt::RadialGradientPattern, ConicalGradientPattern = Qt::ConicalGradientPattern, TexturePattern = Qt::TexturePattern};
947 NoBrush = Qt::NoBrush, SolidPattern = Qt::SolidPattern, Dense1Pattern = Qt::Dense1Pattern, Dense2Pattern = Qt::Dense2Pattern, Dense3Pattern = Qt::Dense3Pattern, Dense4Pattern = Qt::Dense4Pattern, Dense5Pattern = Qt::Dense5Pattern, Dense6Pattern = Qt::Dense6Pattern, Dense7Pattern = Qt::Dense7Pattern, HorPattern = Qt::HorPattern, VerPattern = Qt::VerPattern, CrossPattern = Qt::CrossPattern, BDiagPattern = Qt::BDiagPattern, FDiagPattern = Qt::FDiagPattern, DiagCrossPattern = Qt::DiagCrossPattern, LinearGradientPattern = Qt::LinearGradientPattern, RadialGradientPattern = Qt::RadialGradientPattern, ConicalGradientPattern = Qt::ConicalGradientPattern, TexturePattern = Qt::TexturePattern};
944 enum ItemSelectionMode{
948 enum ItemSelectionMode{
945 ContainsItemShape = Qt::ContainsItemShape, IntersectsItemShape = Qt::IntersectsItemShape, ContainsItemBoundingRect = Qt::ContainsItemBoundingRect, IntersectsItemBoundingRect = Qt::IntersectsItemBoundingRect};
949 ContainsItemShape = Qt::ContainsItemShape, IntersectsItemShape = Qt::IntersectsItemShape, ContainsItemBoundingRect = Qt::ContainsItemBoundingRect, IntersectsItemBoundingRect = Qt::IntersectsItemBoundingRect};
946 enum DateFormat{
950 enum DateFormat{
947 TextDate = Qt::TextDate, ISODate = Qt::ISODate, SystemLocaleDate = Qt::SystemLocaleDate, LocalDate = Qt::LocalDate, LocaleDate = Qt::LocaleDate, SystemLocaleShortDate = Qt::SystemLocaleShortDate, SystemLocaleLongDate = Qt::SystemLocaleLongDate, DefaultLocaleShortDate = Qt::DefaultLocaleShortDate, DefaultLocaleLongDate = Qt::DefaultLocaleLongDate};
951 TextDate = Qt::TextDate, ISODate = Qt::ISODate, SystemLocaleDate = Qt::SystemLocaleDate, LocalDate = Qt::LocalDate, LocaleDate = Qt::LocaleDate, SystemLocaleShortDate = Qt::SystemLocaleShortDate, SystemLocaleLongDate = Qt::SystemLocaleLongDate, DefaultLocaleShortDate = Qt::DefaultLocaleShortDate, DefaultLocaleLongDate = Qt::DefaultLocaleLongDate};
948 enum ApplicationAttribute{
952 enum ApplicationAttribute{
949 AA_ImmediateWidgetCreation = Qt::AA_ImmediateWidgetCreation, AA_MSWindowsUseDirect3DByDefault = Qt::AA_MSWindowsUseDirect3DByDefault, AA_DontShowIconsInMenus = Qt::AA_DontShowIconsInMenus, AA_NativeWindows = Qt::AA_NativeWindows, AA_DontCreateNativeWidgetSiblings = Qt::AA_DontCreateNativeWidgetSiblings, AA_MacPluginApplication = Qt::AA_MacPluginApplication, AA_DontUseNativeMenuBar = Qt::AA_DontUseNativeMenuBar, AA_MacDontSwapCtrlAndMeta = Qt::AA_MacDontSwapCtrlAndMeta, AA_Use96Dpi = Qt::AA_Use96Dpi, AA_X11InitThreads = Qt::AA_X11InitThreads, AA_SynthesizeTouchForUnhandledMouseEvents = Qt::AA_SynthesizeTouchForUnhandledMouseEvents, AA_SynthesizeMouseForUnhandledTouchEvents = Qt::AA_SynthesizeMouseForUnhandledTouchEvents, AA_AttributeCount = Qt::AA_AttributeCount};
953 AA_ImmediateWidgetCreation = Qt::AA_ImmediateWidgetCreation, AA_MSWindowsUseDirect3DByDefault = Qt::AA_MSWindowsUseDirect3DByDefault, AA_DontShowIconsInMenus = Qt::AA_DontShowIconsInMenus, AA_NativeWindows = Qt::AA_NativeWindows, AA_DontCreateNativeWidgetSiblings = Qt::AA_DontCreateNativeWidgetSiblings, AA_MacPluginApplication = Qt::AA_MacPluginApplication, AA_DontUseNativeMenuBar = Qt::AA_DontUseNativeMenuBar, AA_MacDontSwapCtrlAndMeta = Qt::AA_MacDontSwapCtrlAndMeta, AA_Use96Dpi = Qt::AA_Use96Dpi, AA_X11InitThreads = Qt::AA_X11InitThreads, AA_SynthesizeTouchForUnhandledMouseEvents = Qt::AA_SynthesizeTouchForUnhandledMouseEvents, AA_SynthesizeMouseForUnhandledTouchEvents = Qt::AA_SynthesizeMouseForUnhandledTouchEvents, AA_AttributeCount = Qt::AA_AttributeCount};
950 enum ItemFlag{
954 enum ItemFlag{
951 NoItemFlags = Qt::NoItemFlags, ItemIsSelectable = Qt::ItemIsSelectable, ItemIsEditable = Qt::ItemIsEditable, ItemIsDragEnabled = Qt::ItemIsDragEnabled, ItemIsDropEnabled = Qt::ItemIsDropEnabled, ItemIsUserCheckable = Qt::ItemIsUserCheckable, ItemIsEnabled = Qt::ItemIsEnabled, ItemIsTristate = Qt::ItemIsTristate};
955 NoItemFlags = Qt::NoItemFlags, ItemIsSelectable = Qt::ItemIsSelectable, ItemIsEditable = Qt::ItemIsEditable, ItemIsDragEnabled = Qt::ItemIsDragEnabled, ItemIsDropEnabled = Qt::ItemIsDropEnabled, ItemIsUserCheckable = Qt::ItemIsUserCheckable, ItemIsEnabled = Qt::ItemIsEnabled, ItemIsTristate = Qt::ItemIsTristate};
952 enum ScrollBarPolicy{
956 enum ScrollBarPolicy{
953 ScrollBarAsNeeded = Qt::ScrollBarAsNeeded, ScrollBarAlwaysOff = Qt::ScrollBarAlwaysOff, ScrollBarAlwaysOn = Qt::ScrollBarAlwaysOn};
957 ScrollBarAsNeeded = Qt::ScrollBarAsNeeded, ScrollBarAlwaysOff = Qt::ScrollBarAlwaysOff, ScrollBarAlwaysOn = Qt::ScrollBarAlwaysOn};
954 enum WhiteSpaceMode{
958 enum WhiteSpaceMode{
955 WhiteSpaceNormal = Qt::WhiteSpaceNormal, WhiteSpacePre = Qt::WhiteSpacePre, WhiteSpaceNoWrap = Qt::WhiteSpaceNoWrap, WhiteSpaceModeUndefined = Qt::WhiteSpaceModeUndefined};
959 WhiteSpaceNormal = Qt::WhiteSpaceNormal, WhiteSpacePre = Qt::WhiteSpacePre, WhiteSpaceNoWrap = Qt::WhiteSpaceNoWrap, WhiteSpaceModeUndefined = Qt::WhiteSpaceModeUndefined};
956 enum TimerType{
960 enum TimerType{
957 PreciseTimer = Qt::PreciseTimer, CoarseTimer = Qt::CoarseTimer, VeryCoarseTimer = Qt::VeryCoarseTimer};
961 PreciseTimer = Qt::PreciseTimer, CoarseTimer = Qt::CoarseTimer, VeryCoarseTimer = Qt::VeryCoarseTimer};
958 enum DropAction{
962 enum DropAction{
959 CopyAction = Qt::CopyAction, MoveAction = Qt::MoveAction, LinkAction = Qt::LinkAction, ActionMask = Qt::ActionMask, TargetMoveAction = Qt::TargetMoveAction, IgnoreAction = Qt::IgnoreAction};
963 CopyAction = Qt::CopyAction, MoveAction = Qt::MoveAction, LinkAction = Qt::LinkAction, ActionMask = Qt::ActionMask, TargetMoveAction = Qt::TargetMoveAction, IgnoreAction = Qt::IgnoreAction};
960 enum FocusPolicy{
964 enum FocusPolicy{
961 NoFocus = Qt::NoFocus, TabFocus = Qt::TabFocus, ClickFocus = Qt::ClickFocus, StrongFocus = Qt::StrongFocus, WheelFocus = Qt::WheelFocus};
965 NoFocus = Qt::NoFocus, TabFocus = Qt::TabFocus, ClickFocus = Qt::ClickFocus, StrongFocus = Qt::StrongFocus, WheelFocus = Qt::WheelFocus};
962 enum CursorShape{
966 enum CursorShape{
963 ArrowCursor = Qt::ArrowCursor, UpArrowCursor = Qt::UpArrowCursor, CrossCursor = Qt::CrossCursor, WaitCursor = Qt::WaitCursor, IBeamCursor = Qt::IBeamCursor, SizeVerCursor = Qt::SizeVerCursor, SizeHorCursor = Qt::SizeHorCursor, SizeBDiagCursor = Qt::SizeBDiagCursor, SizeFDiagCursor = Qt::SizeFDiagCursor, SizeAllCursor = Qt::SizeAllCursor, BlankCursor = Qt::BlankCursor, SplitVCursor = Qt::SplitVCursor, SplitHCursor = Qt::SplitHCursor, PointingHandCursor = Qt::PointingHandCursor, ForbiddenCursor = Qt::ForbiddenCursor, WhatsThisCursor = Qt::WhatsThisCursor, BusyCursor = Qt::BusyCursor, OpenHandCursor = Qt::OpenHandCursor, ClosedHandCursor = Qt::ClosedHandCursor, DragCopyCursor = Qt::DragCopyCursor, DragMoveCursor = Qt::DragMoveCursor, DragLinkCursor = Qt::DragLinkCursor, LastCursor = Qt::LastCursor, BitmapCursor = Qt::BitmapCursor, CustomCursor = Qt::CustomCursor};
967 ArrowCursor = Qt::ArrowCursor, UpArrowCursor = Qt::UpArrowCursor, CrossCursor = Qt::CrossCursor, WaitCursor = Qt::WaitCursor, IBeamCursor = Qt::IBeamCursor, SizeVerCursor = Qt::SizeVerCursor, SizeHorCursor = Qt::SizeHorCursor, SizeBDiagCursor = Qt::SizeBDiagCursor, SizeFDiagCursor = Qt::SizeFDiagCursor, SizeAllCursor = Qt::SizeAllCursor, BlankCursor = Qt::BlankCursor, SplitVCursor = Qt::SplitVCursor, SplitHCursor = Qt::SplitHCursor, PointingHandCursor = Qt::PointingHandCursor, ForbiddenCursor = Qt::ForbiddenCursor, WhatsThisCursor = Qt::WhatsThisCursor, BusyCursor = Qt::BusyCursor, OpenHandCursor = Qt::OpenHandCursor, ClosedHandCursor = Qt::ClosedHandCursor, DragCopyCursor = Qt::DragCopyCursor, DragMoveCursor = Qt::DragMoveCursor, DragLinkCursor = Qt::DragLinkCursor, LastCursor = Qt::LastCursor, BitmapCursor = Qt::BitmapCursor, CustomCursor = Qt::CustomCursor};
964 enum TouchPointState{
968 enum TouchPointState{
965 TouchPointPressed = Qt::TouchPointPressed, TouchPointMoved = Qt::TouchPointMoved, TouchPointStationary = Qt::TouchPointStationary, TouchPointReleased = Qt::TouchPointReleased};
969 TouchPointPressed = Qt::TouchPointPressed, TouchPointMoved = Qt::TouchPointMoved, TouchPointStationary = Qt::TouchPointStationary, TouchPointReleased = Qt::TouchPointReleased};
966 enum CursorMoveStyle{
970 enum CursorMoveStyle{
967 LogicalMoveStyle = Qt::LogicalMoveStyle, VisualMoveStyle = Qt::VisualMoveStyle};
971 LogicalMoveStyle = Qt::LogicalMoveStyle, VisualMoveStyle = Qt::VisualMoveStyle};
968 enum InputMethodHint{
972 enum InputMethodHint{
969 ImhNone = Qt::ImhNone, ImhHiddenText = Qt::ImhHiddenText, ImhSensitiveData = Qt::ImhSensitiveData, ImhNoAutoUppercase = Qt::ImhNoAutoUppercase, ImhPreferNumbers = Qt::ImhPreferNumbers, ImhPreferUppercase = Qt::ImhPreferUppercase, ImhPreferLowercase = Qt::ImhPreferLowercase, ImhNoPredictiveText = Qt::ImhNoPredictiveText, ImhDate = Qt::ImhDate, ImhTime = Qt::ImhTime, ImhPreferLatin = Qt::ImhPreferLatin, ImhDigitsOnly = Qt::ImhDigitsOnly, ImhFormattedNumbersOnly = Qt::ImhFormattedNumbersOnly, ImhUppercaseOnly = Qt::ImhUppercaseOnly, ImhLowercaseOnly = Qt::ImhLowercaseOnly, ImhDialableCharactersOnly = Qt::ImhDialableCharactersOnly, ImhEmailCharactersOnly = Qt::ImhEmailCharactersOnly, ImhUrlCharactersOnly = Qt::ImhUrlCharactersOnly, ImhLatinOnly = Qt::ImhLatinOnly, ImhExclusiveInputMask = Qt::ImhExclusiveInputMask};
973 ImhNone = Qt::ImhNone, ImhHiddenText = Qt::ImhHiddenText, ImhSensitiveData = Qt::ImhSensitiveData, ImhNoAutoUppercase = Qt::ImhNoAutoUppercase, ImhPreferNumbers = Qt::ImhPreferNumbers, ImhPreferUppercase = Qt::ImhPreferUppercase, ImhPreferLowercase = Qt::ImhPreferLowercase, ImhNoPredictiveText = Qt::ImhNoPredictiveText, ImhDate = Qt::ImhDate, ImhTime = Qt::ImhTime, ImhPreferLatin = Qt::ImhPreferLatin, ImhDigitsOnly = Qt::ImhDigitsOnly, ImhFormattedNumbersOnly = Qt::ImhFormattedNumbersOnly, ImhUppercaseOnly = Qt::ImhUppercaseOnly, ImhLowercaseOnly = Qt::ImhLowercaseOnly, ImhDialableCharactersOnly = Qt::ImhDialableCharactersOnly, ImhEmailCharactersOnly = Qt::ImhEmailCharactersOnly, ImhUrlCharactersOnly = Qt::ImhUrlCharactersOnly, ImhLatinOnly = Qt::ImhLatinOnly, ImhExclusiveInputMask = Qt::ImhExclusiveInputMask};
970 enum ArrowType{
974 enum ArrowType{
971 NoArrow = Qt::NoArrow, UpArrow = Qt::UpArrow, DownArrow = Qt::DownArrow, LeftArrow = Qt::LeftArrow, RightArrow = Qt::RightArrow};
975 NoArrow = Qt::NoArrow, UpArrow = Qt::UpArrow, DownArrow = Qt::DownArrow, LeftArrow = Qt::LeftArrow, RightArrow = Qt::RightArrow};
972 enum TextFormat{
976 enum TextFormat{
973 PlainText = Qt::PlainText, RichText = Qt::RichText, AutoText = Qt::AutoText};
977 PlainText = Qt::PlainText, RichText = Qt::RichText, AutoText = Qt::AutoText};
974 enum HitTestAccuracy{
978 enum HitTestAccuracy{
975 ExactHit = Qt::ExactHit, FuzzyHit = Qt::FuzzyHit};
979 ExactHit = Qt::ExactHit, FuzzyHit = Qt::FuzzyHit};
976 enum ToolButtonStyle{
980 enum ToolButtonStyle{
977 ToolButtonIconOnly = Qt::ToolButtonIconOnly, ToolButtonTextOnly = Qt::ToolButtonTextOnly, ToolButtonTextBesideIcon = Qt::ToolButtonTextBesideIcon, ToolButtonTextUnderIcon = Qt::ToolButtonTextUnderIcon, ToolButtonFollowStyle = Qt::ToolButtonFollowStyle};
981 ToolButtonIconOnly = Qt::ToolButtonIconOnly, ToolButtonTextOnly = Qt::ToolButtonTextOnly, ToolButtonTextBesideIcon = Qt::ToolButtonTextBesideIcon, ToolButtonTextUnderIcon = Qt::ToolButtonTextUnderIcon, ToolButtonFollowStyle = Qt::ToolButtonFollowStyle};
978 enum FocusReason{
982 enum FocusReason{
979 MouseFocusReason = Qt::MouseFocusReason, TabFocusReason = Qt::TabFocusReason, BacktabFocusReason = Qt::BacktabFocusReason, ActiveWindowFocusReason = Qt::ActiveWindowFocusReason, PopupFocusReason = Qt::PopupFocusReason, ShortcutFocusReason = Qt::ShortcutFocusReason, MenuBarFocusReason = Qt::MenuBarFocusReason, OtherFocusReason = Qt::OtherFocusReason, NoFocusReason = Qt::NoFocusReason};
983 MouseFocusReason = Qt::MouseFocusReason, TabFocusReason = Qt::TabFocusReason, BacktabFocusReason = Qt::BacktabFocusReason, ActiveWindowFocusReason = Qt::ActiveWindowFocusReason, PopupFocusReason = Qt::PopupFocusReason, ShortcutFocusReason = Qt::ShortcutFocusReason, MenuBarFocusReason = Qt::MenuBarFocusReason, OtherFocusReason = Qt::OtherFocusReason, NoFocusReason = Qt::NoFocusReason};
980 enum TextElideMode{
984 enum TextElideMode{
981 ElideLeft = Qt::ElideLeft, ElideRight = Qt::ElideRight, ElideMiddle = Qt::ElideMiddle, ElideNone = Qt::ElideNone};
985 ElideLeft = Qt::ElideLeft, ElideRight = Qt::ElideRight, ElideMiddle = Qt::ElideMiddle, ElideNone = Qt::ElideNone};
982 enum CoordinateSystem{
986 enum CoordinateSystem{
983 DeviceCoordinates = Qt::DeviceCoordinates, LogicalCoordinates = Qt::LogicalCoordinates};
987 DeviceCoordinates = Qt::DeviceCoordinates, LogicalCoordinates = Qt::LogicalCoordinates};
984 enum KeyboardModifier{
988 enum KeyboardModifier{
985 NoModifier = Qt::NoModifier, ShiftModifier = Qt::ShiftModifier, ControlModifier = Qt::ControlModifier, AltModifier = Qt::AltModifier, MetaModifier = Qt::MetaModifier, KeypadModifier = Qt::KeypadModifier, GroupSwitchModifier = Qt::GroupSwitchModifier, KeyboardModifierMask = Qt::KeyboardModifierMask};
989 NoModifier = Qt::NoModifier, ShiftModifier = Qt::ShiftModifier, ControlModifier = Qt::ControlModifier, AltModifier = Qt::AltModifier, MetaModifier = Qt::MetaModifier, KeypadModifier = Qt::KeypadModifier, GroupSwitchModifier = Qt::GroupSwitchModifier, KeyboardModifierMask = Qt::KeyboardModifierMask};
986 enum UIEffect{
990 enum UIEffect{
987 UI_General = Qt::UI_General, UI_AnimateMenu = Qt::UI_AnimateMenu, UI_FadeMenu = Qt::UI_FadeMenu, UI_AnimateCombo = Qt::UI_AnimateCombo, UI_AnimateTooltip = Qt::UI_AnimateTooltip, UI_FadeTooltip = Qt::UI_FadeTooltip, UI_AnimateToolBox = Qt::UI_AnimateToolBox};
991 UI_General = Qt::UI_General, UI_AnimateMenu = Qt::UI_AnimateMenu, UI_FadeMenu = Qt::UI_FadeMenu, UI_AnimateCombo = Qt::UI_AnimateCombo, UI_AnimateTooltip = Qt::UI_AnimateTooltip, UI_FadeTooltip = Qt::UI_FadeTooltip, UI_AnimateToolBox = Qt::UI_AnimateToolBox};
988 enum ScreenOrientation{
992 enum ScreenOrientation{
989 PrimaryOrientation = Qt::PrimaryOrientation, PortraitOrientation = Qt::PortraitOrientation, LandscapeOrientation = Qt::LandscapeOrientation, InvertedPortraitOrientation = Qt::InvertedPortraitOrientation, InvertedLandscapeOrientation = Qt::InvertedLandscapeOrientation};
993 PrimaryOrientation = Qt::PrimaryOrientation, PortraitOrientation = Qt::PortraitOrientation, LandscapeOrientation = Qt::LandscapeOrientation, InvertedPortraitOrientation = Qt::InvertedPortraitOrientation, InvertedLandscapeOrientation = Qt::InvertedLandscapeOrientation};
990 enum ImageConversionFlag{
994 enum ImageConversionFlag{
991 ColorMode_Mask = Qt::ColorMode_Mask, AutoColor = Qt::AutoColor, ColorOnly = Qt::ColorOnly, MonoOnly = Qt::MonoOnly, AlphaDither_Mask = Qt::AlphaDither_Mask, ThresholdAlphaDither = Qt::ThresholdAlphaDither, OrderedAlphaDither = Qt::OrderedAlphaDither, DiffuseAlphaDither = Qt::DiffuseAlphaDither, NoAlpha = Qt::NoAlpha, Dither_Mask = Qt::Dither_Mask, DiffuseDither = Qt::DiffuseDither, OrderedDither = Qt::OrderedDither, ThresholdDither = Qt::ThresholdDither, DitherMode_Mask = Qt::DitherMode_Mask, AutoDither = Qt::AutoDither, PreferDither = Qt::PreferDither, AvoidDither = Qt::AvoidDither, NoOpaqueDetection = Qt::NoOpaqueDetection, NoFormatConversion = Qt::NoFormatConversion};
995 ColorMode_Mask = Qt::ColorMode_Mask, AutoColor = Qt::AutoColor, ColorOnly = Qt::ColorOnly, MonoOnly = Qt::MonoOnly, AlphaDither_Mask = Qt::AlphaDither_Mask, ThresholdAlphaDither = Qt::ThresholdAlphaDither, OrderedAlphaDither = Qt::OrderedAlphaDither, DiffuseAlphaDither = Qt::DiffuseAlphaDither, NoAlpha = Qt::NoAlpha, Dither_Mask = Qt::Dither_Mask, DiffuseDither = Qt::DiffuseDither, OrderedDither = Qt::OrderedDither, ThresholdDither = Qt::ThresholdDither, DitherMode_Mask = Qt::DitherMode_Mask, AutoDither = Qt::AutoDither, PreferDither = Qt::PreferDither, AvoidDither = Qt::AvoidDither, NoOpaqueDetection = Qt::NoOpaqueDetection, NoFormatConversion = Qt::NoFormatConversion};
992 enum TransformationMode{
996 enum TransformationMode{
993 FastTransformation = Qt::FastTransformation, SmoothTransformation = Qt::SmoothTransformation};
997 FastTransformation = Qt::FastTransformation, SmoothTransformation = Qt::SmoothTransformation};
994 enum PenJoinStyle{
998 enum PenJoinStyle{
995 MiterJoin = Qt::MiterJoin, BevelJoin = Qt::BevelJoin, RoundJoin = Qt::RoundJoin, SvgMiterJoin = Qt::SvgMiterJoin, MPenJoinStyle = Qt::MPenJoinStyle};
999 MiterJoin = Qt::MiterJoin, BevelJoin = Qt::BevelJoin, RoundJoin = Qt::RoundJoin, SvgMiterJoin = Qt::SvgMiterJoin, MPenJoinStyle = Qt::MPenJoinStyle};
996 enum EventPriority{
1000 enum EventPriority{
997 HighEventPriority = Qt::HighEventPriority, NormalEventPriority = Qt::NormalEventPriority, LowEventPriority = Qt::LowEventPriority};
1001 HighEventPriority = Qt::HighEventPriority, NormalEventPriority = Qt::NormalEventPriority, LowEventPriority = Qt::LowEventPriority};
998 enum LayoutDirection{
1002 enum LayoutDirection{
999 LeftToRight = Qt::LeftToRight, RightToLeft = Qt::RightToLeft, LayoutDirectionAuto = Qt::LayoutDirectionAuto};
1003 LeftToRight = Qt::LeftToRight, RightToLeft = Qt::RightToLeft, LayoutDirectionAuto = Qt::LayoutDirectionAuto};
1000 enum TextInteractionFlag{
1004 enum TextInteractionFlag{
1001 NoTextInteraction = Qt::NoTextInteraction, TextSelectableByMouse = Qt::TextSelectableByMouse, TextSelectableByKeyboard = Qt::TextSelectableByKeyboard, LinksAccessibleByMouse = Qt::LinksAccessibleByMouse, LinksAccessibleByKeyboard = Qt::LinksAccessibleByKeyboard, TextEditable = Qt::TextEditable, TextEditorInteraction = Qt::TextEditorInteraction, TextBrowserInteraction = Qt::TextBrowserInteraction};
1005 NoTextInteraction = Qt::NoTextInteraction, TextSelectableByMouse = Qt::TextSelectableByMouse, TextSelectableByKeyboard = Qt::TextSelectableByKeyboard, LinksAccessibleByMouse = Qt::LinksAccessibleByMouse, LinksAccessibleByKeyboard = Qt::LinksAccessibleByKeyboard, TextEditable = Qt::TextEditable, TextEditorInteraction = Qt::TextEditorInteraction, TextBrowserInteraction = Qt::TextBrowserInteraction};
1002 enum Corner{
1006 enum Corner{
1003 TopLeftCorner = Qt::TopLeftCorner, TopRightCorner = Qt::TopRightCorner, BottomLeftCorner = Qt::BottomLeftCorner, BottomRightCorner = Qt::BottomRightCorner};
1007 TopLeftCorner = Qt::TopLeftCorner, TopRightCorner = Qt::TopRightCorner, BottomLeftCorner = Qt::BottomLeftCorner, BottomRightCorner = Qt::BottomRightCorner};
1004 enum TileRule{
1008 enum TileRule{
1005 StretchTile = Qt::StretchTile, RepeatTile = Qt::RepeatTile, RoundTile = Qt::RoundTile};
1009 StretchTile = Qt::StretchTile, RepeatTile = Qt::RepeatTile, RoundTile = Qt::RoundTile};
1006 enum ConnectionType{
1010 enum ConnectionType{
1007 AutoConnection = Qt::AutoConnection, DirectConnection = Qt::DirectConnection, QueuedConnection = Qt::QueuedConnection, BlockingQueuedConnection = Qt::BlockingQueuedConnection, UniqueConnection = Qt::UniqueConnection};
1011 AutoConnection = Qt::AutoConnection, DirectConnection = Qt::DirectConnection, QueuedConnection = Qt::QueuedConnection, BlockingQueuedConnection = Qt::BlockingQueuedConnection, UniqueConnection = Qt::UniqueConnection};
1008 enum AlignmentFlag{
1012 enum AlignmentFlag{
1009 AlignLeft = Qt::AlignLeft, AlignLeading = Qt::AlignLeading, AlignRight = Qt::AlignRight, AlignTrailing = Qt::AlignTrailing, AlignHCenter = Qt::AlignHCenter, AlignJustify = Qt::AlignJustify, AlignAbsolute = Qt::AlignAbsolute, AlignHorizontal_Mask = Qt::AlignHorizontal_Mask, AlignTop = Qt::AlignTop, AlignBottom = Qt::AlignBottom, AlignVCenter = Qt::AlignVCenter, AlignVertical_Mask = Qt::AlignVertical_Mask, AlignCenter = Qt::AlignCenter};
1013 AlignLeft = Qt::AlignLeft, AlignLeading = Qt::AlignLeading, AlignRight = Qt::AlignRight, AlignTrailing = Qt::AlignTrailing, AlignHCenter = Qt::AlignHCenter, AlignJustify = Qt::AlignJustify, AlignAbsolute = Qt::AlignAbsolute, AlignHorizontal_Mask = Qt::AlignHorizontal_Mask, AlignTop = Qt::AlignTop, AlignBottom = Qt::AlignBottom, AlignVCenter = Qt::AlignVCenter, AlignVertical_Mask = Qt::AlignVertical_Mask, AlignCenter = Qt::AlignCenter};
1010 enum Key{
1014 enum Key{
1011 Key_Escape = Qt::Key_Escape, Key_Tab = Qt::Key_Tab, Key_Backtab = Qt::Key_Backtab, Key_Backspace = Qt::Key_Backspace, Key_Return = Qt::Key_Return, Key_Enter = Qt::Key_Enter, Key_Insert = Qt::Key_Insert, Key_Delete = Qt::Key_Delete, Key_Pause = Qt::Key_Pause, Key_Print = Qt::Key_Print, Key_SysReq = Qt::Key_SysReq, Key_Clear = Qt::Key_Clear, Key_Home = Qt::Key_Home, Key_End = Qt::Key_End, Key_Left = Qt::Key_Left, Key_Up = Qt::Key_Up, Key_Right = Qt::Key_Right, Key_Down = Qt::Key_Down, Key_PageUp = Qt::Key_PageUp, Key_PageDown = Qt::Key_PageDown, Key_Shift = Qt::Key_Shift, Key_Control = Qt::Key_Control, Key_Meta = Qt::Key_Meta, Key_Alt = Qt::Key_Alt, Key_CapsLock = Qt::Key_CapsLock, Key_NumLock = Qt::Key_NumLock, Key_ScrollLock = Qt::Key_ScrollLock, Key_F1 = Qt::Key_F1, Key_F2 = Qt::Key_F2, Key_F3 = Qt::Key_F3, Key_F4 = Qt::Key_F4, Key_F5 = Qt::Key_F5, Key_F6 = Qt::Key_F6, Key_F7 = Qt::Key_F7, Key_F8 = Qt::Key_F8, Key_F9 = Qt::Key_F9, Key_F10 = Qt::Key_F10, Key_F11 = Qt::Key_F11, Key_F12 = Qt::Key_F12, Key_F13 = Qt::Key_F13, Key_F14 = Qt::Key_F14, Key_F15 = Qt::Key_F15, Key_F16 = Qt::Key_F16, Key_F17 = Qt::Key_F17, Key_F18 = Qt::Key_F18, Key_F19 = Qt::Key_F19, Key_F20 = Qt::Key_F20, Key_F21 = Qt::Key_F21, Key_F22 = Qt::Key_F22, Key_F23 = Qt::Key_F23, Key_F24 = Qt::Key_F24, Key_F25 = Qt::Key_F25, Key_F26 = Qt::Key_F26, Key_F27 = Qt::Key_F27, Key_F28 = Qt::Key_F28, Key_F29 = Qt::Key_F29, Key_F30 = Qt::Key_F30, Key_F31 = Qt::Key_F31, Key_F32 = Qt::Key_F32, Key_F33 = Qt::Key_F33, Key_F34 = Qt::Key_F34, Key_F35 = Qt::Key_F35, Key_Super_L = Qt::Key_Super_L, Key_Super_R = Qt::Key_Super_R, Key_Menu = Qt::Key_Menu, Key_Hyper_L = Qt::Key_Hyper_L, Key_Hyper_R = Qt::Key_Hyper_R, Key_Help = Qt::Key_Help, Key_Direction_L = Qt::Key_Direction_L, Key_Direction_R = Qt::Key_Direction_R, Key_Space = Qt::Key_Space, Key_Any = Qt::Key_Any, Key_Exclam = Qt::Key_Exclam, Key_QuoteDbl = Qt::Key_QuoteDbl, Key_NumberSign = Qt::Key_NumberSign, Key_Dollar = Qt::Key_Dollar, Key_Percent = Qt::Key_Percent, Key_Ampersand = Qt::Key_Ampersand, Key_Apostrophe = Qt::Key_Apostrophe, Key_ParenLeft = Qt::Key_ParenLeft, Key_ParenRight = Qt::Key_ParenRight, Key_Asterisk = Qt::Key_Asterisk, Key_Plus = Qt::Key_Plus, Key_Comma = Qt::Key_Comma, Key_Minus = Qt::Key_Minus, Key_Period = Qt::Key_Period, Key_Slash = Qt::Key_Slash, Key_0 = Qt::Key_0, Key_1 = Qt::Key_1, Key_2 = Qt::Key_2, Key_3 = Qt::Key_3, Key_4 = Qt::Key_4, Key_5 = Qt::Key_5, Key_6 = Qt::Key_6, Key_7 = Qt::Key_7, Key_8 = Qt::Key_8, Key_9 = Qt::Key_9, Key_Colon = Qt::Key_Colon, Key_Semicolon = Qt::Key_Semicolon, Key_Less = Qt::Key_Less, Key_Equal = Qt::Key_Equal, Key_Greater = Qt::Key_Greater, Key_Question = Qt::Key_Question, Key_At = Qt::Key_At, Key_A = Qt::Key_A, Key_B = Qt::Key_B, Key_C = Qt::Key_C, Key_D = Qt::Key_D, Key_E = Qt::Key_E, Key_F = Qt::Key_F, Key_G = Qt::Key_G, Key_H = Qt::Key_H, Key_I = Qt::Key_I, Key_J = Qt::Key_J, Key_K = Qt::Key_K, Key_L = Qt::Key_L, Key_M = Qt::Key_M, Key_N = Qt::Key_N, Key_O = Qt::Key_O, Key_P = Qt::Key_P, Key_Q = Qt::Key_Q, Key_R = Qt::Key_R, Key_S = Qt::Key_S, Key_T = Qt::Key_T, Key_U = Qt::Key_U, Key_V = Qt::Key_V, Key_W = Qt::Key_W, Key_X = Qt::Key_X, Key_Y = Qt::Key_Y, Key_Z = Qt::Key_Z, Key_BracketLeft = Qt::Key_BracketLeft, Key_Backslash = Qt::Key_Backslash, Key_BracketRight = Qt::Key_BracketRight, Key_AsciiCircum = Qt::Key_AsciiCircum, Key_Underscore = Qt::Key_Underscore, Key_QuoteLeft = Qt::Key_QuoteLeft, Key_BraceLeft = Qt::Key_BraceLeft, Key_Bar = Qt::Key_Bar, Key_BraceRight = Qt::Key_BraceRight, Key_AsciiTilde = Qt::Key_AsciiTilde, Key_nobreakspace = Qt::Key_nobreakspace, Key_exclamdown = Qt::Key_exclamdown, Key_cent = Qt::Key_cent, Key_sterling = Qt::Key_sterling, Key_currency = Qt::Key_currency, Key_yen = Qt::Key_yen, Key_brokenbar = Qt::Key_brokenbar, Key_section = Qt::Key_section, Key_diaeresis = Qt::Key_diaeresis, Key_copyright = Qt::Key_copyright, Key_ordfeminine = Qt::Key_ordfeminine, Key_guillemotleft = Qt::Key_guillemotleft, Key_notsign = Qt::Key_notsign, Key_hyphen = Qt::Key_hyphen, Key_registered = Qt::Key_registered, Key_macron = Qt::Key_macron, Key_degree = Qt::Key_degree, Key_plusminus = Qt::Key_plusminus, Key_twosuperior = Qt::Key_twosuperior, Key_threesuperior = Qt::Key_threesuperior, Key_acute = Qt::Key_acute, Key_mu = Qt::Key_mu, Key_paragraph = Qt::Key_paragraph, Key_periodcentered = Qt::Key_periodcentered, Key_cedilla = Qt::Key_cedilla, Key_onesuperior = Qt::Key_onesuperior, Key_masculine = Qt::Key_masculine, Key_guillemotright = Qt::Key_guillemotright, Key_onequarter = Qt::Key_onequarter, Key_onehalf = Qt::Key_onehalf, Key_threequarters = Qt::Key_threequarters, Key_questiondown = Qt::Key_questiondown, Key_Agrave = Qt::Key_Agrave, Key_Aacute = Qt::Key_Aacute, Key_Acircumflex = Qt::Key_Acircumflex, Key_Atilde = Qt::Key_Atilde, Key_Adiaeresis = Qt::Key_Adiaeresis, Key_Aring = Qt::Key_Aring, Key_AE = Qt::Key_AE, Key_Ccedilla = Qt::Key_Ccedilla, Key_Egrave = Qt::Key_Egrave, Key_Eacute = Qt::Key_Eacute, Key_Ecircumflex = Qt::Key_Ecircumflex, Key_Ediaeresis = Qt::Key_Ediaeresis, Key_Igrave = Qt::Key_Igrave, Key_Iacute = Qt::Key_Iacute, Key_Icircumflex = Qt::Key_Icircumflex, Key_Idiaeresis = Qt::Key_Idiaeresis, Key_ETH = Qt::Key_ETH, Key_Ntilde = Qt::Key_Ntilde, Key_Ograve = Qt::Key_Ograve, Key_Oacute = Qt::Key_Oacute, Key_Ocircumflex = Qt::Key_Ocircumflex, Key_Otilde = Qt::Key_Otilde, Key_Odiaeresis = Qt::Key_Odiaeresis, Key_multiply = Qt::Key_multiply, Key_Ooblique = Qt::Key_Ooblique, Key_Ugrave = Qt::Key_Ugrave, Key_Uacute = Qt::Key_Uacute, Key_Ucircumflex = Qt::Key_Ucircumflex, Key_Udiaeresis = Qt::Key_Udiaeresis, Key_Yacute = Qt::Key_Yacute, Key_THORN = Qt::Key_THORN, Key_ssharp = Qt::Key_ssharp, Key_division = Qt::Key_division, Key_ydiaeresis = Qt::Key_ydiaeresis, Key_AltGr = Qt::Key_AltGr, Key_Multi_key = Qt::Key_Multi_key, Key_Codeinput = Qt::Key_Codeinput, Key_SingleCandidate = Qt::Key_SingleCandidate, Key_MultipleCandidate = Qt::Key_MultipleCandidate, Key_PreviousCandidate = Qt::Key_PreviousCandidate, Key_Mode_switch = Qt::Key_Mode_switch, Key_Kanji = Qt::Key_Kanji, Key_Muhenkan = Qt::Key_Muhenkan, Key_Henkan = Qt::Key_Henkan, Key_Romaji = Qt::Key_Romaji, Key_Hiragana = Qt::Key_Hiragana, Key_Katakana = Qt::Key_Katakana, Key_Hiragana_Katakana = Qt::Key_Hiragana_Katakana, Key_Zenkaku = Qt::Key_Zenkaku, Key_Hankaku = Qt::Key_Hankaku, Key_Zenkaku_Hankaku = Qt::Key_Zenkaku_Hankaku, Key_Touroku = Qt::Key_Touroku, Key_Massyo = Qt::Key_Massyo, Key_Kana_Lock = Qt::Key_Kana_Lock, Key_Kana_Shift = Qt::Key_Kana_Shift, Key_Eisu_Shift = Qt::Key_Eisu_Shift, Key_Eisu_toggle = Qt::Key_Eisu_toggle, Key_Hangul = Qt::Key_Hangul, Key_Hangul_Start = Qt::Key_Hangul_Start, Key_Hangul_End = Qt::Key_Hangul_End, Key_Hangul_Hanja = Qt::Key_Hangul_Hanja, Key_Hangul_Jamo = Qt::Key_Hangul_Jamo, Key_Hangul_Romaja = Qt::Key_Hangul_Romaja, Key_Hangul_Jeonja = Qt::Key_Hangul_Jeonja, Key_Hangul_Banja = Qt::Key_Hangul_Banja, Key_Hangul_PreHanja = Qt::Key_Hangul_PreHanja, Key_Hangul_PostHanja = Qt::Key_Hangul_PostHanja, Key_Hangul_Special = Qt::Key_Hangul_Special, Key_Dead_Grave = Qt::Key_Dead_Grave, Key_Dead_Acute = Qt::Key_Dead_Acute, Key_Dead_Circumflex = Qt::Key_Dead_Circumflex, Key_Dead_Tilde = Qt::Key_Dead_Tilde, Key_Dead_Macron = Qt::Key_Dead_Macron, Key_Dead_Breve = Qt::Key_Dead_Breve, Key_Dead_Abovedot = Qt::Key_Dead_Abovedot, Key_Dead_Diaeresis = Qt::Key_Dead_Diaeresis, Key_Dead_Abovering = Qt::Key_Dead_Abovering, Key_Dead_Doubleacute = Qt::Key_Dead_Doubleacute, Key_Dead_Caron = Qt::Key_Dead_Caron, Key_Dead_Cedilla = Qt::Key_Dead_Cedilla, Key_Dead_Ogonek = Qt::Key_Dead_Ogonek, Key_Dead_Iota = Qt::Key_Dead_Iota, Key_Dead_Voiced_Sound = Qt::Key_Dead_Voiced_Sound, Key_Dead_Semivoiced_Sound = Qt::Key_Dead_Semivoiced_Sound, Key_Dead_Belowdot = Qt::Key_Dead_Belowdot, Key_Dead_Hook = Qt::Key_Dead_Hook, Key_Dead_Horn = Qt::Key_Dead_Horn, Key_Back = Qt::Key_Back, Key_Forward = Qt::Key_Forward, Key_Stop = Qt::Key_Stop, Key_Refresh = Qt::Key_Refresh, Key_VolumeDown = Qt::Key_VolumeDown, Key_VolumeMute = Qt::Key_VolumeMute, Key_VolumeUp = Qt::Key_VolumeUp, Key_BassBoost = Qt::Key_BassBoost, Key_BassUp = Qt::Key_BassUp, Key_BassDown = Qt::Key_BassDown, Key_TrebleUp = Qt::Key_TrebleUp, Key_TrebleDown = Qt::Key_TrebleDown, Key_MediaPlay = Qt::Key_MediaPlay, Key_MediaStop = Qt::Key_MediaStop, Key_MediaPrevious = Qt::Key_MediaPrevious, Key_MediaNext = Qt::Key_MediaNext, Key_MediaRecord = Qt::Key_MediaRecord, Key_MediaPause = Qt::Key_MediaPause, Key_MediaTogglePlayPause = Qt::Key_MediaTogglePlayPause, Key_HomePage = Qt::Key_HomePage, Key_Favorites = Qt::Key_Favorites, Key_Search = Qt::Key_Search, Key_Standby = Qt::Key_Standby, Key_OpenUrl = Qt::Key_OpenUrl, Key_LaunchMail = Qt::Key_LaunchMail, Key_LaunchMedia = Qt::Key_LaunchMedia, Key_Launch0 = Qt::Key_Launch0, Key_Launch1 = Qt::Key_Launch1, Key_Launch2 = Qt::Key_Launch2, Key_Launch3 = Qt::Key_Launch3, Key_Launch4 = Qt::Key_Launch4, Key_Launch5 = Qt::Key_Launch5, Key_Launch6 = Qt::Key_Launch6, Key_Launch7 = Qt::Key_Launch7, Key_Launch8 = Qt::Key_Launch8, Key_Launch9 = Qt::Key_Launch9, Key_LaunchA = Qt::Key_LaunchA, Key_LaunchB = Qt::Key_LaunchB, Key_LaunchC = Qt::Key_LaunchC, Key_LaunchD = Qt::Key_LaunchD, Key_LaunchE = Qt::Key_LaunchE, Key_LaunchF = Qt::Key_LaunchF, Key_MonBrightnessUp = Qt::Key_MonBrightnessUp, Key_MonBrightnessDown = Qt::Key_MonBrightnessDown, Key_KeyboardLightOnOff = Qt::Key_KeyboardLightOnOff, Key_KeyboardBrightnessUp = Qt::Key_KeyboardBrightnessUp, Key_KeyboardBrightnessDown = Qt::Key_KeyboardBrightnessDown, Key_PowerOff = Qt::Key_PowerOff, Key_WakeUp = Qt::Key_WakeUp, Key_Eject = Qt::Key_Eject, Key_ScreenSaver = Qt::Key_ScreenSaver, Key_WWW = Qt::Key_WWW, Key_Memo = Qt::Key_Memo, Key_LightBulb = Qt::Key_LightBulb, Key_Shop = Qt::Key_Shop, Key_History = Qt::Key_History, Key_AddFavorite = Qt::Key_AddFavorite, Key_HotLinks = Qt::Key_HotLinks, Key_BrightnessAdjust = Qt::Key_BrightnessAdjust, Key_Finance = Qt::Key_Finance, Key_Community = Qt::Key_Community, Key_AudioRewind = Qt::Key_AudioRewind, Key_BackForward = Qt::Key_BackForward, Key_ApplicationLeft = Qt::Key_ApplicationLeft, Key_ApplicationRight = Qt::Key_ApplicationRight, Key_Book = Qt::Key_Book, Key_CD = Qt::Key_CD, Key_Calculator = Qt::Key_Calculator, Key_ToDoList = Qt::Key_ToDoList, Key_ClearGrab = Qt::Key_ClearGrab, Key_Close = Qt::Key_Close, Key_Copy = Qt::Key_Copy, Key_Cut = Qt::Key_Cut, Key_Display = Qt::Key_Display, Key_DOS = Qt::Key_DOS, Key_Documents = Qt::Key_Documents, Key_Excel = Qt::Key_Excel, Key_Explorer = Qt::Key_Explorer, Key_Game = Qt::Key_Game, Key_Go = Qt::Key_Go, Key_iTouch = Qt::Key_iTouch, Key_LogOff = Qt::Key_LogOff, Key_Market = Qt::Key_Market, Key_Meeting = Qt::Key_Meeting, Key_MenuKB = Qt::Key_MenuKB, Key_MenuPB = Qt::Key_MenuPB, Key_MySites = Qt::Key_MySites, Key_News = Qt::Key_News, Key_OfficeHome = Qt::Key_OfficeHome, Key_Option = Qt::Key_Option, Key_Paste = Qt::Key_Paste, Key_Phone = Qt::Key_Phone, Key_Calendar = Qt::Key_Calendar, Key_Reply = Qt::Key_Reply, Key_Reload = Qt::Key_Reload, Key_RotateWindows = Qt::Key_RotateWindows, Key_RotationPB = Qt::Key_RotationPB, Key_RotationKB = Qt::Key_RotationKB, Key_Save = Qt::Key_Save, Key_Send = Qt::Key_Send, Key_Spell = Qt::Key_Spell, Key_SplitScreen = Qt::Key_SplitScreen, Key_Support = Qt::Key_Support, Key_TaskPane = Qt::Key_TaskPane, Key_Terminal = Qt::Key_Terminal, Key_Tools = Qt::Key_Tools, Key_Travel = Qt::Key_Travel, Key_Video = Qt::Key_Video, Key_Word = Qt::Key_Word, Key_Xfer = Qt::Key_Xfer, Key_ZoomIn = Qt::Key_ZoomIn, Key_ZoomOut = Qt::Key_ZoomOut, Key_Away = Qt::Key_Away, Key_Messenger = Qt::Key_Messenger, Key_WebCam = Qt::Key_WebCam, Key_MailForward = Qt::Key_MailForward, Key_Pictures = Qt::Key_Pictures, Key_Music = Qt::Key_Music, Key_Battery = Qt::Key_Battery, Key_Bluetooth = Qt::Key_Bluetooth, Key_WLAN = Qt::Key_WLAN, Key_UWB = Qt::Key_UWB, Key_AudioForward = Qt::Key_AudioForward, Key_AudioRepeat = Qt::Key_AudioRepeat, Key_AudioRandomPlay = Qt::Key_AudioRandomPlay, Key_Subtitle = Qt::Key_Subtitle, Key_AudioCycleTrack = Qt::Key_AudioCycleTrack, Key_Time = Qt::Key_Time, Key_Hibernate = Qt::Key_Hibernate, Key_View = Qt::Key_View, Key_TopMenu = Qt::Key_TopMenu, Key_PowerDown = Qt::Key_PowerDown, Key_Suspend = Qt::Key_Suspend, Key_ContrastAdjust = Qt::Key_ContrastAdjust, Key_LaunchG = Qt::Key_LaunchG, Key_LaunchH = Qt::Key_LaunchH, Key_TouchpadToggle = Qt::Key_TouchpadToggle, Key_TouchpadOn = Qt::Key_TouchpadOn, Key_TouchpadOff = Qt::Key_TouchpadOff, Key_MediaLast = Qt::Key_MediaLast, Key_Select = Qt::Key_Select, Key_Yes = Qt::Key_Yes, Key_No = Qt::Key_No, Key_Cancel = Qt::Key_Cancel, Key_Printer = Qt::Key_Printer, Key_Execute = Qt::Key_Execute, Key_Sleep = Qt::Key_Sleep, Key_Play = Qt::Key_Play, Key_Zoom = Qt::Key_Zoom, Key_Context1 = Qt::Key_Context1, Key_Context2 = Qt::Key_Context2, Key_Context3 = Qt::Key_Context3, Key_Context4 = Qt::Key_Context4, Key_Call = Qt::Key_Call, Key_Hangup = Qt::Key_Hangup, Key_Flip = Qt::Key_Flip, Key_ToggleCallHangup = Qt::Key_ToggleCallHangup, Key_VoiceDial = Qt::Key_VoiceDial, Key_LastNumberRedial = Qt::Key_LastNumberRedial, Key_Camera = Qt::Key_Camera, Key_CameraFocus = Qt::Key_CameraFocus, Key_unknown = Qt::Key_unknown};
1015 Key_Escape = Qt::Key_Escape, Key_Tab = Qt::Key_Tab, Key_Backtab = Qt::Key_Backtab, Key_Backspace = Qt::Key_Backspace, Key_Return = Qt::Key_Return, Key_Enter = Qt::Key_Enter, Key_Insert = Qt::Key_Insert, Key_Delete = Qt::Key_Delete, Key_Pause = Qt::Key_Pause, Key_Print = Qt::Key_Print, Key_SysReq = Qt::Key_SysReq, Key_Clear = Qt::Key_Clear, Key_Home = Qt::Key_Home, Key_End = Qt::Key_End, Key_Left = Qt::Key_Left, Key_Up = Qt::Key_Up, Key_Right = Qt::Key_Right, Key_Down = Qt::Key_Down, Key_PageUp = Qt::Key_PageUp, Key_PageDown = Qt::Key_PageDown, Key_Shift = Qt::Key_Shift, Key_Control = Qt::Key_Control, Key_Meta = Qt::Key_Meta, Key_Alt = Qt::Key_Alt, Key_CapsLock = Qt::Key_CapsLock, Key_NumLock = Qt::Key_NumLock, Key_ScrollLock = Qt::Key_ScrollLock, Key_F1 = Qt::Key_F1, Key_F2 = Qt::Key_F2, Key_F3 = Qt::Key_F3, Key_F4 = Qt::Key_F4, Key_F5 = Qt::Key_F5, Key_F6 = Qt::Key_F6, Key_F7 = Qt::Key_F7, Key_F8 = Qt::Key_F8, Key_F9 = Qt::Key_F9, Key_F10 = Qt::Key_F10, Key_F11 = Qt::Key_F11, Key_F12 = Qt::Key_F12, Key_F13 = Qt::Key_F13, Key_F14 = Qt::Key_F14, Key_F15 = Qt::Key_F15, Key_F16 = Qt::Key_F16, Key_F17 = Qt::Key_F17, Key_F18 = Qt::Key_F18, Key_F19 = Qt::Key_F19, Key_F20 = Qt::Key_F20, Key_F21 = Qt::Key_F21, Key_F22 = Qt::Key_F22, Key_F23 = Qt::Key_F23, Key_F24 = Qt::Key_F24, Key_F25 = Qt::Key_F25, Key_F26 = Qt::Key_F26, Key_F27 = Qt::Key_F27, Key_F28 = Qt::Key_F28, Key_F29 = Qt::Key_F29, Key_F30 = Qt::Key_F30, Key_F31 = Qt::Key_F31, Key_F32 = Qt::Key_F32, Key_F33 = Qt::Key_F33, Key_F34 = Qt::Key_F34, Key_F35 = Qt::Key_F35, Key_Super_L = Qt::Key_Super_L, Key_Super_R = Qt::Key_Super_R, Key_Menu = Qt::Key_Menu, Key_Hyper_L = Qt::Key_Hyper_L, Key_Hyper_R = Qt::Key_Hyper_R, Key_Help = Qt::Key_Help, Key_Direction_L = Qt::Key_Direction_L, Key_Direction_R = Qt::Key_Direction_R, Key_Space = Qt::Key_Space, Key_Any = Qt::Key_Any, Key_Exclam = Qt::Key_Exclam, Key_QuoteDbl = Qt::Key_QuoteDbl, Key_NumberSign = Qt::Key_NumberSign, Key_Dollar = Qt::Key_Dollar, Key_Percent = Qt::Key_Percent, Key_Ampersand = Qt::Key_Ampersand, Key_Apostrophe = Qt::Key_Apostrophe, Key_ParenLeft = Qt::Key_ParenLeft, Key_ParenRight = Qt::Key_ParenRight, Key_Asterisk = Qt::Key_Asterisk, Key_Plus = Qt::Key_Plus, Key_Comma = Qt::Key_Comma, Key_Minus = Qt::Key_Minus, Key_Period = Qt::Key_Period, Key_Slash = Qt::Key_Slash, Key_0 = Qt::Key_0, Key_1 = Qt::Key_1, Key_2 = Qt::Key_2, Key_3 = Qt::Key_3, Key_4 = Qt::Key_4, Key_5 = Qt::Key_5, Key_6 = Qt::Key_6, Key_7 = Qt::Key_7, Key_8 = Qt::Key_8, Key_9 = Qt::Key_9, Key_Colon = Qt::Key_Colon, Key_Semicolon = Qt::Key_Semicolon, Key_Less = Qt::Key_Less, Key_Equal = Qt::Key_Equal, Key_Greater = Qt::Key_Greater, Key_Question = Qt::Key_Question, Key_At = Qt::Key_At, Key_A = Qt::Key_A, Key_B = Qt::Key_B, Key_C = Qt::Key_C, Key_D = Qt::Key_D, Key_E = Qt::Key_E, Key_F = Qt::Key_F, Key_G = Qt::Key_G, Key_H = Qt::Key_H, Key_I = Qt::Key_I, Key_J = Qt::Key_J, Key_K = Qt::Key_K, Key_L = Qt::Key_L, Key_M = Qt::Key_M, Key_N = Qt::Key_N, Key_O = Qt::Key_O, Key_P = Qt::Key_P, Key_Q = Qt::Key_Q, Key_R = Qt::Key_R, Key_S = Qt::Key_S, Key_T = Qt::Key_T, Key_U = Qt::Key_U, Key_V = Qt::Key_V, Key_W = Qt::Key_W, Key_X = Qt::Key_X, Key_Y = Qt::Key_Y, Key_Z = Qt::Key_Z, Key_BracketLeft = Qt::Key_BracketLeft, Key_Backslash = Qt::Key_Backslash, Key_BracketRight = Qt::Key_BracketRight, Key_AsciiCircum = Qt::Key_AsciiCircum, Key_Underscore = Qt::Key_Underscore, Key_QuoteLeft = Qt::Key_QuoteLeft, Key_BraceLeft = Qt::Key_BraceLeft, Key_Bar = Qt::Key_Bar, Key_BraceRight = Qt::Key_BraceRight, Key_AsciiTilde = Qt::Key_AsciiTilde, Key_nobreakspace = Qt::Key_nobreakspace, Key_exclamdown = Qt::Key_exclamdown, Key_cent = Qt::Key_cent, Key_sterling = Qt::Key_sterling, Key_currency = Qt::Key_currency, Key_yen = Qt::Key_yen, Key_brokenbar = Qt::Key_brokenbar, Key_section = Qt::Key_section, Key_diaeresis = Qt::Key_diaeresis, Key_copyright = Qt::Key_copyright, Key_ordfeminine = Qt::Key_ordfeminine, Key_guillemotleft = Qt::Key_guillemotleft, Key_notsign = Qt::Key_notsign, Key_hyphen = Qt::Key_hyphen, Key_registered = Qt::Key_registered, Key_macron = Qt::Key_macron, Key_degree = Qt::Key_degree, Key_plusminus = Qt::Key_plusminus, Key_twosuperior = Qt::Key_twosuperior, Key_threesuperior = Qt::Key_threesuperior, Key_acute = Qt::Key_acute, Key_mu = Qt::Key_mu, Key_paragraph = Qt::Key_paragraph, Key_periodcentered = Qt::Key_periodcentered, Key_cedilla = Qt::Key_cedilla, Key_onesuperior = Qt::Key_onesuperior, Key_masculine = Qt::Key_masculine, Key_guillemotright = Qt::Key_guillemotright, Key_onequarter = Qt::Key_onequarter, Key_onehalf = Qt::Key_onehalf, Key_threequarters = Qt::Key_threequarters, Key_questiondown = Qt::Key_questiondown, Key_Agrave = Qt::Key_Agrave, Key_Aacute = Qt::Key_Aacute, Key_Acircumflex = Qt::Key_Acircumflex, Key_Atilde = Qt::Key_Atilde, Key_Adiaeresis = Qt::Key_Adiaeresis, Key_Aring = Qt::Key_Aring, Key_AE = Qt::Key_AE, Key_Ccedilla = Qt::Key_Ccedilla, Key_Egrave = Qt::Key_Egrave, Key_Eacute = Qt::Key_Eacute, Key_Ecircumflex = Qt::Key_Ecircumflex, Key_Ediaeresis = Qt::Key_Ediaeresis, Key_Igrave = Qt::Key_Igrave, Key_Iacute = Qt::Key_Iacute, Key_Icircumflex = Qt::Key_Icircumflex, Key_Idiaeresis = Qt::Key_Idiaeresis, Key_ETH = Qt::Key_ETH, Key_Ntilde = Qt::Key_Ntilde, Key_Ograve = Qt::Key_Ograve, Key_Oacute = Qt::Key_Oacute, Key_Ocircumflex = Qt::Key_Ocircumflex, Key_Otilde = Qt::Key_Otilde, Key_Odiaeresis = Qt::Key_Odiaeresis, Key_multiply = Qt::Key_multiply, Key_Ooblique = Qt::Key_Ooblique, Key_Ugrave = Qt::Key_Ugrave, Key_Uacute = Qt::Key_Uacute, Key_Ucircumflex = Qt::Key_Ucircumflex, Key_Udiaeresis = Qt::Key_Udiaeresis, Key_Yacute = Qt::Key_Yacute, Key_THORN = Qt::Key_THORN, Key_ssharp = Qt::Key_ssharp, Key_division = Qt::Key_division, Key_ydiaeresis = Qt::Key_ydiaeresis, Key_AltGr = Qt::Key_AltGr, Key_Multi_key = Qt::Key_Multi_key, Key_Codeinput = Qt::Key_Codeinput, Key_SingleCandidate = Qt::Key_SingleCandidate, Key_MultipleCandidate = Qt::Key_MultipleCandidate, Key_PreviousCandidate = Qt::Key_PreviousCandidate, Key_Mode_switch = Qt::Key_Mode_switch, Key_Kanji = Qt::Key_Kanji, Key_Muhenkan = Qt::Key_Muhenkan, Key_Henkan = Qt::Key_Henkan, Key_Romaji = Qt::Key_Romaji, Key_Hiragana = Qt::Key_Hiragana, Key_Katakana = Qt::Key_Katakana, Key_Hiragana_Katakana = Qt::Key_Hiragana_Katakana, Key_Zenkaku = Qt::Key_Zenkaku, Key_Hankaku = Qt::Key_Hankaku, Key_Zenkaku_Hankaku = Qt::Key_Zenkaku_Hankaku, Key_Touroku = Qt::Key_Touroku, Key_Massyo = Qt::Key_Massyo, Key_Kana_Lock = Qt::Key_Kana_Lock, Key_Kana_Shift = Qt::Key_Kana_Shift, Key_Eisu_Shift = Qt::Key_Eisu_Shift, Key_Eisu_toggle = Qt::Key_Eisu_toggle, Key_Hangul = Qt::Key_Hangul, Key_Hangul_Start = Qt::Key_Hangul_Start, Key_Hangul_End = Qt::Key_Hangul_End, Key_Hangul_Hanja = Qt::Key_Hangul_Hanja, Key_Hangul_Jamo = Qt::Key_Hangul_Jamo, Key_Hangul_Romaja = Qt::Key_Hangul_Romaja, Key_Hangul_Jeonja = Qt::Key_Hangul_Jeonja, Key_Hangul_Banja = Qt::Key_Hangul_Banja, Key_Hangul_PreHanja = Qt::Key_Hangul_PreHanja, Key_Hangul_PostHanja = Qt::Key_Hangul_PostHanja, Key_Hangul_Special = Qt::Key_Hangul_Special, Key_Dead_Grave = Qt::Key_Dead_Grave, Key_Dead_Acute = Qt::Key_Dead_Acute, Key_Dead_Circumflex = Qt::Key_Dead_Circumflex, Key_Dead_Tilde = Qt::Key_Dead_Tilde, Key_Dead_Macron = Qt::Key_Dead_Macron, Key_Dead_Breve = Qt::Key_Dead_Breve, Key_Dead_Abovedot = Qt::Key_Dead_Abovedot, Key_Dead_Diaeresis = Qt::Key_Dead_Diaeresis, Key_Dead_Abovering = Qt::Key_Dead_Abovering, Key_Dead_Doubleacute = Qt::Key_Dead_Doubleacute, Key_Dead_Caron = Qt::Key_Dead_Caron, Key_Dead_Cedilla = Qt::Key_Dead_Cedilla, Key_Dead_Ogonek = Qt::Key_Dead_Ogonek, Key_Dead_Iota = Qt::Key_Dead_Iota, Key_Dead_Voiced_Sound = Qt::Key_Dead_Voiced_Sound, Key_Dead_Semivoiced_Sound = Qt::Key_Dead_Semivoiced_Sound, Key_Dead_Belowdot = Qt::Key_Dead_Belowdot, Key_Dead_Hook = Qt::Key_Dead_Hook, Key_Dead_Horn = Qt::Key_Dead_Horn, Key_Back = Qt::Key_Back, Key_Forward = Qt::Key_Forward, Key_Stop = Qt::Key_Stop, Key_Refresh = Qt::Key_Refresh, Key_VolumeDown = Qt::Key_VolumeDown, Key_VolumeMute = Qt::Key_VolumeMute, Key_VolumeUp = Qt::Key_VolumeUp, Key_BassBoost = Qt::Key_BassBoost, Key_BassUp = Qt::Key_BassUp, Key_BassDown = Qt::Key_BassDown, Key_TrebleUp = Qt::Key_TrebleUp, Key_TrebleDown = Qt::Key_TrebleDown, Key_MediaPlay = Qt::Key_MediaPlay, Key_MediaStop = Qt::Key_MediaStop, Key_MediaPrevious = Qt::Key_MediaPrevious, Key_MediaNext = Qt::Key_MediaNext, Key_MediaRecord = Qt::Key_MediaRecord, Key_MediaPause = Qt::Key_MediaPause, Key_MediaTogglePlayPause = Qt::Key_MediaTogglePlayPause, Key_HomePage = Qt::Key_HomePage, Key_Favorites = Qt::Key_Favorites, Key_Search = Qt::Key_Search, Key_Standby = Qt::Key_Standby, Key_OpenUrl = Qt::Key_OpenUrl, Key_LaunchMail = Qt::Key_LaunchMail, Key_LaunchMedia = Qt::Key_LaunchMedia, Key_Launch0 = Qt::Key_Launch0, Key_Launch1 = Qt::Key_Launch1, Key_Launch2 = Qt::Key_Launch2, Key_Launch3 = Qt::Key_Launch3, Key_Launch4 = Qt::Key_Launch4, Key_Launch5 = Qt::Key_Launch5, Key_Launch6 = Qt::Key_Launch6, Key_Launch7 = Qt::Key_Launch7, Key_Launch8 = Qt::Key_Launch8, Key_Launch9 = Qt::Key_Launch9, Key_LaunchA = Qt::Key_LaunchA, Key_LaunchB = Qt::Key_LaunchB, Key_LaunchC = Qt::Key_LaunchC, Key_LaunchD = Qt::Key_LaunchD, Key_LaunchE = Qt::Key_LaunchE, Key_LaunchF = Qt::Key_LaunchF, Key_MonBrightnessUp = Qt::Key_MonBrightnessUp, Key_MonBrightnessDown = Qt::Key_MonBrightnessDown, Key_KeyboardLightOnOff = Qt::Key_KeyboardLightOnOff, Key_KeyboardBrightnessUp = Qt::Key_KeyboardBrightnessUp, Key_KeyboardBrightnessDown = Qt::Key_KeyboardBrightnessDown, Key_PowerOff = Qt::Key_PowerOff, Key_WakeUp = Qt::Key_WakeUp, Key_Eject = Qt::Key_Eject, Key_ScreenSaver = Qt::Key_ScreenSaver, Key_WWW = Qt::Key_WWW, Key_Memo = Qt::Key_Memo, Key_LightBulb = Qt::Key_LightBulb, Key_Shop = Qt::Key_Shop, Key_History = Qt::Key_History, Key_AddFavorite = Qt::Key_AddFavorite, Key_HotLinks = Qt::Key_HotLinks, Key_BrightnessAdjust = Qt::Key_BrightnessAdjust, Key_Finance = Qt::Key_Finance, Key_Community = Qt::Key_Community, Key_AudioRewind = Qt::Key_AudioRewind, Key_BackForward = Qt::Key_BackForward, Key_ApplicationLeft = Qt::Key_ApplicationLeft, Key_ApplicationRight = Qt::Key_ApplicationRight, Key_Book = Qt::Key_Book, Key_CD = Qt::Key_CD, Key_Calculator = Qt::Key_Calculator, Key_ToDoList = Qt::Key_ToDoList, Key_ClearGrab = Qt::Key_ClearGrab, Key_Close = Qt::Key_Close, Key_Copy = Qt::Key_Copy, Key_Cut = Qt::Key_Cut, Key_Display = Qt::Key_Display, Key_DOS = Qt::Key_DOS, Key_Documents = Qt::Key_Documents, Key_Excel = Qt::Key_Excel, Key_Explorer = Qt::Key_Explorer, Key_Game = Qt::Key_Game, Key_Go = Qt::Key_Go, Key_iTouch = Qt::Key_iTouch, Key_LogOff = Qt::Key_LogOff, Key_Market = Qt::Key_Market, Key_Meeting = Qt::Key_Meeting, Key_MenuKB = Qt::Key_MenuKB, Key_MenuPB = Qt::Key_MenuPB, Key_MySites = Qt::Key_MySites, Key_News = Qt::Key_News, Key_OfficeHome = Qt::Key_OfficeHome, Key_Option = Qt::Key_Option, Key_Paste = Qt::Key_Paste, Key_Phone = Qt::Key_Phone, Key_Calendar = Qt::Key_Calendar, Key_Reply = Qt::Key_Reply, Key_Reload = Qt::Key_Reload, Key_RotateWindows = Qt::Key_RotateWindows, Key_RotationPB = Qt::Key_RotationPB, Key_RotationKB = Qt::Key_RotationKB, Key_Save = Qt::Key_Save, Key_Send = Qt::Key_Send, Key_Spell = Qt::Key_Spell, Key_SplitScreen = Qt::Key_SplitScreen, Key_Support = Qt::Key_Support, Key_TaskPane = Qt::Key_TaskPane, Key_Terminal = Qt::Key_Terminal, Key_Tools = Qt::Key_Tools, Key_Travel = Qt::Key_Travel, Key_Video = Qt::Key_Video, Key_Word = Qt::Key_Word, Key_Xfer = Qt::Key_Xfer, Key_ZoomIn = Qt::Key_ZoomIn, Key_ZoomOut = Qt::Key_ZoomOut, Key_Away = Qt::Key_Away, Key_Messenger = Qt::Key_Messenger, Key_WebCam = Qt::Key_WebCam, Key_MailForward = Qt::Key_MailForward, Key_Pictures = Qt::Key_Pictures, Key_Music = Qt::Key_Music, Key_Battery = Qt::Key_Battery, Key_Bluetooth = Qt::Key_Bluetooth, Key_WLAN = Qt::Key_WLAN, Key_UWB = Qt::Key_UWB, Key_AudioForward = Qt::Key_AudioForward, Key_AudioRepeat = Qt::Key_AudioRepeat, Key_AudioRandomPlay = Qt::Key_AudioRandomPlay, Key_Subtitle = Qt::Key_Subtitle, Key_AudioCycleTrack = Qt::Key_AudioCycleTrack, Key_Time = Qt::Key_Time, Key_Hibernate = Qt::Key_Hibernate, Key_View = Qt::Key_View, Key_TopMenu = Qt::Key_TopMenu, Key_PowerDown = Qt::Key_PowerDown, Key_Suspend = Qt::Key_Suspend, Key_ContrastAdjust = Qt::Key_ContrastAdjust, Key_LaunchG = Qt::Key_LaunchG, Key_LaunchH = Qt::Key_LaunchH, Key_TouchpadToggle = Qt::Key_TouchpadToggle, Key_TouchpadOn = Qt::Key_TouchpadOn, Key_TouchpadOff = Qt::Key_TouchpadOff, Key_MediaLast = Qt::Key_MediaLast, Key_Select = Qt::Key_Select, Key_Yes = Qt::Key_Yes, Key_No = Qt::Key_No, Key_Cancel = Qt::Key_Cancel, Key_Printer = Qt::Key_Printer, Key_Execute = Qt::Key_Execute, Key_Sleep = Qt::Key_Sleep, Key_Play = Qt::Key_Play, Key_Zoom = Qt::Key_Zoom, Key_Context1 = Qt::Key_Context1, Key_Context2 = Qt::Key_Context2, Key_Context3 = Qt::Key_Context3, Key_Context4 = Qt::Key_Context4, Key_Call = Qt::Key_Call, Key_Hangup = Qt::Key_Hangup, Key_Flip = Qt::Key_Flip, Key_ToggleCallHangup = Qt::Key_ToggleCallHangup, Key_VoiceDial = Qt::Key_VoiceDial, Key_LastNumberRedial = Qt::Key_LastNumberRedial, Key_Camera = Qt::Key_Camera, Key_CameraFocus = Qt::Key_CameraFocus, Key_unknown = Qt::Key_unknown};
1012 enum WindowState{
1016 enum WindowState{
1013 WindowNoState = Qt::WindowNoState, WindowMinimized = Qt::WindowMinimized, WindowMaximized = Qt::WindowMaximized, WindowFullScreen = Qt::WindowFullScreen, WindowActive = Qt::WindowActive};
1017 WindowNoState = Qt::WindowNoState, WindowMinimized = Qt::WindowMinimized, WindowMaximized = Qt::WindowMaximized, WindowFullScreen = Qt::WindowFullScreen, WindowActive = Qt::WindowActive};
1014 enum CheckState{
1018 enum CheckState{
1015 Unchecked = Qt::Unchecked, PartiallyChecked = Qt::PartiallyChecked, Checked = Qt::Checked};
1019 Unchecked = Qt::Unchecked, PartiallyChecked = Qt::PartiallyChecked, Checked = Qt::Checked};
1016 enum ToolBarAreaSizes{
1020 enum ToolBarAreaSizes{
1017 NToolBarAreas = Qt::NToolBarAreas};
1021 NToolBarAreas = Qt::NToolBarAreas};
1018 enum SizeMode{
1022 enum SizeMode{
1019 AbsoluteSize = Qt::AbsoluteSize, RelativeSize = Qt::RelativeSize};
1023 AbsoluteSize = Qt::AbsoluteSize, RelativeSize = Qt::RelativeSize};
1020 enum Axis{
1024 enum Axis{
1021 XAxis = Qt::XAxis, YAxis = Qt::YAxis, ZAxis = Qt::ZAxis};
1025 XAxis = Qt::XAxis, YAxis = Qt::YAxis, ZAxis = Qt::ZAxis};
1022 enum FillRule{
1026 enum FillRule{
1023 OddEvenFill = Qt::OddEvenFill, WindingFill = Qt::WindingFill};
1027 OddEvenFill = Qt::OddEvenFill, WindingFill = Qt::WindingFill};
1024 enum GestureType{
1028 enum GestureType{
1025 TapGesture = Qt::TapGesture, TapAndHoldGesture = Qt::TapAndHoldGesture, PanGesture = Qt::PanGesture, PinchGesture = Qt::PinchGesture, SwipeGesture = Qt::SwipeGesture, CustomGesture = Qt::CustomGesture, LastGestureType = Qt::LastGestureType};
1029 TapGesture = Qt::TapGesture, TapAndHoldGesture = Qt::TapAndHoldGesture, PanGesture = Qt::PanGesture, PinchGesture = Qt::PinchGesture, SwipeGesture = Qt::SwipeGesture, CustomGesture = Qt::CustomGesture, LastGestureType = Qt::LastGestureType};
1026 enum ClipOperation{
1030 enum ClipOperation{
1027 NoClip = Qt::NoClip, ReplaceClip = Qt::ReplaceClip, IntersectClip = Qt::IntersectClip};
1031 NoClip = Qt::NoClip, ReplaceClip = Qt::ReplaceClip, IntersectClip = Qt::IntersectClip};
1028 enum InputMethodQuery{
1032 enum InputMethodQuery{
1029 ImEnabled = Qt::ImEnabled, ImCursorRectangle = Qt::ImCursorRectangle, ImMicroFocus = Qt::ImMicroFocus, ImFont = Qt::ImFont, ImCursorPosition = Qt::ImCursorPosition, ImSurroundingText = Qt::ImSurroundingText, ImCurrentSelection = Qt::ImCurrentSelection, ImMaximumTextLength = Qt::ImMaximumTextLength, ImAnchorPosition = Qt::ImAnchorPosition, ImHints = Qt::ImHints, ImPreferredLanguage = Qt::ImPreferredLanguage, ImPlatformData = Qt::ImPlatformData, ImQueryInput = Qt::ImQueryInput, ImQueryAll = Qt::ImQueryAll};
1033 ImEnabled = Qt::ImEnabled, ImCursorRectangle = Qt::ImCursorRectangle, ImMicroFocus = Qt::ImMicroFocus, ImFont = Qt::ImFont, ImCursorPosition = Qt::ImCursorPosition, ImSurroundingText = Qt::ImSurroundingText, ImCurrentSelection = Qt::ImCurrentSelection, ImMaximumTextLength = Qt::ImMaximumTextLength, ImAnchorPosition = Qt::ImAnchorPosition, ImHints = Qt::ImHints, ImPreferredLanguage = Qt::ImPreferredLanguage, ImPlatformData = Qt::ImPlatformData, ImQueryInput = Qt::ImQueryInput, ImQueryAll = Qt::ImQueryAll};
1030 enum TimeSpec{
1034 enum TimeSpec{
1031 LocalTime = Qt::LocalTime, UTC = Qt::UTC, OffsetFromUTC = Qt::OffsetFromUTC};
1035 LocalTime = Qt::LocalTime, UTC = Qt::UTC, OffsetFromUTC = Qt::OffsetFromUTC};
1032 enum ItemDataRole{
1036 enum ItemDataRole{
1033 DisplayRole = Qt::DisplayRole, DecorationRole = Qt::DecorationRole, EditRole = Qt::EditRole, ToolTipRole = Qt::ToolTipRole, StatusTipRole = Qt::StatusTipRole, WhatsThisRole = Qt::WhatsThisRole, FontRole = Qt::FontRole, TextAlignmentRole = Qt::TextAlignmentRole, BackgroundColorRole = Qt::BackgroundColorRole, BackgroundRole = Qt::BackgroundRole, TextColorRole = Qt::TextColorRole, ForegroundRole = Qt::ForegroundRole, CheckStateRole = Qt::CheckStateRole, AccessibleTextRole = Qt::AccessibleTextRole, AccessibleDescriptionRole = Qt::AccessibleDescriptionRole, SizeHintRole = Qt::SizeHintRole, InitialSortOrderRole = Qt::InitialSortOrderRole, DisplayPropertyRole = Qt::DisplayPropertyRole, DecorationPropertyRole = Qt::DecorationPropertyRole, ToolTipPropertyRole = Qt::ToolTipPropertyRole, StatusTipPropertyRole = Qt::StatusTipPropertyRole, WhatsThisPropertyRole = Qt::WhatsThisPropertyRole, UserRole = Qt::UserRole};
1037 DisplayRole = Qt::DisplayRole, DecorationRole = Qt::DecorationRole, EditRole = Qt::EditRole, ToolTipRole = Qt::ToolTipRole, StatusTipRole = Qt::StatusTipRole, WhatsThisRole = Qt::WhatsThisRole, FontRole = Qt::FontRole, TextAlignmentRole = Qt::TextAlignmentRole, BackgroundColorRole = Qt::BackgroundColorRole, BackgroundRole = Qt::BackgroundRole, TextColorRole = Qt::TextColorRole, ForegroundRole = Qt::ForegroundRole, CheckStateRole = Qt::CheckStateRole, AccessibleTextRole = Qt::AccessibleTextRole, AccessibleDescriptionRole = Qt::AccessibleDescriptionRole, SizeHintRole = Qt::SizeHintRole, InitialSortOrderRole = Qt::InitialSortOrderRole, DisplayPropertyRole = Qt::DisplayPropertyRole, DecorationPropertyRole = Qt::DecorationPropertyRole, ToolTipPropertyRole = Qt::ToolTipPropertyRole, StatusTipPropertyRole = Qt::StatusTipPropertyRole, WhatsThisPropertyRole = Qt::WhatsThisPropertyRole, UserRole = Qt::UserRole};
1034 enum ShortcutContext{
1038 enum ShortcutContext{
1035 WidgetShortcut = Qt::WidgetShortcut, WindowShortcut = Qt::WindowShortcut, ApplicationShortcut = Qt::ApplicationShortcut, WidgetWithChildrenShortcut = Qt::WidgetWithChildrenShortcut};
1039 WidgetShortcut = Qt::WidgetShortcut, WindowShortcut = Qt::WindowShortcut, ApplicationShortcut = Qt::ApplicationShortcut, WidgetWithChildrenShortcut = Qt::WidgetWithChildrenShortcut};
1036 enum MaskMode{
1040 enum MaskMode{
1037 MaskInColor = Qt::MaskInColor, MaskOutColor = Qt::MaskOutColor};
1041 MaskInColor = Qt::MaskInColor, MaskOutColor = Qt::MaskOutColor};
1038 enum WindowType{
1042 enum WindowType{
1039 Widget = Qt::Widget, Window = Qt::Window, Dialog = Qt::Dialog, Sheet = Qt::Sheet, Drawer = Qt::Drawer, Popup = Qt::Popup, Tool = Qt::Tool, ToolTip = Qt::ToolTip, SplashScreen = Qt::SplashScreen, Desktop = Qt::Desktop, SubWindow = Qt::SubWindow, WindowType_Mask = Qt::WindowType_Mask, MSWindowsFixedSizeDialogHint = Qt::MSWindowsFixedSizeDialogHint, MSWindowsOwnDC = Qt::MSWindowsOwnDC, X11BypassWindowManagerHint = Qt::X11BypassWindowManagerHint, FramelessWindowHint = Qt::FramelessWindowHint, WindowTitleHint = Qt::WindowTitleHint, WindowSystemMenuHint = Qt::WindowSystemMenuHint, WindowMinimizeButtonHint = Qt::WindowMinimizeButtonHint, WindowMaximizeButtonHint = Qt::WindowMaximizeButtonHint, WindowMinMaxButtonsHint = Qt::WindowMinMaxButtonsHint, WindowContextHelpButtonHint = Qt::WindowContextHelpButtonHint, WindowShadeButtonHint = Qt::WindowShadeButtonHint, WindowStaysOnTopHint = Qt::WindowStaysOnTopHint, WindowTransparentForInput = Qt::WindowTransparentForInput, WindowOverridesSystemGestures = Qt::WindowOverridesSystemGestures, WindowDoesNotAcceptFocus = Qt::WindowDoesNotAcceptFocus, CustomizeWindowHint = Qt::CustomizeWindowHint, WindowStaysOnBottomHint = Qt::WindowStaysOnBottomHint, WindowCloseButtonHint = Qt::WindowCloseButtonHint, MacWindowToolBarButtonHint = Qt::MacWindowToolBarButtonHint, BypassGraphicsProxyWidget = Qt::BypassGraphicsProxyWidget, WindowOkButtonHint = Qt::WindowOkButtonHint, WindowCancelButtonHint = Qt::WindowCancelButtonHint, NoDropShadowWindowHint = Qt::NoDropShadowWindowHint, WindowFullscreenButtonHint = Qt::WindowFullscreenButtonHint};
1043 Widget = Qt::Widget, Window = Qt::Window, Dialog = Qt::Dialog, Sheet = Qt::Sheet, Drawer = Qt::Drawer, Popup = Qt::Popup, Tool = Qt::Tool, ToolTip = Qt::ToolTip, SplashScreen = Qt::SplashScreen, Desktop = Qt::Desktop, SubWindow = Qt::SubWindow, WindowType_Mask = Qt::WindowType_Mask, MSWindowsFixedSizeDialogHint = Qt::MSWindowsFixedSizeDialogHint, MSWindowsOwnDC = Qt::MSWindowsOwnDC, X11BypassWindowManagerHint = Qt::X11BypassWindowManagerHint, FramelessWindowHint = Qt::FramelessWindowHint, WindowTitleHint = Qt::WindowTitleHint, WindowSystemMenuHint = Qt::WindowSystemMenuHint, WindowMinimizeButtonHint = Qt::WindowMinimizeButtonHint, WindowMaximizeButtonHint = Qt::WindowMaximizeButtonHint, WindowMinMaxButtonsHint = Qt::WindowMinMaxButtonsHint, WindowContextHelpButtonHint = Qt::WindowContextHelpButtonHint, WindowShadeButtonHint = Qt::WindowShadeButtonHint, WindowStaysOnTopHint = Qt::WindowStaysOnTopHint, WindowTransparentForInput = Qt::WindowTransparentForInput, WindowOverridesSystemGestures = Qt::WindowOverridesSystemGestures, WindowDoesNotAcceptFocus = Qt::WindowDoesNotAcceptFocus, CustomizeWindowHint = Qt::CustomizeWindowHint, WindowStaysOnBottomHint = Qt::WindowStaysOnBottomHint, WindowCloseButtonHint = Qt::WindowCloseButtonHint, MacWindowToolBarButtonHint = Qt::MacWindowToolBarButtonHint, BypassGraphicsProxyWidget = Qt::BypassGraphicsProxyWidget, WindowOkButtonHint = Qt::WindowOkButtonHint, WindowCancelButtonHint = Qt::WindowCancelButtonHint, NoDropShadowWindowHint = Qt::NoDropShadowWindowHint, WindowFullscreenButtonHint = Qt::WindowFullscreenButtonHint};
1040 enum DockWidgetArea{
1044 enum DockWidgetArea{
1041 LeftDockWidgetArea = Qt::LeftDockWidgetArea, RightDockWidgetArea = Qt::RightDockWidgetArea, TopDockWidgetArea = Qt::TopDockWidgetArea, BottomDockWidgetArea = Qt::BottomDockWidgetArea, DockWidgetArea_Mask = Qt::DockWidgetArea_Mask, AllDockWidgetAreas = Qt::AllDockWidgetAreas, NoDockWidgetArea = Qt::NoDockWidgetArea};
1045 LeftDockWidgetArea = Qt::LeftDockWidgetArea, RightDockWidgetArea = Qt::RightDockWidgetArea, TopDockWidgetArea = Qt::TopDockWidgetArea, BottomDockWidgetArea = Qt::BottomDockWidgetArea, DockWidgetArea_Mask = Qt::DockWidgetArea_Mask, AllDockWidgetAreas = Qt::AllDockWidgetAreas, NoDockWidgetArea = Qt::NoDockWidgetArea};
1042 enum ContextMenuPolicy{
1046 enum ContextMenuPolicy{
1043 NoContextMenu = Qt::NoContextMenu, DefaultContextMenu = Qt::DefaultContextMenu, ActionsContextMenu = Qt::ActionsContextMenu, CustomContextMenu = Qt::CustomContextMenu, PreventContextMenu = Qt::PreventContextMenu};
1047 NoContextMenu = Qt::NoContextMenu, DefaultContextMenu = Qt::DefaultContextMenu, ActionsContextMenu = Qt::ActionsContextMenu, CustomContextMenu = Qt::CustomContextMenu, PreventContextMenu = Qt::PreventContextMenu};
1044 Q_DECLARE_FLAGS(MouseButtons, MouseButton)
1048 Q_DECLARE_FLAGS(MouseButtons, MouseButton)
1045 Q_DECLARE_FLAGS(Orientations, Orientation)
1049 Q_DECLARE_FLAGS(Orientations, Orientation)
1046 Q_DECLARE_FLAGS(GestureFlags, GestureFlag)
1050 Q_DECLARE_FLAGS(GestureFlags, GestureFlag)
1047 Q_DECLARE_FLAGS(ToolBarAreas, ToolBarArea)
1051 Q_DECLARE_FLAGS(ToolBarAreas, ToolBarArea)
1048 Q_DECLARE_FLAGS(MatchFlags, MatchFlag)
1052 Q_DECLARE_FLAGS(MatchFlags, MatchFlag)
1049 Q_DECLARE_FLAGS(ItemFlags, ItemFlag)
1053 Q_DECLARE_FLAGS(ItemFlags, ItemFlag)
1050 Q_DECLARE_FLAGS(DropActions, DropAction)
1054 Q_DECLARE_FLAGS(DropActions, DropAction)
1051 Q_DECLARE_FLAGS(TouchPointStates, TouchPointState)
1055 Q_DECLARE_FLAGS(TouchPointStates, TouchPointState)
1052 Q_DECLARE_FLAGS(InputMethodHints, InputMethodHint)
1056 Q_DECLARE_FLAGS(InputMethodHints, InputMethodHint)
1053 Q_DECLARE_FLAGS(KeyboardModifiers, KeyboardModifier)
1057 Q_DECLARE_FLAGS(KeyboardModifiers, KeyboardModifier)
1054 Q_DECLARE_FLAGS(ImageConversionFlags, ImageConversionFlag)
1058 Q_DECLARE_FLAGS(ImageConversionFlags, ImageConversionFlag)
1055 Q_DECLARE_FLAGS(TextInteractionFlags, TextInteractionFlag)
1059 Q_DECLARE_FLAGS(TextInteractionFlags, TextInteractionFlag)
1056 Q_DECLARE_FLAGS(Alignment, AlignmentFlag)
1060 Q_DECLARE_FLAGS(Alignment, AlignmentFlag)
1057 Q_DECLARE_FLAGS(WindowStates, WindowState)
1061 Q_DECLARE_FLAGS(WindowStates, WindowState)
1058 Q_DECLARE_FLAGS(WindowFlags, WindowType)
1062 Q_DECLARE_FLAGS(WindowFlags, WindowType)
1059 Q_DECLARE_FLAGS(DockWidgetAreas, DockWidgetArea)
1063 Q_DECLARE_FLAGS(DockWidgetAreas, DockWidgetArea)
1060 public slots:
1064 public slots:
1061 };
1065 };
1062
1066
1063
1067
@@ -1,2936 +1,2928
1 <?xml version="1.0"?>
1 <?xml version="1.0"?>
2 <typesystem package="com.trolltech.qt.core"><template name="core.prepare_removed_bool*_argument">
2 <typesystem package="com.trolltech.qt.core"><template name="core.prepare_removed_bool*_argument">
3 bool __ok;
3 bool __ok;
4 bool *%out% = &amp;__ok;
4 bool *%out% = &amp;__ok;
5 </template><template name="core.convert_to_null_or_wrap">
5 </template><template name="core.convert_to_null_or_wrap">
6 QScriptValue %out%;
6 QScriptValue %out%;
7 if (!__ok)
7 if (!__ok)
8 %out% = context-&gt;engine()-&gt;nullValue();
8 %out% = context-&gt;engine()-&gt;nullValue();
9 else
9 else
10 %out% = qScriptValueFromValue(context-&gt;engine(), %in%);
10 %out% = qScriptValueFromValue(context-&gt;engine(), %in%);
11 </template><template name="core.convert_to_null_or_primitive">
11 </template><template name="core.convert_to_null_or_primitive">
12 QScriptValue %out%;
12 QScriptValue %out%;
13 if (!__ok)
13 if (!__ok)
14 %out% = context-&gt;engine()-&gt;nullValue();
14 %out% = context-&gt;engine()-&gt;nullValue();
15 else
15 else
16 %out% = QScriptValue(context-&gt;engine(), %in%);
16 %out% = QScriptValue(context-&gt;engine(), %in%);
17 </template><template name="core.convert_string_arg_to_latin1">
17 </template><template name="core.convert_string_arg_to_latin1">
18 QByteArray %out% = %in%.toString().toLatin1();
18 QByteArray %out% = %in%.toString().toLatin1();
19 </template><template name="core.convert_string_arg_to_char*">
19 </template><template name="core.convert_string_arg_to_char*">
20 QByteArray tmp_%out% = %in%.toString().toLatin1();
20 QByteArray tmp_%out% = %in%.toString().toLatin1();
21 const char * %out% = tmp_%out%.constData();
21 const char * %out% = tmp_%out%.constData();
22 </template><template name="core.convert_int_arg_and_check_range">
22 </template><template name="core.convert_int_arg_and_check_range">
23 int %out% = %in%.toInt32();
23 int %out% = %in%.toInt32();
24 if ((%out% &lt; 0) || (%this%-&gt;size() &lt; %out%)) {
24 if ((%out% &lt; 0) || (%this%-&gt;size() &lt; %out%)) {
25 return context-&gt;throwError(QScriptContext::RangeError,
25 return context-&gt;throwError(QScriptContext::RangeError,
26 QString::fromLatin1("%CLASS_NAME%::%FUNCTION_NAME%(): index out of range"));
26 QString::fromLatin1("%CLASS_NAME%::%FUNCTION_NAME%(): index out of range"));
27 }
27 }
28 </template><template name="core.convert_pointer_arg_and_check_null">
28 </template><template name="core.convert_pointer_arg_and_check_null">
29 %TYPE% %out% = qscriptvalue_cast&lt;%TYPE%&gt;(%in%);
29 %TYPE% %out% = qscriptvalue_cast&lt;%TYPE%&gt;(%in%);
30 if (!%out%) {
30 if (!%out%) {
31 return context-&gt;throwError(QScriptContext::TypeError,
31 return context-&gt;throwError(QScriptContext::TypeError,
32 QString::fromLatin1("%CLASS_NAME%::%FUNCTION_NAME%(): failed to convert argument to %TYPE%"));
32 QString::fromLatin1("%CLASS_NAME%::%FUNCTION_NAME%(): failed to convert argument to %TYPE%"));
33 }
33 }
34 </template><template name="core.convert_stringref_to_string">
34 </template><template name="core.convert_stringref_to_string">
35 QString %out% = %in%.toString();
35 QString %out% = %in%.toString();
36 </template><rejection class="QTextCodec::ConverterState"/><rejection class="QTextCodecFactoryInterface"/><rejection class="QAbstractEventDispatcher"/><rejection class="QAbstractFileEngine"/><rejection class="QAbstractFileEngineHandler"/><rejection class="QAbstractFileEngineIterator"/><rejection class="QFSFileEngine"/><rejection class="QSystemLocale"/><rejection class="QThread"/><rejection class="QFutureWatcherBase"/><rejection class="QFutureSynchronizer"/><rejection class="QByteArray" function-name="contains"/><enum-type name="QXmlStreamReader::Error"/><enum-type name="QXmlStreamReader::TokenType"/><primitive-type name="bool"/><primitive-type name="double"/><primitive-type name="qreal"/><primitive-type name="float"/><primitive-type name="qint64"/><primitive-type name="__int64"/><primitive-type name="unsigned __int64"/><primitive-type name="unsigned long long"/><primitive-type name="long long"/><primitive-type name="qlonglong"/><primitive-type name="qulonglong"/><primitive-type name="short"/><primitive-type name="short"/><primitive-type name="signed short"/><primitive-type name="ushort"/><primitive-type name="unsigned short"/><primitive-type name="char"/><primitive-type name="signed char"/><primitive-type name="uchar"/><primitive-type name="unsigned char"/><primitive-type name="int"/><primitive-type name="signed int"/><primitive-type name="uint"/><primitive-type name="ulong"/><primitive-type name="unsigned int"/><primitive-type name="signed long"/><primitive-type name="long"/><primitive-type name="unsigned long"/><primitive-type name="WId"/><primitive-type name="Qt::HANDLE"/><primitive-type name="QVariant::Type"/><primitive-type name="QByteRef"/><primitive-type name="QBitRef"/><primitive-type name="QBool"/><primitive-type name="jobject"/><primitive-type name="quintptr"/><suppress-warning text="WARNING(MetaJavaBuilder) :: signal 'finished' in class 'QProcess' is overloaded."/><suppress-warning text="WARNING(MetaJavaBuilder) :: missing required class for enums: QRegExp"/><suppress-warning text="WARNING(MetaJavaBuilder) :: enum 'QtValidLicenseForScriptToolsModule' does not have a type entry or is not an enum"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Rejected enum has no alternative...: QDataStream::Qt_4_5"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unhandled enum value: Qt::MatchFlags(Qt::MatchStartsWith in Qt::MatchFlag"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unhandled enum value: Qt::MatchWrap) in Qt::MatchFlag"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unmatched enum Qt::MatchFlags(Qt::MatchStartsWith|Qt::MatchWrap) when parsing default value of 'match' in class 'QAbstractItemModel'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Unable to decide type of property: 'Qt::GestureState' in class 'QGesture'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: enum 'Qt::GestureState' does not have a type entry or is not an enum"/><suppress-warning text="WARNING(MetaJavaBuilder) :: template baseclass 'QGenericMatrix&lt;qreal&gt;' of 'QMatrix3x3' is not known"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unhandled enum value: ~0u in Qt::GestureType"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unmatched enum ~0u"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unhandled enum value: Qt::GestureFlags() in Qt::GestureFlag"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unmatched enum Qt::GestureFlags() when parsing default value of 'grabGesture' in class 'QWidget'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unmatched enum Qt::GestureFlags() when parsing default value of 'grabGesture' in class 'QGraphicsObject'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unsupported default value 'QLatin1String(defaultConnection)' of argument in function '*', class '*'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Class '*' has equals operators but no qHash() function"/><suppress-warning text="WARNING(MetaJavaBuilder) :: type '*' is specified in typesystem, but not defined. This could potentially lead to compilation errors."/><suppress-warning text="WARNING(MetaJavaBuilder) :: namespace '*' for enum '*' is not declared"/><suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function '*', unmatched parameter type '*'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function '*', unmatched return type '*'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: signature '*' for function modification in '*' not found. Possible candidates: "/><suppress-warning text="WARNING(MetaJavaBuilder) :: namespace '*' does not have a type entry"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unsupported default value '*' of argument in function '*', class '*'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Shadowing: * and *; Java code will not compile"/><suppress-warning text="WARNING(MetaJavaBuilder) :: enum '*' is specified in typesystem, but not declared"/>
36 </template><rejection class="QTextCodec::ConverterState"/><rejection class="QTextCodecFactoryInterface"/><rejection class="QAbstractEventDispatcher"/><rejection class="QAbstractFileEngine"/><rejection class="QAbstractFileEngineHandler"/><rejection class="QAbstractFileEngineIterator"/><rejection class="QFSFileEngine"/><rejection class="QSystemLocale"/><rejection class="QThread"/><rejection class="QFutureWatcherBase"/><rejection class="QFutureSynchronizer"/><rejection class="QByteArray" function-name="contains"/><enum-type name="QXmlStreamReader::Error"/><enum-type name="QXmlStreamReader::TokenType"/><primitive-type name="bool"/><primitive-type name="double"/><primitive-type name="qreal"/><primitive-type name="float"/><primitive-type name="qint64"/><primitive-type name="__int64"/><primitive-type name="unsigned __int64"/><primitive-type name="unsigned long long"/><primitive-type name="long long"/><primitive-type name="qlonglong"/><primitive-type name="qulonglong"/><primitive-type name="short"/><primitive-type name="short"/><primitive-type name="signed short"/><primitive-type name="ushort"/><primitive-type name="unsigned short"/><primitive-type name="char"/><primitive-type name="signed char"/><primitive-type name="uchar"/><primitive-type name="unsigned char"/><primitive-type name="int"/><primitive-type name="signed int"/><primitive-type name="uint"/><primitive-type name="ulong"/><primitive-type name="unsigned int"/><primitive-type name="signed long"/><primitive-type name="long"/><primitive-type name="unsigned long"/><primitive-type name="WId"/><primitive-type name="Qt::HANDLE"/><primitive-type name="QVariant::Type"/><primitive-type name="QByteRef"/><primitive-type name="QBitRef"/><primitive-type name="QBool"/><primitive-type name="jobject"/><primitive-type name="quintptr"/><suppress-warning text="WARNING(MetaJavaBuilder) :: signal 'finished' in class 'QProcess' is overloaded."/><suppress-warning text="WARNING(MetaJavaBuilder) :: missing required class for enums: QRegExp"/><suppress-warning text="WARNING(MetaJavaBuilder) :: enum 'QtValidLicenseForScriptToolsModule' does not have a type entry or is not an enum"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Rejected enum has no alternative...: QDataStream::Qt_4_5"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unhandled enum value: Qt::MatchFlags(Qt::MatchStartsWith in Qt::MatchFlag"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unhandled enum value: Qt::MatchWrap) in Qt::MatchFlag"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unmatched enum Qt::MatchFlags(Qt::MatchStartsWith|Qt::MatchWrap) when parsing default value of 'match' in class 'QAbstractItemModel'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Unable to decide type of property: 'Qt::GestureState' in class 'QGesture'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: enum 'Qt::GestureState' does not have a type entry or is not an enum"/><suppress-warning text="WARNING(MetaJavaBuilder) :: template baseclass 'QGenericMatrix&lt;qreal&gt;' of 'QMatrix3x3' is not known"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unhandled enum value: ~0u in Qt::GestureType"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unmatched enum ~0u"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unhandled enum value: Qt::GestureFlags() in Qt::GestureFlag"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unmatched enum Qt::GestureFlags() when parsing default value of 'grabGesture' in class 'QWidget'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unmatched enum Qt::GestureFlags() when parsing default value of 'grabGesture' in class 'QGraphicsObject'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unsupported default value 'QLatin1String(defaultConnection)' of argument in function '*', class '*'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Class '*' has equals operators but no qHash() function"/><suppress-warning text="WARNING(MetaJavaBuilder) :: type '*' is specified in typesystem, but not defined. This could potentially lead to compilation errors."/><suppress-warning text="WARNING(MetaJavaBuilder) :: namespace '*' for enum '*' is not declared"/><suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function '*', unmatched parameter type '*'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function '*', unmatched return type '*'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: signature '*' for function modification in '*' not found. Possible candidates: "/><suppress-warning text="WARNING(MetaJavaBuilder) :: namespace '*' does not have a type entry"/><suppress-warning text="WARNING(MetaJavaBuilder) :: unsupported default value '*' of argument in function '*', class '*'"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Shadowing: * and *; Java code will not compile"/><suppress-warning text="WARNING(MetaJavaBuilder) :: enum '*' is specified in typesystem, but not declared"/>
37
37
38 <rejection class="*" function-name="d_func"/>
38 <rejection class="*" function-name="d_func"/>
39 <rejection class="*" function-name="data_ptr"/>
39 <rejection class="*" function-name="data_ptr"/>
40 <rejection class="*" function-name="detach"/>
40 <rejection class="*" function-name="detach"/>
41 <rejection class="*" function-name="isDetached"/>
41 <rejection class="*" function-name="isDetached"/>
42
42
43 <rejection class="*" field-name="d_ptr"/>
43 <rejection class="*" field-name="d_ptr"/>
44 <rejection class="*" field-name="d"/>
44 <rejection class="*" field-name="d"/>
45
45
46 <rejection class="" enum-name="QtValidLicenseForTestModule"/>
46 <rejection class="" enum-name="QtValidLicenseForTestModule"/>
47
47
48
48
49 <rejection class="" enum-name="QtValidLicenseForDBusModule"/>
49 <rejection class="" enum-name="QtValidLicenseForDBusModule"/>
50 <rejection class="" enum-name="QtValidLicenseForSqlModule"/>
50 <rejection class="" enum-name="QtValidLicenseForSqlModule"/>
51 <rejection class="" enum-name="QtValidLicenseForOpenGLModule"/>
51 <rejection class="" enum-name="QtValidLicenseForOpenGLModule"/>
52 <rejection class="" enum-name="enum_1"/>
52 <rejection class="" enum-name="enum_1"/>
53 <rejection class="" enum-name="enum_2"/>
53 <rejection class="" enum-name="enum_2"/>
54 <rejection class="" enum-name="QtValidLicenseForXmlModule"/>
54 <rejection class="" enum-name="QtValidLicenseForXmlModule"/>
55 <rejection class="" enum-name="QtValidLicenseForXmlPatternsModule"/>
55 <rejection class="" enum-name="QtValidLicenseForXmlPatternsModule"/>
56 <rejection class="" enum-name="QtValidLicenseForActiveQtModule"/>
56 <rejection class="" enum-name="QtValidLicenseForActiveQtModule"/>
57 <rejection class="" enum-name="QtValidLicenseForCoreModule"/>
57 <rejection class="" enum-name="QtValidLicenseForCoreModule"/>
58 <rejection class="" enum-name="QtValidLicenseForQt3SupportLightModule"/>
58 <rejection class="" enum-name="QtValidLicenseForQt3SupportLightModule"/>
59 <rejection class="" enum-name="QtValidLicenseForQt3SupportModule"/>
59 <rejection class="" enum-name="QtValidLicenseForQt3SupportModule"/>
60 <rejection class="" enum-name="QtValidLicenseForNetworkModule"/>
60 <rejection class="" enum-name="QtValidLicenseForNetworkModule"/>
61 <rejection class="" enum-name="QtValidLicenseForSvgModule"/>
61 <rejection class="" enum-name="QtValidLicenseForSvgModule"/>
62 <rejection class="" enum-name="QtValidLicenseForGuiModule"/>
62 <rejection class="" enum-name="QtValidLicenseForGuiModule"/>
63 <rejection class="" enum-name="QtValidLicenseForScriptModule"/>
63 <rejection class="" enum-name="QtValidLicenseForScriptModule"/>
64 <rejection class="" enum-name="QtValidLicenseForHelpModule"/>
64 <rejection class="" enum-name="QtValidLicenseForHelpModule"/>
65 <rejection class="" enum-name="QtValidLicenseForScriptToolsModule"/>
65 <rejection class="" enum-name="QtValidLicenseForScriptToolsModule"/>
66 <rejection class="" enum-name="QtValidLicenseForMultimediaModule"/>
66 <rejection class="" enum-name="QtValidLicenseForMultimediaModule"/>
67 <rejection class="" enum-name="QtValidLicenseForOpenVGModule"/>
67 <rejection class="" enum-name="QtValidLicenseForOpenVGModule"/>
68 <rejection class="" enum-name="QtValidLicenseForDeclarativeModule"/>
68 <rejection class="" enum-name="QtValidLicenseForDeclarativeModule"/>
69
69
70 <rejection class="QtConcurrent" enum-name="enum_1"/>
70 <rejection class="QtConcurrent" enum-name="enum_1"/>
71 <rejection class="QtConcurrent" function-name="operator|"/>
71 <rejection class="QtConcurrent" function-name="operator|"/>
72
72
73 <rejection class="Qt" enum-name="Modifier"/>
73 <rejection class="Qt" enum-name="Modifier"/>
74
74
75 <rejection class="QSharedPointer"/>
75 <rejection class="QSharedPointer"/>
76 <rejection class="QWeakPointer"/>
76 <rejection class="QWeakPointer"/>
77 <rejection class="QFuture::const_iterator"/>
77 <rejection class="QFuture::const_iterator"/>
78 <rejection class="QFutureInterface"/>
78 <rejection class="QFutureInterface"/>
79 <rejection class="QFutureInterfaceBase"/>
79 <rejection class="QFutureInterfaceBase"/>
80 <rejection class="QtConcurrent::BlockSizeManager"/>
80 <rejection class="QtConcurrent::BlockSizeManager"/>
81 <rejection class="QtConcurrent::ConstMemberFunctionWrapper"/>
81 <rejection class="QtConcurrent::ConstMemberFunctionWrapper"/>
82 <rejection class="QtConcurrent::Exception"/>
82 <rejection class="QtConcurrent::Exception"/>
83 <rejection class="QtConcurrent::FilterKernel"/>
83 <rejection class="QtConcurrent::FilterKernel"/>
84 <rejection class="QtConcurrent::FilteredEachKernel"/>
84 <rejection class="QtConcurrent::FilteredEachKernel"/>
85 <rejection class="QtConcurrent::FilteredReducedKernel"/>
85 <rejection class="QtConcurrent::FilteredReducedKernel"/>
86 <rejection class="QtConcurrent::FunctionWrapper0"/>
86 <rejection class="QtConcurrent::FunctionWrapper0"/>
87 <rejection class="QtConcurrent::FunctionWrapper1"/>
87 <rejection class="QtConcurrent::FunctionWrapper1"/>
88 <rejection class="QtConcurrent::FunctionWrapper2"/>
88 <rejection class="QtConcurrent::FunctionWrapper2"/>
89 <rejection class="QtConcurrent::IntermediateResults"/>
89 <rejection class="QtConcurrent::IntermediateResults"/>
90 <rejection class="QtConcurrent::IterateKernel"/>
90 <rejection class="QtConcurrent::IterateKernel"/>
91 <rejection class="QtConcurrent::MapKernel"/>
91 <rejection class="QtConcurrent::MapKernel"/>
92 <rejection class="QtConcurrent::MappedEachKernel"/>
92 <rejection class="QtConcurrent::MappedEachKernel"/>
93 <rejection class="QtConcurrent::MappedReducedKernel"/>
93 <rejection class="QtConcurrent::MappedReducedKernel"/>
94 <rejection class="QtConcurrent::Median"/>
94 <rejection class="QtConcurrent::Median"/>
95 <rejection class="QtConcurrent::MemberFunctionWrapper"/>
95 <rejection class="QtConcurrent::MemberFunctionWrapper"/>
96 <rejection class="QtConcurrent::MemberFunctionWrapper1"/>
96 <rejection class="QtConcurrent::MemberFunctionWrapper1"/>
97 <rejection class="QtConcurrent::qValueType"/>
97 <rejection class="QtConcurrent::qValueType"/>
98 <rejection class="QtConcurrent::ReduceKernel"/>
98 <rejection class="QtConcurrent::ReduceKernel"/>
99 <rejection class="QtConcurrent::ResultItem"/>
99 <rejection class="QtConcurrent::ResultItem"/>
100 <rejection class="QtConcurrent::ResultIterator"/>
100 <rejection class="QtConcurrent::ResultIterator"/>
101 <rejection class="QtConcurrent::ResultIteratorBase"/>
101 <rejection class="QtConcurrent::ResultIteratorBase"/>
102 <rejection class="QtConcurrent::ResultReporter"/>
102 <rejection class="QtConcurrent::ResultReporter"/>
103 <rejection class="QtConcurrent::ResultStore"/>
103 <rejection class="QtConcurrent::ResultStore"/>
104 <rejection class="QtConcurrent::ResultStoreBase"/>
104 <rejection class="QtConcurrent::ResultStoreBase"/>
105 <rejection class="QtConcurrent::RunFunctionTask"/>
105 <rejection class="QtConcurrent::RunFunctionTask"/>
106 <rejection class="QtConcurrent::RunFunctionTaskBase"/>
106 <rejection class="QtConcurrent::RunFunctionTaskBase"/>
107 <rejection class="QtConcurrent::SelectSpecialization"/>
107 <rejection class="QtConcurrent::SelectSpecialization"/>
108 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionCall0"/>
108 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionCall0"/>
109 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionCall1"/>
109 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionCall1"/>
110 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionCall2"/>
110 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionCall2"/>
111 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionCall3"/>
111 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionCall3"/>
112 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionCall4"/>
112 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionCall4"/>
113 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionCall5"/>
113 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionCall5"/>
114 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionPointerCall0"/>
114 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionPointerCall0"/>
115 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionPointerCall1"/>
115 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionPointerCall1"/>
116 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionPointerCall2"/>
116 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionPointerCall2"/>
117 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionPointerCall3"/>
117 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionPointerCall3"/>
118 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionPointerCall4"/>
118 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionPointerCall4"/>
119 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionPointerCall5"/>
119 <rejection class="QtConcurrent::SelectStoredConstMemberFunctionPointerCall5"/>
120 <rejection class="QtConcurrent::SelectStoredFunctorCall0"/>
120 <rejection class="QtConcurrent::SelectStoredFunctorCall0"/>
121 <rejection class="QtConcurrent::SelectStoredFunctorCall1"/>
121 <rejection class="QtConcurrent::SelectStoredFunctorCall1"/>
122 <rejection class="QtConcurrent::SelectStoredFunctorCall2"/>
122 <rejection class="QtConcurrent::SelectStoredFunctorCall2"/>
123 <rejection class="QtConcurrent::SelectStoredFunctorCall3"/>
123 <rejection class="QtConcurrent::SelectStoredFunctorCall3"/>
124 <rejection class="QtConcurrent::SelectStoredFunctorCall4"/>
124 <rejection class="QtConcurrent::SelectStoredFunctorCall4"/>
125 <rejection class="QtConcurrent::SelectStoredFunctorCall5"/>
125 <rejection class="QtConcurrent::SelectStoredFunctorCall5"/>
126 <rejection class="QtConcurrent::SelectStoredFunctorPointerCall0"/>
126 <rejection class="QtConcurrent::SelectStoredFunctorPointerCall0"/>
127 <rejection class="QtConcurrent::SelectStoredFunctorPointerCall1"/>
127 <rejection class="QtConcurrent::SelectStoredFunctorPointerCall1"/>
128 <rejection class="QtConcurrent::SelectStoredFunctorPointerCall2"/>
128 <rejection class="QtConcurrent::SelectStoredFunctorPointerCall2"/>
129 <rejection class="QtConcurrent::SelectStoredFunctorPointerCall3"/>
129 <rejection class="QtConcurrent::SelectStoredFunctorPointerCall3"/>
130 <rejection class="QtConcurrent::SelectStoredFunctorPointerCall4"/>
130 <rejection class="QtConcurrent::SelectStoredFunctorPointerCall4"/>
131 <rejection class="QtConcurrent::SelectStoredFunctorPointerCall5"/>
131 <rejection class="QtConcurrent::SelectStoredFunctorPointerCall5"/>
132 <rejection class="QtConcurrent::SelectStoredMemberFunctionCall0"/>
132 <rejection class="QtConcurrent::SelectStoredMemberFunctionCall0"/>
133 <rejection class="QtConcurrent::SelectStoredMemberFunctionCall1"/>
133 <rejection class="QtConcurrent::SelectStoredMemberFunctionCall1"/>
134 <rejection class="QtConcurrent::SelectStoredMemberFunctionCall2"/>
134 <rejection class="QtConcurrent::SelectStoredMemberFunctionCall2"/>
135 <rejection class="QtConcurrent::SelectStoredMemberFunctionCall3"/>
135 <rejection class="QtConcurrent::SelectStoredMemberFunctionCall3"/>
136 <rejection class="QtConcurrent::SelectStoredMemberFunctionCall4"/>
136 <rejection class="QtConcurrent::SelectStoredMemberFunctionCall4"/>
137 <rejection class="QtConcurrent::SelectStoredMemberFunctionCall5"/>
137 <rejection class="QtConcurrent::SelectStoredMemberFunctionCall5"/>
138 <rejection class="QtConcurrent::SelectStoredMemberFunctionPointerCall0"/>
138 <rejection class="QtConcurrent::SelectStoredMemberFunctionPointerCall0"/>
139 <rejection class="QtConcurrent::SelectStoredMemberFunctionPointerCall1"/>
139 <rejection class="QtConcurrent::SelectStoredMemberFunctionPointerCall1"/>
140 <rejection class="QtConcurrent::SelectStoredMemberFunctionPointerCall2"/>
140 <rejection class="QtConcurrent::SelectStoredMemberFunctionPointerCall2"/>
141 <rejection class="QtConcurrent::SelectStoredMemberFunctionPointerCall3"/>
141 <rejection class="QtConcurrent::SelectStoredMemberFunctionPointerCall3"/>
142 <rejection class="QtConcurrent::SelectStoredMemberFunctionPointerCall4"/>
142 <rejection class="QtConcurrent::SelectStoredMemberFunctionPointerCall4"/>
143 <rejection class="QtConcurrent::SelectStoredMemberFunctionPointerCall5"/>
143 <rejection class="QtConcurrent::SelectStoredMemberFunctionPointerCall5"/>
144 <rejection class="QtConcurrent::SequenceHolder1"/>
144 <rejection class="QtConcurrent::SequenceHolder1"/>
145 <rejection class="QtConcurrent::SequenceHolder2"/>
145 <rejection class="QtConcurrent::SequenceHolder2"/>
146 <rejection class="QtConcurrent::StoredConstMemberFunctionCall0"/>
146 <rejection class="QtConcurrent::StoredConstMemberFunctionCall0"/>
147 <rejection class="QtConcurrent::StoredConstMemberFunctionCall1"/>
147 <rejection class="QtConcurrent::StoredConstMemberFunctionCall1"/>
148 <rejection class="QtConcurrent::StoredConstMemberFunctionCall2"/>
148 <rejection class="QtConcurrent::StoredConstMemberFunctionCall2"/>
149 <rejection class="QtConcurrent::StoredConstMemberFunctionCall3"/>
149 <rejection class="QtConcurrent::StoredConstMemberFunctionCall3"/>
150 <rejection class="QtConcurrent::StoredConstMemberFunctionCall4"/>
150 <rejection class="QtConcurrent::StoredConstMemberFunctionCall4"/>
151 <rejection class="QtConcurrent::StoredConstMemberFunctionCall5"/>
151 <rejection class="QtConcurrent::StoredConstMemberFunctionCall5"/>
152 <rejection class="QtConcurrent::StoredConstMemberFunctionPointerCall0"/>
152 <rejection class="QtConcurrent::StoredConstMemberFunctionPointerCall0"/>
153 <rejection class="QtConcurrent::StoredConstMemberFunctionPointerCall1"/>
153 <rejection class="QtConcurrent::StoredConstMemberFunctionPointerCall1"/>
154 <rejection class="QtConcurrent::StoredConstMemberFunctionPointerCall2"/>
154 <rejection class="QtConcurrent::StoredConstMemberFunctionPointerCall2"/>
155 <rejection class="QtConcurrent::StoredConstMemberFunctionPointerCall3"/>
155 <rejection class="QtConcurrent::StoredConstMemberFunctionPointerCall3"/>
156 <rejection class="QtConcurrent::StoredConstMemberFunctionPointerCall4"/>
156 <rejection class="QtConcurrent::StoredConstMemberFunctionPointerCall4"/>
157 <rejection class="QtConcurrent::StoredConstMemberFunctionPointerCall5"/>
157 <rejection class="QtConcurrent::StoredConstMemberFunctionPointerCall5"/>
158 <rejection class="QtConcurrent::StoredFunctorCall0"/>
158 <rejection class="QtConcurrent::StoredFunctorCall0"/>
159 <rejection class="QtConcurrent::StoredFunctorCall1"/>
159 <rejection class="QtConcurrent::StoredFunctorCall1"/>
160 <rejection class="QtConcurrent::StoredFunctorCall2"/>
160 <rejection class="QtConcurrent::StoredFunctorCall2"/>
161 <rejection class="QtConcurrent::StoredFunctorCall3"/>
161 <rejection class="QtConcurrent::StoredFunctorCall3"/>
162 <rejection class="QtConcurrent::StoredFunctorCall4"/>
162 <rejection class="QtConcurrent::StoredFunctorCall4"/>
163 <rejection class="QtConcurrent::StoredFunctorCall5"/>
163 <rejection class="QtConcurrent::StoredFunctorCall5"/>
164 <rejection class="QtConcurrent::StoredFunctorPointerCall0"/>
164 <rejection class="QtConcurrent::StoredFunctorPointerCall0"/>
165 <rejection class="QtConcurrent::StoredFunctorPointerCall1"/>
165 <rejection class="QtConcurrent::StoredFunctorPointerCall1"/>
166 <rejection class="QtConcurrent::StoredFunctorPointerCall2"/>
166 <rejection class="QtConcurrent::StoredFunctorPointerCall2"/>
167 <rejection class="QtConcurrent::StoredFunctorPointerCall3"/>
167 <rejection class="QtConcurrent::StoredFunctorPointerCall3"/>
168 <rejection class="QtConcurrent::StoredFunctorPointerCall4"/>
168 <rejection class="QtConcurrent::StoredFunctorPointerCall4"/>
169 <rejection class="QtConcurrent::StoredFunctorPointerCall5"/>
169 <rejection class="QtConcurrent::StoredFunctorPointerCall5"/>
170 <rejection class="QtConcurrent::StoredMemberFunctionCall0"/>
170 <rejection class="QtConcurrent::StoredMemberFunctionCall0"/>
171 <rejection class="QtConcurrent::StoredMemberFunctionCall1"/>
171 <rejection class="QtConcurrent::StoredMemberFunctionCall1"/>
172 <rejection class="QtConcurrent::StoredMemberFunctionCall2"/>
172 <rejection class="QtConcurrent::StoredMemberFunctionCall2"/>
173 <rejection class="QtConcurrent::StoredMemberFunctionCall3"/>
173 <rejection class="QtConcurrent::StoredMemberFunctionCall3"/>
174 <rejection class="QtConcurrent::StoredMemberFunctionCall4"/>
174 <rejection class="QtConcurrent::StoredMemberFunctionCall4"/>
175 <rejection class="QtConcurrent::StoredMemberFunctionCall5"/>
175 <rejection class="QtConcurrent::StoredMemberFunctionCall5"/>
176 <rejection class="QtConcurrent::StoredMemberFunctionPointerCall0"/>
176 <rejection class="QtConcurrent::StoredMemberFunctionPointerCall0"/>
177 <rejection class="QtConcurrent::StoredMemberFunctionPointerCall1"/>
177 <rejection class="QtConcurrent::StoredMemberFunctionPointerCall1"/>
178 <rejection class="QtConcurrent::StoredMemberFunctionPointerCall2"/>
178 <rejection class="QtConcurrent::StoredMemberFunctionPointerCall2"/>
179 <rejection class="QtConcurrent::StoredMemberFunctionPointerCall3"/>
179 <rejection class="QtConcurrent::StoredMemberFunctionPointerCall3"/>
180 <rejection class="QtConcurrent::StoredMemberFunctionPointerCall4"/>
180 <rejection class="QtConcurrent::StoredMemberFunctionPointerCall4"/>
181 <rejection class="QtConcurrent::StoredMemberFunctionPointerCall5"/>
181 <rejection class="QtConcurrent::StoredMemberFunctionPointerCall5"/>
182 <rejection class="QtConcurrent::ThreadEngine"/>
182 <rejection class="QtConcurrent::ThreadEngine"/>
183 <rejection class="QtConcurrent::ThreadEngineBase"/>
183 <rejection class="QtConcurrent::ThreadEngineBase"/>
184 <rejection class="QtConcurrent::ThreadEngineSemaphore"/>
184 <rejection class="QtConcurrent::ThreadEngineSemaphore"/>
185 <rejection class="QtConcurrent::ThreadEngineStarter"/>
185 <rejection class="QtConcurrent::ThreadEngineStarter"/>
186 <rejection class="QtConcurrent::ThreadEngineStarterBase"/>
186 <rejection class="QtConcurrent::ThreadEngineStarterBase"/>
187 <rejection class="QtConcurrent::UnhandledException"/>
187 <rejection class="QtConcurrent::UnhandledException"/>
188 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionCall0"/>
188 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionCall0"/>
189 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionCall1"/>
189 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionCall1"/>
190 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionCall2"/>
190 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionCall2"/>
191 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionCall3"/>
191 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionCall3"/>
192 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionCall4"/>
192 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionCall4"/>
193 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionCall5"/>
193 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionCall5"/>
194 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionPointerCall0"/>
194 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionPointerCall0"/>
195 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionPointerCall1"/>
195 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionPointerCall1"/>
196 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionPointerCall2"/>
196 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionPointerCall2"/>
197 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionPointerCall3"/>
197 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionPointerCall3"/>
198 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionPointerCall4"/>
198 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionPointerCall4"/>
199 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionPointerCall5"/>
199 <rejection class="QtConcurrent::VoidStoredConstMemberFunctionPointerCall5"/>
200 <rejection class="QtConcurrent::VoidStoredFunctorCall0"/>
200 <rejection class="QtConcurrent::VoidStoredFunctorCall0"/>
201 <rejection class="QtConcurrent::VoidStoredFunctorCall1"/>
201 <rejection class="QtConcurrent::VoidStoredFunctorCall1"/>
202 <rejection class="QtConcurrent::VoidStoredFunctorCall2"/>
202 <rejection class="QtConcurrent::VoidStoredFunctorCall2"/>
203 <rejection class="QtConcurrent::VoidStoredFunctorCall3"/>
203 <rejection class="QtConcurrent::VoidStoredFunctorCall3"/>
204 <rejection class="QtConcurrent::VoidStoredFunctorCall4"/>
204 <rejection class="QtConcurrent::VoidStoredFunctorCall4"/>
205 <rejection class="QtConcurrent::VoidStoredFunctorCall5"/>
205 <rejection class="QtConcurrent::VoidStoredFunctorCall5"/>
206 <rejection class="QtConcurrent::VoidStoredFunctorPointerCall0"/>
206 <rejection class="QtConcurrent::VoidStoredFunctorPointerCall0"/>
207 <rejection class="QtConcurrent::VoidStoredFunctorPointerCall1"/>
207 <rejection class="QtConcurrent::VoidStoredFunctorPointerCall1"/>
208 <rejection class="QtConcurrent::VoidStoredFunctorPointerCall2"/>
208 <rejection class="QtConcurrent::VoidStoredFunctorPointerCall2"/>
209 <rejection class="QtConcurrent::VoidStoredFunctorPointerCall3"/>
209 <rejection class="QtConcurrent::VoidStoredFunctorPointerCall3"/>
210 <rejection class="QtConcurrent::VoidStoredFunctorPointerCall4"/>
210 <rejection class="QtConcurrent::VoidStoredFunctorPointerCall4"/>
211 <rejection class="QtConcurrent::VoidStoredFunctorPointerCall5"/>
211 <rejection class="QtConcurrent::VoidStoredFunctorPointerCall5"/>
212 <rejection class="QtConcurrent::VoidStoredMemberFunctionCall0"/>
212 <rejection class="QtConcurrent::VoidStoredMemberFunctionCall0"/>
213 <rejection class="QtConcurrent::VoidStoredMemberFunctionCall1"/>
213 <rejection class="QtConcurrent::VoidStoredMemberFunctionCall1"/>
214 <rejection class="QtConcurrent::VoidStoredMemberFunctionCall2"/>
214 <rejection class="QtConcurrent::VoidStoredMemberFunctionCall2"/>
215 <rejection class="QtConcurrent::VoidStoredMemberFunctionCall3"/>
215 <rejection class="QtConcurrent::VoidStoredMemberFunctionCall3"/>
216 <rejection class="QtConcurrent::VoidStoredMemberFunctionCall4"/>
216 <rejection class="QtConcurrent::VoidStoredMemberFunctionCall4"/>
217 <rejection class="QtConcurrent::VoidStoredMemberFunctionCall5"/>
217 <rejection class="QtConcurrent::VoidStoredMemberFunctionCall5"/>
218 <rejection class="QtConcurrent::VoidStoredMemberFunctionPointerCall0"/>
218 <rejection class="QtConcurrent::VoidStoredMemberFunctionPointerCall0"/>
219 <rejection class="QtConcurrent::VoidStoredMemberFunctionPointerCall1"/>
219 <rejection class="QtConcurrent::VoidStoredMemberFunctionPointerCall1"/>
220 <rejection class="QtConcurrent::VoidStoredMemberFunctionPointerCall2"/>
220 <rejection class="QtConcurrent::VoidStoredMemberFunctionPointerCall2"/>
221 <rejection class="QtConcurrent::VoidStoredMemberFunctionPointerCall3"/>
221 <rejection class="QtConcurrent::VoidStoredMemberFunctionPointerCall3"/>
222 <rejection class="QtConcurrent::VoidStoredMemberFunctionPointerCall4"/>
222 <rejection class="QtConcurrent::VoidStoredMemberFunctionPointerCall4"/>
223 <rejection class="QtConcurrent::VoidStoredMemberFunctionPointerCall5"/>
223 <rejection class="QtConcurrent::VoidStoredMemberFunctionPointerCall5"/>
224
224
225 <rejection class="QMdi"/>
225 <rejection class="QMdi"/>
226 <rejection class="stdext"/>
226 <rejection class="stdext"/>
227 <rejection class="QAlgorithmsPrivate"/>
227 <rejection class="QAlgorithmsPrivate"/>
228 <rejection class="QAtomic"/>
228 <rejection class="QAtomic"/>
229 <rejection class="QAtomicPointer"/>
229 <rejection class="QAtomicPointer"/>
230 <rejection class="QAtomicInt"/>
230 <rejection class="QAtomicInt"/>
231 <rejection class="QBasicAtomicInt"/>
231 <rejection class="QBasicAtomicInt"/>
232 <rejection class="QBasicAtomic"/>
232 <rejection class="QBasicAtomic"/>
233 <rejection class="QBasicAtomicPointer"/>
233 <rejection class="QBasicAtomicPointer"/>
234 <rejection class="QScopedPointer"/>
234 <rejection class="QScopedPointer"/>
235 <rejection class="QScopedArrayPointer"/>
235 <rejection class="QScopedArrayPointer"/>
236 <rejection class="QScopedPointer"/>
236 <rejection class="QScopedPointer"/>
237 <rejection class="QScopedPointerArrayDeleter"/>
237 <rejection class="QScopedPointerArrayDeleter"/>
238 <rejection class="QScopedPointerDeleter"/>
238 <rejection class="QScopedPointerDeleter"/>
239 <rejection class="QScopedPointerPodDeleter"/>
239 <rejection class="QScopedPointerPodDeleter"/>
240 <rejection class="QScopedPointerSharedDeleter"/>
240 <rejection class="QScopedPointerSharedDeleter"/>
241 <rejection class="QScopedSharedPointer"/>
241 <rejection class="QScopedSharedPointer"/>
242 <rejection class="QCustomScopedPointer"/>
242 <rejection class="QCustomScopedPointer"/>
243 <rejection class="QStringBuilder"/>
243 <rejection class="QStringBuilder"/>
244
244
245 <rejection class="QBitRef"/>
245 <rejection class="QBitRef"/>
246 <rejection class="QCache"/>
246 <rejection class="QCache"/>
247 <rejection class="QContiguousCache"/>
247 <rejection class="QContiguousCache"/>
248 <rejection class="QContiguousCacheData"/>
248 <rejection class="QContiguousCacheData"/>
249 <rejection class="QContiguousCacheTypedData"/>
249 <rejection class="QContiguousCacheTypedData"/>
250 <rejection class="QCharRef"/>
250 <rejection class="QCharRef"/>
251 <rejection class="QDebug"/>
251 <rejection class="QDebug"/>
252 <rejection class="QNoDebug"/>
252 <rejection class="QNoDebug"/>
253 <rejection class="QExplicitlySharedDataPointer"/>
253 <rejection class="QExplicitlySharedDataPointer"/>
254 <rejection class="QFlag"/>
254 <rejection class="QFlag"/>
255 <rejection class="QFlags"/>
255 <rejection class="QFlags"/>
256 <rejection class="QForeachContainer"/>
256 <rejection class="QForeachContainer"/>
257 <rejection class="QForeachContainerBase"/>
257 <rejection class="QForeachContainerBase"/>
258 <rejection class="QGlobalStatic"/>
258 <rejection class="QGlobalStatic"/>
259 <rejection class="QHash"/>
259 <rejection class="QHash"/>
260 <rejection class="QHashData"/>
260 <rejection class="QHashData"/>
261 <rejection class="QHashDummyNode"/>
261 <rejection class="QHashDummyNode"/>
262 <rejection class="QHashDummyNode"/>
262 <rejection class="QHashDummyNode"/>
263 <rejection class="QHashDummyNode"/>
263 <rejection class="QHashDummyNode"/>
264 <rejection class="QHashDummyNode"/>
264 <rejection class="QHashDummyNode"/>
265 <rejection class="QHashDummyNode"/>
265 <rejection class="QHashDummyNode"/>
266 <rejection class="QHashDummyValue"/>
266 <rejection class="QHashDummyValue"/>
267 <rejection class="QHashIterator"/>
267 <rejection class="QHashIterator"/>
268 <rejection class="QHashNode"/>
268 <rejection class="QHashNode"/>
269 <rejection class="QHashNode"/>
269 <rejection class="QHashNode"/>
270 <rejection class="QHashNode"/>
270 <rejection class="QHashNode"/>
271 <rejection class="QHashNode"/>
271 <rejection class="QHashNode"/>
272 <rejection class="QHashNode"/>
272 <rejection class="QHashNode"/>
273 <rejection class="QInternal"/>
273 <rejection class="QInternal"/>
274 <rejection class="QIncompatibleFlag"/>
274 <rejection class="QIncompatibleFlag"/>
275 <rejection class="QLibrary"/>
275 <rejection class="QLibrary"/>
276 <rejection class="QLinkedList"/>
276 <rejection class="QLinkedList"/>
277 <rejection class="QLinkedListData"/>
277 <rejection class="QLinkedListData"/>
278 <rejection class="QLinkedListIterator"/>
278 <rejection class="QLinkedListIterator"/>
279 <rejection class="QLinkedListNode"/>
279 <rejection class="QLinkedListNode"/>
280 <rejection class="QListData"/>
280 <rejection class="QListData"/>
281 <rejection class="QListIterator"/>
281 <rejection class="QListIterator"/>
282 <rejection class="QMap"/>
282 <rejection class="QMap"/>
283 <rejection class="QMapNode"/>
283 <rejection class="QMapNode"/>
284 <rejection class="QMapPayloadNode"/>
284 <rejection class="QMapPayloadNode"/>
285 <rejection class="QMapData"/>
285 <rejection class="QMapData"/>
286 <rejection class="QMapIterator"/>
286 <rejection class="QMapIterator"/>
287 <rejection class="QMetaType"/>
287 <rejection class="QMetaType"/>
288 <rejection class="QMetaTypeId"/>
288 <rejection class="QMetaTypeId"/>
289 <rejection class="QMetaProperty"/>
289 <rejection class="QMetaProperty"/>
290 <rejection class="QMetaObject"/>
290 <rejection class="QMetaObject"/>
291 <rejection class="QMetaClassInfo"/>
291 <rejection class="QMetaClassInfo"/>
292 <rejection class="QMetaMethod"/>
292 <rejection class="QMetaMethod"/>
293 <rejection class="QMetaEnum"/>
293 <rejection class="QMetaEnum"/>
294 <rejection class="QMultiHash"/>
294 <rejection class="QMultiHash"/>
295 <rejection class="QMultiMap"/>
295 <rejection class="QMultiMap"/>
296 <rejection class="QMutableHashIterator"/>
296 <rejection class="QMutableHashIterator"/>
297 <rejection class="QMutableLinkedListIterator"/>
297 <rejection class="QMutableLinkedListIterator"/>
298 <rejection class="QMutableListIterator"/>
298 <rejection class="QMutableListIterator"/>
299 <rejection class="QMutableMapIterator"/>
299 <rejection class="QMutableMapIterator"/>
300 <rejection class="QMutableVectorIterator"/>
300 <rejection class="QMutableVectorIterator"/>
301 <rejection class="QMutexLocker"/>
301 <rejection class="QMutexLocker"/>
302 <rejection class="QNoImplicitBoolCast"/>
302 <rejection class="QNoImplicitBoolCast"/>
303 <rejection class="QObjectCleanupHandler"/>
303 <rejection class="QObjectCleanupHandler"/>
304 <rejection class="QObjectData"/>
304 <rejection class="QObjectData"/>
305 <rejection class="QObjectUserData"/>
305 <rejection class="QObjectUserData"/>
306 <rejection class="QPluginLoader"/>
306 <rejection class="QPluginLoader"/>
307 <rejection class="QPointer"/>
307 <rejection class="QPointer"/>
308 <rejection class="QReadLocker"/>
308 <rejection class="QReadLocker"/>
309 <rejection class="QResource"/>
309 <rejection class="QResource"/>
310 <rejection class="QSet"/>
310 <rejection class="QSet"/>
311 <rejection class="QSetIterator"/>
311 <rejection class="QSetIterator"/>
312 <rejection class="QSharedData"/>
312 <rejection class="QSharedData"/>
313 <rejection class="QSharedDataPointer"/>
313 <rejection class="QSharedDataPointer"/>
314 <rejection class="QStack"/>
314 <rejection class="QStack"/>
315 <rejection class="QSysInfo"/>
315 <rejection class="QSysInfo"/>
316 <rejection class="QTextStreamManipulator"/>
316 <rejection class="QTextStreamManipulator"/>
317 <rejection class="QThread"/>
317 <rejection class="QThread"/>
318 <rejection class="QThreadStorage"/>
318 <rejection class="QThreadStorage"/>
319 <rejection class="QThreadStorageData"/>
319 <rejection class="QThreadStorageData"/>
320 <rejection class="QTypeInfo"/>
320 <rejection class="QTypeInfo"/>
321 <rejection class="QTypeInfo"/>
321 <rejection class="QTypeInfo"/>
322 <rejection class="QVFbKeyData"/>
322 <rejection class="QVFbKeyData"/>
323 <rejection class="QVariantComparisonHelper"/>
323 <rejection class="QVariantComparisonHelper"/>
324 <rejection class="QVectorData"/>
324 <rejection class="QVectorData"/>
325 <rejection class="QVectorIterator"/>
325 <rejection class="QVectorIterator"/>
326 <rejection class="QVectorTypedData"/>
326 <rejection class="QVectorTypedData"/>
327 <rejection class="QWriteLocker"/>
327 <rejection class="QWriteLocker"/>
328 <rejection class="QtPrivate"/>
328 <rejection class="QtPrivate"/>
329 <rejection class="qGreater"/>
329 <rejection class="qGreater"/>
330 <rejection class="qLess"/>
330 <rejection class="qLess"/>
331 <rejection class="std"/>
331 <rejection class="std"/>
332 <rejection class="QAbstractFileEngine::ExtensionOption"/>
332 <rejection class="QAbstractFileEngine::ExtensionOption"/>
333 <rejection class="QAbstractFileEngine::ExtensionReturn"/>
333 <rejection class="QAbstractFileEngine::ExtensionReturn"/>
334 <rejection class="QByteArray::Data"/>
334 <rejection class="QByteArray::Data"/>
335 <rejection class="QIntForType"/>
335 <rejection class="QIntForType"/>
336 <rejection class="QList::Node"/>
336 <rejection class="QList::Node"/>
337 <rejection class="QList::const_iterator"/>
337 <rejection class="QList::const_iterator"/>
338 <rejection class="QList::iterator"/>
338 <rejection class="QList::iterator"/>
339 <rejection class="QMetaTypeId2"/>
339 <rejection class="QMetaTypeId2"/>
340 <rejection class="QMutableSetIterator"/>
340 <rejection class="QMutableSetIterator"/>
341 <rejection class="QSubString"/>
341 <rejection class="QSubString"/>
342 <rejection class="QUintForType"/>
342 <rejection class="QUintForType"/>
343 <rejection class="QtConcurrent::internal"/>
343 <rejection class="QtConcurrent::internal"/>
344 <rejection class="QByteArrayMatcher::Data"/>
344 <rejection class="QByteArrayMatcher::Data"/>
345 <rejection class="QStringMatcher::Data"/>
345 <rejection class="QStringMatcher::Data"/>
346
346
347 <rejection class="StringBuilder"/>
347 <rejection class="StringBuilder"/>
348 <rejection class="QConcatenable"/>
348 <rejection class="QConcatenable"/>
349 <rejection class="QLatin1Literal"/>
349 <rejection class="QLatin1Literal"/>
350 <rejection class="QIntegerForSizeof"/>
350 <rejection class="QIntegerForSizeof"/>
351
351
352
352
353 <rejection class="QLocale::Data"/>
353 <rejection class="QLocale::Data"/>
354 <rejection class="QGlobalStaticDeleter"/>
354 <rejection class="QGlobalStaticDeleter"/>
355 <rejection class="QSharedMemory"/> <!-- Temporarily until we know how to implement it in Java -->
355 <rejection class="QSharedMemory"/> <!-- Temporarily until we know how to implement it in Java -->
356 <rejection class="QVarLengthArray"/>
356 <rejection class="QVarLengthArray"/>
357
357
358 <!-- DBus -->
358 <!-- DBus -->
359 <rejection class="QDBusAbstractAdaptor"/>
359 <rejection class="QDBusAbstractAdaptor"/>
360 <rejection class="QDBusAbstractInterface"/>
360 <rejection class="QDBusAbstractInterface"/>
361 <rejection class="QDBusArgument"/>
361 <rejection class="QDBusArgument"/>
362 <rejection class="QDBusConnection"/>
362 <rejection class="QDBusConnection"/>
363 <rejection class="QDBusConnectionInterface"/>
363 <rejection class="QDBusConnectionInterface"/>
364 <rejection class="QDBusContext"/>
364 <rejection class="QDBusContext"/>
365 <rejection class="QDBusError"/>
365 <rejection class="QDBusError"/>
366 <rejection class="QDBusInterface"/>
366 <rejection class="QDBusInterface"/>
367 <rejection class="QDBusMessage"/>
367 <rejection class="QDBusMessage"/>
368 <rejection class="QDBusMetaType"/>
368 <rejection class="QDBusMetaType"/>
369 <rejection class="QDBusObjectPath"/>
369 <rejection class="QDBusObjectPath"/>
370 <rejection class="QDBusReply"/>
370 <rejection class="QDBusReply"/>
371 <rejection class="QDBusServer"/>
371 <rejection class="QDBusServer"/>
372 <rejection class="QDBusSignature"/>
372 <rejection class="QDBusSignature"/>
373 <rejection class="QDBusVariant"/>
373 <rejection class="QDBusVariant"/>
374
374
375 <rejection class="_Revbidit"/>
375 <rejection class="_Revbidit"/>
376 <rejection class="_complex"/>
376 <rejection class="_complex"/>
377 <rejection class="_exception"/>
377 <rejection class="_exception"/>
378 <rejection class="_iobuf"/>
378 <rejection class="_iobuf"/>
379 <rejection class="_stat"/>
379 <rejection class="_stat"/>
380 <rejection class="_wfinddata_t"/>
380 <rejection class="_wfinddata_t"/>
381 <rejection class="exception"/>
381 <rejection class="exception"/>
382 <rejection class="istreambuf_iterator"/>
382 <rejection class="istreambuf_iterator"/>
383 <rejection class="ostreambuf_iterator"/>
383 <rejection class="ostreambuf_iterator"/>
384 <rejection class="reverse_bidirectional_iterator"/>
384 <rejection class="reverse_bidirectional_iterator"/>
385 <rejection class="reverse_iterator"/>
385 <rejection class="reverse_iterator"/>
386 <rejection class="stat"/>
386 <rejection class="stat"/>
387 <rejection class="tm"/>
387 <rejection class="tm"/>
388
388
389 <rejection class="Qt" enum-name="Initialization"/>
389 <rejection class="Qt" enum-name="Initialization"/>
390
390
391 <rejection class="QAbstractEventDispatcher" function-name="filterEvent"/>
391 <rejection class="QAbstractEventDispatcher" function-name="filterEvent"/>
392 <rejection class="QAbstractEventDispatcher" function-name="setEventFilter"/>
392 <rejection class="QAbstractEventDispatcher" function-name="setEventFilter"/>
393 <rejection class="QAbstractEventDispatcher" function-name="registerTimer"/>
393 <rejection class="QAbstractEventDispatcher" function-name="registerTimer"/>
394 <rejection class="QAbstractFileEngine" function-name="beginEntryList"/>
394 <rejection class="QAbstractFileEngine" function-name="beginEntryList"/>
395 <rejection class="QAbstractFileEngine" function-name="endEntryList"/>
395 <rejection class="QAbstractFileEngine" function-name="endEntryList"/>
396 <rejection class="QAbstractFileEngine" function-name="extension"/>
396 <rejection class="QAbstractFileEngine" function-name="extension"/>
397 <rejection class="QCoreApplication" function-name="compressEvent"/>
397 <rejection class="QCoreApplication" function-name="compressEvent"/>
398 <rejection class="QCoreApplication" function-name="eventFilter"/>
398 <rejection class="QCoreApplication" function-name="eventFilter"/>
399 <rejection class="QCoreApplication" function-name="filterEvent"/>
399 <rejection class="QCoreApplication" function-name="filterEvent"/>
400 <rejection class="QCoreApplication" function-name="setEventFilter"/>
400 <rejection class="QCoreApplication" function-name="setEventFilter"/>
401 <rejection class="QFile" function-name="setDecodingFunction"/>
401 <rejection class="QFile" function-name="setDecodingFunction"/>
402 <rejection class="QFile" function-name="setEncodingFunction"/>
402 <rejection class="QFile" function-name="setEncodingFunction"/>
403 <rejection class="QList" function-name="begin"/>
403 <rejection class="QList" function-name="begin"/>
404 <rejection class="QList" function-name="constBegin"/>
404 <rejection class="QList" function-name="constBegin"/>
405 <rejection class="QList" function-name="constEnd"/>
405 <rejection class="QList" function-name="constEnd"/>
406 <rejection class="QList" function-name="end"/>
406 <rejection class="QList" function-name="end"/>
407 <rejection class="QList" function-name="erase"/>
407 <rejection class="QList" function-name="erase"/>
408 <rejection class="QList" function-name="erase"/>
408 <rejection class="QList" function-name="erase"/>
409 <rejection class="QList" function-name="free"/>
409 <rejection class="QList" function-name="free"/>
410 <rejection class="QList" function-name="fromList"/>
410 <rejection class="QList" function-name="fromList"/>
411 <rejection class="QList" function-name="fromSet"/>
411 <rejection class="QList" function-name="fromSet"/>
412 <rejection class="QList" function-name="fromSet"/>
412 <rejection class="QList" function-name="fromSet"/>
413 <rejection class="QList" function-name="insert"/>
413 <rejection class="QList" function-name="insert"/>
414 <rejection class="QList" function-name="malloc"/>
414 <rejection class="QList" function-name="malloc"/>
415 <rejection class="QList" function-name="node_construct"/>
415 <rejection class="QList" function-name="node_construct"/>
416 <rejection class="QList" function-name="node_copy"/>
416 <rejection class="QList" function-name="node_copy"/>
417 <rejection class="QList" function-name="node_destruct"/>
417 <rejection class="QList" function-name="node_destruct"/>
418 <rejection class="QList" function-name="toSet"/>
418 <rejection class="QList" function-name="toSet"/>
419 <rejection class="QObject" function-name="receivers"/>
419 <rejection class="QObject" function-name="receivers"/>
420 <rejection class="QObject" function-name="findChild"/>
420 <rejection class="QObject" function-name="findChild"/>
421 <rejection class="QObject" function-name="findChildren"/>
421 <rejection class="QObject" function-name="findChildren"/>
422 <rejection class="QObject" function-name="setUserData"/>
422 <rejection class="QObject" function-name="setUserData"/>
423 <rejection class="QObject" function-name="userData"/>
423 <rejection class="QObject" function-name="userData"/>
424 <rejection class="QObject" function-name="destroyed"/>
424 <rejection class="QObject" function-name="destroyed"/>
425 <rejection class="QObject" function-name="connect"/>
425 <rejection class="QObject" function-name="connect"/>
426 <rejection class="QObject" function-name="connectNotify"/>
426 <rejection class="QObject" function-name="connectNotify"/>
427 <rejection class="QObject" function-name="disconnect"/>
427 <rejection class="QObject" function-name="disconnect"/>
428 <rejection class="QObject" function-name="disconnectNotify"/>
428 <rejection class="QObject" function-name="disconnectNotify"/>
429 <rejection class="QObject" function-name="registerUserData"/>
429 <rejection class="QObject" function-name="registerUserData"/>
430 <rejection class="QObject" function-name="sender"/>
430 <rejection class="QObject" function-name="sender"/>
431 <rejection class="QObject" function-name="moveToThread"/>
431 <rejection class="QObject" function-name="moveToThread"/>
432 <rejection class="QObject" function-name="thread"/>
432 <rejection class="QObject" function-name="thread"/>
433 <rejection class="QTimer" function-name="singleShot"/>
433 <rejection class="QTimer" function-name="singleShot"/>
434 <rejection class="QProcess" function-name="pid"/>
434 <rejection class="QProcess" function-name="pid"/>
435 <rejection class="QRegion" function-name="cleanUp"/>
435 <rejection class="QRegion" function-name="cleanUp"/>
436 <rejection class="QSettings" function-name="registerFormat"/>
436 <rejection class="QSettings" function-name="registerFormat"/>
437 <rejection class="QVector" function-name="back"/>
437 <rejection class="QVector" function-name="back"/>
438 <rejection class="QVector" function-name="begin"/>
438 <rejection class="QVector" function-name="begin"/>
439 <rejection class="QVector" function-name="constBegin"/>
439 <rejection class="QVector" function-name="constBegin"/>
440 <rejection class="QVector" function-name="constEnd"/>
440 <rejection class="QVector" function-name="constEnd"/>
441 <rejection class="QVector" function-name="end"/>
441 <rejection class="QVector" function-name="end"/>
442 <rejection class="QVector" function-name="erase"/>
442 <rejection class="QVector" function-name="erase"/>
443 <rejection class="QVector" function-name="free"/>
443 <rejection class="QVector" function-name="free"/>
444 <rejection class="QVector" function-name="front"/>
444 <rejection class="QVector" function-name="front"/>
445 <rejection class="QVector" function-name="insert"/>
445 <rejection class="QVector" function-name="insert"/>
446 <rejection class="QVector" function-name="malloc"/>
446 <rejection class="QVector" function-name="malloc"/>
447 <rejection class="QVector" function-name="alloc"/>
447 <rejection class="QVector" function-name="alloc"/>
448 <rejection class="QVector" function-name="operator+="/>
448 <rejection class="QVector" function-name="operator+="/>
449 <rejection class="QAbstractFileEngineIterator" function-name="entryInfo"/>
449 <rejection class="QAbstractFileEngineIterator" function-name="entryInfo"/>
450 <rejection class="QtConcurrent::ThreadEngineBarrier"/>
450 <rejection class="QtConcurrent::ThreadEngineBarrier"/>
451
451
452 <rejection class="QAbstractFileEngineIterator" enum-name="EntryInfoType"/>
452 <rejection class="QAbstractFileEngineIterator" enum-name="EntryInfoType"/>
453 <rejection class="QDataStream"/>
453 <rejection class="QDataStream"/>
454 <rejection class="QDataStream" enum-name="ByteOrder"/>
454 <rejection class="QDataStream" enum-name="ByteOrder"/>
455
455
456
456
457 <namespace-type name="Qt">
457 <namespace-type name="Qt">
458 <modify-function signature="codecForHtml(const QByteArray &amp;)" remove="all"/>
458 <modify-function signature="codecForHtml(const QByteArray &amp;)" remove="all"/>
459 <modify-function signature="mightBeRichText(const QString &amp;)" remove="all"/>
459 <modify-function signature="mightBeRichText(const QString &amp;)" remove="all"/>
460 <modify-function signature="escape(const QString&amp;)" remove="all"/>
460 <modify-function signature="escape(const QString&amp;)" remove="all"/>
461 <modify-function signature="convertFromPlainText(const QString &amp;, Qt::WhiteSpaceMode)" remove="all"/>
461 <modify-function signature="convertFromPlainText(const QString &amp;, Qt::WhiteSpaceMode)" remove="all"/>
462 <extra-includes>
462 <extra-includes>
463 <include file-name="QGesture" location="global"/>
463 <include file-name="QGesture" location="global"/>
464 </extra-includes>
464 </extra-includes>
465
465
466 <extra-includes>
466 <extra-includes>
467 <include file-name="QTextDocument" location="global"/>
467 <include file-name="QTextDocument" location="global"/>
468 </extra-includes>
468 </extra-includes>
469 </namespace-type>
469 </namespace-type>
470
470
471 <enum-type name="QDate::MonthNameType"/>
471 <enum-type name="QDate::MonthNameType"/>
472 <enum-type name="QAbstractAnimation::DeletionPolicy"/>
472 <enum-type name="QAbstractAnimation::DeletionPolicy"/>
473 <enum-type name="QAbstractAnimation::Direction"/>
473 <enum-type name="QAbstractAnimation::Direction"/>
474 <enum-type name="QAbstractAnimation::State"/>
474 <enum-type name="QAbstractAnimation::State"/>
475 <enum-type name="QDataStream::FloatingPointPrecision"/>
475 <enum-type name="QDataStream::FloatingPointPrecision"/>
476 <enum-type name="QEasingCurve::Type"/>
476 <enum-type name="QEasingCurve::Type"/>
477 <enum-type name="QHistoryState::HistoryType"/>
477 <enum-type name="QHistoryState::HistoryType"/>
478 <enum-type name="QState::ChildMode"/>
478 <enum-type name="QState::ChildMode"/>
479 <enum-type name="QStateMachine::Error"/>
479 <enum-type name="QStateMachine::Error"/>
480 <enum-type name="QStateMachine::EventPriority"/>
480 <enum-type name="QStateMachine::EventPriority"/>
481 <enum-type name="QStateMachine::RestorePolicy"/>
481 <enum-type name="QStateMachine::RestorePolicy"/>
482 <enum-type name="Qt::AnchorPoint"/>
482 <enum-type name="Qt::AnchorPoint"/>
483 <enum-type name="Qt::CoordinateSystem"/>
483 <enum-type name="Qt::CoordinateSystem"/>
484 <enum-type name="Qt::GestureFlag" flags="Qt::GestureFlags"/>
484 <enum-type name="Qt::GestureFlag" flags="Qt::GestureFlags"/>
485 <enum-type name="Qt::GestureState"/>
485 <enum-type name="Qt::GestureState"/>
486 <enum-type name="Qt::GestureType"/>
486 <enum-type name="Qt::GestureType"/>
487 <enum-type name="Qt::InputMethodHint" flags="Qt::InputMethodHints"/>
487 <enum-type name="Qt::InputMethodHint" flags="Qt::InputMethodHints"/>
488 <enum-type name="Qt::NavigationMode"/>
488 <enum-type name="Qt::NavigationMode"/>
489 <enum-type name="Qt::RenderHint"/>
489 <enum-type name="Qt::RenderHint"/>
490 <enum-type name="Qt::TileRule"/>
490 <enum-type name="Qt::TileRule"/>
491 <enum-type name="Qt::TouchPointState" flags="Qt::TouchPointStates"/>
491 <enum-type name="Qt::TouchPointState" flags="Qt::TouchPointStates"/>
492
492
493 <enum-type name="QtMsgType">
493 <enum-type name="QtMsgType">
494 <reject-enum-value name="QtSystemMsg"/>
494 <reject-enum-value name="QtSystemMsg"/>
495 </enum-type>
495 </enum-type>
496
496
497
497
498 <enum-type name="QReadWriteLock::RecursionMode"/>
498 <enum-type name="QReadWriteLock::RecursionMode"/>
499 <enum-type name="QSystemSemaphore::AccessMode"/>
499 <enum-type name="QSystemSemaphore::AccessMode"/>
500 <enum-type name="QSystemSemaphore::SystemSemaphoreError"/>
500 <enum-type name="QSystemSemaphore::SystemSemaphoreError"/>
501 <enum-type name="QTextBoundaryFinder::BoundaryReason" flags="QTextBoundaryFinder::BoundaryReasons"/>
501 <enum-type name="QTextBoundaryFinder::BoundaryReason" flags="QTextBoundaryFinder::BoundaryReasons"/>
502 <enum-type name="QTextBoundaryFinder::BoundaryType"/>
502 <enum-type name="QTextBoundaryFinder::BoundaryType"/>
503 <enum-type name="QAbstractFileEngine::Extension" extensible="yes"/>
503 <enum-type name="QAbstractFileEngine::Extension" extensible="yes"/>
504 <enum-type name="QAbstractFileEngine::FileFlag" flags="QAbstractFileEngine::FileFlags"/>
504 <enum-type name="QAbstractFileEngine::FileFlag" flags="QAbstractFileEngine::FileFlags"/>
505 <enum-type name="QAbstractFileEngine::FileName"/>
505 <enum-type name="QAbstractFileEngine::FileName"/>
506 <enum-type name="QAbstractFileEngine::FileOwner"/>
506 <enum-type name="QAbstractFileEngine::FileOwner"/>
507 <enum-type name="QAbstractFileEngine::FileTime"/>
507 <enum-type name="QAbstractFileEngine::FileTime"/>
508 <enum-type name="QDataStream::Status"/>
508 <enum-type name="QDataStream::Status"/>
509 <enum-type name="QDir::Filter" flags="QDir::Filters"/>
509 <enum-type name="QDir::Filter" flags="QDir::Filters"/>
510 <enum-type name="QEvent::Type" extensible="yes">
510 <enum-type name="QEvent::Type" extensible="yes">
511 <reject-enum-value name="ApplicationActivated"/>
511 <reject-enum-value name="ApplicationActivated"/>
512 <reject-enum-value name="ApplicationDeactivated"/>
512 <reject-enum-value name="ApplicationDeactivated"/>
513 </enum-type>
513 </enum-type>
514 <enum-type name="QEventLoop::ProcessEventsFlag" flags="QEventLoop::ProcessEventsFlags"/>
514 <enum-type name="QEventLoop::ProcessEventsFlag" flags="QEventLoop::ProcessEventsFlags"/>
515 <enum-type name="QFile::FileHandleFlag"/>
515 <enum-type name="QFile::FileHandleFlag"/>
516 <enum-type name="QFile::FileError"/>
516 <enum-type name="QFile::FileError"/>
517 <enum-type name="QFile::MemoryMapFlags"/>
517 <enum-type name="QFile::MemoryMapFlags"/>
518 <enum-type name="QFile::Permission" flags="QFile::Permissions"/>
518 <enum-type name="QFile::Permission" flags="QFile::Permissions"/>
519 <enum-type name="QIODevice::OpenModeFlag" flags="QIODevice::OpenMode"/>
519 <enum-type name="QIODevice::OpenModeFlag" flags="QIODevice::OpenMode"/>
520 <enum-type name="QLibraryInfo::LibraryLocation"/>
520 <enum-type name="QLibraryInfo::LibraryLocation"/>
521 <enum-type name="QLocale::FormatType"/>
521 <enum-type name="QLocale::FormatType"/>
522 <enum-type name="QLocale::QuotationStyle"/>
522 <enum-type name="QLocale::QuotationStyle"/>
523 <enum-type name="QLocale::CurrencySymbolFormat"/>
523 <enum-type name="QLocale::CurrencySymbolFormat"/>
524 <enum-type name="QLocale::Script"/>
524 <enum-type name="QLocale::Script"/>
525 <enum-type name="QLocale::NumberOption" flags="QLocale::NumberOptions"/>
525 <enum-type name="QLocale::NumberOption" flags="QLocale::NumberOptions"/>
526 <enum-type name="QLocale::MeasurementSystem"/>
526 <enum-type name="QLocale::MeasurementSystem"/>
527 <enum-type name="QMutex::RecursionMode"/>
527 <enum-type name="QMutex::RecursionMode"/>
528 <enum-type name="QProcess::ExitStatus"/>
528 <enum-type name="QProcess::ExitStatus"/>
529 <enum-type name="QProcess::ProcessChannel"/>
529 <enum-type name="QProcess::ProcessChannel"/>
530 <enum-type name="QProcess::ProcessChannelMode"/>
530 <enum-type name="QProcess::ProcessChannelMode"/>
531 <enum-type name="QProcess::ProcessError"/>
531 <enum-type name="QProcess::ProcessError"/>
532 <enum-type name="QProcess::ProcessState"/>
532 <enum-type name="QProcess::ProcessState"/>
533 <enum-type name="QRegExp::CaretMode"/>
533 <enum-type name="QRegExp::CaretMode"/>
534 <enum-type name="QRegExp::PatternSyntax"/>
534 <enum-type name="QRegExp::PatternSyntax"/>
535 <enum-type name="QSettings::Format"/>
535 <enum-type name="QSettings::Format"/>
536 <enum-type name="QSettings::Scope"/>
536 <enum-type name="QSettings::Scope"/>
537 <enum-type name="QSettings::Status"/>
537 <enum-type name="QSettings::Status"/>
538 <enum-type name="QSocketNotifier::Type"/>
538 <enum-type name="QSocketNotifier::Type"/>
539 <enum-type name="QSystemLocale::QueryType"/>
539 <enum-type name="QSystemLocale::QueryType"/>
540 <enum-type name="QTextCodec::ConversionFlag" flags="QTextCodec::ConversionFlags"/>
540 <enum-type name="QTextCodec::ConversionFlag" flags="QTextCodec::ConversionFlags"/>
541 <enum-type name="QTextStream::FieldAlignment"/>
541 <enum-type name="QTextStream::FieldAlignment"/>
542 <enum-type name="QTextStream::NumberFlag" flags="QTextStream::NumberFlags"/>
542 <enum-type name="QTextStream::NumberFlag" flags="QTextStream::NumberFlags"/>
543 <enum-type name="QTextStream::RealNumberNotation"/>
543 <enum-type name="QTextStream::RealNumberNotation"/>
544 <enum-type name="QTextStream::Status"/>
544 <enum-type name="QTextStream::Status"/>
545 <enum-type name="QTimeLine::CurveShape"/>
545 <enum-type name="QTimeLine::CurveShape"/>
546 <enum-type name="QTimeLine::Direction"/>
546 <enum-type name="QTimeLine::Direction"/>
547 <enum-type name="QTimeLine::State"/>
547 <enum-type name="QTimeLine::State"/>
548 <enum-type name="QUrl::ParsingMode"/>
548 <enum-type name="QUrl::ParsingMode"/>
549 <enum-type name="QUuid::Variant"/>
549 <enum-type name="QUuid::Variant"/>
550 <enum-type name="QUuid::Version"/>
550 <enum-type name="QUuid::Version"/>
551 <enum-type name="Qt::SizeHint"/>
551 <enum-type name="Qt::SizeHint"/>
552 <enum-type name="Qt::TimerType"/>
552 <enum-type name="Qt::TimerType"/>
553 <enum-type name="Qt::CursorMoveStyle"/>
553 <enum-type name="Qt::CursorMoveStyle"/>
554 <enum-type name="Qt::FindChildOption"/>
554 <enum-type name="Qt::FindChildOption"/>
555 <enum-type name="Qt::ScreenOrientation"/>
555 <enum-type name="Qt::ScreenOrientation"/>
556 <enum-type name="Qt::SizeMode"/>
556 <enum-type name="Qt::SizeMode"/>
557 <enum-type name="Qt::WindowFrameSection"/>
557 <enum-type name="Qt::WindowFrameSection"/>
558 <enum-type name="Qt::Axis"/>
558 <enum-type name="Qt::Axis"/>
559 <enum-type name="Qt::AnchorAttribute"/>
559 <enum-type name="Qt::AnchorAttribute"/>
560 <enum-type name="Qt::ApplicationAttribute"/>
560 <enum-type name="Qt::ApplicationAttribute"/>
561 <enum-type name="Qt::ArrowType"/>
561 <enum-type name="Qt::ArrowType"/>
562 <enum-type name="Qt::AspectRatioMode"/>
562 <enum-type name="Qt::AspectRatioMode"/>
563 <enum-type name="Qt::BGMode"/>
563 <enum-type name="Qt::BGMode"/>
564 <enum-type name="Qt::BrushStyle"/>
564 <enum-type name="Qt::BrushStyle"/>
565 <enum-type name="Qt::CaseSensitivity"/>
565 <enum-type name="Qt::CaseSensitivity"/>
566 <enum-type name="Qt::CheckState"/>
566 <enum-type name="Qt::CheckState"/>
567 <enum-type name="Qt::ClipOperation"/>
567 <enum-type name="Qt::ClipOperation"/>
568 <enum-type name="Qt::ConnectionType"/>
568 <enum-type name="Qt::ConnectionType"/>
569 <enum-type name="Qt::ContextMenuPolicy"/>
569 <enum-type name="Qt::ContextMenuPolicy"/>
570 <enum-type name="Qt::Corner"/>
570 <enum-type name="Qt::Corner"/>
571 <enum-type name="Qt::DayOfWeek"/>
571 <enum-type name="Qt::DayOfWeek"/>
572 <enum-type name="Qt::DockWidgetAreaSizes"/>
572 <enum-type name="Qt::DockWidgetAreaSizes"/>
573 <enum-type name="Qt::DropAction" flags="Qt::DropActions"/>
573 <enum-type name="Qt::DropAction" flags="Qt::DropActions"/>
574 <enum-type name="Qt::FillRule"/>
574 <enum-type name="Qt::FillRule"/>
575 <enum-type name="Qt::FocusPolicy"/>
575 <enum-type name="Qt::FocusPolicy"/>
576 <enum-type name="Qt::FocusReason"/>
576 <enum-type name="Qt::FocusReason"/>
577 <enum-type name="Qt::GlobalColor"/>
577 <enum-type name="Qt::GlobalColor"/>
578 <enum-type name="Qt::HitTestAccuracy"/>
578 <enum-type name="Qt::HitTestAccuracy"/>
579 <enum-type name="Qt::InputMethodQuery"/>
579 <enum-type name="Qt::InputMethodQuery"/>
580 <enum-type name="Qt::ItemFlag" flags="Qt::ItemFlags"/>
580 <enum-type name="Qt::ItemFlag" flags="Qt::ItemFlags"/>
581 <enum-type name="Qt::ItemSelectionMode"/>
581 <enum-type name="Qt::ItemSelectionMode"/>
582 <enum-type name="Qt::KeyboardModifier" flags="Qt::KeyboardModifiers"/>
582 <enum-type name="Qt::KeyboardModifier" flags="Qt::KeyboardModifiers"/>
583 <enum-type name="Qt::LayoutDirection"/>
583 <enum-type name="Qt::LayoutDirection"/>
584 <enum-type name="Qt::MatchFlag" flags="Qt::MatchFlags"/>
584 <enum-type name="Qt::MatchFlag" flags="Qt::MatchFlags"/>
585 <enum-type name="Qt::Modifier"/>
585 <enum-type name="Qt::Modifier"/>
586 <enum-type name="Qt::MouseButton" flags="Qt::MouseButtons"/>
586 <enum-type name="Qt::MouseButton" flags="Qt::MouseButtons"/>
587 <enum-type name="Qt::Orientation" flags="Qt::Orientations"/>
587 <enum-type name="Qt::Orientation" flags="Qt::Orientations"/>
588 <enum-type name="Qt::PenCapStyle"/>
588 <enum-type name="Qt::PenCapStyle"/>
589 <enum-type name="Qt::PenJoinStyle"/>
589 <enum-type name="Qt::PenJoinStyle"/>
590 <enum-type name="Qt::PenStyle"/>
590 <enum-type name="Qt::PenStyle"/>
591 <enum-type name="Qt::ScrollBarPolicy"/>
591 <enum-type name="Qt::ScrollBarPolicy"/>
592 <enum-type name="Qt::ShortcutContext"/>
592 <enum-type name="Qt::ShortcutContext"/>
593 <enum-type name="Qt::SortOrder"/>
593 <enum-type name="Qt::SortOrder"/>
594 <enum-type name="Qt::TextElideMode"/>
594 <enum-type name="Qt::TextElideMode"/>
595 <enum-type name="Qt::TextFlag"/>
595 <enum-type name="Qt::TextFlag"/>
596 <enum-type name="Qt::TextFormat"/>
596 <enum-type name="Qt::TextFormat"/>
597 <enum-type name="Qt::TextInteractionFlag" flags="Qt::TextInteractionFlags"/>
597 <enum-type name="Qt::TextInteractionFlag" flags="Qt::TextInteractionFlags"/>
598 <enum-type name="Qt::TimeSpec"/>
598 <enum-type name="Qt::TimeSpec"/>
599 <enum-type name="Qt::ToolBarAreaSizes"/>
599 <enum-type name="Qt::ToolBarAreaSizes"/>
600 <enum-type name="Qt::ToolButtonStyle"/>
600 <enum-type name="Qt::ToolButtonStyle"/>
601 <enum-type name="Qt::TransformationMode"/>
601 <enum-type name="Qt::TransformationMode"/>
602 <enum-type name="Qt::UIEffect"/>
602 <enum-type name="Qt::UIEffect"/>
603 <enum-type name="Qt::WhiteSpaceMode"/>
603 <enum-type name="Qt::WhiteSpaceMode"/>
604 <enum-type name="Qt::WindowModality"/>
604 <enum-type name="Qt::WindowModality"/>
605 <enum-type name="Qt::WindowState" flags="Qt::WindowStates"/>
605 <enum-type name="Qt::WindowState" flags="Qt::WindowStates"/>
606 <enum-type name="Qt::WindowType" flags="Qt::WindowFlags"/>
606 <enum-type name="Qt::WindowType" flags="Qt::WindowFlags"/>
607 <enum-type name="QDirIterator::IteratorFlag" flags="QDirIterator::IteratorFlags"/>
607 <enum-type name="QDirIterator::IteratorFlag" flags="QDirIterator::IteratorFlags"/>
608 <enum-type name="Qt::EventPriority"/>
608 <enum-type name="Qt::EventPriority"/>
609 <enum-type name="Qt::MaskMode"/>
609 <enum-type name="Qt::MaskMode"/>
610 <enum-type name="QCryptographicHash::Algorithm"/>
610 <enum-type name="QCryptographicHash::Algorithm"/>
611
611
612 <enum-type name="QtConcurrent::ReduceOption" flags="QtConcurrent::ReduceOptions"/>
612 <enum-type name="QtConcurrent::ReduceOption" flags="QtConcurrent::ReduceOptions"/>
613 <enum-type name="QtConcurrent::ThreadFunctionResult"/>
613 <enum-type name="QtConcurrent::ThreadFunctionResult"/>
614
614
615
615
616 <enum-type name="QCoreApplication::Encoding">
616 <enum-type name="QCoreApplication::Encoding">
617 <reject-enum-value name="DefaultCodec"/>
617 <reject-enum-value name="DefaultCodec"/>
618 </enum-type>
618 </enum-type>
619
619
620 <enum-type name="Qt::AlignmentFlag" flags="Qt::Alignment">
620 <enum-type name="Qt::AlignmentFlag" flags="Qt::Alignment">
621 <reject-enum-value name="AlignLeading"/>
621 <reject-enum-value name="AlignLeading"/>
622 <reject-enum-value name="AlignTrailing"/>
622 <reject-enum-value name="AlignTrailing"/>
623 </enum-type>
623 </enum-type>
624
624
625 <enum-type name="Qt::CursorShape">
625 <enum-type name="Qt::CursorShape">
626 <reject-enum-value name="LastCursor"/>
626 <reject-enum-value name="LastCursor"/>
627 </enum-type>
627 </enum-type>
628
628
629 <enum-type name="Qt::DateFormat">
629 <enum-type name="Qt::DateFormat">
630 <reject-enum-value name="LocalDate"/>
630 <reject-enum-value name="LocalDate"/>
631 </enum-type>
631 </enum-type>
632
632
633
633
634 <enum-type name="Qt::ItemDataRole" force-integer="yes">
634 <enum-type name="Qt::ItemDataRole" force-integer="yes">
635 <reject-enum-value name="BackgroundColorRole"/>
635 <reject-enum-value name="BackgroundColorRole"/>
636 <reject-enum-value name="TextColorRole"/>
636 <reject-enum-value name="TextColorRole"/>
637 </enum-type>
637 </enum-type>
638
638
639
639
640 <enum-type name="QDataStream::Version">
640 <enum-type name="QDataStream::Version">
641 <reject-enum-value name="Qt_4_1"/>
641 <reject-enum-value name="Qt_4_1"/>
642 <reject-enum-value name="Qt_4_5"/>
642 <reject-enum-value name="Qt_4_5"/>
643 <reject-enum-value name="Qt_4_6"/>
643 <reject-enum-value name="Qt_4_6"/>
644 </enum-type>
644 </enum-type>
645
645
646 <enum-type name="QDir::SortFlag" flags="QDir::SortFlags">
646 <enum-type name="QDir::SortFlag" flags="QDir::SortFlags">
647 <reject-enum-value name="Unsorted"/>
647 <reject-enum-value name="Unsorted"/>
648 </enum-type>
648 </enum-type>
649
649
650 <enum-type name="Qt::DockWidgetArea" flags="Qt::DockWidgetAreas">
650 <enum-type name="Qt::DockWidgetArea" flags="Qt::DockWidgetAreas">
651 <reject-enum-value name="AllDockWidgetAreas"/>
651 <reject-enum-value name="AllDockWidgetAreas"/>
652 </enum-type>
652 </enum-type>
653
653
654 <enum-type name="Qt::ImageConversionFlag" flags="Qt::ImageConversionFlags">
654 <enum-type name="Qt::ImageConversionFlag" flags="Qt::ImageConversionFlags">
655 <reject-enum-value name="AutoDither"/>
655 <reject-enum-value name="AutoDither"/>
656 <reject-enum-value name="ColorOnly"/>
656 <reject-enum-value name="ColorOnly"/>
657 <reject-enum-value name="DiffuseDither"/>
657 <reject-enum-value name="DiffuseDither"/>
658 <reject-enum-value name="NoAlpha"/>
658 <reject-enum-value name="NoAlpha"/>
659 <reject-enum-value name="ThresholdAlphaDither"/>
659 <reject-enum-value name="ThresholdAlphaDither"/>
660 </enum-type>
660 </enum-type>
661
661
662 <enum-type name="Qt::Key">
662 <enum-type name="Qt::Key">
663 <reject-enum-value name="Key_Any"/>
663 <reject-enum-value name="Key_Any"/>
664 </enum-type>
664 </enum-type>
665
665
666 <enum-type name="QLocale::Language">
666 <enum-type name="QLocale::Language">
667 <reject-enum-value name="LastLanguage"/>
667 <reject-enum-value name="LastLanguage"/>
668 <reject-enum-value name="NorwegianBokmal"/>
668 <reject-enum-value name="NorwegianBokmal"/>
669 <reject-enum-value name="Nynorsk"/>
669 <reject-enum-value name="Nynorsk"/>
670 </enum-type>
670 </enum-type>
671
671
672 <enum-type name="QLocale::Country">
672 <enum-type name="QLocale::Country">
673 <reject-enum-value name="LastCountry"/>
673 <reject-enum-value name="LastCountry"/>
674 </enum-type>
674 </enum-type>
675
675
676 <enum-type name="Qt::ToolBarArea" flags="Qt::ToolBarAreas">
676 <enum-type name="Qt::ToolBarArea" flags="Qt::ToolBarAreas">
677 <reject-enum-value name="AllToolBarAreas"/>
677 <reject-enum-value name="AllToolBarAreas"/>
678 </enum-type>
678 </enum-type>
679
679
680 <enum-type name="Qt::WidgetAttribute">
680 <enum-type name="Qt::WidgetAttribute">
681 <reject-enum-value name="WA_ForceAcceptDrops"/>
681 <reject-enum-value name="WA_ForceAcceptDrops"/>
682 <reject-enum-value name="WA_NoBackground"/>
682 <reject-enum-value name="WA_NoBackground"/>
683 <reject-enum-value name="WA_MacMetalStyle"/>
683 <reject-enum-value name="WA_MacMetalStyle"/>
684 </enum-type>
684 </enum-type>
685
685
686 <value-type name="QProcessEnvironment"/>
686 <value-type name="QProcessEnvironment"/>
687 <value-type name="QBasicTimer"/>
687 <value-type name="QBasicTimer"/>
688 <value-type name="QByteArrayMatcher">
688 <value-type name="QByteArrayMatcher">
689 <modify-function signature="operator=(QByteArrayMatcher)" remove="all"/>
689 <modify-function signature="operator=(QByteArrayMatcher)" remove="all"/>
690 </value-type>
690 </value-type>
691
691
692 <value-type name="QDate">
692 <value-type name="QDate">
693 <modify-function signature="julianToGregorian(uint,int&amp;,int&amp;,int&amp;)">
693 <modify-function signature="julianToGregorian(uint,int&amp;,int&amp;,int&amp;)">
694 <remove/>
694 <remove/>
695 </modify-function>
695 </modify-function>
696
696
697 <modify-function signature="setYMD(int, int, int)" remove="all"/>
697 <modify-function signature="setYMD(int, int, int)" remove="all"/>
698 <!--### Obsolete in 4.3-->
698 <!--### Obsolete in 4.3-->
699 </value-type>
699 </value-type>
700
700
701 <value-type name="QDateTime">
701 <value-type name="QDateTime">
702 <modify-function signature="operator=(QDateTime)" remove="all"/>
702 <modify-function signature="operator=(QDateTime)" remove="all"/>
703 </value-type>
703 </value-type>
704
704
705 <value-type name="QDir">
705 <value-type name="QDir">
706 <modify-function signature="QDir(QString,QString,QFlags&lt;QDir::SortFlag&gt;,QFlags&lt;QDir::Filter&gt;)">
706 <modify-function signature="QDir(QString,QString,QFlags&lt;QDir::SortFlag&gt;,QFlags&lt;QDir::Filter&gt;)">
707 <modify-argument index="3">
707 <modify-argument index="3">
708 <replace-default-expression with="SortFlag.Name, SortFlag.IgnoreCase"/>
708 <replace-default-expression with="SortFlag.Name, SortFlag.IgnoreCase"/>
709 </modify-argument>
709 </modify-argument>
710 </modify-function>
710 </modify-function>
711 <modify-function signature="operator=(QDir)" remove="all"/>
711 <modify-function signature="operator=(QDir)" remove="all"/>
712 <modify-function signature="operator=(QString)" remove="all"/>
712 <modify-function signature="operator=(QString)" remove="all"/>
713 <modify-function signature="addResourceSearchPath(QString)" remove="all"/>
713 <modify-function signature="addResourceSearchPath(QString)" remove="all"/>
714 <!--### Obsolete in 4.3-->
714 <!--### Obsolete in 4.3-->
715 </value-type>
715 </value-type>
716
716
717 <value-type name="QPoint">
717 <value-type name="QPoint">
718 <modify-function signature="rx()" remove="all"/>
718 <modify-function signature="rx()" remove="all"/>
719 <modify-function signature="ry()" remove="all"/>
719 <modify-function signature="ry()" remove="all"/>
720 </value-type>
720 </value-type>
721 <value-type name="QPointF">
721 <value-type name="QPointF">
722 <modify-function signature="rx()" remove="all"/>
722 <modify-function signature="rx()" remove="all"/>
723 <modify-function signature="ry()" remove="all"/>
723 <modify-function signature="ry()" remove="all"/>
724 </value-type>
724 </value-type>
725
725
726 <value-type name="QRect">
726 <value-type name="QRect">
727 <modify-function signature="getCoords(int*,int*,int*,int*)const">
727 <modify-function signature="getCoords(int*,int*,int*,int*)const">
728 <remove/>
728 <remove/>
729 </modify-function>
729 </modify-function>
730 <modify-function signature="getRect(int*,int*,int*,int*)const">
730 <modify-function signature="getRect(int*,int*,int*,int*)const">
731 <remove/>
731 <remove/>
732 </modify-function>
732 </modify-function>
733 <modify-function signature="operator&amp;=(QRect)">
733 <modify-function signature="operator&amp;=(QRect)">
734 <remove/>
734 <remove/>
735 </modify-function>
735 </modify-function>
736 <modify-function signature="operator|=(QRect)">
736 <modify-function signature="operator|=(QRect)">
737 <remove/>
737 <remove/>
738 </modify-function>
738 </modify-function>
739 <modify-function signature="operator&amp;(QRect)const">
739 <modify-function signature="operator&amp;(QRect)const">
740 <remove/>
740 <remove/>
741 </modify-function>
741 </modify-function>
742 <modify-function signature="operator|(QRect)const">
742 <modify-function signature="operator|(QRect)const">
743 <remove/>
743 <remove/>
744 </modify-function>
744 </modify-function>
745
745
746 <modify-function signature="intersect(const QRect&amp;)const" remove="all"/>
746 <modify-function signature="intersect(const QRect&amp;)const" remove="all"/>
747 <!--### Obsolete in 4.3-->
747 <!--### Obsolete in 4.3-->
748 <modify-function signature="unite(const QRect&amp;)const" remove="all"/>
748 <modify-function signature="unite(const QRect&amp;)const" remove="all"/>
749 <!--### Obsolete in 4.3-->
749 <!--### Obsolete in 4.3-->
750 </value-type>
750 </value-type>
751
751
752 <value-type name="QRectF">
752 <value-type name="QRectF">
753 <modify-function signature="getCoords(qreal*,qreal*,qreal*,qreal*)const">
753 <modify-function signature="getCoords(qreal*,qreal*,qreal*,qreal*)const">
754 <remove/>
754 <remove/>
755 </modify-function>
755 </modify-function>
756 <modify-function signature="getRect(qreal*,qreal*,qreal*,qreal*)const">
756 <modify-function signature="getRect(qreal*,qreal*,qreal*,qreal*)const">
757 <remove/>
757 <remove/>
758 </modify-function>
758 </modify-function>
759 <modify-function signature="operator&amp;=(QRectF)">
759 <modify-function signature="operator&amp;=(QRectF)">
760 <remove/>
760 <remove/>
761 </modify-function>
761 </modify-function>
762 <modify-function signature="operator|=(QRectF)">
762 <modify-function signature="operator|=(QRectF)">
763 <remove/>
763 <remove/>
764 </modify-function>
764 </modify-function>
765 <modify-function signature="operator&amp;(QRectF)const">
765 <modify-function signature="operator&amp;(QRectF)const">
766 <remove/>
766 <remove/>
767 </modify-function>
767 </modify-function>
768 <modify-function signature="operator|(QRectF)const">
768 <modify-function signature="operator|(QRectF)const">
769 <remove/>
769 <remove/>
770 </modify-function>
770 </modify-function>
771
771
772 <modify-function signature="intersect(const QRectF&amp;)const" remove="all"/>
772 <modify-function signature="intersect(const QRectF&amp;)const" remove="all"/>
773 <!--### Obsolete in 4.3-->
773 <!--### Obsolete in 4.3-->
774 <modify-function signature="unite(const QRectF&amp;)const" remove="all"/>
774 <modify-function signature="unite(const QRectF&amp;)const" remove="all"/>
775 <!--### Obsolete in 4.3-->
775 <!--### Obsolete in 4.3-->
776 </value-type>
776 </value-type>
777
777
778
778
779 <value-type name="QSize">
779 <value-type name="QSize">
780 <modify-function signature="operator*=(qreal)">
780 <modify-function signature="operator*=(qreal)">
781 <access modifier="private"/>
781 <access modifier="private"/>
782 </modify-function>
782 </modify-function>
783 <modify-function signature="operator/=(qreal)">
783 <modify-function signature="operator/=(qreal)">
784 <access modifier="private"/>
784 <access modifier="private"/>
785 </modify-function>
785 </modify-function>
786 <modify-function signature="operator+=(QSize)">
786 <modify-function signature="operator+=(QSize)">
787 <access modifier="private"/>
787 <access modifier="private"/>
788 </modify-function>
788 </modify-function>
789 <modify-function signature="operator-=(QSize)">
789 <modify-function signature="operator-=(QSize)">
790 <access modifier="private"/>
790 <access modifier="private"/>
791 </modify-function>
791 </modify-function>
792 <modify-function signature="rheight()">
792 <modify-function signature="rheight()">
793 <remove/>
793 <remove/>
794 </modify-function>
794 </modify-function>
795 <modify-function signature="rwidth()">
795 <modify-function signature="rwidth()">
796 <remove/>
796 <remove/>
797 </modify-function>
797 </modify-function>
798 </value-type>
798 </value-type>
799
799
800 <value-type name="QSizeF">
800 <value-type name="QSizeF">
801 <modify-function signature="operator*=(qreal)">
801 <modify-function signature="operator*=(qreal)">
802 <access modifier="private"/>
802 <access modifier="private"/>
803 </modify-function>
803 </modify-function>
804 <modify-function signature="operator/=(qreal)">
804 <modify-function signature="operator/=(qreal)">
805 <access modifier="private"/>
805 <access modifier="private"/>
806 </modify-function>
806 </modify-function>
807 <modify-function signature="operator+=(QSizeF)">
807 <modify-function signature="operator+=(QSizeF)">
808 <access modifier="private"/>
808 <access modifier="private"/>
809 </modify-function>
809 </modify-function>
810 <modify-function signature="operator-=(QSizeF)">
810 <modify-function signature="operator-=(QSizeF)">
811 <access modifier="private"/>
811 <access modifier="private"/>
812 </modify-function>
812 </modify-function>
813 <modify-function signature="rheight()">
813 <modify-function signature="rheight()">
814 <remove/>
814 <remove/>
815 </modify-function>
815 </modify-function>
816 <modify-function signature="rwidth()">
816 <modify-function signature="rwidth()">
817 <remove/>
817 <remove/>
818 </modify-function>
818 </modify-function>
819 </value-type>
819 </value-type>
820
820
821 <value-type name="QStringMatcher">
821 <value-type name="QStringMatcher">
822 <modify-function signature="operator=(QStringMatcher)" remove="all"/>
822 <modify-function signature="operator=(QStringMatcher)" remove="all"/>
823 <modify-function signature="QStringMatcher(const QChar*,int,Qt::CaseSensitivity)" remove="all"/>
823 <modify-function signature="QStringMatcher(const QChar*,int,Qt::CaseSensitivity)" remove="all"/>
824 <modify-function signature="indexIn(const QChar*,int,int)const" remove="all"/>
824 <modify-function signature="indexIn(const QChar*,int,int)const" remove="all"/>
825 </value-type>
825 </value-type>
826
826
827 <value-type name="QTime"/>
827 <value-type name="QTime"/>
828
828
829 <value-type name="QPersistentModelIndex">
829 <value-type name="QPersistentModelIndex">
830 <modify-function signature="operator=(QPersistentModelIndex)" remove="all"/>
830 <modify-function signature="operator=(QPersistentModelIndex)" remove="all"/>
831 <modify-function signature="operator=(QModelIndex)" remove="all"/>
831 <modify-function signature="operator=(QModelIndex)" remove="all"/>
832 <modify-function signature="internalPointer()const" remove="all"/>
832 <modify-function signature="internalPointer()const" remove="all"/>
833 </value-type>
833 </value-type>
834
834
835 <value-type name="QUuid">
835 <value-type name="QUuid">
836 <modify-function signature="QUuid(const char*)">
836 <modify-function signature="QUuid(const char*)">
837 <remove/>
837 <remove/>
838 </modify-function>
838 </modify-function>
839 </value-type>
839 </value-type>
840
840
841 <value-type name="QLocale">
841 <value-type name="QLocale">
842 <modify-function signature="toString(qlonglong) const" remove="all"/>
842 <modify-function signature="toString(qlonglong) const" remove="all"/>
843 <modify-function signature="toString(ushort) const" remove="all"/>
843 <modify-function signature="toString(ushort) const" remove="all"/>
844 <modify-function signature="toString(unsigned int) const" remove="all"/>
844 <modify-function signature="toString(unsigned int) const" remove="all"/>
845 <modify-function signature="toUInt(QString,bool*,int)const" remove="all"/>
845 <modify-function signature="toUInt(QString,bool*,int)const" remove="all"/>
846 <modify-function signature="toULongLong(QString,bool*,int)const" remove="all"/>
846 <modify-function signature="toULongLong(QString,bool*,int)const" remove="all"/>
847 <modify-function signature="operator=(QLocale)" remove="all"/>
847 <modify-function signature="operator=(QLocale)" remove="all"/>
848
848
849 <extra-includes>
849 <extra-includes>
850 <include file-name="QDate" location="global"/>
850 <include file-name="QDate" location="global"/>
851 </extra-includes>
851 </extra-includes>
852
852
853 <inject-code class="native" position="beginning">
853 <inject-code class="native" position="beginning">
854 Q_DECLARE_METATYPE(QScriptValue)
854 Q_DECLARE_METATYPE(QScriptValue)
855 </inject-code>
855 </inject-code>
856
856
857 <modify-function signature="toDouble(QString,bool*)const">
857 <modify-function signature="toDouble(QString,bool*)const">
858 <modify-argument index="2">
858 <modify-argument index="2">
859 <remove-default-expression/>
859 <remove-default-expression/>
860 <remove-argument/>
860 <remove-argument/>
861 <conversion-rule class="native">
861 <conversion-rule class="native">
862 <insert-template name="core.prepare_removed_bool*_argument"/>
862 <insert-template name="core.prepare_removed_bool*_argument"/>
863 </conversion-rule>
863 </conversion-rule>
864 </modify-argument>
864 </modify-argument>
865 <modify-argument index="return">
865 <modify-argument index="return">
866 <conversion-rule class="native">
866 <conversion-rule class="native">
867 <insert-template name="core.convert_to_null_or_primitive"/>
867 <insert-template name="core.convert_to_null_or_primitive"/>
868 </conversion-rule>
868 </conversion-rule>
869 </modify-argument>
869 </modify-argument>
870 </modify-function>
870 </modify-function>
871
871
872 <modify-function signature="toFloat(QString,bool*)const">
872 <modify-function signature="toFloat(QString,bool*)const">
873 <modify-argument index="2">
873 <modify-argument index="2">
874 <remove-default-expression/>
874 <remove-default-expression/>
875 <remove-argument/>
875 <remove-argument/>
876 <conversion-rule class="native">
876 <conversion-rule class="native">
877 <insert-template name="core.prepare_removed_bool*_argument"/>
877 <insert-template name="core.prepare_removed_bool*_argument"/>
878 </conversion-rule>
878 </conversion-rule>
879 </modify-argument>
879 </modify-argument>
880 <modify-argument index="return">
880 <modify-argument index="return">
881 <conversion-rule class="native">
881 <conversion-rule class="native">
882 <insert-template name="core.convert_to_null_or_primitive"/>
882 <insert-template name="core.convert_to_null_or_primitive"/>
883 </conversion-rule>
883 </conversion-rule>
884 </modify-argument>
884 </modify-argument>
885 </modify-function>
885 </modify-function>
886
886
887 <modify-function signature="toInt(QString,bool*,int)const">
887 <modify-function signature="toInt(QString,bool*,int)const">
888 <modify-argument index="2">
888 <modify-argument index="2">
889 <remove-default-expression/>
889 <remove-default-expression/>
890 <remove-argument/>
890 <remove-argument/>
891 <conversion-rule class="native">
891 <conversion-rule class="native">
892 <insert-template name="core.prepare_removed_bool*_argument"/>
892 <insert-template name="core.prepare_removed_bool*_argument"/>
893 </conversion-rule>
893 </conversion-rule>
894 </modify-argument>
894 </modify-argument>
895 <modify-argument index="return">
895 <modify-argument index="return">
896 <conversion-rule class="native">
896 <conversion-rule class="native">
897 <insert-template name="core.convert_to_null_or_primitive"/>
897 <insert-template name="core.convert_to_null_or_primitive"/>
898 </conversion-rule>
898 </conversion-rule>
899 </modify-argument>
899 </modify-argument>
900 </modify-function>
900 </modify-function>
901
901
902 <modify-function signature="toLongLong(QString,bool*,int)const">
902 <modify-function signature="toLongLong(QString,bool*,int)const">
903 <modify-argument index="2">
903 <modify-argument index="2">
904 <remove-default-expression/>
904 <remove-default-expression/>
905 <remove-argument/>
905 <remove-argument/>
906 <conversion-rule class="native">
906 <conversion-rule class="native">
907 <insert-template name="core.prepare_removed_bool*_argument"/>
907 <insert-template name="core.prepare_removed_bool*_argument"/>
908 </conversion-rule>
908 </conversion-rule>
909 </modify-argument>
909 </modify-argument>
910 <modify-argument index="return">
910 <modify-argument index="return">
911 <conversion-rule class="native">
911 <conversion-rule class="native">
912 QScriptValue %out%;
912 QScriptValue %out%;
913 if (!__ok)
913 if (!__ok)
914 %out% = context-&gt;engine()-&gt;nullValue();
914 %out% = context-&gt;engine()-&gt;nullValue();
915 else
915 else
916 %out% = QScriptValue(context-&gt;engine(), double(%in%)).toObject();
916 %out% = QScriptValue(context-&gt;engine(), double(%in%)).toObject();
917 </conversion-rule>
917 </conversion-rule>
918 </modify-argument>
918 </modify-argument>
919 </modify-function>
919 </modify-function>
920
920
921 <modify-function signature="toShort(QString,bool*,int)const">
921 <modify-function signature="toShort(QString,bool*,int)const">
922 <modify-argument index="2">
922 <modify-argument index="2">
923 <remove-default-expression/>
923 <remove-default-expression/>
924 <remove-argument/>
924 <remove-argument/>
925 <conversion-rule class="native">
925 <conversion-rule class="native">
926 <insert-template name="core.prepare_removed_bool*_argument"/>
926 <insert-template name="core.prepare_removed_bool*_argument"/>
927 </conversion-rule>
927 </conversion-rule>
928 </modify-argument>
928 </modify-argument>
929 <modify-argument index="return">
929 <modify-argument index="return">
930 <conversion-rule class="native">
930 <conversion-rule class="native">
931 <insert-template name="core.convert_to_null_or_primitive"/>
931 <insert-template name="core.convert_to_null_or_primitive"/>
932 </conversion-rule>
932 </conversion-rule>
933 </modify-argument>
933 </modify-argument>
934 </modify-function>
934 </modify-function>
935
935
936 <modify-function signature="toUShort(QString,bool*,int)const">
936 <modify-function signature="toUShort(QString,bool*,int)const">
937 <modify-argument index="2">
937 <modify-argument index="2">
938 <remove-default-expression/>
938 <remove-default-expression/>
939 <remove-argument/>
939 <remove-argument/>
940 <conversion-rule class="native">
940 <conversion-rule class="native">
941 <insert-template name="core.prepare_removed_bool*_argument"/>
941 <insert-template name="core.prepare_removed_bool*_argument"/>
942 </conversion-rule>
942 </conversion-rule>
943 </modify-argument>
943 </modify-argument>
944 <modify-argument index="return">
944 <modify-argument index="return">
945 <conversion-rule class="native">
945 <conversion-rule class="native">
946 <insert-template name="core.convert_to_null_or_primitive"/>
946 <insert-template name="core.convert_to_null_or_primitive"/>
947 </conversion-rule>
947 </conversion-rule>
948 </modify-argument>
948 </modify-argument>
949 </modify-function>
949 </modify-function>
950 </value-type>
950 </value-type>
951
951
952
952
953 <value-type name="QBitArray">
953 <value-type name="QBitArray">
954 <modify-function signature="operator[](int)" remove="all"/>
954 <modify-function signature="operator[](int)" remove="all"/>
955 <modify-function signature="operator[](int)const" remove="all"/>
955 <modify-function signature="operator[](int)const" remove="all"/>
956 <modify-function signature="operator[](uint)const" remove="all"/>
956 <modify-function signature="operator[](uint)const" remove="all"/>
957 <modify-function signature="operator[](uint)" remove="all"/>
957 <modify-function signature="operator[](uint)" remove="all"/>
958
958
959 <modify-function signature="operator&amp;=(QBitArray)" access="private"/>
959 <modify-function signature="operator&amp;=(QBitArray)" access="private"/>
960 <modify-function signature="operator=(QBitArray)" access="private"/>
960 <modify-function signature="operator=(QBitArray)" access="private"/>
961 <modify-function signature="operator^=(QBitArray)" access="private"/>
961 <modify-function signature="operator^=(QBitArray)" access="private"/>
962 <modify-function signature="operator|=(QBitArray)" access="private"/>
962 <modify-function signature="operator|=(QBitArray)" access="private"/>
963 <modify-function signature="operator~()const" access="private"/>
963 <modify-function signature="operator~()const" access="private"/>
964
964
965 <modify-function signature="at(int)const">
965 <modify-function signature="at(int)const">
966 <modify-argument index="1">
966 <modify-argument index="1">
967 <conversion-rule class="native">
967 <conversion-rule class="native">
968 <insert-template name="core.convert_int_arg_and_check_range">
968 <insert-template name="core.convert_int_arg_and_check_range">
969 <replace from="%CLASS_NAME%" to="QBitArray"/>
969 <replace from="%CLASS_NAME%" to="QBitArray"/>
970 <replace from="%FUNCTION_NAME%" to="at"/>
970 <replace from="%FUNCTION_NAME%" to="at"/>
971 </insert-template>
971 </insert-template>
972 </conversion-rule>
972 </conversion-rule>
973 </modify-argument>
973 </modify-argument>
974 </modify-function>
974 </modify-function>
975
975
976 <modify-function signature="clearBit(int)">
976 <modify-function signature="clearBit(int)">
977 <modify-argument index="1">
977 <modify-argument index="1">
978 <conversion-rule class="native">
978 <conversion-rule class="native">
979 <insert-template name="core.convert_int_arg_and_check_range">
979 <insert-template name="core.convert_int_arg_and_check_range">
980 <replace from="%CLASS_NAME%" to="QBitArray"/>
980 <replace from="%CLASS_NAME%" to="QBitArray"/>
981 <replace from="%FUNCTION_NAME%" to="clearBit"/>
981 <replace from="%FUNCTION_NAME%" to="clearBit"/>
982 </insert-template>
982 </insert-template>
983 </conversion-rule>
983 </conversion-rule>
984 </modify-argument>
984 </modify-argument>
985 </modify-function>
985 </modify-function>
986
986
987 <modify-function signature="setBit(int)">
987 <modify-function signature="setBit(int)">
988 <modify-argument index="1">
988 <modify-argument index="1">
989 <conversion-rule class="native">
989 <conversion-rule class="native">
990 <insert-template name="core.convert_int_arg_and_check_range">
990 <insert-template name="core.convert_int_arg_and_check_range">
991 <replace from="%CLASS_NAME%" to="QBitArray"/>
991 <replace from="%CLASS_NAME%" to="QBitArray"/>
992 <replace from="%FUNCTION_NAME%" to="setBit"/>
992 <replace from="%FUNCTION_NAME%" to="setBit"/>
993 </insert-template>
993 </insert-template>
994 </conversion-rule>
994 </conversion-rule>
995 </modify-argument>
995 </modify-argument>
996 </modify-function>
996 </modify-function>
997
997
998 <modify-function signature="setBit(int,bool)">
998 <modify-function signature="setBit(int,bool)">
999 <modify-argument index="1">
999 <modify-argument index="1">
1000 <conversion-rule class="native">
1000 <conversion-rule class="native">
1001 <insert-template name="core.convert_int_arg_and_check_range">
1001 <insert-template name="core.convert_int_arg_and_check_range">
1002 <replace from="%CLASS_NAME%" to="QBitArray"/>
1002 <replace from="%CLASS_NAME%" to="QBitArray"/>
1003 <replace from="%FUNCTION_NAME%" to="setBit"/>
1003 <replace from="%FUNCTION_NAME%" to="setBit"/>
1004 </insert-template>
1004 </insert-template>
1005 </conversion-rule>
1005 </conversion-rule>
1006 </modify-argument>
1006 </modify-argument>
1007 </modify-function>
1007 </modify-function>
1008
1008
1009 <modify-function signature="testBit(int)const">
1009 <modify-function signature="testBit(int)const">
1010 <modify-argument index="1">
1010 <modify-argument index="1">
1011 <conversion-rule class="native">
1011 <conversion-rule class="native">
1012 <insert-template name="core.convert_int_arg_and_check_range">
1012 <insert-template name="core.convert_int_arg_and_check_range">
1013 <replace from="%CLASS_NAME%" to="QBitArray"/>
1013 <replace from="%CLASS_NAME%" to="QBitArray"/>
1014 <replace from="%FUNCTION_NAME%" to="testBit"/>
1014 <replace from="%FUNCTION_NAME%" to="testBit"/>
1015 </insert-template>
1015 </insert-template>
1016 </conversion-rule>
1016 </conversion-rule>
1017 </modify-argument>
1017 </modify-argument>
1018 </modify-function>
1018 </modify-function>
1019
1019
1020 <modify-function signature="toggleBit(int)">
1020 <modify-function signature="toggleBit(int)">
1021 <modify-argument index="1">
1021 <modify-argument index="1">
1022 <conversion-rule class="native">
1022 <conversion-rule class="native">
1023 <insert-template name="core.convert_int_arg_and_check_range">
1023 <insert-template name="core.convert_int_arg_and_check_range">
1024 <replace from="%CLASS_NAME%" to="QBitArray"/>
1024 <replace from="%CLASS_NAME%" to="QBitArray"/>
1025 <replace from="%FUNCTION_NAME%" to="toggleBit"/>
1025 <replace from="%FUNCTION_NAME%" to="toggleBit"/>
1026 </insert-template>
1026 </insert-template>
1027 </conversion-rule>
1027 </conversion-rule>
1028 </modify-argument>
1028 </modify-argument>
1029 </modify-function>
1029 </modify-function>
1030
1030
1031 <modify-function signature="operator&amp;=(QBitArray)">
1031 <modify-function signature="operator&amp;=(QBitArray)">
1032 <modify-argument index="0" replace-value="this"/>
1032 <modify-argument index="0" replace-value="this"/>
1033 </modify-function>
1033 </modify-function>
1034 <modify-function signature="operator=(QBitArray)">
1034 <modify-function signature="operator=(QBitArray)">
1035 <modify-argument index="0" replace-value="this"/>
1035 <modify-argument index="0" replace-value="this"/>
1036 </modify-function>
1036 </modify-function>
1037 <modify-function signature="operator^=(QBitArray)">
1037 <modify-function signature="operator^=(QBitArray)">
1038 <modify-argument index="0" replace-value="this"/>
1038 <modify-argument index="0" replace-value="this"/>
1039 </modify-function>
1039 </modify-function>
1040 <modify-function signature="operator|=(QBitArray)">
1040 <modify-function signature="operator|=(QBitArray)">
1041 <modify-argument index="0" replace-value="this"/>
1041 <modify-argument index="0" replace-value="this"/>
1042 </modify-function>
1042 </modify-function>
1043 </value-type>
1043 </value-type>
1044
1044
1045 <object-type name="QReadWriteLock"/>
1045 <object-type name="QReadWriteLock"/>
1046 <object-type name="QDirIterator"/>
1046 <object-type name="QDirIterator"/>
1047 <object-type name="QAbstractFileEngineIterator"/>
1047 <object-type name="QAbstractFileEngineIterator"/>
1048 <object-type name="QAbstractItemModel"/>
1048 <object-type name="QAbstractItemModel"/>
1049
1049
1050 <object-type name="QAbstractListModel">
1050 <object-type name="QAbstractListModel">
1051 <extra-includes>
1051 <extra-includes>
1052 <include file-name="QStringList" location="global"/>
1052 <include file-name="QStringList" location="global"/>
1053 <include file-name="QSize" location="global"/>
1053 <include file-name="QSize" location="global"/>
1054 </extra-includes>
1054 </extra-includes>
1055 </object-type>
1055 </object-type>
1056
1056
1057 <object-type name="QAbstractTableModel">
1057 <object-type name="QAbstractTableModel">
1058 <extra-includes>
1058 <extra-includes>
1059 <include file-name="QStringList" location="global"/>
1059 <include file-name="QStringList" location="global"/>
1060 <include file-name="QSize" location="global"/>
1060 <include file-name="QSize" location="global"/>
1061 </extra-includes>
1061 </extra-includes>
1062 </object-type>
1062 </object-type>
1063
1063
1064 <value-type name="QUrl">
1064 <value-type name="QUrl">
1065 <extra-includes>
1065 <extra-includes>
1066 <include file-name="QStringList" location="global"/>
1066 <include file-name="QStringList" location="global"/>
1067 </extra-includes>
1067 </extra-includes>
1068 <modify-function signature="operator=(QUrl)" remove="all"/>
1068 <modify-function signature="operator=(QUrl)" remove="all"/>
1069 <modify-function signature="operator=(QString)" remove="all"/>
1069 <modify-function signature="operator=(QString)" remove="all"/>
1070
1070
1071 <modify-function signature="fromPunycode(const QByteArray&amp;)" remove="all"/>
1071 <modify-function signature="fromPunycode(const QByteArray&amp;)" remove="all"/>
1072 <!--### Obsolete in 4.3-->
1072 <!--### Obsolete in 4.3-->
1073 <modify-function signature="toPunycode(const QString&amp;)" remove="all"/>
1073 <modify-function signature="toPunycode(const QString&amp;)" remove="all"/>
1074 <!--### Obsolete in 4.3-->
1074 <!--### Obsolete in 4.3-->
1075 </value-type>
1075 </value-type>
1076
1076
1077 <value-type name="QRegExp">
1077 <value-type name="QRegExp">
1078 <extra-includes>
1078 <extra-includes>
1079 <include file-name="QStringList" location="global"/>
1079 <include file-name="QStringList" location="global"/>
1080 </extra-includes>
1080 </extra-includes>
1081 <modify-function signature="operator=(QRegExp)" remove="all"/>
1081 <modify-function signature="operator=(QRegExp)" remove="all"/>
1082
1082
1083 <modify-function signature="cap(int)" remove="all"/>
1083 <modify-function signature="cap(int)" remove="all"/>
1084 <modify-function signature="capturedTexts()" remove="all"/>
1084 <modify-function signature="capturedTexts()" remove="all"/>
1085 <modify-function signature="pos(int)" remove="all"/>
1085 <modify-function signature="pos(int)" remove="all"/>
1086 <modify-function signature="errorString()" remove="all"/>
1086 <modify-function signature="errorString()" remove="all"/>
1087 </value-type>
1087 </value-type>
1088
1088
1089 <value-type name="QFileInfo">
1089 <value-type name="QFileInfo">
1090 <extra-includes>
1090 <extra-includes>
1091 <include file-name="QDateTime" location="global"/>
1091 <include file-name="QDateTime" location="global"/>
1092 <include file-name="QDir" location="global"/>
1092 <include file-name="QDir" location="global"/>
1093 </extra-includes>
1093 </extra-includes>
1094 <modify-function signature="operator!=(const QFileInfo &amp;)const" remove="all"/>
1094 <modify-function signature="operator!=(const QFileInfo &amp;)const" remove="all"/>
1095 <modify-function signature="operator==(const QFileInfo &amp;)const" remove="all"/>
1095 <modify-function signature="operator==(const QFileInfo &amp;)const" remove="all"/>
1096 <modify-function signature="operator=(QFileInfo)" remove="all"/>
1096 <modify-function signature="operator=(QFileInfo)" remove="all"/>
1097 <modify-function signature="setFile(QFile)">
1097 <modify-function signature="setFile(QFile)">
1098 <modify-argument index="1">
1098 <modify-argument index="1">
1099 <reference-count action="ignore"/>
1099 <reference-count action="ignore"/>
1100 </modify-argument>
1100 </modify-argument>
1101 </modify-function>
1101 </modify-function>
1102
1102
1103 <modify-function signature="readLink()const" remove="all"/>
1103 <modify-function signature="readLink()const" remove="all"/>
1104 <!--### Obsolete in 4.3-->
1104 <!--### Obsolete in 4.3-->
1105
1105
1106 <modify-function signature="QFileInfo(QFile)">
1106 <modify-function signature="QFileInfo(QFile)">
1107 <modify-argument index="1">
1107 <modify-argument index="1">
1108 <replace-type modified-type="QFile*"/>
1108 <replace-type modified-type="QFile*"/>
1109 <conversion-rule class="native">
1109 <conversion-rule class="native">
1110 QFile &amp; %out% = *qscriptvalue_cast&lt;QFile*&gt;(%in%);
1110 QFile &amp; %out% = *qscriptvalue_cast&lt;QFile*&gt;(%in%);
1111 </conversion-rule>
1111 </conversion-rule>
1112 </modify-argument>
1112 </modify-argument>
1113 </modify-function>
1113 </modify-function>
1114 <modify-function signature="setFile(QFile)">
1114 <modify-function signature="setFile(QFile)">
1115 <modify-argument index="1">
1115 <modify-argument index="1">
1116 <replace-type modified-type="QFile*"/>
1116 <replace-type modified-type="QFile*"/>
1117 <conversion-rule class="native">
1117 <conversion-rule class="native">
1118 QFile &amp; %out% = *qscriptvalue_cast&lt;QFile*&gt;(%in%);
1118 QFile &amp; %out% = *qscriptvalue_cast&lt;QFile*&gt;(%in%);
1119 </conversion-rule>
1119 </conversion-rule>
1120 </modify-argument>
1120 </modify-argument>
1121 </modify-function>
1121 </modify-function>
1122 </value-type>
1122 </value-type>
1123
1123
1124 <!-- <interface-type name="QFactoryInterface" java-name="QAbstractFactory" /> -->
1124 <!-- <interface-type name="QFactoryInterface" java-name="QAbstractFactory" /> -->
1125
1125
1126 <value-type name="QByteArray">
1126 <value-type name="QByteArray">
1127
1127
1128 <extra-includes>
1128 <extra-includes>
1129 <include file-name="QNoImplicitBoolCast" location="global"/>
1129 <include file-name="QNoImplicitBoolCast" location="global"/>
1130 </extra-includes>
1130 </extra-includes>
1131
1131
1132 <!-- removed functions -->
1132 <!-- removed functions -->
1133 <modify-function signature="begin()" remove="all"/>
1133 <modify-function signature="begin()" remove="all"/>
1134 <modify-function signature="begin()const" remove="all"/>
1134 <modify-function signature="begin()const" remove="all"/>
1135 <modify-function signature="constBegin()const" remove="all"/>
1135 <modify-function signature="constBegin()const" remove="all"/>
1136 <modify-function signature="constData()const" remove="all"/>
1136 <modify-function signature="constData()const" remove="all"/>
1137 <modify-function signature="constEnd()const" remove="all"/>
1137 <modify-function signature="constEnd()const" remove="all"/>
1138 <modify-function signature="count()const" remove="all"/>
1138 <modify-function signature="count()const" remove="all"/>
1139 <modify-function signature="data()const" remove="all"/>
1139 <modify-function signature="data()const" remove="all"/>
1140 <modify-function signature="end()" remove="all"/>
1140 <modify-function signature="end()" remove="all"/>
1141 <modify-function signature="end()const" remove="all"/>
1141 <modify-function signature="end()const" remove="all"/>
1142 <modify-function signature="number(uint,int)" remove="all"/>
1142 <modify-function signature="number(uint,int)" remove="all"/>
1143 <modify-function signature="number(qulonglong,int)" remove="all"/>
1143 <modify-function signature="number(qulonglong,int)" remove="all"/>
1144 <modify-function signature="operator const char *()const" remove="all"/>
1144 <modify-function signature="operator const char *()const" remove="all"/>
1145 <modify-function signature="operator const void *()const" remove="all"/>
1145 <modify-function signature="operator const void *()const" remove="all"/>
1146 <modify-function signature="operator+=(const char*)" remove="all"/>
1146 <modify-function signature="operator+=(const char*)" remove="all"/>
1147 <modify-function signature="operator=(const char*)" remove="all"/>
1147 <modify-function signature="operator=(const char*)" remove="all"/>
1148 <modify-function signature="operator[](int)" remove="all"/>
1148 <modify-function signature="operator[](int)" remove="all"/>
1149 <modify-function signature="operator[](int)const" remove="all"/>
1149 <modify-function signature="operator[](int)const" remove="all"/>
1150 <modify-function signature="operator[](uint)" remove="all"/>
1150 <modify-function signature="operator[](uint)" remove="all"/>
1151 <modify-function signature="operator[](uint)const" remove="all"/>
1151 <modify-function signature="operator[](uint)const" remove="all"/>
1152 <modify-function signature="push_back(char)" remove="all"/>
1152 <modify-function signature="push_back(char)" remove="all"/>
1153 <modify-function signature="push_back(const QByteArray&amp;)" remove="all"/>
1153 <modify-function signature="push_back(const QByteArray&amp;)" remove="all"/>
1154 <modify-function signature="push_back(const char*)" remove="all"/>
1154 <modify-function signature="push_back(const char*)" remove="all"/>
1155 <modify-function signature="push_front(char)" remove="all"/>
1155 <modify-function signature="push_front(char)" remove="all"/>
1156 <modify-function signature="push_front(const QByteArray&amp;)" remove="all"/>
1156 <modify-function signature="push_front(const QByteArray&amp;)" remove="all"/>
1157 <modify-function signature="push_front(const char*)" remove="all"/>
1157 <modify-function signature="push_front(const char*)" remove="all"/>
1158 <modify-function signature="setNum(uint,int)" remove="all"/>
1158 <modify-function signature="setNum(uint,int)" remove="all"/>
1159 <modify-function signature="setNum(qulonglong,int)" remove="all"/>
1159 <modify-function signature="setNum(qulonglong,int)" remove="all"/>
1160 <modify-function signature="setNum(ushort,int)" remove="all"/>
1160 <modify-function signature="setNum(ushort,int)" remove="all"/>
1161 <modify-function signature="toLong(bool*, int) const" remove="all"/>
1161 <modify-function signature="toLong(bool*, int) const" remove="all"/>
1162 <modify-function signature="toLongLong(bool*, int) const" remove="all"/>
1162 <modify-function signature="toLongLong(bool*, int) const" remove="all"/>
1163 <modify-function signature="toShort(bool*, int) const" remove="all"/>
1163 <modify-function signature="toShort(bool*, int) const" remove="all"/>
1164 <modify-function signature="toUInt(bool*, int) const" remove="all"/>
1164 <modify-function signature="toUInt(bool*, int) const" remove="all"/>
1165 <modify-function signature="toULong(bool*, int) const" remove="all"/>
1165 <modify-function signature="toULong(bool*, int) const" remove="all"/>
1166 <modify-function signature="toULongLong(bool*, int) const" remove="all"/>
1166 <modify-function signature="toULongLong(bool*, int) const" remove="all"/>
1167
1167
1168 <!-- functions made private... -->
1168 <!-- functions made private... -->
1169 <modify-function signature="operator=(QByteArray)" access="private"/>
1169 <modify-function signature="operator=(QByteArray)" access="private"/>
1170 <modify-function signature="operator+=(QByteArray)" remove="all"/>
1170 <modify-function signature="operator+=(QByteArray)" remove="all"/>
1171 <modify-function signature="operator+=(QString)" remove="all"/>
1171 <modify-function signature="operator+=(QString)" remove="all"/>
1172 <modify-function signature="operator+=(char)" remove="all"/>
1172 <modify-function signature="operator+=(char)" remove="all"/>
1173
1173
1174 <inject-code class="pywrap-h">
1174 <inject-code class="pywrap-h">
1175 PyObject* data(QByteArray* b) {
1175 PyObject* data(QByteArray* b) {
1176 if (b-&gt;data()) {
1176 if (b-&gt;data()) {
1177 return PyString_FromStringAndSize(b-&gt;data(), b-&gt;size());
1177 return PyString_FromStringAndSize(b-&gt;data(), b-&gt;size());
1178 } else {
1178 } else {
1179 Py_INCREF(Py_None);
1179 Py_INCREF(Py_None);
1180 return Py_None;
1180 return Py_None;
1181 }
1181 }
1182 }
1182 }
1183 </inject-code>
1183 </inject-code>
1184
1184
1185 <inject-code class="native" position="beginning">
1185 <inject-code class="native" position="beginning">
1186 Q_DECLARE_METATYPE(QScriptValue)
1186 Q_DECLARE_METATYPE(QScriptValue)
1187 </inject-code>
1187 </inject-code>
1188
1188
1189
1189
1190 <modify-function signature="QByteArray(const char*,int)" remove="all"/>
1190 <modify-function signature="QByteArray(const char*,int)" remove="all"/>
1191 <modify-function signature="QByteArray(const char*)" remove="all"/>
1191 <modify-function signature="QByteArray(const char*)" remove="all"/>
1192
1192
1193 <modify-function signature="at(int)const">
1193 <modify-function signature="at(int)const">
1194 <modify-argument index="1">
1194 <modify-argument index="1">
1195 <conversion-rule class="native">
1195 <conversion-rule class="native">
1196 <insert-template name="core.convert_int_arg_and_check_range">
1196 <insert-template name="core.convert_int_arg_and_check_range">
1197 <replace from="%CLASS_NAME%" to="QByteArray"/>
1197 <replace from="%CLASS_NAME%" to="QByteArray"/>
1198 <replace from="%FUNCTION_NAME%" to="at"/>
1198 <replace from="%FUNCTION_NAME%" to="at"/>
1199 </insert-template>
1199 </insert-template>
1200 </conversion-rule>
1200 </conversion-rule>
1201 </modify-argument>
1201 </modify-argument>
1202 </modify-function>
1202 </modify-function>
1203
1203
1204 <modify-function signature="append(const char *)" remove="all"/>
1204 <modify-function signature="append(const char *)" remove="all"/>
1205 <modify-function signature="append(QByteArray)">
1205 <modify-function signature="append(QByteArray)">
1206 <modify-argument index="0" replace-value="this"/>
1206 <modify-argument index="0" replace-value="this"/>
1207 </modify-function>
1207 </modify-function>
1208 <modify-function signature="append(QString)">
1208 <modify-function signature="append(QString)">
1209 <modify-argument index="0" replace-value="this"/>
1209 <modify-argument index="0" replace-value="this"/>
1210 </modify-function>
1210 </modify-function>
1211 <modify-function signature="append(const char *)" remove="all">
1211 <modify-function signature="append(const char *)" remove="all">
1212 <modify-argument index="0" replace-value="this"/>
1212 <modify-argument index="0" replace-value="this"/>
1213 </modify-function>
1213 </modify-function>
1214 <modify-function signature="append(char)">
1214 <modify-function signature="append(char)">
1215 <modify-argument index="0" replace-value="this"/>
1215 <modify-argument index="0" replace-value="this"/>
1216 <rename to="appendByte"/>
1216 <rename to="appendByte"/>
1217 </modify-function>
1217 </modify-function>
1218
1218
1219 <modify-function signature="count(const char *)const" remove="all"/>
1219 <modify-function signature="count(const char *)const" remove="all"/>
1220
1220
1221 <modify-function signature="data()" remove="all"/>
1221 <modify-function signature="data()" remove="all"/>
1222
1222
1223 <modify-function signature="endsWith(const char *)const" remove="all"/>
1223 <modify-function signature="endsWith(const char *)const" remove="all"/>
1224
1224
1225 <modify-function signature="fill(char,int)">
1225 <modify-function signature="fill(char,int)">
1226 <modify-argument index="0" replace-value="this"/>
1226 <modify-argument index="0" replace-value="this"/>
1227 </modify-function>
1227 </modify-function>
1228
1228
1229 <modify-function signature="indexOf(const char*,int)const" remove="all"/>
1229 <modify-function signature="indexOf(const char*,int)const" remove="all"/>
1230 <modify-function signature="indexOf(char,int)const">
1230 <modify-function signature="indexOf(char,int)const">
1231 <rename to="indexOfByte"/>
1231 <rename to="indexOfByte"/>
1232 </modify-function>
1232 </modify-function>
1233
1233
1234 <modify-function signature="insert(int,QByteArray)">
1234 <modify-function signature="insert(int,QByteArray)">
1235 <modify-argument index="0" replace-value="this"/>
1235 <modify-argument index="0" replace-value="this"/>
1236 </modify-function>
1236 </modify-function>
1237 <modify-function signature="insert(int,QString)">
1237 <modify-function signature="insert(int,QString)">
1238 <modify-argument index="0" replace-value="this"/>
1238 <modify-argument index="0" replace-value="this"/>
1239 </modify-function>
1239 </modify-function>
1240 <modify-function signature="insert(int,const char *)" remove="all"/>
1240 <modify-function signature="insert(int,const char *)" remove="all"/>
1241 <modify-function signature="insert(int,char)">
1241 <modify-function signature="insert(int,char)">
1242 <modify-argument index="0" replace-value="this"/>
1242 <modify-argument index="0" replace-value="this"/>
1243 <rename to="insertByte"/>
1243 <rename to="insertByte"/>
1244 </modify-function>
1244 </modify-function>
1245
1245
1246 <modify-function signature="lastIndexOf(const char*,int)const" remove="all"/>
1246 <modify-function signature="lastIndexOf(const char*,int)const" remove="all"/>
1247 <modify-function signature="lastIndexOf(char,int)const">
1247 <modify-function signature="lastIndexOf(char,int)const">
1248 <rename to="lastIndexOfByte"/>
1248 <rename to="lastIndexOfByte"/>
1249 </modify-function>
1249 </modify-function>
1250
1250
1251 <modify-function signature="prepend(QByteArray)">
1251 <modify-function signature="prepend(QByteArray)">
1252 <modify-argument index="0" replace-value="this"/>
1252 <modify-argument index="0" replace-value="this"/>
1253 </modify-function>
1253 </modify-function>
1254 <modify-function signature="prepend(const char *)" remove="all"/>
1254 <modify-function signature="prepend(const char *)" remove="all"/>
1255 <modify-function signature="prepend(char)">
1255 <modify-function signature="prepend(char)">
1256 <modify-argument index="0" replace-value="this"/>
1256 <modify-argument index="0" replace-value="this"/>
1257 <rename to="prependByte"/>
1257 <rename to="prependByte"/>
1258 </modify-function>
1258 </modify-function>
1259
1259
1260 <modify-function signature="remove(int,int)">
1260 <modify-function signature="remove(int,int)">
1261 <modify-argument index="0" replace-value="this"/>
1261 <modify-argument index="0" replace-value="this"/>
1262 </modify-function>
1262 </modify-function>
1263
1263
1264 <modify-function signature="replace(int,int,QByteArray)">
1264 <modify-function signature="replace(int,int,QByteArray)">
1265 <modify-argument index="0" replace-value="this"/>
1265 <modify-argument index="0" replace-value="this"/>
1266 </modify-function>
1266 </modify-function>
1267 <modify-function signature="replace(int,int,const char *)" remove="all"/>
1267 <modify-function signature="replace(int,int,const char *)" remove="all"/>
1268 <modify-function signature="replace(QByteArray,QByteArray)">
1268 <modify-function signature="replace(QByteArray,QByteArray)">
1269 <modify-argument index="0" replace-value="this"/>
1269 <modify-argument index="0" replace-value="this"/>
1270 </modify-function>
1270 </modify-function>
1271 <modify-function signature="replace(const char*,QByteArray)" remove="all"/>
1271 <modify-function signature="replace(const char*,QByteArray)" remove="all"/>
1272 <modify-function signature="replace(QByteArray,const char *)" remove="all"/>
1272 <modify-function signature="replace(QByteArray,const char *)" remove="all"/>
1273 <modify-function signature="replace(QString,QByteArray)">
1273 <modify-function signature="replace(QString,QByteArray)">
1274 <modify-argument index="0" replace-value="this"/>
1274 <modify-argument index="0" replace-value="this"/>
1275 </modify-function>
1275 </modify-function>
1276 <modify-function signature="replace(QString,const char *)" remove="all"/>
1276 <modify-function signature="replace(QString,const char *)" remove="all"/>
1277 <modify-function signature="replace(const char *,const char *)" remove="all"/>
1277 <modify-function signature="replace(const char *,const char *)" remove="all"/>
1278 <modify-function signature="replace(char,QByteArray)">
1278 <modify-function signature="replace(char,QByteArray)">
1279 <modify-argument index="0" replace-value="this"/>
1279 <modify-argument index="0" replace-value="this"/>
1280 </modify-function>
1280 </modify-function>
1281 <modify-function signature="replace(char,QString)">
1281 <modify-function signature="replace(char,QString)">
1282 <modify-argument index="0" replace-value="this"/>
1282 <modify-argument index="0" replace-value="this"/>
1283 </modify-function>
1283 </modify-function>
1284 <modify-function signature="replace(char,const char *)" remove="all"/>
1284 <modify-function signature="replace(char,const char *)" remove="all"/>
1285 <modify-function signature="replace(char,char)">
1285 <modify-function signature="replace(char,char)">
1286 <modify-argument index="0" replace-value="this"/>
1286 <modify-argument index="0" replace-value="this"/>
1287 </modify-function>
1287 </modify-function>
1288
1288
1289 <modify-function signature="startsWith(const char *)const" remove="all"/>
1289 <modify-function signature="startsWith(const char *)const" remove="all"/>
1290
1290
1291 <modify-function signature="fromRawData(const char*,int)" remove="all"/>
1291 <modify-function signature="fromRawData(const char*,int)" remove="all"/>
1292
1292
1293 <modify-function signature="number(int,int)">
1293 <modify-function signature="number(int,int)">
1294 <rename to="fromInt"/>
1294 <rename to="fromInt"/>
1295 </modify-function>
1295 </modify-function>
1296 <modify-function signature="number(uint,int)">
1296 <modify-function signature="number(uint,int)">
1297 <rename to="fromUInt"/>
1297 <rename to="fromUInt"/>
1298 </modify-function>
1298 </modify-function>
1299 <modify-function signature="number(qlonglong,int)">
1299 <modify-function signature="number(qlonglong,int)">
1300 <rename to="fromLongLong"/>
1300 <rename to="fromLongLong"/>
1301 </modify-function>
1301 </modify-function>
1302 <modify-function signature="number(qulonglong,int)">
1302 <modify-function signature="number(qulonglong,int)">
1303 <rename to="fromULongLong"/>
1303 <rename to="fromULongLong"/>
1304 </modify-function>
1304 </modify-function>
1305
1305
1306 <modify-function signature="setNum(int,int)">
1306 <modify-function signature="setNum(int,int)">
1307 <modify-argument index="0" replace-value="this"/>
1307 <modify-argument index="0" replace-value="this"/>
1308 <rename to="setInt"/>
1308 <rename to="setInt"/>
1309 </modify-function>
1309 </modify-function>
1310 <modify-function signature="setNum(uint,int)">
1310 <modify-function signature="setNum(uint,int)">
1311 <modify-argument index="0" replace-value="this"/>
1311 <modify-argument index="0" replace-value="this"/>
1312 <rename to="setUInt"/>
1312 <rename to="setUInt"/>
1313 </modify-function>
1313 </modify-function>
1314 <modify-function signature="setNum(short,int)">
1314 <modify-function signature="setNum(short,int)">
1315 <modify-argument index="0" replace-value="this"/>
1315 <modify-argument index="0" replace-value="this"/>
1316 <rename to="setShort"/>
1316 <rename to="setShort"/>
1317 </modify-function>
1317 </modify-function>
1318 <modify-function signature="setNum(ushort,int)">
1318 <modify-function signature="setNum(ushort,int)">
1319 <modify-argument index="0" replace-value="this"/>
1319 <modify-argument index="0" replace-value="this"/>
1320 <rename to="setUShort"/>
1320 <rename to="setUShort"/>
1321 </modify-function>
1321 </modify-function>
1322 <modify-function signature="setNum(qlonglong,int)">
1322 <modify-function signature="setNum(qlonglong,int)">
1323 <modify-argument index="0" replace-value="this"/>
1323 <modify-argument index="0" replace-value="this"/>
1324 <rename to="setLongLong"/>
1324 <rename to="setLongLong"/>
1325 </modify-function>
1325 </modify-function>
1326 <modify-function signature="setNum(qulonglong,int)">
1326 <modify-function signature="setNum(qulonglong,int)">
1327 <modify-argument index="0" replace-value="this"/>
1327 <modify-argument index="0" replace-value="this"/>
1328 <rename to="setULongLong"/>
1328 <rename to="setULongLong"/>
1329 </modify-function>
1329 </modify-function>
1330 <modify-function signature="setNum(double,char,int)">
1330 <modify-function signature="setNum(double,char,int)">
1331 <modify-argument index="0" replace-value="this"/>
1331 <modify-argument index="0" replace-value="this"/>
1332 <rename to="setDouble"/>
1332 <rename to="setDouble"/>
1333 </modify-function>
1333 </modify-function>
1334 <modify-function signature="setNum(float,char,int)">
1334 <modify-function signature="setNum(float,char,int)">
1335 <modify-argument index="0" replace-value="this"/>
1335 <modify-argument index="0" replace-value="this"/>
1336 <rename to="setFloat"/>
1336 <rename to="setFloat"/>
1337 </modify-function>
1337 </modify-function>
1338
1338
1339 <modify-function signature="toDouble(bool*)const">
1339 <modify-function signature="toDouble(bool*)const">
1340 <modify-argument index="1">
1340 <modify-argument index="1">
1341 <remove-default-expression/>
1341 <remove-default-expression/>
1342 <remove-argument/>
1342 <remove-argument/>
1343 <conversion-rule class="native">
1343 <conversion-rule class="native">
1344 <insert-template name="core.prepare_removed_bool*_argument"/>
1344 <insert-template name="core.prepare_removed_bool*_argument"/>
1345 </conversion-rule>
1345 </conversion-rule>
1346 </modify-argument>
1346 </modify-argument>
1347 <modify-argument index="return">
1347 <modify-argument index="return">
1348 <conversion-rule class="native">
1348 <conversion-rule class="native">
1349 <insert-template name="core.convert_to_null_or_primitive"/>
1349 <insert-template name="core.convert_to_null_or_primitive"/>
1350 </conversion-rule>
1350 </conversion-rule>
1351 </modify-argument>
1351 </modify-argument>
1352 </modify-function>
1352 </modify-function>
1353
1353
1354 <modify-function signature="toFloat(bool*)const">
1354 <modify-function signature="toFloat(bool*)const">
1355 <modify-argument index="1">
1355 <modify-argument index="1">
1356 <remove-default-expression/>
1356 <remove-default-expression/>
1357 <remove-argument/>
1357 <remove-argument/>
1358 <conversion-rule class="native">
1358 <conversion-rule class="native">
1359 <insert-template name="core.prepare_removed_bool*_argument"/>
1359 <insert-template name="core.prepare_removed_bool*_argument"/>
1360 </conversion-rule>
1360 </conversion-rule>
1361 </modify-argument>
1361 </modify-argument>
1362 <modify-argument index="return">
1362 <modify-argument index="return">
1363 <conversion-rule class="native">
1363 <conversion-rule class="native">
1364 <insert-template name="core.convert_to_null_or_primitive"/>
1364 <insert-template name="core.convert_to_null_or_primitive"/>
1365 </conversion-rule>
1365 </conversion-rule>
1366 </modify-argument>
1366 </modify-argument>
1367 </modify-function>
1367 </modify-function>
1368
1368
1369 <modify-function signature="toInt(bool*,int)const">
1369 <modify-function signature="toInt(bool*,int)const">
1370 <modify-argument index="1">
1370 <modify-argument index="1">
1371 <remove-default-expression/>
1371 <remove-default-expression/>
1372 <remove-argument/>
1372 <remove-argument/>
1373 <conversion-rule class="native">
1373 <conversion-rule class="native">
1374 <insert-template name="core.prepare_removed_bool*_argument"/>
1374 <insert-template name="core.prepare_removed_bool*_argument"/>
1375 </conversion-rule>
1375 </conversion-rule>
1376 </modify-argument>
1376 </modify-argument>
1377 <modify-argument index="return">
1377 <modify-argument index="return">
1378 <conversion-rule class="native">
1378 <conversion-rule class="native">
1379 <insert-template name="core.convert_to_null_or_primitive"/>
1379 <insert-template name="core.convert_to_null_or_primitive"/>
1380 </conversion-rule>
1380 </conversion-rule>
1381 </modify-argument>
1381 </modify-argument>
1382 </modify-function>
1382 </modify-function>
1383
1383
1384 <modify-function signature="toUShort(bool*,int)const">
1384 <modify-function signature="toUShort(bool*,int)const">
1385 <modify-argument index="1">
1385 <modify-argument index="1">
1386 <remove-default-expression/>
1386 <remove-default-expression/>
1387 <remove-argument/>
1387 <remove-argument/>
1388 <conversion-rule class="native">
1388 <conversion-rule class="native">
1389 <insert-template name="core.prepare_removed_bool*_argument"/>
1389 <insert-template name="core.prepare_removed_bool*_argument"/>
1390 </conversion-rule>
1390 </conversion-rule>
1391 </modify-argument>
1391 </modify-argument>
1392 <modify-argument index="return">
1392 <modify-argument index="return">
1393 <conversion-rule class="native">
1393 <conversion-rule class="native">
1394 <insert-template name="core.convert_to_null_or_primitive"/>
1394 <insert-template name="core.convert_to_null_or_primitive"/>
1395 </conversion-rule>
1395 </conversion-rule>
1396 </modify-argument>
1396 </modify-argument>
1397 </modify-function>
1397 </modify-function>
1398 </value-type>
1398 </value-type>
1399
1399
1400 <value-type name="QTextBoundaryFinder">
1400 <value-type name="QTextBoundaryFinder">
1401 <modify-function signature="QTextBoundaryFinder(QTextBoundaryFinder::BoundaryType,const QChar*,int,unsigned char*,int)" remove="all"/>
1401 <modify-function signature="QTextBoundaryFinder(QTextBoundaryFinder::BoundaryType,const QChar*,int,unsigned char*,int)" remove="all"/>
1402 <modify-function signature="operator=(QTextBoundaryFinder)" remove="all"/>
1402 <modify-function signature="operator=(QTextBoundaryFinder)" remove="all"/>
1403 </value-type>
1403 </value-type>
1404
1404
1405 <value-type name="QEasingCurve">
1405 <value-type name="QEasingCurve">
1406 <modify-function signature="customType()const" remove="all"/>
1406 <modify-function signature="customType()const" remove="all"/>
1407 <modify-function signature="setCustomType(double)" remove="all"/>
1407 <modify-function signature="setCustomType(double)" remove="all"/>
1408
1408
1409 <modify-function signature="QEasingCurve(QEasingCurve)" remove="all"/>
1409 <modify-function signature="QEasingCurve(QEasingCurve)" remove="all"/>
1410 <modify-function signature="operator=(QEasingCurve)" remove="all"/>
1410 <modify-function signature="operator=(QEasingCurve)" remove="all"/>
1411 <modify-function signature="operator==(const QEasingCurve &amp;)const" remove="all"/>
1411 <modify-function signature="operator==(const QEasingCurve &amp;)const" remove="all"/>
1412 <modify-function signature="operator!=(const QEasingCurve &amp;)const" remove="all"/>
1412 <modify-function signature="operator!=(const QEasingCurve &amp;)const" remove="all"/>
1413 <modify-function signature="setCustomType(double)" remove="all"/>
1413 <modify-function signature="setCustomType(double)" remove="all"/>
1414 <modify-function signature="customType()const" remove="all"/>
1414 <modify-function signature="customType()const" remove="all"/>
1415 </value-type>
1415 </value-type>
1416
1416
1417 <object-type name="QAbstractAnimation"/>
1417 <object-type name="QAbstractAnimation"/>
1418 <object-type name="QVariantAnimation"/>
1418 <object-type name="QVariantAnimation"/>
1419 <object-type name="QAnimationGroup"/>
1419 <object-type name="QAnimationGroup"/>
1420 <object-type name="QPauseAnimation"/>
1420 <object-type name="QPauseAnimation"/>
1421 <object-type name="QParallelAnimationGroup"/>
1421 <object-type name="QParallelAnimationGroup"/>
1422 <object-type name="QSequentialAnimationGroup"/>
1422 <object-type name="QSequentialAnimationGroup"/>
1423 <object-type name="QPropertyAnimation">
1423 <object-type name="QPropertyAnimation">
1424 <modify-function signature="QPropertyAnimation(QObject*,QByteArray,QObject*)">
1424 <modify-function signature="QPropertyAnimation(QObject*,QByteArray,QObject*)">
1425 <modify-argument index="2">
1425 <modify-argument index="2">
1426 <replace-type modified-type="QString"/>
1426 <replace-type modified-type="QString"/>
1427 <conversion-rule class="native">
1427 <conversion-rule class="native">
1428 <insert-template name="core.convert_string_arg_to_latin1"/>
1428 <insert-template name="core.convert_string_arg_to_latin1"/>
1429 </conversion-rule>
1429 </conversion-rule>
1430 </modify-argument>
1430 </modify-argument>
1431 </modify-function>
1431 </modify-function>
1432 </object-type>
1432 </object-type>
1433
1433
1434 <object-type name="QAbstractState"/>
1434 <object-type name="QAbstractState"/>
1435 <object-type name="QAbstractTransition"/>
1435 <object-type name="QAbstractTransition"/>
1436 <object-type name="QState">
1436 <object-type name="QState">
1437 <modify-function signature="addTransition(QObject*,const char*,QAbstractState*)">
1437 <modify-function signature="addTransition(QObject*,const char*,QAbstractState*)">
1438 <modify-argument index="2">
1438 <modify-argument index="2">
1439 <replace-type modified-type="QString"/>
1439 <replace-type modified-type="QString"/>
1440 <conversion-rule class="native">
1440 <conversion-rule class="native">
1441 <insert-template name="core.convert_string_arg_to_char*"/>
1441 <insert-template name="core.convert_string_arg_to_char*"/>
1442 </conversion-rule>
1442 </conversion-rule>
1443 </modify-argument>
1443 </modify-argument>
1444 </modify-function>
1444 </modify-function>
1445 <modify-function signature="assignProperty(QObject*,const char*,QVariant)">
1445 <modify-function signature="assignProperty(QObject*,const char*,QVariant)">
1446 <modify-argument index="2">
1446 <modify-argument index="2">
1447 <replace-type modified-type="QString"/>
1447 <replace-type modified-type="QString"/>
1448 <conversion-rule class="native">
1448 <conversion-rule class="native">
1449 <insert-template name="core.convert_string_arg_to_char*"/>
1449 <insert-template name="core.convert_string_arg_to_char*"/>
1450 </conversion-rule>
1450 </conversion-rule>
1451 </modify-argument>
1451 </modify-argument>
1452 </modify-function>
1452 </modify-function>
1453 </object-type>
1453 </object-type>
1454 <object-type name="QStateMachine"/>
1454 <object-type name="QStateMachine"/>
1455 <object-type name="QHistoryState"/>
1455 <object-type name="QHistoryState"/>
1456 <object-type name="QSignalTransition"/>
1456 <object-type name="QSignalTransition"/>
1457 <object-type name="QEventTransition"/>
1457 <object-type name="QEventTransition"/>
1458 <object-type name="QFinalState"/>
1458 <object-type name="QFinalState"/>
1459
1459
1460 <object-type name="QXmlStreamEntityResolver"/>
1460 <object-type name="QXmlStreamEntityResolver"/>
1461 <!-- object-type name="QAbstractEventDispatcher"/ -->
1461 <!-- object-type name="QAbstractEventDispatcher"/ -->
1462 <object-type name="QEventLoop"/>
1462 <object-type name="QEventLoop"/>
1463 <object-type name="QFile">
1463 <object-type name="QFile">
1464 <modify-function signature="readLink()const" remove="all"/>
1464 <modify-function signature="readLink()const" remove="all"/>
1465 <!--### Obsolete in 4.3-->
1465 <!--### Obsolete in 4.3-->
1466 <modify-function signature="readLink(QString)" remove="all"/>
1466 <modify-function signature="readLink(QString)" remove="all"/>
1467 <!--### Obsolete in 4.3-->
1467 <!--### Obsolete in 4.3-->
1468 <modify-function signature="map(qint64,qint64,QFile::MemoryMapFlags)" remove="all"/>
1468 <modify-function signature="map(qint64,qint64,QFile::MemoryMapFlags)" remove="all"/>
1469 <!-- Can't provide same API and performance -->
1469 <!-- Can't provide same API and performance -->
1470 <modify-function signature="unmap(uchar*)" remove="all"/>
1470 <modify-function signature="unmap(uchar*)" remove="all"/>
1471 <!-- Can't provide same API and performance -->
1471 <!-- Can't provide same API and performance -->
1472
1472
1473 <modify-function signature="open(int,QFlags&lt;QIODevice::OpenModeFlag&gt;)" remove="all"/>
1473 <modify-function signature="open(int,QFlags&lt;QIODevice::OpenModeFlag&gt;)" remove="all"/>
1474 <modify-function signature="decodeName(const char*)" remove="all"/>
1474 <modify-function signature="decodeName(const char*)" remove="all"/>
1475 <modify-function signature="map(qint64,qint64,QFile::MemoryMapFlags)" remove="all"/>
1475 <modify-function signature="map(qint64,qint64,QFile::MemoryMapFlags)" remove="all"/>
1476 <modify-function signature="unmap(uchar*)" remove="all"/>
1476 <modify-function signature="unmap(uchar*)" remove="all"/>
1477 </object-type>
1477 </object-type>
1478
1478
1479 <object-type name="QIODevice">
1479 <object-type name="QIODevice">
1480 <modify-function signature="peek(char *,qint64)" remove="all"/>
1480 <modify-function signature="peek(char *,qint64)" remove="all"/>
1481 <modify-function signature="read(char *,qint64)" remove="all"/>
1481 <modify-function signature="read(char *,qint64)" remove="all"/>
1482 <modify-function signature="readLine(char *,qint64)" remove="all"/>
1482 <modify-function signature="readLine(char *,qint64)" remove="all"/>
1483 <modify-function signature="write(const char *,qint64)" remove="all"/>
1483 <modify-function signature="write(const char *,qint64)" remove="all"/>
1484 </object-type>
1484 </object-type>
1485 <object-type name="QStateMachine::SignalEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::StateMachineSignal"/>
1485 <object-type name="QStateMachine::SignalEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::StateMachineSignal"/>
1486 <object-type name="QStateMachine::WrappedEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::StateMachineWrapped"/>
1486 <object-type name="QStateMachine::WrappedEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::StateMachineWrapped"/>
1487
1487
1488 <object-type name="QCryptographicHash">
1488 <object-type name="QCryptographicHash">
1489 <modify-function signature="addData(const char*,int)" remove="all"/>
1489 <modify-function signature="addData(const char*,int)" remove="all"/>
1490 </object-type>
1490 </object-type>
1491 <object-type name="QLibraryInfo"/>
1491 <object-type name="QLibraryInfo"/>
1492 <object-type name="QBasicMutex"/>
1492 <object-type name="QBasicMutex"/>
1493 <object-type name="QMutex"/>
1493 <object-type name="QMutex"/>
1494 <object-type name="QSemaphore"/>
1494 <object-type name="QSemaphore"/>
1495 <object-type name="QSocketNotifier"/>
1495 <object-type name="QSocketNotifier"/>
1496 <object-type name="QSystemLocale"/>
1496 <object-type name="QSystemLocale"/>
1497 <object-type name="QTemporaryFile">
1497 <object-type name="QTemporaryFile">
1498 <modify-function signature="fileName()const" rename="uniqueFilename"/>
1498 <modify-function signature="fileName()const" rename="uniqueFilename"/>
1499
1499
1500 <modify-function signature="createLocalFile(QFile&amp;)">
1500 <modify-function signature="createLocalFile(QFile&amp;)">
1501 <modify-argument index="1">
1501 <modify-argument index="1">
1502 <replace-type modified-type="QFile*"/>
1502 <replace-type modified-type="QFile*"/>
1503 <conversion-rule class="native">
1503 <conversion-rule class="native">
1504 QFile &amp; %out% = *qscriptvalue_cast&lt;QFile*&gt;(%in%);
1504 QFile &amp; %out% = *qscriptvalue_cast&lt;QFile*&gt;(%in%);
1505 </conversion-rule>
1505 </conversion-rule>
1506 </modify-argument>
1506 </modify-argument>
1507 </modify-function>
1507 </modify-function>
1508 <modify-function signature="createNativeFile(QFile&amp;)">
1509 <modify-argument index="1">
1510 <replace-type modified-type="QFile*"/>
1511 <conversion-rule class="native">
1512 QFile &amp; %out% = *qscriptvalue_cast&lt;QFile*&gt;(%in%);
1513 </conversion-rule>
1514 </modify-argument>
1515 </modify-function>
1516 </object-type>
1508 </object-type>
1517 <object-type name="QMimeData">
1509 <object-type name="QMimeData">
1518 <extra-includes>
1510 <extra-includes>
1519 <include file-name="QStringList" location="global"/>
1511 <include file-name="QStringList" location="global"/>
1520 <include file-name="QUrl" location="global"/>
1512 <include file-name="QUrl" location="global"/>
1521 </extra-includes>
1513 </extra-includes>
1522 </object-type>
1514 </object-type>
1523 <object-type name="QTextCodec">
1515 <object-type name="QTextCodec">
1524
1516
1525 <modify-function signature="setCodecForTr(QTextCodec*)">
1517 <modify-function signature="setCodecForTr(QTextCodec*)">
1526 <access modifier="private"/>
1518 <access modifier="private"/>
1527 <modify-argument index="1">
1519 <modify-argument index="1">
1528 <reference-count action="set" variable-name="__rcCodecForTr"/>
1520 <reference-count action="set" variable-name="__rcCodecForTr"/>
1529 </modify-argument>
1521 </modify-argument>
1530 </modify-function>
1522 </modify-function>
1531 <modify-function signature="setCodecForCStrings(QTextCodec*)">
1523 <modify-function signature="setCodecForCStrings(QTextCodec*)">
1532 <modify-argument index="1">
1524 <modify-argument index="1">
1533 <reference-count action="set" variable-name="__rcCodecForCStrings"/>
1525 <reference-count action="set" variable-name="__rcCodecForCStrings"/>
1534 </modify-argument>
1526 </modify-argument>
1535 </modify-function>
1527 </modify-function>
1536 <modify-function signature="setCodecForLocale(QTextCodec*)">
1528 <modify-function signature="setCodecForLocale(QTextCodec*)">
1537 <modify-argument index="1">
1529 <modify-argument index="1">
1538 <reference-count action="set" variable-name="__rcCodecForLocale"/>
1530 <reference-count action="set" variable-name="__rcCodecForLocale"/>
1539 </modify-argument>
1531 </modify-argument>
1540 </modify-function>
1532 </modify-function>
1541
1533
1542
1534
1543 <modify-function signature="codecForTr()">
1535 <modify-function signature="codecForTr()">
1544 <remove/>
1536 <remove/>
1545 </modify-function>
1537 </modify-function>
1546
1538
1547 <modify-function signature="QTextCodec()">
1539 <modify-function signature="QTextCodec()">
1548 <modify-argument index="-1">
1540 <modify-argument index="-1">
1549 <define-ownership class="java" owner="c++"/>
1541 <define-ownership class="java" owner="c++"/>
1550 </modify-argument>
1542 </modify-argument>
1551 </modify-function>
1543 </modify-function>
1552
1544
1553 <modify-function signature="fromUnicode(const QChar*,int,QTextCodec::ConverterState*)const">
1545 <modify-function signature="fromUnicode(const QChar*,int,QTextCodec::ConverterState*)const">
1554 <remove/>
1546 <remove/>
1555 </modify-function>
1547 </modify-function>
1556
1548
1557 <modify-function signature="toUnicode(const char*,int,QTextCodec::ConverterState*)const">
1549 <modify-function signature="toUnicode(const char*,int,QTextCodec::ConverterState*)const">
1558 <remove/>
1550 <remove/>
1559 </modify-function>
1551 </modify-function>
1560
1552
1561 <modify-function signature="toUnicode(const char*)const">
1553 <modify-function signature="toUnicode(const char*)const">
1562 <remove/>
1554 <remove/>
1563 </modify-function>
1555 </modify-function>
1564 </object-type>
1556 </object-type>
1565
1557
1566 <interface-type name="QTextCodecFactoryInterface" java-name="QAbstractTextCodecFactory"/>
1558 <interface-type name="QTextCodecFactoryInterface" java-name="QAbstractTextCodecFactory"/>
1567 <object-type name="QTextCodecPlugin"/>
1559 <object-type name="QTextCodecPlugin"/>
1568
1560
1569 <object-type name="QTextDecoder">
1561 <object-type name="QTextDecoder">
1570 <modify-function signature="toUnicode(const char*,int)">
1562 <modify-function signature="toUnicode(const char*,int)">
1571 <remove/>
1563 <remove/>
1572 </modify-function>
1564 </modify-function>
1573 <modify-function signature="toUnicode(QString*,const char*,int)" remove="all"/>
1565 <modify-function signature="toUnicode(QString*,const char*,int)" remove="all"/>
1574 </object-type>
1566 </object-type>
1575 <object-type name="QTextEncoder">
1567 <object-type name="QTextEncoder">
1576 <modify-function signature="fromUnicode(const QChar*,int)">
1568 <modify-function signature="fromUnicode(const QChar*,int)">
1577 <remove/>
1569 <remove/>
1578 </modify-function>
1570 </modify-function>
1579 </object-type>
1571 </object-type>
1580 <object-type name="QTimeLine"/>
1572 <object-type name="QTimeLine"/>
1581 <object-type name="QTranslator">
1573 <object-type name="QTranslator">
1582 <modify-function signature="translate(const char*,const char*,const char*,int)const">
1574 <modify-function signature="translate(const char*,const char*,const char*,int)const">
1583 <remove/>
1575 <remove/>
1584 </modify-function>
1576 </modify-function>
1585 </object-type>
1577 </object-type>
1586
1578
1587 <object-type name="QWaitCondition"/>
1579 <object-type name="QWaitCondition"/>
1588
1580
1589 <object-type name="QFileSystemWatcher">
1581 <object-type name="QFileSystemWatcher">
1590 <extra-includes>
1582 <extra-includes>
1591 <include file-name="QStringList" location="global"/>
1583 <include file-name="QStringList" location="global"/>
1592 </extra-includes>
1584 </extra-includes>
1593 </object-type>
1585 </object-type>
1594
1586
1595 <object-type name="QTextCodec::ConverterState">
1587 <object-type name="QTextCodec::ConverterState">
1596 <include file-name="QTextCodec" location="global"/>
1588 <include file-name="QTextCodec" location="global"/>
1597 </object-type>
1589 </object-type>
1598
1590
1599 <object-type name="QBuffer">
1591 <object-type name="QBuffer">
1600 <modify-function signature="buffer()">
1592 <modify-function signature="buffer()">
1601 <remove/>
1593 <remove/>
1602 </modify-function>
1594 </modify-function>
1603
1595
1604 <!-- ### modify to return value by pointer? -->
1596 <!-- ### modify to return value by pointer? -->
1605 <modify-function signature="buffer()const" remove="all"/>
1597 <modify-function signature="buffer()const" remove="all"/>
1606 <modify-function signature="data()const" remove="all"/>
1598 <modify-function signature="data()const" remove="all"/>
1607
1599
1608 <modify-function signature="setData(const char*,int)" remove="all"/>
1600 <modify-function signature="setData(const char*,int)" remove="all"/>
1609 </object-type>
1601 </object-type>
1610
1602
1611 <object-type name="QTimer"/>
1603 <object-type name="QTimer"/>
1612
1604
1613 <object-type name="QAbstractFileEngineHandler">
1605 <object-type name="QAbstractFileEngineHandler">
1614 <modify-function signature="create(const QString &amp;) const">
1606 <modify-function signature="create(const QString &amp;) const">
1615 <modify-argument index="return">
1607 <modify-argument index="return">
1616 <define-ownership owner="c++" class="shell"/>
1608 <define-ownership owner="c++" class="shell"/>
1617 </modify-argument>
1609 </modify-argument>
1618 </modify-function>
1610 </modify-function>
1619 </object-type>
1611 </object-type>
1620
1612
1621 <!-- <object-type name="QAbstractFileEngine::MapExtensionOption" /> -->
1613 <!-- <object-type name="QAbstractFileEngine::MapExtensionOption" /> -->
1622 <!-- <object-type name="QAbstractFileEngine::MapExtensionReturn" /> -->
1614 <!-- <object-type name="QAbstractFileEngine::MapExtensionReturn" /> -->
1623 <!-- <object-type name="QAbstractFileEngine::UnMapExtensionOption" /> -->
1615 <!-- <object-type name="QAbstractFileEngine::UnMapExtensionOption" /> -->
1624 <object-type name="QAbstractFileEngine">
1616 <object-type name="QAbstractFileEngine">
1625 <extra-includes>
1617 <extra-includes>
1626 <include file-name="QDateTime" location="global"/>
1618 <include file-name="QDateTime" location="global"/>
1627 </extra-includes>
1619 </extra-includes>
1628 <modify-function signature="map(qlonglong,qlonglong,QFile::MemoryMapFlags)" remove="all"/>
1620 <modify-function signature="map(qlonglong,qlonglong,QFile::MemoryMapFlags)" remove="all"/>
1629 <modify-function signature="unmap(unsigned char*)" remove="all"/>
1621 <modify-function signature="unmap(unsigned char*)" remove="all"/>
1630 </object-type>
1622 </object-type>
1631
1623
1632 <object-type name="QProcess">
1624 <object-type name="QProcess">
1633 <modify-function signature="readChannelMode()const" remove="all"/>
1625 <modify-function signature="readChannelMode()const" remove="all"/>
1634 <!--### Obsolete in 4.3-->
1626 <!--### Obsolete in 4.3-->
1635 <modify-function signature="setReadChannelMode(QProcess::ProcessChannelMode)" remove="all"/>
1627 <modify-function signature="setReadChannelMode(QProcess::ProcessChannelMode)" remove="all"/>
1636 <!--### Obsolete in 4.3-->
1628 <!--### Obsolete in 4.3-->
1637 </object-type>
1629 </object-type>
1638
1630
1639 <object-type name="QSignalMapper">
1631 <object-type name="QSignalMapper">
1640 <modify-function signature="mapped(const QString &amp;)">
1632 <modify-function signature="mapped(const QString &amp;)">
1641 <rename to="mappedString"/>
1633 <rename to="mappedString"/>
1642 </modify-function>
1634 </modify-function>
1643 <modify-function signature="mapped(int)">
1635 <modify-function signature="mapped(int)">
1644 <rename to="mappedInteger"/>
1636 <rename to="mappedInteger"/>
1645 </modify-function>
1637 </modify-function>
1646 <modify-function signature="mapped(QObject *)">
1638 <modify-function signature="mapped(QObject *)">
1647 <rename to="mappedQObject"/>
1639 <rename to="mappedQObject"/>
1648 </modify-function>
1640 </modify-function>
1649 <modify-function signature="mapped(QWidget *)" remove="all"/>
1641 <modify-function signature="mapped(QWidget *)" remove="all"/>
1650
1642
1651 <modify-function signature="mapping(QWidget*)const" remove="all"/>
1643 <modify-function signature="mapping(QWidget*)const" remove="all"/>
1652
1644
1653 <modify-function signature="setMapping(QObject*,QWidget*)" remove="all"/>
1645 <modify-function signature="setMapping(QObject*,QWidget*)" remove="all"/>
1654
1646
1655 <!-- ### overloads -->
1647 <!-- ### overloads -->
1656 <modify-function signature="mapping(int)const">
1648 <modify-function signature="mapping(int)const">
1657 <rename to="mappingById"/>
1649 <rename to="mappingById"/>
1658 </modify-function>
1650 </modify-function>
1659 <modify-function signature="mapping(QString)const">
1651 <modify-function signature="mapping(QString)const">
1660 <rename to="mappingByString"/>
1652 <rename to="mappingByString"/>
1661 </modify-function>
1653 </modify-function>
1662 <modify-function signature="mapping(QObject*)const">
1654 <modify-function signature="mapping(QObject*)const">
1663 <rename to="mappingByObject"/>
1655 <rename to="mappingByObject"/>
1664 </modify-function>
1656 </modify-function>
1665 <modify-function signature="setMapping(QObject*,int)">
1657 <modify-function signature="setMapping(QObject*,int)">
1666 <rename to="setMappingById"/>
1658 <rename to="setMappingById"/>
1667 </modify-function>
1659 </modify-function>
1668 <modify-function signature="setMapping(QObject*,QString)">
1660 <modify-function signature="setMapping(QObject*,QString)">
1669 <rename to="setMappingByString"/>
1661 <rename to="setMappingByString"/>
1670 </modify-function>
1662 </modify-function>
1671 <modify-function signature="setMapping(QObject*,QObject*)">
1663 <modify-function signature="setMapping(QObject*,QObject*)">
1672 <rename to="setMappingByObject"/>
1664 <rename to="setMappingByObject"/>
1673 </modify-function>
1665 </modify-function>
1674 </object-type>
1666 </object-type>
1675
1667
1676 <object-type name="QObject">
1668 <object-type name="QObject">
1677 <modify-function signature="childEvent(QChildEvent*)">
1669 <modify-function signature="childEvent(QChildEvent*)">
1678 <modify-argument index="1" invalidate-after-use="yes"/>
1670 <modify-argument index="1" invalidate-after-use="yes"/>
1679 </modify-function>
1671 </modify-function>
1680 <modify-function signature="customEvent(QEvent*)">
1672 <modify-function signature="customEvent(QEvent*)">
1681 <modify-argument index="1" invalidate-after-use="yes"/>
1673 <modify-argument index="1" invalidate-after-use="yes"/>
1682 </modify-function>
1674 </modify-function>
1683 <modify-function signature="event(QEvent*)">
1675 <modify-function signature="event(QEvent*)">
1684 <modify-argument index="1" invalidate-after-use="yes"/>
1676 <modify-argument index="1" invalidate-after-use="yes"/>
1685 </modify-function>
1677 </modify-function>
1686 <modify-function signature="eventFilter(QObject*,QEvent*)">
1678 <modify-function signature="eventFilter(QObject*,QEvent*)">
1687 <modify-argument index="2" invalidate-after-use="yes"/>
1679 <modify-argument index="2" invalidate-after-use="yes"/>
1688 </modify-function>
1680 </modify-function>
1689 <modify-function signature="timerEvent(QTimerEvent*)">
1681 <modify-function signature="timerEvent(QTimerEvent*)">
1690 <modify-argument index="1" invalidate-after-use="yes"/>
1682 <modify-argument index="1" invalidate-after-use="yes"/>
1691 </modify-function>
1683 </modify-function>
1692
1684
1693 <modify-function signature="installEventFilter(QObject*)">
1685 <modify-function signature="installEventFilter(QObject*)">
1694 <modify-argument index="1">
1686 <modify-argument index="1">
1695 <reference-count action="add" variable-name="__rcEventFilters"/>
1687 <reference-count action="add" variable-name="__rcEventFilters"/>
1696 </modify-argument>
1688 </modify-argument>
1697 </modify-function>
1689 </modify-function>
1698 <modify-function signature="removeEventFilter(QObject*)">
1690 <modify-function signature="removeEventFilter(QObject*)">
1699 <modify-argument index="1">
1691 <modify-argument index="1">
1700 <reference-count action="remove" variable-name="__rcEventFilters"/>
1692 <reference-count action="remove" variable-name="__rcEventFilters"/>
1701 </modify-argument>
1693 </modify-argument>
1702 </modify-function>
1694 </modify-function>
1703 <modify-function signature="setParent(QObject*)">
1695 <modify-function signature="setParent(QObject*)">
1704 <modify-argument index="1">
1696 <modify-argument index="1">
1705 <reference-count action="ignore"/>
1697 <reference-count action="ignore"/>
1706 </modify-argument>
1698 </modify-argument>
1707 </modify-function>
1699 </modify-function>
1708
1700
1709 <modify-function signature="deleteLater()">
1701 <modify-function signature="deleteLater()">
1710 <rename to="disposeLater"/>
1702 <rename to="disposeLater"/>
1711 </modify-function>
1703 </modify-function>
1712 <!--
1704 <!--
1713 <modify-function signature="inherits(const char*)const">
1705 <modify-function signature="inherits(const char*)const">
1714 <remove/>
1706 <remove/>
1715 </modify-function>
1707 </modify-function>
1716 -->
1708 -->
1717 <modify-function signature="property(const char*)const">
1709 <modify-function signature="property(const char*)const">
1718 <access modifier="private"/>
1710 <access modifier="private"/>
1719 </modify-function>
1711 </modify-function>
1720
1712
1721 <modify-function signature="setProperty(const char*,QVariant)">
1713 <modify-function signature="setProperty(const char*,QVariant)">
1722 <access modifier="private"/>
1714 <access modifier="private"/>
1723 </modify-function>
1715 </modify-function>
1724
1716
1725
1717
1726 <extra-includes>
1718 <extra-includes>
1727 <include file-name="QVarLengthArray" location="global"/>
1719 <include file-name="QVarLengthArray" location="global"/>
1728 </extra-includes>
1720 </extra-includes>
1729
1721
1730
1722
1731 <modify-function signature="property(const char*)const">
1723 <modify-function signature="property(const char*)const">
1732 <modify-argument index="1">
1724 <modify-argument index="1">
1733 <replace-type modified-type="QString"/>
1725 <replace-type modified-type="QString"/>
1734 <conversion-rule class="native">
1726 <conversion-rule class="native">
1735 <insert-template name="core.convert_string_arg_to_char*"/>
1727 <insert-template name="core.convert_string_arg_to_char*"/>
1736 </conversion-rule>
1728 </conversion-rule>
1737 </modify-argument>
1729 </modify-argument>
1738 </modify-function>
1730 </modify-function>
1739
1731
1740 <modify-function signature="setProperty(const char*,QVariant)">
1732 <modify-function signature="setProperty(const char*,QVariant)">
1741 <modify-argument index="1">
1733 <modify-argument index="1">
1742 <replace-type modified-type="QString"/>
1734 <replace-type modified-type="QString"/>
1743 <conversion-rule class="native">
1735 <conversion-rule class="native">
1744 <insert-template name="core.convert_string_arg_to_char*"/>
1736 <insert-template name="core.convert_string_arg_to_char*"/>
1745 </conversion-rule>
1737 </conversion-rule>
1746 </modify-argument>
1738 </modify-argument>
1747 </modify-function>
1739 </modify-function>
1748
1740
1749 <modify-function signature="inherits(const char*)const">
1741 <modify-function signature="inherits(const char*)const">
1750 <modify-argument index="1">
1742 <modify-argument index="1">
1751 <replace-type modified-type="QString"/>
1743 <replace-type modified-type="QString"/>
1752 <conversion-rule class="native">
1744 <conversion-rule class="native">
1753 <insert-template name="core.convert_string_arg_to_char*"/>
1745 <insert-template name="core.convert_string_arg_to_char*"/>
1754 </conversion-rule>
1746 </conversion-rule>
1755 </modify-argument>
1747 </modify-argument>
1756 </modify-function>
1748 </modify-function>
1757 </object-type>
1749 </object-type>
1758
1750
1759 <object-type name="QCoreApplication">
1751 <object-type name="QCoreApplication">
1760 <extra-includes>
1752 <extra-includes>
1761 <include file-name="QStringList" location="global"/>
1753 <include file-name="QStringList" location="global"/>
1762 </extra-includes>
1754 </extra-includes>
1763
1755
1764 <modify-function signature="argv()" remove="all"/>
1756 <modify-function signature="argv()" remove="all"/>
1765 <!-- Obsolete -->
1757 <!-- Obsolete -->
1766 <modify-function signature="argc()" remove="all"/>
1758 <modify-function signature="argc()" remove="all"/>
1767 <!-- Obsolete -->
1759 <!-- Obsolete -->
1768
1760
1769 <modify-function signature="notify(QObject*,QEvent*)">
1761 <modify-function signature="notify(QObject*,QEvent*)">
1770 <modify-argument index="2" invalidate-after-use="yes"/>
1762 <modify-argument index="2" invalidate-after-use="yes"/>
1771 </modify-function>
1763 </modify-function>
1772
1764
1773
1765
1774 <modify-function signature="QCoreApplication(int &amp;, char **)">
1766 <modify-function signature="QCoreApplication(int &amp;, char **)">
1775 <access modifier="private"/>
1767 <access modifier="private"/>
1776 </modify-function>
1768 </modify-function>
1777 <modify-function signature="removePostedEvents(QObject*)">
1769 <modify-function signature="removePostedEvents(QObject*)">
1778 <modify-argument index="1">
1770 <modify-argument index="1">
1779 <reference-count action="ignore"/>
1771 <reference-count action="ignore"/>
1780 </modify-argument>
1772 </modify-argument>
1781 </modify-function>
1773 </modify-function>
1782 <modify-function signature="removePostedEvents(QObject*,int)">
1774 <modify-function signature="removePostedEvents(QObject*,int)">
1783 <modify-argument index="1">
1775 <modify-argument index="1">
1784 <reference-count action="ignore"/>
1776 <reference-count action="ignore"/>
1785 </modify-argument>
1777 </modify-argument>
1786 </modify-function>
1778 </modify-function>
1787
1779
1788 <modify-function signature="installTranslator(QTranslator *)">
1780 <modify-function signature="installTranslator(QTranslator *)">
1789 <modify-argument index="1">
1781 <modify-argument index="1">
1790 <reference-count action="add" variable-name="__rcTranslators"/>
1782 <reference-count action="add" variable-name="__rcTranslators"/>
1791 </modify-argument>
1783 </modify-argument>
1792 </modify-function>
1784 </modify-function>
1793
1785
1794 <modify-function signature="removeTranslator(QTranslator *)">
1786 <modify-function signature="removeTranslator(QTranslator *)">
1795 <modify-argument index="1">
1787 <modify-argument index="1">
1796 <reference-count action="remove" variable-name="__rcTranslators"/>
1788 <reference-count action="remove" variable-name="__rcTranslators"/>
1797 </modify-argument>
1789 </modify-argument>
1798 </modify-function>
1790 </modify-function>
1799
1791
1800
1792
1801 <modify-function signature="postEvent(QObject*,QEvent*)">
1793 <modify-function signature="postEvent(QObject*,QEvent*)">
1802 <modify-argument index="2">
1794 <modify-argument index="2">
1803 <define-ownership class="java" owner="c++"/>
1795 <define-ownership class="java" owner="c++"/>
1804 </modify-argument>
1796 </modify-argument>
1805 </modify-function>
1797 </modify-function>
1806
1798
1807 <modify-function signature="QCoreApplication(int &amp;, char **)" remove="all"/>
1799 <modify-function signature="QCoreApplication(int &amp;, char **)" remove="all"/>
1808 <!-- ### arguments() causes a warning: "QScriptValue::setProperty(arguments): cannot change flags of a native property" -->
1800 <!-- ### arguments() causes a warning: "QScriptValue::setProperty(arguments): cannot change flags of a native property" -->
1809 <modify-function signature="arguments()" remove="all"/>
1801 <modify-function signature="arguments()" remove="all"/>
1810 <modify-function signature="translate(const char*,const char*,const char*,QCoreApplication::Encoding,int)">
1802 <modify-function signature="translate(const char*,const char*,const char*,QCoreApplication::Encoding,int)">
1811 <modify-argument index="1">
1803 <modify-argument index="1">
1812 <replace-type modified-type="QString"/>
1804 <replace-type modified-type="QString"/>
1813 <conversion-rule class="native">
1805 <conversion-rule class="native">
1814 <insert-template name="core.convert_string_arg_to_char*"/>
1806 <insert-template name="core.convert_string_arg_to_char*"/>
1815 </conversion-rule>
1807 </conversion-rule>
1816 </modify-argument>
1808 </modify-argument>
1817 <modify-argument index="2">
1809 <modify-argument index="2">
1818 <replace-type modified-type="QString"/>
1810 <replace-type modified-type="QString"/>
1819 <conversion-rule class="native">
1811 <conversion-rule class="native">
1820 <insert-template name="core.convert_string_arg_to_char*"/>
1812 <insert-template name="core.convert_string_arg_to_char*"/>
1821 </conversion-rule>
1813 </conversion-rule>
1822 </modify-argument>
1814 </modify-argument>
1823 <modify-argument index="3">
1815 <modify-argument index="3">
1824 <replace-type modified-type="QString"/>
1816 <replace-type modified-type="QString"/>
1825 <conversion-rule class="native">
1817 <conversion-rule class="native">
1826 <insert-template name="core.convert_string_arg_to_char*"/>
1818 <insert-template name="core.convert_string_arg_to_char*"/>
1827 </conversion-rule>
1819 </conversion-rule>
1828 </modify-argument>
1820 </modify-argument>
1829 </modify-function>
1821 </modify-function>
1830 <modify-function signature="translate(const char *,const char *,const char *,QCoreApplication::Encoding)">
1822 <modify-function signature="translate(const char *,const char *,const char *,QCoreApplication::Encoding)">
1831 <modify-argument index="1">
1823 <modify-argument index="1">
1832 <replace-type modified-type="QString"/>
1824 <replace-type modified-type="QString"/>
1833 <conversion-rule class="native">
1825 <conversion-rule class="native">
1834 <insert-template name="core.convert_string_arg_to_char*"/>
1826 <insert-template name="core.convert_string_arg_to_char*"/>
1835 </conversion-rule>
1827 </conversion-rule>
1836 </modify-argument>
1828 </modify-argument>
1837 <modify-argument index="2">
1829 <modify-argument index="2">
1838 <replace-type modified-type="QString"/>
1830 <replace-type modified-type="QString"/>
1839 <conversion-rule class="native">
1831 <conversion-rule class="native">
1840 <insert-template name="core.convert_string_arg_to_char*"/>
1832 <insert-template name="core.convert_string_arg_to_char*"/>
1841 </conversion-rule>
1833 </conversion-rule>
1842 </modify-argument>
1834 </modify-argument>
1843 <modify-argument index="3">
1835 <modify-argument index="3">
1844 <replace-type modified-type="QString"/>
1836 <replace-type modified-type="QString"/>
1845 <conversion-rule class="native">
1837 <conversion-rule class="native">
1846 <insert-template name="core.convert_string_arg_to_char*"/>
1838 <insert-template name="core.convert_string_arg_to_char*"/>
1847 </conversion-rule>
1839 </conversion-rule>
1848 </modify-argument>
1840 </modify-argument>
1849 </modify-function>
1841 </modify-function>
1850
1842
1851 </object-type>
1843 </object-type>
1852
1844
1853 <object-type name="QSettings">
1845 <object-type name="QSettings">
1854 <extra-includes>
1846 <extra-includes>
1855 <include file-name="QStringList" location="global"/>
1847 <include file-name="QStringList" location="global"/>
1856 </extra-includes>
1848 </extra-includes>
1857
1849
1858 <modify-function signature="setSystemIniPath(const QString&amp;)" remove="all"/>
1850 <modify-function signature="setSystemIniPath(const QString&amp;)" remove="all"/>
1859 <!--### Obsolete in 4.3-->
1851 <!--### Obsolete in 4.3-->
1860 <modify-function signature="setUserIniPath(const QString&amp;)" remove="all"/>
1852 <modify-function signature="setUserIniPath(const QString&amp;)" remove="all"/>
1861 <!--### Obsolete in 4.3-->
1853 <!--### Obsolete in 4.3-->
1862 </object-type>
1854 </object-type>
1863
1855
1864 <object-type name="QEvent" polymorphic-base="yes" polymorphic-id-expression="%1-&gt;type() == QEvent::None"/>
1856 <object-type name="QEvent" polymorphic-base="yes" polymorphic-id-expression="%1-&gt;type() == QEvent::None"/>
1865 <object-type name="QChildEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::ChildAdded || %1-&gt;type() == QEvent::ChildPolished || %1-&gt;type() == QEvent::ChildRemoved">
1857 <object-type name="QChildEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::ChildAdded || %1-&gt;type() == QEvent::ChildPolished || %1-&gt;type() == QEvent::ChildRemoved">
1866 <modify-field name="c" read="false" write="false"/>
1858 <modify-field name="c" read="false" write="false"/>
1867 </object-type>
1859 </object-type>
1868 <object-type name="QTimerEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Timer"/>
1860 <object-type name="QTimerEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Timer"/>
1869 <object-type name="QDynamicPropertyChangeEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::DynamicPropertyChange"/>
1861 <object-type name="QDynamicPropertyChangeEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::DynamicPropertyChange"/>
1870
1862
1871 <object-type name="QDataStream">
1863 <object-type name="QDataStream">
1872 <modify-function signature="setDevice(QIODevice*)">
1864 <modify-function signature="setDevice(QIODevice*)">
1873 <modify-argument index="1">
1865 <modify-argument index="1">
1874 <reference-count action="set" variable-name="__rcDevice"/>
1866 <reference-count action="set" variable-name="__rcDevice"/>
1875 </modify-argument>
1867 </modify-argument>
1876 </modify-function>
1868 </modify-function>
1877 <!--
1869 <!--
1878 <modify-function signature="unsetDevice()">
1870 <modify-function signature="unsetDevice()">
1879 <inject-code position="end">
1871 <inject-code position="end">
1880 __rcDevice = null;
1872 __rcDevice = null;
1881 </inject-code>
1873 </inject-code>
1882 </modify-function>
1874 </modify-function>
1883 -->
1875 -->
1884
1876
1885
1877
1886 <modify-function signature="operator&lt;&lt;(const char*)">
1878 <modify-function signature="operator&lt;&lt;(const char*)">
1887 <remove/>
1879 <remove/>
1888 </modify-function>
1880 </modify-function>
1889 <modify-function signature="operator&lt;&lt;(unsigned int)">
1881 <modify-function signature="operator&lt;&lt;(unsigned int)">
1890 <remove/>
1882 <remove/>
1891 </modify-function>
1883 </modify-function>
1892 <modify-function signature="operator&lt;&lt;(unsigned long long)">
1884 <modify-function signature="operator&lt;&lt;(unsigned long long)">
1893 <remove/>
1885 <remove/>
1894 </modify-function>
1886 </modify-function>
1895 <modify-function signature="operator&lt;&lt;(unsigned short)">
1887 <modify-function signature="operator&lt;&lt;(unsigned short)">
1896 <remove/>
1888 <remove/>
1897 </modify-function>
1889 </modify-function>
1898
1890
1899 <modify-function signature="operator&gt;&gt;(char &amp;*)">
1891 <modify-function signature="operator&gt;&gt;(char &amp;*)">
1900 <remove/>
1892 <remove/>
1901 </modify-function>
1893 </modify-function>
1902
1894
1903 <modify-function signature="readRawData(char*,int)">
1895 <modify-function signature="readRawData(char*,int)">
1904 <remove/>
1896 <remove/>
1905 </modify-function>
1897 </modify-function>
1906 <modify-function signature="readBytes(char&amp;*,uint&amp;)">
1898 <modify-function signature="readBytes(char&amp;*,uint&amp;)">
1907 <remove/>
1899 <remove/>
1908 </modify-function>
1900 </modify-function>
1909 <modify-function signature="writeRawData(const char*,int)">
1901 <modify-function signature="writeRawData(const char*,int)">
1910 <remove/>
1902 <remove/>
1911 </modify-function>
1903 </modify-function>
1912 <modify-function signature="writeBytes(const char*,uint)">
1904 <modify-function signature="writeBytes(const char*,uint)">
1913 <remove/>
1905 <remove/>
1914 </modify-function>
1906 </modify-function>
1915
1907
1916 <modify-function signature="operator&gt;&gt;(signed char&amp;)" remove="all"/>
1908 <modify-function signature="operator&gt;&gt;(signed char&amp;)" remove="all"/>
1917 <modify-function signature="operator&lt;&lt;(signed char)" remove="all"/>
1909 <modify-function signature="operator&lt;&lt;(signed char)" remove="all"/>
1918
1910
1919 <modify-function signature="operator&lt;&lt;(bool)">
1911 <modify-function signature="operator&lt;&lt;(bool)">
1920 <rename to="writeBoolean"/>
1912 <rename to="writeBoolean"/>
1921 <modify-argument index="0" replace-value="this"/>
1913 <modify-argument index="0" replace-value="this"/>
1922 </modify-function>
1914 </modify-function>
1923 <modify-function signature="operator&lt;&lt;(unsigned char)">
1915 <modify-function signature="operator&lt;&lt;(unsigned char)">
1924 <modify-argument index="0" replace-value="this"/>
1916 <modify-argument index="0" replace-value="this"/>
1925 <rename to="writeByte"/>
1917 <rename to="writeByte"/>
1926 </modify-function>
1918 </modify-function>
1927 <modify-function signature="operator&lt;&lt;(int)">
1919 <modify-function signature="operator&lt;&lt;(int)">
1928 <rename to="writeInt"/>
1920 <rename to="writeInt"/>
1929 <modify-argument index="0" replace-value="this"/>
1921 <modify-argument index="0" replace-value="this"/>
1930 </modify-function>
1922 </modify-function>
1931 <modify-function signature="operator&lt;&lt;(qint64)">
1923 <modify-function signature="operator&lt;&lt;(qint64)">
1932 <rename to="writeLongLong"/>
1924 <rename to="writeLongLong"/>
1933 <modify-argument index="0" replace-value="this"/>
1925 <modify-argument index="0" replace-value="this"/>
1934 </modify-function>
1926 </modify-function>
1935 <modify-function signature="operator&lt;&lt;(float)">
1927 <modify-function signature="operator&lt;&lt;(float)">
1936 <rename to="writeFloat"/>
1928 <rename to="writeFloat"/>
1937 <modify-argument index="0" replace-value="this"/>
1929 <modify-argument index="0" replace-value="this"/>
1938 </modify-function>
1930 </modify-function>
1939 <modify-function signature="operator&lt;&lt;(double)">
1931 <modify-function signature="operator&lt;&lt;(double)">
1940 <rename to="writeDouble"/>
1932 <rename to="writeDouble"/>
1941 <modify-argument index="0" replace-value="this"/>
1933 <modify-argument index="0" replace-value="this"/>
1942 </modify-function>
1934 </modify-function>
1943 <modify-function signature="operator&lt;&lt;(short)">
1935 <modify-function signature="operator&lt;&lt;(short)">
1944 <rename to="writeShort"/>
1936 <rename to="writeShort"/>
1945 <modify-argument index="0" replace-value="this"/>
1937 <modify-argument index="0" replace-value="this"/>
1946 </modify-function>
1938 </modify-function>
1947
1939
1948 <modify-function signature="operator&gt;&gt;(bool &amp;)">
1940 <modify-function signature="operator&gt;&gt;(bool &amp;)">
1949 <rename to="readBoolean"/>
1941 <rename to="readBoolean"/>
1950 <modify-argument index="1">
1942 <modify-argument index="1">
1951 <remove-argument/>
1943 <remove-argument/>
1952 <conversion-rule class="native">
1944 <conversion-rule class="native">
1953 bool __result;
1945 bool __result;
1954 bool &amp; %out% = __result;
1946 bool &amp; %out% = __result;
1955 </conversion-rule>
1947 </conversion-rule>
1956 </modify-argument>
1948 </modify-argument>
1957 <modify-argument index="0" replace-value="void">
1949 <modify-argument index="0" replace-value="void">
1958 <conversion-rule class="native">
1950 <conversion-rule class="native">
1959 bool %out% = __result;
1951 bool %out% = __result;
1960 </conversion-rule>
1952 </conversion-rule>
1961 </modify-argument>
1953 </modify-argument>
1962 </modify-function>
1954 </modify-function>
1963 <modify-function signature="operator&gt;&gt;(unsigned char &amp;)">
1955 <modify-function signature="operator&gt;&gt;(unsigned char &amp;)">
1964 <rename to="readByte"/>
1956 <rename to="readByte"/>
1965 <modify-argument index="1">
1957 <modify-argument index="1">
1966 <remove-argument/>
1958 <remove-argument/>
1967 <conversion-rule class="native">
1959 <conversion-rule class="native">
1968 unsigned char __result;
1960 unsigned char __result;
1969 unsigned char &amp; %out% = __result;
1961 unsigned char &amp; %out% = __result;
1970 </conversion-rule>
1962 </conversion-rule>
1971 </modify-argument>
1963 </modify-argument>
1972 <modify-argument index="0" replace-value="void">
1964 <modify-argument index="0" replace-value="void">
1973 <conversion-rule class="native">
1965 <conversion-rule class="native">
1974 int %out% = __result;
1966 int %out% = __result;
1975 </conversion-rule>
1967 </conversion-rule>
1976 </modify-argument>
1968 </modify-argument>
1977 </modify-function>
1969 </modify-function>
1978 <modify-function signature="operator&gt;&gt;(int &amp;)">
1970 <modify-function signature="operator&gt;&gt;(int &amp;)">
1979 <rename to="readInt"/>
1971 <rename to="readInt"/>
1980 <modify-argument index="1">
1972 <modify-argument index="1">
1981 <remove-argument/>
1973 <remove-argument/>
1982 <conversion-rule class="native">
1974 <conversion-rule class="native">
1983 int __result;
1975 int __result;
1984 int &amp; %out% = __result;
1976 int &amp; %out% = __result;
1985 </conversion-rule>
1977 </conversion-rule>
1986 </modify-argument>
1978 </modify-argument>
1987 <modify-argument index="0" replace-value="void">
1979 <modify-argument index="0" replace-value="void">
1988 <conversion-rule class="native">
1980 <conversion-rule class="native">
1989 int %out% = __result;
1981 int %out% = __result;
1990 </conversion-rule>
1982 </conversion-rule>
1991 </modify-argument>
1983 </modify-argument>
1992 </modify-function>
1984 </modify-function>
1993 <modify-function signature="operator&gt;&gt;(uint &amp;)">
1985 <modify-function signature="operator&gt;&gt;(uint &amp;)">
1994 <rename to="readUInt"/>
1986 <rename to="readUInt"/>
1995 <modify-argument index="1">
1987 <modify-argument index="1">
1996 <remove-argument/>
1988 <remove-argument/>
1997 <conversion-rule class="native">
1989 <conversion-rule class="native">
1998 uint __result;
1990 uint __result;
1999 uint &amp; %out% = __result;
1991 uint &amp; %out% = __result;
2000 </conversion-rule>
1992 </conversion-rule>
2001 </modify-argument>
1993 </modify-argument>
2002 <modify-argument index="0" replace-value="void">
1994 <modify-argument index="0" replace-value="void">
2003 <conversion-rule class="native">
1995 <conversion-rule class="native">
2004 uint %out% = __result;
1996 uint %out% = __result;
2005 </conversion-rule>
1997 </conversion-rule>
2006 </modify-argument>
1998 </modify-argument>
2007 </modify-function>
1999 </modify-function>
2008 <modify-function signature="operator&gt;&gt;(qint64 &amp;)">
2000 <modify-function signature="operator&gt;&gt;(qint64 &amp;)">
2009 <rename to="readLongLong"/>
2001 <rename to="readLongLong"/>
2010 <modify-argument index="1">
2002 <modify-argument index="1">
2011 <remove-argument/>
2003 <remove-argument/>
2012 <conversion-rule class="native">
2004 <conversion-rule class="native">
2013 qint64 __result;
2005 qint64 __result;
2014 qint64 &amp; %out% = __result;
2006 qint64 &amp; %out% = __result;
2015 </conversion-rule>
2007 </conversion-rule>
2016 </modify-argument>
2008 </modify-argument>
2017 <modify-argument index="0" replace-value="void">
2009 <modify-argument index="0" replace-value="void">
2018 <conversion-rule class="native">
2010 <conversion-rule class="native">
2019 qint64 %out% = __result;
2011 qint64 %out% = __result;
2020 </conversion-rule>
2012 </conversion-rule>
2021 </modify-argument>
2013 </modify-argument>
2022 </modify-function>
2014 </modify-function>
2023 <modify-function signature="operator&gt;&gt;(unsigned long long &amp;)">
2015 <modify-function signature="operator&gt;&gt;(unsigned long long &amp;)">
2024 <rename to="readULongLong"/>
2016 <rename to="readULongLong"/>
2025 <modify-argument index="1">
2017 <modify-argument index="1">
2026 <remove-argument/>
2018 <remove-argument/>
2027 <conversion-rule class="native">
2019 <conversion-rule class="native">
2028 unsigned long long __result;
2020 unsigned long long __result;
2029 unsigned long long &amp; %out% = __result;
2021 unsigned long long &amp; %out% = __result;
2030 </conversion-rule>
2022 </conversion-rule>
2031 </modify-argument>
2023 </modify-argument>
2032 <modify-argument index="0" replace-value="void">
2024 <modify-argument index="0" replace-value="void">
2033 <conversion-rule class="native">
2025 <conversion-rule class="native">
2034 unsigned long long %out% = __result;
2026 unsigned long long %out% = __result;
2035 </conversion-rule>
2027 </conversion-rule>
2036 </modify-argument>
2028 </modify-argument>
2037 </modify-function>
2029 </modify-function>
2038 <modify-function signature="operator&gt;&gt;(float &amp;)">
2030 <modify-function signature="operator&gt;&gt;(float &amp;)">
2039 <rename to="readFloat"/>
2031 <rename to="readFloat"/>
2040 <modify-argument index="1">
2032 <modify-argument index="1">
2041 <remove-argument/>
2033 <remove-argument/>
2042 <conversion-rule class="native">
2034 <conversion-rule class="native">
2043 float __result;
2035 float __result;
2044 float &amp; %out% = __result;
2036 float &amp; %out% = __result;
2045 </conversion-rule>
2037 </conversion-rule>
2046 </modify-argument>
2038 </modify-argument>
2047 <modify-argument index="0" replace-value="void">
2039 <modify-argument index="0" replace-value="void">
2048 <conversion-rule class="native">
2040 <conversion-rule class="native">
2049 float %out% = __result;
2041 float %out% = __result;
2050 </conversion-rule>
2042 </conversion-rule>
2051 </modify-argument>
2043 </modify-argument>
2052 </modify-function>
2044 </modify-function>
2053 <modify-function signature="operator&gt;&gt;(double &amp;)">
2045 <modify-function signature="operator&gt;&gt;(double &amp;)">
2054 <rename to="readDouble"/>
2046 <rename to="readDouble"/>
2055 <modify-argument index="1">
2047 <modify-argument index="1">
2056 <remove-argument/>
2048 <remove-argument/>
2057 <conversion-rule class="native">
2049 <conversion-rule class="native">
2058 double __result;
2050 double __result;
2059 double &amp; %out% = __result;
2051 double &amp; %out% = __result;
2060 </conversion-rule>
2052 </conversion-rule>
2061 </modify-argument>
2053 </modify-argument>
2062 <modify-argument index="0" replace-value="void">
2054 <modify-argument index="0" replace-value="void">
2063 <conversion-rule class="native">
2055 <conversion-rule class="native">
2064 double %out% = __result;
2056 double %out% = __result;
2065 </conversion-rule>
2057 </conversion-rule>
2066 </modify-argument>
2058 </modify-argument>
2067 </modify-function>
2059 </modify-function>
2068 <modify-function signature="operator&gt;&gt;(short &amp;)">
2060 <modify-function signature="operator&gt;&gt;(short &amp;)">
2069 <rename to="readShort"/>
2061 <rename to="readShort"/>
2070 <modify-argument index="1">
2062 <modify-argument index="1">
2071 <remove-argument/>
2063 <remove-argument/>
2072 <conversion-rule class="native">
2064 <conversion-rule class="native">
2073 short __result;
2065 short __result;
2074 short &amp; %out% = __result;
2066 short &amp; %out% = __result;
2075 </conversion-rule>
2067 </conversion-rule>
2076 </modify-argument>
2068 </modify-argument>
2077 <modify-argument index="0" replace-value="void">
2069 <modify-argument index="0" replace-value="void">
2078 <conversion-rule class="native">
2070 <conversion-rule class="native">
2079 short %out% = __result;
2071 short %out% = __result;
2080 </conversion-rule>
2072 </conversion-rule>
2081 </modify-argument>
2073 </modify-argument>
2082 </modify-function>
2074 </modify-function>
2083 <modify-function signature="operator&gt;&gt;(unsigned short &amp;)">
2075 <modify-function signature="operator&gt;&gt;(unsigned short &amp;)">
2084 <rename to="readUShort"/>
2076 <rename to="readUShort"/>
2085 <modify-argument index="1">
2077 <modify-argument index="1">
2086 <remove-argument/>
2078 <remove-argument/>
2087 <conversion-rule class="native">
2079 <conversion-rule class="native">
2088 unsigned short __result;
2080 unsigned short __result;
2089 unsigned short &amp; %out% = __result;
2081 unsigned short &amp; %out% = __result;
2090 </conversion-rule>
2082 </conversion-rule>
2091 </modify-argument>
2083 </modify-argument>
2092 <modify-argument index="0" replace-value="void">
2084 <modify-argument index="0" replace-value="void">
2093 <conversion-rule class="native">
2085 <conversion-rule class="native">
2094 unsigned short %out% = __result;
2086 unsigned short %out% = __result;
2095 </conversion-rule>
2087 </conversion-rule>
2096 </modify-argument>
2088 </modify-argument>
2097 </modify-function>
2089 </modify-function>
2098 </object-type>
2090 </object-type>
2099
2091
2100 <object-type name="QFSFileEngine">
2092 <object-type name="QFSFileEngine">
2101 <extra-includes>
2093 <extra-includes>
2102 <include file-name="QDateTime" location="global"/>
2094 <include file-name="QDateTime" location="global"/>
2103 </extra-includes>
2095 </extra-includes>
2104 </object-type>
2096 </object-type>
2105
2097
2106 <object-type name="QTextStream">
2098 <object-type name="QTextStream">
2107 <modify-function signature="QTextStream(QByteArray *, QFlags&lt;QIODevice::OpenModeFlag&gt;)">
2099 <modify-function signature="QTextStream(QByteArray *, QFlags&lt;QIODevice::OpenModeFlag&gt;)">
2108 <remove/>
2100 <remove/>
2109 </modify-function>
2101 </modify-function>
2110 <modify-function signature="QTextStream(QString*,QFlags&lt;QIODevice::OpenModeFlag&gt;)">
2102 <modify-function signature="QTextStream(QString*,QFlags&lt;QIODevice::OpenModeFlag&gt;)">
2111 <remove/>
2103 <remove/>
2112 </modify-function>
2104 </modify-function>
2113 <modify-function signature="operator&gt;&gt;(QChar&amp;)">
2105 <modify-function signature="operator&gt;&gt;(QChar&amp;)">
2114 <remove/>
2106 <remove/>
2115 </modify-function>
2107 </modify-function>
2116 <modify-function signature="operator&lt;&lt;(const void*)">
2108 <modify-function signature="operator&lt;&lt;(const void*)">
2117 <remove/>
2109 <remove/>
2118 </modify-function>
2110 </modify-function>
2119 <modify-function signature="operator&lt;&lt;(unsigned int)">
2111 <modify-function signature="operator&lt;&lt;(unsigned int)">
2120 <remove/>
2112 <remove/>
2121 </modify-function>
2113 </modify-function>
2122 <modify-function signature="operator&lt;&lt;(qlonglong)">
2114 <modify-function signature="operator&lt;&lt;(qlonglong)">
2123 <remove/>
2115 <remove/>
2124 </modify-function>
2116 </modify-function>
2125 <modify-function signature="operator&lt;&lt;(const QChar &amp;)">
2117 <modify-function signature="operator&lt;&lt;(const QChar &amp;)">
2126 <remove/>
2118 <remove/>
2127 </modify-function>
2119 </modify-function>
2128 <modify-function signature="operator&lt;&lt;(unsigned long)">
2120 <modify-function signature="operator&lt;&lt;(unsigned long)">
2129 <remove/>
2121 <remove/>
2130 </modify-function>
2122 </modify-function>
2131 <modify-function signature="operator&lt;&lt;(signed long)">
2123 <modify-function signature="operator&lt;&lt;(signed long)">
2132 <remove/>
2124 <remove/>
2133 </modify-function>
2125 </modify-function>
2134 <modify-function signature="operator&lt;&lt;(const char*)">
2126 <modify-function signature="operator&lt;&lt;(const char*)">
2135 <remove/>
2127 <remove/>
2136 </modify-function>
2128 </modify-function>
2137 <modify-function signature="operator&lt;&lt;(unsigned short)">
2129 <modify-function signature="operator&lt;&lt;(unsigned short)">
2138 <remove/>
2130 <remove/>
2139 </modify-function>
2131 </modify-function>
2140 <modify-function signature="operator&gt;&gt;(qulonglong&amp;)">
2132 <modify-function signature="operator&gt;&gt;(qulonglong&amp;)">
2141 <remove/>
2133 <remove/>
2142 </modify-function>
2134 </modify-function>
2143 <modify-function signature="operator&gt;&gt;(ulong&amp;)">
2135 <modify-function signature="operator&gt;&gt;(ulong&amp;)">
2144 <remove/>
2136 <remove/>
2145 </modify-function>
2137 </modify-function>
2146 <modify-function signature="operator&lt;&lt;(const QLatin1String &amp;)">
2138 <modify-function signature="operator&lt;&lt;(const QLatin1String &amp;)">
2147 <remove/>
2139 <remove/>
2148 </modify-function>
2140 </modify-function>
2149 <modify-function signature="setString(QString*,QFlags&lt;QIODevice::OpenModeFlag&gt;)">
2141 <modify-function signature="setString(QString*,QFlags&lt;QIODevice::OpenModeFlag&gt;)">
2150 <remove/>
2142 <remove/>
2151 </modify-function>
2143 </modify-function>
2152 <modify-function signature="string()const">
2144 <modify-function signature="string()const">
2153 <remove/>
2145 <remove/>
2154 </modify-function>
2146 </modify-function>
2155 <modify-function signature="operator&gt;&gt;(signed long&amp;)">
2147 <modify-function signature="operator&gt;&gt;(signed long&amp;)">
2156 <remove/>
2148 <remove/>
2157 </modify-function>
2149 </modify-function>
2158 <modify-function signature="operator&gt;&gt;(char*)">
2150 <modify-function signature="operator&gt;&gt;(char*)">
2159 <remove/>
2151 <remove/>
2160 </modify-function>
2152 </modify-function>
2161 <modify-function signature="operator&gt;&gt;(QByteArray&amp;)">
2153 <modify-function signature="operator&gt;&gt;(QByteArray&amp;)">
2162 <remove/>
2154 <remove/>
2163 </modify-function>
2155 </modify-function>
2164 <modify-function signature="operator&gt;&gt;(QString&amp;)">
2156 <modify-function signature="operator&gt;&gt;(QString&amp;)">
2165 <remove/>
2157 <remove/>
2166 </modify-function>
2158 </modify-function>
2167
2159
2168
2160
2169 <modify-function signature="setCodec(QTextCodec *)">
2161 <modify-function signature="setCodec(QTextCodec *)">
2170 <modify-argument index="1">
2162 <modify-argument index="1">
2171 <reference-count action="set" variable-name="__rcCodec"/>
2163 <reference-count action="set" variable-name="__rcCodec"/>
2172 </modify-argument>
2164 </modify-argument>
2173 </modify-function>
2165 </modify-function>
2174
2166
2175 <modify-function signature="QTextStream(QIODevice *)">
2167 <modify-function signature="QTextStream(QIODevice *)">
2176 <modify-argument index="1">
2168 <modify-argument index="1">
2177 <reference-count action="set" variable-name="__rcDevice"/>
2169 <reference-count action="set" variable-name="__rcDevice"/>
2178 </modify-argument>
2170 </modify-argument>
2179 </modify-function>
2171 </modify-function>
2180 <modify-function signature="setDevice(QIODevice *)">
2172 <modify-function signature="setDevice(QIODevice *)">
2181 <modify-argument index="1">
2173 <modify-argument index="1">
2182 <reference-count action="set" variable-name="__rcDevice"/>
2174 <reference-count action="set" variable-name="__rcDevice"/>
2183 </modify-argument>
2175 </modify-argument>
2184 </modify-function>
2176 </modify-function>
2185
2177
2186 <modify-function signature="setCodec(const char *)">
2178 <modify-function signature="setCodec(const char *)">
2187 <modify-argument index="1">
2179 <modify-argument index="1">
2188 <replace-type modified-type="QString"/>
2180 <replace-type modified-type="QString"/>
2189 <conversion-rule class="native">
2181 <conversion-rule class="native">
2190 <insert-template name="core.convert_string_arg_to_char*"/>
2182 <insert-template name="core.convert_string_arg_to_char*"/>
2191 </conversion-rule>
2183 </conversion-rule>
2192 </modify-argument>
2184 </modify-argument>
2193 </modify-function>
2185 </modify-function>
2194
2186
2195 <modify-function signature="operator&lt;&lt;(QBool)">
2187 <modify-function signature="operator&lt;&lt;(QBool)">
2196 <rename to="writeBoolean"/>
2188 <rename to="writeBoolean"/>
2197 <modify-argument index="0" replace-value="this"/>
2189 <modify-argument index="0" replace-value="this"/>
2198 </modify-function>
2190 </modify-function>
2199 <modify-function signature="operator&lt;&lt;(char)">
2191 <modify-function signature="operator&lt;&lt;(char)">
2200 <modify-argument index="0" replace-value="this"/>
2192 <modify-argument index="0" replace-value="this"/>
2201 <rename to="writeByte"/>
2193 <rename to="writeByte"/>
2202 </modify-function>
2194 </modify-function>
2203 <modify-function signature="operator&lt;&lt;(signed int)">
2195 <modify-function signature="operator&lt;&lt;(signed int)">
2204 <rename to="writeInt"/>
2196 <rename to="writeInt"/>
2205 <modify-argument index="0" replace-value="this"/>
2197 <modify-argument index="0" replace-value="this"/>
2206 </modify-function>
2198 </modify-function>
2207 <modify-function signature="operator&lt;&lt;(qlonglong)">
2199 <modify-function signature="operator&lt;&lt;(qlonglong)">
2208 <rename to="writeLongLong"/>
2200 <rename to="writeLongLong"/>
2209 <modify-argument index="0" replace-value="this"/>
2201 <modify-argument index="0" replace-value="this"/>
2210 </modify-function>
2202 </modify-function>
2211 <modify-function signature="operator&lt;&lt;(float)">
2203 <modify-function signature="operator&lt;&lt;(float)">
2212 <rename to="writeFloat"/>
2204 <rename to="writeFloat"/>
2213 <modify-argument index="0" replace-value="this"/>
2205 <modify-argument index="0" replace-value="this"/>
2214 </modify-function>
2206 </modify-function>
2215 <modify-function signature="operator&lt;&lt;(double)">
2207 <modify-function signature="operator&lt;&lt;(double)">
2216 <rename to="writeDouble"/>
2208 <rename to="writeDouble"/>
2217 <modify-argument index="0" replace-value="this"/>
2209 <modify-argument index="0" replace-value="this"/>
2218 </modify-function>
2210 </modify-function>
2219 <modify-function signature="operator&lt;&lt;(signed short)">
2211 <modify-function signature="operator&lt;&lt;(signed short)">
2220 <rename to="writeShort"/>
2212 <rename to="writeShort"/>
2221 <modify-argument index="0" replace-value="this"/>
2213 <modify-argument index="0" replace-value="this"/>
2222 </modify-function>
2214 </modify-function>
2223 <modify-function signature="operator&lt;&lt;(const QByteArray&amp;)">
2215 <modify-function signature="operator&lt;&lt;(const QByteArray&amp;)">
2224 <rename to="writeByteArray"/>
2216 <rename to="writeByteArray"/>
2225 <modify-argument index="0" replace-value="this"/>
2217 <modify-argument index="0" replace-value="this"/>
2226 </modify-function>
2218 </modify-function>
2227 <modify-function signature="operator&lt;&lt;(const QString&amp;)">
2219 <modify-function signature="operator&lt;&lt;(const QString&amp;)">
2228 <rename to="writeString"/>
2220 <rename to="writeString"/>
2229 <modify-argument index="0" replace-value="this"/>
2221 <modify-argument index="0" replace-value="this"/>
2230 </modify-function>
2222 </modify-function>
2231
2223
2232 <modify-function signature="operator&gt;&gt;(char&amp;)">
2224 <modify-function signature="operator&gt;&gt;(char&amp;)">
2233 <rename to="readByte"/>
2225 <rename to="readByte"/>
2234 <modify-argument index="1">
2226 <modify-argument index="1">
2235 <remove-argument/>
2227 <remove-argument/>
2236 <conversion-rule class="native">
2228 <conversion-rule class="native">
2237 char __result;
2229 char __result;
2238 char &amp; %out% = __result;
2230 char &amp; %out% = __result;
2239 </conversion-rule>
2231 </conversion-rule>
2240 </modify-argument>
2232 </modify-argument>
2241 <modify-argument index="0" replace-value="void">
2233 <modify-argument index="0" replace-value="void">
2242 <conversion-rule class="native">
2234 <conversion-rule class="native">
2243 int %out% = __result;
2235 int %out% = __result;
2244 </conversion-rule>
2236 </conversion-rule>
2245 </modify-argument>
2237 </modify-argument>
2246 </modify-function>
2238 </modify-function>
2247 <modify-function signature="operator&gt;&gt;(signed short&amp;)">
2239 <modify-function signature="operator&gt;&gt;(signed short&amp;)">
2248 <rename to="readShort"/>
2240 <rename to="readShort"/>
2249 <modify-argument index="1">
2241 <modify-argument index="1">
2250 <remove-argument/>
2242 <remove-argument/>
2251 <conversion-rule class="native">
2243 <conversion-rule class="native">
2252 short __result;
2244 short __result;
2253 short &amp; %out% = __result;
2245 short &amp; %out% = __result;
2254 </conversion-rule>
2246 </conversion-rule>
2255 </modify-argument>
2247 </modify-argument>
2256 <modify-argument index="0" replace-value="void">
2248 <modify-argument index="0" replace-value="void">
2257 <conversion-rule class="native">
2249 <conversion-rule class="native">
2258 short %out% = __result;
2250 short %out% = __result;
2259 </conversion-rule>
2251 </conversion-rule>
2260 </modify-argument>
2252 </modify-argument>
2261 </modify-function>
2253 </modify-function>
2262 <modify-function signature="operator&gt;&gt;(signed int&amp;)">
2254 <modify-function signature="operator&gt;&gt;(signed int&amp;)">
2263 <rename to="readInt"/>
2255 <rename to="readInt"/>
2264 <modify-argument index="1">
2256 <modify-argument index="1">
2265 <remove-argument/>
2257 <remove-argument/>
2266 <conversion-rule class="native">
2258 <conversion-rule class="native">
2267 int __result;
2259 int __result;
2268 int &amp; %out% = __result;
2260 int &amp; %out% = __result;
2269 </conversion-rule>
2261 </conversion-rule>
2270 </modify-argument>
2262 </modify-argument>
2271 <modify-argument index="0" replace-value="void">
2263 <modify-argument index="0" replace-value="void">
2272 <conversion-rule class="native">
2264 <conversion-rule class="native">
2273 int %out% = __result;
2265 int %out% = __result;
2274 </conversion-rule>
2266 </conversion-rule>
2275 </modify-argument>
2267 </modify-argument>
2276 </modify-function>
2268 </modify-function>
2277 <modify-function signature="operator&gt;&gt;(unsigned short&amp;)">
2269 <modify-function signature="operator&gt;&gt;(unsigned short&amp;)">
2278 <rename to="readUShort"/>
2270 <rename to="readUShort"/>
2279 <modify-argument index="1">
2271 <modify-argument index="1">
2280 <remove-argument/>
2272 <remove-argument/>
2281 <conversion-rule class="native">
2273 <conversion-rule class="native">
2282 unsigned short __result;
2274 unsigned short __result;
2283 unsigned short &amp; %out% = __result;
2275 unsigned short &amp; %out% = __result;
2284 </conversion-rule>
2276 </conversion-rule>
2285 </modify-argument>
2277 </modify-argument>
2286 <modify-argument index="0" replace-value="void">
2278 <modify-argument index="0" replace-value="void">
2287 <conversion-rule class="native">
2279 <conversion-rule class="native">
2288 unsigned short %out% = __result;
2280 unsigned short %out% = __result;
2289 </conversion-rule>
2281 </conversion-rule>
2290 </modify-argument>
2282 </modify-argument>
2291 </modify-function>
2283 </modify-function>
2292 <modify-function signature="operator&gt;&gt;(unsigned int&amp;)">
2284 <modify-function signature="operator&gt;&gt;(unsigned int&amp;)">
2293 <rename to="readUInt"/>
2285 <rename to="readUInt"/>
2294 <modify-argument index="1">
2286 <modify-argument index="1">
2295 <remove-argument/>
2287 <remove-argument/>
2296 <conversion-rule class="native">
2288 <conversion-rule class="native">
2297 unsigned int __result;
2289 unsigned int __result;
2298 unsigned int &amp; %out% = __result;
2290 unsigned int &amp; %out% = __result;
2299 </conversion-rule>
2291 </conversion-rule>
2300 </modify-argument>
2292 </modify-argument>
2301 <modify-argument index="0" replace-value="void">
2293 <modify-argument index="0" replace-value="void">
2302 <conversion-rule class="native">
2294 <conversion-rule class="native">
2303 unsigned int %out% = __result;
2295 unsigned int %out% = __result;
2304 </conversion-rule>
2296 </conversion-rule>
2305 </modify-argument>
2297 </modify-argument>
2306 </modify-function>
2298 </modify-function>
2307 <modify-function signature="operator&gt;&gt;(qlonglong&amp;)">
2299 <modify-function signature="operator&gt;&gt;(qlonglong&amp;)">
2308 <rename to="readLongLong"/>
2300 <rename to="readLongLong"/>
2309 <modify-argument index="1">
2301 <modify-argument index="1">
2310 <remove-argument/>
2302 <remove-argument/>
2311 <conversion-rule class="native">
2303 <conversion-rule class="native">
2312 qlonglong __result;
2304 qlonglong __result;
2313 qlonglong &amp; %out% = __result;
2305 qlonglong &amp; %out% = __result;
2314 </conversion-rule>
2306 </conversion-rule>
2315 </modify-argument>
2307 </modify-argument>
2316 <modify-argument index="0" replace-value="void">
2308 <modify-argument index="0" replace-value="void">
2317 <conversion-rule class="native">
2309 <conversion-rule class="native">
2318 qlonglong %out% = __result;
2310 qlonglong %out% = __result;
2319 </conversion-rule>
2311 </conversion-rule>
2320 </modify-argument>
2312 </modify-argument>
2321 </modify-function>
2313 </modify-function>
2322 <modify-function signature="operator&gt;&gt;(qulonglong&amp;)">
2314 <modify-function signature="operator&gt;&gt;(qulonglong&amp;)">
2323 <rename to="readULongLong"/>
2315 <rename to="readULongLong"/>
2324 <modify-argument index="1">
2316 <modify-argument index="1">
2325 <remove-argument/>
2317 <remove-argument/>
2326 <conversion-rule class="native">
2318 <conversion-rule class="native">
2327 qulonglong __result;
2319 qulonglong __result;
2328 qulonglong &amp; %out% = __result;
2320 qulonglong &amp; %out% = __result;
2329 </conversion-rule>
2321 </conversion-rule>
2330 </modify-argument>
2322 </modify-argument>
2331 <modify-argument index="0" replace-value="void">
2323 <modify-argument index="0" replace-value="void">
2332 <conversion-rule class="native">
2324 <conversion-rule class="native">
2333 qulonglong %out% = __result;
2325 qulonglong %out% = __result;
2334 </conversion-rule>
2326 </conversion-rule>
2335 </modify-argument>
2327 </modify-argument>
2336 </modify-function>
2328 </modify-function>
2337 <modify-function signature="operator&gt;&gt;(float&amp;)">
2329 <modify-function signature="operator&gt;&gt;(float&amp;)">
2338 <rename to="readFloat"/>
2330 <rename to="readFloat"/>
2339 <modify-argument index="1">
2331 <modify-argument index="1">
2340 <remove-argument/>
2332 <remove-argument/>
2341 <conversion-rule class="native">
2333 <conversion-rule class="native">
2342 float __result;
2334 float __result;
2343 float &amp; %out% = __result;
2335 float &amp; %out% = __result;
2344 </conversion-rule>
2336 </conversion-rule>
2345 </modify-argument>
2337 </modify-argument>
2346 <modify-argument index="0" replace-value="void">
2338 <modify-argument index="0" replace-value="void">
2347 <conversion-rule class="native">
2339 <conversion-rule class="native">
2348 float %out% = __result;
2340 float %out% = __result;
2349 </conversion-rule>
2341 </conversion-rule>
2350 </modify-argument>
2342 </modify-argument>
2351 </modify-function>
2343 </modify-function>
2352 <modify-function signature="operator&gt;&gt;(double&amp;)">
2344 <modify-function signature="operator&gt;&gt;(double&amp;)">
2353 <rename to="readDouble"/>
2345 <rename to="readDouble"/>
2354 <modify-argument index="1">
2346 <modify-argument index="1">
2355 <remove-argument/>
2347 <remove-argument/>
2356 <conversion-rule class="native">
2348 <conversion-rule class="native">
2357 double __result;
2349 double __result;
2358 double &amp; %out% = __result;
2350 double &amp; %out% = __result;
2359 </conversion-rule>
2351 </conversion-rule>
2360 </modify-argument>
2352 </modify-argument>
2361 <modify-argument index="0" replace-value="void">
2353 <modify-argument index="0" replace-value="void">
2362 <conversion-rule class="native">
2354 <conversion-rule class="native">
2363 double %out% = __result;
2355 double %out% = __result;
2364 </conversion-rule>
2356 </conversion-rule>
2365 </modify-argument>
2357 </modify-argument>
2366 </modify-function>
2358 </modify-function>
2367
2359
2368 <modify-function signature="operator&lt;&lt;(qulonglong)" remove="all"/>
2360 <modify-function signature="operator&lt;&lt;(qulonglong)" remove="all"/>
2369 <modify-function signature="operator&gt;&gt;(qulonglong&amp;)" remove="all"/>
2361 <modify-function signature="operator&gt;&gt;(qulonglong&amp;)" remove="all"/>
2370 </object-type>
2362 </object-type>
2371
2363
2372 <object-type name="QSystemSemaphore"/>
2364 <object-type name="QSystemSemaphore"/>
2373
2365
2374 <namespace-type name="QtConcurrent" target-type="class">
2366 <namespace-type name="QtConcurrent" target-type="class">
2375 <extra-includes>
2367 <extra-includes>
2376 <include file-name="qtconcurrentreducekernel.h" location="global"/>
2368 <include file-name="qtconcurrentreducekernel.h" location="global"/>
2377 <include file-name="qtconcurrentthreadengine.h" location="global"/>
2369 <include file-name="qtconcurrentthreadengine.h" location="global"/>
2378 </extra-includes>
2370 </extra-includes>
2379 </namespace-type>
2371 </namespace-type>
2380
2372
2381 <value-type name="QFuture" generate="no">
2373 <value-type name="QFuture" generate="no">
2382 <modify-function signature="operator T() const" remove="all"/>
2374 <modify-function signature="operator T() const" remove="all"/>
2383 <modify-function signature="operator=(const QFuture &amp;)" remove="all"/>
2375 <modify-function signature="operator=(const QFuture &amp;)" remove="all"/>
2384 </value-type>
2376 </value-type>
2385 <value-type name="QtScriptVoidFuture" java-name="QFutureVoid">
2377 <value-type name="QtScriptVoidFuture" java-name="QFutureVoid">
2386 <modify-function signature="resultCount()const" remove="all"/>
2378 <modify-function signature="resultCount()const" remove="all"/>
2387 <modify-function signature="isResultReadyAt(int)const" remove="all"/>
2379 <modify-function signature="isResultReadyAt(int)const" remove="all"/>
2388
2380
2389 <modify-function signature="operator==(const QFuture &amp;)const">
2381 <modify-function signature="operator==(const QFuture &amp;)const">
2390 <modify-argument index="1">
2382 <modify-argument index="1">
2391 <replace-type modified-type="QtScriptVoidFuture*"/>
2383 <replace-type modified-type="QtScriptVoidFuture*"/>
2392 <conversion-rule class="native">
2384 <conversion-rule class="native">
2393 const QtScriptVoidFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptVoidFuture*&gt;(%in%);
2385 const QtScriptVoidFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptVoidFuture*&gt;(%in%);
2394 </conversion-rule>
2386 </conversion-rule>
2395 </modify-argument>
2387 </modify-argument>
2396 </modify-function>
2388 </modify-function>
2397 <modify-function signature="QFuture(const QFuture &amp;)">
2389 <modify-function signature="QFuture(const QFuture &amp;)">
2398 <modify-argument index="1">
2390 <modify-argument index="1">
2399 <replace-type modified-type="QtScriptVoidFuture*"/>
2391 <replace-type modified-type="QtScriptVoidFuture*"/>
2400 <conversion-rule class="native">
2392 <conversion-rule class="native">
2401 const QtScriptVoidFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptVoidFuture*&gt;(%in%);
2393 const QtScriptVoidFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptVoidFuture*&gt;(%in%);
2402 </conversion-rule>
2394 </conversion-rule>
2403 </modify-argument>
2395 </modify-argument>
2404 </modify-function>
2396 </modify-function>
2405 </value-type>
2397 </value-type>
2406 <value-type name="QtScriptFuture" java-name="QFuture" generic-class="yes">
2398 <value-type name="QtScriptFuture" java-name="QFuture" generic-class="yes">
2407 <modify-function signature="operator==(const QFuture &amp;)const">
2399 <modify-function signature="operator==(const QFuture &amp;)const">
2408 <modify-argument index="1">
2400 <modify-argument index="1">
2409 <replace-type modified-type="QtScriptFuture*"/>
2401 <replace-type modified-type="QtScriptFuture*"/>
2410 <conversion-rule class="native">
2402 <conversion-rule class="native">
2411 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2403 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2412 </conversion-rule>
2404 </conversion-rule>
2413 </modify-argument>
2405 </modify-argument>
2414 </modify-function>
2406 </modify-function>
2415 <modify-function signature="QFuture(const QFuture &amp;)">
2407 <modify-function signature="QFuture(const QFuture &amp;)">
2416 <modify-argument index="1">
2408 <modify-argument index="1">
2417 <replace-type modified-type="QtScriptFuture"/>
2409 <replace-type modified-type="QtScriptFuture"/>
2418 <conversion-rule class="native">
2410 <conversion-rule class="native">
2419 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2411 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2420 </conversion-rule>
2412 </conversion-rule>
2421 </modify-argument>
2413 </modify-argument>
2422 </modify-function>
2414 </modify-function>
2423 <inject-code class="native">
2415 <inject-code class="native">
2424 </inject-code>
2416 </inject-code>
2425 </value-type>
2417 </value-type>
2426
2418
2427 <object-type name="QFutureWatcherBase">
2419 <object-type name="QFutureWatcherBase">
2428 <modify-function signature="connectNotify(const char *)" remove="all"/>
2420 <modify-function signature="connectNotify(const char *)" remove="all"/>
2429 <modify-function signature="disconnectNotify(const char *)" remove="all"/>
2421 <modify-function signature="disconnectNotify(const char *)" remove="all"/>
2430 </object-type>
2422 </object-type>
2431 <object-type name="QtScriptVoidFutureWatcher" java-name="QFutureWatcherVoid">
2423 <object-type name="QtScriptVoidFutureWatcher" java-name="QFutureWatcherVoid">
2432 <modify-function signature="setFuture(const QFuture &amp;)">
2424 <modify-function signature="setFuture(const QFuture &amp;)">
2433 <modify-argument index="1">
2425 <modify-argument index="1">
2434 <replace-type modified-type="QtScriptVoidFuture*"/>
2426 <replace-type modified-type="QtScriptVoidFuture*"/>
2435 <conversion-rule class="native">
2427 <conversion-rule class="native">
2436 const QtScriptVoidFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptVoidFuture*&gt;(%in%);
2428 const QtScriptVoidFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptVoidFuture*&gt;(%in%);
2437 </conversion-rule>
2429 </conversion-rule>
2438 </modify-argument>
2430 </modify-argument>
2439 </modify-function>
2431 </modify-function>
2440 </object-type>
2432 </object-type>
2441
2433
2442 <object-type name="QFutureWatcher" generate="no">
2434 <object-type name="QFutureWatcher" generate="no">
2443 <modify-function signature="future()const" remove="all"/>
2435 <modify-function signature="future()const" remove="all"/>
2444 </object-type>
2436 </object-type>
2445 <object-type name="QtScriptFutureWatcher" java-name="QFutureWatcher" generic-class="yes">
2437 <object-type name="QtScriptFutureWatcher" java-name="QFutureWatcher" generic-class="yes">
2446 <modify-function signature="setFuture(const QFuture &amp;)">
2438 <modify-function signature="setFuture(const QFuture &amp;)">
2447 <modify-argument index="1">
2439 <modify-argument index="1">
2448 <replace-type modified-type="QtScriptFuture*"/>
2440 <replace-type modified-type="QtScriptFuture*"/>
2449 <conversion-rule class="native">
2441 <conversion-rule class="native">
2450 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2442 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2451 </conversion-rule>
2443 </conversion-rule>
2452 </modify-argument>
2444 </modify-argument>
2453 </modify-function>
2445 </modify-function>
2454 </object-type>
2446 </object-type>
2455
2447
2456 <object-type name="QFutureSynchronizer" generate="no"/>
2448 <object-type name="QFutureSynchronizer" generate="no"/>
2457 <object-type name="QtScriptFutureSynchronizer" generic-class="yes" java-name="QFutureSynchronizer">
2449 <object-type name="QtScriptFutureSynchronizer" generic-class="yes" java-name="QFutureSynchronizer">
2458 <modify-function signature="QFutureSynchronizer(const QFuture &amp;)">
2450 <modify-function signature="QFutureSynchronizer(const QFuture &amp;)">
2459 <modify-argument index="1">
2451 <modify-argument index="1">
2460 <replace-type modified-type="QtScriptFuture*"/>
2452 <replace-type modified-type="QtScriptFuture*"/>
2461 <conversion-rule class="native">
2453 <conversion-rule class="native">
2462 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2454 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2463 </conversion-rule>
2455 </conversion-rule>
2464 </modify-argument>
2456 </modify-argument>
2465 </modify-function>
2457 </modify-function>
2466 <modify-function signature="addFuture(const QFuture &amp;)">
2458 <modify-function signature="addFuture(const QFuture &amp;)">
2467 <modify-argument index="1">
2459 <modify-argument index="1">
2468 <replace-type modified-type="QtScriptFuture*"/>
2460 <replace-type modified-type="QtScriptFuture*"/>
2469 <conversion-rule class="native">
2461 <conversion-rule class="native">
2470 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2462 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2471 </conversion-rule>
2463 </conversion-rule>
2472 </modify-argument>
2464 </modify-argument>
2473 </modify-function>
2465 </modify-function>
2474 <modify-function signature="setFuture(const QFuture &amp;)">
2466 <modify-function signature="setFuture(const QFuture &amp;)">
2475 <modify-argument index="1">
2467 <modify-argument index="1">
2476 <replace-type modified-type="QtScriptFuture*"/>
2468 <replace-type modified-type="QtScriptFuture*"/>
2477 <conversion-rule class="native">
2469 <conversion-rule class="native">
2478 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2470 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2479 </conversion-rule>
2471 </conversion-rule>
2480 </modify-argument>
2472 </modify-argument>
2481 </modify-function>
2473 </modify-function>
2482 <modify-function signature="futures()const" remove="all"/>
2474 <modify-function signature="futures()const" remove="all"/>
2483 </object-type>
2475 </object-type>
2484 <object-type name="QtScriptVoidFutureSynchronizer" java-name="QFutureSynchronizerVoid">
2476 <object-type name="QtScriptVoidFutureSynchronizer" java-name="QFutureSynchronizerVoid">
2485 <modify-function signature="QFutureSynchronizer(const QFuture &amp;)">
2477 <modify-function signature="QFutureSynchronizer(const QFuture &amp;)">
2486 <modify-argument index="1">
2478 <modify-argument index="1">
2487 <replace-type modified-type="QtScriptVoidFuture*"/>
2479 <replace-type modified-type="QtScriptVoidFuture*"/>
2488 <conversion-rule class="native">
2480 <conversion-rule class="native">
2489 const QtScriptVoidFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptVoidFuture*&gt;(%in%);
2481 const QtScriptVoidFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptVoidFuture*&gt;(%in%);
2490 </conversion-rule>
2482 </conversion-rule>
2491 </modify-argument>
2483 </modify-argument>
2492 </modify-function>
2484 </modify-function>
2493 <modify-function signature="addFuture(const QFuture &amp;)">
2485 <modify-function signature="addFuture(const QFuture &amp;)">
2494 <modify-argument index="1">
2486 <modify-argument index="1">
2495 <replace-type modified-type="QtScriptVoidFuture*"/>
2487 <replace-type modified-type="QtScriptVoidFuture*"/>
2496 <conversion-rule class="native">
2488 <conversion-rule class="native">
2497 const QtScriptVoidFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptVoidFuture*&gt;(%in%);
2489 const QtScriptVoidFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptVoidFuture*&gt;(%in%);
2498 </conversion-rule>
2490 </conversion-rule>
2499 </modify-argument>
2491 </modify-argument>
2500 </modify-function>
2492 </modify-function>
2501 <modify-function signature="setFuture(const QFuture &amp;)">
2493 <modify-function signature="setFuture(const QFuture &amp;)">
2502 <modify-argument index="1">
2494 <modify-argument index="1">
2503 <replace-type modified-type="QtScriptVoidFuture*"/>
2495 <replace-type modified-type="QtScriptVoidFuture*"/>
2504 <conversion-rule class="native">
2496 <conversion-rule class="native">
2505 const QtScriptVoidFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptVoidFuture*&gt;(%in%);
2497 const QtScriptVoidFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptVoidFuture*&gt;(%in%);
2506 </conversion-rule>
2498 </conversion-rule>
2507 </modify-argument>
2499 </modify-argument>
2508 </modify-function>
2500 </modify-function>
2509 <modify-function signature="futures()const" remove="all"/>
2501 <modify-function signature="futures()const" remove="all"/>
2510 </object-type>
2502 </object-type>
2511 <object-type name="QThreadPool"/>
2503 <object-type name="QThreadPool"/>
2512
2504
2513 <object-type name="QFutureIterator" generate="no">
2505 <object-type name="QFutureIterator" generate="no">
2514 <modify-function signature="operator=(const QFuture&amp;)" remove="all"/>
2506 <modify-function signature="operator=(const QFuture&amp;)" remove="all"/>
2515 </object-type>
2507 </object-type>
2516 <object-type name="QtScriptFutureIterator" generic-class="yes" java-name="QFutureIterator">
2508 <object-type name="QtScriptFutureIterator" generic-class="yes" java-name="QFutureIterator">
2517 <modify-function signature="QFutureIterator(const QFuture &amp;)">
2509 <modify-function signature="QFutureIterator(const QFuture &amp;)">
2518 <modify-argument index="1">
2510 <modify-argument index="1">
2519 <replace-type modified-type="QtScriptFuture*"/>
2511 <replace-type modified-type="QtScriptFuture*"/>
2520 <conversion-rule class="native">
2512 <conversion-rule class="native">
2521 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2513 const QtScriptFuture &amp; %out% = *qscriptvalue_cast&lt;QtScriptFuture*&gt;(%in%);
2522 </conversion-rule>
2514 </conversion-rule>
2523 </modify-argument>
2515 </modify-argument>
2524 </modify-function>
2516 </modify-function>
2525 </object-type>
2517 </object-type>
2526 <object-type name="QRunnable"/>
2518 <object-type name="QRunnable"/>
2527
2519
2528
2520
2529 <value-type name="QXmlStreamAttribute">
2521 <value-type name="QXmlStreamAttribute">
2530 <modify-function signature="operator=(QXmlStreamAttribute)" remove="all"/>
2522 <modify-function signature="operator=(QXmlStreamAttribute)" remove="all"/>
2531
2523
2532 <modify-function signature="name()const">
2524 <modify-function signature="name()const">
2533 <modify-argument index="return">
2525 <modify-argument index="return">
2534 <conversion-rule class="native">
2526 <conversion-rule class="native">
2535 <insert-template name="core.convert_stringref_to_string"/>
2527 <insert-template name="core.convert_stringref_to_string"/>
2536 </conversion-rule>
2528 </conversion-rule>
2537 </modify-argument>
2529 </modify-argument>
2538 </modify-function>
2530 </modify-function>
2539
2531
2540 <modify-function signature="namespaceUri()const">
2532 <modify-function signature="namespaceUri()const">
2541 <modify-argument index="return">
2533 <modify-argument index="return">
2542 <conversion-rule class="native">
2534 <conversion-rule class="native">
2543 <insert-template name="core.convert_stringref_to_string"/>
2535 <insert-template name="core.convert_stringref_to_string"/>
2544 </conversion-rule>
2536 </conversion-rule>
2545 </modify-argument>
2537 </modify-argument>
2546 </modify-function>
2538 </modify-function>
2547
2539
2548 <modify-function signature="prefix()const">
2540 <modify-function signature="prefix()const">
2549 <modify-argument index="return">
2541 <modify-argument index="return">
2550 <conversion-rule class="native">
2542 <conversion-rule class="native">
2551 <insert-template name="core.convert_stringref_to_string"/>
2543 <insert-template name="core.convert_stringref_to_string"/>
2552 </conversion-rule>
2544 </conversion-rule>
2553 </modify-argument>
2545 </modify-argument>
2554 </modify-function>
2546 </modify-function>
2555
2547
2556 <modify-function signature="qualifiedName()const">
2548 <modify-function signature="qualifiedName()const">
2557 <modify-argument index="return">
2549 <modify-argument index="return">
2558 <conversion-rule class="native">
2550 <conversion-rule class="native">
2559 <insert-template name="core.convert_stringref_to_string"/>
2551 <insert-template name="core.convert_stringref_to_string"/>
2560 </conversion-rule>
2552 </conversion-rule>
2561 </modify-argument>
2553 </modify-argument>
2562 </modify-function>
2554 </modify-function>
2563
2555
2564 <modify-function signature="value()const">
2556 <modify-function signature="value()const">
2565 <modify-argument index="return">
2557 <modify-argument index="return">
2566 <conversion-rule class="native">
2558 <conversion-rule class="native">
2567 <insert-template name="core.convert_stringref_to_string"/>
2559 <insert-template name="core.convert_stringref_to_string"/>
2568 </conversion-rule>
2560 </conversion-rule>
2569 </modify-argument>
2561 </modify-argument>
2570 </modify-function>
2562 </modify-function>
2571
2563
2572 </value-type>
2564 </value-type>
2573 <value-type name="QXmlStreamAttributes">
2565 <value-type name="QXmlStreamAttributes">
2574 <modify-function signature="operator+(QVector&lt;QXmlStreamAttribute&gt;)const" remove="all"/>
2566 <modify-function signature="operator+(QVector&lt;QXmlStreamAttribute&gt;)const" remove="all"/>
2575 <modify-function signature="operator&lt;&lt;(QVector&lt;QXmlStreamAttribute&gt;)" remove="all"/>
2567 <modify-function signature="operator&lt;&lt;(QVector&lt;QXmlStreamAttribute&gt;)" remove="all"/>
2576 <modify-function signature="operator&lt;&lt;(QXmlStreamAttribute)" remove="all"/>
2568 <modify-function signature="operator&lt;&lt;(QXmlStreamAttribute)" remove="all"/>
2577 <modify-function signature="push_back(QXmlStreamAttribute)" remove="all"/>
2569 <modify-function signature="push_back(QXmlStreamAttribute)" remove="all"/>
2578 <modify-function signature="pop_back()" remove="all"/>
2570 <modify-function signature="pop_back()" remove="all"/>
2579 <modify-function signature="push_front(QXmlStreamAttribute)" remove="all"/>
2571 <modify-function signature="push_front(QXmlStreamAttribute)" remove="all"/>
2580 <modify-function signature="pop_front()" remove="all"/>
2572 <modify-function signature="pop_front()" remove="all"/>
2581
2573
2582 <modify-function signature="value(const QString &amp;, const QLatin1String &amp;)const">
2574 <modify-function signature="value(const QString &amp;, const QLatin1String &amp;)const">
2583 <remove/>
2575 <remove/>
2584 </modify-function>
2576 </modify-function>
2585 <modify-function signature="value(const QLatin1String &amp;, const QLatin1String &amp;)const">
2577 <modify-function signature="value(const QLatin1String &amp;, const QLatin1String &amp;)const">
2586 <remove/>
2578 <remove/>
2587 </modify-function>
2579 </modify-function>
2588 <modify-function signature="value(const QLatin1String &amp;)const">
2580 <modify-function signature="value(const QLatin1String &amp;)const">
2589 <remove/>
2581 <remove/>
2590 </modify-function>
2582 </modify-function>
2591 <modify-function signature="hasAttribute(const QLatin1String &amp;)const">
2583 <modify-function signature="hasAttribute(const QLatin1String &amp;)const">
2592 <remove/>
2584 <remove/>
2593 </modify-function>
2585 </modify-function>
2594
2586
2595
2587
2596 <modify-function signature="value(QString,QString)const">
2588 <modify-function signature="value(QString,QString)const">
2597 <modify-argument index="return">
2589 <modify-argument index="return">
2598 <conversion-rule class="native">
2590 <conversion-rule class="native">
2599 <insert-template name="core.convert_stringref_to_string"/>
2591 <insert-template name="core.convert_stringref_to_string"/>
2600 </conversion-rule>
2592 </conversion-rule>
2601 </modify-argument>
2593 </modify-argument>
2602 </modify-function>
2594 </modify-function>
2603
2595
2604 <modify-function signature="value(QString)const">
2596 <modify-function signature="value(QString)const">
2605 <modify-argument index="return">
2597 <modify-argument index="return">
2606 <conversion-rule class="native">
2598 <conversion-rule class="native">
2607 <insert-template name="core.convert_stringref_to_string"/>
2599 <insert-template name="core.convert_stringref_to_string"/>
2608 </conversion-rule>
2600 </conversion-rule>
2609 </modify-argument>
2601 </modify-argument>
2610 </modify-function>
2602 </modify-function>
2611
2603
2612 </value-type>
2604 </value-type>
2613 <value-type name="QXmlStreamNamespaceDeclaration">
2605 <value-type name="QXmlStreamNamespaceDeclaration">
2614 <modify-function signature="operator=(QXmlStreamNamespaceDeclaration)" remove="all"/>
2606 <modify-function signature="operator=(QXmlStreamNamespaceDeclaration)" remove="all"/>
2615
2607
2616 <modify-function signature="namespaceUri()const">
2608 <modify-function signature="namespaceUri()const">
2617 <modify-argument index="return">
2609 <modify-argument index="return">
2618 <conversion-rule class="native">
2610 <conversion-rule class="native">
2619 <insert-template name="core.convert_stringref_to_string"/>
2611 <insert-template name="core.convert_stringref_to_string"/>
2620 </conversion-rule>
2612 </conversion-rule>
2621 </modify-argument>
2613 </modify-argument>
2622 </modify-function>
2614 </modify-function>
2623
2615
2624 <modify-function signature="prefix()const">
2616 <modify-function signature="prefix()const">
2625 <modify-argument index="return">
2617 <modify-argument index="return">
2626 <conversion-rule class="native">
2618 <conversion-rule class="native">
2627 <insert-template name="core.convert_stringref_to_string"/>
2619 <insert-template name="core.convert_stringref_to_string"/>
2628 </conversion-rule>
2620 </conversion-rule>
2629 </modify-argument>
2621 </modify-argument>
2630 </modify-function>
2622 </modify-function>
2631
2623
2632 </value-type>
2624 </value-type>
2633 <value-type name="QXmlStreamNotationDeclaration">
2625 <value-type name="QXmlStreamNotationDeclaration">
2634 <modify-function signature="operator=(QXmlStreamNotationDeclaration)" remove="all"/>
2626 <modify-function signature="operator=(QXmlStreamNotationDeclaration)" remove="all"/>
2635
2627
2636 <modify-function signature="name()const">
2628 <modify-function signature="name()const">
2637 <modify-argument index="return">
2629 <modify-argument index="return">
2638 <conversion-rule class="native">
2630 <conversion-rule class="native">
2639 <insert-template name="core.convert_stringref_to_string"/>
2631 <insert-template name="core.convert_stringref_to_string"/>
2640 </conversion-rule>
2632 </conversion-rule>
2641 </modify-argument>
2633 </modify-argument>
2642 </modify-function>
2634 </modify-function>
2643
2635
2644 <modify-function signature="publicId()const">
2636 <modify-function signature="publicId()const">
2645 <modify-argument index="return">
2637 <modify-argument index="return">
2646 <conversion-rule class="native">
2638 <conversion-rule class="native">
2647 <insert-template name="core.convert_stringref_to_string"/>
2639 <insert-template name="core.convert_stringref_to_string"/>
2648 </conversion-rule>
2640 </conversion-rule>
2649 </modify-argument>
2641 </modify-argument>
2650 </modify-function>
2642 </modify-function>
2651
2643
2652 <modify-function signature="systemId()const">
2644 <modify-function signature="systemId()const">
2653 <modify-argument index="return">
2645 <modify-argument index="return">
2654 <conversion-rule class="native">
2646 <conversion-rule class="native">
2655 <insert-template name="core.convert_stringref_to_string"/>
2647 <insert-template name="core.convert_stringref_to_string"/>
2656 </conversion-rule>
2648 </conversion-rule>
2657 </modify-argument>
2649 </modify-argument>
2658 </modify-function>
2650 </modify-function>
2659
2651
2660 </value-type>
2652 </value-type>
2661 <value-type name="QXmlStreamEntityDeclaration">
2653 <value-type name="QXmlStreamEntityDeclaration">
2662 <modify-function signature="operator=(QXmlStreamEntityDeclaration)" remove="all"/>
2654 <modify-function signature="operator=(QXmlStreamEntityDeclaration)" remove="all"/>
2663
2655
2664 <modify-function signature="name()const">
2656 <modify-function signature="name()const">
2665 <modify-argument index="return">
2657 <modify-argument index="return">
2666 <conversion-rule class="native">
2658 <conversion-rule class="native">
2667 <insert-template name="core.convert_stringref_to_string"/>
2659 <insert-template name="core.convert_stringref_to_string"/>
2668 </conversion-rule>
2660 </conversion-rule>
2669 </modify-argument>
2661 </modify-argument>
2670 </modify-function>
2662 </modify-function>
2671
2663
2672 <modify-function signature="notationName()const">
2664 <modify-function signature="notationName()const">
2673 <modify-argument index="return">
2665 <modify-argument index="return">
2674 <conversion-rule class="native">
2666 <conversion-rule class="native">
2675 <insert-template name="core.convert_stringref_to_string"/>
2667 <insert-template name="core.convert_stringref_to_string"/>
2676 </conversion-rule>
2668 </conversion-rule>
2677 </modify-argument>
2669 </modify-argument>
2678 </modify-function>
2670 </modify-function>
2679
2671
2680 <modify-function signature="publicId()const">
2672 <modify-function signature="publicId()const">
2681 <modify-argument index="return">
2673 <modify-argument index="return">
2682 <conversion-rule class="native">
2674 <conversion-rule class="native">
2683 <insert-template name="core.convert_stringref_to_string"/>
2675 <insert-template name="core.convert_stringref_to_string"/>
2684 </conversion-rule>
2676 </conversion-rule>
2685 </modify-argument>
2677 </modify-argument>
2686 </modify-function>
2678 </modify-function>
2687
2679
2688 <modify-function signature="systemId()const">
2680 <modify-function signature="systemId()const">
2689 <modify-argument index="return">
2681 <modify-argument index="return">
2690 <conversion-rule class="native">
2682 <conversion-rule class="native">
2691 <insert-template name="core.convert_stringref_to_string"/>
2683 <insert-template name="core.convert_stringref_to_string"/>
2692 </conversion-rule>
2684 </conversion-rule>
2693 </modify-argument>
2685 </modify-argument>
2694 </modify-function>
2686 </modify-function>
2695
2687
2696 <modify-function signature="value()const">
2688 <modify-function signature="value()const">
2697 <modify-argument index="return">
2689 <modify-argument index="return">
2698 <conversion-rule class="native">
2690 <conversion-rule class="native">
2699 <insert-template name="core.convert_stringref_to_string"/>
2691 <insert-template name="core.convert_stringref_to_string"/>
2700 </conversion-rule>
2692 </conversion-rule>
2701 </modify-argument>
2693 </modify-argument>
2702 </modify-function>
2694 </modify-function>
2703
2695
2704 </value-type>
2696 </value-type>
2705 <object-type name="QXmlStreamReader">
2697 <object-type name="QXmlStreamReader">
2706 <modify-function signature="QXmlStreamReader(const char*)" remove="all"/>
2698 <modify-function signature="QXmlStreamReader(const char*)" remove="all"/>
2707 <modify-function signature="addData(const char*)" remove="all"/>
2699 <modify-function signature="addData(const char*)" remove="all"/>
2708 <modify-function signature="setEntityResolver(QXmlStreamEntityResolver*)">
2700 <modify-function signature="setEntityResolver(QXmlStreamEntityResolver*)">
2709 <modify-argument index="1">
2701 <modify-argument index="1">
2710 <reference-count action="set" variable-name="__rcEntityResolver"/>
2702 <reference-count action="set" variable-name="__rcEntityResolver"/>
2711 </modify-argument>
2703 </modify-argument>
2712 </modify-function>
2704 </modify-function>
2713
2705
2714 <modify-function signature="name()const">
2706 <modify-function signature="name()const">
2715 <modify-argument index="return">
2707 <modify-argument index="return">
2716 <conversion-rule class="native">
2708 <conversion-rule class="native">
2717 <insert-template name="core.convert_stringref_to_string"/>
2709 <insert-template name="core.convert_stringref_to_string"/>
2718 </conversion-rule>
2710 </conversion-rule>
2719 </modify-argument>
2711 </modify-argument>
2720 </modify-function>
2712 </modify-function>
2721
2713
2722 <modify-function signature="documentEncoding()const">
2714 <modify-function signature="documentEncoding()const">
2723 <modify-argument index="return">
2715 <modify-argument index="return">
2724 <conversion-rule class="native">
2716 <conversion-rule class="native">
2725 <insert-template name="core.convert_stringref_to_string"/>
2717 <insert-template name="core.convert_stringref_to_string"/>
2726 </conversion-rule>
2718 </conversion-rule>
2727 </modify-argument>
2719 </modify-argument>
2728 </modify-function>
2720 </modify-function>
2729
2721
2730 <modify-function signature="documentVersion()const">
2722 <modify-function signature="documentVersion()const">
2731 <modify-argument index="return">
2723 <modify-argument index="return">
2732 <conversion-rule class="native">
2724 <conversion-rule class="native">
2733 <insert-template name="core.convert_stringref_to_string"/>
2725 <insert-template name="core.convert_stringref_to_string"/>
2734 </conversion-rule>
2726 </conversion-rule>
2735 </modify-argument>
2727 </modify-argument>
2736 </modify-function>
2728 </modify-function>
2737
2729
2738 <modify-function signature="dtdName()const">
2730 <modify-function signature="dtdName()const">
2739 <modify-argument index="return">
2731 <modify-argument index="return">
2740 <conversion-rule class="native">
2732 <conversion-rule class="native">
2741 <insert-template name="core.convert_stringref_to_string"/>
2733 <insert-template name="core.convert_stringref_to_string"/>
2742 </conversion-rule>
2734 </conversion-rule>
2743 </modify-argument>
2735 </modify-argument>
2744 </modify-function>
2736 </modify-function>
2745
2737
2746 <modify-function signature="dtdPublicId()const">
2738 <modify-function signature="dtdPublicId()const">
2747 <modify-argument index="return">
2739 <modify-argument index="return">
2748 <conversion-rule class="native">
2740 <conversion-rule class="native">
2749 <insert-template name="core.convert_stringref_to_string"/>
2741 <insert-template name="core.convert_stringref_to_string"/>
2750 </conversion-rule>
2742 </conversion-rule>
2751 </modify-argument>
2743 </modify-argument>
2752 </modify-function>
2744 </modify-function>
2753
2745
2754 <modify-function signature="dtdSystemId()const">
2746 <modify-function signature="dtdSystemId()const">
2755 <modify-argument index="return">
2747 <modify-argument index="return">
2756 <conversion-rule class="native">
2748 <conversion-rule class="native">
2757 <insert-template name="core.convert_stringref_to_string"/>
2749 <insert-template name="core.convert_stringref_to_string"/>
2758 </conversion-rule>
2750 </conversion-rule>
2759 </modify-argument>
2751 </modify-argument>
2760 </modify-function>
2752 </modify-function>
2761
2753
2762 <modify-function signature="namespaceUri()const">
2754 <modify-function signature="namespaceUri()const">
2763 <modify-argument index="return">
2755 <modify-argument index="return">
2764 <conversion-rule class="native">
2756 <conversion-rule class="native">
2765 <insert-template name="core.convert_stringref_to_string"/>
2757 <insert-template name="core.convert_stringref_to_string"/>
2766 </conversion-rule>
2758 </conversion-rule>
2767 </modify-argument>
2759 </modify-argument>
2768 </modify-function>
2760 </modify-function>
2769
2761
2770 <modify-function signature="prefix()const">
2762 <modify-function signature="prefix()const">
2771 <modify-argument index="return">
2763 <modify-argument index="return">
2772 <conversion-rule class="native">
2764 <conversion-rule class="native">
2773 <insert-template name="core.convert_stringref_to_string"/>
2765 <insert-template name="core.convert_stringref_to_string"/>
2774 </conversion-rule>
2766 </conversion-rule>
2775 </modify-argument>
2767 </modify-argument>
2776 </modify-function>
2768 </modify-function>
2777
2769
2778 <modify-function signature="processingInstructionData()const">
2770 <modify-function signature="processingInstructionData()const">
2779 <modify-argument index="return">
2771 <modify-argument index="return">
2780 <conversion-rule class="native">
2772 <conversion-rule class="native">
2781 <insert-template name="core.convert_stringref_to_string"/>
2773 <insert-template name="core.convert_stringref_to_string"/>
2782 </conversion-rule>
2774 </conversion-rule>
2783 </modify-argument>
2775 </modify-argument>
2784 </modify-function>
2776 </modify-function>
2785
2777
2786 <modify-function signature="processingInstructionTarget()const">
2778 <modify-function signature="processingInstructionTarget()const">
2787 <modify-argument index="return">
2779 <modify-argument index="return">
2788 <conversion-rule class="native">
2780 <conversion-rule class="native">
2789 <insert-template name="core.convert_stringref_to_string"/>
2781 <insert-template name="core.convert_stringref_to_string"/>
2790 </conversion-rule>
2782 </conversion-rule>
2791 </modify-argument>
2783 </modify-argument>
2792 </modify-function>
2784 </modify-function>
2793
2785
2794 <modify-function signature="qualifiedName()const">
2786 <modify-function signature="qualifiedName()const">
2795 <modify-argument index="return">
2787 <modify-argument index="return">
2796 <conversion-rule class="native">
2788 <conversion-rule class="native">
2797 <insert-template name="core.convert_stringref_to_string"/>
2789 <insert-template name="core.convert_stringref_to_string"/>
2798 </conversion-rule>
2790 </conversion-rule>
2799 </modify-argument>
2791 </modify-argument>
2800 </modify-function>
2792 </modify-function>
2801
2793
2802 <modify-function signature="text()const">
2794 <modify-function signature="text()const">
2803 <modify-argument index="return">
2795 <modify-argument index="return">
2804 <conversion-rule class="native">
2796 <conversion-rule class="native">
2805 <insert-template name="core.convert_stringref_to_string"/>
2797 <insert-template name="core.convert_stringref_to_string"/>
2806 </conversion-rule>
2798 </conversion-rule>
2807 </modify-argument>
2799 </modify-argument>
2808 </modify-function>
2800 </modify-function>
2809 </object-type>
2801 </object-type>
2810 <object-type name="QXmlStreamWriter">
2802 <object-type name="QXmlStreamWriter">
2811 <modify-function signature="QXmlStreamWriter(QString *)">
2803 <modify-function signature="QXmlStreamWriter(QString *)">
2812 <remove/>
2804 <remove/>
2813 </modify-function>
2805 </modify-function>
2814
2806
2815 <modify-function signature="setCodec(const char*)">
2807 <modify-function signature="setCodec(const char*)">
2816 <modify-argument index="1">
2808 <modify-argument index="1">
2817 <replace-type modified-type="QString"/>
2809 <replace-type modified-type="QString"/>
2818 <conversion-rule class="native">
2810 <conversion-rule class="native">
2819 <insert-template name="core.convert_string_arg_to_char*"/>
2811 <insert-template name="core.convert_string_arg_to_char*"/>
2820 </conversion-rule>
2812 </conversion-rule>
2821 </modify-argument>
2813 </modify-argument>
2822 </modify-function>
2814 </modify-function>
2823
2815
2824 <modify-function signature="writeCurrentToken(QXmlStreamReader)">
2816 <modify-function signature="writeCurrentToken(QXmlStreamReader)">
2825 <modify-argument index="1">
2817 <modify-argument index="1">
2826 <replace-type modified-type="QXmlStreamReader*"/>
2818 <replace-type modified-type="QXmlStreamReader*"/>
2827 <conversion-rule class="native">
2819 <conversion-rule class="native">
2828 QXmlStreamReader &amp; %out% = *qscriptvalue_cast&lt;QXmlStreamReader*&gt;(%in%);
2820 QXmlStreamReader &amp; %out% = *qscriptvalue_cast&lt;QXmlStreamReader*&gt;(%in%);
2829 </conversion-rule>
2821 </conversion-rule>
2830 </modify-argument>
2822 </modify-argument>
2831 </modify-function>
2823 </modify-function>
2832
2824
2833 </object-type>
2825 </object-type>
2834 <enum-type name="QXmlStreamReader::ReadElementTextBehaviour"/>
2826 <enum-type name="QXmlStreamReader::ReadElementTextBehaviour"/>
2835
2827
2836 <value-type name="QModelIndex"/>
2828 <value-type name="QModelIndex"/>
2837 <value-type name="QMargins"/>
2829 <value-type name="QMargins"/>
2838
2830
2839 <!-- Inefficient hash codes -->
2831 <!-- Inefficient hash codes -->
2840 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QUuid' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2832 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QUuid' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2841 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QLocale' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2833 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QLocale' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2842 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QFuture' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2834 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QFuture' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2843 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QRegExp' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2835 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QRegExp' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2844 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QFutureVoid' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2836 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QFutureVoid' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2845 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QUrl' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2837 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QUrl' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2846 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QProcessEnvironment' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2838 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QProcessEnvironment' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
2847
2839
2848 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::selectIteration', unmatched parameter type 'T'"/>
2840 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::selectIteration', unmatched parameter type 'T'"/>
2849 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QVariantAnimation::registerInterpolator', unmatched parameter type 'QVariantAnimation::Interpolator'"/>
2841 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QVariantAnimation::registerInterpolator', unmatched parameter type 'QVariantAnimation::Interpolator'"/>
2850
2842
2851 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'Qt::Initialization'"/>
2843 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'Qt::Initialization'"/>
2852 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'std::*'"/>
2844 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'std::*'"/>
2853 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type '*Private\*'"/>
2845 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type '*Private\*'"/>
2854 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type '*Private&amp;'"/>
2846 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type '*Private&amp;'"/>
2855 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QMetaObject'"/>
2847 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QMetaObject'"/>
2856 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'FILE\*'"/>
2848 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'FILE\*'"/>
2857 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QByteArray::Data\*'"/>
2849 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QByteArray::Data\*'"/>
2858 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QTSMFC'"/>
2850 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QTSMFC'"/>
2859 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QTSMFI'"/>
2851 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QTSMFI'"/>
2860 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QAbstractFileEngine::ExtensionOption const\*'"/>
2852 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QAbstractFileEngine::ExtensionOption const\*'"/>
2861 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QAbstractFileEngine::Iterator\*'"/>
2853 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QAbstractFileEngine::Iterator\*'"/>
2862 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QDataStream::ByteOrder'"/>
2854 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QDataStream::ByteOrder'"/>
2863 <suppress-warning text="WARNING(MetaJavaBuilder) :: visibility of function '*' modified in class '*'"/>
2855 <suppress-warning text="WARNING(MetaJavaBuilder) :: visibility of function '*' modified in class '*'"/>
2864 <suppress-warning text="WARNING(MetaJavaBuilder) :: hiding of function '*' in class '*'"/>
2856 <suppress-warning text="WARNING(MetaJavaBuilder) :: hiding of function '*' in class '*'"/>
2865 <suppress-warning text="WARNING(CppImplGenerator) :: protected function '*' in final class '*'"/>
2857 <suppress-warning text="WARNING(CppImplGenerator) :: protected function '*' in final class '*'"/>
2866 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QPointer&lt;*&gt;'"/>
2858 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QPointer&lt;*&gt;'"/>
2867 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QVector&lt;*&gt;'"/>
2859 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QVector&lt;*&gt;'"/>
2868 <suppress-warning text="* private virtual function '*' in 'QAbstractListModel'"/>
2860 <suppress-warning text="* private virtual function '*' in 'QAbstractListModel'"/>
2869 <suppress-warning text="* private virtual function '*' in 'QAbstractTableModel'"/>
2861 <suppress-warning text="* private virtual function '*' in 'QAbstractTableModel'"/>
2870 <suppress-warning text="* private virtual function '*' in 'QListWidget'"/>
2862 <suppress-warning text="* private virtual function '*' in 'QListWidget'"/>
2871 <suppress-warning text="* private virtual function '*' in 'QTreeWidget'"/>
2863 <suppress-warning text="* private virtual function '*' in 'QTreeWidget'"/>
2872 <suppress-warning text="* private virtual function '*' in 'QFontDialog'"/>
2864 <suppress-warning text="* private virtual function '*' in 'QFontDialog'"/>
2873 <suppress-warning text="* private virtual function '*' in 'QTableWidget'"/>
2865 <suppress-warning text="* private virtual function '*' in 'QTableWidget'"/>
2874 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFutureWatcherBase::futureInterface', unmatched return type 'QFutureInterfaceBase&amp;'"/>
2866 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFutureWatcherBase::futureInterface', unmatched return type 'QFutureInterfaceBase&amp;'"/>
2875 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFutureWatcherBase::futureInterface', unmatched return type 'QFutureInterfaceBase const&amp;'"/>
2867 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFutureWatcherBase::futureInterface', unmatched return type 'QFutureInterfaceBase const&amp;'"/>
2876 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFutureWatcher::futureInterface', unmatched return type 'QFutureInterfaceBase&amp;'"/>
2868 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFutureWatcher::futureInterface', unmatched return type 'QFutureInterfaceBase&amp;'"/>
2877 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFutureWatcher::futureInterface', unmatched return type 'QFutureInterfaceBase const&amp;'"/>
2869 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFutureWatcher::futureInterface', unmatched return type 'QFutureInterfaceBase const&amp;'"/>
2878 <suppress-warning text="WARNING(MetaJavaBuilder) :: unknown operator 'T'"/>
2870 <suppress-warning text="WARNING(MetaJavaBuilder) :: unknown operator 'T'"/>
2879 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFuture::constBegin', unmatched return type 'const_iterator'"/>
2871 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFuture::constBegin', unmatched return type 'const_iterator'"/>
2880 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFuture::end', unmatched return type 'const_iterator'"/>
2872 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFuture::end', unmatched return type 'const_iterator'"/>
2881 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFuture::constEnd', unmatched return type 'const_iterator'"/>
2873 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFuture::constEnd', unmatched return type 'const_iterator'"/>
2882 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFuture::QFuture', unmatched parameter type 'QFutureInterface&lt;T&gt;*'"/>
2874 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFuture::QFuture', unmatched parameter type 'QFutureInterface&lt;T&gt;*'"/>
2883 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFuture::begin', unmatched return type 'const_iterator'"/>
2875 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFuture::begin', unmatched return type 'const_iterator'"/>
2884 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::advance', unmatched parameter type 'It&amp;'"/>
2876 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::advance', unmatched parameter type 'It&amp;'"/>
2885 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMapped', unmatched return type 'Sequence'"/>
2877 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMapped', unmatched return type 'Sequence'"/>
2886 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMapped', unmatched return type 'QList&lt;U&gt;'"/>
2878 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMapped', unmatched return type 'QList&lt;U&gt;'"/>
2887 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMapped', unmatched return type 'QList&lt;MapFunctor::result_type&gt;'"/>
2879 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMapped', unmatched return type 'QList&lt;MapFunctor::result_type&gt;'"/>
2888 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMapped', unmatched return type 'OutputSequence'"/>
2880 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMapped', unmatched return type 'OutputSequence'"/>
2889 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::filtered', unmatched parameter type 'Iterator'"/>
2881 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::filtered', unmatched parameter type 'Iterator'"/>
2890 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::filtered', unmatched parameter type 'Sequence const&amp;'"/>
2882 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::filtered', unmatched parameter type 'Sequence const&amp;'"/>
2891 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::filter', unmatched parameter type 'Sequence&amp;'"/>
2883 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::filter', unmatched parameter type 'Sequence&amp;'"/>
2892 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startFiltered', unmatched return type 'ThreadEngineStarter&lt;qValueType&lt;Iterator&gt;::value_type&gt;"/>
2884 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startFiltered', unmatched return type 'ThreadEngineStarter&lt;qValueType&lt;Iterator&gt;::value_type&gt;"/>
2893 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startFiltered', unmatched return type 'ThreadEngineStarter&lt;Sequence::value_type&gt;'"/>
2885 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startFiltered', unmatched return type 'ThreadEngineStarter&lt;Sequence::value_type&gt;'"/>
2894 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startFiltered', unmatched return type 'ThreadEngineStarter&lt;Iterator::value_type&gt;'"/>
2886 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startFiltered', unmatched return type 'ThreadEngineStarter&lt;Iterator::value_type&gt;'"/>
2895 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMappedReduced', unmatched return type 'V'"/>
2887 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMappedReduced', unmatched return type 'V'"/>
2896 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMappedReduced', unmatched return type 'W'"/>
2888 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMappedReduced', unmatched return type 'W'"/>
2897 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMappedReduced', unmatched return type 'ResultType'"/>
2889 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMappedReduced', unmatched return type 'ResultType'"/>
2898 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMappedReduced', unmatched return type 'U'"/>
2890 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMappedReduced', unmatched return type 'U'"/>
2899 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingFiltered', unmatched return type 'OutputSequence'"/>
2891 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingFiltered', unmatched return type 'OutputSequence'"/>
2900 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingFiltered', unmatched return type 'Sequence'"/>
2892 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingFiltered', unmatched return type 'Sequence'"/>
2901 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startMappedReduced', unmatched return type 'ThreadEngineStarter&lt;ResultType&gt;'"/>
2893 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startMappedReduced', unmatched return type 'ThreadEngineStarter&lt;ResultType&gt;'"/>
2902 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingFilteredReduced', unmatched return type 'U'"/>
2894 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingFilteredReduced', unmatched return type 'U'"/>
2903 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingFilteredReduced', unmatched return type 'V'"/>
2895 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingFilteredReduced', unmatched return type 'V'"/>
2904 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingFilteredReduced', unmatched return type 'ResultType'"/>
2896 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingFilteredReduced', unmatched return type 'ResultType'"/>
2905 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startMap', unmatched return type 'ThreadEngineStarter&lt;void&gt;'"/>
2897 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startMap', unmatched return type 'ThreadEngineStarter&lt;void&gt;'"/>
2906 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startThreadEngine', unmatched return type 'ThreadEngineStarter&lt;ThreadEngine::ResultType&gt;'"/>
2898 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startThreadEngine', unmatched return type 'ThreadEngineStarter&lt;ThreadEngine::ResultType&gt;'"/>
2907 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::mappedReduced', unmatched parameter type 'Iterator'"/>
2899 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::mappedReduced', unmatched parameter type 'Iterator'"/>
2908 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::mappedReduced', unmatched parameter type 'Sequence const&amp;'"/>
2900 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::mappedReduced', unmatched parameter type 'Sequence const&amp;'"/>
2909 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::filteredReduced', unmatched parameter type 'Iterator'"/>
2901 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::filteredReduced', unmatched parameter type 'Iterator'"/>
2910 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::filteredReduced', unmatched parameter type 'Sequence const&amp;'"/>
2902 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::filteredReduced', unmatched parameter type 'Sequence const&amp;'"/>
2911 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::map', unmatched parameter type 'Iterator'"/>
2903 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::map', unmatched parameter type 'Iterator'"/>
2912 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::map', unmatched parameter type 'Sequence&amp;'"/>
2904 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::map', unmatched parameter type 'Sequence&amp;'"/>
2913 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::filterInternal', unmatched return type 'ThreadEngineStarter&lt;void&gt;'"/>
2905 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::filterInternal', unmatched return type 'ThreadEngineStarter&lt;void&gt;'"/>
2914 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::createFunctor', unmatched return type 'QtConcurrent::SelectMemberFunctor0lt;T,Class&gt;::type'"/>
2906 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::createFunctor', unmatched return type 'QtConcurrent::SelectMemberFunctor0lt;T,Class&gt;::type'"/>
2915 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::createFunctor', unmatched return type 'SelectFunctor0&lt;T,T&gt;::type'"/>
2907 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::createFunctor', unmatched return type 'SelectFunctor0&lt;T,T&gt;::type'"/>
2916 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::mapped', unmatched parameter type 'Iterator'"/>
2908 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::mapped', unmatched parameter type 'Iterator'"/>
2917 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::mapped', unmatched parameter type 'Sequence const&amp;'"/>
2909 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::mapped', unmatched parameter type 'Sequence const&amp;'"/>
2918 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMap', unmatched parameter type 'Iterator'"/>
2910 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMap', unmatched parameter type 'Iterator'"/>
2919 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMap', unmatched parameter type 'Sequence&amp;'"/>
2911 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingMap', unmatched parameter type 'Sequence&amp;'"/>
2920 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startMapped', unmatched return type 'QtConcurrent::ThreadEngineStarter&lt;T&gt;'"/>
2912 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startMapped', unmatched return type 'QtConcurrent::ThreadEngineStarter&lt;T&gt;'"/>
2921 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startFilteredReduced', unmatched return type 'ThreadEngineStarter&lt;ResultType&gt;'"/>
2913 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::startFilteredReduced', unmatched return type 'ThreadEngineStarter&lt;ResultType&gt;'"/>
2922 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::run', unmatched parameter type 'Class const*'"/>
2914 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::run', unmatched parameter type 'Class const*'"/>
2923 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::run', unmatched parameter type 'Class*'"/>
2915 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::run', unmatched parameter type 'Class*'"/>
2924 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::run', unmatched parameter type 'Class const&amp;'"/>
2916 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::run', unmatched parameter type 'Class const&amp;'"/>
2925 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::run', unmatched parameter type 'FunctionObject*'"/>
2917 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::run', unmatched parameter type 'FunctionObject*'"/>
2926 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::run', unmatched parameter type 'FunctionObject'"/>
2918 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::run', unmatched parameter type 'FunctionObject'"/>
2927 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::run', unmatched parameter type 'T'"/>
2919 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::run', unmatched parameter type 'T'"/>
2928 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingFilter', unmatched parameter type 'Sequence&amp;'"/>
2920 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::blockingFilter', unmatched parameter type 'Sequence&amp;'"/>
2929 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::createFunctor', unmatched return type 'QtConcurrent::SelectMemberFunctor0&lt;T,Class&gt;::type'"/>
2921 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QtConcurrent::createFunctor', unmatched return type 'QtConcurrent::SelectMemberFunctor0&lt;T,Class&gt;::type'"/>
2930
2922
2931 <suppress-warning text="WARNING(Parser) :: ** WARNING scope not found for function definition:QFuture&lt;void&gt;::operator= - definition *ignored*"/>
2923 <suppress-warning text="WARNING(Parser) :: ** WARNING scope not found for function definition:QFuture&lt;void&gt;::operator= - definition *ignored*"/>
2932 <suppress-warning text="WARNING(Parser) :: ** WARNING scope not found for function definition:QFutureInterface&lt;void&gt;::future - definition *ignored*"/>
2924 <suppress-warning text="WARNING(Parser) :: ** WARNING scope not found for function definition:QFutureInterface&lt;void&gt;::future - definition *ignored*"/>
2933 <suppress-warning text="WARNING(Parser) :: ** WARNING scope not found for function definition:QFutureWatcher&lt;void&gt;::setFuture - definition *ignored*"/>
2925 <suppress-warning text="WARNING(Parser) :: ** WARNING scope not found for function definition:QFutureWatcher&lt;void&gt;::setFuture - definition *ignored*"/>
2934
2926
2935
2927
2936 </typesystem>
2928 </typesystem>
@@ -1,5673 +1,5676
1 <?xml version="1.0"?>
1 <?xml version="1.0"?>
2 <typesystem package="com.trolltech.qt.gui"><rejection class="QAbstractTextDocumentLayout"/><rejection class="QColormap"/><rejection class="QFontDatabase"/><rejection class="QIconEngineV2"/><rejection class="QInputMethodEvent"/><rejection class="QPainterPath::Element"/><rejection class="QTextBlock::iterator"/><rejection class="QTextFrame::iterator"/><rejection class="QTextLayout::FormatRange"/><rejection class="QTreeWidgetItemIterator"/><rejection class="QAccessibleFactoryInterface"/><rejection class="QIconEngineFactoryInterfaceV2"/><rejection class="QImageIOHandlerFactoryInterface"/><rejection class="QInputContextFactoryInterface"/><rejection class="QStyleFactoryInterface"/><rejection class="QPictureFormatInterface"/><rejection class="QAbstractProxyModel"/><rejection class="QSortFilterProxyModel"/><rejection class="QDirModel"/><rejection class="QFileSystemModel"/><rejection class="QPrinterInfo"/><rejection class="QProxyModel"/><rejection class="QPrinterInfo"/><rejection class="QTextOption"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Rejected enum has no alternative...: QPalette::NColorRoles"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Cannot find enum constant for value 'DragMove' in 'QDragMoveEvent' or any of its super classes"/><suppress-warning text="WARNING() :: Unknown attribute for 'modify-function': 'allow-as-slot'"/>
2 <typesystem package="com.trolltech.qt.gui"><rejection class="QAbstractTextDocumentLayout"/><rejection class="QColormap"/><rejection class="QFontDatabase"/><rejection class="QIconEngineV2"/><rejection class="QInputMethodEvent"/><rejection class="QPainterPath::Element"/><rejection class="QTextBlock::iterator"/><rejection class="QTextFrame::iterator"/><rejection class="QTextLayout::FormatRange"/><rejection class="QTreeWidgetItemIterator"/><rejection class="QAccessibleFactoryInterface"/><rejection class="QIconEngineFactoryInterfaceV2"/><rejection class="QImageIOHandlerFactoryInterface"/><rejection class="QInputContextFactoryInterface"/><rejection class="QStyleFactoryInterface"/><rejection class="QPictureFormatInterface"/><rejection class="QAbstractProxyModel"/><rejection class="QSortFilterProxyModel"/><rejection class="QDirModel"/><rejection class="QFileSystemModel"/><rejection class="QPrinterInfo"/><rejection class="QProxyModel"/><rejection class="QPrinterInfo"/><rejection class="QTextOption"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Rejected enum has no alternative...: QPalette::NColorRoles"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Cannot find enum constant for value 'DragMove' in 'QDragMoveEvent' or any of its super classes"/><suppress-warning text="WARNING() :: Unknown attribute for 'modify-function': 'allow-as-slot'"/>
3
3
4 <rejection class="*" function-name="d_func"/>
4 <rejection class="*" function-name="d_func"/>
5
5
6 <rejection class="*" field-name="d_ptr"/>
6 <rejection class="*" field-name="d_ptr"/>
7 <rejection class="*" field-name="d"/>
7 <rejection class="*" field-name="d"/>
8
8
9 <rejection class="QGenericMatrix"/>
9 <rejection class="QGenericMatrix"/>
10 <rejection class="QPixmapFilterPrivate"/>
10 <rejection class="QPixmapFilterPrivate"/>
11 <rejection class="QPenPrivate"/>
11 <rejection class="QPenPrivate"/>
12 <rejection class="QGtkStyle"/>
12 <rejection class="QGtkStyle"/>
13 <rejection class="QWindowsCEStyle"/>
13 <rejection class="QWindowsCEStyle"/>
14 <rejection class="QWindowsMobileStyle"/>
14 <rejection class="QWindowsMobileStyle"/>
15 <rejection class="QAbstractUndoItem"/>
15 <rejection class="QAbstractUndoItem"/>
16 <rejection class="QAccessibleApplication"/>
16 <rejection class="QAccessibleApplication"/>
17 <rejection class="QBrushData"/>
17 <rejection class="QBrushData"/>
18 <rejection class="QImageTextKeyLang"/>
18 <rejection class="QImageTextKeyLang"/>
19 <rejection class="QItemEditorCreator"/>
19 <rejection class="QItemEditorCreator"/>
20 <rejection class="QLibrary"/>
20 <rejection class="QLibrary"/>
21 <rejection class="QLinkedList"/>
21 <rejection class="QLinkedList"/>
22 <rejection class="QLinkedListData"/>
22 <rejection class="QLinkedListData"/>
23 <rejection class="QLinkedListIterator"/>
23 <rejection class="QLinkedListIterator"/>
24 <rejection class="QLinkedListNode"/>
24 <rejection class="QLinkedListNode"/>
25 <rejection class="QMimeSource"/>
25 <rejection class="QMimeSource"/>
26 <rejection class="QPainterPathPrivate"/>
26 <rejection class="QPainterPathPrivate"/>
27 <rejection class="QRegionData"/>
27 <rejection class="QRegionData"/>
28 <rejection class="QStandardItemEditorCreator"/>
28 <rejection class="QStandardItemEditorCreator"/>
29 <rejection class="QStyleOptionQ3DockWindow"/>
29 <rejection class="QStyleOptionQ3DockWindow"/>
30 <rejection class="QStyleOptionQ3ListView"/>
30 <rejection class="QStyleOptionQ3ListView"/>
31 <rejection class="QStyleOptionQ3ListViewItem"/>
31 <rejection class="QStyleOptionQ3ListViewItem"/>
32 <rejection class="QTextFrameLayoutData"/>
32 <rejection class="QTextFrameLayoutData"/>
33 <rejection class="QUpdateLaterEvent"/>
33 <rejection class="QUpdateLaterEvent"/>
34 <rejection class="QVFbHeader"/>
34 <rejection class="QVFbHeader"/>
35 <rejection class="QWidgetData"/>
35 <rejection class="QWidgetData"/>
36 <rejection class="QWindowSurface"/>
36 <rejection class="QWindowSurface"/>
37 <rejection class="QWindowsXPStyle"/>
37 <rejection class="QWindowsXPStyle"/>
38 <rejection class="QWindowsVistaStyle"/>
38 <rejection class="QWindowsVistaStyle"/>
39 <rejection class="QWSEmbedWidget"/>
39 <rejection class="QWSEmbedWidget"/>
40 <rejection class="QRegion::QRegionData"/>
40 <rejection class="QRegion::QRegionData"/>
41 <rejection class="JObject_key"/>
41 <rejection class="JObject_key"/>
42 <rejection class="QAccessibleEditableTextInterface"/>
42 <rejection class="QAccessibleEditableTextInterface"/>
43 <rejection class="QAccessibleSimpleEditableTextInterface"/>
43 <rejection class="QAccessibleSimpleEditableTextInterface"/>
44 <rejection class="QAccessibleTextInterface"/>
44 <rejection class="QAccessibleTextInterface"/>
45 <rejection class="QAccessibleValueInterface"/>
45 <rejection class="QAccessibleValueInterface"/>
46 <rejection class="QAccessibleBridge"/>
46 <rejection class="QAccessibleBridge"/>
47 <rejection class="QIconEngineFactoryInterface"/>
47 <rejection class="QIconEngineFactoryInterface"/>
48 <rejection class="QIconEnginePlugin"/>
48 <rejection class="QIconEnginePlugin"/>
49 <rejection class="QWidgetItemV2"/>
49 <rejection class="QWidgetItemV2"/>
50 <rejection class="QAbstractItemDelegate" function-name="operator="/>
50 <rejection class="QAbstractItemDelegate" function-name="operator="/>
51 <rejection class="QAccessible" function-name="installFactory"/>
51 <rejection class="QAccessible" function-name="installFactory"/>
52 <rejection class="QAccessible" function-name="installRootObjectHandler"/>
52 <rejection class="QAccessible" function-name="installRootObjectHandler"/>
53 <rejection class="QAccessible" function-name="installUpdateHandler"/>
53 <rejection class="QAccessible" function-name="installUpdateHandler"/>
54 <rejection class="QAccessible" function-name="removeFactory"/>
54 <rejection class="QAccessible" function-name="removeFactory"/>
55 <rejection class="QApplication" function-name="compressEvent"/>
55 <rejection class="QApplication" function-name="compressEvent"/>
56 <rejection class="QBrush" function-name="cleanUp"/>
56 <rejection class="QBrush" function-name="cleanUp"/>
57 <rejection class="QPictureIO" function-name="defineIOHandler"/>
57 <rejection class="QPictureIO" function-name="defineIOHandler"/>
58 <rejection class="QPolygon" function-name="putPoints"/>
58 <rejection class="QPolygon" function-name="putPoints"/>
59 <rejection class="QPolygon" function-name="setPoints"/>
59 <rejection class="QPolygon" function-name="setPoints"/>
60 <rejection class="QPolygon" function-name="setPoint"/>
60 <rejection class="QPolygon" function-name="setPoint"/>
61 <rejection class="QPolygon" function-name="points"/>
61 <rejection class="QPolygon" function-name="points"/>
62 <rejection class="QPolygon" function-name="point"/>
62 <rejection class="QPolygon" function-name="point"/>
63 <rejection class="QPrinter" function-name="printerSelectionOption"/>
63 <rejection class="QPrinter" function-name="printerSelectionOption"/>
64 <rejection class="QPrinter" function-name="setPrinterSelectionOption"/>
64 <rejection class="QPrinter" function-name="setPrinterSelectionOption"/>
65 <rejection class="QWidget" function-name="create"/>
65 <rejection class="QWidget" function-name="create"/>
66 <rejection class="QWidget" function-name="find"/>
66 <rejection class="QWidget" function-name="find"/>
67 <rejection class="QWidget" function-name="handle"/>
67 <rejection class="QWidget" function-name="handle"/>
68 <rejection class="QWidget" function-name="styleChange"/>
68 <rejection class="QWidget" function-name="styleChange"/>
69 <rejection class="QWidget" function-name="internalWinId"/>
69 <rejection class="QWidget" function-name="internalWinId"/>
70 <rejection class="QActionGroup" function-name="selected"/>
70 <rejection class="QActionGroup" function-name="selected"/>
71 <rejection class="QPaintEngine" function-name="fix_neg_rect"/>
71 <rejection class="QPaintEngine" function-name="fix_neg_rect"/>
72 <rejection class="QTreeModel" function-name="node"/>
72 <rejection class="QTreeModel" function-name="node"/>
73 <rejection class="QTreeModel" function-name="initializeNode"/>
73 <rejection class="QTreeModel" function-name="initializeNode"/>
74 <rejection class="QTreeModel" function-name="queryChildren"/>
74 <rejection class="QTreeModel" function-name="queryChildren"/>
75 <rejection class="QTextObjectInterface"/>
75 <rejection class="QTextObjectInterface"/>
76 <rejection class="QAccessible" function-name="cast_helper"/>
76 <rejection class="QAccessible" function-name="cast_helper"/>
77 <rejection class="QAccessible" function-name="updateAccessibility"/>
77 <rejection class="QAccessible" function-name="updateAccessibility"/>
78 <rejection class="QAccessible2"/>
78 <rejection class="QAccessible2"/>
79 <rejection class="QAccessibleInterface" function-name="backgroundColor"/>
79 <rejection class="QAccessibleInterface" function-name="backgroundColor"/>
80 <rejection class="QAccessibleInterface" function-name="foregroundColor"/>
80 <rejection class="QAccessibleInterface" function-name="foregroundColor"/>
81 <rejection class="QAccessibleInterface" function-name="textInterface"/>
81 <rejection class="QAccessibleInterface" function-name="textInterface"/>
82 <rejection class="QAccessibleInterface" function-name="valueInterface"/>
82 <rejection class="QAccessibleInterface" function-name="valueInterface"/>
83 <rejection class="QAccessibleInterface" function-name="tableInterface"/>
83 <rejection class="QAccessibleInterface" function-name="tableInterface"/>
84 <rejection class="QAccessibleInterface" function-name="editableTextInterface"/>
84 <rejection class="QAccessibleInterface" function-name="editableTextInterface"/>
85 <rejection class="QAccessibleInterface" function-name="cast_helper"/>
85 <rejection class="QAccessibleInterface" function-name="cast_helper"/>
86 <rejection class="QAccessibleInterfaceEx" function-name="interface_cast"/>
86 <rejection class="QAccessibleInterfaceEx" function-name="interface_cast"/>
87 <rejection class="QAccessibleBridgePlugin"/>
87 <rejection class="QAccessibleBridgePlugin"/>
88 <rejection class="QAccessibleBridgeFactoryInterface"/>
88 <rejection class="QAccessibleBridgeFactoryInterface"/>
89 <rejection class="QTabletEvent" field-name="mExtra"/>
89 <rejection class="QTabletEvent" field-name="mExtra"/>
90 <rejection class="QWidgetItem" field-name="wid"/>
90 <rejection class="QWidgetItem" field-name="wid"/>
91 <rejection class="QFont" enum-name="ResolveProperties"/>
91 <rejection class="QFont" enum-name="ResolveProperties"/>
92 <rejection class="QGradient" enum-name="InterpolationMode"/>
92 <rejection class="QGradient" enum-name="InterpolationMode"/>
93 <rejection class="QIconEngine::AvailableSizesArgument"/>
93 <rejection class="QIconEngine::AvailableSizesArgument"/>
94 <rejection class="QIconEngine" enum-name="IconEngineHook"/>
94 <rejection class="QIconEngine" enum-name="IconEngineHook"/>
95 <rejection class="QGradient" enum-name="InterpolationMode"/>
95 <rejection class="QGradient" enum-name="InterpolationMode"/>
96 <rejection class="QGradient" function-name="setInterpolationMode"/>
96 <rejection class="QGradient" function-name="setInterpolationMode"/>
97 <rejection class="QGradient" function-name="interpolationMode"/>
97 <rejection class="QGradient" function-name="interpolationMode"/>
98 <rejection class="QAbstractTextDocumentLayout" function-name="handlerForObject"/>
98 <rejection class="QAbstractTextDocumentLayout" function-name="handlerForObject"/>
99 <rejection class="QStyleOptionDockWidgetV2"/>
99 <rejection class="QStyleOptionDockWidgetV2"/>
100 <rejection class="QStyleOptionFrameV2"/>
100 <rejection class="QStyleOptionFrameV2"/>
101 <rejection class="QStyleOptionFrameV3"/>
101 <rejection class="QStyleOptionFrameV3"/>
102 <rejection class="QStyleOptionProgressBarV2"/>
102 <rejection class="QStyleOptionProgressBarV2"/>
103 <rejection class="QStyleOptionTabBarBaseV2"/>
103 <rejection class="QStyleOptionTabBarBaseV2"/>
104 <rejection class="QStyleOptionTabV2"/>
104 <rejection class="QStyleOptionTabV2"/>
105 <rejection class="QStyleOptionTabV3"/>
105 <rejection class="QStyleOptionTabV3"/>
106 <rejection class="QStyleOptionToolBoxV2"/>
106 <rejection class="QStyleOptionToolBoxV2"/>
107 <rejection class="QStyleOptionViewItemV2"/>
107 <rejection class="QStyleOptionViewItemV2"/>
108 <rejection class="QStyleOptionViewItemV3"/>
108 <rejection class="QStyleOptionViewItemV3"/>
109 <rejection class="QStyleOptionViewItemV4"/>
109 <rejection class="QStyleOptionViewItemV4"/>
110 <rejection class="QDataStream"/>
110 <rejection class="QDataStream"/>
111 <rejection class="QIconEngine"/>
111 <rejection class="QIconEngine"/>
112
112
113 <enum-type name="QStyleOptionTabBarBase::StyleOptionVersion"/>
113 <enum-type name="QStyleOptionTabBarBase::StyleOptionVersion"/>
114 <enum-type name="QTabBar::SelectionBehavior"/>
114 <enum-type name="QTabBar::SelectionBehavior"/>
115 <enum-type name="QTabBar::ButtonPosition"/>
115 <enum-type name="QTabBar::ButtonPosition"/>
116 <enum-type name="QInputDialog::InputMode"/>
116 <enum-type name="QInputDialog::InputMode"/>
117 <enum-type name="QInputDialog::InputDialogOption" flags="QInputDialog::InputDialogOptions"/>
117 <enum-type name="QInputDialog::InputDialogOption" flags="QInputDialog::InputDialogOptions"/>
118 <enum-type name="QFontDialog::FontDialogOption" flags="QFontDialog::FontDialogOptions"/>
118 <enum-type name="QFontDialog::FontDialogOption" flags="QFontDialog::FontDialogOptions"/>
119 <enum-type name="QColorDialog::ColorDialogOption" flags="QColorDialog::ColorDialogOptions"/>
119 <enum-type name="QColorDialog::ColorDialogOption" flags="QColorDialog::ColorDialogOptions"/>
120 <enum-type name="QAbstractItemDelegate::EndEditHint"/>
120 <enum-type name="QAbstractItemDelegate::EndEditHint"/>
121 <enum-type name="QAbstractItemView::CursorAction"/>
121 <enum-type name="QAbstractItemView::CursorAction"/>
122 <enum-type name="QAbstractItemView::DragDropMode"/>
122 <enum-type name="QAbstractItemView::DragDropMode"/>
123 <enum-type name="QAbstractItemView::DropIndicatorPosition"/>
123 <enum-type name="QAbstractItemView::DropIndicatorPosition"/>
124 <enum-type name="QAbstractItemView::EditTrigger" flags="QAbstractItemView::EditTriggers"/>
124 <enum-type name="QAbstractItemView::EditTrigger" flags="QAbstractItemView::EditTriggers"/>
125 <enum-type name="QAbstractItemView::ScrollHint"/>
125 <enum-type name="QAbstractItemView::ScrollHint"/>
126 <enum-type name="QAbstractItemView::ScrollMode"/>
126 <enum-type name="QAbstractItemView::ScrollMode"/>
127 <enum-type name="QAbstractItemView::SelectionBehavior"/>
127 <enum-type name="QAbstractItemView::SelectionBehavior"/>
128 <enum-type name="QAbstractItemView::SelectionMode"/>
128 <enum-type name="QAbstractItemView::SelectionMode"/>
129 <enum-type name="QAbstractItemView::State"/>
129 <enum-type name="QAbstractItemView::State"/>
130 <enum-type name="QAbstractPrintDialog::PrintDialogOption" flags="QAbstractPrintDialog::PrintDialogOptions"/>
130 <enum-type name="QAbstractPrintDialog::PrintDialogOption" flags="QAbstractPrintDialog::PrintDialogOptions"/>
131 <enum-type name="QAbstractPrintDialog::PrintRange"/>
131 <enum-type name="QAbstractPrintDialog::PrintRange"/>
132 <enum-type name="QAbstractSlider::SliderAction"/>
132 <enum-type name="QAbstractSlider::SliderAction"/>
133 <enum-type name="QAbstractSlider::SliderChange"/>
133 <enum-type name="QAbstractSlider::SliderChange"/>
134 <enum-type name="QAbstractSpinBox::ButtonSymbols"/>
134 <enum-type name="QAbstractSpinBox::ButtonSymbols"/>
135 <enum-type name="QAbstractSpinBox::CorrectionMode"/>
135 <enum-type name="QAbstractSpinBox::CorrectionMode"/>
136 <enum-type name="QAbstractSpinBox::StepEnabledFlag" flags="QAbstractSpinBox::StepEnabled"/>
136 <enum-type name="QAbstractSpinBox::StepEnabledFlag" flags="QAbstractSpinBox::StepEnabled"/>
137 <enum-type name="QAccessible::Event"/>
137 <enum-type name="QAccessible::Event"/>
138 <enum-type name="QAccessible::Method"/>
138 <enum-type name="QAccessible::Method"/>
139 <enum-type name="QAccessible::State"/>
139 <enum-type name="QAccessible::State"/>
140 <enum-type name="QAccessible::RelationFlag" flags="QAccessible::Relation"/>
140 <enum-type name="QAccessible::RelationFlag" flags="QAccessible::Relation"/>
141 <enum-type name="QAccessible::Role"/>
141 <enum-type name="QAccessible::Role"/>
142 <enum-type name="QAccessible::Text"/>
142 <enum-type name="QAccessible::Text"/>
143 <enum-type name="QDesktopServices::StandardLocation"/>
143 <enum-type name="QDesktopServices::StandardLocation"/>
144 <enum-type name="QDirModel::Roles"/>
144 <enum-type name="QDirModel::Roles"/>
145 <enum-type name="QFont::Capitalization"/>
145 <enum-type name="QFont::Capitalization"/>
146 <enum-type name="QFont::SpacingType"/>
146 <enum-type name="QFont::SpacingType"/>
147 <enum-type name="QGraphicsItem::CacheMode"/>
147 <enum-type name="QGraphicsItem::CacheMode"/>
148 <enum-type name="QMdiArea::AreaOption" flags="QMdiArea::AreaOptions"/>
148 <enum-type name="QMdiArea::AreaOption" flags="QMdiArea::AreaOptions"/>
149 <enum-type name="QMdiArea::WindowOrder"/>
149 <enum-type name="QMdiArea::WindowOrder"/>
150 <enum-type name="QMdiArea::ViewMode"/>
150 <enum-type name="QMdiArea::ViewMode"/>
151 <enum-type name="QFileSystemModel::Roles"/>
151 <enum-type name="QFileSystemModel::Roles"/>
152 <enum-type name="QFormLayout::FieldGrowthPolicy"/>
152 <enum-type name="QFormLayout::FieldGrowthPolicy"/>
153 <enum-type name="QFormLayout::FormStyle"/>
153 <enum-type name="QFormLayout::FormStyle"/>
154 <enum-type name="QFormLayout::ItemRole"/>
154 <enum-type name="QFormLayout::ItemRole"/>
155 <enum-type name="QFormLayout::RowWrapPolicy"/>
155 <enum-type name="QFormLayout::RowWrapPolicy"/>
156 <enum-type name="QGraphicsProxyWidget::enum_1"/>
156 <enum-type name="QGraphicsProxyWidget::enum_1"/>
157 <enum-type name="QGraphicsWidget::enum_1"/>
157 <enum-type name="QGraphicsWidget::enum_1"/>
158 <enum-type name="QPlainTextEdit::LineWrapMode"/>
158 <enum-type name="QPlainTextEdit::LineWrapMode"/>
159 <enum-type name="QPrintPreviewWidget::ViewMode"/>
159 <enum-type name="QPrintPreviewWidget::ViewMode"/>
160 <enum-type name="QPrintPreviewWidget::ZoomMode"/>
160 <enum-type name="QPrintPreviewWidget::ZoomMode"/>
161 <enum-type name="QStyleOptionTab::StyleOptionVersion"/>
161 <enum-type name="QStyleOptionTab::StyleOptionVersion"/>
162 <enum-type name="QStyleOptionFrame::StyleOptionVersion"/>
162 <enum-type name="QStyleOptionFrame::StyleOptionVersion"/>
163 <enum-type name="QStyleOptionViewItem::StyleOptionVersion"/>
163 <enum-type name="QStyleOptionViewItem::StyleOptionVersion"/>
164 <enum-type name="QStyleOptionViewItem::ViewItemPosition"/>
164 <enum-type name="QStyleOptionViewItem::ViewItemPosition"/>
165
165
166 <enum-type name="QMdiSubWindow::SubWindowOption" flags="QMdiSubWindow::SubWindowOptions"/>
166 <enum-type name="QMdiSubWindow::SubWindowOption" flags="QMdiSubWindow::SubWindowOptions"/>
167
167
168 <enum-type name="QAction::ActionEvent"/>
168 <enum-type name="QAction::ActionEvent"/>
169 <enum-type name="QAction::MenuRole"/>
169 <enum-type name="QAction::MenuRole"/>
170 <enum-type name="QApplication::ColorSpec"/>
170 <enum-type name="QApplication::ColorSpec"/>
171 <enum-type name="QApplication::Type"/>
171 <enum-type name="QApplication::Type"/>
172 <enum-type name="QCalendarWidget::HorizontalHeaderFormat"/>
172 <enum-type name="QCalendarWidget::HorizontalHeaderFormat"/>
173 <enum-type name="QCalendarWidget::SelectionMode"/>
173 <enum-type name="QCalendarWidget::SelectionMode"/>
174 <enum-type name="QCalendarWidget::VerticalHeaderFormat"/>
174 <enum-type name="QCalendarWidget::VerticalHeaderFormat"/>
175 <enum-type name="QColor::Spec"/>
175 <enum-type name="QColor::Spec"/>
176 <enum-type name="QColormap::Mode"/>
176 <enum-type name="QColormap::Mode"/>
177 <enum-type name="QComboBox::InsertPolicy"/>
177 <enum-type name="QComboBox::InsertPolicy"/>
178 <enum-type name="QComboBox::SizeAdjustPolicy"/>
178 <enum-type name="QComboBox::SizeAdjustPolicy"/>
179 <enum-type name="QCompleter::CompletionMode"/>
179 <enum-type name="QCompleter::CompletionMode"/>
180 <enum-type name="QCompleter::ModelSorting"/>
180 <enum-type name="QCompleter::ModelSorting"/>
181 <enum-type name="QContextMenuEvent::Reason"/>
181 <enum-type name="QContextMenuEvent::Reason"/>
182 <enum-type name="QDataWidgetMapper::SubmitPolicy"/>
182 <enum-type name="QDataWidgetMapper::SubmitPolicy"/>
183 <enum-type name="QDateTimeEdit::Section" flags="QDateTimeEdit::Sections"/>
183 <enum-type name="QDateTimeEdit::Section" flags="QDateTimeEdit::Sections"/>
184 <enum-type name="QDialog::DialogCode"/>
184 <enum-type name="QDialog::DialogCode"/>
185 <enum-type name="QDialogButtonBox::ButtonLayout"/>
185 <enum-type name="QDialogButtonBox::ButtonLayout"/>
186 <enum-type name="QDialogButtonBox::ButtonRole"/>
186 <enum-type name="QDialogButtonBox::ButtonRole"/>
187 <enum-type name="QFileDialog::AcceptMode"/>
187 <enum-type name="QFileDialog::AcceptMode"/>
188 <enum-type name="QFileDialog::DialogLabel"/>
188 <enum-type name="QFileDialog::DialogLabel"/>
189 <enum-type name="QFileDialog::FileMode"/>
189 <enum-type name="QFileDialog::FileMode"/>
190 <enum-type name="QFileDialog::Option" flags="QFileDialog::Options"/>
190 <enum-type name="QFileDialog::Option" flags="QFileDialog::Options"/>
191 <enum-type name="QFileDialog::ViewMode"/>
191 <enum-type name="QFileDialog::ViewMode"/>
192 <enum-type name="QFileIconProvider::IconType"/>
192 <enum-type name="QFileIconProvider::IconType"/>
193 <enum-type name="QFont::Stretch"/>
193 <enum-type name="QFont::Stretch"/>
194 <enum-type name="QFont::Style"/>
194 <enum-type name="QFont::Style"/>
195 <enum-type name="QFont::StyleStrategy"/>
195 <enum-type name="QFont::StyleStrategy"/>
196 <enum-type name="QFont::Weight"/>
196 <enum-type name="QFont::Weight"/>
197 <enum-type name="QFontComboBox::FontFilter" flags="QFontComboBox::FontFilters"/>
197 <enum-type name="QFontComboBox::FontFilter" flags="QFontComboBox::FontFilters"/>
198 <enum-type name="QFrame::Shadow" extensible="yes"/>
198 <enum-type name="QFrame::Shadow" extensible="yes"/>
199 <enum-type name="QFrame::Shape"/>
199 <enum-type name="QFrame::Shape"/>
200 <enum-type name="QFrame::StyleMask"/>
200 <enum-type name="QFrame::StyleMask"/>
201 <enum-type name="QGradient::CoordinateMode"/>
201 <enum-type name="QGradient::CoordinateMode"/>
202 <enum-type name="QGradient::Spread" lower-bound="QGradient.PadSpread" upper-bound="QGradient.RepeatSpread"/>
202 <enum-type name="QGradient::Spread" lower-bound="QGradient.PadSpread" upper-bound="QGradient.RepeatSpread"/>
203 <enum-type name="QGradient::Type"/>
203 <enum-type name="QGradient::Type"/>
204 <enum-type name="QGraphicsEllipseItem::enum_1"/>
204 <enum-type name="QGraphicsEllipseItem::enum_1"/>
205 <enum-type name="QGraphicsItem::Extension"/>
205 <enum-type name="QGraphicsItem::Extension"/>
206 <enum-type name="QGraphicsItem::GraphicsItemChange"/>
206 <enum-type name="QGraphicsItem::GraphicsItemChange"/>
207 <enum-type name="QGraphicsItem::GraphicsItemFlag" flags="QGraphicsItem::GraphicsItemFlags"/>
207 <enum-type name="QGraphicsItem::GraphicsItemFlag" flags="QGraphicsItem::GraphicsItemFlags"/>
208 <enum-type name="QGraphicsItem::enum_1"/>
208 <enum-type name="QGraphicsItem::enum_1"/>
209 <enum-type name="QGraphicsItemGroup::enum_1"/>
209 <enum-type name="QGraphicsItemGroup::enum_1"/>
210 <enum-type name="QGraphicsLineItem::enum_1"/>
210 <enum-type name="QGraphicsLineItem::enum_1"/>
211 <enum-type name="QGraphicsPathItem::enum_1"/>
211 <enum-type name="QGraphicsPathItem::enum_1"/>
212 <enum-type name="QGraphicsPixmapItem::ShapeMode"/>
212 <enum-type name="QGraphicsPixmapItem::ShapeMode"/>
213 <enum-type name="QGraphicsPixmapItem::enum_1"/>
213 <enum-type name="QGraphicsPixmapItem::enum_1"/>
214 <enum-type name="QGraphicsPolygonItem::enum_1"/>
214 <enum-type name="QGraphicsPolygonItem::enum_1"/>
215 <enum-type name="QGraphicsRectItem::enum_1"/>
215 <enum-type name="QGraphicsRectItem::enum_1"/>
216 <enum-type name="QGraphicsScene::ItemIndexMethod"/>
216 <enum-type name="QGraphicsScene::ItemIndexMethod"/>
217 <enum-type name="QGraphicsSceneContextMenuEvent::Reason"/>
217 <enum-type name="QGraphicsSceneContextMenuEvent::Reason"/>
218 <enum-type name="QGraphicsSimpleTextItem::enum_1"/>
218 <enum-type name="QGraphicsSimpleTextItem::enum_1"/>
219 <enum-type name="QGraphicsTextItem::enum_1"/>
219 <enum-type name="QGraphicsTextItem::enum_1"/>
220 <enum-type name="QGraphicsView::CacheModeFlag" flags="QGraphicsView::CacheMode"/>
220 <enum-type name="QGraphicsView::CacheModeFlag" flags="QGraphicsView::CacheMode"/>
221 <enum-type name="QGraphicsView::DragMode"/>
221 <enum-type name="QGraphicsView::DragMode"/>
222 <enum-type name="QGraphicsView::OptimizationFlag" flags="QGraphicsView::OptimizationFlags"/>
222 <enum-type name="QGraphicsView::OptimizationFlag" flags="QGraphicsView::OptimizationFlags"/>
223 <enum-type name="QGraphicsView::ViewportAnchor"/>
223 <enum-type name="QGraphicsView::ViewportAnchor"/>
224 <enum-type name="QGraphicsView::ViewportUpdateMode"/>
224 <enum-type name="QGraphicsView::ViewportUpdateMode"/>
225 <enum-type name="QIcon::Mode"/>
225 <enum-type name="QIcon::Mode"/>
226 <enum-type name="QIcon::State"/>
226 <enum-type name="QIcon::State"/>
227 <enum-type name="QImage::Format"/>
227 <enum-type name="QImage::Format"/>
228 <enum-type name="QImage::InvertMode"/>
228 <enum-type name="QImage::InvertMode"/>
229 <enum-type name="QImageIOHandler::ImageOption"/>
229 <enum-type name="QImageIOHandler::ImageOption"/>
230 <enum-type name="QImageReader::ImageReaderError"/>
230 <enum-type name="QImageReader::ImageReaderError"/>
231 <enum-type name="QImageWriter::ImageWriterError"/>
231 <enum-type name="QImageWriter::ImageWriterError"/>
232 <enum-type name="QInputContext::StandardFormat"/>
232 <enum-type name="QInputContext::StandardFormat"/>
233 <enum-type name="QInputMethodEvent::AttributeType"/>
233 <enum-type name="QInputMethodEvent::AttributeType"/>
234 <enum-type name="QItemSelectionModel::SelectionFlag" flags="QItemSelectionModel::SelectionFlags"/>
234 <enum-type name="QItemSelectionModel::SelectionFlag" flags="QItemSelectionModel::SelectionFlags"/>
235 <enum-type name="QKeySequence::SequenceFormat"/>
235 <enum-type name="QKeySequence::SequenceFormat"/>
236 <enum-type name="QKeySequence::SequenceMatch"/>
236 <enum-type name="QKeySequence::SequenceMatch"/>
237 <enum-type name="QKeySequence::StandardKey"/>
237 <enum-type name="QKeySequence::StandardKey"/>
238 <enum-type name="QLCDNumber::Mode"/>
238 <enum-type name="QLCDNumber::Mode"/>
239 <enum-type name="QLCDNumber::SegmentStyle"/>
239 <enum-type name="QLCDNumber::SegmentStyle"/>
240 <enum-type name="QLayout::SizeConstraint"/>
240 <enum-type name="QLayout::SizeConstraint"/>
241 <enum-type name="QLineEdit::EchoMode"/>
241 <enum-type name="QLineEdit::EchoMode"/>
242 <enum-type name="QLineF::IntersectType"/>
242 <enum-type name="QLineF::IntersectType"/>
243 <enum-type name="QListView::Flow"/>
243 <enum-type name="QListView::Flow"/>
244 <enum-type name="QListView::LayoutMode"/>
244 <enum-type name="QListView::LayoutMode"/>
245 <enum-type name="QListView::Movement"/>
245 <enum-type name="QListView::Movement"/>
246 <enum-type name="QListView::ResizeMode"/>
246 <enum-type name="QListView::ResizeMode"/>
247 <enum-type name="QListView::ViewMode"/>
247 <enum-type name="QListView::ViewMode"/>
248 <enum-type name="QListWidgetItem::ItemType"/>
248 <enum-type name="QListWidgetItem::ItemType"/>
249 <enum-type name="QMainWindow::DockOption" flags="QMainWindow::DockOptions"/>
249 <enum-type name="QMainWindow::DockOption" flags="QMainWindow::DockOptions"/>
250 <enum-type name="QMessageBox::ButtonRole"/>
250 <enum-type name="QMessageBox::ButtonRole"/>
251 <enum-type name="QMessageBox::Icon"/>
251 <enum-type name="QMessageBox::Icon"/>
252 <enum-type name="QMovie::CacheMode"/>
252 <enum-type name="QMovie::CacheMode"/>
253 <enum-type name="QMovie::MovieState"/>
253 <enum-type name="QMovie::MovieState"/>
254 <enum-type name="QPaintDevice::PaintDeviceMetric"/>
254 <enum-type name="QPaintDevice::PaintDeviceMetric"/>
255 <enum-type name="QPaintEngine::DirtyFlag" flags="QPaintEngine::DirtyFlags"/>
255 <enum-type name="QPaintEngine::DirtyFlag" flags="QPaintEngine::DirtyFlags"/>
256 <enum-type name="QPaintEngine::PaintEngineFeature" flags="QPaintEngine::PaintEngineFeatures"/>
256 <enum-type name="QPaintEngine::PaintEngineFeature" flags="QPaintEngine::PaintEngineFeatures"/>
257 <enum-type name="QPaintEngine::PolygonDrawMode"/>
257 <enum-type name="QPaintEngine::PolygonDrawMode"/>
258 <enum-type name="QPaintEngine::Type"/>
258 <enum-type name="QPaintEngine::Type"/>
259 <enum-type name="QPageSetupDialog::PageSetupDialogOption" flags="QPageSetupDialog::PageSetupDialogOptions"/>
259 <enum-type name="QPageSetupDialog::PageSetupDialogOption" flags="QPageSetupDialog::PageSetupDialogOptions"/>
260 <enum-type name="QPainter::CompositionMode"/>
260 <enum-type name="QPainter::CompositionMode"/>
261 <enum-type name="QPainter::PixmapFragmentHint"/>
261 <enum-type name="QPainter::PixmapFragmentHint"/>
262 <enum-type name="QPainter::RenderHint" flags="QPainter::RenderHints"/>
262 <enum-type name="QPainter::RenderHint" flags="QPainter::RenderHints"/>
263 <enum-type name="QPainterPath::ElementType"/>
263 <enum-type name="QPainterPath::ElementType"/>
264 <enum-type name="QPrintEngine::PrintEnginePropertyKey">
264 <enum-type name="QPrintEngine::PrintEnginePropertyKey">
265 <reject-enum-value name="PPK_PaperSize"/>
265 <reject-enum-value name="PPK_PaperSize"/>
266 </enum-type>
266 </enum-type>
267 <enum-type name="QPrinter::ColorMode"/>
267 <enum-type name="QPrinter::ColorMode"/>
268 <enum-type name="QPrinter::Orientation"/>
268 <enum-type name="QPrinter::Orientation"/>
269 <enum-type name="QPrinter::OutputFormat"/>
269 <enum-type name="QPrinter::OutputFormat"/>
270 <enum-type name="QPrinter::PageOrder"/>
270 <enum-type name="QPrinter::PageOrder"/>
271 <enum-type name="QPrinter::PaperSource"/>
271 <enum-type name="QPrinter::PaperSource"/>
272 <enum-type name="QPrinter::PrintRange"/>
272 <enum-type name="QPrinter::PrintRange"/>
273 <enum-type name="QPrinter::PrinterMode"/>
273 <enum-type name="QPrinter::PrinterMode"/>
274 <enum-type name="QPrinter::PrinterState"/>
274 <enum-type name="QPrinter::PrinterState"/>
275 <enum-type name="QPrinter::Unit"/>
275 <enum-type name="QPrinter::Unit"/>
276 <enum-type name="QPrinter::DuplexMode"/>
276 <enum-type name="QPrinter::DuplexMode"/>
277 <enum-type name="QProgressBar::Direction"/>
277 <enum-type name="QProgressBar::Direction"/>
278 <enum-type name="QRegion::RegionType"/>
278 <enum-type name="QRegion::RegionType"/>
279 <enum-type name="QRubberBand::Shape"/>
279 <enum-type name="QRubberBand::Shape"/>
280 <enum-type name="QSessionManager::RestartHint"/>
280 <enum-type name="QSessionManager::RestartHint"/>
281 <enum-type name="QSizePolicy::Policy"/>
281 <enum-type name="QSizePolicy::Policy"/>
282 <enum-type name="QSizePolicy::PolicyFlag"/>
282 <enum-type name="QSizePolicy::PolicyFlag"/>
283 <enum-type name="QSizePolicy::ControlType" flags="QSizePolicy::ControlTypes"/>
283 <enum-type name="QSizePolicy::ControlType" flags="QSizePolicy::ControlTypes"/>
284 <enum-type name="QStandardItem::ItemType"/>
284 <enum-type name="QStandardItem::ItemType"/>
285 <enum-type name="QStyle::SubControl" flags="QStyle::SubControls" extensible="yes" force-integer="yes"/>
285 <enum-type name="QStyle::SubControl" flags="QStyle::SubControls" extensible="yes" force-integer="yes"/>
286 <enum-type name="QStyle::ComplexControl" extensible="yes"/>
286 <enum-type name="QStyle::ComplexControl" extensible="yes"/>
287 <enum-type name="QStyle::ContentsType" extensible="yes"/>
287 <enum-type name="QStyle::ContentsType" extensible="yes"/>
288 <enum-type name="QStyle::ControlElement" extensible="yes"/>
288 <enum-type name="QStyle::ControlElement" extensible="yes"/>
289 <enum-type name="QStyle::PixelMetric" extensible="yes">
289 <enum-type name="QStyle::PixelMetric" extensible="yes">
290 <reject-enum-value name="PM_MDIFrameWidth"/>
290 <reject-enum-value name="PM_MDIFrameWidth"/>
291 <reject-enum-value name="PM_MDIMinimizedWidth"/>
291 <reject-enum-value name="PM_MDIMinimizedWidth"/>
292 </enum-type>
292 </enum-type>
293 <enum-type name="QStyle::PrimitiveElement" extensible="yes">
293 <enum-type name="QStyle::PrimitiveElement" extensible="yes">
294 <reject-enum-value name="PE_IndicatorItemViewItemCheck"/>
294 <reject-enum-value name="PE_IndicatorItemViewItemCheck"/>
295 <reject-enum-value name="PE_FrameStatusBarItem"/>
295 <reject-enum-value name="PE_FrameStatusBarItem"/>
296 </enum-type>
296 </enum-type>
297 <enum-type name="QStyle::StandardPixmap" extensible="yes"/>
297 <enum-type name="QStyle::StandardPixmap" extensible="yes"/>
298 <enum-type name="QStyle::StateFlag" flags="QStyle::State"/>
298 <enum-type name="QStyle::StateFlag" flags="QStyle::State"/>
299 <enum-type name="QStyle::SubElement" extensible="yes">
299 <enum-type name="QStyle::SubElement" extensible="yes">
300 <reject-enum-value name="SE_ItemViewItemCheckIndicator"/>
300 <reject-enum-value name="SE_ItemViewItemCheckIndicator"/>
301 </enum-type>
301 </enum-type>
302 <enum-type name="QStyleHintReturn::HintReturnType"/>
302 <enum-type name="QStyleHintReturn::HintReturnType"/>
303 <enum-type name="QStyleHintReturn::StyleOptionType"/>
303 <enum-type name="QStyleHintReturn::StyleOptionType"/>
304 <enum-type name="QStyleHintReturn::StyleOptionVersion"/>
304 <enum-type name="QStyleHintReturn::StyleOptionVersion"/>
305 <enum-type name="QStyleHintReturnVariant::StyleOptionType"/>
305 <enum-type name="QStyleHintReturnVariant::StyleOptionType"/>
306 <enum-type name="QStyleHintReturnVariant::StyleOptionVersion"/>
306 <enum-type name="QStyleHintReturnVariant::StyleOptionVersion"/>
307
307
308 <enum-type name="QStyleHintReturnMask::StyleOptionType"/>
308 <enum-type name="QStyleHintReturnMask::StyleOptionType"/>
309 <enum-type name="QStyleHintReturnMask::StyleOptionVersion"/>
309 <enum-type name="QStyleHintReturnMask::StyleOptionVersion"/>
310 <enum-type name="QStyleOption::StyleOptionType"/>
310 <enum-type name="QStyleOption::StyleOptionType"/>
311 <enum-type name="QStyleOption::OptionType" extensible="yes"/>
311 <enum-type name="QStyleOption::OptionType" extensible="yes"/>
312 <enum-type name="QStyleOption::StyleOptionVersion"/>
312 <enum-type name="QStyleOption::StyleOptionVersion"/>
313 <enum-type name="QStyleOptionButton::ButtonFeature" flags="QStyleOptionButton::ButtonFeatures"/>
313 <enum-type name="QStyleOptionButton::ButtonFeature" flags="QStyleOptionButton::ButtonFeatures"/>
314 <enum-type name="QStyleOptionButton::StyleOptionType"/>
314 <enum-type name="QStyleOptionButton::StyleOptionType"/>
315 <enum-type name="QStyleOptionButton::StyleOptionVersion"/>
315 <enum-type name="QStyleOptionButton::StyleOptionVersion"/>
316 <enum-type name="QStyleOptionComboBox::StyleOptionType"/>
316 <enum-type name="QStyleOptionComboBox::StyleOptionType"/>
317 <enum-type name="QStyleOptionComboBox::StyleOptionVersion"/>
317 <enum-type name="QStyleOptionComboBox::StyleOptionVersion"/>
318 <enum-type name="QStyleOptionComplex::StyleOptionType"/>
318 <enum-type name="QStyleOptionComplex::StyleOptionType"/>
319 <enum-type name="QStyleOptionComplex::StyleOptionVersion"/>
319 <enum-type name="QStyleOptionComplex::StyleOptionVersion"/>
320 <enum-type name="QStyleOptionDockWidget::StyleOptionType"/>
320 <enum-type name="QStyleOptionDockWidget::StyleOptionType"/>
321 <enum-type name="QStyleOptionDockWidget::StyleOptionVersion"/>
321 <enum-type name="QStyleOptionDockWidget::StyleOptionVersion"/>
322 <enum-type name="QStyleOptionFocusRect::StyleOptionType"/>
322 <enum-type name="QStyleOptionFocusRect::StyleOptionType"/>
323 <enum-type name="QStyleOptionFocusRect::StyleOptionVersion"/>
323 <enum-type name="QStyleOptionFocusRect::StyleOptionVersion"/>
324 <enum-type name="QStyleOptionFrame::StyleOptionType"/>
324 <enum-type name="QStyleOptionFrame::StyleOptionType"/>
325 <enum-type name="QStyleOptionFrame::FrameFeature" flags="QStyleOptionFrame::FrameFeatures"/>
325 <enum-type name="QStyleOptionFrame::FrameFeature" flags="QStyleOptionFrame::FrameFeatures"/>
326 <enum-type name="QStyleOptionGraphicsItem::StyleOptionType"/>
326 <enum-type name="QStyleOptionGraphicsItem::StyleOptionType"/>
327 <enum-type name="QStyleOptionGraphicsItem::StyleOptionVersion"/>
327 <enum-type name="QStyleOptionGraphicsItem::StyleOptionVersion"/>
328 <enum-type name="QStyleOptionGroupBox::StyleOptionType"/>
328 <enum-type name="QStyleOptionGroupBox::StyleOptionType"/>
329 <enum-type name="QStyleOptionGroupBox::StyleOptionVersion"/>
329 <enum-type name="QStyleOptionGroupBox::StyleOptionVersion"/>
330 <enum-type name="QStyleOptionHeader::SectionPosition"/>
330 <enum-type name="QStyleOptionHeader::SectionPosition"/>
331 <enum-type name="QStyleOptionHeader::SelectedPosition"/>
331 <enum-type name="QStyleOptionHeader::SelectedPosition"/>
332 <enum-type name="QStyleOptionHeader::SortIndicator"/>
332 <enum-type name="QStyleOptionHeader::SortIndicator"/>
333 <enum-type name="QStyleOptionHeader::StyleOptionType"/>
333 <enum-type name="QStyleOptionHeader::StyleOptionType"/>
334 <enum-type name="QStyleOptionHeader::StyleOptionVersion"/>
334 <enum-type name="QStyleOptionHeader::StyleOptionVersion"/>
335 <enum-type name="QStyleOptionMenuItem::CheckType"/>
335 <enum-type name="QStyleOptionMenuItem::CheckType"/>
336 <enum-type name="QStyleOptionMenuItem::MenuItemType"/>
336 <enum-type name="QStyleOptionMenuItem::MenuItemType"/>
337 <enum-type name="QStyleOptionMenuItem::StyleOptionType"/>
337 <enum-type name="QStyleOptionMenuItem::StyleOptionType"/>
338 <enum-type name="QStyleOptionMenuItem::StyleOptionVersion"/>
338 <enum-type name="QStyleOptionMenuItem::StyleOptionVersion"/>
339 <enum-type name="QStyleOptionProgressBar::StyleOptionType"/>
339 <enum-type name="QStyleOptionProgressBar::StyleOptionType"/>
340 <enum-type name="QStyleOptionProgressBar::StyleOptionVersion"/>
340 <enum-type name="QStyleOptionProgressBar::StyleOptionVersion"/>
341 <enum-type name="QStyleOptionRubberBand::StyleOptionType"/>
341 <enum-type name="QStyleOptionRubberBand::StyleOptionType"/>
342 <enum-type name="QStyleOptionRubberBand::StyleOptionVersion"/>
342 <enum-type name="QStyleOptionRubberBand::StyleOptionVersion"/>
343 <enum-type name="QStyleOptionSizeGrip::StyleOptionType"/>
343 <enum-type name="QStyleOptionSizeGrip::StyleOptionType"/>
344 <enum-type name="QStyleOptionSizeGrip::StyleOptionVersion"/>
344 <enum-type name="QStyleOptionSizeGrip::StyleOptionVersion"/>
345 <enum-type name="QStyleOptionSlider::StyleOptionType"/>
345 <enum-type name="QStyleOptionSlider::StyleOptionType"/>
346 <enum-type name="QStyleOptionSlider::StyleOptionVersion"/>
346 <enum-type name="QStyleOptionSlider::StyleOptionVersion"/>
347 <enum-type name="QStyleOptionSpinBox::StyleOptionType"/>
347 <enum-type name="QStyleOptionSpinBox::StyleOptionType"/>
348 <enum-type name="QStyleOptionSpinBox::StyleOptionVersion"/>
348 <enum-type name="QStyleOptionSpinBox::StyleOptionVersion"/>
349 <enum-type name="QStyleOptionTab::CornerWidget" flags="QStyleOptionTab::CornerWidgets"/>
349 <enum-type name="QStyleOptionTab::CornerWidget" flags="QStyleOptionTab::CornerWidgets"/>
350 <enum-type name="QStyleOptionTab::SelectedPosition"/>
350 <enum-type name="QStyleOptionTab::SelectedPosition"/>
351 <enum-type name="QStyleOptionTab::StyleOptionType"/>
351 <enum-type name="QStyleOptionTab::StyleOptionType"/>
352 <enum-type name="QStyleOptionTab::TabPosition"/>
352 <enum-type name="QStyleOptionTab::TabPosition"/>
353 <enum-type name="QStyleOptionTabBarBase::StyleOptionType"/>
353 <enum-type name="QStyleOptionTabBarBase::StyleOptionType"/>
354 <enum-type name="QStyleOptionTabWidgetFrame::StyleOptionType"/>
354 <enum-type name="QStyleOptionTabWidgetFrame::StyleOptionType"/>
355 <enum-type name="QStyleOptionTabWidgetFrame::StyleOptionVersion"/>
355 <enum-type name="QStyleOptionTabWidgetFrame::StyleOptionVersion"/>
356 <enum-type name="QStyleOptionTitleBar::StyleOptionType"/>
356 <enum-type name="QStyleOptionTitleBar::StyleOptionType"/>
357 <enum-type name="QStyleOptionTitleBar::StyleOptionVersion"/>
357 <enum-type name="QStyleOptionTitleBar::StyleOptionVersion"/>
358 <enum-type name="QStyleOptionToolBar::StyleOptionType"/>
358 <enum-type name="QStyleOptionToolBar::StyleOptionType"/>
359 <enum-type name="QStyleOptionToolBar::StyleOptionVersion"/>
359 <enum-type name="QStyleOptionToolBar::StyleOptionVersion"/>
360 <enum-type name="QStyleOptionToolBar::ToolBarFeature" flags="QStyleOptionToolBar::ToolBarFeatures"/>
360 <enum-type name="QStyleOptionToolBar::ToolBarFeature" flags="QStyleOptionToolBar::ToolBarFeatures"/>
361 <enum-type name="QStyleOptionToolBar::ToolBarPosition"/>
361 <enum-type name="QStyleOptionToolBar::ToolBarPosition"/>
362 <enum-type name="QStyleOptionToolBox::StyleOptionType"/>
362 <enum-type name="QStyleOptionToolBox::StyleOptionType"/>
363 <enum-type name="QStyleOptionToolBox::StyleOptionVersion"/>
363 <enum-type name="QStyleOptionToolBox::StyleOptionVersion"/>
364 <enum-type name="QStyleOptionToolButton::StyleOptionType"/>
364 <enum-type name="QStyleOptionToolButton::StyleOptionType"/>
365 <enum-type name="QStyleOptionToolButton::StyleOptionVersion"/>
365 <enum-type name="QStyleOptionToolButton::StyleOptionVersion"/>
366 <enum-type name="QStyleOptionToolButton::ToolButtonFeature" flags="QStyleOptionToolButton::ToolButtonFeatures">
366 <enum-type name="QStyleOptionToolButton::ToolButtonFeature" flags="QStyleOptionToolButton::ToolButtonFeatures">
367 <reject-enum-value name="MenuButtonPopup"/>
367 <reject-enum-value name="MenuButtonPopup"/>
368 </enum-type>
368 </enum-type>
369 <enum-type name="QStyleOptionViewItem::Position"/>
369 <enum-type name="QStyleOptionViewItem::Position"/>
370 <enum-type name="QStyleOptionViewItem::StyleOptionType"/>
370 <enum-type name="QStyleOptionViewItem::StyleOptionType"/>
371 <enum-type name="QStyleOptionViewItem::ViewItemFeature" flags="QStyleOptionViewItem::ViewItemFeatures"/>
371 <enum-type name="QStyleOptionViewItem::ViewItemFeature" flags="QStyleOptionViewItem::ViewItemFeatures"/>
372 <enum-type name="QSystemTrayIcon::ActivationReason"/>
372 <enum-type name="QSystemTrayIcon::ActivationReason"/>
373 <enum-type name="QSystemTrayIcon::MessageIcon"/>
373 <enum-type name="QSystemTrayIcon::MessageIcon"/>
374 <enum-type name="QTabBar::Shape"/>
374 <enum-type name="QTabBar::Shape"/>
375 <enum-type name="QTabWidget::TabPosition"/>
375 <enum-type name="QTabWidget::TabPosition"/>
376 <enum-type name="QTabWidget::TabShape"/>
376 <enum-type name="QTabWidget::TabShape"/>
377 <enum-type name="QTableWidgetItem::ItemType"/>
377 <enum-type name="QTableWidgetItem::ItemType"/>
378 <enum-type name="QTabletEvent::PointerType"/>
378 <enum-type name="QTabletEvent::PointerType"/>
379 <enum-type name="QTabletEvent::TabletDevice"/>
379 <enum-type name="QTabletEvent::TabletDevice"/>
380 <enum-type name="QTextCharFormat::UnderlineStyle"/>
380 <enum-type name="QTextCharFormat::UnderlineStyle"/>
381 <enum-type name="QTextCharFormat::VerticalAlignment"/>
381 <enum-type name="QTextCharFormat::VerticalAlignment"/>
382 <enum-type name="QTextCursor::MoveMode"/>
382 <enum-type name="QTextCursor::MoveMode"/>
383 <enum-type name="QTextCursor::MoveOperation"/>
383 <enum-type name="QTextCursor::MoveOperation"/>
384 <enum-type name="QTextCursor::SelectionType"/>
384 <enum-type name="QTextCursor::SelectionType"/>
385 <enum-type name="QTextDocument::FindFlag" flags="QTextDocument::FindFlags"/>
385 <enum-type name="QTextDocument::FindFlag" flags="QTextDocument::FindFlags"/>
386 <enum-type name="QTextDocument::MetaInformation"/>
386 <enum-type name="QTextDocument::MetaInformation"/>
387 <enum-type name="QTextDocument::ResourceType"/>
387 <enum-type name="QTextDocument::ResourceType"/>
388 <enum-type name="QTextDocument::Stacks"/>
388 <enum-type name="QTextDocument::Stacks"/>
389 <enum-type name="QTextEdit::AutoFormattingFlag" flags="QTextEdit::AutoFormatting"/>
389 <enum-type name="QTextEdit::AutoFormattingFlag" flags="QTextEdit::AutoFormatting"/>
390 <enum-type name="QTextEdit::LineWrapMode"/>
390 <enum-type name="QTextEdit::LineWrapMode"/>
391 <enum-type name="QTextFormat::ObjectTypes"/>
391 <enum-type name="QTextFormat::ObjectTypes"/>
392 <enum-type name="QTextFormat::PageBreakFlag" flags="QTextFormat::PageBreakFlags"/>
392 <enum-type name="QTextFormat::PageBreakFlag" flags="QTextFormat::PageBreakFlags"/>
393 <enum-type name="QTextFrameFormat::Position"/>
393 <enum-type name="QTextFrameFormat::Position"/>
394 <enum-type name="QTextFrameFormat::BorderStyle"/>
394 <enum-type name="QTextFrameFormat::BorderStyle"/>
395 <enum-type name="QTextItem::RenderFlag" flags="QTextItem::RenderFlags"/>
395 <enum-type name="QTextItem::RenderFlag" flags="QTextItem::RenderFlags"/>
396 <enum-type name="QTextLayout::CursorMode"/>
396 <enum-type name="QTextLayout::CursorMode"/>
397 <enum-type name="QTextLength::Type"/>
397 <enum-type name="QTextLength::Type"/>
398 <enum-type name="QTextLine::CursorPosition"/>
398 <enum-type name="QTextLine::CursorPosition"/>
399 <enum-type name="QTextLine::Edge"/>
399 <enum-type name="QTextLine::Edge"/>
400 <enum-type name="QTextListFormat::Style"/>
400 <enum-type name="QTextListFormat::Style"/>
401 <enum-type name="QTextOption::Flag" flags="QTextOption::Flags"/>
401 <enum-type name="QTextOption::Flag" flags="QTextOption::Flags"/>
402 <enum-type name="QTextOption::WrapMode"/>
402 <enum-type name="QTextOption::WrapMode"/>
403 <enum-type name="QTextOption::TabType"/>
403 <enum-type name="QTextOption::TabType"/>
404 <enum-type name="QToolButton::ToolButtonPopupMode"/>
404 <enum-type name="QToolButton::ToolButtonPopupMode"/>
405 <enum-type name="QTreeWidgetItem::ItemType"/>
405 <enum-type name="QTreeWidgetItem::ItemType"/>
406 <enum-type name="QTreeWidgetItemIterator::IteratorFlag" flags="QTreeWidgetItemIterator::IteratorFlags"/>
406 <enum-type name="QTreeWidgetItemIterator::IteratorFlag" flags="QTreeWidgetItemIterator::IteratorFlags"/>
407 <enum-type name="QValidator::State"/>
407 <enum-type name="QValidator::State"/>
408 <enum-type name="QWidget::RenderFlag" flags="QWidget::RenderFlags"/>
408 <enum-type name="QWidget::RenderFlag" flags="QWidget::RenderFlags"/>
409 <enum-type name="QWorkspace::WindowOrder"/>
409 <enum-type name="QWorkspace::WindowOrder"/>
410 <enum-type name="QDoubleValidator::Notation"/>
410 <enum-type name="QDoubleValidator::Notation"/>
411 <enum-type name="QGraphicsScene::SceneLayer" flags="QGraphicsScene::SceneLayers"/>
411 <enum-type name="QGraphicsScene::SceneLayer" flags="QGraphicsScene::SceneLayers"/>
412 <enum-type name="QStyleOptionToolBox::SelectedPosition"/>
412 <enum-type name="QStyleOptionToolBox::SelectedPosition"/>
413 <enum-type name="QStyleOptionToolBox::TabPosition"/>
413 <enum-type name="QStyleOptionToolBox::TabPosition"/>
414 <enum-type name="QTransform::TransformationType"/>
414 <enum-type name="QTransform::TransformationType"/>
415 <enum-type name="QTreeWidgetItem::ChildIndicatorPolicy"/>
415 <enum-type name="QTreeWidgetItem::ChildIndicatorPolicy"/>
416 <enum-type name="QWizard::WizardOption" flags="QWizard::WizardOptions"/>
416 <enum-type name="QWizard::WizardOption" flags="QWizard::WizardOptions"/>
417 <enum-type name="QWizard::WizardPixmap"/>
417 <enum-type name="QWizard::WizardPixmap"/>
418 <enum-type name="QWizard::WizardStyle"/>
418 <enum-type name="QWizard::WizardStyle"/>
419 <enum-type name="QImageIOPlugin::Capability" flags="QImageIOPlugin::Capabilities"/>
419 <enum-type name="QImageIOPlugin::Capability" flags="QImageIOPlugin::Capabilities"/>
420 <enum-type name="QStackedLayout::StackingMode"/>
420 <enum-type name="QStackedLayout::StackingMode"/>
421
421
422 <enum-type name="QWizard::WizardButton">
422 <enum-type name="QWizard::WizardButton">
423 <reject-enum-value name="NStandardButtons"/>
423 <reject-enum-value name="NStandardButtons"/>
424 <reject-enum-value name="NButtons"/>
424 <reject-enum-value name="NButtons"/>
425 </enum-type>
425 </enum-type>
426
426
427 <enum-type name="QAccessible::Action">
427 <enum-type name="QAccessible::Action">
428 <reject-enum-value name="FirstStandardAction"/>
428 <reject-enum-value name="FirstStandardAction"/>
429 <reject-enum-value name="LastStandardAction"/>
429 <reject-enum-value name="LastStandardAction"/>
430 </enum-type>
430 </enum-type>
431
431
432 <enum-type name="QBoxLayout::Direction">
432 <enum-type name="QBoxLayout::Direction">
433 <reject-enum-value name="Down"/>
433 <reject-enum-value name="Down"/>
434 <reject-enum-value name="Up"/>
434 <reject-enum-value name="Up"/>
435 </enum-type>
435 </enum-type>
436
436
437
437
438 <enum-type name="QClipboard::Mode">
438 <enum-type name="QClipboard::Mode">
439 <reject-enum-value name="LastMode"/>
439 <reject-enum-value name="LastMode"/>
440 </enum-type>
440 </enum-type>
441
441
442 <enum-type name="QDialogButtonBox::StandardButton" flags="QDialogButtonBox::StandardButtons">
442 <enum-type name="QDialogButtonBox::StandardButton" flags="QDialogButtonBox::StandardButtons">
443 <reject-enum-value name="FirstButton"/>
443 <reject-enum-value name="FirstButton"/>
444 <reject-enum-value name="LastButton"/>
444 <reject-enum-value name="LastButton"/>
445 <reject-enum-value name="YesAll"/>
445 <reject-enum-value name="YesAll"/>
446 <reject-enum-value name="NoAll"/>
446 <reject-enum-value name="NoAll"/>
447 <reject-enum-value name="Default"/>
447 <reject-enum-value name="Default"/>
448 <reject-enum-value name="Escape"/>
448 <reject-enum-value name="Escape"/>
449 <reject-enum-value name="FlagMask"/>
449 <reject-enum-value name="FlagMask"/>
450 <reject-enum-value name="ButtonMask"/>
450 <reject-enum-value name="ButtonMask"/>
451 </enum-type>
451 </enum-type>
452
452
453 <enum-type name="QDockWidget::DockWidgetFeature" flags="QDockWidget::DockWidgetFeatures"/>
453 <enum-type name="QDockWidget::DockWidgetFeature" flags="QDockWidget::DockWidgetFeatures"/>
454
454
455 <enum-type name="QFont::StyleHint">
455 <enum-type name="QFont::StyleHint">
456 <reject-enum-value name="SansSerif"/>
456 <reject-enum-value name="SansSerif"/>
457 <reject-enum-value name="Serif"/>
457 <reject-enum-value name="Serif"/>
458 <reject-enum-value name="TypeWriter"/>
458 <reject-enum-value name="TypeWriter"/>
459 <reject-enum-value name="Decorative"/>
459 <reject-enum-value name="Decorative"/>
460 </enum-type>
460 </enum-type>
461
461
462 <enum-type name="QFontDatabase::WritingSystem">
462 <enum-type name="QFontDatabase::WritingSystem">
463 <reject-enum-value name="Other"/>
463 <reject-enum-value name="Other"/>
464 </enum-type>
464 </enum-type>
465
465
466 <enum-type name="QHeaderView::ResizeMode">
466 <enum-type name="QHeaderView::ResizeMode">
467 <reject-enum-value name="Custom"/>
467 <reject-enum-value name="Custom"/>
468 </enum-type>
468 </enum-type>
469
469
470
470
471 <enum-type name="QMessageBox::StandardButton" flags="QMessageBox::StandardButtons">
471 <enum-type name="QMessageBox::StandardButton" flags="QMessageBox::StandardButtons">
472 <reject-enum-value name="FirstButton"/>
472 <reject-enum-value name="FirstButton"/>
473 <reject-enum-value name="LastButton"/>
473 <reject-enum-value name="LastButton"/>
474 <reject-enum-value name="YesAll"/>
474 <reject-enum-value name="YesAll"/>
475 <reject-enum-value name="NoAll"/>
475 <reject-enum-value name="NoAll"/>
476 </enum-type>
476 </enum-type>
477
477
478 <enum-type name="QPalette::ColorGroup">
478 <enum-type name="QPalette::ColorGroup">
479 <reject-enum-value name="Normal"/>
479 <reject-enum-value name="Normal"/>
480 </enum-type>
480 </enum-type>
481
481
482 <enum-type name="QPalette::ColorRole">
482 <enum-type name="QPalette::ColorRole">
483 <reject-enum-value name="NColorRoles"/>
483 <reject-enum-value name="NColorRoles"/>
484 <reject-enum-value name="Foreground"/>
484 <reject-enum-value name="Foreground"/>
485 <reject-enum-value name="Background"/>
485 <reject-enum-value name="Background"/>
486 </enum-type>
486 </enum-type>
487
487
488 <enum-type name="QPrinter::PageSize">
488 <enum-type name="QPrinter::PageSize">
489 <reject-enum-value name="NPageSize"/>
489 <reject-enum-value name="NPageSize"/>
490 <reject-enum-value name="NPaperSize"/>
490 <reject-enum-value name="NPaperSize"/>
491 </enum-type>
491 </enum-type>
492
492
493 <enum-type name="QSlider::TickPosition">
493 <enum-type name="QSlider::TickPosition">
494 <reject-enum-value name="TicksLeft"/>
494 <reject-enum-value name="TicksLeft"/>
495 <reject-enum-value name="TicksRight"/>
495 <reject-enum-value name="TicksRight"/>
496 </enum-type>
496 </enum-type>
497
497
498 <enum-type name="QStyle::StyleHint" extensible="yes">
498 <enum-type name="QStyle::StyleHint" extensible="yes">
499 <reject-enum-value name="SH_ScrollBar_StopMouseOverSlider"/>
499 <reject-enum-value name="SH_ScrollBar_StopMouseOverSlider"/>
500 </enum-type>
500 </enum-type>
501
501
502
502
503 <enum-type name="QTextFormat::FormatType"/>
503 <enum-type name="QTextFormat::FormatType"/>
504
504
505 <enum-type name="QTextFormat::Property">
505 <enum-type name="QTextFormat::Property">
506 <reject-enum-value name="FontSizeIncrement"/>
506 <reject-enum-value name="FontSizeIncrement"/>
507 <reject-enum-value name="FirstFontProperty"/>
507 <reject-enum-value name="FirstFontProperty"/>
508 <reject-enum-value name="LastFontProperty"/>
508 <reject-enum-value name="LastFontProperty"/>
509 </enum-type>
509 </enum-type>
510
510
511 <enum-type name="QAction::Priority"/>
511 <enum-type name="QAction::Priority"/>
512 <enum-type name="QAction::SoftKeyRole"/>
512 <enum-type name="QAction::SoftKeyRole"/>
513 <enum-type name="QGraphicsEffect::ChangeFlag" flags="QGraphicsEffect::ChangeFlags"/>
513 <enum-type name="QGraphicsEffect::ChangeFlag" flags="QGraphicsEffect::ChangeFlags"/>
514 <enum-type name="QGraphicsItem::PanelModality"/>
514 <enum-type name="QGraphicsItem::PanelModality"/>
515 <enum-type name="QPinchGesture::WhatChange" flags="QPinchGesture::WhatChanged"/>
515 <enum-type name="QPinchGesture::WhatChange" flags="QPinchGesture::WhatChanged"/>
516 <enum-type name="QStyle::RequestSoftwareInputPanel"/>
516 <enum-type name="QStyle::RequestSoftwareInputPanel"/>
517 <enum-type name="QSwipeGesture::SwipeDirection"/>
517 <enum-type name="QSwipeGesture::SwipeDirection"/>
518 <enum-type name="QTouchEvent::DeviceType"/>
518 <enum-type name="QTouchEvent::DeviceType"/>
519
519
520 <enum-type name="QTextBlockFormat::LineHeightTypes"/>
520 <enum-type name="QTextBlockFormat::LineHeightTypes"/>
521
521
522
522
523 <value-type name="QPixmapCache::Key"/>
523 <value-type name="QPixmapCache::Key"/>
524 <value-type name="QTileRules"/>
524 <value-type name="QTileRules"/>
525 <value-type name="QVector2D"/>
525 <value-type name="QVector2D"/>
526 <value-type name="QVector3D"/>
526 <value-type name="QVector3D"/>
527 <value-type name="QVector4D"/>
527 <value-type name="QVector4D"/>
528 <value-type name="QTouchEvent::TouchPoint"/>
528 <value-type name="QTouchEvent::TouchPoint"/>
529
529
530
530
531 <value-type name="QTransform">
531 <value-type name="QTransform">
532 <modify-function signature="operator=(QTransform)" remove="all"/>
532 <modify-function signature="operator=(QTransform)" remove="all"/>
533 <modify-function signature="map(int,int,int*,int*)const" remove="all"/>
533 <modify-function signature="map(int,int,int*,int*)const" remove="all"/>
534 <modify-function signature="map(qreal,qreal,qreal*,qreal*)const" remove="all"/>
534 <modify-function signature="map(qreal,qreal,qreal*,qreal*)const" remove="all"/>
535
535
536 <modify-function signature="operator*=(qreal)" access="private"/>
536 <modify-function signature="operator*=(qreal)" access="private"/>
537 <modify-function signature="operator+=(qreal)" access="private"/>
537 <modify-function signature="operator+=(qreal)" access="private"/>
538 <modify-function signature="operator-=(qreal)" access="private"/>
538 <modify-function signature="operator-=(qreal)" access="private"/>
539 <modify-function signature="operator/=(qreal)" access="private"/>
539 <modify-function signature="operator/=(qreal)" access="private"/>
540 <modify-function signature="operator*(QTransform)const" rename="multiplied"/>
540 <modify-function signature="operator*(QTransform)const" rename="multiplied"/>
541 <modify-function signature="operator*=(QTransform)" access="private"/>
541 <modify-function signature="operator*=(QTransform)" access="private"/>
542
542
543 <modify-function signature="inverted(bool*)const">
543 <modify-function signature="inverted(bool*)const">
544 <modify-argument index="1">
544 <modify-argument index="1">
545 <remove-argument/>
545 <remove-argument/>
546 </modify-argument>
546 </modify-argument>
547 </modify-function>
547 </modify-function>
548 </value-type>
548 </value-type>
549
549
550 <value-type name="QStyleOption" delete-in-main-thread="yes" polymorphic-base="yes" polymorphic-id-expression="%1-&gt;type == QStyleOption::SO_Default">
550 <value-type name="QStyleOption" delete-in-main-thread="yes" polymorphic-base="yes" polymorphic-id-expression="%1-&gt;type == QStyleOption::SO_Default">
551 <modify-function signature="operator=(QStyleOption)" remove="all"/>
551 <modify-function signature="operator=(QStyleOption)" remove="all"/>
552 <modify-function signature="init(const QWidget*)" remove="all"/> <!--### Obsolete in 4.3-->
552 <modify-function signature="init(const QWidget*)" remove="all"/> <!--### Obsolete in 4.3-->
553 </value-type>
553 </value-type>
554 <value-type name="QStyleOptionGraphicsItem" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionGraphicsItem::Type &amp;&amp; %1-&gt;version == QStyleOptionGraphicsItem::Version"/>
554 <value-type name="QStyleOptionGraphicsItem" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionGraphicsItem::Type &amp;&amp; %1-&gt;version == QStyleOptionGraphicsItem::Version"/>
555 <value-type name="QStyleOptionSizeGrip" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionSizeGrip::Type &amp;&amp; %1-&gt;version == QStyleOptionSizeGrip::Version"/>
555 <value-type name="QStyleOptionSizeGrip" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionSizeGrip::Type &amp;&amp; %1-&gt;version == QStyleOptionSizeGrip::Version"/>
556 <value-type name="QStyleOptionButton" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionButton::Type &amp;&amp; %1-&gt;version == QStyleOptionButton::Version"/>
556 <value-type name="QStyleOptionButton" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionButton::Type &amp;&amp; %1-&gt;version == QStyleOptionButton::Version"/>
557 <value-type name="QStyleOptionComboBox" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionComboBox::Type &amp;&amp; %1-&gt;version == QStyleOptionComboBox::Version"/>
557 <value-type name="QStyleOptionComboBox" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionComboBox::Type &amp;&amp; %1-&gt;version == QStyleOptionComboBox::Version"/>
558 <value-type name="QStyleOptionComplex" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionComplex::Type &amp;&amp; %1-&gt;version == QStyleOptionComplex::Version"/>
558 <value-type name="QStyleOptionComplex" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionComplex::Type &amp;&amp; %1-&gt;version == QStyleOptionComplex::Version"/>
559 <value-type name="QStyleOptionDockWidget" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionDockWidget::Type &amp;&amp; %1-&gt;version == QStyleOptionDockWidget::Version"/>
559 <value-type name="QStyleOptionDockWidget" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionDockWidget::Type &amp;&amp; %1-&gt;version == QStyleOptionDockWidget::Version"/>
560 <value-type name="QStyleOptionFocusRect" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionFocusRect::Type &amp;&amp; %1-&gt;version == QStyleOptionFocusRect::Version"/>
560 <value-type name="QStyleOptionFocusRect" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionFocusRect::Type &amp;&amp; %1-&gt;version == QStyleOptionFocusRect::Version"/>
561 <value-type name="QStyleOptionFrame" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionFrame::Type &amp;&amp; %1-&gt;version == QStyleOptionFrame::Version"/>
561 <value-type name="QStyleOptionFrame" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionFrame::Type &amp;&amp; %1-&gt;version == QStyleOptionFrame::Version"/>
562
562
563 <value-type name="QStyleOptionGroupBox" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionGroupBox::Type &amp;&amp; %1-&gt;version == QStyleOptionGroupBox::Version"/>
563 <value-type name="QStyleOptionGroupBox" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionGroupBox::Type &amp;&amp; %1-&gt;version == QStyleOptionGroupBox::Version"/>
564 <value-type name="QStyleOptionHeader" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionHeader::Type &amp;&amp; %1-&gt;version == QStyleOptionHeader::Version"/>
564 <value-type name="QStyleOptionHeader" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionHeader::Type &amp;&amp; %1-&gt;version == QStyleOptionHeader::Version"/>
565 <value-type name="QStyleOptionMenuItem" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionMenuItem::Type &amp;&amp; %1-&gt;version == QStyleOptionMenuItem::Version"/>
565 <value-type name="QStyleOptionMenuItem" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionMenuItem::Type &amp;&amp; %1-&gt;version == QStyleOptionMenuItem::Version"/>
566 <value-type name="QStyleOptionProgressBar" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionProgressBar::Type &amp;&amp; %1-&gt;version == QStyleOptionProgressBar::Version"/>
566 <value-type name="QStyleOptionProgressBar" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionProgressBar::Type &amp;&amp; %1-&gt;version == QStyleOptionProgressBar::Version"/>
567
567
568 <value-type name="QStyleOptionRubberBand" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionRubberBand::Type &amp;&amp; %1-&gt;version == QStyleOptionRubberBand::Version"/>
568 <value-type name="QStyleOptionRubberBand" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionRubberBand::Type &amp;&amp; %1-&gt;version == QStyleOptionRubberBand::Version"/>
569 <value-type name="QStyleOptionSlider" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionSlider::Type &amp;&amp; %1-&gt;version == QStyleOptionSlider::Version"/>
569 <value-type name="QStyleOptionSlider" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionSlider::Type &amp;&amp; %1-&gt;version == QStyleOptionSlider::Version"/>
570 <value-type name="QStyleOptionSpinBox" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionSpinBox::Type &amp;&amp; %1-&gt;version == QStyleOptionSpinBox::Version"/>
570 <value-type name="QStyleOptionSpinBox" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionSpinBox::Type &amp;&amp; %1-&gt;version == QStyleOptionSpinBox::Version"/>
571 <value-type name="QStyleOptionTab" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionTab::Type &amp;&amp; %1-&gt;version == QStyleOptionTab::Version"/>
571 <value-type name="QStyleOptionTab" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionTab::Type &amp;&amp; %1-&gt;version == QStyleOptionTab::Version"/>
572 <value-type name="QStyleOptionTabBarBase" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionTabBarBase::Type &amp;&amp; %1-&gt;version == QStyleOptionTabBarBase::Version"/>
572 <value-type name="QStyleOptionTabBarBase" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionTabBarBase::Type &amp;&amp; %1-&gt;version == QStyleOptionTabBarBase::Version"/>
573 <value-type name="QStyleOptionTabWidgetFrame" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionTabWidgetFrame::Type &amp;&amp; %1-&gt;version == QStyleOptionTabWidgetFrame::Version"/>
573 <value-type name="QStyleOptionTabWidgetFrame" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionTabWidgetFrame::Type &amp;&amp; %1-&gt;version == QStyleOptionTabWidgetFrame::Version"/>
574 <value-type name="QStyleOptionTitleBar" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionTitleBar::Type &amp;&amp; %1-&gt;version == QStyleOptionTitleBar::Version"/>
574 <value-type name="QStyleOptionTitleBar" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionTitleBar::Type &amp;&amp; %1-&gt;version == QStyleOptionTitleBar::Version"/>
575 <value-type name="QStyleOptionToolBar" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionToolBar::Type &amp;&amp; %1-&gt;version == QStyleOptionToolBar::Version"/>
575 <value-type name="QStyleOptionToolBar" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionToolBar::Type &amp;&amp; %1-&gt;version == QStyleOptionToolBar::Version"/>
576 <value-type name="QStyleOptionToolBox" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionToolBox::Type &amp;&amp; %1-&gt;version == QStyleOptionToolBox::Version"/>
576 <value-type name="QStyleOptionToolBox" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionToolBox::Type &amp;&amp; %1-&gt;version == QStyleOptionToolBox::Version"/>
577 <value-type name="QStyleOptionToolButton" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionToolButton::Type &amp;&amp; %1-&gt;version == QStyleOptionToolButton::Version"/>
577 <value-type name="QStyleOptionToolButton" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionToolButton::Type &amp;&amp; %1-&gt;version == QStyleOptionToolButton::Version"/>
578 <value-type name="QStyleOptionViewItem" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionViewItem::Type &amp;&amp; %1-&gt;version == QStyleOptionViewItem::Version"/>
578 <value-type name="QStyleOptionViewItem" delete-in-main-thread="yes" polymorphic-id-expression="%1-&gt;type == QStyleOptionViewItem::Type &amp;&amp; %1-&gt;version == QStyleOptionViewItem::Version"/>
579 <value-type name="QTextFragment" delete-in-main-thread="yes">
579 <value-type name="QTextFragment" delete-in-main-thread="yes">
580 <modify-function signature="operator=(QTextFragment)" remove="all"/>
580 <modify-function signature="operator=(QTextFragment)" remove="all"/>
581 </value-type>
581 </value-type>
582 <value-type name="QBitmap" delete-in-main-thread="yes">
582 <value-type name="QBitmap" delete-in-main-thread="yes">
583 <modify-function signature="operator=(const QPixmap &amp;)" remove="all"/>
583 <modify-function signature="operator=(const QPixmap &amp;)" remove="all"/>
584 <modify-function signature="QBitmap(QString,const char*)" access="private">
584 <modify-function signature="QBitmap(QString,const char*)" access="private">
585 <modify-argument index="2"> <remove-default-expression/> </modify-argument>
585 <modify-argument index="2"> <remove-default-expression/> </modify-argument>
586 </modify-function>
586 </modify-function>
587
587
588 <modify-function signature="fromData(QSize,const uchar*,QImage::Format)">
588 <modify-function signature="fromData(QSize,const uchar*,QImage::Format)">
589 <access modifier="private"/>
589 <access modifier="private"/>
590 <modify-argument index="3">
590 <modify-argument index="3">
591 <remove-default-expression/>
591 <remove-default-expression/>
592 </modify-argument>
592 </modify-argument>
593 </modify-function>
593 </modify-function>
594
594
595 <modify-function signature="fromData(QSize,const uchar*,QImage::Format)" remove="all"/>
595 <modify-function signature="fromData(QSize,const uchar*,QImage::Format)" remove="all"/>
596
596
597 <modify-function signature="QBitmap(QString,const char*)">
597 <modify-function signature="QBitmap(QString,const char*)">
598 <modify-argument index="2">
598 <modify-argument index="2">
599 <replace-type modified-type="QString"/>
599 <replace-type modified-type="QString"/>
600 <conversion-rule class="native">
600 <conversion-rule class="native">
601 <insert-template name="core.convert_string_arg_to_char*"/>
601 <insert-template name="core.convert_string_arg_to_char*"/>
602 </conversion-rule>
602 </conversion-rule>
603 </modify-argument>
603 </modify-argument>
604 </modify-function>
604 </modify-function>
605 </value-type>
605 </value-type>
606 <value-type name="QTextInlineObject" delete-in-main-thread="yes"/>
606 <value-type name="QTextInlineObject" delete-in-main-thread="yes"/>
607 <value-type name="QSizePolicy"/>
607 <value-type name="QSizePolicy"/>
608 <value-type name="QTableWidgetSelectionRange"/>
608 <value-type name="QTableWidgetSelectionRange"/>
609 <value-type name="QTextDocumentFragment" delete-in-main-thread="yes">
609 <value-type name="QTextDocumentFragment" delete-in-main-thread="yes">
610 <modify-function signature="operator=(QTextDocumentFragment)" remove="all"/>
610 <modify-function signature="operator=(QTextDocumentFragment)" remove="all"/>
611 </value-type>
611 </value-type>
612 <value-type name="QTextOption" delete-in-main-thread="yes">
612 <value-type name="QTextOption" delete-in-main-thread="yes">
613 <modify-function signature="operator=(const QTextOption &amp;)" remove="all"/>
613 <modify-function signature="operator=(const QTextOption &amp;)" remove="all"/>
614 </value-type>
614 </value-type>
615 <value-type name="QTextLine" delete-in-main-thread="yes">
615 <value-type name="QTextLine" delete-in-main-thread="yes">
616 <modify-function signature="cursorToX(int*,QTextLine::Edge)const">
616 <modify-function signature="cursorToX(int*,QTextLine::Edge)const">
617 <remove/>
617 <remove/>
618 </modify-function>
618 </modify-function>
619 </value-type>
619 </value-type>
620 <value-type name="QTextTableFormat" delete-in-main-thread="yes"/>
620 <value-type name="QTextTableFormat" delete-in-main-thread="yes"/>
621 <value-type name="QTextImageFormat" delete-in-main-thread="yes"/>
621 <value-type name="QTextImageFormat" delete-in-main-thread="yes"/>
622 <value-type name="QTextFrameFormat" delete-in-main-thread="yes">
622 <value-type name="QTextFrameFormat" delete-in-main-thread="yes">
623 <modify-function signature="isValid()const" access="non-final"/>
623 <modify-function signature="isValid()const" access="non-final"/>
624 </value-type>
624 </value-type>
625 <value-type name="QTextLength" delete-in-main-thread="yes"/>
625 <value-type name="QTextLength" delete-in-main-thread="yes"/>
626 <value-type name="QItemSelectionRange">
626 <value-type name="QItemSelectionRange">
627 <modify-function signature="intersect(QItemSelectionRange)const" remove="all"/> <!--### Obsolete in 4.3-->
627 <modify-function signature="intersect(QItemSelectionRange)const" remove="all"/> <!--### Obsolete in 4.3-->
628 </value-type>
628 </value-type>
629 <value-type name="QLine"/>
629 <value-type name="QLine"/>
630 <value-type name="QLineF"/>
630 <value-type name="QLineF"/>
631
631
632 <value-type name="QPainterPath">
632 <value-type name="QPainterPath">
633 <modify-function signature="operator=(QPainterPath)" remove="all"/>
633 <modify-function signature="operator=(QPainterPath)" remove="all"/>
634 </value-type>
634 </value-type>
635 <value-type name="QPalette">
635 <value-type name="QPalette">
636 <modify-function signature="operator=(const QPalette&amp;)" remove="all"/>
636 <modify-function signature="operator=(const QPalette&amp;)" remove="all"/>
637
637
638 <modify-function signature="QPalette(QColor, QColor, QColor, QColor, QColor, QColor, QColor)" remove="all"/> <!--### Obsolete in 4.3-->
638 <modify-function signature="QPalette(QColor, QColor, QColor, QColor, QColor, QColor, QColor)" remove="all"/> <!--### Obsolete in 4.3-->
639 <modify-function signature="background()const" remove="all"/> <!--### Obsolete in 4.3-->
639 <modify-function signature="background()const" remove="all"/> <!--### Obsolete in 4.3-->
640 <modify-function signature="foreground()const" remove="all"/> <!--### Obsolete in 4.3-->
640 <modify-function signature="foreground()const" remove="all"/> <!--### Obsolete in 4.3-->
641 <modify-function signature="serialNumber()const" remove="all"/> <!--### Obsolete in 4.3-->
641 <modify-function signature="serialNumber()const" remove="all"/> <!--### Obsolete in 4.3-->
642 </value-type>
642 </value-type>
643 <value-type name="QKeySequence">
643 <value-type name="QKeySequence">
644 <modify-function signature="operator=(QKeySequence)" remove="all"/>
644 <modify-function signature="operator=(QKeySequence)" remove="all"/>
645 <modify-function signature="operator int()const" access="private"/>
645 <modify-function signature="operator int()const" access="private"/>
646 <modify-function signature="operator[](uint)const" access="private"/>
646 <modify-function signature="operator[](uint)const" access="private"/>
647 </value-type>
647 </value-type>
648
648
649 <value-type name="QPicture" delete-in-main-thread="yes">
649 <value-type name="QPicture" delete-in-main-thread="yes">
650 <modify-function signature="operator=(QPicture)" remove="all"/>
650 <modify-function signature="operator=(QPicture)" remove="all"/>
651 <modify-function signature="pictureFormat(QString)">
651 <modify-function signature="pictureFormat(QString)">
652 <remove/>
652 <remove/>
653 </modify-function>
653 </modify-function>
654
654
655 <modify-function signature="inputFormatList()" remove="all"/> <!--### Obsolete in 4.3-->
655 <modify-function signature="inputFormatList()" remove="all"/> <!--### Obsolete in 4.3-->
656 <modify-function signature="inputFormats()" remove="all"/> <!--### Obsolete in 4.3-->
656 <modify-function signature="inputFormats()" remove="all"/> <!--### Obsolete in 4.3-->
657 <modify-function signature="outputFormatList()" remove="all"/> <!--### Obsolete in 4.3-->
657 <modify-function signature="outputFormatList()" remove="all"/> <!--### Obsolete in 4.3-->
658 <modify-function signature="outputFormats()" remove="all"/> <!--### Obsolete in 4.3-->
658 <modify-function signature="outputFormats()" remove="all"/> <!--### Obsolete in 4.3-->
659
659
660 <modify-function signature="setData(const char*,uint)" remove="all"/>
660 <modify-function signature="setData(const char*,uint)" remove="all"/>
661
661
662 <modify-function signature="load(QIODevice*,const char*)">
662 <modify-function signature="load(QIODevice*,const char*)">
663 <modify-argument index="2">
663 <modify-argument index="2">
664 <replace-type modified-type="QString"/>
664 <replace-type modified-type="QString"/>
665 <conversion-rule class="native">
665 <conversion-rule class="native">
666 <insert-template name="core.convert_string_arg_to_char*"/>
666 <insert-template name="core.convert_string_arg_to_char*"/>
667 </conversion-rule>
667 </conversion-rule>
668 </modify-argument>
668 </modify-argument>
669 </modify-function>
669 </modify-function>
670
670
671 <modify-function signature="load(QString,const char*)">
671 <modify-function signature="load(QString,const char*)">
672 <modify-argument index="2">
672 <modify-argument index="2">
673 <replace-type modified-type="QString"/>
673 <replace-type modified-type="QString"/>
674 <conversion-rule class="native">
674 <conversion-rule class="native">
675 <insert-template name="core.convert_string_arg_to_char*"/>
675 <insert-template name="core.convert_string_arg_to_char*"/>
676 </conversion-rule>
676 </conversion-rule>
677 </modify-argument>
677 </modify-argument>
678 </modify-function>
678 </modify-function>
679
679
680 <modify-function signature="save(QIODevice*,const char*)">
680 <modify-function signature="save(QIODevice*,const char*)">
681 <modify-argument index="2">
681 <modify-argument index="2">
682 <replace-type modified-type="QString"/>
682 <replace-type modified-type="QString"/>
683 <conversion-rule class="native">
683 <conversion-rule class="native">
684 <insert-template name="core.convert_string_arg_to_char*"/>
684 <insert-template name="core.convert_string_arg_to_char*"/>
685 </conversion-rule>
685 </conversion-rule>
686 </modify-argument>
686 </modify-argument>
687 </modify-function>
687 </modify-function>
688
688
689 <modify-function signature="save(QString,const char*)">
689 <modify-function signature="save(QString,const char*)">
690 <modify-argument index="2">
690 <modify-argument index="2">
691 <replace-type modified-type="QString"/>
691 <replace-type modified-type="QString"/>
692 <conversion-rule class="native">
692 <conversion-rule class="native">
693 <insert-template name="core.convert_string_arg_to_char*"/>
693 <insert-template name="core.convert_string_arg_to_char*"/>
694 </conversion-rule>
694 </conversion-rule>
695 </modify-argument>
695 </modify-argument>
696 </modify-function>
696 </modify-function>
697 </value-type>
697 </value-type>
698
698
699 <value-type name="QRegion" expense-limit="4096">
699 <value-type name="QRegion" expense-limit="4096">
700 <modify-function signature="operator=(QRegion)" remove="all"/>
700 <modify-function signature="operator=(QRegion)" remove="all"/>
701 <modify-function signature="operator&amp;=(QRegion)" remove="all"/>
701 <modify-function signature="operator&amp;=(QRegion)" remove="all"/>
702 <modify-function signature="operator+=(QRegion)" remove="all"/>
702 <modify-function signature="operator+=(QRegion)" remove="all"/>
703 <modify-function signature="operator-=(QRegion)" remove="all"/>
703 <modify-function signature="operator-=(QRegion)" remove="all"/>
704 <modify-function signature="operator^=(QRegion)" remove="all"/>
704 <modify-function signature="operator^=(QRegion)" remove="all"/>
705 <modify-function signature="operator|=(QRegion)" remove="all"/>
705 <modify-function signature="operator|=(QRegion)" remove="all"/>
706 <modify-function signature="operator&amp;(QRegion)const" remove="all"/>
706 <modify-function signature="operator&amp;(QRegion)const" remove="all"/>
707 <modify-function signature="operator+(QRegion)const" remove="all"/>
707 <modify-function signature="operator+(QRegion)const" remove="all"/>
708 <modify-function signature="operator-(QRegion)const" remove="all"/>
708 <modify-function signature="operator-(QRegion)const" remove="all"/>
709 <modify-function signature="operator^(QRegion)const" remove="all"/>
709 <modify-function signature="operator^(QRegion)const" remove="all"/>
710 <modify-function signature="operator|(QRegion)const" remove="all"/>
710 <modify-function signature="operator|(QRegion)const" remove="all"/>
711 <modify-function signature="eor(QRegion)const" remove="all"/> <!--### Obsolete in 4.3-->
711 <modify-function signature="eor(QRegion)const" remove="all"/> <!--### Obsolete in 4.3-->
712 <modify-function signature="intersect(QRegion)const" remove="all"/> <!--### Obsolete in 4.3-->
712 <modify-function signature="intersect(QRegion)const" remove="all"/> <!--### Obsolete in 4.3-->
713 <modify-function signature="subtract(QRegion)const" remove="all"/> <!--### Obsolete in 4.3-->
713 <modify-function signature="subtract(QRegion)const" remove="all"/> <!--### Obsolete in 4.3-->
714 <modify-function signature="unite(QRegion)const" remove="all"/> <!--### Obsolete in 4.3-->
714 <modify-function signature="unite(QRegion)const" remove="all"/> <!--### Obsolete in 4.3-->
715 <modify-function signature="operator&amp;=(QRect)" remove="all"/>
715 <modify-function signature="operator&amp;=(QRect)" remove="all"/>
716 <modify-function signature="operator+=(QRect)" remove="all"/>
716 <modify-function signature="operator+=(QRect)" remove="all"/>
717
717
718 </value-type>
718 </value-type>
719
719
720 <value-type name="QTextBlock" delete-in-main-thread="yes">
720 <value-type name="QTextBlock" delete-in-main-thread="yes">
721 <modify-function signature="operator=(QTextBlock)" remove="all"/>
721 <modify-function signature="operator=(QTextBlock)" remove="all"/>
722 <modify-function signature="setUserData(QTextBlockUserData *)">
722 <modify-function signature="setUserData(QTextBlockUserData *)">
723 <modify-argument index="1">
723 <modify-argument index="1">
724 <define-ownership class="java" owner="c++"/>
724 <define-ownership class="java" owner="c++"/>
725 </modify-argument>
725 </modify-argument>
726 </modify-function>
726 </modify-function>
727 </value-type>
727 </value-type>
728 <value-type name="QTextBlockFormat" delete-in-main-thread="yes"/>
728 <value-type name="QTextBlockFormat" delete-in-main-thread="yes"/>
729 <value-type name="QTextTableCellFormat" delete-in-main-thread="yes"/>
729 <value-type name="QTextTableCellFormat" delete-in-main-thread="yes"/>
730 <value-type name="QTextCharFormat" delete-in-main-thread="yes">
730 <value-type name="QTextCharFormat" delete-in-main-thread="yes">
731 <modify-function signature="isValid()const" access="non-final"/>
731 <modify-function signature="isValid()const" access="non-final"/>
732
732
733 <modify-function signature="anchorName()const" remove="all"/> <!--### Obsolete in 4.3-->
733 <modify-function signature="anchorName()const" remove="all"/> <!--### Obsolete in 4.3-->
734 <modify-function signature="setAnchorName(QString)" remove="all"/> <!--### Obsolete in 4.3-->
734 <modify-function signature="setAnchorName(QString)" remove="all"/> <!--### Obsolete in 4.3-->
735 </value-type>
735 </value-type>
736 <value-type name="QTextFormat" delete-in-main-thread="yes">
736 <value-type name="QTextFormat" delete-in-main-thread="yes">
737 <modify-function signature="operator=(QTextFormat)" remove="all"/>
737 <modify-function signature="operator=(QTextFormat)" remove="all"/>
738 <modify-function signature="isValid()const" access="non-final"/>
738 <modify-function signature="isValid()const" access="non-final"/>
739
739
740
740
741 <modify-function signature="setProperty(int,QVector&lt;QTextLength&gt;)" rename="setLengthVectorProperty"/>
741 <modify-function signature="setProperty(int,QVector&lt;QTextLength&gt;)" rename="setLengthVectorProperty"/>
742 <inject-code class="native" position="constructor">
742 <inject-code class="native" position="constructor">
743 if ((context-&gt;argumentCount() == 1) &amp;&amp; (qMetaTypeId&lt;QTextFormat&gt;() == context-&gt;argument(0).toVariant().userType())) {
743 if ((context-&gt;argumentCount() == 1) &amp;&amp; (qMetaTypeId&lt;QTextFormat&gt;() == context-&gt;argument(0).toVariant().userType())) {
744 QTextFormat _q_arg0 = qscriptvalue_cast&lt;QTextFormat&gt;(context-&gt;argument(0));
744 QTextFormat _q_arg0 = qscriptvalue_cast&lt;QTextFormat&gt;(context-&gt;argument(0));
745 QTextFormat _q_cpp_result(_q_arg0);
745 QTextFormat _q_cpp_result(_q_arg0);
746 QScriptValue _q_result = context-&gt;engine()-&gt;newVariant(context-&gt;thisObject(), qVariantFromValue(_q_cpp_result));
746 QScriptValue _q_result = context-&gt;engine()-&gt;newVariant(context-&gt;thisObject(), qVariantFromValue(_q_cpp_result));
747 return _q_result;
747 return _q_result;
748 }
748 }
749 </inject-code>
749 </inject-code>
750 </value-type>
750 </value-type>
751
751
752 <value-type name="QTextListFormat" delete-in-main-thread="yes"/>
752 <value-type name="QTextListFormat" delete-in-main-thread="yes"/>
753 <value-type name="QPolygon">
753 <value-type name="QPolygon">
754 <modify-function signature="QPolygon(int, const int *)" remove="all"/>
754 <modify-function signature="QPolygon(int, const int *)" remove="all"/>
755 <modify-function signature="operator+(QVector&lt;QPoint&gt;)const" remove="all"/>
755 <modify-function signature="operator+(QVector&lt;QPoint&gt;)const" remove="all"/>
756 <modify-function signature="operator&lt;&lt;(QPoint)" remove="all"/>
756 <modify-function signature="operator&lt;&lt;(QPoint)" remove="all"/>
757 <modify-function signature="operator&lt;&lt;(QVector&lt;QPoint&gt;)" remove="all"/>
757 <modify-function signature="operator&lt;&lt;(QVector&lt;QPoint&gt;)" remove="all"/>
758
758
759
759
760 </value-type>
760 </value-type>
761
761
762 <value-type name="QPolygonF">
762 <value-type name="QPolygonF">
763 <modify-function signature="operator+(QVector&lt;QPointF&gt;)const" remove="all"/>
763 <modify-function signature="operator+(QVector&lt;QPointF&gt;)const" remove="all"/>
764 <modify-function signature="operator&lt;&lt;(QPointF)" remove="all"/>
764 <modify-function signature="operator&lt;&lt;(QPointF)" remove="all"/>
765 <modify-function signature="operator&lt;&lt;(QVector&lt;QPointF&gt;)" remove="all"/>
765 <modify-function signature="operator&lt;&lt;(QVector&lt;QPointF&gt;)" remove="all"/>
766 </value-type>
766 </value-type>
767
767
768 <value-type name="QIcon" delete-in-main-thread="yes">
768 <value-type name="QIcon" delete-in-main-thread="yes">
769 <include file-name="QIconEngine" location="global"/>
769 <include file-name="QIconEngine" location="global"/>
770 <modify-function signature="operator=(QIcon)" remove="all"/>
770 <modify-function signature="operator=(QIcon)" remove="all"/>
771 <modify-function signature="serialNumber()const" remove="all"/> <!--### Obsolete in 4.3-->
771 <modify-function signature="serialNumber()const" remove="all"/> <!--### Obsolete in 4.3-->
772 <!--modify-function signature="QIcon(QIconEngineV2 *)">
772 <!--modify-function signature="QIcon(QIconEngineV2 *)">
773 <modify-argument index="1">
773 <modify-argument index="1">
774 <define-ownership class="java" owner="c++" />
774 <define-ownership class="java" owner="c++" />
775 </modify-argument>
775 </modify-argument>
776 </modify-function-->
776 </modify-function-->
777 <modify-function signature="QIcon(QIconEngine *)">
777 <modify-function signature="QIcon(QIconEngine *)">
778 <modify-argument index="1">
778 <modify-argument index="1">
779 <define-ownership class="java" owner="c++"/>
779 <define-ownership class="java" owner="c++"/>
780 </modify-argument>
780 </modify-argument>
781 </modify-function>
781 </modify-function>
782 </value-type>
782 </value-type>
783
783
784 <value-type name="QTextFrame::iterator" delete-in-main-thread="yes">
784 <value-type name="QTextFrame::iterator" delete-in-main-thread="yes">
785 <include file-name="QTextFrame" location="global"/>
785 <include file-name="QTextFrame" location="global"/>
786 <modify-function signature="operator++(int)" remove="all"/>
786 <modify-function signature="operator++(int)" remove="all"/>
787 <modify-function signature="operator--(int)" remove="all"/>
787 <modify-function signature="operator--(int)" remove="all"/>
788 <modify-function signature="operator=(QTextFrame::iterator)" remove="all"/>
788 <modify-function signature="operator=(QTextFrame::iterator)" remove="all"/>
789 <modify-function signature="operator++()" access="private"/>
789 <modify-function signature="operator++()" access="private"/>
790 <modify-function signature="operator--()" access="private"/>
790 <modify-function signature="operator--()" access="private"/>
791 </value-type>
791 </value-type>
792
792
793 <value-type name="QTreeWidgetItemIterator" delete-in-main-thread="yes">
793 <value-type name="QTreeWidgetItemIterator" delete-in-main-thread="yes">
794 <custom-constructor>
794 <custom-constructor>
795 return new QTreeWidgetItemIterator(*copy);
795 return new QTreeWidgetItemIterator(*copy);
796 </custom-constructor>
796 </custom-constructor>
797 <custom-destructor>
797 <custom-destructor>
798 delete copy;
798 delete copy;
799 </custom-destructor>
799 </custom-destructor>
800 <modify-function signature="operator=(QTreeWidgetItemIterator)" remove="all"/>
800 <modify-function signature="operator=(QTreeWidgetItemIterator)" remove="all"/>
801 <modify-function signature="operator++(int)" remove="all"/>
801 <modify-function signature="operator++(int)" remove="all"/>
802 <modify-function signature="operator--(int)" remove="all"/>
802 <modify-function signature="operator--(int)" remove="all"/>
803 <modify-function signature="operator+=(int)" access="private"/>
803 <modify-function signature="operator+=(int)" access="private"/>
804 <modify-function signature="operator-=(int)" access="private"/>
804 <modify-function signature="operator-=(int)" access="private"/>
805 <modify-function signature="operator++()" access="private"/>
805 <modify-function signature="operator++()" access="private"/>
806 <modify-function signature="operator--()" access="private"/>
806 <modify-function signature="operator--()" access="private"/>
807 <modify-function signature="operator*()const" access="private"/>
807 <modify-function signature="operator*()const" access="private"/>
808 </value-type>
808 </value-type>
809
809
810 <value-type name="QTextBlock::iterator" delete-in-main-thread="yes">
810 <value-type name="QTextBlock::iterator" delete-in-main-thread="yes">
811 <include file-name="QTextBlock" location="global"/>
811 <include file-name="QTextBlock" location="global"/>
812
812
813 <modify-function signature="operator++()" access="private"/>
813 <modify-function signature="operator++()" access="private"/>
814 <modify-function signature="operator--()" access="private"/>
814 <modify-function signature="operator--()" access="private"/>
815 <modify-function signature="operator++(int)" remove="all"/>
815 <modify-function signature="operator++(int)" remove="all"/>
816 <modify-function signature="operator--(int)" remove="all"/>
816 <modify-function signature="operator--(int)" remove="all"/>
817 </value-type>
817 </value-type>
818
818
819 <value-type name="QAbstractTextDocumentLayout::PaintContext" delete-in-main-thread="yes">
819 <value-type name="QAbstractTextDocumentLayout::PaintContext" delete-in-main-thread="yes">
820 <include file-name="QAbstractTextDocumentLayout" location="global"/>
820 <include file-name="QAbstractTextDocumentLayout" location="global"/>
821 </value-type>
821 </value-type>
822 <value-type name="QAbstractTextDocumentLayout::Selection" delete-in-main-thread="yes"/>
822 <value-type name="QAbstractTextDocumentLayout::Selection" delete-in-main-thread="yes"/>
823
823
824 <value-type name="QPixmap" delete-in-main-thread="yes">
824 <value-type name="QPixmap" delete-in-main-thread="yes">
825 <modify-function signature="operator=(QPixmap)" remove="all"/>
825 <modify-function signature="operator=(QPixmap)" remove="all"/>
826 <modify-function signature="operator!()const" remove="all"/>
826 <modify-function signature="operator!()const" remove="all"/>
827 <modify-function signature="QPixmap(const char **)" access="private"/>
827 <modify-function signature="QPixmap(const char **)" access="private"/>
828 <modify-function signature="serialNumber()const" remove="all"/> <!--### Obsolete in 4.3-->
828 <modify-function signature="serialNumber()const" remove="all"/> <!--### Obsolete in 4.3-->
829
829
830 <modify-function signature="loadFromData(const uchar *,uint,const char *,QFlags&lt;Qt::ImageConversionFlag&gt;)" remove="all"/>
830 <modify-function signature="loadFromData(const uchar *,uint,const char *,QFlags&lt;Qt::ImageConversionFlag&gt;)" remove="all"/>
831
831
832 <modify-function signature="QPixmap(QString,const char*,QFlags&lt;Qt::ImageConversionFlag&gt;)">
832 <modify-function signature="QPixmap(QString,const char*,QFlags&lt;Qt::ImageConversionFlag&gt;)">
833 <modify-argument index="2">
833 <modify-argument index="2">
834 <replace-type modified-type="QString"/>
834 <replace-type modified-type="QString"/>
835 <conversion-rule class="native">
835 <conversion-rule class="native">
836 <insert-template name="core.convert_string_arg_to_char*"/>
836 <insert-template name="core.convert_string_arg_to_char*"/>
837 </conversion-rule>
837 </conversion-rule>
838 </modify-argument>
838 </modify-argument>
839 </modify-function>
839 </modify-function>
840
840
841 <modify-function signature="load(QString,const char*,QFlags&lt;Qt::ImageConversionFlag&gt;)">
841 <modify-function signature="load(QString,const char*,QFlags&lt;Qt::ImageConversionFlag&gt;)">
842 <modify-argument index="2">
842 <modify-argument index="2">
843 <replace-type modified-type="QString"/>
843 <replace-type modified-type="QString"/>
844 <conversion-rule class="native">
844 <conversion-rule class="native">
845 <insert-template name="core.convert_string_arg_to_char*"/>
845 <insert-template name="core.convert_string_arg_to_char*"/>
846 </conversion-rule>
846 </conversion-rule>
847 </modify-argument>
847 </modify-argument>
848 </modify-function>
848 </modify-function>
849
849
850 <modify-function signature="loadFromData(QByteArray,const char*,QFlags&lt;Qt::ImageConversionFlag&gt;)">
850 <modify-function signature="loadFromData(QByteArray,const char*,QFlags&lt;Qt::ImageConversionFlag&gt;)">
851 <modify-argument index="2">
851 <modify-argument index="2">
852 <replace-type modified-type="QString"/>
852 <replace-type modified-type="QString"/>
853 <conversion-rule class="native">
853 <conversion-rule class="native">
854 <insert-template name="core.convert_string_arg_to_char*"/>
854 <insert-template name="core.convert_string_arg_to_char*"/>
855 </conversion-rule>
855 </conversion-rule>
856 </modify-argument>
856 </modify-argument>
857 </modify-function>
857 </modify-function>
858
858
859 <modify-function signature="save(QIODevice*,const char*,int)const">
859 <modify-function signature="save(QIODevice*,const char*,int)const">
860 <modify-argument index="2">
860 <modify-argument index="2">
861 <replace-type modified-type="QString"/>
861 <replace-type modified-type="QString"/>
862 <conversion-rule class="native">
862 <conversion-rule class="native">
863 <insert-template name="core.convert_string_arg_to_char*"/>
863 <insert-template name="core.convert_string_arg_to_char*"/>
864 </conversion-rule>
864 </conversion-rule>
865 </modify-argument>
865 </modify-argument>
866 </modify-function>
866 </modify-function>
867
867
868 <modify-function signature="save(QString,const char*,int)const">
868 <modify-function signature="save(QString,const char*,int)const">
869 <modify-argument index="2">
869 <modify-argument index="2">
870 <replace-type modified-type="QString"/>
870 <replace-type modified-type="QString"/>
871 <conversion-rule class="native">
871 <conversion-rule class="native">
872 <insert-template name="core.convert_string_arg_to_char*"/>
872 <insert-template name="core.convert_string_arg_to_char*"/>
873 </conversion-rule>
873 </conversion-rule>
874 </modify-argument>
874 </modify-argument>
875 </modify-function>
875 </modify-function>
876 </value-type>
876 </value-type>
877
877
878 <value-type name="QTextCursor" delete-in-main-thread="yes">
878 <value-type name="QTextCursor" delete-in-main-thread="yes">
879 <extra-includes>
879 <extra-includes>
880 <include file-name="QTextBlock" location="global"/>
880 <include file-name="QTextBlock" location="global"/>
881 <include file-name="QTextDocumentFragment" location="global"/>
881 <include file-name="QTextDocumentFragment" location="global"/>
882 </extra-includes>
882 </extra-includes>
883 <modify-function signature="operator=(QTextCursor)" remove="all"/>
883 <modify-function signature="operator=(QTextCursor)" remove="all"/>
884 <modify-function signature="selectedTableCells(int*,int*,int*,int*)const">
884 <modify-function signature="selectedTableCells(int*,int*,int*,int*)const">
885 <access modifier="private"/>
885 <access modifier="private"/>
886 </modify-function>
886 </modify-function>
887 </value-type>
887 </value-type>
888
888
889 <value-type name="QTextLayout::FormatRange">
889 <value-type name="QTextLayout::FormatRange">
890 <include file-name="QTextLayout" location="global"/>
890 <include file-name="QTextLayout" location="global"/>
891 </value-type>
891 </value-type>
892
892
893 <value-type name="QInputMethodEvent::Attribute">
893 <value-type name="QInputMethodEvent::Attribute">
894 <include file-name="QInputMethodEvent" location="global"/>
894 <include file-name="QInputMethodEvent" location="global"/>
895 <custom-constructor>
895 <custom-constructor>
896 return new QInputMethodEvent::Attribute(copy-&gt;type, copy-&gt;start, copy-&gt;length, copy-&gt;value);
896 return new QInputMethodEvent::Attribute(copy-&gt;type, copy-&gt;start, copy-&gt;length, copy-&gt;value);
897 </custom-constructor>
897 </custom-constructor>
898 <custom-destructor>
898 <custom-destructor>
899 delete copy;
899 delete copy;
900 </custom-destructor>
900 </custom-destructor>
901 </value-type>
901 </value-type>
902
902
903 <value-type name="QItemSelection" delete-in-main-thread="yes">
903 <value-type name="QItemSelection" delete-in-main-thread="yes">
904
904
905 <modify-function signature="operator+(const QList&lt;QItemSelectionRange&gt;&amp;)const" remove="all"/>
905 <modify-function signature="operator+(const QList&lt;QItemSelectionRange&gt;&amp;)const" remove="all"/>
906 <modify-function signature="operator+=(const QList&lt;QItemSelectionRange&gt;&amp;)" remove="all"/>
906 <modify-function signature="operator+=(const QList&lt;QItemSelectionRange&gt;&amp;)" remove="all"/>
907 <modify-function signature="operator+=(const QItemSelectionRange&amp;)" remove="all"/>
907 <modify-function signature="operator+=(const QItemSelectionRange&amp;)" remove="all"/>
908 <modify-function signature="operator&lt;&lt;(const QList&lt;QItemSelectionRange&gt;&amp;)" remove="all"/>
908 <modify-function signature="operator&lt;&lt;(const QList&lt;QItemSelectionRange&gt;&amp;)" remove="all"/>
909 <modify-function signature="operator&lt;&lt;(QItemSelectionRange)" remove="all"/>
909 <modify-function signature="operator&lt;&lt;(QItemSelectionRange)" remove="all"/>
910 </value-type>
910 </value-type>
911
911
912 <value-type name="QMatrix4x4">
912 <value-type name="QMatrix4x4">
913 <modify-function signature="data()const" remove="all"/>
913 <modify-function signature="data()const" remove="all"/>
914 <modify-function signature="operator()(int, int)const" remove="all"/>
914 <modify-function signature="operator()(int, int)const" remove="all"/>
915 </value-type>
915 </value-type>
916 <value-type name="QMatrix">
916 <value-type name="QMatrix">
917 <extra-includes>
917 <extra-includes>
918 <include file-name="QPainterPath" location="global"/>
918 <include file-name="QPainterPath" location="global"/>
919 </extra-includes>
919 </extra-includes>
920
920
921 <modify-function signature="map(int,int,int*,int*)const" remove="all"/>
921 <modify-function signature="map(int,int,int*,int*)const" remove="all"/>
922 <modify-function signature="map(qreal,qreal,qreal*,qreal*)const" remove="all"/>
922 <modify-function signature="map(qreal,qreal,qreal*,qreal*)const" remove="all"/>
923 <modify-function signature="operator=(QMatrix)" remove="all"/>
923 <modify-function signature="operator=(QMatrix)" remove="all"/>
924
924
925 <modify-function signature="operator*(QMatrix)const" access="private"/>
925 <modify-function signature="operator*(QMatrix)const" access="private"/>
926 <modify-function signature="operator*=(QMatrix)" access="private"/>
926 <modify-function signature="operator*=(QMatrix)" access="private"/>
927 <modify-function signature="rotate(qreal)" access="private" rename="rotate_private"/>
927 <modify-function signature="rotate(qreal)" access="private" rename="rotate_private"/>
928 <modify-function signature="scale(qreal,qreal)" access="private" rename="scale_private"/>
928 <modify-function signature="scale(qreal,qreal)" access="private" rename="scale_private"/>
929 <modify-function signature="shear(qreal,qreal)" access="private" rename="shear_private"/>
929 <modify-function signature="shear(qreal,qreal)" access="private" rename="shear_private"/>
930 <modify-function signature="translate(qreal,qreal)" access="private" rename="translate_private"/>
930 <modify-function signature="translate(qreal,qreal)" access="private" rename="translate_private"/>
931
931
932 <modify-function signature="inverted(bool*)const">
932 <modify-function signature="inverted(bool*)const">
933 <access modifier="private"/>
933 <access modifier="private"/>
934 <modify-argument index="1">
934 <modify-argument index="1">
935 <!-- <remove-default-expression/> -->
935 <!-- <remove-default-expression/> -->
936 </modify-argument>
936 </modify-argument>
937 </modify-function>
937 </modify-function>
938
938
939 <inject-code>
939 <inject-code>
940 <insert-template name="core.unary_other_type">
940 <insert-template name="core.unary_other_type">
941 <replace from="%FUNCTION_NAME" to="rotate"/>
941 <replace from="%FUNCTION_NAME" to="rotate"/>
942 <replace from="%OUT_TYPE" to="QMatrix"/>
942 <replace from="%OUT_TYPE" to="QMatrix"/>
943 <replace from="%IN_TYPE" to="double"/>
943 <replace from="%IN_TYPE" to="double"/>
944 </insert-template>
944 </insert-template>
945
945
946 <insert-template name="core.private_function_return_self">
946 <insert-template name="core.private_function_return_self">
947 <replace from="%RETURN_TYPE" to="QMatrix"/>
947 <replace from="%RETURN_TYPE" to="QMatrix"/>
948 <replace from="%FUNCTION_NAME" to="scale"/>
948 <replace from="%FUNCTION_NAME" to="scale"/>
949 <replace from="%ARGUMENTS" to="double sx, double sy"/>
949 <replace from="%ARGUMENTS" to="double sx, double sy"/>
950 <replace from="%ARGUMENT_NAMES" to="sx, sy"/>
950 <replace from="%ARGUMENT_NAMES" to="sx, sy"/>
951 </insert-template>
951 </insert-template>
952
952
953 <insert-template name="core.private_function_return_self">
953 <insert-template name="core.private_function_return_self">
954 <replace from="%RETURN_TYPE" to="QMatrix"/>
954 <replace from="%RETURN_TYPE" to="QMatrix"/>
955 <replace from="%FUNCTION_NAME" to="shear"/>
955 <replace from="%FUNCTION_NAME" to="shear"/>
956 <replace from="%ARGUMENTS" to="double sh, double sv"/>
956 <replace from="%ARGUMENTS" to="double sh, double sv"/>
957 <replace from="%ARGUMENT_NAMES" to="sh, sv"/>
957 <replace from="%ARGUMENT_NAMES" to="sh, sv"/>
958 </insert-template>
958 </insert-template>
959
959
960 <insert-template name="core.private_function_return_self">
960 <insert-template name="core.private_function_return_self">
961 <replace from="%RETURN_TYPE" to="QMatrix"/>
961 <replace from="%RETURN_TYPE" to="QMatrix"/>
962 <replace from="%FUNCTION_NAME" to="translate"/>
962 <replace from="%FUNCTION_NAME" to="translate"/>
963 <replace from="%ARGUMENTS" to="double dx, double dy"/>
963 <replace from="%ARGUMENTS" to="double dx, double dy"/>
964 <replace from="%ARGUMENT_NAMES" to="dx, dy"/>
964 <replace from="%ARGUMENT_NAMES" to="dx, dy"/>
965 </insert-template>
965 </insert-template>
966 </inject-code>
966 </inject-code>
967
967
968 <modify-function signature="inverted(bool*)const">
968 <modify-function signature="inverted(bool*)const">
969 <modify-argument index="1">
969 <modify-argument index="1">
970 <remove-argument/>
970 <remove-argument/>
971 </modify-argument>
971 </modify-argument>
972 </modify-function>
972 </modify-function>
973 </value-type>
973 </value-type>
974
974
975 <value-type name="QConicalGradient" polymorphic-id-expression="%1-&gt;type() == QGradient::ConicalGradient">
975 <value-type name="QConicalGradient" polymorphic-id-expression="%1-&gt;type() == QGradient::ConicalGradient">
976 <custom-constructor>
976 <custom-constructor>
977 return new QConicalGradient(copy-&gt;center(), copy-&gt;angle());
977 return new QConicalGradient(copy-&gt;center(), copy-&gt;angle());
978 </custom-constructor>
978 </custom-constructor>
979 <custom-destructor>
979 <custom-destructor>
980 delete copy;
980 delete copy;
981 </custom-destructor>
981 </custom-destructor>
982 </value-type>
982 </value-type>
983
983
984 <value-type name="QFontInfo" delete-in-main-thread="yes" expense-cost="1" expense-limit="1000">
984 <value-type name="QFontInfo" delete-in-main-thread="yes" expense-cost="1" expense-limit="1000">
985 <custom-constructor>
985 <custom-constructor>
986 return new QFontInfo(*copy);
986 return new QFontInfo(*copy);
987 </custom-constructor>
987 </custom-constructor>
988 <custom-destructor>
988 <custom-destructor>
989 delete copy;
989 delete copy;
990 </custom-destructor>
990 </custom-destructor>
991 <modify-function signature="operator=(QFontInfo)" remove="all"/>
991 <modify-function signature="operator=(QFontInfo)" remove="all"/>
992
992
993
993
994 <modify-function signature="QFontInfo(QFontInfo)">
994 <modify-function signature="QFontInfo(QFontInfo)">
995 <modify-argument index="1">
995 <modify-argument index="1">
996 <replace-type modified-type="QFontInfo*"/>
996 <replace-type modified-type="QFontInfo*"/>
997 <conversion-rule class="native">
997 <conversion-rule class="native">
998 QFontInfo &amp; %out% = *qscriptvalue_cast&lt;QFontInfo*&gt;(%in%);
998 QFontInfo &amp; %out% = *qscriptvalue_cast&lt;QFontInfo*&gt;(%in%);
999 </conversion-rule>
999 </conversion-rule>
1000 </modify-argument>
1000 </modify-argument>
1001 </modify-function>
1001 </modify-function>
1002 </value-type>
1002 </value-type>
1003
1003
1004 <value-type name="QRadialGradient" polymorphic-id-expression="%1-&gt;type() == QGradient::RadialGradient">
1004 <value-type name="QRadialGradient" polymorphic-id-expression="%1-&gt;type() == QGradient::RadialGradient">
1005 <custom-constructor>
1005 <custom-constructor>
1006 return new QRadialGradient(copy-&gt;center(), copy-&gt;radius(), copy-&gt;focalPoint());
1006 return new QRadialGradient(copy-&gt;center(), copy-&gt;radius(), copy-&gt;focalPoint());
1007 </custom-constructor>
1007 </custom-constructor>
1008 <custom-destructor>
1008 <custom-destructor>
1009 delete copy;
1009 delete copy;
1010 </custom-destructor>
1010 </custom-destructor>
1011 </value-type>
1011 </value-type>
1012
1012
1013 <value-type name="QPainterPath::Element">
1013 <value-type name="QPainterPath::Element">
1014 <modify-field name="x" write="false"/>
1014 <modify-field name="x" write="false"/>
1015 <modify-field name="y" write="false"/>
1015 <modify-field name="y" write="false"/>
1016 <modify-field name="type" write="false"/>
1016 <modify-field name="type" write="false"/>
1017 <include file-name="QPainterPath" location="global"/>
1017 <include file-name="QPainterPath" location="global"/>
1018 <modify-function signature="operator QPointF()const" access="private"/>
1018 <modify-function signature="operator QPointF()const" access="private"/>
1019 </value-type>
1019 </value-type>
1020
1020
1021 <value-type name="QTextEdit::ExtraSelection" delete-in-main-thread="yes">
1021 <value-type name="QTextEdit::ExtraSelection" delete-in-main-thread="yes">
1022 <include file-name="QTextEdit" location="global"/>
1022 <include file-name="QTextEdit" location="global"/>
1023 </value-type>
1023 </value-type>
1024
1024
1025 <value-type name="QFont" delete-in-main-thread="yes" expense-cost="1" expense-limit="1000">
1025 <value-type name="QFont" delete-in-main-thread="yes" expense-cost="1" expense-limit="1000">
1026 <extra-includes>
1026 <extra-includes>
1027 <include file-name="QStringList" location="global"/>
1027 <include file-name="QStringList" location="global"/>
1028 </extra-includes>
1028 </extra-includes>
1029 <modify-function signature="operator=(QFont)" remove="all"/>
1029 <modify-function signature="operator=(QFont)" remove="all"/>
1030 </value-type>
1030 </value-type>
1031
1031
1032 <value-type name="QTextTableCell" delete-in-main-thread="yes">
1032 <value-type name="QTextTableCell" delete-in-main-thread="yes">
1033 <extra-includes>
1033 <extra-includes>
1034 <include file-name="QTextCursor" location="global"/>
1034 <include file-name="QTextCursor" location="global"/>
1035 </extra-includes>
1035 </extra-includes>
1036 <modify-function signature="operator=(QTextTableCell)" remove="all"/>
1036 <modify-function signature="operator=(QTextTableCell)" remove="all"/>
1037 </value-type>
1037 </value-type>
1038
1038
1039 <value-type name="QImage" expense-limit="67108864" expense-cost="height()*bytesPerLine()">
1039 <value-type name="QImage" expense-limit="67108864" expense-cost="height()*bytesPerLine()">
1040 <modify-function signature="QImage(const char *, const char *)">
1040 <modify-function signature="QImage(const char *, const char *)">
1041 <remove/>
1041 <remove/>
1042 </modify-function>
1042 </modify-function>
1043 <modify-function signature="QImage(const char **)">
1043 <modify-function signature="QImage(const char **)">
1044 <access modifier="private"/>
1044 <access modifier="private"/>
1045 </modify-function>
1045 </modify-function>
1046 <modify-function signature="QImage(const uchar*,int,int,int,QImage::Format)">
1046 <modify-function signature="QImage(const uchar*,int,int,int,QImage::Format)">
1047 <remove/>
1047 <remove/>
1048 </modify-function>
1048 </modify-function>
1049 <modify-function signature="bits()const">
1049 <modify-function signature="bits()const">
1050 <remove/>
1050 <remove/>
1051 </modify-function>
1051 </modify-function>
1052 <modify-function signature="scanLine(int)const">
1052 <modify-function signature="scanLine(int)const">
1053 <remove/>
1053 <remove/>
1054 </modify-function>
1054 </modify-function>
1055 <modify-function signature="QImage(const uchar *, int, int, QImage::Format)">
1055 <modify-function signature="QImage(const uchar *, int, int, QImage::Format)">
1056 <remove/>
1056 <remove/>
1057 </modify-function>
1057 </modify-function>
1058
1058
1059 <extra-includes>
1059 <extra-includes>
1060 <include file-name="QStringList" location="global"/>
1060 <include file-name="QStringList" location="global"/>
1061 <include file-name="QMatrix" location="global"/>
1061 <include file-name="QMatrix" location="global"/>
1062 </extra-includes>
1062 </extra-includes>
1063
1063
1064 <modify-function signature="QImage(uchar*,int,int,QImage::Format)">
1064 <modify-function signature="QImage(uchar*,int,int,QImage::Format)">
1065 <access modifier="private"/>
1065 <access modifier="private"/>
1066 </modify-function>
1066 </modify-function>
1067
1067
1068 <!--
1068 <!--
1069 <modify-function signature="QImage(QString,const char*)">
1069 <modify-function signature="QImage(QString,const char*)">
1070 <access modifier="private"/>
1070 <access modifier="private"/>
1071 <modify-argument index="2">
1071 <modify-argument index="2">
1072 <remove-default-expression/>
1072 <remove-default-expression/>
1073 </modify-argument>
1073 </modify-argument>
1074 </modify-function>
1074 </modify-function>
1075 -->
1075 -->
1076
1076
1077 <modify-function signature="load(QString,const char*)">
1077 <modify-function signature="load(QString,const char*)">
1078 <access modifier="private"/>
1078 <access modifier="private"/>
1079 <modify-argument index="2">
1079 <modify-argument index="2">
1080 <remove-default-expression/>
1080 <remove-default-expression/>
1081 </modify-argument>
1081 </modify-argument>
1082 </modify-function>
1082 </modify-function>
1083
1083
1084 <modify-function signature="load(QIODevice*,const char*)">
1084 <modify-function signature="load(QIODevice*,const char*)">
1085 <access modifier="private"/>
1085 <access modifier="private"/>
1086 </modify-function>
1086 </modify-function>
1087
1087
1088 <modify-function signature="loadFromData(const uchar*,int,const char*)">
1088 <modify-function signature="loadFromData(const uchar*,int,const char*)">
1089 <access modifier="private"/>
1089 <access modifier="private"/>
1090 <modify-argument index="2">
1090 <modify-argument index="2">
1091 <remove-default-expression/>
1091 <remove-default-expression/>
1092 </modify-argument>
1092 </modify-argument>
1093 <modify-argument index="3">
1093 <modify-argument index="3">
1094 <remove-default-expression/>
1094 <remove-default-expression/>
1095 </modify-argument>
1095 </modify-argument>
1096 </modify-function>
1096 </modify-function>
1097
1097
1098 <modify-function signature="loadFromData(QByteArray,const char*)">
1098 <modify-function signature="loadFromData(QByteArray,const char*)">
1099 <access modifier="private"/>
1099 <access modifier="private"/>
1100 <modify-argument index="2">
1100 <modify-argument index="2">
1101 <remove-default-expression/>
1101 <remove-default-expression/>
1102 </modify-argument>
1102 </modify-argument>
1103 </modify-function>
1103 </modify-function>
1104
1104
1105 <modify-function signature="operator=(QImage)" remove="all"/>
1105 <modify-function signature="operator=(QImage)" remove="all"/>
1106
1106
1107 <modify-function signature="setText(const char*,const char*,QString)">
1107 <modify-function signature="setText(const char*,const char*,QString)">
1108 <remove/>
1108 <remove/>
1109 </modify-function>
1109 </modify-function>
1110
1110
1111 <modify-function signature="text(const char*,const char*)const">
1111 <modify-function signature="text(const char*,const char*)const">
1112 <remove/>
1112 <remove/>
1113 </modify-function>
1113 </modify-function>
1114
1114
1115 <modify-function signature="fromData(QByteArray,const char*)">
1115 <modify-function signature="fromData(QByteArray,const char*)">
1116 <access modifier="private"/>
1116 <access modifier="private"/>
1117 <modify-argument index="2">
1117 <modify-argument index="2">
1118 <remove-default-expression/>
1118 <remove-default-expression/>
1119 </modify-argument>
1119 </modify-argument>
1120 </modify-function>
1120 </modify-function>
1121
1121
1122 <modify-function signature="fromData(const uchar*,int,const char*)">
1122 <modify-function signature="fromData(const uchar*,int,const char*)">
1123 <remove/>
1123 <remove/>
1124 </modify-function>
1124 </modify-function>
1125
1125
1126 <modify-function signature="serialNumber()const" remove="all"/> <!--### Obsolete in 4.3-->
1126 <modify-function signature="serialNumber()const" remove="all"/> <!--### Obsolete in 4.3-->
1127 <modify-function signature="textLanguages()const" remove="all"/> <!--### Obsolete in 4.3-->
1127 <modify-function signature="textLanguages()const" remove="all"/> <!--### Obsolete in 4.3-->
1128
1128
1129 <modify-function signature="QImage(const char**)" remove="all"/>
1129 <modify-function signature="QImage(const char**)" remove="all"/>
1130 <modify-function signature="QImage(const uchar *,int,int,QImage::Format)" remove="all"/>
1130 <modify-function signature="QImage(const uchar *,int,int,QImage::Format)" remove="all"/>
1131 <modify-function signature="QImage(const uchar *,int,int,int,QImage::Format)" remove="all"/>
1131 <modify-function signature="QImage(const uchar *,int,int,int,QImage::Format)" remove="all"/>
1132 <modify-function signature="QImage(uchar *,int,int,QImage::Format)" remove="all"/>
1132 <modify-function signature="QImage(uchar *,int,int,QImage::Format)" remove="all"/>
1133 <modify-function signature="QImage(uchar *,int,int,int,QImage::Format)" remove="all"/>
1133 <modify-function signature="QImage(uchar *,int,int,int,QImage::Format)" remove="all"/>
1134 <modify-function signature="setColorTable(const QVector&lt;uint&gt;)" remove="all"/>
1134 <modify-function signature="setColorTable(const QVector&lt;uint&gt;)" remove="all"/>
1135 <modify-function signature="loadFromData(const uchar *,int,const char *)" remove="all"/>
1135 <modify-function signature="loadFromData(const uchar *,int,const char *)" remove="all"/>
1136 <modify-function signature="fromData(const uchar *,int,const char *)" remove="all"/>
1136 <modify-function signature="fromData(const uchar *,int,const char *)" remove="all"/>
1137 <modify-function signature="bits()" remove="all"/>
1137 <modify-function signature="bits()" remove="all"/>
1138 <modify-function signature="scanLine(int)" remove="all"/>
1138 <modify-function signature="scanLine(int)" remove="all"/>
1139
1139
1140 <modify-function signature="QImage(QString,const char*)">
1140 <modify-function signature="QImage(QString,const char*)">
1141 <modify-argument index="2">
1141 <modify-argument index="2">
1142 <replace-type modified-type="QString"/>
1142 <replace-type modified-type="QString"/>
1143 <conversion-rule class="native">
1143 <conversion-rule class="native">
1144 <insert-template name="core.convert_string_arg_to_char*"/>
1144 <insert-template name="core.convert_string_arg_to_char*"/>
1145 </conversion-rule>
1145 </conversion-rule>
1146 </modify-argument>
1146 </modify-argument>
1147 </modify-function>
1147 </modify-function>
1148
1148
1149 <modify-function signature="fromData(QByteArray,const char*)">
1149 <modify-function signature="fromData(QByteArray,const char*)">
1150 <modify-argument index="2">
1150 <modify-argument index="2">
1151 <replace-type modified-type="QString"/>
1151 <replace-type modified-type="QString"/>
1152 <conversion-rule class="native">
1152 <conversion-rule class="native">
1153 <insert-template name="core.convert_string_arg_to_char*"/>
1153 <insert-template name="core.convert_string_arg_to_char*"/>
1154 </conversion-rule>
1154 </conversion-rule>
1155 </modify-argument>
1155 </modify-argument>
1156 </modify-function>
1156 </modify-function>
1157
1157
1158 <modify-function signature="load(QString,const char*)">
1158 <modify-function signature="load(QString,const char*)">
1159 <modify-argument index="2">
1159 <modify-argument index="2">
1160 <replace-type modified-type="QString"/>
1160 <replace-type modified-type="QString"/>
1161 <conversion-rule class="native">
1161 <conversion-rule class="native">
1162 <insert-template name="core.convert_string_arg_to_char*"/>
1162 <insert-template name="core.convert_string_arg_to_char*"/>
1163 </conversion-rule>
1163 </conversion-rule>
1164 </modify-argument>
1164 </modify-argument>
1165 </modify-function>
1165 </modify-function>
1166
1166
1167 <modify-function signature="load(QIODevice*,const char*)">
1167 <modify-function signature="load(QIODevice*,const char*)">
1168 <modify-argument index="2">
1168 <modify-argument index="2">
1169 <replace-type modified-type="QString"/>
1169 <replace-type modified-type="QString"/>
1170 <conversion-rule class="native">
1170 <conversion-rule class="native">
1171 <insert-template name="core.convert_string_arg_to_char*"/>
1171 <insert-template name="core.convert_string_arg_to_char*"/>
1172 </conversion-rule>
1172 </conversion-rule>
1173 </modify-argument>
1173 </modify-argument>
1174 </modify-function>
1174 </modify-function>
1175
1175
1176 <modify-function signature="loadFromData(QByteArray,const char*)">
1176 <modify-function signature="loadFromData(QByteArray,const char*)">
1177 <modify-argument index="2">
1177 <modify-argument index="2">
1178 <replace-type modified-type="QString"/>
1178 <replace-type modified-type="QString"/>
1179 <conversion-rule class="native">
1179 <conversion-rule class="native">
1180 <insert-template name="core.convert_string_arg_to_char*"/>
1180 <insert-template name="core.convert_string_arg_to_char*"/>
1181 </conversion-rule>
1181 </conversion-rule>
1182 </modify-argument>
1182 </modify-argument>
1183 </modify-function>
1183 </modify-function>
1184
1184
1185 <modify-function signature="save(QString,const char*,int)const">
1185 <modify-function signature="save(QString,const char*,int)const">
1186 <modify-argument index="2">
1186 <modify-argument index="2">
1187 <replace-type modified-type="QString"/>
1187 <replace-type modified-type="QString"/>
1188 <conversion-rule class="native">
1188 <conversion-rule class="native">
1189 <insert-template name="core.convert_string_arg_to_char*"/>
1189 <insert-template name="core.convert_string_arg_to_char*"/>
1190 </conversion-rule>
1190 </conversion-rule>
1191 </modify-argument>
1191 </modify-argument>
1192 </modify-function>
1192 </modify-function>
1193
1193
1194 <modify-function signature="save(QIODevice*,const char*,int)const">
1194 <modify-function signature="save(QIODevice*,const char*,int)const">
1195 <modify-argument index="2">
1195 <modify-argument index="2">
1196 <replace-type modified-type="QString"/>
1196 <replace-type modified-type="QString"/>
1197 <conversion-rule class="native">
1197 <conversion-rule class="native">
1198 <insert-template name="core.convert_string_arg_to_char*"/>
1198 <insert-template name="core.convert_string_arg_to_char*"/>
1199 </conversion-rule>
1199 </conversion-rule>
1200 </modify-argument>
1200 </modify-argument>
1201 </modify-function>
1201 </modify-function>
1202
1202
1203 <inject-code class="pywrap-h">
1204 QImage* new_QImage( const uchar * data, int width, int height, QImage::Format format )
1205 {
1206 QImage* image = new QImage(width, height, format);
1207 memcpy(image-&gt;bits(), data, image-&gt;byteCount());
1208 return image;
1209 }
1210 </inject-code>
1211 </value-type>
1203 </value-type>
1212
1204
1213 <value-type name="QColormap" delete-in-main-thread="yes">
1205 <value-type name="QColormap" delete-in-main-thread="yes">
1214 <modify-function signature="operator=(QColormap)" remove="all"/>
1206 <modify-function signature="operator=(QColormap)" remove="all"/>
1215 <extra-includes>
1207 <extra-includes>
1216 <include file-name="QColor" location="global"/>
1208 <include file-name="QColor" location="global"/>
1217 </extra-includes>
1209 </extra-includes>
1218 <custom-constructor>
1210 <custom-constructor>
1219 return new QColormap(*copy);
1211 return new QColormap(*copy);
1220 </custom-constructor>
1212 </custom-constructor>
1221 <custom-destructor>
1213 <custom-destructor>
1222 delete copy;
1214 delete copy;
1223 </custom-destructor>
1215 </custom-destructor>
1224 </value-type>
1216 </value-type>
1225
1217
1226 <value-type name="QCursor" delete-in-main-thread="yes">
1218 <value-type name="QCursor" delete-in-main-thread="yes">
1227 <extra-includes>
1219 <extra-includes>
1228 <include file-name="QPixmap" location="global"/>
1220 <include file-name="QPixmap" location="global"/>
1229 </extra-includes>
1221 </extra-includes>
1230 <modify-function signature="operator=(QCursor)" remove="all"/>
1222 <modify-function signature="operator=(QCursor)" remove="all"/>
1231 </value-type>
1223 </value-type>
1232
1224
1233 <value-type name="QFontDatabase" delete-in-main-thread="yes">
1225 <value-type name="QFontDatabase" delete-in-main-thread="yes">
1234 <extra-includes>
1226 <extra-includes>
1235 <include file-name="QStringList" location="global"/>
1227 <include file-name="QStringList" location="global"/>
1236 </extra-includes>
1228 </extra-includes>
1237 </value-type>
1229 </value-type>
1238
1230
1239 <value-type name="QPen">
1231 <value-type name="QPen">
1240 <extra-includes>
1232 <extra-includes>
1241 <include file-name="QBrush" location="global"/>
1233 <include file-name="QBrush" location="global"/>
1242 </extra-includes>
1234 </extra-includes>
1243
1235
1244 <modify-function signature="operator=(QPen)" remove="all"/>
1236 <modify-function signature="operator=(QPen)" remove="all"/>
1245 </value-type>
1237 </value-type>
1246
1238
1247 <value-type name="QBrush">
1239 <value-type name="QBrush">
1248 <modify-function signature="QBrush(Qt::GlobalColor, Qt::BrushStyle)" remove="all"/>
1240 <modify-function signature="QBrush(Qt::GlobalColor, Qt::BrushStyle)" remove="all"/>
1249 <modify-function signature="operator=(const QBrush &amp;)" remove="all"/>
1241 <modify-function signature="operator=(const QBrush &amp;)" remove="all"/>
1250
1242
1251 <extra-includes>
1243 <extra-includes>
1252 <include file-name="QPixmap" location="global"/>
1244 <include file-name="QPixmap" location="global"/>
1253 </extra-includes>
1245 </extra-includes>
1254
1246
1255 <modify-function signature="QBrush(QGradient)">
1247 <modify-function signature="QBrush(QGradient)">
1256 <modify-argument index="1">
1248 <modify-argument index="1">
1257 <replace-type modified-type="QGradient*"/>
1249 <replace-type modified-type="QGradient*"/>
1258 <conversion-rule class="native">
1250 <conversion-rule class="native">
1259 QGradient &amp; %out% = *qscriptvalue_cast&lt;QGradient*&gt;(%in%);
1251 QGradient &amp; %out% = *qscriptvalue_cast&lt;QGradient*&gt;(%in%);
1260 </conversion-rule>
1252 </conversion-rule>
1261 </modify-argument>
1253 </modify-argument>
1262 </modify-function>
1254 </modify-function>
1263 </value-type>
1255 </value-type>
1264
1256
1265 <value-type name="QColor">
1257 <value-type name="QColor">
1266 <modify-function signature="QColor(QColor::Spec)" remove="all"/>
1258 <modify-function signature="QColor(QColor::Spec)" remove="all"/>
1267 <modify-function signature="operator=(QColor)" remove="all"/>
1259 <modify-function signature="operator=(QColor)" remove="all"/>
1268 <modify-function signature="operator=(Qt::GlobalColor)" remove="all"/>
1260 <modify-function signature="operator=(Qt::GlobalColor)" remove="all"/>
1269
1261
1270 <modify-function signature="QColor(const char*)">
1262 <modify-function signature="QColor(const char*)">
1271 <remove/>
1263 <remove/>
1272 </modify-function>
1264 </modify-function>
1273
1265
1274 <modify-function signature="getCmyk(int*,int*,int*,int*,int*)">
1266 <modify-function signature="getCmyk(int*,int*,int*,int*,int*)">
1275 <remove/>
1267 <remove/>
1276 </modify-function>
1268 </modify-function>
1277
1269
1278 <modify-function signature="getCmykF(qreal*,qreal*,qreal*,qreal*,qreal*)">
1270 <modify-function signature="getCmykF(qreal*,qreal*,qreal*,qreal*,qreal*)">
1279 <remove/>
1271 <remove/>
1280 </modify-function>
1272 </modify-function>
1281
1273
1282 <modify-function signature="getHsv(int*,int*,int*,int*)const">
1274 <modify-function signature="getHsv(int*,int*,int*,int*)const">
1283 <remove/>
1275 <remove/>
1284 </modify-function>
1276 </modify-function>
1285
1277
1286 <modify-function signature="getHsvF(qreal*,qreal*,qreal*,qreal*)const">
1278 <modify-function signature="getHsvF(qreal*,qreal*,qreal*,qreal*)const">
1287 <remove/>
1279 <remove/>
1288 </modify-function>
1280 </modify-function>
1289
1281
1290 <modify-function signature="getRgb(int*,int*,int*,int*)const">
1282 <modify-function signature="getRgb(int*,int*,int*,int*)const">
1291 <remove/>
1283 <remove/>
1292 </modify-function>
1284 </modify-function>
1293
1285
1294 <modify-function signature="getRgbF(qreal*,qreal*,qreal*,qreal*)const">
1286 <modify-function signature="getRgbF(qreal*,qreal*,qreal*,qreal*)const">
1295 <remove/>
1287 <remove/>
1296 </modify-function>
1288 </modify-function>
1297
1289
1298 <modify-function signature="dark(int)const" remove="all"/> <!--### Obsolete in 4.3-->
1290 <modify-function signature="dark(int)const" remove="all"/> <!--### Obsolete in 4.3-->
1299 <modify-function signature="light(int)const" remove="all"/> <!--### Obsolete in 4.3-->
1291 <modify-function signature="light(int)const" remove="all"/> <!--### Obsolete in 4.3-->
1300 </value-type>
1292 </value-type>
1301
1293
1302 <value-type name="QFontMetricsF" delete-in-main-thread="yes" expense-cost="1" expense-limit="1000">
1294 <value-type name="QFontMetricsF" delete-in-main-thread="yes" expense-cost="1" expense-limit="1000">
1303 <custom-constructor>
1295 <custom-constructor>
1304 return new QFontMetricsF(*copy);
1296 return new QFontMetricsF(*copy);
1305 </custom-constructor>
1297 </custom-constructor>
1306 <custom-destructor>
1298 <custom-destructor>
1307 delete copy;
1299 delete copy;
1308 </custom-destructor>
1300 </custom-destructor>
1309 <modify-function signature="operator!=(const QFontMetricsF &amp;)">
1301 <modify-function signature="operator!=(const QFontMetricsF &amp;)">
1310 <remove/>
1302 <remove/>
1311 </modify-function>
1303 </modify-function>
1312 <modify-function signature="operator==(const QFontMetricsF &amp;)">
1304 <modify-function signature="operator==(const QFontMetricsF &amp;)">
1313 <remove/>
1305 <remove/>
1314 </modify-function>
1306 </modify-function>
1315
1307
1316 <modify-function signature="boundingRect(QRectF,int,QString,int,int*)const">
1308 <modify-function signature="boundingRect(QRectF,int,QString,int,int*)const">
1317 <access modifier="private"/>
1309 <access modifier="private"/>
1318 <modify-argument index="4">
1310 <modify-argument index="4">
1319 <remove-default-expression/>
1311 <remove-default-expression/>
1320 </modify-argument>
1312 </modify-argument>
1321 <modify-argument index="5">
1313 <modify-argument index="5">
1322 <remove-default-expression/>
1314 <remove-default-expression/>
1323 </modify-argument>
1315 </modify-argument>
1324 </modify-function>
1316 </modify-function>
1325
1317
1326 <modify-function signature="operator=(QFontMetrics)" remove="all"/>
1318 <modify-function signature="operator=(QFontMetrics)" remove="all"/>
1327 <modify-function signature="operator=(QFontMetricsF)" remove="all"/>
1319 <modify-function signature="operator=(QFontMetricsF)" remove="all"/>
1328
1320
1329 <modify-function signature="size(int,QString,int,int*)const">
1321 <modify-function signature="size(int,QString,int,int*)const">
1330 <access modifier="private"/>
1322 <access modifier="private"/>
1331 <modify-argument index="3">
1323 <modify-argument index="3">
1332 <remove-default-expression/>
1324 <remove-default-expression/>
1333 </modify-argument>
1325 </modify-argument>
1334 <modify-argument index="4">
1326 <modify-argument index="4">
1335 <remove-default-expression/>
1327 <remove-default-expression/>
1336 </modify-argument>
1328 </modify-argument>
1337 </modify-function>
1329 </modify-function>
1338
1330
1339 <modify-function signature="QFontMetricsF(QFontMetricsF)" remove="all"/>
1331 <modify-function signature="QFontMetricsF(QFontMetricsF)" remove="all"/>
1340 <modify-function signature="QFontMetricsF(QFontMetrics)" remove="all"/>
1332 <modify-function signature="QFontMetricsF(QFontMetrics)" remove="all"/>
1341 <modify-function signature="operator==(QFontMetricsF)const" remove="all"/>
1333 <modify-function signature="operator==(QFontMetricsF)const" remove="all"/>
1342 <modify-function signature="operator!=(QFontMetricsF)const" remove="all"/>
1334 <modify-function signature="operator!=(QFontMetricsF)const" remove="all"/>
1343 </value-type>
1335 </value-type>
1344 <value-type name="QTextOption::Tab"/>
1336 <value-type name="QTextOption::Tab"/>
1345
1337
1346 <value-type name="QFontMetrics" delete-in-main-thread="yes" expense-cost="1" expense-limit="1000">
1338 <value-type name="QFontMetrics" delete-in-main-thread="yes" expense-cost="1" expense-limit="1000">
1347 <custom-constructor>
1339 <custom-constructor>
1348 return new QFontMetrics(*copy);
1340 return new QFontMetrics(*copy);
1349 </custom-constructor>
1341 </custom-constructor>
1350 <custom-destructor>
1342 <custom-destructor>
1351 delete copy;
1343 delete copy;
1352 </custom-destructor>
1344 </custom-destructor>
1353 <modify-function signature="operator!=(const QFontMetrics &amp;)">
1345 <modify-function signature="operator!=(const QFontMetrics &amp;)">
1354 <remove/>
1346 <remove/>
1355 </modify-function>
1347 </modify-function>
1356 <modify-function signature="operator==(const QFontMetrics &amp;)">
1348 <modify-function signature="operator==(const QFontMetrics &amp;)">
1357 <remove/>
1349 <remove/>
1358 </modify-function>
1350 </modify-function>
1359
1351
1360 <modify-function signature="boundingRect(int,int,int,int,int,QString,int,int*)const">
1352 <modify-function signature="boundingRect(int,int,int,int,int,QString,int,int*)const">
1361 <access modifier="private"/>
1353 <access modifier="private"/>
1362 <modify-argument index="7">
1354 <modify-argument index="7">
1363 <remove-default-expression/>
1355 <remove-default-expression/>
1364 </modify-argument>
1356 </modify-argument>
1365 <modify-argument index="8">
1357 <modify-argument index="8">
1366 <remove-default-expression/>
1358 <remove-default-expression/>
1367 </modify-argument>
1359 </modify-argument>
1368 </modify-function>
1360 </modify-function>
1369
1361
1370 <modify-function signature="boundingRect(QRect,int,QString,int,int*)const">
1362 <modify-function signature="boundingRect(QRect,int,QString,int,int*)const">
1371 <access modifier="private"/>
1363 <access modifier="private"/>
1372 <modify-argument index="4">
1364 <modify-argument index="4">
1373 <remove-default-expression/>
1365 <remove-default-expression/>
1374 </modify-argument>
1366 </modify-argument>
1375 <modify-argument index="5">
1367 <modify-argument index="5">
1376 <remove-default-expression/>
1368 <remove-default-expression/>
1377 </modify-argument>
1369 </modify-argument>
1378 </modify-function>
1370 </modify-function>
1379
1371
1380 <modify-function signature="operator=(QFontMetrics)" remove="all"/>
1372 <modify-function signature="operator=(QFontMetrics)" remove="all"/>
1381
1373
1382 <modify-function signature="size(int,QString,int,int*)const">
1374 <modify-function signature="size(int,QString,int,int*)const">
1383 <access modifier="private"/>
1375 <access modifier="private"/>
1384 <modify-argument index="3">
1376 <modify-argument index="3">
1385 <remove-default-expression/>
1377 <remove-default-expression/>
1386 </modify-argument>
1378 </modify-argument>
1387 <modify-argument index="4">
1379 <modify-argument index="4">
1388 <remove-default-expression/>
1380 <remove-default-expression/>
1389 </modify-argument>
1381 </modify-argument>
1390 </modify-function>
1382 </modify-function>
1391
1383
1392
1384
1393 <modify-function signature="QFontMetrics(QFontMetrics)" remove="all"/>
1385 <modify-function signature="QFontMetrics(QFontMetrics)" remove="all"/>
1394 <modify-function signature="operator==(QFontMetrics)const" remove="all"/>
1386 <modify-function signature="operator==(QFontMetrics)const" remove="all"/>
1395 <modify-function signature="operator!=(QFontMetrics)const" remove="all"/>
1387 <modify-function signature="operator!=(QFontMetrics)const" remove="all"/>
1396 </value-type>
1388 </value-type>
1397
1389
1398 <value-type name="QGradient" force-abstract="yes" polymorphic-base="yes" polymorphic-id-expression="%1-&gt;type() == QGradient::NoGradient">
1390 <value-type name="QGradient" force-abstract="yes" polymorphic-base="yes" polymorphic-id-expression="%1-&gt;type() == QGradient::NoGradient">
1399 <custom-constructor>
1391 <custom-constructor>
1400 Q_UNUSED(copy)
1392 Q_UNUSED(copy)
1401 qWarning("Copying empty QGradient object");
1393 qWarning("Copying empty QGradient object");
1402 return new QGradient();
1394 return new QGradient();
1403 </custom-constructor>
1395 </custom-constructor>
1404 <custom-destructor>
1396 <custom-destructor>
1405 delete copy;
1397 delete copy;
1406 </custom-destructor>
1398 </custom-destructor>
1407 <modify-function signature="operator==(const QGradient &amp;)">
1399 <modify-function signature="operator==(const QGradient &amp;)">
1408 <remove/>
1400 <remove/>
1409 </modify-function>
1401 </modify-function>
1410 </value-type>
1402 </value-type>
1411
1403
1412 <value-type name="QLinearGradient" polymorphic-id-expression="%1-&gt;type() == QGradient::LinearGradient">
1404 <value-type name="QLinearGradient" polymorphic-id-expression="%1-&gt;type() == QGradient::LinearGradient">
1413 <custom-constructor>
1405 <custom-constructor>
1414 QLinearGradient *lg = new QLinearGradient(copy-&gt;start(), copy-&gt;finalStop());
1406 QLinearGradient *lg = new QLinearGradient(copy-&gt;start(), copy-&gt;finalStop());
1415 lg-&gt;setSpread(copy-&gt;spread());
1407 lg-&gt;setSpread(copy-&gt;spread());
1416 lg-&gt;setStops(copy-&gt;stops());
1408 lg-&gt;setStops(copy-&gt;stops());
1417 return (void *) lg;
1409 return (void *) lg;
1418 </custom-constructor>
1410 </custom-constructor>
1419 <custom-destructor>
1411 <custom-destructor>
1420 delete copy;
1412 delete copy;
1421 </custom-destructor>
1413 </custom-destructor>
1422 </value-type>
1414 </value-type>
1423
1415
1424 <value-type name="QPrinterInfo">
1416 <value-type name="QPrinterInfo">
1425 <modify-function signature="operator=(const QPrinterInfo &amp;)" remove="all"/>
1417 <modify-function signature="operator=(const QPrinterInfo &amp;)" remove="all"/>
1426 </value-type>
1418 </value-type>
1427
1419
1428 <interface-type name="QLayoutItem"/>
1420 <interface-type name="QLayoutItem"/>
1429 <interface-type name="QPaintDevice"/>
1421 <interface-type name="QPaintDevice"/>
1430
1422
1431 <interface-type name="QGraphicsItem" delete-in-main-thread="yes">
1423 <interface-type name="QGraphicsItem" delete-in-main-thread="yes">
1432 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/>
1424 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/>
1433 <modify-function signature="toGraphicsObject() const" remove="all"/>
1425 <modify-function signature="toGraphicsObject() const" remove="all"/>
1434
1426
1435 <modify-function signature="paint(QPainter*,const QStyleOptionGraphicsItem*,QWidget*)">
1427 <modify-function signature="paint(QPainter*,const QStyleOptionGraphicsItem*,QWidget*)">
1436 <modify-argument index="1" invalidate-after-use="yes"/>
1428 <modify-argument index="1" invalidate-after-use="yes"/>
1437 </modify-function>
1429 </modify-function>
1438 <modify-function signature="collidesWithItem(const QGraphicsItem*,Qt::ItemSelectionMode)const">
1430 <modify-function signature="collidesWithItem(const QGraphicsItem*,Qt::ItemSelectionMode)const">
1439 <modify-argument index="1" invalidate-after-use="yes"/>
1431 <modify-argument index="1" invalidate-after-use="yes"/>
1440 </modify-function>
1432 </modify-function>
1441
1433
1442 <modify-function signature="contextMenuEvent(QGraphicsSceneContextMenuEvent*)">
1434 <modify-function signature="contextMenuEvent(QGraphicsSceneContextMenuEvent*)">
1443 <modify-argument index="1" invalidate-after-use="yes"/>
1435 <modify-argument index="1" invalidate-after-use="yes"/>
1444 </modify-function>
1436 </modify-function>
1445 <modify-function signature="dragEnterEvent(QGraphicsSceneDragDropEvent*)">
1437 <modify-function signature="dragEnterEvent(QGraphicsSceneDragDropEvent*)">
1446 <modify-argument index="1" invalidate-after-use="yes"/>
1438 <modify-argument index="1" invalidate-after-use="yes"/>
1447 </modify-function>
1439 </modify-function>
1448 <modify-function signature="dragLeaveEvent(QGraphicsSceneDragDropEvent*)">
1440 <modify-function signature="dragLeaveEvent(QGraphicsSceneDragDropEvent*)">
1449 <modify-argument index="1" invalidate-after-use="yes"/>
1441 <modify-argument index="1" invalidate-after-use="yes"/>
1450 </modify-function>
1442 </modify-function>
1451 <modify-function signature="dragMoveEvent(QGraphicsSceneDragDropEvent*)">
1443 <modify-function signature="dragMoveEvent(QGraphicsSceneDragDropEvent*)">
1452 <modify-argument index="1" invalidate-after-use="yes"/>
1444 <modify-argument index="1" invalidate-after-use="yes"/>
1453 </modify-function>
1445 </modify-function>
1454 <modify-function signature="dropEvent(QGraphicsSceneDragDropEvent*)">
1446 <modify-function signature="dropEvent(QGraphicsSceneDragDropEvent*)">
1455 <modify-argument index="1" invalidate-after-use="yes"/>
1447 <modify-argument index="1" invalidate-after-use="yes"/>
1456 </modify-function>
1448 </modify-function>
1457 <modify-function signature="focusInEvent(QFocusEvent*)">
1449 <modify-function signature="focusInEvent(QFocusEvent*)">
1458 <modify-argument index="1" invalidate-after-use="yes"/>
1450 <modify-argument index="1" invalidate-after-use="yes"/>
1459 </modify-function>
1451 </modify-function>
1460 <modify-function signature="focusOutEvent(QFocusEvent*)">
1452 <modify-function signature="focusOutEvent(QFocusEvent*)">
1461 <modify-argument index="1" invalidate-after-use="yes"/>
1453 <modify-argument index="1" invalidate-after-use="yes"/>
1462 </modify-function>
1454 </modify-function>
1463 <modify-function signature="hoverEnterEvent(QGraphicsSceneHoverEvent*)">
1455 <modify-function signature="hoverEnterEvent(QGraphicsSceneHoverEvent*)">
1464 <modify-argument index="1" invalidate-after-use="yes"/>
1456 <modify-argument index="1" invalidate-after-use="yes"/>
1465 </modify-function>
1457 </modify-function>
1466 <modify-function signature="hoverLeaveEvent(QGraphicsSceneHoverEvent*)">
1458 <modify-function signature="hoverLeaveEvent(QGraphicsSceneHoverEvent*)">
1467 <modify-argument index="1" invalidate-after-use="yes"/>
1459 <modify-argument index="1" invalidate-after-use="yes"/>
1468 </modify-function>
1460 </modify-function>
1469 <modify-function signature="hoverMoveEvent(QGraphicsSceneHoverEvent*)">
1461 <modify-function signature="hoverMoveEvent(QGraphicsSceneHoverEvent*)">
1470 <modify-argument index="1" invalidate-after-use="yes"/>
1462 <modify-argument index="1" invalidate-after-use="yes"/>
1471 </modify-function>
1463 </modify-function>
1472 <modify-function signature="inputMethodEvent(QInputMethodEvent*)">
1464 <modify-function signature="inputMethodEvent(QInputMethodEvent*)">
1473 <modify-argument index="1" invalidate-after-use="yes"/>
1465 <modify-argument index="1" invalidate-after-use="yes"/>
1474 </modify-function>
1466 </modify-function>
1475 <modify-function signature="isObscuredBy(const QGraphicsItem*)const">
1467 <modify-function signature="isObscuredBy(const QGraphicsItem*)const">
1476 <modify-argument index="1" invalidate-after-use="yes"/>
1468 <modify-argument index="1" invalidate-after-use="yes"/>
1477 </modify-function>
1469 </modify-function>
1478 <modify-function signature="keyPressEvent(QKeyEvent*)">
1470 <modify-function signature="keyPressEvent(QKeyEvent*)">
1479 <modify-argument index="1" invalidate-after-use="yes"/>
1471 <modify-argument index="1" invalidate-after-use="yes"/>
1480 </modify-function>
1472 </modify-function>
1481 <modify-function signature="keyReleaseEvent(QKeyEvent*)">
1473 <modify-function signature="keyReleaseEvent(QKeyEvent*)">
1482 <modify-argument index="1" invalidate-after-use="yes"/>
1474 <modify-argument index="1" invalidate-after-use="yes"/>
1483 </modify-function>
1475 </modify-function>
1484 <modify-function signature="mouseDoubleClickEvent(QGraphicsSceneMouseEvent*)">
1476 <modify-function signature="mouseDoubleClickEvent(QGraphicsSceneMouseEvent*)">
1485 <modify-argument index="1" invalidate-after-use="yes"/>
1477 <modify-argument index="1" invalidate-after-use="yes"/>
1486 </modify-function>
1478 </modify-function>
1487 <modify-function signature="mouseMoveEvent(QGraphicsSceneMouseEvent*)">
1479 <modify-function signature="mouseMoveEvent(QGraphicsSceneMouseEvent*)">
1488 <modify-argument index="1" invalidate-after-use="yes"/>
1480 <modify-argument index="1" invalidate-after-use="yes"/>
1489 </modify-function>
1481 </modify-function>
1490 <modify-function signature="mousePressEvent(QGraphicsSceneMouseEvent*)">
1482 <modify-function signature="mousePressEvent(QGraphicsSceneMouseEvent*)">
1491 <modify-argument index="1" invalidate-after-use="yes"/>
1483 <modify-argument index="1" invalidate-after-use="yes"/>
1492 </modify-function>
1484 </modify-function>
1493 <modify-function signature="mouseReleaseEvent(QGraphicsSceneMouseEvent*)">
1485 <modify-function signature="mouseReleaseEvent(QGraphicsSceneMouseEvent*)">
1494 <modify-argument index="1" invalidate-after-use="yes"/>
1486 <modify-argument index="1" invalidate-after-use="yes"/>
1495 </modify-function>
1487 </modify-function>
1496 <modify-function signature="sceneEvent(QEvent*)">
1488 <modify-function signature="sceneEvent(QEvent*)">
1497 <modify-argument index="1" invalidate-after-use="yes"/>
1489 <modify-argument index="1" invalidate-after-use="yes"/>
1498 </modify-function>
1490 </modify-function>
1499 <modify-function signature="sceneEventFilter(QGraphicsItem*,QEvent*)">
1491 <modify-function signature="sceneEventFilter(QGraphicsItem*,QEvent*)">
1500 <modify-argument index="1" invalidate-after-use="yes"/>
1492 <modify-argument index="1" invalidate-after-use="yes"/>
1501 <modify-argument index="2" invalidate-after-use="yes"/>
1493 <modify-argument index="2" invalidate-after-use="yes"/>
1502 </modify-function>
1494 </modify-function>
1503 <modify-function signature="wheelEvent(QGraphicsSceneWheelEvent*)">
1495 <modify-function signature="wheelEvent(QGraphicsSceneWheelEvent*)">
1504 <modify-argument index="1" invalidate-after-use="yes"/>
1496 <modify-argument index="1" invalidate-after-use="yes"/>
1505 </modify-function>
1497 </modify-function>
1506
1498
1507 <modify-function signature="children()const" remove="all"/>
1499 <modify-function signature="children()const" remove="all"/>
1508 <modify-function signature="installSceneEventFilter(QGraphicsItem *)">
1500 <modify-function signature="installSceneEventFilter(QGraphicsItem *)">
1509 <modify-argument index="1">
1501 <modify-argument index="1">
1510 <!-- Safe to ignore because items in a scene are memory managed by the scene -->
1502 <!-- Safe to ignore because items in a scene are memory managed by the scene -->
1511 <reference-count action="ignore"/>
1503 <reference-count action="ignore"/>
1512 </modify-argument>
1504 </modify-argument>
1513 </modify-function>
1505 </modify-function>
1514 <modify-function signature="removeSceneEventFilter(QGraphicsItem *)">
1506 <modify-function signature="removeSceneEventFilter(QGraphicsItem *)">
1515 <modify-argument index="1">
1507 <modify-argument index="1">
1516 <!-- Safe to ignore because items in a scene are memory managed by the scene -->
1508 <!-- Safe to ignore because items in a scene are memory managed by the scene -->
1517 <reference-count action="ignore"/>
1509 <reference-count action="ignore"/>
1518 </modify-argument>
1510 </modify-argument>
1519 </modify-function>
1511 </modify-function>
1520
1512
1521 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1513 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1522 <modify-function signature="resetMatrix()" remove="all"/> <!--### Obsolete in 4.3-->
1514 <modify-function signature="resetMatrix()" remove="all"/> <!--### Obsolete in 4.3-->
1523 <modify-function signature="sceneMatrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1515 <modify-function signature="sceneMatrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1524 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
1516 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
1525
1517
1526 <modify-function signature="supportsExtension(QGraphicsItem::Extension)const" remove="all"/>
1518 <modify-function signature="supportsExtension(QGraphicsItem::Extension)const" remove="all"/>
1527 <modify-function signature="setExtension(QGraphicsItem::Extension,QVariant)" remove="all"/>
1519 <modify-function signature="setExtension(QGraphicsItem::Extension,QVariant)" remove="all"/>
1528 </interface-type>
1520 </interface-type>
1529
1521
1530 <object-type name="QAbstractGraphicsShapeItem" delete-in-main-thread="yes">
1522 <object-type name="QAbstractGraphicsShapeItem" delete-in-main-thread="yes">
1531 <modify-function signature="QAbstractGraphicsShapeItem(QGraphicsItem*,QGraphicsScene*)">
1523 <modify-function signature="QAbstractGraphicsShapeItem(QGraphicsItem*,QGraphicsScene*)">
1532 <inject-code position="end">
1524 <inject-code position="end">
1533 <argument-map index="1" meta-name="%1"/>
1525 <argument-map index="1" meta-name="%1"/>
1534 if (%1 != null) disableGarbageCollection();
1526 if (%1 != null) disableGarbageCollection();
1535 </inject-code>
1527 </inject-code>
1536 </modify-function>
1528 </modify-function>
1537
1529
1538 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1530 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1539 <modify-function signature="resetMatrix()" remove="all"/> <!--### Obsolete in 4.3-->
1531 <modify-function signature="resetMatrix()" remove="all"/> <!--### Obsolete in 4.3-->
1540 <modify-function signature="sceneMatrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1532 <modify-function signature="sceneMatrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1541 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
1533 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
1542 </object-type>
1534 </object-type>
1543
1535
1544 <object-type name="QAbstractItemView">
1536 <object-type name="QAbstractItemView">
1545 <modify-function signature="update()" remove="all"/>
1537 <modify-function signature="update()" remove="all"/>
1546 <modify-function signature="horizontalStepsPerItem()const" remove="all"/> <!--### Obsolete in 4.3-->
1538 <modify-function signature="horizontalStepsPerItem()const" remove="all"/> <!--### Obsolete in 4.3-->
1547 <modify-function signature="setHorizontalStepsPerItem(int)" remove="all"/> <!--### Obsolete in 4.3-->
1539 <modify-function signature="setHorizontalStepsPerItem(int)" remove="all"/> <!--### Obsolete in 4.3-->
1548 <modify-function signature="setVerticalStepsPerItem(int)" remove="all"/> <!--### Obsolete in 4.3-->
1540 <modify-function signature="setVerticalStepsPerItem(int)" remove="all"/> <!--### Obsolete in 4.3-->
1549 <modify-function signature="verticalStepsPerItem()const" remove="all"/> <!--### Obsolete in 4.3-->
1541 <modify-function signature="verticalStepsPerItem()const" remove="all"/> <!--### Obsolete in 4.3-->
1550
1542
1551 <modify-function signature="edit(QModelIndex,QAbstractItemView::EditTrigger,QEvent*)">
1543 <modify-function signature="edit(QModelIndex,QAbstractItemView::EditTrigger,QEvent*)">
1552 <modify-argument index="3" invalidate-after-use="yes"/>
1544 <modify-argument index="3" invalidate-after-use="yes"/>
1553 </modify-function>
1545 </modify-function>
1554 <modify-function signature="selectionCommand(QModelIndex,const QEvent*)const">
1546 <modify-function signature="selectionCommand(QModelIndex,const QEvent*)const">
1555 <modify-argument index="2" invalidate-after-use="yes"/>
1547 <modify-argument index="2" invalidate-after-use="yes"/>
1556 </modify-function>
1548 </modify-function>
1557
1549
1558
1550
1559 <!-- ### because the CursorAction enum is protected -->
1551 <!-- ### because the CursorAction enum is protected -->
1560 <modify-function signature="moveCursor(QAbstractItemView::CursorAction,QFlags&lt;Qt::KeyboardModifier&gt;)" remove="all"/>
1552 <modify-function signature="moveCursor(QAbstractItemView::CursorAction,QFlags&lt;Qt::KeyboardModifier&gt;)" remove="all"/>
1561 <inject-code class="shell-declaration">
1553 <inject-code class="shell-declaration">
1562 QModelIndex moveCursor(QAbstractItemView::CursorAction, Qt::KeyboardModifiers)
1554 QModelIndex moveCursor(QAbstractItemView::CursorAction, Qt::KeyboardModifiers)
1563 { return QModelIndex(); }
1555 { return QModelIndex(); }
1564 </inject-code>
1556 </inject-code>
1565 </object-type>
1557 </object-type>
1566
1558
1567 <object-type name="QAbstractPageSetupDialog"/>
1559 <object-type name="QAbstractPageSetupDialog"/>
1568 <object-type name="QAbstractPrintDialog"/>
1560 <object-type name="QAbstractPrintDialog"/>
1569 <object-type name="QAbstractSlider">
1561 <object-type name="QAbstractSlider">
1570 <modify-function signature="sliderChange(QAbstractSlider::SliderChange)" remove="all"/>
1562 <modify-function signature="sliderChange(QAbstractSlider::SliderChange)" remove="all"/>
1571 </object-type>
1563 </object-type>
1572 <object-type name="QAbstractTextDocumentLayout">
1564 <object-type name="QAbstractTextDocumentLayout">
1573 <modify-function signature="setPaintDevice(QPaintDevice*)">
1565 <modify-function signature="setPaintDevice(QPaintDevice*)">
1574 <modify-argument index="1">
1566 <modify-argument index="1">
1575 <reference-count action="set" variable-name="__rcPaintDevice"/>
1567 <reference-count action="set" variable-name="__rcPaintDevice"/>
1576 </modify-argument>
1568 </modify-argument>
1577 </modify-function>
1569 </modify-function>
1578
1570
1579 <modify-function signature="draw(QPainter*,QAbstractTextDocumentLayout::PaintContext)">
1571 <modify-function signature="draw(QPainter*,QAbstractTextDocumentLayout::PaintContext)">
1580 <modify-argument index="1" invalidate-after-use="yes"/>
1572 <modify-argument index="1" invalidate-after-use="yes"/>
1581 </modify-function>
1573 </modify-function>
1582 <modify-function signature="drawInlineObject(QPainter*,QRectF,QTextInlineObject,int,QTextFormat)">
1574 <modify-function signature="drawInlineObject(QPainter*,QRectF,QTextInlineObject,int,QTextFormat)">
1583 <modify-argument index="1" invalidate-after-use="yes"/>
1575 <modify-argument index="1" invalidate-after-use="yes"/>
1584 </modify-function>
1576 </modify-function>
1585
1577
1586 </object-type>
1578 </object-type>
1587 <object-type name="QActionGroup"/>
1579 <object-type name="QActionGroup"/>
1588 <object-type name="QCDEStyle">
1580 <object-type name="QCDEStyle">
1589 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
1581 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
1590 </object-type>
1582 </object-type>
1591 <object-type name="QCheckBox">
1583 <object-type name="QCheckBox">
1592 <modify-function signature="initStyleOption(QStyleOptionButton*)const">
1584 <modify-function signature="initStyleOption(QStyleOptionButton*)const">
1593 <access modifier="private"/>
1585 <access modifier="private"/>
1594 </modify-function>
1586 </modify-function>
1595 </object-type>
1587 </object-type>
1596 <object-type name="QCleanlooksStyle">
1588 <object-type name="QCleanlooksStyle">
1597 <modify-function signature="standardPixmap(QStyle::StandardPixmap,const QStyleOption*,const QWidget*)const" remove="all"/> <!--### Obsolete in 4.3-->
1589 <modify-function signature="standardPixmap(QStyle::StandardPixmap,const QStyleOption*,const QWidget*)const" remove="all"/> <!--### Obsolete in 4.3-->
1598 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
1590 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
1599 </object-type>
1591 </object-type>
1600 <object-type name="QCommonStyle">
1592 <object-type name="QCommonStyle">
1601 <modify-function signature="standardPixmap(QStyle::StandardPixmap, const QStyleOption*,const QWidget*)const" remove="all"/> <!--### Obsolete in 4.3-->
1593 <modify-function signature="standardPixmap(QStyle::StandardPixmap, const QStyleOption*,const QWidget*)const" remove="all"/> <!--### Obsolete in 4.3-->
1602 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
1594 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
1603 </object-type>
1595 </object-type>
1604 <object-type name="QDataWidgetMapper">
1596 <object-type name="QDataWidgetMapper">
1605 <modify-function signature="addMapping(QWidget*,int)">
1597 <modify-function signature="addMapping(QWidget*,int)">
1606 <modify-argument index="1">
1598 <modify-argument index="1">
1607 <reference-count action="add" variable-name="__rcMappings"/>
1599 <reference-count action="add" variable-name="__rcMappings"/>
1608 </modify-argument>
1600 </modify-argument>
1609 </modify-function>
1601 </modify-function>
1610 <modify-function signature="addMapping(QWidget*,int,QByteArray)">
1602 <modify-function signature="addMapping(QWidget*,int,QByteArray)">
1611 <modify-argument index="1">
1603 <modify-argument index="1">
1612 <reference-count action="add" variable-name="__rcMappings"/>
1604 <reference-count action="add" variable-name="__rcMappings"/>
1613 </modify-argument>
1605 </modify-argument>
1614 </modify-function>
1606 </modify-function>
1615 <modify-function signature="removeMapping(QWidget*)">
1607 <modify-function signature="removeMapping(QWidget*)">
1616 <modify-argument index="1">
1608 <modify-argument index="1">
1617 <reference-count action="remove" variable-name="__rcMappings"/>
1609 <reference-count action="remove" variable-name="__rcMappings"/>
1618 </modify-argument>
1610 </modify-argument>
1619 </modify-function>
1611 </modify-function>
1620 <modify-function signature="setItemDelegate(QAbstractItemDelegate*)">
1612 <modify-function signature="setItemDelegate(QAbstractItemDelegate*)">
1621 <modify-argument index="1">
1613 <modify-argument index="1">
1622 <reference-count action="set" variable-name="__rcItemDelegate"/>
1614 <reference-count action="set" variable-name="__rcItemDelegate"/>
1623 </modify-argument>
1615 </modify-argument>
1624 </modify-function>
1616 </modify-function>
1625 <modify-function signature="setModel(QAbstractItemModel*)">
1617 <modify-function signature="setModel(QAbstractItemModel*)">
1626 <modify-argument index="1">
1618 <modify-argument index="1">
1627 <reference-count action="set" variable-name="__rcModel"/>
1619 <reference-count action="set" variable-name="__rcModel"/>
1628 </modify-argument>
1620 </modify-argument>
1629 </modify-function>
1621 </modify-function>
1630 </object-type>
1622 </object-type>
1631 <object-type name="QDateEdit"/>
1623 <object-type name="QDateEdit"/>
1632 <object-type name="QDesktopServices">
1624 <object-type name="QDesktopServices">
1633 <modify-function signature="setUrlHandler(const QString &amp;, QObject *, const char *)" access="private">
1625 <modify-function signature="setUrlHandler(const QString &amp;, QObject *, const char *)" access="private">
1634 <modify-argument index="2">
1626 <modify-argument index="2">
1635 <reference-count action="ignore"/> <!-- Handled in injected code -->
1627 <reference-count action="ignore"/> <!-- Handled in injected code -->
1636 </modify-argument>
1628 </modify-argument>
1637 </modify-function>
1629 </modify-function>
1638 </object-type>
1630 </object-type>
1639 <object-type name="QDialog">
1631 <object-type name="QDialog">
1640 <modify-function signature="setExtension(QWidget*)" remove="all"/>
1632 <modify-function signature="setExtension(QWidget*)" remove="all"/>
1641 <modify-function signature="exec()" access="non-final"/>
1633 <modify-function signature="exec()" access="non-final"/>
1642 <modify-function signature="extension()const" remove="all"/> <!--### Obsolete in 4.3-->
1634 <modify-function signature="extension()const" remove="all"/> <!--### Obsolete in 4.3-->
1643 <modify-function signature="orientation()const" remove="all"/> <!--### Obsolete in 4.3-->
1635 <modify-function signature="orientation()const" remove="all"/> <!--### Obsolete in 4.3-->
1644 <modify-function signature="open()" virtual-slot="yes"/>
1636 <modify-function signature="open()" virtual-slot="yes"/>
1645 <modify-function signature="setOrientation(Qt::Orientation)" remove="all"/> <!--### Obsolete in 4.3-->
1637 <modify-function signature="setOrientation(Qt::Orientation)" remove="all"/> <!--### Obsolete in 4.3-->
1646 <modify-function signature="showExtension(bool)" remove="all"/> <!--### Obsolete in 4.3-->
1638 <modify-function signature="showExtension(bool)" remove="all"/> <!--### Obsolete in 4.3-->
1647 <modify-function signature="setVisible(bool)" allow-as-slot="yes"/>
1639 <modify-function signature="setVisible(bool)" allow-as-slot="yes"/>
1648 </object-type>
1640 </object-type>
1649 <object-type name="QDialogButtonBox">
1641 <object-type name="QDialogButtonBox">
1650 <modify-function signature="addButton(QAbstractButton*,QDialogButtonBox::ButtonRole)">
1642 <modify-function signature="addButton(QAbstractButton*,QDialogButtonBox::ButtonRole)">
1651 <modify-argument index="1">
1643 <modify-argument index="1">
1652 <reference-count action="ignore"/>
1644 <reference-count action="ignore"/>
1653 </modify-argument>
1645 </modify-argument>
1654 </modify-function>
1646 </modify-function>
1655 <modify-function signature="removeButton(QAbstractButton*)">
1647 <modify-function signature="removeButton(QAbstractButton*)">
1656 <modify-argument index="1">
1648 <modify-argument index="1">
1657 <reference-count action="ignore"/>
1649 <reference-count action="ignore"/>
1658 </modify-argument>
1650 </modify-argument>
1659 </modify-function>
1651 </modify-function>
1660 </object-type>
1652 </object-type>
1661 <object-type name="QDirModel">
1653 <object-type name="QDirModel">
1662 <modify-function signature="parent()const" remove="all"/>
1654 <modify-function signature="parent()const" remove="all"/>
1663 <modify-function signature="setIconProvider(QFileIconProvider*)">
1655 <modify-function signature="setIconProvider(QFileIconProvider*)">
1664 <modify-argument index="1">
1656 <modify-argument index="1">
1665 <reference-count action="set" variable-name="__rcIconProvider"/>
1657 <reference-count action="set" variable-name="__rcIconProvider"/>
1666 </modify-argument>
1658 </modify-argument>
1667 </modify-function>
1659 </modify-function>
1668 </object-type>
1660 </object-type>
1669 <object-type name="QDoubleValidator"/>
1661 <object-type name="QDoubleValidator"/>
1670 <object-type name="QFileIconProvider"/>
1662 <object-type name="QFileIconProvider"/>
1671 <object-type name="QWizard">
1663 <object-type name="QWizard">
1672 <!-- ### Requires correct class name in meta object -->
1664 <!-- ### Requires correct class name in meta object -->
1673 <modify-function signature="setDefaultProperty(const char *, const char *, const char *)" remove="all"/>
1665 <modify-function signature="setDefaultProperty(const char *, const char *, const char *)" remove="all"/>
1674 <modify-function signature="addPage(QWizardPage*)">
1666 <modify-function signature="addPage(QWizardPage*)">
1675 <modify-argument index="1">
1667 <modify-argument index="1">
1676 <no-null-pointer/>
1668 <no-null-pointer/>
1677 <reference-count action="ignore"/>
1669 <reference-count action="ignore"/>
1678 </modify-argument>
1670 </modify-argument>
1679 </modify-function>
1671 </modify-function>
1680 <modify-function signature="setButton(QWizard::WizardButton,QAbstractButton*)">
1672 <modify-function signature="setButton(QWizard::WizardButton,QAbstractButton*)">
1681 <modify-argument index="1">
1673 <modify-argument index="1">
1682 <reference-count action="ignore"/>
1674 <reference-count action="ignore"/>
1683 </modify-argument>
1675 </modify-argument>
1684 </modify-function>
1676 </modify-function>
1685 <modify-function signature="setPage(int,QWizardPage*)">
1677 <modify-function signature="setPage(int,QWizardPage*)">
1686 <modify-argument index="2">
1678 <modify-argument index="2">
1687 <no-null-pointer/>
1679 <no-null-pointer/>
1688 <reference-count action="ignore"/>
1680 <reference-count action="ignore"/>
1689 </modify-argument>
1681 </modify-argument>
1690 </modify-function>
1682 </modify-function>
1691
1683
1692 </object-type>
1684 </object-type>
1693 <object-type name="QWizardPage">
1685 <object-type name="QWizardPage">
1694 <!-- ### Reduced functionality due to meta object having missing information -->
1686 <!-- ### Reduced functionality due to meta object having missing information -->
1695 <modify-function signature="registerField(const QString &amp;, QWidget *, const char *, const char *)">
1687 <modify-function signature="registerField(const QString &amp;, QWidget *, const char *, const char *)">
1696 <access modifier="private"/>
1688 <access modifier="private"/>
1697 <modify-argument index="3">
1689 <modify-argument index="3">
1698 <remove-default-expression/>
1690 <remove-default-expression/>
1699 </modify-argument>
1691 </modify-argument>
1700 <modify-argument index="4">
1692 <modify-argument index="4">
1701 <remove-default-expression/>
1693 <remove-default-expression/>
1702 </modify-argument>
1694 </modify-argument>
1703 </modify-function>
1695 </modify-function>
1704
1696
1705 </object-type>
1697 </object-type>
1706 <object-type name="QFocusFrame">
1698 <object-type name="QFocusFrame">
1707 <modify-function signature="initStyleOption(QStyleOption*)const">
1699 <modify-function signature="initStyleOption(QStyleOption*)const">
1708 <access modifier="private"/>
1700 <access modifier="private"/>
1709 </modify-function>
1701 </modify-function>
1710 <modify-function signature="setWidget(QWidget*)">
1702 <modify-function signature="setWidget(QWidget*)">
1711 <modify-argument index="1">
1703 <modify-argument index="1">
1712 <reference-count action="set" variable-name="__rcWidget"/>
1704 <reference-count action="set" variable-name="__rcWidget"/>
1713 </modify-argument>
1705 </modify-argument>
1714 </modify-function>
1706 </modify-function>
1715 <inject-code>
1707 <inject-code>
1716 <insert-template name="gui.init_style_option">
1708 <insert-template name="gui.init_style_option">
1717 <replace from="%TYPE" to="QStyleOption"/>
1709 <replace from="%TYPE" to="QStyleOption"/>
1718 </insert-template>
1710 </insert-template>
1719 </inject-code>
1711 </inject-code>
1720 </object-type>
1712 </object-type>
1721 <object-type name="QFontComboBox"/>
1713 <object-type name="QFontComboBox"/>
1722 <object-type name="QFontDialog">
1714 <object-type name="QFontDialog">
1723 <inject-code class="native" position="beginning">
1715 <inject-code class="native" position="beginning">
1724 Q_DECLARE_METATYPE(QScriptValue)
1716 Q_DECLARE_METATYPE(QScriptValue)
1725 </inject-code>
1717 </inject-code>
1726 <modify-function signature="getFont(bool*,QWidget*)">
1718 <modify-function signature="getFont(bool*,QWidget*)">
1727 <modify-argument index="1">
1719 <modify-argument index="1">
1728 <remove-argument/>
1720 <remove-argument/>
1729 <conversion-rule class="native">
1721 <conversion-rule class="native">
1730 <insert-template name="core.prepare_removed_bool*_argument"/>
1722 <insert-template name="core.prepare_removed_bool*_argument"/>
1731 </conversion-rule>
1723 </conversion-rule>
1732 </modify-argument>
1724 </modify-argument>
1733 <modify-argument index="return">
1725 <modify-argument index="return">
1734 <conversion-rule class="native">
1726 <conversion-rule class="native">
1735 <insert-template name="core.convert_to_null_or_wrap"/>
1727 <insert-template name="core.convert_to_null_or_wrap"/>
1736 </conversion-rule>
1728 </conversion-rule>
1737 </modify-argument>
1729 </modify-argument>
1738 </modify-function>
1730 </modify-function>
1739
1731
1740 <modify-function signature="getFont(bool*,QFont,QWidget*)">
1732 <modify-function signature="getFont(bool*,QFont,QWidget*)">
1741 <modify-argument index="1">
1733 <modify-argument index="1">
1742 <remove-argument/>
1734 <remove-argument/>
1743 <conversion-rule class="native">
1735 <conversion-rule class="native">
1744 <insert-template name="core.prepare_removed_bool*_argument"/>
1736 <insert-template name="core.prepare_removed_bool*_argument"/>
1745 </conversion-rule>
1737 </conversion-rule>
1746 </modify-argument>
1738 </modify-argument>
1747 <modify-argument index="return">
1739 <modify-argument index="return">
1748 <conversion-rule class="native">
1740 <conversion-rule class="native">
1749 <insert-template name="core.convert_to_null_or_wrap"/>
1741 <insert-template name="core.convert_to_null_or_wrap"/>
1750 </conversion-rule>
1742 </conversion-rule>
1751 </modify-argument>
1743 </modify-argument>
1752 </modify-function>
1744 </modify-function>
1753
1745
1754 <modify-function signature="getFont(bool*,QFont,QWidget*,QString)">
1746 <modify-function signature="getFont(bool*,QFont,QWidget*,QString)">
1755 <modify-argument index="1">
1747 <modify-argument index="1">
1756 <remove-argument/>
1748 <remove-argument/>
1757 <conversion-rule class="native">
1749 <conversion-rule class="native">
1758 <insert-template name="core.prepare_removed_bool*_argument"/>
1750 <insert-template name="core.prepare_removed_bool*_argument"/>
1759 </conversion-rule>
1751 </conversion-rule>
1760 </modify-argument>
1752 </modify-argument>
1761 <modify-argument index="return">
1753 <modify-argument index="return">
1762 <conversion-rule class="native">
1754 <conversion-rule class="native">
1763 <insert-template name="core.convert_to_null_or_wrap"/>
1755 <insert-template name="core.convert_to_null_or_wrap"/>
1764 </conversion-rule>
1756 </conversion-rule>
1765 </modify-argument>
1757 </modify-argument>
1766 </modify-function>
1758 </modify-function>
1767 </object-type>
1759 </object-type>
1768
1760
1769 <object-type name="QGraphicsEllipseItem" delete-in-main-thread="yes"/>
1761 <object-type name="QGraphicsEllipseItem" delete-in-main-thread="yes"/>
1770 <object-type name="QGraphicsItemAnimation">
1762 <object-type name="QGraphicsItemAnimation">
1771 <modify-function signature="setItem(QGraphicsItem*)">
1763 <modify-function signature="setItem(QGraphicsItem*)">
1772 <modify-argument index="1">
1764 <modify-argument index="1">
1773 <reference-count action="set" variable-name="__rcItem"/>
1765 <reference-count action="set" variable-name="__rcItem"/>
1774 </modify-argument>
1766 </modify-argument>
1775 </modify-function>
1767 </modify-function>
1776 <modify-function signature="setTimeLine(QTimeLine*)">
1768 <modify-function signature="setTimeLine(QTimeLine*)">
1777 <modify-argument index="1">
1769 <modify-argument index="1">
1778 <reference-count action="set" variable-name="__rcTimeLine"/>
1770 <reference-count action="set" variable-name="__rcTimeLine"/>
1779 </modify-argument>
1771 </modify-argument>
1780 </modify-function>
1772 </modify-function>
1781
1773
1782 <extra-includes>
1774 <extra-includes>
1783 <include file-name="QPair" location="global"/>
1775 <include file-name="QPair" location="global"/>
1784 </extra-includes>
1776 </extra-includes>
1785 </object-type>
1777 </object-type>
1786 <object-type name="QGraphicsItemGroup" delete-in-main-thread="yes">
1778 <object-type name="QGraphicsItemGroup" delete-in-main-thread="yes">
1787 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1779 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1788 <modify-function signature="resetMatrix()" remove="all"/> <!--### Obsolete in 4.3-->
1780 <modify-function signature="resetMatrix()" remove="all"/> <!--### Obsolete in 4.3-->
1789 <modify-function signature="sceneMatrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1781 <modify-function signature="sceneMatrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1790 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
1782 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
1791 </object-type>
1783 </object-type>
1792 <object-type name="QGraphicsLineItem" delete-in-main-thread="yes">
1784 <object-type name="QGraphicsLineItem" delete-in-main-thread="yes">
1793 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1785 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1794 <modify-function signature="resetMatrix()" remove="all"/> <!--### Obsolete in 4.3-->
1786 <modify-function signature="resetMatrix()" remove="all"/> <!--### Obsolete in 4.3-->
1795 <modify-function signature="sceneMatrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1787 <modify-function signature="sceneMatrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1796 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
1788 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
1797 </object-type>
1789 </object-type>
1798 <object-type name="QGraphicsPathItem" delete-in-main-thread="yes"/>
1790 <object-type name="QGraphicsPathItem" delete-in-main-thread="yes"/>
1799
1791
1800 <object-type name="QGraphicsPixmapItem" delete-in-main-thread="yes">
1792 <object-type name="QGraphicsPixmapItem" delete-in-main-thread="yes">
1801 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1793 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1802 <modify-function signature="resetMatrix()" remove="all"/> <!--### Obsolete in 4.3-->
1794 <modify-function signature="resetMatrix()" remove="all"/> <!--### Obsolete in 4.3-->
1803 <modify-function signature="sceneMatrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1795 <modify-function signature="sceneMatrix()const" remove="all"/> <!--### Obsolete in 4.3-->
1804 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
1796 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
1805 </object-type>
1797 </object-type>
1806 <object-type name="QGraphicsPolygonItem" delete-in-main-thread="yes"/>
1798 <object-type name="QGraphicsPolygonItem" delete-in-main-thread="yes"/>
1807 <object-type name="QGraphicsRectItem" delete-in-main-thread="yes"/>
1799 <object-type name="QGraphicsRectItem" delete-in-main-thread="yes"/>
1808 <object-type name="QGraphicsSimpleTextItem" delete-in-main-thread="yes"/>
1800 <object-type name="QGraphicsSimpleTextItem" delete-in-main-thread="yes"/>
1809 <object-type name="QHBoxLayout"/>
1801 <object-type name="QHBoxLayout"/>
1810 <object-type name="QHeaderView">
1802 <object-type name="QHeaderView">
1811 <modify-function signature="initStyleOption(QStyleOptionHeader*)const">
1803 <modify-function signature="initStyleOption(QStyleOptionHeader*)const">
1812 <access modifier="private"/>
1804 <access modifier="private"/>
1813 </modify-function>
1805 </modify-function>
1814
1806
1815 <modify-function signature="paintSection(QPainter*,QRect,int)const">
1807 <modify-function signature="paintSection(QPainter*,QRect,int)const">
1816 <modify-argument index="1" invalidate-after-use="yes"/>
1808 <modify-argument index="1" invalidate-after-use="yes"/>
1817 </modify-function>
1809 </modify-function>
1818
1810
1819 <inject-code>
1811 <inject-code>
1820 <insert-template name="gui.init_style_option">
1812 <insert-template name="gui.init_style_option">
1821 <replace from="%TYPE" to="QStyleOptionHeader"/>
1813 <replace from="%TYPE" to="QStyleOptionHeader"/>
1822 </insert-template>
1814 </insert-template>
1823 </inject-code>
1815 </inject-code>
1824 <modify-function signature="setModel(QAbstractItemModel*)">
1816 <modify-function signature="setModel(QAbstractItemModel*)">
1825 <modify-argument index="1">
1817 <modify-argument index="1">
1826 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcModel"/>
1818 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcModel"/>
1827 </modify-argument>
1819 </modify-argument>
1828 </modify-function>
1820 </modify-function>
1829 </object-type>
1821 </object-type>
1830 <rejection class="QIconEngineV2"/>
1822 <rejection class="QIconEngineV2"/>
1831 <object-type name="QIconEngine">
1823 <object-type name="QIconEngine">
1832 <!-- modify-function signature="read(QDataStream&amp;)">
1824 <!-- modify-function signature="read(QDataStream&amp;)">
1833 <modify-argument index="1">
1825 <modify-argument index="1">
1834 <replace-type modified-type="QDataStream*"/>
1826 <replace-type modified-type="QDataStream*"/>
1835 <conversion-rule class="native">
1827 <conversion-rule class="native">
1836 QDataStream &amp; %out% = *qscriptvalue_cast&lt;QDataStream*&gt;(%in%);
1828 QDataStream &amp; %out% = *qscriptvalue_cast&lt;QDataStream*&gt;(%in%);
1837 </conversion-rule>
1829 </conversion-rule>
1838 </modify-argument>
1830 </modify-argument>
1839 </modify-function>
1831 </modify-function>
1840 <modify-function signature="write(QDataStream&amp;)const">
1832 <modify-function signature="write(QDataStream&amp;)const">
1841 <modify-argument index="1">
1833 <modify-argument index="1">
1842 <replace-type modified-type="QDataStream*"/>
1834 <replace-type modified-type="QDataStream*"/>
1843 <conversion-rule class="native">
1835 <conversion-rule class="native">
1844 QDataStream &amp; %out% = *qscriptvalue_cast&lt;QDataStream*&gt;(%in%);
1836 QDataStream &amp; %out% = *qscriptvalue_cast&lt;QDataStream*&gt;(%in%);
1845 </conversion-rule>
1837 </conversion-rule>
1846 </modify-argument>
1838 </modify-argument>
1847 </modify-function -->
1839 </modify-function -->
1848
1840
1849 <modify-function signature="virtual_hook(int,void*)" remove="all"/>
1841 <modify-function signature="virtual_hook(int,void*)" remove="all"/>
1850 <modify-function signature="clone()const">
1842 <modify-function signature="clone()const">
1851 <modify-argument index="return">
1843 <modify-argument index="return">
1852 <define-ownership class="shell" owner="c++"/>
1844 <define-ownership class="shell" owner="c++"/>
1853 </modify-argument>
1845 </modify-argument>
1854 </modify-function>
1846 </modify-function>
1855
1847
1856 <modify-function signature="read(QDataStream&amp;)">
1848 <modify-function signature="read(QDataStream&amp;)">
1857 <modify-argument index="1">
1849 <modify-argument index="1">
1858 <replace-type modified-type="QDataStream*"/>
1850 <replace-type modified-type="QDataStream*"/>
1859 <conversion-rule class="native">
1851 <conversion-rule class="native">
1860 QDataStream &amp; %out% = *qscriptvalue_cast&lt;QDataStream*&gt;(%in%);
1852 QDataStream &amp; %out% = *qscriptvalue_cast&lt;QDataStream*&gt;(%in%);
1861 </conversion-rule>
1853 </conversion-rule>
1862 <conversion-rule class="shell">
1854 <conversion-rule class="shell">
1863 jobject %out = qtjambi_from_object(__jni_env, %in, "QImage", "com/trolltech/qt/gui/", false);
1855 jobject %out = qtjambi_from_object(__jni_env, %in, "QImage", "com/trolltech/qt/gui/", false);
1864 QtJambiLink *__link = %out != 0 ? QtJambiLink::findLink(__jni_env, %out) : 0;
1856 QtJambiLink *__link = %out != 0 ? QtJambiLink::findLink(__jni_env, %out) : 0;
1865 </conversion-rule>
1857 </conversion-rule>
1866 </modify-argument>
1858 </modify-argument>
1867 </modify-function>
1859 </modify-function>
1868 <modify-function signature="write(QDataStream&amp;)const">
1860 <modify-function signature="write(QDataStream&amp;)const">
1869 <modify-argument index="1">
1861 <modify-argument index="1">
1870 <replace-type modified-type="QDataStream*"/>
1862 <replace-type modified-type="QDataStream*"/>
1871 <conversion-rule class="native">
1863 <conversion-rule class="native">
1872 QDataStream &amp; %out% = *qscriptvalue_cast&lt;QDataStream*&gt;(%in%);
1864 QDataStream &amp; %out% = *qscriptvalue_cast&lt;QDataStream*&gt;(%in%);
1873 </conversion-rule>
1865 </conversion-rule>
1874 </modify-argument>
1866 </modify-argument>
1875 </modify-function>
1867 </modify-function>
1876 </object-type>
1868 </object-type>
1877 <object-type name="QImageWriter">
1869 <object-type name="QImageWriter">
1878 <modify-function signature="setDevice(QIODevice*)">
1870 <modify-function signature="setDevice(QIODevice*)">
1879 <modify-argument index="1">
1871 <modify-argument index="1">
1880 <reference-count action="set" variable-name="__rcDevice"/>
1872 <reference-count action="set" variable-name="__rcDevice"/>
1881 </modify-argument>
1873 </modify-argument>
1882 </modify-function>
1874 </modify-function>
1883 <modify-function signature="description()const" remove="all"/> <!--### Obsolete in 4.3-->
1875 <modify-function signature="description()const" remove="all"/> <!--### Obsolete in 4.3-->
1884 <modify-function signature="setDescription(QString)" remove="all"/> <!--### Obsolete in 4.3-->
1876 <modify-function signature="setDescription(QString)" remove="all"/> <!--### Obsolete in 4.3-->
1885 </object-type>
1877 </object-type>
1886 <object-type name="QInputContextFactory"/>
1878 <object-type name="QInputContextFactory"/>
1887 <object-type name="QIntValidator"/>
1879 <object-type name="QIntValidator"/>
1888 <object-type name="QItemDelegate">
1880 <object-type name="QItemDelegate">
1889 <modify-function signature="doLayout(QStyleOptionViewItem,QRect*,QRect*,QRect*,bool)const">
1881 <modify-function signature="doLayout(QStyleOptionViewItem,QRect*,QRect*,QRect*,bool)const">
1890 <remove/>
1882 <remove/>
1891 </modify-function>
1883 </modify-function>
1892
1884
1893 <modify-function signature="drawCheck(QPainter*,QStyleOptionViewItem,QRect,Qt::CheckState)const">
1885 <modify-function signature="drawCheck(QPainter*,QStyleOptionViewItem,QRect,Qt::CheckState)const">
1894 <modify-argument index="1" invalidate-after-use="yes"/>
1886 <modify-argument index="1" invalidate-after-use="yes"/>
1895 </modify-function>
1887 </modify-function>
1896 <modify-function signature="drawDecoration(QPainter*,QStyleOptionViewItem,QRect,QPixmap)const">
1888 <modify-function signature="drawDecoration(QPainter*,QStyleOptionViewItem,QRect,QPixmap)const">
1897 <modify-argument index="1" invalidate-after-use="yes"/>
1889 <modify-argument index="1" invalidate-after-use="yes"/>
1898 </modify-function>
1890 </modify-function>
1899 <modify-function signature="drawDisplay(QPainter*,QStyleOptionViewItem,QRect,QString)const">
1891 <modify-function signature="drawDisplay(QPainter*,QStyleOptionViewItem,QRect,QString)const">
1900 <modify-argument index="1" invalidate-after-use="yes"/>
1892 <modify-argument index="1" invalidate-after-use="yes"/>
1901 </modify-function>
1893 </modify-function>
1902 <modify-function signature="drawFocus(QPainter*,QStyleOptionViewItem,QRect)const">
1894 <modify-function signature="drawFocus(QPainter*,QStyleOptionViewItem,QRect)const">
1903 <modify-argument index="1" invalidate-after-use="yes"/>
1895 <modify-argument index="1" invalidate-after-use="yes"/>
1904 </modify-function>
1896 </modify-function>
1905
1897
1906
1898
1907 <modify-function signature="selected(QPixmap,QPalette,bool)const">
1899 <modify-function signature="selected(QPixmap,QPalette,bool)const">
1908 <remove/>
1900 <remove/>
1909 </modify-function>
1901 </modify-function>
1910 <modify-function signature="setItemEditorFactory(QItemEditorFactory*)">
1902 <modify-function signature="setItemEditorFactory(QItemEditorFactory*)">
1911 <modify-argument index="1">
1903 <modify-argument index="1">
1912 <reference-count action="set" variable-name="__rcItemEditorFactory"/>
1904 <reference-count action="set" variable-name="__rcItemEditorFactory"/>
1913 </modify-argument>
1905 </modify-argument>
1914 </modify-function>
1906 </modify-function>
1915 <modify-function signature="setEditorData(QWidget*,QModelIndex)const">
1907 <modify-function signature="setEditorData(QWidget*,QModelIndex)const">
1916 <modify-argument index="1">
1908 <modify-argument index="1">
1917 <reference-count action="ignore"/>
1909 <reference-count action="ignore"/>
1918 </modify-argument>
1910 </modify-argument>
1919 </modify-function>
1911 </modify-function>
1920 <modify-function signature="setModelData(QWidget*,QAbstractItemModel*,QModelIndex)const">
1912 <modify-function signature="setModelData(QWidget*,QAbstractItemModel*,QModelIndex)const">
1921 <modify-argument index="1">
1913 <modify-argument index="1">
1922 <reference-count action="ignore"/>
1914 <reference-count action="ignore"/>
1923 </modify-argument>
1915 </modify-argument>
1924 </modify-function>
1916 </modify-function>
1925
1917
1926 </object-type>
1918 </object-type>
1927 <object-type name="QItemEditorCreatorBase"/>
1919 <object-type name="QItemEditorCreatorBase"/>
1928 <object-type name="QItemEditorFactory">
1920 <object-type name="QItemEditorFactory">
1929 <modify-function signature="registerEditor(QVariant::Type, QItemEditorCreatorBase *)">
1921 <modify-function signature="registerEditor(QVariant::Type, QItemEditorCreatorBase *)">
1930 <modify-argument index="2">
1922 <modify-argument index="2">
1931 <define-ownership class="java" owner="c++"/>
1923 <define-ownership class="java" owner="c++"/>
1932 </modify-argument>
1924 </modify-argument>
1933 </modify-function>
1925 </modify-function>
1934 <modify-function signature="setDefaultFactory(QItemEditorFactory *)">
1926 <modify-function signature="setDefaultFactory(QItemEditorFactory *)">
1935 <modify-argument index="1">
1927 <modify-argument index="1">
1936 <reference-count action="set" variable-name="__rcDefaultItemEditorFactory"/>
1928 <reference-count action="set" variable-name="__rcDefaultItemEditorFactory"/>
1937 </modify-argument>
1929 </modify-argument>
1938 </modify-function>
1930 </modify-function>
1939 </object-type>
1931 </object-type>
1940 <object-type name="QItemSelectionModel"/>
1932 <object-type name="QItemSelectionModel"/>
1941 <object-type name="QTreeModel"/>
1933 <object-type name="QTreeModel"/>
1942 <object-type name="QListView"/>
1934 <object-type name="QListView"/>
1943 <object-type name="QColumnView">
1935 <object-type name="QColumnView">
1944 <modify-function signature="setPreviewWidget(QWidget*)">
1936 <modify-function signature="setPreviewWidget(QWidget*)">
1945 <modify-argument index="1">
1937 <modify-argument index="1">
1946 <reference-count action="ignore"/>
1938 <reference-count action="ignore"/>
1947 </modify-argument>
1939 </modify-argument>
1948 </modify-function>
1940 </modify-function>
1949 <modify-function signature="setModel(QAbstractItemModel*)">
1941 <modify-function signature="setModel(QAbstractItemModel*)">
1950 <modify-argument index="1">
1942 <modify-argument index="1">
1951 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemModel"/>
1943 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemModel"/>
1952 </modify-argument>
1944 </modify-argument>
1953 </modify-function>
1945 </modify-function>
1954 <modify-function signature="setSelectionModel(QItemSelectionModel*)">
1946 <modify-function signature="setSelectionModel(QItemSelectionModel*)">
1955 <modify-argument index="1">
1947 <modify-argument index="1">
1956 <no-null-pointer/>
1948 <no-null-pointer/>
1957 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemSelectionModel"/>
1949 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemSelectionModel"/>
1958 </modify-argument>
1950 </modify-argument>
1959 </modify-function>
1951 </modify-function>
1960 </object-type>
1952 </object-type>
1961 <object-type name="QMainWindow">
1953 <object-type name="QMainWindow">
1962 <modify-function signature="addDockWidget(Qt::DockWidgetArea,QDockWidget*,Qt::Orientation)">
1954 <modify-function signature="addDockWidget(Qt::DockWidgetArea,QDockWidget*,Qt::Orientation)">
1963 <modify-argument index="2">
1955 <modify-argument index="2">
1964 <reference-count action="ignore"/>
1956 <reference-count action="ignore"/>
1965 </modify-argument>
1957 </modify-argument>
1966 </modify-function>
1958 </modify-function>
1967 <modify-function signature="addDockWidget(Qt::DockWidgetArea,QDockWidget*)">
1959 <modify-function signature="addDockWidget(Qt::DockWidgetArea,QDockWidget*)">
1968 <modify-argument index="2">
1960 <modify-argument index="2">
1969 <reference-count action="ignore"/>
1961 <reference-count action="ignore"/>
1970 </modify-argument>
1962 </modify-argument>
1971 </modify-function>
1963 </modify-function>
1972 <modify-function signature="addToolBar(QToolBar*)">
1964 <modify-function signature="addToolBar(QToolBar*)">
1973 <modify-argument index="1">
1965 <modify-argument index="1">
1974 <reference-count action="ignore"/>
1966 <reference-count action="ignore"/>
1975 </modify-argument>
1967 </modify-argument>
1976 </modify-function>
1968 </modify-function>
1977 <modify-function signature="addToolBar(Qt::ToolBarArea,QToolBar*)">
1969 <modify-function signature="addToolBar(Qt::ToolBarArea,QToolBar*)">
1978 <modify-argument index="2">
1970 <modify-argument index="2">
1979 <reference-count action="ignore"/>
1971 <reference-count action="ignore"/>
1980 </modify-argument>
1972 </modify-argument>
1981 </modify-function>
1973 </modify-function>
1982 <modify-function signature="insertToolBar(QToolBar*,QToolBar*)">
1974 <modify-function signature="insertToolBar(QToolBar*,QToolBar*)">
1983 <modify-argument index="2">
1975 <modify-argument index="2">
1984 <reference-count action="ignore"/>
1976 <reference-count action="ignore"/>
1985 </modify-argument>
1977 </modify-argument>
1986 <modify-argument index="2">
1978 <modify-argument index="2">
1987 <reference-count action="ignore"/>
1979 <reference-count action="ignore"/>
1988 </modify-argument>
1980 </modify-argument>
1989 </modify-function>
1981 </modify-function>
1990 <modify-function signature="insertToolBarBreak(QToolBar*)">
1982 <modify-function signature="insertToolBarBreak(QToolBar*)">
1991 <modify-argument index="1">
1983 <modify-argument index="1">
1992 <reference-count action="ignore"/>
1984 <reference-count action="ignore"/>
1993 </modify-argument>
1985 </modify-argument>
1994 </modify-function>
1986 </modify-function>
1995 <modify-function signature="removeDockWidget(QDockWidget*)">
1987 <modify-function signature="removeDockWidget(QDockWidget*)">
1996 <modify-argument index="1">
1988 <modify-argument index="1">
1997 <reference-count action="ignore"/>
1989 <reference-count action="ignore"/>
1998 </modify-argument>
1990 </modify-argument>
1999 </modify-function>
1991 </modify-function>
2000 <modify-function signature="removeToolBar(QToolBar*)">
1992 <modify-function signature="removeToolBar(QToolBar*)">
2001 <modify-argument index="1">
1993 <modify-argument index="1">
2002 <reference-count action="ignore"/>
1994 <reference-count action="ignore"/>
2003 </modify-argument>
1995 </modify-argument>
2004 </modify-function>
1996 </modify-function>
2005 <modify-function signature="removeToolBarBreak(QToolBar*)">
1997 <modify-function signature="removeToolBarBreak(QToolBar*)">
2006 <modify-argument index="1">
1998 <modify-argument index="1">
2007 <reference-count action="ignore"/>
1999 <reference-count action="ignore"/>
2008 </modify-argument>
2000 </modify-argument>
2009 </modify-function>
2001 </modify-function>
2010 <modify-function signature="setCentralWidget(QWidget*)">
2002 <modify-function signature="setCentralWidget(QWidget*)">
2011 <modify-argument index="1">
2003 <modify-argument index="1">
2012 <reference-count action="ignore"/>
2004 <reference-count action="ignore"/>
2013 </modify-argument>
2005 </modify-argument>
2014 </modify-function>
2006 </modify-function>
2015 <modify-function signature="setMenuBar(QMenuBar*)">
2007 <modify-function signature="setMenuBar(QMenuBar*)">
2016 <modify-argument index="1">
2008 <modify-argument index="1">
2017 <reference-count action="ignore"/>
2009 <reference-count action="ignore"/>
2018 </modify-argument>
2010 </modify-argument>
2019 </modify-function>
2011 </modify-function>
2020 <modify-function signature="setMenuWidget(QWidget*)">
2012 <modify-function signature="setMenuWidget(QWidget*)">
2021 <modify-argument index="1">
2013 <modify-argument index="1">
2022 <reference-count action="ignore"/>
2014 <reference-count action="ignore"/>
2023 </modify-argument>
2015 </modify-argument>
2024 </modify-function>
2016 </modify-function>
2025 <modify-function signature="setStatusBar(QStatusBar*)">
2017 <modify-function signature="setStatusBar(QStatusBar*)">
2026 <modify-argument index="1">
2018 <modify-argument index="1">
2027 <reference-count action="ignore"/>
2019 <reference-count action="ignore"/>
2028 </modify-argument>
2020 </modify-argument>
2029 </modify-function>
2021 </modify-function>
2030
2022
2031 </object-type>
2023 </object-type>
2032 <object-type name="QMdiArea">
2024 <object-type name="QMdiArea">
2033 <modify-function signature="addSubWindow(QWidget*,QFlags&lt;Qt::WindowType&gt;)">
2025 <modify-function signature="addSubWindow(QWidget*,QFlags&lt;Qt::WindowType&gt;)">
2034 <modify-argument index="1">
2026 <modify-argument index="1">
2035 <reference-count action="ignore"/>
2027 <reference-count action="ignore"/>
2036 </modify-argument>
2028 </modify-argument>
2037 </modify-function>
2029 </modify-function>
2038
2030
2039 <modify-function signature="removeSubWindow(QWidget*)">
2031 <modify-function signature="removeSubWindow(QWidget*)">
2040 <modify-argument index="1">
2032 <modify-argument index="1">
2041 <reference-count action="ignore"/>
2033 <reference-count action="ignore"/>
2042 </modify-argument>
2034 </modify-argument>
2043 </modify-function>
2035 </modify-function>
2044
2036
2045 <modify-function signature="setActiveSubWindow(QMdiSubWindow*)">
2037 <modify-function signature="setActiveSubWindow(QMdiSubWindow*)">
2046 <modify-argument index="1">
2038 <modify-argument index="1">
2047 <reference-count action="ignore"/>
2039 <reference-count action="ignore"/>
2048 </modify-argument>
2040 </modify-argument>
2049 </modify-function>
2041 </modify-function>
2050
2042
2051 <modify-function signature="setupViewport(QWidget*)">
2043 <modify-function signature="setupViewport(QWidget*)">
2052 <modify-argument index="1">
2044 <modify-argument index="1">
2053 <reference-count action="ignore"/>
2045 <reference-count action="ignore"/>
2054 </modify-argument>
2046 </modify-argument>
2055 </modify-function>
2047 </modify-function>
2056
2048
2057 </object-type>
2049 </object-type>
2058 <object-type name="QMdiSubWindow">
2050 <object-type name="QMdiSubWindow">
2059 <modify-function signature="setSystemMenu(QMenu*)">
2051 <modify-function signature="setSystemMenu(QMenu*)">
2060 <modify-argument index="1">
2052 <modify-argument index="1">
2061 <reference-count action="ignore"/>
2053 <reference-count action="ignore"/>
2062 </modify-argument>
2054 </modify-argument>
2063 </modify-function>
2055 </modify-function>
2064 <modify-function signature="setWidget(QWidget*)">
2056 <modify-function signature="setWidget(QWidget*)">
2065 <modify-argument index="1">
2057 <modify-argument index="1">
2066 <reference-count action="ignore"/>
2058 <reference-count action="ignore"/>
2067 </modify-argument>
2059 </modify-argument>
2068 </modify-function>
2060 </modify-function>
2069 </object-type>
2061 </object-type>
2070 <object-type name="QMenu">
2062 <object-type name="QMenu">
2071 <modify-function signature="addAction(QAction *)" remove="all"/>
2063 <modify-function signature="addAction(QAction *)" remove="all"/>
2072 <modify-function signature="addMenu(QMenu*)">
2064 <modify-function signature="addMenu(QMenu*)">
2073 <modify-argument index="1">
2065 <modify-argument index="1">
2074 <reference-count action="add" variable-name="__rcMenus"/>
2066 <reference-count action="add" variable-name="__rcMenus"/>
2075 </modify-argument>
2067 </modify-argument>
2076 </modify-function>
2068 </modify-function>
2077 <modify-function signature="insertMenu(QAction*,QMenu*)">
2069 <modify-function signature="insertMenu(QAction*,QMenu*)">
2078 <modify-argument index="2">
2070 <modify-argument index="2">
2079 <reference-count action="add" variable-name="__rcMenus"/>
2071 <reference-count action="add" variable-name="__rcMenus"/>
2080 </modify-argument>
2072 </modify-argument>
2081 </modify-function>
2073 </modify-function>
2082 <modify-function signature="insertSeparator(QAction*)">
2074 <modify-function signature="insertSeparator(QAction*)">
2083 <modify-argument index="1">
2075 <modify-argument index="1">
2084 <reference-count action="ignore"/>
2076 <reference-count action="ignore"/>
2085 </modify-argument>
2077 </modify-argument>
2086 </modify-function>
2078 </modify-function>
2087 <modify-function signature="setActiveAction(QAction*)">
2079 <modify-function signature="setActiveAction(QAction*)">
2088 <modify-argument index="1">
2080 <modify-argument index="1">
2089 <reference-count action="ignore"/>
2081 <reference-count action="ignore"/>
2090 </modify-argument>
2082 </modify-argument>
2091 </modify-function>
2083 </modify-function>
2092 <modify-function signature="setDefaultAction(QAction*)">
2084 <modify-function signature="setDefaultAction(QAction*)">
2093 <modify-argument index="1">
2085 <modify-argument index="1">
2094 <reference-count action="ignore"/>
2086 <reference-count action="ignore"/>
2095 </modify-argument>
2087 </modify-argument>
2096 </modify-function>
2088 </modify-function>
2097 <modify-function signature="setNoReplayFor(QWidget*)">
2089 <modify-function signature="setNoReplayFor(QWidget*)">
2098 <remove/>
2090 <remove/>
2099 </modify-function>
2091 </modify-function>
2100 <modify-function signature="initStyleOption(QStyleOptionMenuItem*,const QAction*)const">
2092 <modify-function signature="initStyleOption(QStyleOptionMenuItem*,const QAction*)const">
2101 <access modifier="private"/>
2093 <access modifier="private"/>
2102 </modify-function>
2094 </modify-function>
2103
2095
2104 <inject-code class="pywrap-h">
2096 <modify-function signature="addAction(QString,const QObject*,const char*,QKeySequence)">
2105 QAction* addAction (QMenu* menu, const QString &amp; text, PyObject* callable, const QKeySequence &amp; shortcut = 0) {
2097 <remove/>
2106 QAction* a = menu-&gt;addAction(text);
2098 </modify-function>
2107 a-&gt;setShortcut(shortcut);
2108 PythonQt::self()-&gt;addSignalHandler(a, SIGNAL(triggered(bool)), callable);
2109 return a;
2110 }
2111
2099
2112 QAction* addAction (QMenu* menu, const QIcon&amp; icon, const QString&amp; text, PyObject* callable, const QKeySequence&amp; shortcut = 0)
2100 <modify-function signature="addAction(QIcon,QString,const QObject*,const char*,QKeySequence)">
2113 {
2101 <remove/>
2114 QAction* a = menu-&gt;addAction(text);
2102 </modify-function>
2115 a-&gt;setIcon(icon);
2103
2116 a-&gt;setShortcut(shortcut);
2104 <inject-code class="pywrap-h">
2117 PythonQt::self()-&gt;addSignalHandler(a, SIGNAL(triggered(bool)), callable);
2105 QAction* addAction (QMenu* menu, const QString &amp; text, PyObject* callable, const QKeySequence &amp; shortcut = 0) {
2118 return a;
2106 QAction* a = menu-&gt;addAction(text);
2119 }
2107 a-&gt;setShortcut(shortcut);
2120 </inject-code>
2108 PythonQt::self()-&gt;addSignalHandler(a, SIGNAL(triggered(bool)), callable);
2109 return a;
2110 }
2111
2112 QAction* addAction (QMenu* menu, const QIcon&amp; icon, const QString&amp; text, PyObject* callable, const QKeySequence&amp; shortcut = 0)
2113 {
2114 QAction* a = menu-&gt;addAction(text);
2115 a-&gt;setIcon(icon);
2116 a-&gt;setShortcut(shortcut);
2117 PythonQt::self()-&gt;addSignalHandler(a, SIGNAL(triggered(bool)), callable);
2118 return a;
2119 }
2120 </inject-code>
2121 </object-type>
2121 </object-type>
2122
2122
2123 <object-type name="QMenuBar">
2123 <object-type name="QMenuBar">
2124 <modify-function signature="addAction(QAction *)" remove="all"/>
2124 <modify-function signature="addAction(QAction *)" remove="all"/>
2125 <modify-function signature="addAction(QString,const QObject*,const char*)">
2125 <modify-function signature="addAction(QString,const QObject*,const char*)">
2126 <remove/>
2126 <remove/>
2127 </modify-function>
2127 </modify-function>
2128
2128
2129 <modify-function signature="initStyleOption(QStyleOptionMenuItem*,const QAction*)const">
2129 <modify-function signature="initStyleOption(QStyleOptionMenuItem*,const QAction*)const">
2130 <access modifier="private"/>
2130 <access modifier="private"/>
2131 </modify-function>
2131 </modify-function>
2132
2132
2133 <modify-function signature="addMenu(QMenu*)">
2133 <modify-function signature="addMenu(QMenu*)">
2134 <modify-argument index="1">
2134 <modify-argument index="1">
2135 <reference-count action="add" variable-name="__rcMenus"/>
2135 <reference-count action="add" variable-name="__rcMenus"/>
2136 </modify-argument>
2136 </modify-argument>
2137 </modify-function>
2137 </modify-function>
2138 <modify-function signature="insertMenu(QAction*,QMenu*)">
2138 <modify-function signature="insertMenu(QAction*,QMenu*)">
2139 <modify-argument index="1">
2139 <modify-argument index="1">
2140 <reference-count action="ignore"/>
2140 <reference-count action="ignore"/>
2141 </modify-argument>
2141 </modify-argument>
2142 <modify-argument index="2">
2142 <modify-argument index="2">
2143 <reference-count action="add" variable-name="__rcMenus"/>
2143 <reference-count action="add" variable-name="__rcMenus"/>
2144 </modify-argument>
2144 </modify-argument>
2145 </modify-function>
2145 </modify-function>
2146 <modify-function signature="insertSeparator(QAction*)">
2146 <modify-function signature="insertSeparator(QAction*)">
2147 <modify-argument index="1">
2147 <modify-argument index="1">
2148 <reference-count action="ignore"/>
2148 <reference-count action="ignore"/>
2149 </modify-argument>
2149 </modify-argument>
2150 </modify-function>
2150 </modify-function>
2151 <modify-function signature="setActiveAction(QAction*)">
2151 <modify-function signature="setActiveAction(QAction*)">
2152 <modify-argument index="1">
2152 <modify-argument index="1">
2153 <reference-count action="ignore"/>
2153 <reference-count action="ignore"/>
2154 </modify-argument>
2154 </modify-argument>
2155 </modify-function>
2155 </modify-function>
2156 <modify-function signature="setCornerWidget(QWidget*,Qt::Corner) ">
2156 <modify-function signature="setCornerWidget(QWidget*,Qt::Corner) ">
2157 <modify-argument index="1">
2157 <modify-argument index="1">
2158 <reference-count action="ignore"/>
2158 <reference-count action="ignore"/>
2159 </modify-argument>
2159 </modify-argument>
2160 </modify-function>
2160 </modify-function>
2161 <inject-code class="pywrap-h">
2161
2162 QAction* addAction (QMenuBar* menu, const QString &amp; text, PyObject* callable)
2162 <inject-code class="pywrap-h">
2163 {
2163 QAction* addAction (QMenuBar* menu, const QString &amp; text, PyObject* callable)
2164 QAction* a = menu-&gt;addAction(text);
2164 {
2165 PythonQt::self()-&gt;addSignalHandler(a, SIGNAL(triggered(bool)), callable);
2165 QAction* a = menu-&gt;addAction(text);
2166 return a;
2166 PythonQt::self()-&gt;addSignalHandler(a, SIGNAL(triggered(bool)), callable);
2167 }
2167 return a;
2168 </inject-code>
2168 }
2169 </inject-code>
2169 </object-type>
2170 </object-type>
2170 <object-type name="QMotifStyle">
2171 <object-type name="QMotifStyle">
2171 <modify-function signature="standardPixmap(QStyle::StandardPixmap, const QStyleOption*, const QWidget*)const" remove="all"/> <!--### Obsolete in 4.3-->
2172 <modify-function signature="standardPixmap(QStyle::StandardPixmap, const QStyleOption*, const QWidget*)const" remove="all"/> <!--### Obsolete in 4.3-->
2172 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
2173 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
2173 </object-type>
2174 </object-type>
2174 <object-type name="QPainterPathStroker"/>
2175 <object-type name="QPainterPathStroker"/>
2175
2176
2176 <object-type name="QPictureIO">
2177 <object-type name="QPictureIO">
2177 <modify-function signature="QPictureIO(QIODevice*,const char*)">
2178 <modify-function signature="QPictureIO(QIODevice*,const char*)">
2178 <access modifier="private"/>
2179 <access modifier="private"/>
2179 <modify-argument index="1">
2180 <modify-argument index="1">
2180 <reference-count action="set" variable-name="__rcDevice"/>
2181 <reference-count action="set" variable-name="__rcDevice"/>
2181 </modify-argument>
2182 </modify-argument>
2182 </modify-function>
2183 </modify-function>
2183
2184
2184 <modify-function signature="setIODevice(QIODevice*)">
2185 <modify-function signature="setIODevice(QIODevice*)">
2185 <modify-argument index="1">
2186 <modify-argument index="1">
2186 <reference-count action="set" variable-name="__rcDevice"/>
2187 <reference-count action="set" variable-name="__rcDevice"/>
2187 </modify-argument>
2188 </modify-argument>
2188 </modify-function>
2189 </modify-function>
2189
2190
2190 <modify-function signature="QPictureIO(QString,const char*)">
2191 <modify-function signature="QPictureIO(QString,const char*)">
2191 <access modifier="private"/>
2192 <access modifier="private"/>
2192 </modify-function>
2193 </modify-function>
2193
2194
2194 <modify-function signature="format()const">
2195 <modify-function signature="format()const">
2195 <access modifier="private"/>
2196 <access modifier="private"/>
2196 <rename to="format_private"/>
2197 <rename to="format_private"/>
2197 </modify-function>
2198 </modify-function>
2198
2199
2199 <modify-function signature="parameters()const">
2200 <modify-function signature="parameters()const">
2200 <access modifier="private"/>
2201 <access modifier="private"/>
2201 <rename to="parameters_private"/>
2202 <rename to="parameters_private"/>
2202 </modify-function>
2203 </modify-function>
2203
2204
2204 <modify-function signature="setFormat(const char*)">
2205 <modify-function signature="setFormat(const char*)">
2205 <access modifier="private"/>
2206 <access modifier="private"/>
2206 </modify-function>
2207 </modify-function>
2207
2208
2208 <modify-function signature="setParameters(const char*)">
2209 <modify-function signature="setParameters(const char*)">
2209 <access modifier="private"/>
2210 <access modifier="private"/>
2210 </modify-function>
2211 </modify-function>
2211
2212
2212
2213
2213 <modify-function signature="QPictureIO(QIODevice*,const char*)">
2214 <modify-function signature="QPictureIO(QIODevice*,const char*)">
2214 <modify-argument index="2">
2215 <modify-argument index="2">
2215 <replace-type modified-type="QString"/>
2216 <replace-type modified-type="QString"/>
2216 <conversion-rule class="native">
2217 <conversion-rule class="native">
2217 <insert-template name="core.convert_string_arg_to_char*"/>
2218 <insert-template name="core.convert_string_arg_to_char*"/>
2218 </conversion-rule>
2219 </conversion-rule>
2219 </modify-argument>
2220 </modify-argument>
2220 </modify-function>
2221 </modify-function>
2221
2222
2222 <modify-function signature="QPictureIO(QString,const char*)">
2223 <modify-function signature="QPictureIO(QString,const char*)">
2223 <modify-argument index="2">
2224 <modify-argument index="2">
2224 <replace-type modified-type="QString"/>
2225 <replace-type modified-type="QString"/>
2225 <conversion-rule class="native">
2226 <conversion-rule class="native">
2226 <insert-template name="core.convert_string_arg_to_char*"/>
2227 <insert-template name="core.convert_string_arg_to_char*"/>
2227 </conversion-rule>
2228 </conversion-rule>
2228 </modify-argument>
2229 </modify-argument>
2229 </modify-function>
2230 </modify-function>
2230
2231
2231 <modify-function signature="setFormat(const char*)">
2232 <modify-function signature="setFormat(const char*)">
2232 <modify-argument index="1">
2233 <modify-argument index="1">
2233 <replace-type modified-type="QString"/>
2234 <replace-type modified-type="QString"/>
2234 <conversion-rule class="native">
2235 <conversion-rule class="native">
2235 <insert-template name="core.convert_string_arg_to_char*"/>
2236 <insert-template name="core.convert_string_arg_to_char*"/>
2236 </conversion-rule>
2237 </conversion-rule>
2237 </modify-argument>
2238 </modify-argument>
2238 </modify-function>
2239 </modify-function>
2239
2240
2240 <modify-function signature="setParameters(const char*)">
2241 <modify-function signature="setParameters(const char*)">
2241 <modify-argument index="1">
2242 <modify-argument index="1">
2242 <replace-type modified-type="QString"/>
2243 <replace-type modified-type="QString"/>
2243 <conversion-rule class="native">
2244 <conversion-rule class="native">
2244 <insert-template name="core.convert_string_arg_to_char*"/>
2245 <insert-template name="core.convert_string_arg_to_char*"/>
2245 </conversion-rule>
2246 </conversion-rule>
2246 </modify-argument>
2247 </modify-argument>
2247 </modify-function>
2248 </modify-function>
2248 </object-type>
2249 </object-type>
2249
2250
2250 <object-type name="QPixmapCache">
2251 <object-type name="QPixmapCache">
2251 <modify-function signature="find(QString)">
2252 <modify-function signature="find(QString)">
2252 <remove/>
2253 <remove/>
2253 </modify-function>
2254 </modify-function>
2254 <modify-function signature="find(QString,QPixmap*)" remove="all"/>
2255 <modify-function signature="find(QString,QPixmap*)" remove="all"/>
2255
2256
2256 <modify-function signature="find(QString,QPixmap&amp;)">
2257 <modify-function signature="find(QString,QPixmap&amp;)">
2257 <access modifier="private"/>
2258 <access modifier="private"/>
2258 </modify-function>
2259 </modify-function>
2259 </object-type>
2260 </object-type>
2260 <object-type name="QPlastiqueStyle">
2261 <object-type name="QPlastiqueStyle">
2261 <modify-function signature="standardPixmap(QStyle::StandardPixmap, const QStyleOption*, const QWidget*)const" remove="all"/> <!--### Obsolete in 4.3-->
2262 <modify-function signature="standardPixmap(QStyle::StandardPixmap, const QStyleOption*, const QWidget*)const" remove="all"/> <!--### Obsolete in 4.3-->
2262 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
2263 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
2263 <modify-function signature="layoutSpacingImplementation(QSizePolicy::ControlType, QSizePolicy::ControlType, Qt::Orientation, const QStyleOption *, const QWidget *) const" virtual-slot="yes"/>
2264 <modify-function signature="layoutSpacingImplementation(QSizePolicy::ControlType, QSizePolicy::ControlType, Qt::Orientation, const QStyleOption *, const QWidget *) const" virtual-slot="yes"/>
2264 </object-type>
2265 </object-type>
2265 <object-type name="QPrintDialog">
2266 <object-type name="QPrintDialog">
2266 </object-type>
2267 </object-type>
2267 <object-type name="QPrintEngine"/>
2268 <object-type name="QPrintEngine"/>
2268 <object-type name="QProgressBar">
2269 <object-type name="QProgressBar">
2269 <modify-function signature="initStyleOption(QStyleOptionProgressBar*)const">
2270 <modify-function signature="initStyleOption(QStyleOptionProgressBar*)const">
2270 <access modifier="private"/>
2271 <access modifier="private"/>
2271 </modify-function>
2272 </modify-function>
2272 </object-type>
2273 </object-type>
2273 <object-type name="QPushButton">
2274 <object-type name="QPushButton">
2274 <modify-function signature="initStyleOption(QStyleOptionButton*)const">
2275 <modify-function signature="initStyleOption(QStyleOptionButton*)const">
2275 <access modifier="private"/>
2276 <access modifier="private"/>
2276 </modify-function>
2277 </modify-function>
2277
2278
2278 <modify-function signature="setMenu(QMenu*)">
2279 <modify-function signature="setMenu(QMenu*)">
2279 <modify-argument index="1">
2280 <modify-argument index="1">
2280 <reference-count action="set" variable-name="__rcMenu"/>
2281 <reference-count action="set" variable-name="__rcMenu"/>
2281 </modify-argument>
2282 </modify-argument>
2282 </modify-function>
2283 </modify-function>
2283 </object-type>
2284 </object-type>
2284 <object-type name="QRegExpValidator"/>
2285 <object-type name="QRegExpValidator"/>
2285 <object-type name="QScrollArea">
2286 <object-type name="QScrollArea">
2286 <modify-function signature="setWidget(QWidget*)">
2287 <modify-function signature="setWidget(QWidget*)">
2287 <modify-argument index="1">
2288 <modify-argument index="1">
2288 <reference-count action="ignore"/>
2289 <reference-count action="ignore"/>
2289 </modify-argument>
2290 </modify-argument>
2290 </modify-function>
2291 </modify-function>
2291 </object-type>
2292 </object-type>
2292 <object-type name="QSessionManager"/>
2293 <object-type name="QSessionManager"/>
2293 <object-type name="QShortcut">
2294 <object-type name="QShortcut">
2294 <modify-function signature="QShortcut(QKeySequence,QWidget*,const char*,const char*,Qt::ShortcutContext)">
2295 <modify-function signature="QShortcut(QKeySequence,QWidget*,const char*,const char*,Qt::ShortcutContext)">
2295 <access modifier="private"/>
2296 <access modifier="private"/>
2296 <modify-argument index="3">
2297 <modify-argument index="3">
2297 <remove-default-expression/>
2298 <remove-default-expression/>
2298 </modify-argument>
2299 </modify-argument>
2299 <modify-argument index="4">
2300 <modify-argument index="4">
2300 <remove-default-expression/>
2301 <remove-default-expression/>
2301 </modify-argument>
2302 </modify-argument>
2302 <modify-argument index="5">
2303 <modify-argument index="5">
2303 <remove-default-expression/>
2304 <remove-default-expression/>
2304 </modify-argument>
2305 </modify-argument>
2305 </modify-function>
2306 </modify-function>
2306 </object-type>
2307 </object-type>
2307 <object-type name="QSizeGrip"/>
2308 <object-type name="QSizeGrip"/>
2308 <object-type name="QSound"/>
2309 <object-type name="QSound"/>
2309 <object-type name="QSpacerItem"/>
2310 <object-type name="QSpacerItem"/>
2310 <object-type name="QStandardItem">
2311 <object-type name="QStandardItem">
2311 <modify-function signature="operator=(QStandardItem)" remove="all"/>
2312 <modify-function signature="operator=(QStandardItem)" remove="all"/>
2312 <modify-function signature="operator&lt;(QStandardItem)const">
2313 <modify-function signature="operator&lt;(QStandardItem)const">
2313 <modify-argument index="1" invalidate-after-use="yes"/>
2314 <modify-argument index="1" invalidate-after-use="yes"/>
2314 </modify-function>
2315 </modify-function>
2315 <modify-function signature="read(QDataStream&amp;)">
2316 <modify-function signature="read(QDataStream&amp;)">
2316 <modify-argument index="1" invalidate-after-use="yes"/>
2317 <modify-argument index="1" invalidate-after-use="yes"/>
2317 </modify-function>
2318 </modify-function>
2318 <modify-function signature="write(QDataStream&amp;)const">
2319 <modify-function signature="write(QDataStream&amp;)const">
2319 <modify-argument index="1" invalidate-after-use="yes"/>
2320 <modify-argument index="1" invalidate-after-use="yes"/>
2320 </modify-function>
2321 </modify-function>
2321
2322
2322
2323
2323 <modify-function signature="read(QDataStream &amp;)" remove="all"/>
2324 <modify-function signature="read(QDataStream &amp;)" remove="all"/>
2324 <modify-function signature="write(QDataStream &amp;)const" remove="all"/>
2325 <modify-function signature="write(QDataStream &amp;)const" remove="all"/>
2325 <modify-function signature="operator=(QStandardItem)" remove="all"/>
2326 <modify-function signature="operator=(QStandardItem)" remove="all"/>
2326 <modify-function signature="operator&lt;(QStandardItem)const" remove="all"/>
2327 <modify-function signature="operator&lt;(QStandardItem)const" remove="all"/>
2327 </object-type>
2328 </object-type>
2328 <object-type name="QStatusBar">
2329 <object-type name="QStatusBar">
2329 <modify-function signature="addPermanentWidget(QWidget *, int)">
2330 <modify-function signature="addPermanentWidget(QWidget *, int)">
2330 <modify-argument index="1">
2331 <modify-argument index="1">
2331 <reference-count action="ignore"/>
2332 <reference-count action="ignore"/>
2332 </modify-argument>
2333 </modify-argument>
2333 </modify-function>
2334 </modify-function>
2334 <modify-function signature="addWidget(QWidget *, int)">
2335 <modify-function signature="addWidget(QWidget *, int)">
2335 <modify-argument index="1">
2336 <modify-argument index="1">
2336 <reference-count action="ignore"/>
2337 <reference-count action="ignore"/>
2337 </modify-argument>
2338 </modify-argument>
2338 </modify-function>
2339 </modify-function>
2339 <modify-function signature="removeWidget(QWidget *)">
2340 <modify-function signature="removeWidget(QWidget *)">
2340 <modify-argument index="1">
2341 <modify-argument index="1">
2341 <reference-count action="ignore"/>
2342 <reference-count action="ignore"/>
2342 </modify-argument>
2343 </modify-argument>
2343 </modify-function>
2344 </modify-function>
2344 <modify-function signature="insertPermanentWidget(int, QWidget *, int)">
2345 <modify-function signature="insertPermanentWidget(int, QWidget *, int)">
2345 <modify-argument index="2">
2346 <modify-argument index="2">
2346 <reference-count action="ignore"/>
2347 <reference-count action="ignore"/>
2347 </modify-argument>
2348 </modify-argument>
2348 </modify-function>
2349 </modify-function>
2349 <modify-function signature="insertWidget(int, QWidget *, int)">
2350 <modify-function signature="insertWidget(int, QWidget *, int)">
2350 <modify-argument index="2">
2351 <modify-argument index="2">
2351 <reference-count action="ignore"/>
2352 <reference-count action="ignore"/>
2352 </modify-argument>
2353 </modify-argument>
2353 </modify-function>
2354 </modify-function>
2354 </object-type>
2355 </object-type>
2355 <object-type name="QStringListModel"/>
2356 <object-type name="QStringListModel"/>
2356 <object-type name="QStyleFactory"/>
2357 <object-type name="QStyleFactory"/>
2357 <object-type name="QStyleHintReturn"/>
2358 <object-type name="QStyleHintReturn"/>
2358 <object-type name="QStyleHintReturnVariant"/>
2359 <object-type name="QStyleHintReturnVariant"/>
2359 <object-type name="QStyleHintReturnMask"/>
2360 <object-type name="QStyleHintReturnMask"/>
2360 <object-type name="QStylePainter" delete-in-main-thread="yes"/>
2361 <object-type name="QStylePainter" delete-in-main-thread="yes"/>
2361 <object-type name="QSyntaxHighlighter">
2362 <object-type name="QSyntaxHighlighter">
2362 <modify-function signature="setCurrentBlockUserData(QTextBlockUserData*)">
2363 <modify-function signature="setCurrentBlockUserData(QTextBlockUserData*)">
2363 <modify-argument index="1">
2364 <modify-argument index="1">
2364 <define-ownership class="java" owner="c++"/>
2365 <define-ownership class="java" owner="c++"/>
2365 </modify-argument>
2366 </modify-argument>
2366 </modify-function>
2367 </modify-function>
2367 <modify-function signature="setDocument(QTextDocument*)">
2368 <modify-function signature="setDocument(QTextDocument*)">
2368 <modify-argument index="1">
2369 <modify-argument index="1">
2369 <reference-count action="set" variable-name="__rcDocument"/>
2370 <reference-count action="set" variable-name="__rcDocument"/>
2370 </modify-argument>
2371 </modify-argument>
2371 </modify-function>
2372 </modify-function>
2372
2373
2373 </object-type>
2374 </object-type>
2374 <object-type name="QSystemTrayIcon">
2375 <object-type name="QSystemTrayIcon">
2375 <modify-function signature="setContextMenu(QMenu*)">
2376 <modify-function signature="setContextMenu(QMenu*)">
2376 <modify-argument index="1">
2377 <modify-argument index="1">
2377 <reference-count action="set" variable-name="__rcContextMenu"/>
2378 <reference-count action="set" variable-name="__rcContextMenu"/>
2378 </modify-argument>
2379 </modify-argument>
2379 </modify-function>
2380 </modify-function>
2380 </object-type>
2381 </object-type>
2381 <object-type name="QTableView">
2382 <object-type name="QTableView">
2382 <modify-function signature="setHorizontalHeader(QHeaderView*)">
2383 <modify-function signature="setHorizontalHeader(QHeaderView*)">
2383 <modify-argument index="1">
2384 <modify-argument index="1">
2384 <reference-count action="ignore"/>
2385 <reference-count action="ignore"/>
2385 </modify-argument>
2386 </modify-argument>
2386 </modify-function>
2387 </modify-function>
2387 <modify-function signature="setVerticalHeader(QHeaderView*)">
2388 <modify-function signature="setVerticalHeader(QHeaderView*)">
2388 <modify-argument index="1">
2389 <modify-argument index="1">
2389 <reference-count action="ignore"/>
2390 <reference-count action="ignore"/>
2390 </modify-argument>
2391 </modify-argument>
2391 </modify-function>
2392 </modify-function>
2392 <modify-function signature="setModel(QAbstractItemModel*)">
2393 <modify-function signature="setModel(QAbstractItemModel*)">
2393 <modify-argument index="1">
2394 <modify-argument index="1">
2394 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemModel"/>
2395 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemModel"/>
2395 </modify-argument>
2396 </modify-argument>
2396 </modify-function>
2397 </modify-function>
2397 <modify-function signature="setSelectionModel(QItemSelectionModel*)">
2398 <modify-function signature="setSelectionModel(QItemSelectionModel*)">
2398 <modify-argument index="1">
2399 <modify-argument index="1">
2399 <no-null-pointer/>
2400 <no-null-pointer/>
2400 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemSelectionModel"/>
2401 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemSelectionModel"/>
2401 </modify-argument>
2402 </modify-argument>
2402 </modify-function>
2403 </modify-function>
2403
2404
2404 <modify-function signature="sortByColumn(int)" remove="all"/> <!--### Obsolete in 4.3-->
2405 <modify-function signature="sortByColumn(int)" remove="all"/> <!--### Obsolete in 4.3-->
2405 </object-type>
2406 </object-type>
2406 <object-type name="QTextBlockGroup" delete-in-main-thread="yes"/>
2407 <object-type name="QTextBlockGroup" delete-in-main-thread="yes"/>
2407 <object-type name="QTextBlockUserData" delete-in-main-thread="yes"/>
2408 <object-type name="QTextBlockUserData" delete-in-main-thread="yes"/>
2408 <object-type name="QTextItem" delete-in-main-thread="yes"/>
2409 <object-type name="QTextItem" delete-in-main-thread="yes"/>
2409 <object-type name="QTextList" delete-in-main-thread="yes">
2410 <object-type name="QTextList" delete-in-main-thread="yes">
2410 <modify-function signature="format()const" rename="textListFormat"/>
2411 <modify-function signature="format()const" rename="textListFormat"/>
2411
2412
2412 <modify-function signature="isEmpty()const" remove="all"/> <!--### Obsolete in 4.3-->
2413 <modify-function signature="isEmpty()const" remove="all"/> <!--### Obsolete in 4.3-->
2413 </object-type>
2414 </object-type>
2414 <object-type name="QTextObject" delete-in-main-thread="yes"/>
2415 <object-type name="QTextObject" delete-in-main-thread="yes"/>
2415 <object-type name="QTextObjectInterface" delete-in-main-thread="yes">
2416 <object-type name="QTextObjectInterface" delete-in-main-thread="yes">
2416 <modify-function signature="drawObject(QPainter*,QRectF,QTextDocument*,int,QTextFormat)">
2417 <modify-function signature="drawObject(QPainter*,QRectF,QTextDocument*,int,QTextFormat)">
2417 <modify-argument index="1" invalidate-after-use="yes"/>
2418 <modify-argument index="1" invalidate-after-use="yes"/>
2418 </modify-function>
2419 </modify-function>
2419 </object-type>
2420 </object-type>
2420
2421
2421 <object-type name="QTimeEdit"/>
2422 <object-type name="QTimeEdit"/>
2422 <object-type name="QToolBox">
2423 <object-type name="QToolBox">
2423 <modify-function signature="addItem(QWidget*,QString)">
2424 <modify-function signature="addItem(QWidget*,QString)">
2424 <modify-argument index="1">
2425 <modify-argument index="1">
2425 <reference-count action="ignore"/>
2426 <reference-count action="ignore"/>
2426 </modify-argument>
2427 </modify-argument>
2427 </modify-function>
2428 </modify-function>
2428 <modify-function signature="addItem(QWidget*,QIcon,QString)">
2429 <modify-function signature="addItem(QWidget*,QIcon,QString)">
2429 <modify-argument index="1">
2430 <modify-argument index="1">
2430 <reference-count action="ignore"/>
2431 <reference-count action="ignore"/>
2431 </modify-argument>
2432 </modify-argument>
2432 </modify-function>
2433 </modify-function>
2433 <modify-function signature="insertItem(int,QWidget*,QIcon,QString)">
2434 <modify-function signature="insertItem(int,QWidget*,QIcon,QString)">
2434 <modify-argument index="2">
2435 <modify-argument index="2">
2435 <reference-count action="ignore"/>
2436 <reference-count action="ignore"/>
2436 </modify-argument>
2437 </modify-argument>
2437 </modify-function>
2438 </modify-function>
2438 <modify-function signature="insertItem(int,QWidget*,QString)">
2439 <modify-function signature="insertItem(int,QWidget*,QString)">
2439 <modify-argument index="2">
2440 <modify-argument index="2">
2440 <reference-count action="ignore"/>
2441 <reference-count action="ignore"/>
2441 </modify-argument>
2442 </modify-argument>
2442 </modify-function>
2443 </modify-function>
2443 <modify-function signature="setCurrentWidget(QWidget*) ">
2444 <modify-function signature="setCurrentWidget(QWidget*) ">
2444 <modify-argument index="1">
2445 <modify-argument index="1">
2445 <reference-count action="ignore"/>
2446 <reference-count action="ignore"/>
2446 </modify-argument>
2447 </modify-argument>
2447 </modify-function>
2448 </modify-function>
2448 </object-type>
2449 </object-type>
2449 <object-type name="QToolButton">
2450 <object-type name="QToolButton">
2450 <modify-function signature="initStyleOption(QStyleOptionToolButton*)const">
2451 <modify-function signature="initStyleOption(QStyleOptionToolButton*)const">
2451 <access modifier="private"/>
2452 <access modifier="private"/>
2452 </modify-function>
2453 </modify-function>
2453
2454
2454 <modify-function signature="setDefaultAction(QAction *)">
2455 <modify-function signature="setDefaultAction(QAction *)">
2455 <modify-argument index="1">
2456 <modify-argument index="1">
2456 <reference-count action="set" variable-name="__rcDefaultAction"/>
2457 <reference-count action="set" variable-name="__rcDefaultAction"/>
2457 </modify-argument>
2458 </modify-argument>
2458 </modify-function>
2459 </modify-function>
2459 <modify-function signature="setMenu(QMenu *)">
2460 <modify-function signature="setMenu(QMenu *)">
2460 <modify-argument index="1">
2461 <modify-argument index="1">
2461 <reference-count action="set" variable-name="__rcMenu"/>
2462 <reference-count action="set" variable-name="__rcMenu"/>
2462 </modify-argument>
2463 </modify-argument>
2463 </modify-function>
2464 </modify-function>
2464 </object-type>
2465 </object-type>
2465 <object-type name="QToolTip"/>
2466 <object-type name="QToolTip"/>
2466 <object-type name="QTreeView">
2467 <object-type name="QTreeView">
2467
2468
2468 <modify-function signature="drawBranches(QPainter*,QRect,QModelIndex)const">
2469 <modify-function signature="drawBranches(QPainter*,QRect,QModelIndex)const">
2469 <modify-argument index="1" invalidate-after-use="yes"/>
2470 <modify-argument index="1" invalidate-after-use="yes"/>
2470 </modify-function>
2471 </modify-function>
2471 <modify-function signature="drawRow(QPainter*,QStyleOptionViewItem,QModelIndex)const">
2472 <modify-function signature="drawRow(QPainter*,QStyleOptionViewItem,QModelIndex)const">
2472 <modify-argument index="1" invalidate-after-use="yes"/>
2473 <modify-argument index="1" invalidate-after-use="yes"/>
2473 </modify-function>
2474 </modify-function>
2474
2475
2475 <modify-function signature="setHeader(QHeaderView*)">
2476 <modify-function signature="setHeader(QHeaderView*)">
2476 <modify-argument index="1">
2477 <modify-argument index="1">
2477 <reference-count action="ignore"/>
2478 <reference-count action="ignore"/>
2478 </modify-argument>
2479 </modify-argument>
2479 </modify-function>
2480 </modify-function>
2480 <modify-function signature="setModel(QAbstractItemModel*)">
2481 <modify-function signature="setModel(QAbstractItemModel*)">
2481 <modify-argument index="1">
2482 <modify-argument index="1">
2482 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemModel"/>
2483 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemModel"/>
2483 </modify-argument>
2484 </modify-argument>
2484 </modify-function>
2485 </modify-function>
2485 <modify-function signature="setSelectionModel(QItemSelectionModel*)">
2486 <modify-function signature="setSelectionModel(QItemSelectionModel*)">
2486 <modify-argument index="1">
2487 <modify-argument index="1">
2487 <no-null-pointer/>
2488 <no-null-pointer/>
2488 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemSelectionModel"/>
2489 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemSelectionModel"/>
2489 </modify-argument>
2490 </modify-argument>
2490 </modify-function>
2491 </modify-function>
2491
2492
2492 <modify-function signature="sortByColumn(int)" remove="all"/> <!--### Obsolete in 4.3-->
2493 <modify-function signature="sortByColumn(int)" remove="all"/> <!--### Obsolete in 4.3-->
2493 </object-type>
2494 </object-type>
2494 <object-type name="QUndoCommand">
2495 <object-type name="QUndoCommand">
2495 <modify-function signature="mergeWith(const QUndoCommand*)">
2496 <modify-function signature="mergeWith(const QUndoCommand*)">
2496 <modify-argument index="1" invalidate-after-use="yes"/>
2497 <modify-argument index="1" invalidate-after-use="yes"/>
2497 </modify-function>
2498 </modify-function>
2498 </object-type>
2499 </object-type>
2499 <object-type name="QUndoGroup">
2500 <object-type name="QUndoGroup">
2500 <modify-function signature="addStack(QUndoStack*)">
2501 <modify-function signature="addStack(QUndoStack*)">
2501 <modify-argument index="1">
2502 <modify-argument index="1">
2502 <reference-count action="add" variable-name="__rcStacks"/>
2503 <reference-count action="add" variable-name="__rcStacks"/>
2503 </modify-argument>
2504 </modify-argument>
2504 </modify-function>
2505 </modify-function>
2505 <modify-function signature="removeStack(QUndoStack*)">
2506 <modify-function signature="removeStack(QUndoStack*)">
2506 <modify-argument index="1">
2507 <modify-argument index="1">
2507 <reference-count action="remove" variable-name="__rcStacks"/>
2508 <reference-count action="remove" variable-name="__rcStacks"/>
2508 </modify-argument>
2509 </modify-argument>
2509 </modify-function>
2510 </modify-function>
2510 <modify-function signature="setActiveStack(QUndoStack*)">
2511 <modify-function signature="setActiveStack(QUndoStack*)">
2511 <modify-argument index="1">
2512 <modify-argument index="1">
2512 <reference-count action="ignore"/>
2513 <reference-count action="ignore"/>
2513 </modify-argument>
2514 </modify-argument>
2514 </modify-function>
2515 </modify-function>
2515 </object-type>
2516 </object-type>
2516
2517
2517 <object-type name="QUndoStack"/>
2518 <object-type name="QUndoStack"/>
2518
2519
2519 <object-type name="QUndoView">
2520 <object-type name="QUndoView">
2520 <modify-function signature="setGroup(QUndoGroup *)">
2521 <modify-function signature="setGroup(QUndoGroup *)">
2521 <modify-argument index="1">
2522 <modify-argument index="1">
2522 <reference-count action="set" variable-name="__rcGroupOrStack"/>
2523 <reference-count action="set" variable-name="__rcGroupOrStack"/>
2523 </modify-argument>
2524 </modify-argument>
2524 </modify-function>
2525 </modify-function>
2525 <modify-function signature="setStack(QUndoStack *)">
2526 <modify-function signature="setStack(QUndoStack *)">
2526 <modify-argument index="1">
2527 <modify-argument index="1">
2527 <reference-count action="set" variable-name="__rcGroupOrStack"/>
2528 <reference-count action="set" variable-name="__rcGroupOrStack"/>
2528 </modify-argument>
2529 </modify-argument>
2529 </modify-function>
2530 </modify-function>
2530 <modify-function signature="QUndoView(QUndoGroup *,QWidget *)">
2531 <modify-function signature="QUndoView(QUndoGroup *,QWidget *)">
2531 <modify-argument index="1">
2532 <modify-argument index="1">
2532 <reference-count action="set" variable-name="__rcGroupOrStack"/>
2533 <reference-count action="set" variable-name="__rcGroupOrStack"/>
2533 </modify-argument>
2534 </modify-argument>
2534 </modify-function>
2535 </modify-function>
2535 <modify-function signature="QUndoView(QUndoStack *,QWidget *)">
2536 <modify-function signature="QUndoView(QUndoStack *,QWidget *)">
2536 <modify-argument index="1">
2537 <modify-argument index="1">
2537 <reference-count action="set" variable-name="__rcGroupOrStack"/>
2538 <reference-count action="set" variable-name="__rcGroupOrStack"/>
2538 </modify-argument>
2539 </modify-argument>
2539 </modify-function>
2540 </modify-function>
2540 </object-type>
2541 </object-type>
2541 <object-type name="QVBoxLayout"/>
2542 <object-type name="QVBoxLayout"/>
2542 <object-type name="QValidator"/>
2543 <object-type name="QValidator"/>
2543 <object-type name="QWhatsThis"/>
2544 <object-type name="QWhatsThis"/>
2544 <object-type name="QWidgetAction">
2545 <object-type name="QWidgetAction">
2545 <modify-function signature="createWidget(QWidget*)">
2546 <modify-function signature="createWidget(QWidget*)">
2546 <modify-argument index="return">
2547 <modify-argument index="return">
2547 <define-ownership class="shell" owner="c++"/>
2548 <define-ownership class="shell" owner="c++"/>
2548 </modify-argument>
2549 </modify-argument>
2549 </modify-function>
2550 </modify-function>
2550 </object-type>
2551 </object-type>
2551 <object-type name="QWidgetItem"/>
2552 <object-type name="QWidgetItem"/>
2552 <object-type name="QWindowsStyle">
2553 <object-type name="QWindowsStyle">
2553 <modify-function signature="standardPixmap(QStyle::StandardPixmap, const QStyleOption*, const QWidget*)const" remove="all"/> <!--### Obsolete in 4.3-->
2554 <modify-function signature="standardPixmap(QStyle::StandardPixmap, const QStyleOption*, const QWidget*)const" remove="all"/> <!--### Obsolete in 4.3-->
2554 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
2555 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
2555 </object-type>
2556 </object-type>
2556 <object-type name="QWorkspace">
2557 <object-type name="QWorkspace">
2557 <modify-function signature="addWindow(QWidget*,QFlags&lt;Qt::WindowType&gt;)">
2558 <modify-function signature="addWindow(QWidget*,QFlags&lt;Qt::WindowType&gt;)">
2558 <modify-argument index="1">
2559 <modify-argument index="1">
2559 <reference-count action="ignore"/>
2560 <reference-count action="ignore"/>
2560 </modify-argument>
2561 </modify-argument>
2561 </modify-function>
2562 </modify-function>
2562 <modify-function signature="setActiveWindow(QWidget*)">
2563 <modify-function signature="setActiveWindow(QWidget*)">
2563 <modify-argument index="1">
2564 <modify-argument index="1">
2564 <reference-count action="ignore"/>
2565 <reference-count action="ignore"/>
2565 </modify-argument>
2566 </modify-argument>
2566 </modify-function>
2567 </modify-function>
2567 </object-type>
2568 </object-type>
2568
2569
2569 <object-type name="QActionEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::ActionAdded || %1-&gt;type() == QEvent::ActionRemoved || %1-&gt;type() == QEvent::ActionChanged"/>
2570 <object-type name="QActionEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::ActionAdded || %1-&gt;type() == QEvent::ActionRemoved || %1-&gt;type() == QEvent::ActionChanged"/>
2570 <object-type name="QClipboardEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Clipboard"/>
2571 <object-type name="QClipboardEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Clipboard"/>
2571 <object-type name="QCloseEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Close"/>
2572 <object-type name="QCloseEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Close"/>
2572 <object-type name="QContextMenuEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::ContextMenu"/>
2573 <object-type name="QContextMenuEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::ContextMenu"/>
2573 <object-type name="QDragEnterEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::DragEnter"/>
2574 <object-type name="QDragEnterEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::DragEnter"/>
2574 <object-type name="QDragLeaveEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::DragLeave"/>
2575 <object-type name="QDragLeaveEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::DragLeave"/>
2575 <object-type name="QDragMoveEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::DragMove">
2576 <object-type name="QDragMoveEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::DragMove">
2576 <modify-function signature="accept()" remove="all"/>
2577 <modify-function signature="accept()" remove="all"/>
2577 <modify-function signature="ignore()" remove="all"/>
2578 <modify-function signature="ignore()" remove="all"/>
2578 </object-type>
2579 </object-type>
2579 <object-type name="QDropEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Drop">
2580 <object-type name="QDropEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Drop">
2580 <modify-function signature="encodedData(const char*)const">
2581 <modify-function signature="encodedData(const char*)const">
2581 <remove/>
2582 <remove/>
2582 </modify-function>
2583 </modify-function>
2583
2584
2584 <modify-function signature="format(int)const">
2585 <modify-function signature="format(int)const">
2585 <remove/>
2586 <remove/>
2586 </modify-function>
2587 </modify-function>
2587
2588
2588 <modify-function signature="provides(const char*)const">
2589 <modify-function signature="provides(const char*)const">
2589 <remove/>
2590 <remove/>
2590 </modify-function>
2591 </modify-function>
2591
2592
2592
2593
2593 </object-type>
2594 </object-type>
2594 <object-type name="QFileOpenEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::FileOpen">
2595 <object-type name="QFileOpenEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::FileOpen">
2595 <modify-function signature="openFile(QFile&amp;,QFlags&lt;QIODevice::OpenModeFlag&gt;)const" remove="all"/>
2596 <modify-function signature="openFile(QFile&amp;,QFlags&lt;QIODevice::OpenModeFlag&gt;)const" remove="all"/>
2596 </object-type>
2597 </object-type>
2597 <object-type name="QFocusEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::FocusIn || %1-&gt;type() == QEvent::FocusOut">
2598 <object-type name="QFocusEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::FocusIn || %1-&gt;type() == QEvent::FocusOut">
2598 <modify-function signature="reason()const">
2599 <modify-function signature="reason()const">
2599 <remove/>
2600 <remove/>
2600 </modify-function>
2601 </modify-function>
2601 </object-type>
2602 </object-type>
2602
2603
2603 <object-type name="QGraphicsSceneContextMenuEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneContextMenu"/>
2604 <object-type name="QGraphicsSceneContextMenuEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneContextMenu"/>
2604 <object-type name="QGraphicsSceneDragDropEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneDragEnter || %1-&gt;type() == QEvent::GraphicsSceneDragLeave || %1-&gt;type() == QEvent::GraphicsSceneDragMove || %1-&gt;type() == QEvent::GraphicsSceneDrop">
2605 <object-type name="QGraphicsSceneDragDropEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneDragEnter || %1-&gt;type() == QEvent::GraphicsSceneDragLeave || %1-&gt;type() == QEvent::GraphicsSceneDragMove || %1-&gt;type() == QEvent::GraphicsSceneDrop">
2605 <modify-function signature="setMimeData(const QMimeData *)">
2606 <modify-function signature="setMimeData(const QMimeData *)">
2606 <remove/>
2607 <remove/>
2607 </modify-function>
2608 </modify-function>
2608 <modify-function signature="setSource(QWidget *)">
2609 <modify-function signature="setSource(QWidget *)">
2609 <remove/>
2610 <remove/>
2610 </modify-function>
2611 </modify-function>
2611 </object-type>
2612 </object-type>
2612 <object-type name="QGraphicsSceneEvent">
2613 <object-type name="QGraphicsSceneEvent">
2613 <modify-function signature="setWidget(QWidget *)">
2614 <modify-function signature="setWidget(QWidget *)">
2614 <remove/>
2615 <remove/>
2615 </modify-function>
2616 </modify-function>
2616 </object-type>
2617 </object-type>
2617 <object-type name="QGraphicsSceneMoveEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneMove"/>
2618 <object-type name="QGraphicsSceneMoveEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneMove"/>
2618 <object-type name="QGraphicsSceneResizeEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneResize"/>
2619 <object-type name="QGraphicsSceneResizeEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneResize"/>
2619 <object-type name="QGraphicsSceneHelpEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneHelp"/>
2620 <object-type name="QGraphicsSceneHelpEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneHelp"/>
2620 <object-type name="QGraphicsSceneHoverEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneHoverEnter || %1-&gt;type() == QEvent::GraphicsSceneHoverLeave || %1-&gt;type() == QEvent::GraphicsSceneHoverMove"/>
2621 <object-type name="QGraphicsSceneHoverEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneHoverEnter || %1-&gt;type() == QEvent::GraphicsSceneHoverLeave || %1-&gt;type() == QEvent::GraphicsSceneHoverMove"/>
2621 <object-type name="QGraphicsSceneMouseEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneMouseDoubleClick || %1-&gt;type() == QEvent::GraphicsSceneMouseMove || %1-&gt;type() == QEvent::GraphicsSceneMousePress || %1-&gt;type() == QEvent::GraphicsSceneMouseRelease"/>
2622 <object-type name="QGraphicsSceneMouseEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneMouseDoubleClick || %1-&gt;type() == QEvent::GraphicsSceneMouseMove || %1-&gt;type() == QEvent::GraphicsSceneMousePress || %1-&gt;type() == QEvent::GraphicsSceneMouseRelease"/>
2622 <object-type name="QGraphicsSceneWheelEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneWheel"/>
2623 <object-type name="QGraphicsSceneWheelEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::GraphicsSceneWheel"/>
2623 <object-type name="QHelpEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::ToolTip || %1-&gt;type() == QEvent::WhatsThis"/>
2624 <object-type name="QHelpEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::ToolTip || %1-&gt;type() == QEvent::WhatsThis"/>
2624 <object-type name="QHideEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Hide"/>
2625 <object-type name="QHideEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Hide"/>
2625 <object-type name="QHoverEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::HoverEnter || %1-&gt;type() == QEvent::HoverLeave || %1-&gt;type() == QEvent::HoverMove"/>
2626 <object-type name="QHoverEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::HoverEnter || %1-&gt;type() == QEvent::HoverLeave || %1-&gt;type() == QEvent::HoverMove"/>
2626 <object-type name="QIconDragEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::IconDrag"/>
2627 <object-type name="QIconDragEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::IconDrag"/>
2627 <object-type name="QInputMethodEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::InputMethod"/>
2628 <object-type name="QInputMethodEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::InputMethod"/>
2628 <object-type name="QMoveEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Move"/>
2629 <object-type name="QMoveEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Move"/>
2629 <object-type name="QResizeEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Resize"/>
2630 <object-type name="QResizeEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Resize"/>
2630 <object-type name="QShortcutEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Shortcut">
2631 <object-type name="QShortcutEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Shortcut">
2631 <!-- All these have const overloads that are used instead -->
2632 <!-- All these have const overloads that are used instead -->
2632 <modify-function signature="isAmbiguous()">
2633 <modify-function signature="isAmbiguous()">
2633 <remove/>
2634 <remove/>
2634 </modify-function>
2635 </modify-function>
2635 <modify-function signature="shortcutId()">
2636 <modify-function signature="shortcutId()">
2636 <remove/>
2637 <remove/>
2637 </modify-function>
2638 </modify-function>
2638 <modify-function signature="key()">
2639 <modify-function signature="key()">
2639 <remove/>
2640 <remove/>
2640 </modify-function>
2641 </modify-function>
2641 </object-type>
2642 </object-type>
2642 <object-type name="QShowEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Show"/>
2643 <object-type name="QShowEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Show"/>
2643 <object-type name="QStatusTipEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::StatusTip"/>
2644 <object-type name="QStatusTipEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::StatusTip"/>
2644 <object-type name="QTabletEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::TabletMove || %1-&gt;type() == QEvent::TabletPress || %1-&gt;type() == QEvent::TabletRelease"/>
2645 <object-type name="QTabletEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::TabletMove || %1-&gt;type() == QEvent::TabletPress || %1-&gt;type() == QEvent::TabletRelease"/>
2645 <object-type name="QToolBarChangeEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::ToolBarChange"/>
2646 <object-type name="QToolBarChangeEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::ToolBarChange"/>
2646 <object-type name="QWhatsThisClickedEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::WhatsThisClicked"/>
2647 <object-type name="QWhatsThisClickedEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::WhatsThisClicked"/>
2647 <object-type name="QWheelEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Wheel"/>
2648 <object-type name="QWheelEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Wheel"/>
2648 <object-type name="QWindowStateChangeEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::WindowStateChange"/>
2649 <object-type name="QWindowStateChangeEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::WindowStateChange"/>
2649 <object-type name="QDragResponseEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::DragResponse"/>
2650 <object-type name="QDragResponseEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::DragResponse"/>
2650 <object-type name="QInputEvent">
2651 <object-type name="QInputEvent">
2651 <modify-function signature="modifiers()const" access="non-final"/>
2652 <modify-function signature="modifiers()const" access="non-final"/>
2652 </object-type>
2653 </object-type>
2653 <object-type name="QKeyEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::KeyPress || %1-&gt;type() == QEvent::KeyRelease"/>
2654 <object-type name="QKeyEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::KeyPress || %1-&gt;type() == QEvent::KeyRelease"/>
2654 <object-type name="QMouseEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::MouseButtonDblClick || %1-&gt;type() == QEvent::MouseButtonPress || %1-&gt;type() == QEvent::MouseButtonRelease || %1-&gt;type() == QEvent::MouseMove"/>
2655 <object-type name="QMouseEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::MouseButtonDblClick || %1-&gt;type() == QEvent::MouseButtonPress || %1-&gt;type() == QEvent::MouseButtonRelease || %1-&gt;type() == QEvent::MouseMove"/>
2655 <object-type name="QPaintEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Paint"/>
2656 <object-type name="QPaintEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::Paint"/>
2656
2657
2657 <object-type name="QAbstractButton"/>
2658 <object-type name="QAbstractButton"/>
2658
2659
2659 <object-type name="QStyle">
2660 <object-type name="QStyle">
2660 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
2661 <modify-function signature="standardIconImplementation(QStyle::StandardPixmap, const QStyleOption *, const QWidget *)const" virtual-slot="yes"/>
2661 <modify-function signature="layoutSpacingImplementation(QSizePolicy::ControlType, QSizePolicy::ControlType, Qt::Orientation, const QStyleOption *, const QWidget *) const" virtual-slot="yes"/>
2662 <modify-function signature="layoutSpacingImplementation(QSizePolicy::ControlType, QSizePolicy::ControlType, Qt::Orientation, const QStyleOption *, const QWidget *) const" virtual-slot="yes"/>
2662
2663
2663 <modify-function signature="drawComplexControl(QStyle::ComplexControl,const QStyleOptionComplex*,QPainter*,const QWidget*)const">
2664 <modify-function signature="drawComplexControl(QStyle::ComplexControl,const QStyleOptionComplex*,QPainter*,const QWidget*)const">
2664 <modify-argument index="3" invalidate-after-use="yes"/>
2665 <modify-argument index="3" invalidate-after-use="yes"/>
2665 </modify-function>
2666 </modify-function>
2666 <modify-function signature="drawControl(QStyle::ControlElement,const QStyleOption*,QPainter*,const QWidget*)const">
2667 <modify-function signature="drawControl(QStyle::ControlElement,const QStyleOption*,QPainter*,const QWidget*)const">
2667 <modify-argument index="3" invalidate-after-use="yes"/>
2668 <modify-argument index="3" invalidate-after-use="yes"/>
2668 </modify-function>
2669 </modify-function>
2669 <modify-function signature="drawPrimitive(QStyle::PrimitiveElement,const QStyleOption*,QPainter*,const QWidget*)const">
2670 <modify-function signature="drawPrimitive(QStyle::PrimitiveElement,const QStyleOption*,QPainter*,const QWidget*)const">
2670 <modify-argument index="3" invalidate-after-use="yes"/>
2671 <modify-argument index="3" invalidate-after-use="yes"/>
2671 </modify-function>
2672 </modify-function>
2672 <modify-function signature="styleHint(QStyle::StyleHint,const QStyleOption*,const QWidget*,QStyleHintReturn*)const">
2673 <modify-function signature="styleHint(QStyle::StyleHint,const QStyleOption*,const QWidget*,QStyleHintReturn*)const">
2673 <modify-argument index="4" invalidate-after-use="yes"/>
2674 <modify-argument index="4" invalidate-after-use="yes"/>
2674 </modify-function>
2675 </modify-function>
2675 <modify-function signature="drawItemPixmap(QPainter*,QRect,int,QPixmap)const">
2676 <modify-function signature="drawItemPixmap(QPainter*,QRect,int,QPixmap)const">
2676 <modify-argument index="1" invalidate-after-use="yes"/>
2677 <modify-argument index="1" invalidate-after-use="yes"/>
2677 </modify-function>
2678 </modify-function>
2678 <modify-function signature="drawItemText(QPainter*,QRect,int,QPalette,bool,QString,QPalette::ColorRole)const">
2679 <modify-function signature="drawItemText(QPainter*,QRect,int,QPalette,bool,QString,QPalette::ColorRole)const">
2679 <modify-argument index="1" invalidate-after-use="yes"/>
2680 <modify-argument index="1" invalidate-after-use="yes"/>
2680 </modify-function>
2681 </modify-function>
2681
2682
2682
2683
2683 <modify-function signature="itemTextRect(QFontMetrics,QRect,int,bool,QString)const" remove="all"/>
2684 <modify-function signature="itemTextRect(QFontMetrics,QRect,int,bool,QString)const" remove="all"/>
2684 </object-type>
2685 </object-type>
2685
2686
2686 <object-type name="QColorDialog">
2687 <object-type name="QColorDialog">
2687
2688
2688 <modify-function signature="getColor(const QColor &amp;, QWidget *)">
2689 <modify-function signature="getColor(const QColor &amp;, QWidget *)">
2689 <modify-argument index="1">
2690 <modify-argument index="1">
2690 <replace-default-expression with="QColor.white"/>
2691 <replace-default-expression with="QColor.white"/>
2691 </modify-argument>
2692 </modify-argument>
2692 </modify-function>
2693 </modify-function>
2693 <modify-function signature="getRgba(uint,bool*,QWidget*)">
2694 <modify-function signature="getRgba(uint,bool*,QWidget*)">
2694 <remove/>
2695 <remove/>
2695 </modify-function>
2696 </modify-function>
2696 </object-type>
2697 </object-type>
2697
2698
2698 <object-type name="QLayout">
2699 <object-type name="QLayout">
2699 <modify-function signature="addItem(QLayoutItem*)">
2700 <modify-function signature="addItem(QLayoutItem*)">
2700 <modify-argument index="1" invalidate-after-use="yes"/>
2701 <modify-argument index="1" invalidate-after-use="yes"/>
2701 </modify-function>
2702 </modify-function>
2702
2703
2703 <modify-function signature="setSpacing(int)" rename="setWidgetSpacing"/>
2704 <modify-function signature="setSpacing(int)" rename="setWidgetSpacing"/>
2704 <modify-function signature="spacing()const" rename="widgetSpacing"/>
2705 <modify-function signature="spacing()const" rename="widgetSpacing"/>
2705 <modify-function signature="addWidget(QWidget *)">
2706 <modify-function signature="addWidget(QWidget *)">
2706 <modify-argument index="1">
2707 <modify-argument index="1">
2707 <no-null-pointer/>
2708 <no-null-pointer/>
2708 <reference-count variable-name="__rcWidgets" action="add"/>
2709 <reference-count variable-name="__rcWidgets" action="add"/>
2709 </modify-argument>
2710 </modify-argument>
2710 </modify-function>
2711 </modify-function>
2711 <modify-function signature="addChildWidget(QWidget *)">
2712 <modify-function signature="addChildWidget(QWidget *)">
2712 <modify-argument index="1">
2713 <modify-argument index="1">
2713 <no-null-pointer/>
2714 <no-null-pointer/>
2714 <reference-count variable-name="__rcWidgets" action="add"/>
2715 <reference-count variable-name="__rcWidgets" action="add"/>
2715 </modify-argument>
2716 </modify-argument>
2716 </modify-function>
2717 </modify-function>
2717 <modify-function signature="removeWidget(QWidget *)">
2718 <modify-function signature="removeWidget(QWidget *)">
2718 <modify-argument index="1">
2719 <modify-argument index="1">
2719 <no-null-pointer/>
2720 <no-null-pointer/>
2720 <reference-count variable-name="__rcWidgets" action="remove"/>
2721 <reference-count variable-name="__rcWidgets" action="remove"/>
2721 </modify-argument>
2722 </modify-argument>
2722 </modify-function>
2723 </modify-function>
2723
2724
2724 <modify-function signature="setAlignment(QWidget*,QFlags&lt;Qt::AlignmentFlag&gt;)">
2725 <modify-function signature="setAlignment(QWidget*,QFlags&lt;Qt::AlignmentFlag&gt;)">
2725 <modify-argument index="1">
2726 <modify-argument index="1">
2726 <reference-count action="ignore"/>
2727 <reference-count action="ignore"/>
2727 </modify-argument>
2728 </modify-argument>
2728 </modify-function>
2729 </modify-function>
2729 <modify-function signature="setAlignment(QLayout*,QFlags&lt;Qt::AlignmentFlag&gt;)">
2730 <modify-function signature="setAlignment(QLayout*,QFlags&lt;Qt::AlignmentFlag&gt;)">
2730 <modify-argument index="1">
2731 <modify-argument index="1">
2731 <reference-count action="ignore"/>
2732 <reference-count action="ignore"/>
2732 </modify-argument>
2733 </modify-argument>
2733 </modify-function>
2734 </modify-function>
2734 <modify-function signature="setMenuBar(QWidget*)">
2735 <modify-function signature="setMenuBar(QWidget*)">
2735 <modify-argument index="1">
2736 <modify-argument index="1">
2736 <reference-count action="set" variable-name="__rcMenuBar"/>
2737 <reference-count action="set" variable-name="__rcMenuBar"/>
2737 </modify-argument>
2738 </modify-argument>
2738 </modify-function>
2739 </modify-function>
2739 <modify-function signature="getContentsMargins(int*,int*,int*,int*)const">
2740 <modify-function signature="getContentsMargins(int*,int*,int*,int*)const">
2740 <access modifier="private"/>
2741 <access modifier="private"/>
2741 </modify-function>
2742 </modify-function>
2742
2743
2743 <modify-function signature="margin()const" remove="all"/> <!--### Obsolete in 4.3-->
2744 <modify-function signature="margin()const" remove="all"/> <!--### Obsolete in 4.3-->
2744 <!-- <modify-function signature="setMargin(int)" remove="all"/> --> <!--### Obsolete in 4.3-->
2745 <!-- <modify-function signature="setMargin(int)" remove="all"/> --> <!--### Obsolete in 4.3-->
2745 </object-type>
2746 </object-type>
2746
2747
2747 <object-type name="QStackedLayout">
2748 <object-type name="QStackedLayout">
2748 <modify-function signature="addItem(QLayoutItem *)">
2749 <modify-function signature="addItem(QLayoutItem *)">
2749 <modify-argument index="1">
2750 <modify-argument index="1">
2750 <define-ownership class="java" owner="c++"/>
2751 <define-ownership class="java" owner="c++"/>
2751 </modify-argument>
2752 </modify-argument>
2752 </modify-function>
2753 </modify-function>
2753 <modify-function signature="itemAt(int) const">
2754 <modify-function signature="itemAt(int) const">
2754 <modify-argument index="return">
2755 <modify-argument index="return">
2755 <define-ownership class="java" owner="c++"/>
2756 <define-ownership class="java" owner="c++"/>
2756 </modify-argument>
2757 </modify-argument>
2757 </modify-function>
2758 </modify-function>
2758 <modify-function signature="addWidget(QWidget *)">
2759 <modify-function signature="addWidget(QWidget *)">
2759 <rename to="addStackedWidget"/>
2760 <rename to="addStackedWidget"/>
2760 <modify-argument index="1">
2761 <modify-argument index="1">
2761 <no-null-pointer/>
2762 <no-null-pointer/>
2762 <reference-count action="add" declare-variable="QLayout" variable-name="__rcWidgets"/>
2763 <reference-count action="add" declare-variable="QLayout" variable-name="__rcWidgets"/>
2763 </modify-argument>
2764 </modify-argument>
2764 </modify-function>
2765 </modify-function>
2765 <modify-function signature="insertWidget(int,QWidget*)">
2766 <modify-function signature="insertWidget(int,QWidget*)">
2766 <modify-argument index="2">
2767 <modify-argument index="2">
2767 <no-null-pointer/>
2768 <no-null-pointer/>
2768 <reference-count action="add" declare-variable="QLayout" variable-name="__rcWidgets"/>
2769 <reference-count action="add" declare-variable="QLayout" variable-name="__rcWidgets"/>
2769 </modify-argument>
2770 </modify-argument>
2770 </modify-function>
2771 </modify-function>
2771 <modify-function signature="setCurrentWidget(QWidget*)">
2772 <modify-function signature="setCurrentWidget(QWidget*)">
2772 <modify-argument index="1">
2773 <modify-argument index="1">
2773 <!-- Safe to ignore because current widget must have been added to layout already -->
2774 <!-- Safe to ignore because current widget must have been added to layout already -->
2774 <reference-count action="ignore"/>
2775 <reference-count action="ignore"/>
2775 </modify-argument>
2776 </modify-argument>
2776 </modify-function>
2777 </modify-function>
2777 </object-type>
2778 </object-type>
2778
2779
2779 <object-type name="QBoxLayout">
2780 <object-type name="QBoxLayout">
2780 <modify-function signature="addWidget(QWidget *, int, QFlags&lt;Qt::AlignmentFlag&gt;)">
2781 <modify-function signature="addWidget(QWidget *, int, QFlags&lt;Qt::AlignmentFlag&gt;)">
2781 <modify-argument index="1">
2782 <modify-argument index="1">
2782 <no-null-pointer/>
2783 <no-null-pointer/>
2783 </modify-argument>
2784 </modify-argument>
2784 </modify-function>
2785 </modify-function>
2785 <modify-function signature="addItem(QLayoutItem *)">
2786 <modify-function signature="addItem(QLayoutItem *)">
2786 <modify-argument index="1">
2787 <modify-argument index="1">
2787 <define-ownership class="java" owner="c++"/>
2788 <define-ownership class="java" owner="c++"/>
2788 </modify-argument>
2789 </modify-argument>
2789 </modify-function>
2790 </modify-function>
2790 <modify-function signature="insertLayout(int, QLayout *, int)">
2791 <modify-function signature="insertLayout(int, QLayout *, int)">
2791 <modify-argument index="2">
2792 <modify-argument index="2">
2792 <define-ownership class="java" owner="c++"/>
2793 <define-ownership class="java" owner="c++"/>
2793 </modify-argument>
2794 </modify-argument>
2794 </modify-function>
2795 </modify-function>
2795 <modify-function signature="insertItem(int, QLayoutItem *)">
2796 <modify-function signature="insertItem(int, QLayoutItem *)">
2796 <modify-argument index="2">
2797 <modify-argument index="2">
2797 <define-ownership class="java" owner="c++"/>
2798 <define-ownership class="java" owner="c++"/>
2798 </modify-argument>
2799 </modify-argument>
2799 </modify-function>
2800 </modify-function>
2800 <modify-function signature="addSpacerItem(QSpacerItem*)">
2801 <modify-function signature="addSpacerItem(QSpacerItem*)">
2801 <modify-argument index="1">
2802 <modify-argument index="1">
2802 <define-ownership class="java" owner="c++"/>
2803 <define-ownership class="java" owner="c++"/>
2803 </modify-argument>
2804 </modify-argument>
2804 </modify-function>
2805 </modify-function>
2805 <modify-function signature="insertSpacerItem(int,QSpacerItem*)">
2806 <modify-function signature="insertSpacerItem(int,QSpacerItem*)">
2806 <modify-argument index="2">
2807 <modify-argument index="2">
2807 <define-ownership class="java" owner="c++"/>
2808 <define-ownership class="java" owner="c++"/>
2808 </modify-argument>
2809 </modify-argument>
2809 </modify-function>
2810 </modify-function>
2810
2811
2811 <modify-function signature="addLayout(QLayout *, int)">
2812 <modify-function signature="addLayout(QLayout *, int)">
2812 <modify-argument index="1">
2813 <modify-argument index="1">
2813 <define-ownership class="java" owner="c++"/>
2814 <define-ownership class="java" owner="c++"/>
2814 </modify-argument>
2815 </modify-argument>
2815 </modify-function>
2816 </modify-function>
2816 <modify-function signature="addWidget(QWidget*,int,QFlags&lt;Qt::AlignmentFlag&gt;)">
2817 <modify-function signature="addWidget(QWidget*,int,QFlags&lt;Qt::AlignmentFlag&gt;)">
2817 <modify-argument index="1">
2818 <modify-argument index="1">
2818 <reference-count declare-variable="QLayout" action="add" variable-name="__rcWidgets"/>
2819 <reference-count declare-variable="QLayout" action="add" variable-name="__rcWidgets"/>
2819 </modify-argument>
2820 </modify-argument>
2820 </modify-function>
2821 </modify-function>
2821 <modify-function signature="insertWidget(int,QWidget*,int,QFlags&lt;Qt::AlignmentFlag&gt;)">
2822 <modify-function signature="insertWidget(int,QWidget*,int,QFlags&lt;Qt::AlignmentFlag&gt;)">
2822 <modify-argument index="2">
2823 <modify-argument index="2">
2823 <reference-count declare-variable="QLayout" action="add" variable-name="__rcWidgets"/>
2824 <reference-count declare-variable="QLayout" action="add" variable-name="__rcWidgets"/>
2824 </modify-argument>
2825 </modify-argument>
2825 </modify-function>
2826 </modify-function>
2826 <modify-function signature="setStretchFactor(QWidget*,int)">
2827 <modify-function signature="setStretchFactor(QWidget*,int)">
2827 <modify-argument index="1">
2828 <modify-argument index="1">
2828 <reference-count action="ignore"/>
2829 <reference-count action="ignore"/>
2829 </modify-argument>
2830 </modify-argument>
2830 </modify-function>
2831 </modify-function>
2831 <modify-function signature="setStretchFactor(QLayout*,int)">
2832 <modify-function signature="setStretchFactor(QLayout*,int)">
2832 <modify-argument index="1">
2833 <modify-argument index="1">
2833 <reference-count action="ignore"/>
2834 <reference-count action="ignore"/>
2834 </modify-argument>
2835 </modify-argument>
2835 </modify-function>
2836 </modify-function>
2836 </object-type>
2837 </object-type>
2837
2838
2838 <object-type name="QGridLayout">
2839 <object-type name="QGridLayout">
2839 <modify-function signature="addWidget(QWidget *)" remove="all"/>
2840 <modify-function signature="addWidget(QWidget *)" remove="all"/>
2840 <modify-function signature="addItem(QLayoutItem *)">
2841 <modify-function signature="addItem(QLayoutItem *)">
2841 <modify-argument index="1">
2842 <modify-argument index="1">
2842 <define-ownership class="java" owner="c++"/>
2843 <define-ownership class="java" owner="c++"/>
2843 </modify-argument>
2844 </modify-argument>
2844 </modify-function>
2845 </modify-function>
2845 <modify-function signature="addItem(QLayoutItem *, int, int, int, int, QFlags&lt;Qt::AlignmentFlag&gt;)">
2846 <modify-function signature="addItem(QLayoutItem *, int, int, int, int, QFlags&lt;Qt::AlignmentFlag&gt;)">
2846 <modify-argument index="1">
2847 <modify-argument index="1">
2847 <define-ownership class="java" owner="c++"/>
2848 <define-ownership class="java" owner="c++"/>
2848 </modify-argument>
2849 </modify-argument>
2849 </modify-function>
2850 </modify-function>
2850 <modify-function signature="addLayout(QLayout *, int, int, QFlags&lt;Qt::AlignmentFlag&gt;)">
2851 <modify-function signature="addLayout(QLayout *, int, int, QFlags&lt;Qt::AlignmentFlag&gt;)">
2851 <modify-argument index="1">
2852 <modify-argument index="1">
2852 <define-ownership class="java" owner="c++"/>
2853 <define-ownership class="java" owner="c++"/>
2853 </modify-argument>
2854 </modify-argument>
2854 </modify-function>
2855 </modify-function>
2855 <modify-function signature="addLayout(QLayout *, int, int, int, int, QFlags&lt;Qt::AlignmentFlag&gt;)">
2856 <modify-function signature="addLayout(QLayout *, int, int, int, int, QFlags&lt;Qt::AlignmentFlag&gt;)">
2856 <modify-argument index="1">
2857 <modify-argument index="1">
2857 <define-ownership class="java" owner="c++"/>
2858 <define-ownership class="java" owner="c++"/>
2858 </modify-argument>
2859 </modify-argument>
2859 </modify-function>
2860 </modify-function>
2860 <modify-function signature="addWidget(QWidget*,int,int,QFlags&lt;Qt::AlignmentFlag&gt;)">
2861 <modify-function signature="addWidget(QWidget*,int,int,QFlags&lt;Qt::AlignmentFlag&gt;)">
2861 <modify-argument index="1">
2862 <modify-argument index="1">
2862 <reference-count declare-variable="QLayout" action="add" variable-name="__rcWidgets"/>
2863 <reference-count declare-variable="QLayout" action="add" variable-name="__rcWidgets"/>
2863 </modify-argument>
2864 </modify-argument>
2864 </modify-function>
2865 </modify-function>
2865 <modify-function signature="addWidget(QWidget*,int,int,int,int,QFlags&lt;Qt::AlignmentFlag&gt;)">
2866 <modify-function signature="addWidget(QWidget*,int,int,int,int,QFlags&lt;Qt::AlignmentFlag&gt;)">
2866 <modify-argument index="1">
2867 <modify-argument index="1">
2867 <reference-count declare-variable="QLayout" action="add" variable-name="__rcWidgets"/>
2868 <reference-count declare-variable="QLayout" action="add" variable-name="__rcWidgets"/>
2868 </modify-argument>
2869 </modify-argument>
2869 </modify-function>
2870 </modify-function>
2870 <modify-function signature="addWidget(QWidget*)">
2871 <modify-function signature="addWidget(QWidget*)">
2871 <modify-argument index="1">
2872 <modify-argument index="1">
2872 <reference-count declare-variable="QLayout" action="add" variable-name="__rcWidgets"/>
2873 <reference-count declare-variable="QLayout" action="add" variable-name="__rcWidgets"/>
2873 </modify-argument>
2874 </modify-argument>
2874 </modify-function>
2875 </modify-function>
2875 <modify-function signature="getItemPosition(int,int*,int*,int*,int*)">
2876 <modify-function signature="getItemPosition(int,int*,int*,int*,int*)">
2876 <access modifier="private"/>
2877 <access modifier="private"/>
2877 </modify-function>
2878 </modify-function>
2878 </object-type>
2879 </object-type>
2879
2880
2880 <object-type name="QGraphicsView">
2881 <object-type name="QGraphicsView">
2881 <extra-includes>
2882 <extra-includes>
2882 <include file-name="QPainterPath" location="global"/>
2883 <include file-name="QPainterPath" location="global"/>
2883 <include file-name="QVarLengthArray" location="global"/>
2884 <include file-name="QVarLengthArray" location="global"/>
2884 </extra-includes>
2885 </extra-includes>
2885 <modify-function signature="fitInView(const QGraphicsItem *, Qt::AspectRatioMode)">
2886 <modify-function signature="fitInView(const QGraphicsItem *, Qt::AspectRatioMode)">
2886 <modify-argument index="1">
2887 <modify-argument index="1">
2887 <no-null-pointer/>
2888 <no-null-pointer/>
2888 </modify-argument>
2889 </modify-argument>
2889 </modify-function>
2890 </modify-function>
2890 <modify-function signature="setupViewport(QWidget *)" access="non-final"/>
2891 <modify-function signature="setupViewport(QWidget *)" access="non-final"/>
2891 <modify-function signature="setScene(QGraphicsScene*)">
2892 <modify-function signature="setScene(QGraphicsScene*)">
2892 <modify-argument index="1">
2893 <modify-argument index="1">
2893 <reference-count action="set" variable-name="__rcScene"/>
2894 <reference-count action="set" variable-name="__rcScene"/>
2894 </modify-argument>
2895 </modify-argument>
2895 </modify-function>
2896 </modify-function>
2896 <modify-function signature="setupViewport(QWidget*)">
2897 <modify-function signature="setupViewport(QWidget*)">
2897 <modify-argument index="1">
2898 <modify-argument index="1">
2898 <reference-count action="ignore"/>
2899 <reference-count action="ignore"/>
2899 </modify-argument>
2900 </modify-argument>
2900 </modify-function>
2901 </modify-function>
2901
2902
2902 <modify-function signature="drawBackground(QPainter*,QRectF)">
2903 <modify-function signature="drawBackground(QPainter*,QRectF)">
2903 <modify-argument index="1" invalidate-after-use="yes"/>
2904 <modify-argument index="1" invalidate-after-use="yes"/>
2904 </modify-function>
2905 </modify-function>
2905 <modify-function signature="drawForeground(QPainter*,QRectF)">
2906 <modify-function signature="drawForeground(QPainter*,QRectF)">
2906 <modify-argument index="1" invalidate-after-use="yes"/>
2907 <modify-argument index="1" invalidate-after-use="yes"/>
2907 </modify-function>
2908 </modify-function>
2908 <modify-function signature="drawItems(QPainter*,int,QGraphicsItem**,const QStyleOptionGraphicsItem*)">
2909 <modify-function signature="drawItems(QPainter*,int,QGraphicsItem**,const QStyleOptionGraphicsItem*)">
2909 <modify-argument index="1" invalidate-after-use="yes"/>
2910 <modify-argument index="1" invalidate-after-use="yes"/>
2910 </modify-function>
2911 </modify-function>
2911
2912
2912 <!--
2913 <!--
2913 <modify-function signature="drawItems(QPainter*,int,QGraphicsItem**,const QStyleOptionGraphicsItem*)">
2914 <modify-function signature="drawItems(QPainter*,int,QGraphicsItem**,const QStyleOptionGraphicsItem*)">
2914 <modify-argument index="2">
2915 <modify-argument index="2">
2915 <remove-argument/>
2916 <remove-argument/>
2916 <conversion-rule class="shell">
2917 <conversion-rule class="shell">
2917 // nothing
2918 // nothing
2918 </conversion-rule>
2919 </conversion-rule>
2919 <conversion-rule class="native">
2920 <conversion-rule class="native">
2920 <insert-template name="core.get_array_length">
2921 <insert-template name="core.get_array_length">
2921 <replace from="%ARRAY" to="%3"/>
2922 <replace from="%ARRAY" to="%3"/>
2922 </insert-template>
2923 </insert-template>
2923 int __length = %out;
2924 int __length = %out;
2924 </conversion-rule>
2925 </conversion-rule>
2925 </modify-argument>
2926 </modify-argument>
2926
2927
2927 <modify-argument index="3">
2928 <modify-argument index="3">
2928 <replace-type modified-type="com.trolltech.qt.gui.QGraphicsItemInterface[]"/>
2929 <replace-type modified-type="com.trolltech.qt.gui.QGraphicsItemInterface[]"/>
2929 <conversion-rule class="shell">
2930 <conversion-rule class="shell">
2930 <insert-template name="gui.convert_graphicsitem_array_to_java">
2931 <insert-template name="gui.convert_graphicsitem_array_to_java">
2931 <replace from="%LENGTH" to="%2"/>
2932 <replace from="%LENGTH" to="%2"/>
2932 </insert-template>
2933 </insert-template>
2933 jobjectArray graphicsItemArrayHolder = %out;
2934 jobjectArray graphicsItemArrayHolder = %out;
2934 </conversion-rule>
2935 </conversion-rule>
2935 <conversion-rule class="native">
2936 <conversion-rule class="native">
2936 <insert-template name="gui.convert_graphicsitem_array_from_java"/>
2937 <insert-template name="gui.convert_graphicsitem_array_from_java"/>
2937 </conversion-rule>
2938 </conversion-rule>
2938 </modify-argument>
2939 </modify-argument>
2939
2940
2940 <modify-argument index="4">
2941 <modify-argument index="4">
2941 <replace-type modified-type="com.trolltech.qt.gui.QStyleOptionGraphicsItem[]"/>
2942 <replace-type modified-type="com.trolltech.qt.gui.QStyleOptionGraphicsItem[]"/>
2942 <conversion-rule class="shell">
2943 <conversion-rule class="shell">
2943 <insert-template name="gui.convert_styleoptiongraphicsitem_array_to_java">
2944 <insert-template name="gui.convert_styleoptiongraphicsitem_array_to_java">
2944 <replace from="%LENGTH" to="%2"/>
2945 <replace from="%LENGTH" to="%2"/>
2945 </insert-template>
2946 </insert-template>
2946 jobjectArray styleOptionArrayHolder = %out;
2947 jobjectArray styleOptionArrayHolder = %out;
2947 </conversion-rule>
2948 </conversion-rule>
2948 <conversion-rule class="native">
2949 <conversion-rule class="native">
2949 <insert-template name="gui.convert_styleoptiongraphicsitem_array_from_java"/>
2950 <insert-template name="gui.convert_styleoptiongraphicsitem_array_from_java"/>
2950 </conversion-rule>
2951 </conversion-rule>
2951 </modify-argument>
2952 </modify-argument>
2952 </modify-function>
2953 </modify-function>
2953 -->
2954 -->
2954 </object-type>
2955 </object-type>
2955
2956
2956 <object-type name="QInputDialog">
2957 <object-type name="QInputDialog">
2957
2958
2958 <modify-function signature="getInt(QWidget*,QString,QString,int,int,int,int,bool*,QFlags&lt;Qt::WindowType&gt;)">
2959 <modify-function signature="getInt(QWidget*,QString,QString,int,int,int,int,bool*,QFlags&lt;Qt::WindowType&gt;)">
2959 <rename to="getInt_private"/>
2960 <rename to="getInt_private"/>
2960 <access modifier="private"/>
2961 <access modifier="private"/>
2961 <modify-argument index="4">
2962 <modify-argument index="4">
2962 <remove-default-expression/>
2963 <remove-default-expression/>
2963 </modify-argument>
2964 </modify-argument>
2964 <modify-argument index="5">
2965 <modify-argument index="5">
2965 <remove-default-expression/>
2966 <remove-default-expression/>
2966 </modify-argument>
2967 </modify-argument>
2967 <modify-argument index="6">
2968 <modify-argument index="6">
2968 <remove-default-expression/>
2969 <remove-default-expression/>
2969 </modify-argument>
2970 </modify-argument>
2970 <modify-argument index="7">
2971 <modify-argument index="7">
2971 <remove-default-expression/>
2972 <remove-default-expression/>
2972 </modify-argument>
2973 </modify-argument>
2973 <modify-argument index="8">
2974 <modify-argument index="8">
2974 <remove-default-expression/>
2975 <remove-default-expression/>
2975 </modify-argument>
2976 </modify-argument>
2976 <modify-argument index="9">
2977 <modify-argument index="9">
2977 <remove-default-expression/>
2978 <remove-default-expression/>
2978 </modify-argument>
2979 </modify-argument>
2979 </modify-function>
2980 </modify-function>
2980
2981
2981 <modify-function signature="getDouble(QWidget *, const QString &amp;, const QString &amp;, double, double, double, int, bool *, QFlags&lt;Qt::WindowType&gt;)">
2982 <modify-function signature="getDouble(QWidget *, const QString &amp;, const QString &amp;, double, double, double, int, bool *, QFlags&lt;Qt::WindowType&gt;)">
2982 <!--
2983 <!--
2983 <rename to="getDouble_internal"/>
2984 <rename to="getDouble_internal"/>
2984 <access modifier="private"/>
2985 <access modifier="private"/>
2985 -->
2986 -->
2986 <modify-argument index="4">
2987 <modify-argument index="4">
2987 <remove-default-expression/>
2988 <remove-default-expression/>
2988 </modify-argument>
2989 </modify-argument>
2989 <modify-argument index="5">
2990 <modify-argument index="5">
2990 <remove-default-expression/>
2991 <remove-default-expression/>
2991 </modify-argument>
2992 </modify-argument>
2992 <modify-argument index="6">
2993 <modify-argument index="6">
2993 <remove-default-expression/>
2994 <remove-default-expression/>
2994 </modify-argument>
2995 </modify-argument>
2995 <modify-argument index="7">
2996 <modify-argument index="7">
2996 <remove-default-expression/>
2997 <remove-default-expression/>
2997 </modify-argument>
2998 </modify-argument>
2998 <modify-argument index="8">
2999 <modify-argument index="8">
2999 <remove-default-expression/>
3000 <remove-default-expression/>
3000 </modify-argument>
3001 </modify-argument>
3001 <modify-argument index="9">
3002 <modify-argument index="9">
3002 <remove-default-expression/>
3003 <remove-default-expression/>
3003 </modify-argument>
3004 </modify-argument>
3004 </modify-function>
3005 </modify-function>
3005
3006
3006 <modify-function signature="getInteger(QWidget *, const QString &amp;, const QString &amp;, int, int, int, int, bool *, QFlags&lt;Qt::WindowType&gt;)">
3007 <modify-function signature="getInteger(QWidget *, const QString &amp;, const QString &amp;, int, int, int, int, bool *, QFlags&lt;Qt::WindowType&gt;)">
3007 <!--
3008 <!--
3008 <rename to="getInteger_internal"/>
3009 <rename to="getInteger_internal"/>
3009 <access modifier="private"/>
3010 <access modifier="private"/>
3010 -->
3011 -->
3011 <modify-argument index="4">
3012 <modify-argument index="4">
3012 <remove-default-expression/>
3013 <remove-default-expression/>
3013 </modify-argument>
3014 </modify-argument>
3014 <modify-argument index="5">
3015 <modify-argument index="5">
3015 <remove-default-expression/>
3016 <remove-default-expression/>
3016 </modify-argument>
3017 </modify-argument>
3017 <modify-argument index="6">
3018 <modify-argument index="6">
3018 <remove-default-expression/>
3019 <remove-default-expression/>
3019 </modify-argument>
3020 </modify-argument>
3020 <modify-argument index="7">
3021 <modify-argument index="7">
3021 <remove-default-expression/>
3022 <remove-default-expression/>
3022 </modify-argument>
3023 </modify-argument>
3023 <modify-argument index="8">
3024 <modify-argument index="8">
3024 <remove-default-expression/>
3025 <remove-default-expression/>
3025 </modify-argument>
3026 </modify-argument>
3026 <modify-argument index="9">
3027 <modify-argument index="9">
3027 <remove-default-expression/>
3028 <remove-default-expression/>
3028 </modify-argument>
3029 </modify-argument>
3029 </modify-function>
3030 </modify-function>
3030
3031
3031 <modify-function signature="getItem(QWidget *, const QString &amp;, const QString &amp;, const QStringList&lt;QString&gt; &amp;, int, bool, bool *, QFlags&lt;Qt::WindowType&gt;)">
3032 <modify-function signature="getItem(QWidget *, const QString &amp;, const QString &amp;, const QStringList&lt;QString&gt; &amp;, int, bool, bool *, QFlags&lt;Qt::WindowType&gt;)">
3032 <!--
3033 <!--
3033 <rename to="getItem_internal"/>
3034 <rename to="getItem_internal"/>
3034 <access modifier="private"/>
3035 <access modifier="private"/>
3035 -->
3036 -->
3036 <modify-argument index="4">
3037 <modify-argument index="4">
3037 <remove-default-expression/>
3038 <remove-default-expression/>
3038 </modify-argument>
3039 </modify-argument>
3039 <modify-argument index="5">
3040 <modify-argument index="5">
3040 <remove-default-expression/>
3041 <remove-default-expression/>
3041 </modify-argument>
3042 </modify-argument>
3042 <modify-argument index="6">
3043 <modify-argument index="6">
3043 <remove-default-expression/>
3044 <remove-default-expression/>
3044 </modify-argument>
3045 </modify-argument>
3045 <modify-argument index="7">
3046 <modify-argument index="7">
3046 <remove-default-expression/>
3047 <remove-default-expression/>
3047 </modify-argument>
3048 </modify-argument>
3048 <modify-argument index="8">
3049 <modify-argument index="8">
3049 <remove-default-expression/>
3050 <remove-default-expression/>
3050 </modify-argument>
3051 </modify-argument>
3051 </modify-function>
3052 </modify-function>
3052
3053
3053 <modify-function signature="getText(QWidget *, const QString &amp;, const QString &amp;, QLineEdit::EchoMode, const QString &amp;, bool *, QFlags&lt;Qt::WindowType&gt;)">
3054 <modify-function signature="getText(QWidget *, const QString &amp;, const QString &amp;, QLineEdit::EchoMode, const QString &amp;, bool *, QFlags&lt;Qt::WindowType&gt;)">
3054 <!--
3055 <!--
3055 <rename to="getText_internal"/>
3056 <rename to="getText_internal"/>
3056 <access modifier="private"/>
3057 <access modifier="private"/>
3057 -->
3058 -->
3058 <modify-argument index="4">
3059 <modify-argument index="4">
3059 <remove-default-expression/>
3060 <remove-default-expression/>
3060 </modify-argument>
3061 </modify-argument>
3061 <modify-argument index="5">
3062 <modify-argument index="5">
3062 <remove-default-expression/>
3063 <remove-default-expression/>
3063 </modify-argument>
3064 </modify-argument>
3064 <modify-argument index="6">
3065 <modify-argument index="6">
3065 <remove-default-expression/>
3066 <remove-default-expression/>
3066 </modify-argument>
3067 </modify-argument>
3067 <modify-argument index="7">
3068 <modify-argument index="7">
3068 <remove-default-expression/>
3069 <remove-default-expression/>
3069 </modify-argument>
3070 </modify-argument>
3070 </modify-function>
3071 </modify-function>
3071
3072
3072 <inject-code class="native" position="beginning">
3073 <inject-code class="native" position="beginning">
3073 Q_DECLARE_METATYPE(QScriptValue)
3074 Q_DECLARE_METATYPE(QScriptValue)
3074 </inject-code>
3075 </inject-code>
3075 <modify-function signature="getDouble(QWidget *, const QString &amp;, const QString &amp;, double, double, double, int, bool *, QFlags&lt;Qt::WindowType&gt;)">
3076 <modify-function signature="getDouble(QWidget *, const QString &amp;, const QString &amp;, double, double, double, int, bool *, QFlags&lt;Qt::WindowType&gt;)">
3076 <modify-argument index="8">
3077 <modify-argument index="8">
3077 <remove-argument/>
3078 <remove-argument/>
3078 <conversion-rule class="native">
3079 <conversion-rule class="native">
3079 <insert-template name="core.prepare_removed_bool*_argument"/>
3080 <insert-template name="core.prepare_removed_bool*_argument"/>
3080 </conversion-rule>
3081 </conversion-rule>
3081 </modify-argument>
3082 </modify-argument>
3082 <modify-argument index="return">
3083 <modify-argument index="return">
3083 <conversion-rule class="native">
3084 <conversion-rule class="native">
3084 <insert-template name="core.convert_to_null_or_primitive"/>
3085 <insert-template name="core.convert_to_null_or_primitive"/>
3085 </conversion-rule>
3086 </conversion-rule>
3086 </modify-argument>
3087 </modify-argument>
3087 </modify-function>
3088 </modify-function>
3088
3089
3089 <modify-function signature="getInteger(QWidget *, const QString &amp;, const QString &amp;, int, int, int, int, bool *, QFlags&lt;Qt::WindowType&gt;)">
3090 <modify-function signature="getInteger(QWidget *, const QString &amp;, const QString &amp;, int, int, int, int, bool *, QFlags&lt;Qt::WindowType&gt;)">
3090 <modify-argument index="8">
3091 <modify-argument index="8">
3091 <remove-argument/>
3092 <remove-argument/>
3092 <conversion-rule class="native">
3093 <conversion-rule class="native">
3093 <insert-template name="core.prepare_removed_bool*_argument"/>
3094 <insert-template name="core.prepare_removed_bool*_argument"/>
3094 </conversion-rule>
3095 </conversion-rule>
3095 </modify-argument>
3096 </modify-argument>
3096 <modify-argument index="return">
3097 <modify-argument index="return">
3097 <conversion-rule class="native">
3098 <conversion-rule class="native">
3098 <insert-template name="core.convert_to_null_or_primitive"/>
3099 <insert-template name="core.convert_to_null_or_primitive"/>
3099 </conversion-rule>
3100 </conversion-rule>
3100 </modify-argument>
3101 </modify-argument>
3101 </modify-function>
3102 </modify-function>
3102
3103
3103 <modify-function signature="getItem(QWidget *, const QString &amp;, const QString &amp;, const QStringList&lt;QString&gt; &amp;, int, bool, bool *, QFlags&lt;Qt::WindowType&gt;)">
3104 <modify-function signature="getItem(QWidget *, const QString &amp;, const QString &amp;, const QStringList&lt;QString&gt; &amp;, int, bool, bool *, QFlags&lt;Qt::WindowType&gt;)">
3104 <modify-argument index="7">
3105 <modify-argument index="7">
3105 <remove-argument/>
3106 <remove-argument/>
3106 <conversion-rule class="native">
3107 <conversion-rule class="native">
3107 <insert-template name="core.prepare_removed_bool*_argument"/>
3108 <insert-template name="core.prepare_removed_bool*_argument"/>
3108 </conversion-rule>
3109 </conversion-rule>
3109 </modify-argument>
3110 </modify-argument>
3110 <modify-argument index="return">
3111 <modify-argument index="return">
3111 <conversion-rule class="native">
3112 <conversion-rule class="native">
3112 <insert-template name="core.convert_to_null_or_primitive"/>
3113 <insert-template name="core.convert_to_null_or_primitive"/>
3113 </conversion-rule>
3114 </conversion-rule>
3114 </modify-argument>
3115 </modify-argument>
3115 </modify-function>
3116 </modify-function>
3116
3117
3117 <modify-function signature="getText(QWidget *, const QString &amp;, const QString &amp;, QLineEdit::EchoMode, const QString &amp;, bool *, QFlags&lt;Qt::WindowType&gt;)">
3118 <modify-function signature="getText(QWidget *, const QString &amp;, const QString &amp;, QLineEdit::EchoMode, const QString &amp;, bool *, QFlags&lt;Qt::WindowType&gt;)">
3118 <modify-argument index="6">
3119 <modify-argument index="6">
3119 <remove-argument/>
3120 <remove-argument/>
3120 <conversion-rule class="native">
3121 <conversion-rule class="native">
3121 <insert-template name="core.prepare_removed_bool*_argument"/>
3122 <insert-template name="core.prepare_removed_bool*_argument"/>
3122 </conversion-rule>
3123 </conversion-rule>
3123 </modify-argument>
3124 </modify-argument>
3124 <modify-argument index="return">
3125 <modify-argument index="return">
3125 <conversion-rule class="native">
3126 <conversion-rule class="native">
3126 <insert-template name="core.convert_to_null_or_primitive"/>
3127 <insert-template name="core.convert_to_null_or_primitive"/>
3127 </conversion-rule>
3128 </conversion-rule>
3128 </modify-argument>
3129 </modify-argument>
3129 </modify-function>
3130 </modify-function>
3130 </object-type>
3131 </object-type>
3131
3132
3132
3133
3133 <object-type name="QGraphicsScene">
3134 <object-type name="QGraphicsScene">
3134 <extra-includes>
3135 <extra-includes>
3135 <include file-name="QVarLengthArray" location="global"/>
3136 <include file-name="QVarLengthArray" location="global"/>
3136 </extra-includes>
3137 </extra-includes>
3137
3138
3138 <modify-function signature="contextMenuEvent(QGraphicsSceneContextMenuEvent*)">
3139 <modify-function signature="contextMenuEvent(QGraphicsSceneContextMenuEvent*)">
3139 <modify-argument index="1" invalidate-after-use="yes"/>
3140 <modify-argument index="1" invalidate-after-use="yes"/>
3140 </modify-function>
3141 </modify-function>
3141 <modify-function signature="dragEnterEvent(QGraphicsSceneDragDropEvent*)">
3142 <modify-function signature="dragEnterEvent(QGraphicsSceneDragDropEvent*)">
3142 <modify-argument index="1" invalidate-after-use="yes"/>
3143 <modify-argument index="1" invalidate-after-use="yes"/>
3143 </modify-function>
3144 </modify-function>
3144 <modify-function signature="dragLeaveEvent(QGraphicsSceneDragDropEvent*)">
3145 <modify-function signature="dragLeaveEvent(QGraphicsSceneDragDropEvent*)">
3145 <modify-argument index="1" invalidate-after-use="yes"/>
3146 <modify-argument index="1" invalidate-after-use="yes"/>
3146 </modify-function>
3147 </modify-function>
3147 <modify-function signature="dragMoveEvent(QGraphicsSceneDragDropEvent*)">
3148 <modify-function signature="dragMoveEvent(QGraphicsSceneDragDropEvent*)">
3148 <modify-argument index="1" invalidate-after-use="yes"/>
3149 <modify-argument index="1" invalidate-after-use="yes"/>
3149 </modify-function>
3150 </modify-function>
3150 <modify-function signature="drawBackground(QPainter*,QRectF)">
3151 <modify-function signature="drawBackground(QPainter*,QRectF)">
3151 <modify-argument index="1" invalidate-after-use="yes"/>
3152 <modify-argument index="1" invalidate-after-use="yes"/>
3152 </modify-function>
3153 </modify-function>
3153 <modify-function signature="drawForeground(QPainter*,QRectF)">
3154 <modify-function signature="drawForeground(QPainter*,QRectF)">
3154 <modify-argument index="1" invalidate-after-use="yes"/>
3155 <modify-argument index="1" invalidate-after-use="yes"/>
3155 </modify-function>
3156 </modify-function>
3156 <modify-function signature="drawItems(QPainter*,int,QGraphicsItem**,const QStyleOptionGraphicsItem*,QWidget*)">
3157 <modify-function signature="drawItems(QPainter*,int,QGraphicsItem**,const QStyleOptionGraphicsItem*,QWidget*)">
3157 <modify-argument index="1" invalidate-after-use="yes"/>
3158 <modify-argument index="1" invalidate-after-use="yes"/>
3158 </modify-function>
3159 </modify-function>
3159 <modify-function signature="dropEvent(QGraphicsSceneDragDropEvent*)">
3160 <modify-function signature="dropEvent(QGraphicsSceneDragDropEvent*)">
3160 <modify-argument index="1" invalidate-after-use="yes"/>
3161 <modify-argument index="1" invalidate-after-use="yes"/>
3161 </modify-function>
3162 </modify-function>
3162 <modify-function signature="focusInEvent(QFocusEvent*)">
3163 <modify-function signature="focusInEvent(QFocusEvent*)">
3163 <modify-argument index="1" invalidate-after-use="yes"/>
3164 <modify-argument index="1" invalidate-after-use="yes"/>
3164 </modify-function>
3165 </modify-function>
3165 <modify-function signature="focusOutEvent(QFocusEvent*)">
3166 <modify-function signature="focusOutEvent(QFocusEvent*)">
3166 <modify-argument index="1" invalidate-after-use="yes"/>
3167 <modify-argument index="1" invalidate-after-use="yes"/>
3167 </modify-function>
3168 </modify-function>
3168 <modify-function signature="helpEvent(QGraphicsSceneHelpEvent*)">
3169 <modify-function signature="helpEvent(QGraphicsSceneHelpEvent*)">
3169 <modify-argument index="1" invalidate-after-use="yes"/>
3170 <modify-argument index="1" invalidate-after-use="yes"/>
3170 </modify-function>
3171 </modify-function>
3171 <modify-function signature="inputMethodEvent(QInputMethodEvent*)">
3172 <modify-function signature="inputMethodEvent(QInputMethodEvent*)">
3172 <modify-argument index="1" invalidate-after-use="yes"/>
3173 <modify-argument index="1" invalidate-after-use="yes"/>
3173 </modify-function>
3174 </modify-function>
3174 <modify-function signature="keyPressEvent(QKeyEvent*)">
3175 <modify-function signature="keyPressEvent(QKeyEvent*)">
3175 <modify-argument index="1" invalidate-after-use="yes"/>
3176 <modify-argument index="1" invalidate-after-use="yes"/>
3176 </modify-function>
3177 </modify-function>
3177 <modify-function signature="keyReleaseEvent(QKeyEvent*)">
3178 <modify-function signature="keyReleaseEvent(QKeyEvent*)">
3178 <modify-argument index="1" invalidate-after-use="yes"/>
3179 <modify-argument index="1" invalidate-after-use="yes"/>
3179 </modify-function>
3180 </modify-function>
3180 <modify-function signature="mouseDoubleClickEvent(QGraphicsSceneMouseEvent*)">
3181 <modify-function signature="mouseDoubleClickEvent(QGraphicsSceneMouseEvent*)">
3181 <modify-argument index="1" invalidate-after-use="yes"/>
3182 <modify-argument index="1" invalidate-after-use="yes"/>
3182 </modify-function>
3183 </modify-function>
3183 <modify-function signature="mouseMoveEvent(QGraphicsSceneMouseEvent*)">
3184 <modify-function signature="mouseMoveEvent(QGraphicsSceneMouseEvent*)">
3184 <modify-argument index="1" invalidate-after-use="yes"/>
3185 <modify-argument index="1" invalidate-after-use="yes"/>
3185 </modify-function>
3186 </modify-function>
3186 <modify-function signature="mousePressEvent(QGraphicsSceneMouseEvent*)">
3187 <modify-function signature="mousePressEvent(QGraphicsSceneMouseEvent*)">
3187 <modify-argument index="1" invalidate-after-use="yes"/>
3188 <modify-argument index="1" invalidate-after-use="yes"/>
3188 </modify-function>
3189 </modify-function>
3189 <modify-function signature="mouseReleaseEvent(QGraphicsSceneMouseEvent*)">
3190 <modify-function signature="mouseReleaseEvent(QGraphicsSceneMouseEvent*)">
3190 <modify-argument index="1" invalidate-after-use="yes"/>
3191 <modify-argument index="1" invalidate-after-use="yes"/>
3191 </modify-function>
3192 </modify-function>
3192 <modify-function signature="wheelEvent(QGraphicsSceneWheelEvent*)">
3193 <modify-function signature="wheelEvent(QGraphicsSceneWheelEvent*)">
3193 <modify-argument index="1" invalidate-after-use="yes"/>
3194 <modify-argument index="1" invalidate-after-use="yes"/>
3194 </modify-function>
3195 </modify-function>
3195
3196
3196 <modify-function signature="setActiveWindow(QGraphicsWidget*)">
3197 <modify-function signature="setActiveWindow(QGraphicsWidget*)">
3197 <modify-argument index="1">
3198 <modify-argument index="1">
3198 <reference-count action="ignore"/>
3199 <reference-count action="ignore"/>
3199 </modify-argument>
3200 </modify-argument>
3200 </modify-function>
3201 </modify-function>
3201 <modify-function signature="setStyle(QStyle*)">
3202 <modify-function signature="setStyle(QStyle*)">
3202 <modify-argument index="1">
3203 <modify-argument index="1">
3203 <reference-count action="ignore"/>
3204 <reference-count action="ignore"/>
3204 </modify-argument>
3205 </modify-argument>
3205 </modify-function>
3206 </modify-function>
3206
3207
3207 <modify-function signature="addItem(QGraphicsItem *)">
3208 <modify-function signature="addItem(QGraphicsItem *)">
3208 <modify-argument index="1">
3209 <modify-argument index="1">
3209 <define-ownership class="java" owner="c++"/>
3210 <define-ownership class="java" owner="c++"/>
3210 </modify-argument>
3211 </modify-argument>
3211 </modify-function>
3212 </modify-function>
3212 <modify-function signature="addEllipse(const QRectF &amp;, const QPen &amp;, const QBrush &amp;)">
3213 <modify-function signature="addEllipse(const QRectF &amp;, const QPen &amp;, const QBrush &amp;)">
3213 <modify-argument index="return">
3214 <modify-argument index="return">
3214 <define-ownership class="java" owner="c++"/>
3215 <define-ownership class="java" owner="c++"/>
3215 </modify-argument>
3216 </modify-argument>
3216 </modify-function>
3217 </modify-function>
3217 <modify-function signature="addLine(const QLineF &amp;, const QPen &amp;)">
3218 <modify-function signature="addLine(const QLineF &amp;, const QPen &amp;)">
3218 <modify-argument index="return">
3219 <modify-argument index="return">
3219 <define-ownership class="java" owner="c++"/>
3220 <define-ownership class="java" owner="c++"/>
3220 </modify-argument>
3221 </modify-argument>
3221 </modify-function>
3222 </modify-function>
3222 <modify-function signature="addPath(const QPainterPath &amp;, const QPen &amp;, const QBrush &amp;)">
3223 <modify-function signature="addPath(const QPainterPath &amp;, const QPen &amp;, const QBrush &amp;)">
3223 <modify-argument index="return">
3224 <modify-argument index="return">
3224 <define-ownership class="java" owner="c++"/>
3225 <define-ownership class="java" owner="c++"/>
3225 </modify-argument>
3226 </modify-argument>
3226 </modify-function>
3227 </modify-function>
3227 <modify-function signature="addPixmap(const QPixmap &amp;)">
3228 <modify-function signature="addPixmap(const QPixmap &amp;)">
3228 <modify-argument index="return">
3229 <modify-argument index="return">
3229 <define-ownership class="java" owner="c++"/>
3230 <define-ownership class="java" owner="c++"/>
3230 </modify-argument>
3231 </modify-argument>
3231 </modify-function>
3232 </modify-function>
3232 <modify-function signature="addPolygon(const QPolygonF &amp;, const QPen &amp;, const QBrush &amp;)">
3233 <modify-function signature="addPolygon(const QPolygonF &amp;, const QPen &amp;, const QBrush &amp;)">
3233 <modify-argument index="return">
3234 <modify-argument index="return">
3234 <define-ownership class="java" owner="c++"/>
3235 <define-ownership class="java" owner="c++"/>
3235 </modify-argument>
3236 </modify-argument>
3236 </modify-function>
3237 </modify-function>
3237 <modify-function signature="addRect(const QRectF &amp;, const QPen &amp;, const QBrush &amp;)">
3238 <modify-function signature="addRect(const QRectF &amp;, const QPen &amp;, const QBrush &amp;)">
3238 <modify-argument index="return">
3239 <modify-argument index="return">
3239 <define-ownership class="java" owner="c++"/>
3240 <define-ownership class="java" owner="c++"/>
3240 </modify-argument>
3241 </modify-argument>
3241 </modify-function>
3242 </modify-function>
3242 <modify-function signature="addText(const QString &amp;, const QFont &amp;)">
3243 <modify-function signature="addText(const QString &amp;, const QFont &amp;)">
3243 <modify-argument index="return">
3244 <modify-argument index="return">
3244 <define-ownership class="java" owner="c++"/>
3245 <define-ownership class="java" owner="c++"/>
3245 </modify-argument>
3246 </modify-argument>
3246 </modify-function>
3247 </modify-function>
3247 <modify-function signature="addWidget(QWidget*,QFlags&lt;Qt::WindowType&gt;)">
3248 <modify-function signature="addWidget(QWidget*,QFlags&lt;Qt::WindowType&gt;)">
3248 <modify-argument index="return">
3249 <modify-argument index="return">
3249 <define-ownership class="java" owner="c++"/>
3250 <define-ownership class="java" owner="c++"/>
3250 </modify-argument>
3251 </modify-argument>
3251 <modify-argument index="1">
3252 <modify-argument index="1">
3252 <define-ownership class="java" owner="c++"/>
3253 <define-ownership class="java" owner="c++"/>
3253 </modify-argument>
3254 </modify-argument>
3254 </modify-function>
3255 </modify-function>
3255 <modify-function signature="removeItem(QGraphicsItem*)">
3256 <modify-function signature="removeItem(QGraphicsItem*)">
3256 <modify-argument index="1">
3257 <modify-argument index="1">
3257 <define-ownership class="java" owner="default"/>
3258 <define-ownership class="java" owner="default"/>
3258 </modify-argument>
3259 </modify-argument>
3259 </modify-function>
3260 </modify-function>
3260 <modify-function signature="setFocusItem(QGraphicsItem*,Qt::FocusReason)">
3261 <modify-function signature="setFocusItem(QGraphicsItem*,Qt::FocusReason)">
3261 <modify-argument index="1">
3262 <modify-argument index="1">
3262 <reference-count action="set" variable-name="__rcFocusItem"/>
3263 <reference-count action="set" variable-name="__rcFocusItem"/>
3263 </modify-argument>
3264 </modify-argument>
3264 </modify-function>
3265 </modify-function>
3265
3266
3266 <modify-function signature="addWidget(QWidget*,QFlags&lt;Qt::WindowType&gt;)">
3267 <modify-function signature="addWidget(QWidget*,QFlags&lt;Qt::WindowType&gt;)">
3267 <modify-argument index="1">
3268 <modify-argument index="1">
3268 <conversion-rule class="native">
3269 <conversion-rule class="native">
3269 QScriptValue %out%_orig = %in%;
3270 QScriptValue %out%_orig = %in%;
3270 QWidget* %out% = qscriptvalue_cast&lt;QWidget*&gt;(%out%_orig);
3271 QWidget* %out% = qscriptvalue_cast&lt;QWidget*&gt;(%out%_orig);
3271 if (%out% != 0)
3272 if (%out% != 0)
3272 context-&gt;engine()-&gt;newQObject(%out%_orig, %out%, QScriptEngine::QtOwnership);
3273 context-&gt;engine()-&gt;newQObject(%out%_orig, %out%, QScriptEngine::QtOwnership);
3273 </conversion-rule>
3274 </conversion-rule>
3274 </modify-argument>
3275 </modify-argument>
3275 </modify-function>
3276 </modify-function>
3276 </object-type>
3277 </object-type>
3277
3278
3278
3279
3279 <object-type name="QCalendarWidget">
3280 <object-type name="QCalendarWidget">
3280 <extra-includes>
3281 <extra-includes>
3281 <include file-name="QTextCharFormat" location="global"/>
3282 <include file-name="QTextCharFormat" location="global"/>
3282 </extra-includes>
3283 </extra-includes>
3283
3284
3284 <modify-function signature="isHeaderVisible()const" remove="all"/> <!--### Obsolete in 4.3-->
3285 <modify-function signature="isHeaderVisible()const" remove="all"/> <!--### Obsolete in 4.3-->
3285 <modify-function signature="setHeaderVisible(bool)" remove="all"/> <!--### Obsolete in 4.3-->
3286 <modify-function signature="setHeaderVisible(bool)" remove="all"/> <!--### Obsolete in 4.3-->
3286
3287
3287 <modify-function signature="paintCell(QPainter*,QRect,QDate)const">
3288 <modify-function signature="paintCell(QPainter*,QRect,QDate)const">
3288 <modify-argument invalidate-after-use="yes" index="1"/>
3289 <modify-argument invalidate-after-use="yes" index="1"/>
3289 </modify-function>
3290 </modify-function>
3290
3291
3291 <modify-function signature="sizeHint()const" rename="getSizeHint"/>
3292 <modify-function signature="sizeHint()const" rename="getSizeHint"/>
3292 <modify-function signature="minimumSizeHint()const" rename="getMinimumSizeHint"/>
3293 <modify-function signature="minimumSizeHint()const" rename="getMinimumSizeHint"/>
3293 </object-type>
3294 </object-type>
3294
3295
3295 <object-type name="QTreeWidget">
3296 <object-type name="QTreeWidget">
3296 <modify-function signature="setSelectionModel(QItemSelectionModel*)">
3297 <modify-function signature="setSelectionModel(QItemSelectionModel*)">
3297 <modify-argument index="1">
3298 <modify-argument index="1">
3298 <no-null-pointer/>
3299 <no-null-pointer/>
3299 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemSelectionModel"/>
3300 <reference-count declare-variable="QAbstractItemView" action="set" variable-name="__rcItemSelectionModel"/>
3300 </modify-argument>
3301 </modify-argument>
3301 </modify-function>
3302 </modify-function>
3302 <modify-function signature="removeItemWidget(QTreeWidgetItem*,int)">
3303 <modify-function signature="removeItemWidget(QTreeWidgetItem*,int)">
3303 <modify-argument index="1">
3304 <modify-argument index="1">
3304 <reference-count action="ignore"/>
3305 <reference-count action="ignore"/>
3305 </modify-argument>
3306 </modify-argument>
3306 </modify-function>
3307 </modify-function>
3307 <modify-function signature="mimeData(const QList&lt;QTreeWidgetItem*&gt;)const">
3308 <modify-function signature="mimeData(const QList&lt;QTreeWidgetItem*&gt;)const">
3308 <modify-argument index="1" invalidate-after-use="yes"/>
3309 <modify-argument index="1" invalidate-after-use="yes"/>
3309 </modify-function>
3310 </modify-function>
3310 <modify-function signature="dropMimeData(QTreeWidgetItem*,int,const QMimeData*,Qt::DropAction)">
3311 <modify-function signature="dropMimeData(QTreeWidgetItem*,int,const QMimeData*,Qt::DropAction)">
3311 <modify-argument index="1" invalidate-after-use="yes"/>
3312 <modify-argument index="1" invalidate-after-use="yes"/>
3312 </modify-function>
3313 </modify-function>
3313 <modify-function signature="isSortingEnabled()const" remove="all"/>
3314 <modify-function signature="isSortingEnabled()const" remove="all"/>
3314 <modify-function signature="setSortingEnabled(bool)" remove="all"/>
3315 <modify-function signature="setSortingEnabled(bool)" remove="all"/>
3315 <modify-function signature="indexOfTopLevelItem(QTreeWidgetItem *)">
3316 <modify-function signature="indexOfTopLevelItem(QTreeWidgetItem *)">
3316 <remove/>
3317 <remove/>
3317 </modify-function>
3318 </modify-function>
3318 <modify-function signature="addTopLevelItem(QTreeWidgetItem *)">
3319 <modify-function signature="addTopLevelItem(QTreeWidgetItem *)">
3319 <modify-argument index="1">
3320 <modify-argument index="1">
3320 <define-ownership class="java" owner="c++"/>
3321 <define-ownership class="java" owner="c++"/>
3321 </modify-argument>
3322 </modify-argument>
3322 </modify-function>
3323 </modify-function>
3323 <modify-function signature="takeTopLevelItem(int)">
3324 <modify-function signature="takeTopLevelItem(int)">
3324 <modify-argument index="return">
3325 <modify-argument index="return">
3325 <define-ownership class="java" owner="default"/>
3326 <define-ownership class="java" owner="default"/>
3326 </modify-argument>
3327 </modify-argument>
3327 </modify-function>
3328 </modify-function>
3328 <modify-function signature="addTopLevelItems(const QList&lt;QTreeWidgetItem*&gt; &amp;)">
3329 <modify-function signature="addTopLevelItems(const QList&lt;QTreeWidgetItem*&gt; &amp;)">
3329 <modify-argument index="1">
3330 <modify-argument index="1">
3330 <define-ownership class="java" owner="c++"/>
3331 <define-ownership class="java" owner="c++"/>
3331 </modify-argument>
3332 </modify-argument>
3332 </modify-function>
3333 </modify-function>
3333 <modify-function signature="insertTopLevelItem(int, QTreeWidgetItem *)">
3334 <modify-function signature="insertTopLevelItem(int, QTreeWidgetItem *)">
3334 <modify-argument index="2">
3335 <modify-argument index="2">
3335 <define-ownership class="java" owner="c++"/>
3336 <define-ownership class="java" owner="c++"/>
3336 </modify-argument>
3337 </modify-argument>
3337 </modify-function>
3338 </modify-function>
3338 <modify-function signature="insertTopLevelItems(int, const QList&lt;QTreeWidgetItem*&gt; &amp;)">
3339 <modify-function signature="insertTopLevelItems(int, const QList&lt;QTreeWidgetItem*&gt; &amp;)">
3339 <modify-argument index="2">
3340 <modify-argument index="2">
3340 <define-ownership class="java" owner="c++"/>
3341 <define-ownership class="java" owner="c++"/>
3341 </modify-argument>
3342 </modify-argument>
3342 </modify-function>
3343 </modify-function>
3343 <modify-function signature="setHeaderItem(QTreeWidgetItem *)">
3344 <modify-function signature="setHeaderItem(QTreeWidgetItem *)">
3344 <modify-argument index="1">
3345 <modify-argument index="1">
3345 <define-ownership class="java" owner="c++"/>
3346 <define-ownership class="java" owner="c++"/>
3346 </modify-argument>
3347 </modify-argument>
3347 </modify-function>
3348 </modify-function>
3348 <modify-function signature="takeTopLevelItem(int)">
3349 <modify-function signature="takeTopLevelItem(int)">
3349 <modify-argument index="return">
3350 <modify-argument index="return">
3350 <define-ownership class="java" owner="default"/>
3351 <define-ownership class="java" owner="default"/>
3351 </modify-argument>
3352 </modify-argument>
3352 </modify-function>
3353 </modify-function>
3353 <modify-function signature="setCurrentItem(QTreeWidgetItem*,int,QFlags&lt;QItemSelectionModel::SelectionFlag&gt;)">
3354 <modify-function signature="setCurrentItem(QTreeWidgetItem*,int,QFlags&lt;QItemSelectionModel::SelectionFlag&gt;)">
3354 <modify-argument index="1">
3355 <modify-argument index="1">
3355 <reference-count action="ignore"/>
3356 <reference-count action="ignore"/>
3356 </modify-argument>
3357 </modify-argument>
3357 </modify-function>
3358 </modify-function>
3358 <modify-function signature="setFirstItemColumnSpanned(const QTreeWidgetItem*,bool)">
3359 <modify-function signature="setFirstItemColumnSpanned(const QTreeWidgetItem*,bool)">
3359 <modify-argument index="1">
3360 <modify-argument index="1">
3360 <reference-count action="ignore"/>
3361 <reference-count action="ignore"/>
3361 </modify-argument>
3362 </modify-argument>
3362 </modify-function>
3363 </modify-function>
3363 <modify-function signature="setCurrentItem(QTreeWidgetItem*)">
3364 <modify-function signature="setCurrentItem(QTreeWidgetItem*)">
3364 <modify-argument index="1">
3365 <modify-argument index="1">
3365 <reference-count action="ignore"/>
3366 <reference-count action="ignore"/>
3366 </modify-argument>
3367 </modify-argument>
3367 </modify-function>
3368 </modify-function>
3368 <modify-function signature="setCurrentItem(QTreeWidgetItem*,int)">
3369 <modify-function signature="setCurrentItem(QTreeWidgetItem*,int)">
3369 <modify-argument index="1">
3370 <modify-argument index="1">
3370 <reference-count action="ignore"/>
3371 <reference-count action="ignore"/>
3371 </modify-argument>
3372 </modify-argument>
3372 </modify-function>
3373 </modify-function>
3373 <modify-function signature="setItemExpanded(const QTreeWidgetItem*,bool)">
3374 <modify-function signature="setItemExpanded(const QTreeWidgetItem*,bool)">
3374 <remove/>
3375 <remove/>
3375 </modify-function>
3376 </modify-function>
3376 <modify-function signature="isItemExpanded(const QTreeWidgetItem*)const">
3377 <modify-function signature="isItemExpanded(const QTreeWidgetItem*)const">
3377 <remove/>
3378 <remove/>
3378 </modify-function>
3379 </modify-function>
3379 <modify-function signature="setItemHidden(const QTreeWidgetItem*,bool)">
3380 <modify-function signature="setItemHidden(const QTreeWidgetItem*,bool)">
3380 <remove/>
3381 <remove/>
3381 </modify-function>
3382 </modify-function>
3382 <modify-function signature="isItemHidden(const QTreeWidgetItem*)const">
3383 <modify-function signature="isItemHidden(const QTreeWidgetItem*)const">
3383 <remove/>
3384 <remove/>
3384 </modify-function>
3385 </modify-function>
3385 <modify-function signature="isItemSelected(const QTreeWidgetItem*)const">
3386 <modify-function signature="isItemSelected(const QTreeWidgetItem*)const">
3386 <remove/>
3387 <remove/>
3387 </modify-function>
3388 </modify-function>
3388 <modify-function signature="setItemSelected(const QTreeWidgetItem*,bool)">
3389 <modify-function signature="setItemSelected(const QTreeWidgetItem*,bool)">
3389 <remove/>
3390 <remove/>
3390 </modify-function>
3391 </modify-function>
3391 <modify-function signature="setItemWidget(QTreeWidgetItem*,int,QWidget*)">
3392 <modify-function signature="setItemWidget(QTreeWidgetItem*,int,QWidget*)">
3392 <modify-argument index="1">
3393 <modify-argument index="1">
3393 <reference-count action="ignore"/>
3394 <reference-count action="ignore"/>
3394 </modify-argument>
3395 </modify-argument>
3395 <modify-argument index="3">
3396 <modify-argument index="3">
3396 <reference-count action="ignore"/>
3397 <reference-count action="ignore"/>
3397 </modify-argument>
3398 </modify-argument>
3398 </modify-function>
3399 </modify-function>
3399 <modify-function signature="setModel(QAbstractItemModel*)">
3400 <modify-function signature="setModel(QAbstractItemModel*)">
3400 <modify-argument index="1">
3401 <modify-argument index="1">
3401 <reference-count action="ignore"/>
3402 <reference-count action="ignore"/>
3402 </modify-argument>
3403 </modify-argument>
3403 </modify-function>
3404 </modify-function>
3404
3405
3405 <modify-function signature="items(const QMimeData*)const" remove="all"/> <!--### Obsolete in 4.3-->
3406 <modify-function signature="items(const QMimeData*)const" remove="all"/> <!--### Obsolete in 4.3-->
3406
3407
3407 <modify-function signature="mimeData(const QList&lt;QTreeWidgetItem*&gt;)const" remove="all"/>
3408 <modify-function signature="mimeData(const QList&lt;QTreeWidgetItem*&gt;)const" remove="all"/>
3408 </object-type>
3409 </object-type>
3409
3410
3410 <object-type name="QAbstractItemDelegate">
3411 <object-type name="QAbstractItemDelegate">
3411 <modify-function signature="setEditorData(QWidget*,QModelIndex)const">
3412 <modify-function signature="setEditorData(QWidget*,QModelIndex)const">
3412 <modify-argument index="1">
3413 <modify-argument index="1">
3413 <!-- Safe to ignore because this implementation is documented to do nothing -->
3414 <!-- Safe to ignore because this implementation is documented to do nothing -->
3414 <reference-count action="ignore"/>
3415 <reference-count action="ignore"/>
3415 </modify-argument>
3416 </modify-argument>
3416 </modify-function>
3417 </modify-function>
3417 <modify-function signature="setModelData(QWidget*,QAbstractItemModel*,QModelIndex)const">
3418 <modify-function signature="setModelData(QWidget*,QAbstractItemModel*,QModelIndex)const">
3418 <modify-argument index="1">
3419 <modify-argument index="1">
3419 <reference-count action="ignore"/>
3420 <reference-count action="ignore"/>
3420 </modify-argument>
3421 </modify-argument>
3421 <modify-argument index="2">
3422 <modify-argument index="2">
3422 <reference-count action="ignore"/>
3423 <reference-count action="ignore"/>
3423 </modify-argument>
3424 </modify-argument>
3424 </modify-function>
3425 </modify-function>
3425
3426
3426 <modify-function signature="paint(QPainter*,QStyleOptionViewItem,QModelIndex)const">
3427 <modify-function signature="paint(QPainter*,QStyleOptionViewItem,QModelIndex)const">
3427 <modify-argument index="1" invalidate-after-use="yes"/>
3428 <modify-argument index="1" invalidate-after-use="yes"/>
3428 </modify-function>
3429 </modify-function>
3429 <modify-function signature="editorEvent(QEvent*,QAbstractItemModel*,QStyleOptionViewItem,QModelIndex)">
3430 <modify-function signature="editorEvent(QEvent*,QAbstractItemModel*,QStyleOptionViewItem,QModelIndex)">
3430 <modify-argument index="1" invalidate-after-use="yes"/>
3431 <modify-argument index="1" invalidate-after-use="yes"/>
3431 </modify-function>
3432 </modify-function>
3432
3433
3433 <modify-function signature="elidedText(QFontMetrics, int, Qt::TextElideMode, QString)" remove="all"/> <!--### Obsolete in 4.3-->
3434 <modify-function signature="elidedText(QFontMetrics, int, Qt::TextElideMode, QString)" remove="all"/> <!--### Obsolete in 4.3-->
3434 </object-type>
3435 </object-type>
3435
3436
3436 <object-type name="QTableWidgetItem" delete-in-main-thread="yes">
3437 <object-type name="QTableWidgetItem" delete-in-main-thread="yes">
3437 <modify-function signature="operator=(const QTableWidgetItem&amp;)" remove="all"/>
3438 <modify-function signature="operator=(const QTableWidgetItem&amp;)" remove="all"/>
3438 <modify-function signature="clone() const">
3439 <modify-function signature="clone() const">
3439 <modify-argument index="return">
3440 <modify-argument index="return">
3440 <define-ownership class="shell" owner="c++"/>
3441 <define-ownership class="shell" owner="c++"/>
3441 </modify-argument>
3442 </modify-argument>
3442 </modify-function>
3443 </modify-function>
3443
3444
3444 <modify-function signature="backgroundColor()const" remove="all"/> <!--### Obsolete in 4.3-->
3445 <modify-function signature="backgroundColor()const" remove="all"/> <!--### Obsolete in 4.3-->
3445 <modify-function signature="setBackgroundColor(QColor)" remove="all"/> <!--### Obsolete in 4.3-->
3446 <modify-function signature="setBackgroundColor(QColor)" remove="all"/> <!--### Obsolete in 4.3-->
3446 <modify-function signature="setTextColor(QColor)" remove="all"/> <!--### Obsolete in 4.3-->
3447 <modify-function signature="setTextColor(QColor)" remove="all"/> <!--### Obsolete in 4.3-->
3447 <modify-function signature="textColor()const" remove="all"/> <!--### Obsolete in 4.3-->
3448 <modify-function signature="textColor()const" remove="all"/> <!--### Obsolete in 4.3-->
3448
3449
3449 <modify-function signature="operator&lt;(QTableWidgetItem)const">
3450 <modify-function signature="operator&lt;(QTableWidgetItem)const">
3450 <modify-argument index="1" invalidate-after-use="yes"/>
3451 <modify-argument index="1" invalidate-after-use="yes"/>
3451 </modify-function>
3452 </modify-function>
3452 <modify-function signature="read(QDataStream&amp;)">
3453 <modify-function signature="read(QDataStream&amp;)">
3453 <modify-argument index="1" invalidate-after-use="yes"/>
3454 <modify-argument index="1" invalidate-after-use="yes"/>
3454 </modify-function>
3455 </modify-function>
3455 <modify-function signature="write(QDataStream&amp;)const">
3456 <modify-function signature="write(QDataStream&amp;)const">
3456 <modify-argument index="1" invalidate-after-use="yes"/>
3457 <modify-argument index="1" invalidate-after-use="yes"/>
3457 </modify-function>
3458 </modify-function>
3458
3459
3459
3460
3460 <modify-function signature="read(QDataStream &amp;)" remove="all"/>
3461 <modify-function signature="read(QDataStream &amp;)" remove="all"/>
3461 <modify-function signature="write(QDataStream &amp;)const" remove="all"/>
3462 <modify-function signature="write(QDataStream &amp;)const" remove="all"/>
3462 <modify-function signature="QTableWidgetItem(QTableWidgetItem)" remove="all"/>
3463 <modify-function signature="QTableWidgetItem(QTableWidgetItem)" remove="all"/>
3463 <modify-function signature="operator=(QTableWidgetItem)" remove="all"/>
3464 <modify-function signature="operator=(QTableWidgetItem)" remove="all"/>
3464 <modify-function signature="operator&lt;(QTableWidgetItem)const" remove="all"/>
3465 <modify-function signature="operator&lt;(QTableWidgetItem)const" remove="all"/>
3465 </object-type>
3466 </object-type>
3466
3467
3467 <object-type name="QListWidgetItem" delete-in-main-thread="yes">
3468 <object-type name="QListWidgetItem" delete-in-main-thread="yes">
3468
3469
3469 <modify-function signature="operator&lt;(QListWidgetItem)const">
3470 <modify-function signature="operator&lt;(QListWidgetItem)const">
3470 <modify-argument index="1" invalidate-after-use="yes"/>
3471 <modify-argument index="1" invalidate-after-use="yes"/>
3471 </modify-function>
3472 </modify-function>
3472 <modify-function signature="read(QDataStream&amp;)">
3473 <modify-function signature="read(QDataStream&amp;)">
3473 <modify-argument index="1" invalidate-after-use="yes"/>
3474 <modify-argument index="1" invalidate-after-use="yes"/>
3474 </modify-function>
3475 </modify-function>
3475 <modify-function signature="write(QDataStream&amp;)const">
3476 <modify-function signature="write(QDataStream&amp;)const">
3476 <modify-argument index="1" invalidate-after-use="yes"/>
3477 <modify-argument index="1" invalidate-after-use="yes"/>
3477 </modify-function>
3478 </modify-function>
3478
3479
3479
3480
3480 <modify-function signature="operator=(const QListWidgetItem&amp;)" remove="all"/>
3481 <modify-function signature="operator=(const QListWidgetItem&amp;)" remove="all"/>
3481 <modify-function signature="QListWidgetItem(QListWidget *, int)">
3482 <modify-function signature="QListWidgetItem(QListWidget *, int)">
3482 <modify-argument index="this">
3483 <modify-argument index="this">
3483 <define-ownership class="java" owner="c++"/>
3484 <define-ownership class="java" owner="c++"/>
3484 </modify-argument>
3485 </modify-argument>
3485 </modify-function>
3486 </modify-function>
3486 <modify-function signature="QListWidgetItem(const QString &amp;, QListWidget *, int)">
3487 <modify-function signature="QListWidgetItem(const QString &amp;, QListWidget *, int)">
3487 <modify-argument index="this">
3488 <modify-argument index="this">
3488 <define-ownership class="java" owner="c++"/>
3489 <define-ownership class="java" owner="c++"/>
3489 </modify-argument>
3490 </modify-argument>
3490 </modify-function>
3491 </modify-function>
3491 <modify-function signature="QListWidgetItem(const QIcon &amp;, const QString &amp;, QListWidget *, int)">
3492 <modify-function signature="QListWidgetItem(const QIcon &amp;, const QString &amp;, QListWidget *, int)">
3492 <modify-argument index="this">
3493 <modify-argument index="this">
3493 <define-ownership class="java" owner="c++"/>
3494 <define-ownership class="java" owner="c++"/>
3494 </modify-argument>
3495 </modify-argument>
3495 </modify-function>
3496 </modify-function>
3496 <modify-function signature="clone() const">
3497 <modify-function signature="clone() const">
3497 <modify-argument index="return">
3498 <modify-argument index="return">
3498 <define-ownership class="shell" owner="c++"/>
3499 <define-ownership class="shell" owner="c++"/>
3499 </modify-argument>
3500 </modify-argument>
3500 </modify-function>
3501 </modify-function>
3501
3502
3502 <modify-function signature="backgroundColor()const" remove="all"/> <!--### Obsolete in 4.3-->
3503 <modify-function signature="backgroundColor()const" remove="all"/> <!--### Obsolete in 4.3-->
3503 <modify-function signature="setBackgroundColor(QColor)" remove="all"/> <!--### Obsolete in 4.3-->
3504 <modify-function signature="setBackgroundColor(QColor)" remove="all"/> <!--### Obsolete in 4.3-->
3504 <modify-function signature="setTextColor(QColor)" remove="all"/> <!--### Obsolete in 4.3-->
3505 <modify-function signature="setTextColor(QColor)" remove="all"/> <!--### Obsolete in 4.3-->
3505 <modify-function signature="textColor()const" remove="all"/> <!--### Obsolete in 4.3-->
3506 <modify-function signature="textColor()const" remove="all"/> <!--### Obsolete in 4.3-->
3506
3507
3507 <modify-function signature="read(QDataStream &amp;)" remove="all"/>
3508 <modify-function signature="read(QDataStream &amp;)" remove="all"/>
3508 <modify-function signature="write(QDataStream &amp;)const" remove="all"/>
3509 <modify-function signature="write(QDataStream &amp;)const" remove="all"/>
3509 <modify-function signature="QListWidgetItem(QListWidgetItem)" remove="all"/>
3510 <modify-function signature="QListWidgetItem(QListWidgetItem)" remove="all"/>
3510 <modify-function signature="operator=(QListWidgetItem)" remove="all"/>
3511 <modify-function signature="operator=(QListWidgetItem)" remove="all"/>
3511 <modify-function signature="operator&lt;(QListWidgetItem)const" remove="all"/>
3512 <modify-function signature="operator&lt;(QListWidgetItem)const" remove="all"/>
3512 </object-type>
3513 </object-type>
3513
3514
3514 <object-type name="QGraphicsTextItem"> <!-- a QObject so main-thread delete redundant -->
3515 <object-type name="QGraphicsTextItem"> <!-- a QObject so main-thread delete redundant -->
3515 <extra-includes>
3516 <extra-includes>
3516 <include file-name="QTextCursor" location="global"/>
3517 <include file-name="QTextCursor" location="global"/>
3517 </extra-includes>
3518 </extra-includes>
3518 <modify-function signature="QGraphicsTextItem(QGraphicsItem*,QGraphicsScene*)">
3519 <modify-function signature="QGraphicsTextItem(QGraphicsItem*,QGraphicsScene*)">
3519 <inject-code position="end">
3520 <inject-code position="end">
3520 <argument-map index="1" meta-name="%1"/>
3521 <argument-map index="1" meta-name="%1"/>
3521 if (%1 != null) disableGarbageCollection();
3522 if (%1 != null) disableGarbageCollection();
3522 </inject-code>
3523 </inject-code>
3523 </modify-function>
3524 </modify-function>
3524 <modify-function signature="QGraphicsTextItem(const QString &amp;,QGraphicsItem*,QGraphicsScene*)">
3525 <modify-function signature="QGraphicsTextItem(const QString &amp;,QGraphicsItem*,QGraphicsScene*)">
3525 <inject-code position="end">
3526 <inject-code position="end">
3526 <argument-map index="2" meta-name="%2"/>
3527 <argument-map index="2" meta-name="%2"/>
3527 if (%2 != null) disableGarbageCollection();
3528 if (%2 != null) disableGarbageCollection();
3528 </inject-code>
3529 </inject-code>
3529 </modify-function>
3530 </modify-function>
3530 <modify-function signature="setDocument(QTextDocument*)">
3531 <modify-function signature="setDocument(QTextDocument*)">
3531 <modify-argument index="1">
3532 <modify-argument index="1">
3532 <reference-count action="set" variable-name="__rcDocument"/>
3533 <reference-count action="set" variable-name="__rcDocument"/>
3533 </modify-argument>
3534 </modify-argument>
3534 </modify-function>
3535 </modify-function>
3535
3536
3536 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
3537 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
3537 <modify-function signature="resetMatrix()" remove="all"/> <!--### Obsolete in 4.3-->
3538 <modify-function signature="resetMatrix()" remove="all"/> <!--### Obsolete in 4.3-->
3538 <modify-function signature="sceneMatrix()const" remove="all"/> <!--### Obsolete in 4.3-->
3539 <modify-function signature="sceneMatrix()const" remove="all"/> <!--### Obsolete in 4.3-->
3539 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
3540 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
3540 </object-type>
3541 </object-type>
3541
3542
3542 <object-type name="QCompleter">
3543 <object-type name="QCompleter">
3543 <modify-function signature="activated(const QModelIndex &amp;)">
3544 <modify-function signature="activated(const QModelIndex &amp;)">
3544 <rename to="activatedIndex"/>
3545 <rename to="activatedIndex"/>
3545 </modify-function>
3546 </modify-function>
3546 <modify-function signature="highlighted(const QModelIndex &amp;)">
3547 <modify-function signature="highlighted(const QModelIndex &amp;)">
3547 <rename to="highlightedIndex"/>
3548 <rename to="highlightedIndex"/>
3548 </modify-function>
3549 </modify-function>
3549 <modify-function signature="setModel(QAbstractItemModel *)">
3550 <modify-function signature="setModel(QAbstractItemModel *)">
3550 <modify-argument index="1">
3551 <modify-argument index="1">
3551 <reference-count action="set" variable-name="__rcModel"/>
3552 <reference-count action="set" variable-name="__rcModel"/>
3552 </modify-argument>
3553 </modify-argument>
3553 </modify-function>
3554 </modify-function>
3554 <modify-function signature="setPopup(QAbstractItemView *)">
3555 <modify-function signature="setPopup(QAbstractItemView *)">
3555 <modify-argument index="1">
3556 <modify-argument index="1">
3556 <no-null-pointer/>
3557 <no-null-pointer/>
3557 <define-ownership class="java" owner="c++"/>
3558 <define-ownership class="java" owner="c++"/>
3558 </modify-argument>
3559 </modify-argument>
3559 </modify-function>
3560 </modify-function>
3560 <modify-function signature="setWidget(QWidget *)">
3561 <modify-function signature="setWidget(QWidget *)">
3561 <modify-argument index="1">
3562 <modify-argument index="1">
3562 <reference-count action="set" variable-name="__rcWidget"/>
3563 <reference-count action="set" variable-name="__rcWidget"/>
3563 </modify-argument>
3564 </modify-argument>
3564 </modify-function>
3565 </modify-function>
3565 </object-type>
3566 </object-type>
3566
3567
3567
3568
3568 <object-type name="QTreeWidgetItem" delete-in-main-thread="yes">
3569 <object-type name="QTreeWidgetItem" delete-in-main-thread="yes">
3569
3570
3570 <modify-function signature="operator&lt;(QTreeWidgetItem)const">
3571 <modify-function signature="operator&lt;(QTreeWidgetItem)const">
3571 <modify-argument index="1" invalidate-after-use="yes"/>
3572 <modify-argument index="1" invalidate-after-use="yes"/>
3572 </modify-function>
3573 </modify-function>
3573 <modify-function signature="read(QDataStream&amp;)">
3574 <modify-function signature="read(QDataStream&amp;)">
3574 <modify-argument index="1" invalidate-after-use="yes"/>
3575 <modify-argument index="1" invalidate-after-use="yes"/>
3575 </modify-function>
3576 </modify-function>
3576 <modify-function signature="write(QDataStream&amp;)const">
3577 <modify-function signature="write(QDataStream&amp;)const">
3577 <modify-argument index="1" invalidate-after-use="yes"/>
3578 <modify-argument index="1" invalidate-after-use="yes"/>
3578 </modify-function>
3579 </modify-function>
3579
3580
3580 <modify-function signature="QTreeWidgetItem(const QTreeWidgetItem &amp;)" remove="all"/>
3581 <modify-function signature="QTreeWidgetItem(const QTreeWidgetItem &amp;)" remove="all"/>
3581 <modify-function signature="operator=(const QTreeWidgetItem&amp;)" remove="all"/>
3582 <modify-function signature="operator=(const QTreeWidgetItem&amp;)" remove="all"/>
3582
3583
3583 <modify-function signature="QTreeWidgetItem(QTreeWidget *,int)">
3584 <modify-function signature="QTreeWidgetItem(QTreeWidget *,int)">
3584 <modify-argument index="this">
3585 <modify-argument index="this">
3585 <define-ownership class="java" owner="c++"/>
3586 <define-ownership class="java" owner="c++"/>
3586 </modify-argument>
3587 </modify-argument>
3587 </modify-function>
3588 </modify-function>
3588 <modify-function signature="QTreeWidgetItem(QTreeWidget *,const QStringList&lt;QString&gt; &amp;,int)">
3589 <modify-function signature="QTreeWidgetItem(QTreeWidget *,const QStringList&lt;QString&gt; &amp;,int)">
3589 <modify-argument index="this">
3590 <modify-argument index="this">
3590 <define-ownership class="java" owner="c++"/>
3591 <define-ownership class="java" owner="c++"/>
3591 </modify-argument>
3592 </modify-argument>
3592 </modify-function>
3593 </modify-function>
3593 <modify-function signature="QTreeWidgetItem(QTreeWidget *,QTreeWidgetItem *,int)">
3594 <modify-function signature="QTreeWidgetItem(QTreeWidget *,QTreeWidgetItem *,int)">
3594 <modify-argument index="this">
3595 <modify-argument index="this">
3595 <define-ownership class="java" owner="c++"/>
3596 <define-ownership class="java" owner="c++"/>
3596 </modify-argument>
3597 </modify-argument>
3597 </modify-function>
3598 </modify-function>
3598 <modify-function signature="QTreeWidgetItem(QTreeWidgetItem *,int)">
3599 <modify-function signature="QTreeWidgetItem(QTreeWidgetItem *,int)">
3599 <modify-argument index="this">
3600 <modify-argument index="this">
3600 <define-ownership class="java" owner="c++"/>
3601 <define-ownership class="java" owner="c++"/>
3601 </modify-argument>
3602 </modify-argument>
3602 </modify-function>
3603 </modify-function>
3603 <modify-function signature="QTreeWidgetItem(QTreeWidgetItem *,const QStringList&lt;QString&gt; &amp;,int)">
3604 <modify-function signature="QTreeWidgetItem(QTreeWidgetItem *,const QStringList&lt;QString&gt; &amp;,int)">
3604 <modify-argument index="this">
3605 <modify-argument index="this">
3605 <define-ownership class="java" owner="c++"/>
3606 <define-ownership class="java" owner="c++"/>
3606 </modify-argument>
3607 </modify-argument>
3607 </modify-function>
3608 </modify-function>
3608 <modify-function signature="QTreeWidgetItem(QTreeWidgetItem *,QTreeWidgetItem *,int)">
3609 <modify-function signature="QTreeWidgetItem(QTreeWidgetItem *,QTreeWidgetItem *,int)">
3609 <modify-argument index="this">
3610 <modify-argument index="this">
3610 <define-ownership class="java" owner="c++"/>
3611 <define-ownership class="java" owner="c++"/>
3611 </modify-argument>
3612 </modify-argument>
3612 </modify-function>
3613 </modify-function>
3613 <modify-function signature="clone() const">
3614 <modify-function signature="clone() const">
3614 <modify-argument index="return">
3615 <modify-argument index="return">
3615 <define-ownership class="shell" owner="c++"/>
3616 <define-ownership class="shell" owner="c++"/>
3616 </modify-argument>
3617 </modify-argument>
3617 </modify-function>
3618 </modify-function>
3618 <modify-function signature="addChild(QTreeWidgetItem *)">
3619 <modify-function signature="addChild(QTreeWidgetItem *)">
3619 <modify-argument index="1">
3620 <modify-argument index="1">
3620 <define-ownership class="java" owner="c++"/>
3621 <define-ownership class="java" owner="c++"/>
3621 </modify-argument>
3622 </modify-argument>
3622 </modify-function>
3623 </modify-function>
3623 <modify-function signature="addChildren(const QList&lt;QTreeWidgetItem*&gt; &amp;)">
3624 <modify-function signature="addChildren(const QList&lt;QTreeWidgetItem*&gt; &amp;)">
3624 <modify-argument index="1">
3625 <modify-argument index="1">
3625 <define-ownership class="java" owner="c++"/>
3626 <define-ownership class="java" owner="c++"/>
3626 </modify-argument>
3627 </modify-argument>
3627 </modify-function>
3628 </modify-function>
3628 <modify-function signature="insertChild(int, QTreeWidgetItem *)">
3629 <modify-function signature="insertChild(int, QTreeWidgetItem *)">
3629 <modify-argument index="2">
3630 <modify-argument index="2">
3630 <define-ownership class="java" owner="c++"/>
3631 <define-ownership class="java" owner="c++"/>
3631 </modify-argument>
3632 </modify-argument>
3632 </modify-function>
3633 </modify-function>
3633 <modify-function signature="insertChildren(int, const QList&lt;QTreeWidgetItem*&gt; &amp;)">
3634 <modify-function signature="insertChildren(int, const QList&lt;QTreeWidgetItem*&gt; &amp;)">
3634 <modify-argument index="2">
3635 <modify-argument index="2">
3635 <define-ownership class="java" owner="c++"/>
3636 <define-ownership class="java" owner="c++"/>
3636 </modify-argument>
3637 </modify-argument>
3637 </modify-function>
3638 </modify-function>
3638 <modify-function signature="removeChild(QTreeWidgetItem*)">
3639 <modify-function signature="removeChild(QTreeWidgetItem*)">
3639 <modify-argument index="1">
3640 <modify-argument index="1">
3640 <define-ownership class="java" owner="default"/>
3641 <define-ownership class="java" owner="default"/>
3641 </modify-argument>
3642 </modify-argument>
3642 </modify-function>
3643 </modify-function>
3643 <modify-function signature="takeChild(int)">
3644 <modify-function signature="takeChild(int)">
3644 <modify-argument index="return">
3645 <modify-argument index="return">
3645 <define-ownership class="java" owner="default"/>
3646 <define-ownership class="java" owner="default"/>
3646 </modify-argument>
3647 </modify-argument>
3647 </modify-function>
3648 </modify-function>
3648 <modify-function signature="takeChildren()">
3649 <modify-function signature="takeChildren()">
3649 <modify-argument index="return">
3650 <modify-argument index="return">
3650 <define-ownership class="java" owner="default"/>
3651 <define-ownership class="java" owner="default"/>
3651 </modify-argument>
3652 </modify-argument>
3652 </modify-function>
3653 </modify-function>
3653
3654
3654 <modify-function signature="backgroundColor(int)const" remove="all"/> <!--### Obsolete in 4.3-->
3655 <modify-function signature="backgroundColor(int)const" remove="all"/> <!--### Obsolete in 4.3-->
3655 <modify-function signature="setBackgroundColor(int, QColor)" remove="all"/> <!--### Obsolete in 4.3-->
3656 <modify-function signature="setBackgroundColor(int, QColor)" remove="all"/> <!--### Obsolete in 4.3-->
3656 <modify-function signature="setTextColor(int, QColor)" remove="all"/> <!--### Obsolete in 4.3-->
3657 <modify-function signature="setTextColor(int, QColor)" remove="all"/> <!--### Obsolete in 4.3-->
3657 <modify-function signature="textColor(int)const" remove="all"/> <!--### Obsolete in 4.3-->
3658 <modify-function signature="textColor(int)const" remove="all"/> <!--### Obsolete in 4.3-->
3658
3659
3659 <modify-function signature="read(QDataStream &amp;)" remove="all"/>
3660 <modify-function signature="read(QDataStream &amp;)" remove="all"/>
3660 <modify-function signature="write(QDataStream &amp;)const" remove="all"/>
3661 <modify-function signature="write(QDataStream &amp;)const" remove="all"/>
3661 <modify-function signature="QTreeWidgetItem(QTreeWidgetItem)" remove="all"/>
3662 <modify-function signature="QTreeWidgetItem(QTreeWidgetItem)" remove="all"/>
3662 <modify-function signature="operator=(QTreeWidgetItem)" remove="all"/>
3663 <modify-function signature="operator=(QTreeWidgetItem)" remove="all"/>
3663 <modify-function signature="operator&lt;(QTreeWidgetItem)const" remove="all"/>
3664 <modify-function signature="operator&lt;(QTreeWidgetItem)const" remove="all"/>
3664 </object-type>
3665 </object-type>
3665
3666
3666 <object-type name="QListWidget">
3667 <object-type name="QListWidget">
3667 <modify-function signature="mimeData(const QList&lt;QListWidgetItem *&gt;)const">
3668 <modify-function signature="mimeData(const QList&lt;QListWidgetItem *&gt;)const">
3668 <modify-argument index="1" invalidate-after-use="yes"/>
3669 <modify-argument index="1" invalidate-after-use="yes"/>
3669 </modify-function>
3670 </modify-function>
3670 <modify-function signature="addItem(QListWidgetItem *)">
3671 <modify-function signature="addItem(QListWidgetItem *)">
3671 <modify-argument index="1">
3672 <modify-argument index="1">
3672 <define-ownership class="java" owner="c++"/>
3673 <define-ownership class="java" owner="c++"/>
3673 </modify-argument>
3674 </modify-argument>
3674 </modify-function>
3675 </modify-function>
3675 <modify-function signature="insertItem(int, QListWidgetItem *)">
3676 <modify-function signature="insertItem(int, QListWidgetItem *)">
3676 <modify-argument index="2">
3677 <modify-argument index="2">
3677 <define-ownership class="java" owner="c++"/>
3678 <define-ownership class="java" owner="c++"/>
3678 </modify-argument>
3679 </modify-argument>
3679 </modify-function>
3680 </modify-function>
3680 <modify-function signature="setCurrentItem(QListWidgetItem*)">
3681 <modify-function signature="setCurrentItem(QListWidgetItem*)">
3681 <modify-argument index="1">
3682 <modify-argument index="1">
3682 <reference-count action="ignore"/>
3683 <reference-count action="ignore"/>
3683 </modify-argument>
3684 </modify-argument>
3684 </modify-function>
3685 </modify-function>
3685 <modify-function signature="setCurrentItem(QListWidgetItem*,QFlags&lt;QItemSelectionModel::SelectionFlag&gt;)">
3686 <modify-function signature="setCurrentItem(QListWidgetItem*,QFlags&lt;QItemSelectionModel::SelectionFlag&gt;)">
3686 <modify-argument index="1">
3687 <modify-argument index="1">
3687 <reference-count action="ignore"/>
3688 <reference-count action="ignore"/>
3688 </modify-argument>
3689 </modify-argument>
3689 </modify-function>
3690 </modify-function>
3690 <modify-function signature="setItemHidden(const QListWidgetItem*,bool)">
3691 <modify-function signature="setItemHidden(const QListWidgetItem*,bool)">
3691 <remove/>
3692 <remove/>
3692 </modify-function>
3693 </modify-function>
3693 <modify-function signature="isItemHidden(const QListWidgetItem*)const">
3694 <modify-function signature="isItemHidden(const QListWidgetItem*)const">
3694 <remove/>
3695 <remove/>
3695 </modify-function>
3696 </modify-function>
3696 <modify-function signature="setItemSelected(const QListWidgetItem*,bool)">
3697 <modify-function signature="setItemSelected(const QListWidgetItem*,bool)">
3697 <remove/>
3698 <remove/>
3698 </modify-function>
3699 </modify-function>
3699 <modify-function signature="isItemSelected(const QListWidgetItem*)const">
3700 <modify-function signature="isItemSelected(const QListWidgetItem*)const">
3700 <remove/>
3701 <remove/>
3701 </modify-function>
3702 </modify-function>
3702 <modify-function signature="takeItem(int)">
3703 <modify-function signature="takeItem(int)">
3703 <modify-argument index="return">
3704 <modify-argument index="return">
3704 <define-ownership class="java" owner="default"/>
3705 <define-ownership class="java" owner="default"/>
3705 </modify-argument>
3706 </modify-argument>
3706 </modify-function>
3707 </modify-function>
3707 <modify-function signature="setItemWidget(QListWidgetItem*,QWidget*)">
3708 <modify-function signature="setItemWidget(QListWidgetItem*,QWidget*)">
3708 <modify-argument index="1">
3709 <modify-argument index="1">
3709 <reference-count action="ignore"/>
3710 <reference-count action="ignore"/>
3710 </modify-argument>
3711 </modify-argument>
3711 <modify-argument index="2">
3712 <modify-argument index="2">
3712 <reference-count action="ignore"/>
3713 <reference-count action="ignore"/>
3713 </modify-argument>
3714 </modify-argument>
3714 </modify-function>
3715 </modify-function>
3715 <modify-function signature="removeItemWidget(QListWidgetItem*)">
3716 <modify-function signature="removeItemWidget(QListWidgetItem*)">
3716 <modify-argument index="1">
3717 <modify-argument index="1">
3717 <reference-count action="ignore"/>
3718 <reference-count action="ignore"/>
3718 </modify-argument>
3719 </modify-argument>
3719 </modify-function>
3720 </modify-function>
3720 <modify-function signature="setModel(QAbstractItemModel*)">
3721 <modify-function signature="setModel(QAbstractItemModel*)">
3721 <modify-argument index="1">
3722 <modify-argument index="1">
3722 <reference-count action="ignore"/>
3723 <reference-count action="ignore"/>
3723 </modify-argument>
3724 </modify-argument>
3724 </modify-function>
3725 </modify-function>
3725
3726
3726
3727
3727 <modify-function signature="mimeData(const QList&lt;QListWidgetItem*&gt;)const" remove="all"/>
3728 <modify-function signature="mimeData(const QList&lt;QListWidgetItem*&gt;)const" remove="all"/>
3728 </object-type>
3729 </object-type>
3729
3730
3730 <object-type name="QWidget">
3731 <object-type name="QWidget">
3731 <extra-includes>
3732 <extra-includes>
3732 <include file-name="QGesture" location="global"/>
3733 <include file-name="QGesture" location="global"/>
3733 <include file-name="QIcon" location="global"/>
3734 <include file-name="QIcon" location="global"/>
3734 <include file-name="QMessageBox" location="global"/>
3735 <include file-name="QMessageBox" location="global"/>
3735 </extra-includes>
3736 </extra-includes>
3736
3737
3737 <modify-function signature="actionEvent(QActionEvent*)">
3738 <modify-function signature="actionEvent(QActionEvent*)">
3738 <modify-argument index="1" invalidate-after-use="yes"/>
3739 <modify-argument index="1" invalidate-after-use="yes"/>
3739 </modify-function>
3740 </modify-function>
3740 <modify-function signature="changeEvent(QEvent*)">
3741 <modify-function signature="changeEvent(QEvent*)">
3741 <modify-argument index="1" invalidate-after-use="yes"/>
3742 <modify-argument index="1" invalidate-after-use="yes"/>
3742 </modify-function>
3743 </modify-function>
3743 <modify-function signature="closeEvent(QCloseEvent*)">
3744 <modify-function signature="closeEvent(QCloseEvent*)">
3744 <modify-argument index="1" invalidate-after-use="yes"/>
3745 <modify-argument index="1" invalidate-after-use="yes"/>
3745 </modify-function>
3746 </modify-function>
3746 <modify-function signature="contextMenuEvent(QContextMenuEvent*)">
3747 <modify-function signature="contextMenuEvent(QContextMenuEvent*)">
3747 <modify-argument index="1" invalidate-after-use="yes"/>
3748 <modify-argument index="1" invalidate-after-use="yes"/>
3748 </modify-function>
3749 </modify-function>
3749 <modify-function signature="dragEnterEvent(QDragEnterEvent*)">
3750 <modify-function signature="dragEnterEvent(QDragEnterEvent*)">
3750 <modify-argument index="1" invalidate-after-use="yes"/>
3751 <modify-argument index="1" invalidate-after-use="yes"/>
3751 </modify-function>
3752 </modify-function>
3752 <modify-function signature="dragLeaveEvent(QDragLeaveEvent*)">
3753 <modify-function signature="dragLeaveEvent(QDragLeaveEvent*)">
3753 <modify-argument index="1" invalidate-after-use="yes"/>
3754 <modify-argument index="1" invalidate-after-use="yes"/>
3754 </modify-function>
3755 </modify-function>
3755 <modify-function signature="dragMoveEvent(QDragMoveEvent*)">
3756 <modify-function signature="dragMoveEvent(QDragMoveEvent*)">
3756 <modify-argument index="1" invalidate-after-use="yes"/>
3757 <modify-argument index="1" invalidate-after-use="yes"/>
3757 </modify-function>
3758 </modify-function>
3758 <modify-function signature="dropEvent(QDropEvent*)">
3759 <modify-function signature="dropEvent(QDropEvent*)">
3759 <modify-argument index="1" invalidate-after-use="yes"/>
3760 <modify-argument index="1" invalidate-after-use="yes"/>
3760 </modify-function>
3761 </modify-function>
3761 <modify-function signature="enterEvent(QEvent*)">
3762 <modify-function signature="enterEvent(QEvent*)">
3762 <modify-argument index="1" invalidate-after-use="yes"/>
3763 <modify-argument index="1" invalidate-after-use="yes"/>
3763 </modify-function>
3764 </modify-function>
3764 <modify-function signature="focusInEvent(QFocusEvent*)">
3765 <modify-function signature="focusInEvent(QFocusEvent*)">
3765 <modify-argument index="1" invalidate-after-use="yes"/>
3766 <modify-argument index="1" invalidate-after-use="yes"/>
3766 </modify-function>
3767 </modify-function>
3767 <modify-function signature="focusOutEvent(QFocusEvent*)">
3768 <modify-function signature="focusOutEvent(QFocusEvent*)">
3768 <modify-argument index="1" invalidate-after-use="yes"/>
3769 <modify-argument index="1" invalidate-after-use="yes"/>
3769 </modify-function>
3770 </modify-function>
3770 <modify-function signature="hideEvent(QHideEvent*)">
3771 <modify-function signature="hideEvent(QHideEvent*)">
3771 <modify-argument index="1" invalidate-after-use="yes"/>
3772 <modify-argument index="1" invalidate-after-use="yes"/>
3772 </modify-function>
3773 </modify-function>
3773 <modify-function signature="inputMethodEvent(QInputMethodEvent*)">
3774 <modify-function signature="inputMethodEvent(QInputMethodEvent*)">
3774 <modify-argument index="1" invalidate-after-use="yes"/>
3775 <modify-argument index="1" invalidate-after-use="yes"/>
3775 </modify-function>
3776 </modify-function>
3776 <modify-function signature="keyPressEvent(QKeyEvent*)">
3777 <modify-function signature="keyPressEvent(QKeyEvent*)">
3777 <modify-argument index="1" invalidate-after-use="yes"/>
3778 <modify-argument index="1" invalidate-after-use="yes"/>
3778 </modify-function>
3779 </modify-function>
3779 <modify-function signature="keyReleaseEvent(QKeyEvent*)">
3780 <modify-function signature="keyReleaseEvent(QKeyEvent*)">
3780 <modify-argument index="1" invalidate-after-use="yes"/>
3781 <modify-argument index="1" invalidate-after-use="yes"/>
3781 </modify-function>
3782 </modify-function>
3782 <modify-function signature="leaveEvent(QEvent*)">
3783 <modify-function signature="leaveEvent(QEvent*)">
3783 <modify-argument index="1" invalidate-after-use="yes"/>
3784 <modify-argument index="1" invalidate-after-use="yes"/>
3784 </modify-function>
3785 </modify-function>
3785 <modify-function signature="mouseDoubleClickEvent(QMouseEvent*)">
3786 <modify-function signature="mouseDoubleClickEvent(QMouseEvent*)">
3786 <modify-argument index="1" invalidate-after-use="yes"/>
3787 <modify-argument index="1" invalidate-after-use="yes"/>
3787 </modify-function>
3788 </modify-function>
3788 <modify-function signature="mouseMoveEvent(QMouseEvent*)">
3789 <modify-function signature="mouseMoveEvent(QMouseEvent*)">
3789 <modify-argument index="1" invalidate-after-use="yes"/>
3790 <modify-argument index="1" invalidate-after-use="yes"/>
3790 </modify-function>
3791 </modify-function>
3791 <modify-function signature="mousePressEvent(QMouseEvent*)">
3792 <modify-function signature="mousePressEvent(QMouseEvent*)">
3792 <modify-argument index="1" invalidate-after-use="yes"/>
3793 <modify-argument index="1" invalidate-after-use="yes"/>
3793 </modify-function>
3794 </modify-function>
3794 <modify-function signature="mouseReleaseEvent(QMouseEvent*)">
3795 <modify-function signature="mouseReleaseEvent(QMouseEvent*)">
3795 <modify-argument index="1" invalidate-after-use="yes"/>
3796 <modify-argument index="1" invalidate-after-use="yes"/>
3796 </modify-function>
3797 </modify-function>
3797 <modify-function signature="moveEvent(QMoveEvent*)">
3798 <modify-function signature="moveEvent(QMoveEvent*)">
3798 <modify-argument index="1" invalidate-after-use="yes"/>
3799 <modify-argument index="1" invalidate-after-use="yes"/>
3799 </modify-function>
3800 </modify-function>
3800 <modify-function signature="paintEvent(QPaintEvent*)">
3801 <modify-function signature="paintEvent(QPaintEvent*)">
3801 <modify-argument index="1" invalidate-after-use="yes"/>
3802 <modify-argument index="1" invalidate-after-use="yes"/>
3802 </modify-function>
3803 </modify-function>
3803 <modify-function signature="resizeEvent(QResizeEvent*)">
3804 <modify-function signature="resizeEvent(QResizeEvent*)">
3804 <modify-argument index="1" invalidate-after-use="yes"/>
3805 <modify-argument index="1" invalidate-after-use="yes"/>
3805 </modify-function>
3806 </modify-function>
3806 <modify-function signature="showEvent(QShowEvent*)">
3807 <modify-function signature="showEvent(QShowEvent*)">
3807 <modify-argument index="1" invalidate-after-use="yes"/>
3808 <modify-argument index="1" invalidate-after-use="yes"/>
3808 </modify-function>
3809 </modify-function>
3809 <modify-function signature="tabletEvent(QTabletEvent*)">
3810 <modify-function signature="tabletEvent(QTabletEvent*)">
3810 <modify-argument index="1" invalidate-after-use="yes"/>
3811 <modify-argument index="1" invalidate-after-use="yes"/>
3811 </modify-function>
3812 </modify-function>
3812 <modify-function signature="wheelEvent(QWheelEvent*)">
3813 <modify-function signature="wheelEvent(QWheelEvent*)">
3813 <modify-argument index="1" invalidate-after-use="yes"/>
3814 <modify-argument index="1" invalidate-after-use="yes"/>
3814 </modify-function>
3815 </modify-function>
3815
3816
3816 <modify-function signature="render(QPainter*,QPoint,QRegion,QFlags&lt;QWidget::RenderFlag&gt;)">
3817 <modify-function signature="render(QPainter*,QPoint,QRegion,QFlags&lt;QWidget::RenderFlag&gt;)">
3817 <modify-argument index="2">
3818 <modify-argument index="2">
3818 <!-- Removed because the render(QPainter*) overload conflicts with the identical function in QGraphicsView -->
3819 <!-- Removed because the render(QPainter*) overload conflicts with the identical function in QGraphicsView -->
3819 <remove-default-expression/>
3820 <remove-default-expression/>
3820 </modify-argument>
3821 </modify-argument>
3821 </modify-function>
3822 </modify-function>
3822
3823
3823 <!--
3824 <!--
3824 <inject-code class="native">
3825 <inject-code class="native">
3825 extern "C" JNIEXPORT void JNICALL QTJAMBI_FUNCTION_PREFIX(Java_com_trolltech_qt_gui_QWidget__1_1qt_1QMessageBox_1setWindowTitle)
3826 extern "C" JNIEXPORT void JNICALL QTJAMBI_FUNCTION_PREFIX(Java_com_trolltech_qt_gui_QWidget__1_1qt_1QMessageBox_1setWindowTitle)
3826 (JNIEnv *__jni_env,
3827 (JNIEnv *__jni_env,
3827 jclass,
3828 jclass,
3828 jlong __this_nativeId,
3829 jlong __this_nativeId,
3829 jobject title0)
3830 jobject title0)
3830 {
3831 {
3831 QTJAMBI_DEBUG_TRACE("(native) entering: QMessageBox::setWindowTitle(const QString &amp; title)");
3832 QTJAMBI_DEBUG_TRACE("(native) entering: QMessageBox::setWindowTitle(const QString &amp; title)");
3832 QString __qt_title0 = qtjambi_to_qstring(__jni_env, (jstring) title0);
3833 QString __qt_title0 = qtjambi_to_qstring(__jni_env, (jstring) title0);
3833 QTJAMBI_EXCEPTION_CHECK(__jni_env);
3834 QTJAMBI_EXCEPTION_CHECK(__jni_env);
3834 QMessageBox *__qt_this = (QMessageBox *) qtjambi_from_jlong(__this_nativeId);
3835 QMessageBox *__qt_this = (QMessageBox *) qtjambi_from_jlong(__this_nativeId);
3835 QTJAMBI_EXCEPTION_CHECK(__jni_env);
3836 QTJAMBI_EXCEPTION_CHECK(__jni_env);
3836 Q_ASSERT(__qt_this);
3837 Q_ASSERT(__qt_this);
3837 __qt_this-&gt;setWindowTitle((const QString&amp; )__qt_title0);
3838 __qt_this-&gt;setWindowTitle((const QString&amp; )__qt_title0);
3838 QTJAMBI_DEBUG_TRACE("(native) -&gt; leaving: QMessageBox::setWindowTitle(const QString &amp; title)");
3839 QTJAMBI_DEBUG_TRACE("(native) -&gt; leaving: QMessageBox::setWindowTitle(const QString &amp; title)");
3839 }
3840 }
3840 </inject-code>
3841 </inject-code>
3841
3842
3842 <inject-code class="native">
3843 <inject-code class="native">
3843 extern "C" JNIEXPORT void JNICALL QTJAMBI_FUNCTION_PREFIX(Java_com_trolltech_qt_gui_QWidget__1_1qt_1QMessageBox_1setWindowModality)
3844 extern "C" JNIEXPORT void JNICALL QTJAMBI_FUNCTION_PREFIX(Java_com_trolltech_qt_gui_QWidget__1_1qt_1QMessageBox_1setWindowModality)
3844 (JNIEnv *__jni_env,
3845 (JNIEnv *__jni_env,
3845 jclass,
3846 jclass,
3846 jlong __this_nativeId,
3847 jlong __this_nativeId,
3847 jint windowModality0)
3848 jint windowModality0)
3848 {
3849 {
3849 Q_UNUSED(__jni_env);
3850 Q_UNUSED(__jni_env);
3850 QTJAMBI_DEBUG_TRACE("(native) entering: QMessageBox::setWindowModality(Qt::WindowModality modality)");
3851 QTJAMBI_DEBUG_TRACE("(native) entering: QMessageBox::setWindowModality(Qt::WindowModality modality)");
3851 Qt::WindowModality __qt_windowModality0 = (Qt::WindowModality) windowModality0;
3852 Qt::WindowModality __qt_windowModality0 = (Qt::WindowModality) windowModality0;
3852 QTJAMBI_EXCEPTION_CHECK(__jni_env);
3853 QTJAMBI_EXCEPTION_CHECK(__jni_env);
3853 QMessageBox *__qt_this = (QMessageBox *) qtjambi_from_jlong(__this_nativeId);
3854 QMessageBox *__qt_this = (QMessageBox *) qtjambi_from_jlong(__this_nativeId);
3854 QTJAMBI_EXCEPTION_CHECK(__jni_env);
3855 QTJAMBI_EXCEPTION_CHECK(__jni_env);
3855 Q_ASSERT(__qt_this);
3856 Q_ASSERT(__qt_this);
3856 __qt_this-&gt;setWindowModality((Qt::WindowModality )__qt_windowModality0);
3857 __qt_this-&gt;setWindowModality((Qt::WindowModality )__qt_windowModality0);
3857 QTJAMBI_DEBUG_TRACE("(native) -&gt; leaving: QMessageBox::setWindowModality(Qt::WindowModality modality)");
3858 QTJAMBI_DEBUG_TRACE("(native) -&gt; leaving: QMessageBox::setWindowModality(Qt::WindowModality modality)");
3858 }
3859 }
3859 </inject-code>
3860 </inject-code>
3860 -->
3861 -->
3861
3862
3862 <modify-function signature="render(QPaintDevice *, const QPoint &amp;, const QRegion &amp;, QFlags&lt;QWidget::RenderFlag&gt;)">
3863 <modify-function signature="render(QPaintDevice *, const QPoint &amp;, const QRegion &amp;, QFlags&lt;QWidget::RenderFlag&gt;)">
3863 <modify-argument index="4">
3864 <modify-argument index="4">
3864 <replace-default-expression with="RenderFlag.DrawWindowBackground, RenderFlag.DrawChildren"/>
3865 <replace-default-expression with="RenderFlag.DrawWindowBackground, RenderFlag.DrawChildren"/>
3865 </modify-argument>
3866 </modify-argument>
3866 </modify-function>
3867 </modify-function>
3867 <modify-function signature="render(QPainter *, const QPoint &amp;, const QRegion &amp;, QFlags&lt;QWidget::RenderFlag&gt;)">
3868 <modify-function signature="render(QPainter *, const QPoint &amp;, const QRegion &amp;, QFlags&lt;QWidget::RenderFlag&gt;)">
3868 <modify-argument index="4">
3869 <modify-argument index="4">
3869 <replace-default-expression with="RenderFlag.DrawWindowBackground, RenderFlag.DrawChildren"/>
3870 <replace-default-expression with="RenderFlag.DrawWindowBackground, RenderFlag.DrawChildren"/>
3870 </modify-argument>
3871 </modify-argument>
3871 </modify-function>
3872 </modify-function>
3872 <modify-function signature="setFocusProxy(QWidget*)">
3873 <modify-function signature="setFocusProxy(QWidget*)">
3873 <modify-argument index="1">
3874 <modify-argument index="1">
3874 <reference-count action="set" variable-name="__rcFocusProxy"/>
3875 <reference-count action="set" variable-name="__rcFocusProxy"/>
3875 </modify-argument>
3876 </modify-argument>
3876 </modify-function>
3877 </modify-function>
3877 <modify-function signature="setInputContext(QInputContext*)">
3878 <modify-function signature="setInputContext(QInputContext*)">
3878 <modify-argument index="1">
3879 <modify-argument index="1">
3879 <define-ownership class="java" owner="c++"/>
3880 <define-ownership class="java" owner="c++"/>
3880 </modify-argument>
3881 </modify-argument>
3881 </modify-function>
3882 </modify-function>
3882 <modify-function signature="setLayout(QLayout*)">
3883 <modify-function signature="setLayout(QLayout*)">
3883 <modify-argument index="1">
3884 <modify-argument index="1">
3884 <no-null-pointer/>
3885 <no-null-pointer/>
3885 <reference-count action="ignore"/>
3886 <reference-count action="ignore"/>
3886 </modify-argument>
3887 </modify-argument>
3887 </modify-function>
3888 </modify-function>
3888 <modify-function signature="setParent(QWidget*,QFlags&lt;Qt::WindowType&gt;)">
3889 <modify-function signature="setParent(QWidget*,QFlags&lt;Qt::WindowType&gt;)">
3889 <modify-argument index="1">
3890 <modify-argument index="1">
3890 <reference-count action="ignore"/>
3891 <reference-count action="ignore"/>
3891 </modify-argument>
3892 </modify-argument>
3892 </modify-function>
3893 </modify-function>
3893 <modify-function signature="setParent(QWidget*)">
3894 <modify-function signature="setParent(QWidget*)">
3894 <modify-argument index="1">
3895 <modify-argument index="1">
3895 <reference-count action="ignore"/>
3896 <reference-count action="ignore"/>
3896 </modify-argument>
3897 </modify-argument>
3897 </modify-function>
3898 </modify-function>
3898 <modify-function signature="setStyle(QStyle*)">
3899 <modify-function signature="setStyle(QStyle*)">
3899 <modify-argument index="1">
3900 <modify-argument index="1">
3900 <reference-count action="set" variable-name="__rcStyle"/>
3901 <reference-count action="set" variable-name="__rcStyle"/>
3901 </modify-argument>
3902 </modify-argument>
3902 </modify-function>
3903 </modify-function>
3903 <modify-function signature="setTabOrder(QWidget*,QWidget*)">
3904 <modify-function signature="setTabOrder(QWidget*,QWidget*)">
3904 <modify-argument index="1">
3905 <modify-argument index="1">
3905 <reference-count action="ignore"/>
3906 <reference-count action="ignore"/>
3906 </modify-argument>
3907 </modify-argument>
3907 <modify-argument index="2">
3908 <modify-argument index="2">
3908 <reference-count action="ignore"/>
3909 <reference-count action="ignore"/>
3909 </modify-argument>
3910 </modify-argument>
3910 </modify-function>
3911 </modify-function>
3911 <modify-function signature="getContentsMargins(int*,int*,int*,int*)const">
3912 <modify-function signature="getContentsMargins(int*,int*,int*,int*)const">
3912 <access modifier="private"/>
3913 <access modifier="private"/>
3913 </modify-function>
3914 </modify-function>
3914
3915
3915 <modify-function signature="addAction(QAction *)">
3916 <modify-function signature="addAction(QAction *)">
3916 <modify-argument index="1">
3917 <modify-argument index="1">
3917 <reference-count action="add" variable-name="__rcActions"/>
3918 <reference-count action="add" variable-name="__rcActions"/>
3918 </modify-argument>
3919 </modify-argument>
3919 </modify-function>
3920 </modify-function>
3920
3921
3921 <modify-function signature="insertAction(QAction *, QAction *)">
3922 <modify-function signature="insertAction(QAction *, QAction *)">
3922 <modify-argument index="2">
3923 <modify-argument index="2">
3923 <reference-count action="add" variable-name="__rcActions"/>
3924 <reference-count action="add" variable-name="__rcActions"/>
3924 </modify-argument>
3925 </modify-argument>
3925 </modify-function>
3926 </modify-function>
3926
3927
3927 <modify-function signature="addActions(const QList&lt;QAction *&gt; &amp;)">
3928 <modify-function signature="addActions(const QList&lt;QAction *&gt; &amp;)">
3928 <modify-argument index="1">
3929 <modify-argument index="1">
3929 <reference-count action="add-all" variable-name="__rcActions"/>
3930 <reference-count action="add-all" variable-name="__rcActions"/>
3930 </modify-argument>
3931 </modify-argument>
3931 </modify-function>
3932 </modify-function>
3932
3933
3933 <modify-function signature="insertActions(QAction *, const QList&lt;QAction *&gt; &amp;)">
3934 <modify-function signature="insertActions(QAction *, const QList&lt;QAction *&gt; &amp;)">
3934 <modify-argument index="2">
3935 <modify-argument index="2">
3935 <reference-count action="add-all" variable-name="__rcActions"/>
3936 <reference-count action="add-all" variable-name="__rcActions"/>
3936 </modify-argument>
3937 </modify-argument>
3937 </modify-function>
3938 </modify-function>
3938
3939
3939 <modify-function signature="removeAction(QAction *)">
3940 <modify-function signature="removeAction(QAction *)">
3940 <modify-argument index="1">
3941 <modify-argument index="1">
3941 <reference-count action="remove" variable-name="__rcActions"/>
3942 <reference-count action="remove" variable-name="__rcActions"/>
3942 </modify-argument>
3943 </modify-argument>
3943 </modify-function>
3944 </modify-function>
3944 <modify-function signature="enabledChange(bool)" remove="all"/> <!--### Obsolete in 4.3-->
3945 <modify-function signature="enabledChange(bool)" remove="all"/> <!--### Obsolete in 4.3-->
3945 <modify-function signature="fontChange(QFont)" remove="all"/> <!--### Obsolete in 4.3-->
3946 <modify-function signature="fontChange(QFont)" remove="all"/> <!--### Obsolete in 4.3-->
3946 <modify-function signature="isEnabledToTLW()const" remove="all"/> <!--### Obsolete in 4.3-->
3947 <modify-function signature="isEnabledToTLW()const" remove="all"/> <!--### Obsolete in 4.3-->
3947 <modify-function signature="isTopLevel()const" remove="all"/> <!--### Obsolete in 4.3-->
3948 <modify-function signature="isTopLevel()const" remove="all"/> <!--### Obsolete in 4.3-->
3948 <modify-function signature="paletteChange(QPalette)" remove="all"/> <!--### Obsolete in 4.3-->
3949 <modify-function signature="paletteChange(QPalette)" remove="all"/> <!--### Obsolete in 4.3-->
3949 <modify-function signature="setShown(bool)" remove="all"/> <!--### Obsolete in 4.3-->
3950 <modify-function signature="setShown(bool)" remove="all"/> <!--### Obsolete in 4.3-->
3950 <modify-function signature="topLevelWidget()const" remove="all"/> <!--### Obsolete in 4.3-->
3951 <modify-function signature="topLevelWidget()const" remove="all"/> <!--### Obsolete in 4.3-->
3951 <modify-function signature="windowActivationChange(bool)" remove="all"/> <!--### Obsolete in 4.3-->
3952 <modify-function signature="windowActivationChange(bool)" remove="all"/> <!--### Obsolete in 4.3-->
3952
3953
3953 <modify-function signature="fontInfo()const" remove="all"/>
3954 <modify-function signature="fontInfo()const" remove="all"/>
3954 <modify-function signature="fontMetrics()const" remove="all"/>
3955 <modify-function signature="fontMetrics()const" remove="all"/>
3955 <modify-function signature="sizeHint()const" rename="getSizeHint"/>
3956 <modify-function signature="sizeHint()const" rename="getSizeHint"/>
3956 <modify-function signature="minimumSizeHint()const" rename="getMinimumSizeHint"/>
3957 <modify-function signature="minimumSizeHint()const" rename="getMinimumSizeHint"/>
3957 <modify-function signature="setVisible(bool)" remove="all"/>
3958 <modify-function signature="setVisible(bool)" remove="all"/>
3958 <modify-function signature="grabGesture(Qt::GestureType type,Qt::GestureFlags)">
3959 <modify-function signature="grabGesture(Qt::GestureType type,Qt::GestureFlags)">
3959 <modify-argument index="2"> <remove-default-expression/> </modify-argument>
3960 <modify-argument index="2"> <remove-default-expression/> </modify-argument>
3960 </modify-function>
3961 </modify-function>
3961 </object-type>
3962 </object-type>
3962
3963
3963 <object-type name="QMessageBox">
3964 <object-type name="QMessageBox">
3964
3965
3965
3966
3966 <modify-function signature="setWindowTitle(const QString &amp;)" remove="all"/>
3967 <modify-function signature="setWindowTitle(const QString &amp;)" remove="all"/>
3967 <modify-function signature="setWindowModality(Qt::WindowModality)" remove="all"/>
3968 <modify-function signature="setWindowModality(Qt::WindowModality)" remove="all"/>
3968 <extra-includes>
3969 <extra-includes>
3969 <include file-name="QPixmap" location="global"/>
3970 <include file-name="QPixmap" location="global"/>
3970 </extra-includes>
3971 </extra-includes>
3971 <modify-function signature="addButton(QAbstractButton*,QMessageBox::ButtonRole)">
3972 <modify-function signature="addButton(QAbstractButton*,QMessageBox::ButtonRole)">
3972 <modify-argument index="1">
3973 <modify-argument index="1">
3973 <reference-count action="ignore"/>
3974 <reference-count action="ignore"/>
3974 </modify-argument>
3975 </modify-argument>
3975 </modify-function>
3976 </modify-function>
3976 <modify-function signature="removeButton(QAbstractButton*)">
3977 <modify-function signature="removeButton(QAbstractButton*)">
3977 <modify-argument index="1">
3978 <modify-argument index="1">
3978 <reference-count action="ignore"/>
3979 <reference-count action="ignore"/>
3979 </modify-argument>
3980 </modify-argument>
3980 </modify-function>
3981 </modify-function>
3981 <modify-function signature="setDefaultButton(QPushButton*)">
3982 <modify-function signature="setDefaultButton(QPushButton*)">
3982 <modify-argument index="1">
3983 <modify-argument index="1">
3983 <reference-count action="ignore"/>
3984 <reference-count action="ignore"/>
3984 </modify-argument>
3985 </modify-argument>
3985 </modify-function>
3986 </modify-function>
3986 <modify-function signature="setEscapeButton(QAbstractButton*)">
3987 <modify-function signature="setEscapeButton(QAbstractButton*)">
3987 <modify-argument index="1">
3988 <modify-argument index="1">
3988 <reference-count action="ignore"/>
3989 <reference-count action="ignore"/>
3989 </modify-argument>
3990 </modify-argument>
3990 </modify-function>
3991 </modify-function>
3991
3992
3992 <modify-function signature="QMessageBox(QString,QString,QMessageBox::Icon,int,int,int,QWidget*,QFlags&lt;Qt::WindowType&gt;)" remove="all"/> <!--### Obsolete in 4.3-->
3993 <modify-function signature="QMessageBox(QString,QString,QMessageBox::Icon,int,int,int,QWidget*,QFlags&lt;Qt::WindowType&gt;)" remove="all"/> <!--### Obsolete in 4.3-->
3993 <modify-function signature="buttonText(int)const" remove="all"/> <!--### Obsolete in 4.3-->
3994 <modify-function signature="buttonText(int)const" remove="all"/> <!--### Obsolete in 4.3-->
3994 <modify-function signature="setButtonText(int, QString)" remove="all"/> <!--### Obsolete in 4.3-->
3995 <modify-function signature="setButtonText(int, QString)" remove="all"/> <!--### Obsolete in 4.3-->
3995 <modify-function signature="standardIcon(QMessageBox::Icon)" remove="all"/> <!--### Obsolete in 4.3-->
3996 <modify-function signature="standardIcon(QMessageBox::Icon)" remove="all"/> <!--### Obsolete in 4.3-->
3996
3997
3997 <modify-function signature="critical(QWidget*,QString,QString,int,int,int)" remove="all"/> <!--### Obsolete in 4.3-->
3998 <modify-function signature="critical(QWidget*,QString,QString,int,int,int)" remove="all"/> <!--### Obsolete in 4.3-->
3998 <modify-function signature="critical(QWidget*,QString,QString,QString,QString,QString,int,int)" remove="all"/> <!--### Obsolete in 4.3-->
3999 <modify-function signature="critical(QWidget*,QString,QString,QString,QString,QString,int,int)" remove="all"/> <!--### Obsolete in 4.3-->
3999 <modify-function signature="information(QWidget*,QString,QString,int,int,int)" remove="all"/> <!--### Obsolete in 4.3-->
4000 <modify-function signature="information(QWidget*,QString,QString,int,int,int)" remove="all"/> <!--### Obsolete in 4.3-->
4000 <modify-function signature="information(QWidget*,QString,QString,QString,QString,QString,int,int)" remove="all"/> <!--### Obsolete in 4.3-->
4001 <modify-function signature="information(QWidget*,QString,QString,QString,QString,QString,int,int)" remove="all"/> <!--### Obsolete in 4.3-->
4001 <modify-function signature="question(QWidget*, QString, QString, int, int, int)" remove="all"/> <!--### Obsolete in 4.3-->
4002 <modify-function signature="question(QWidget*, QString, QString, int, int, int)" remove="all"/> <!--### Obsolete in 4.3-->
4002 <modify-function signature="question(QWidget*, QString, QString, QString, QString, QString, int, int)" remove="all"/> <!--### Obsolete in 4.3-->
4003 <modify-function signature="question(QWidget*, QString, QString, QString, QString, QString, int, int)" remove="all"/> <!--### Obsolete in 4.3-->
4003 <modify-function signature="warning(QWidget*, QString, QString, int, int, int)" remove="all"/> <!--### Obsolete in 4.3-->
4004 <modify-function signature="warning(QWidget*, QString, QString, int, int, int)" remove="all"/> <!--### Obsolete in 4.3-->
4004 <modify-function signature="warning(QWidget*, QString, QString, QString, QString, QString, int, int)" remove="all"/> <!--### Obsolete in 4.3-->
4005 <modify-function signature="warning(QWidget*, QString, QString, QString, QString, QString, int, int)" remove="all"/> <!--### Obsolete in 4.3-->
4005 </object-type>
4006 </object-type>
4006
4007
4007 <object-type name="QAbstractSpinBox">
4008 <object-type name="QAbstractSpinBox">
4008 <modify-function signature="initStyleOption(QStyleOptionSpinBox*)const">
4009 <modify-function signature="initStyleOption(QStyleOptionSpinBox*)const">
4009 <access modifier="private"/>
4010 <access modifier="private"/>
4010 </modify-function>
4011 </modify-function>
4011 <modify-function signature="setLineEdit(QLineEdit*)">
4012 <modify-function signature="setLineEdit(QLineEdit*)">
4012 <modify-argument index="1">
4013 <modify-argument index="1">
4013 <!-- Safe to ignore because the spinbox reparents the line edit -->
4014 <!-- Safe to ignore because the spinbox reparents the line edit -->
4014 <reference-count action="ignore"/>
4015 <reference-count action="ignore"/>
4015 <no-null-pointer/>
4016 <no-null-pointer/>
4016 </modify-argument>
4017 </modify-argument>
4017 </modify-function>
4018 </modify-function>
4018 </object-type>
4019 </object-type>
4019
4020
4020 <object-type name="QTextFrame" delete-in-main-thread="yes">
4021 <object-type name="QTextFrame" delete-in-main-thread="yes">
4021 <extra-includes>
4022 <extra-includes>
4022 <include file-name="QTextCursor" location="global"/>
4023 <include file-name="QTextCursor" location="global"/>
4023 </extra-includes>
4024 </extra-includes>
4024 </object-type>
4025 </object-type>
4025
4026
4026 <object-type name="QImageIOHandler">
4027 <object-type name="QImageIOHandler">
4027 <extra-includes>
4028 <extra-includes>
4028 <include file-name="QRect" location="global"/>
4029 <include file-name="QRect" location="global"/>
4029 </extra-includes>
4030 </extra-includes>
4030 <modify-function signature="setFormat(const QByteArray &amp;)const">
4031 <modify-function signature="setFormat(const QByteArray &amp;)const">
4031 <remove/>
4032 <remove/>
4032 </modify-function>
4033 </modify-function>
4033 <modify-function signature="setDevice(QIODevice*)">
4034 <modify-function signature="setDevice(QIODevice*)">
4034 <modify-argument index="1">
4035 <modify-argument index="1">
4035 <reference-count action="set" variable-name="__rcDevice"/>
4036 <reference-count action="set" variable-name="__rcDevice"/>
4036 </modify-argument>
4037 </modify-argument>
4037 </modify-function>
4038 </modify-function>
4038 <!--
4039 <!--
4039 <modify-function signature="read(QImage*)">
4040 <modify-function signature="read(QImage*)">
4040 <modify-argument index="1">
4041 <modify-argument index="1">
4041 <replace-type modified-type="com.trolltech.qt.gui.QImage"/>
4042 <replace-type modified-type="com.trolltech.qt.gui.QImage"/>
4042 <conversion-rule class="shell">
4043 <conversion-rule class="shell">
4043 jobject %out = qtjambi_from_object(__jni_env, %in, "QImage", "com/trolltech/qt/gui/", false);
4044 jobject %out = qtjambi_from_object(__jni_env, %in, "QImage", "com/trolltech/qt/gui/", false);
4044
4045
4045 QtJambiLink *__link = %out != 0 ? QtJambiLink::findLink(__jni_env, %out) : 0;
4046 QtJambiLink *__link = %out != 0 ? QtJambiLink::findLink(__jni_env, %out) : 0;
4046 </conversion-rule>
4047 </conversion-rule>
4047 <conversion-rule class="native">
4048 <conversion-rule class="native">
4048 QImage *%out = (QImage *) qtjambi_to_object(__jni_env, %in);
4049 QImage *%out = (QImage *) qtjambi_to_object(__jni_env, %in);
4049 </conversion-rule>
4050 </conversion-rule>
4050 </modify-argument>
4051 </modify-argument>
4051 <modify-argument index="0">
4052 <modify-argument index="0">
4052 <conversion-rule class="shell">
4053 <conversion-rule class="shell">
4053 // Invalidate object
4054 // Invalidate object
4054 if (__link != 0) __link-&gt;resetObject(__jni_env);
4055 if (__link != 0) __link-&gt;resetObject(__jni_env);
4055 bool %out = (bool) %in;
4056 bool %out = (bool) %in;
4056 </conversion-rule>
4057 </conversion-rule>
4057 </modify-argument>
4058 </modify-argument>
4058 </modify-function>
4059 </modify-function>
4059 -->
4060 -->
4060
4061
4061 <modify-function signature="name()const" remove="all"/> <!--### Obsolete in 4.3-->
4062 <modify-function signature="name()const" remove="all"/> <!--### Obsolete in 4.3-->
4062 </object-type>
4063 </object-type>
4063
4064
4064 <object-type name="QProxyModel">
4065 <object-type name="QProxyModel">
4065 <modify-function signature="parent()const" remove="all"/>
4066 <modify-function signature="parent()const" remove="all"/>
4066 <extra-includes>
4067 <extra-includes>
4067 <include file-name="QPixmap" location="global"/>
4068 <include file-name="QPixmap" location="global"/>
4068 <include file-name="QStringList" location="global"/>
4069 <include file-name="QStringList" location="global"/>
4069 <include file-name="QSize" location="global"/>
4070 <include file-name="QSize" location="global"/>
4070 </extra-includes>
4071 </extra-includes>
4071 <modify-function signature="setModel(QAbstractItemModel*)">
4072 <modify-function signature="setModel(QAbstractItemModel*)">
4072 <modify-argument index="1">
4073 <modify-argument index="1">
4073 <reference-count action="set" variable-name="__rcModel"/>
4074 <reference-count action="set" variable-name="__rcModel"/>
4074 </modify-argument>
4075 </modify-argument>
4075 </modify-function>
4076 </modify-function>
4076 </object-type>
4077 </object-type>
4077
4078
4078 <object-type name="QImageReader">
4079 <object-type name="QImageReader">
4079 <extra-includes>
4080 <extra-includes>
4080 <include file-name="QColor" location="global"/>
4081 <include file-name="QColor" location="global"/>
4081 <include file-name="QRect" location="global"/>
4082 <include file-name="QRect" location="global"/>
4082 <include file-name="QSize" location="global"/>
4083 <include file-name="QSize" location="global"/>
4083 <include file-name="QStringList" location="global"/>
4084 <include file-name="QStringList" location="global"/>
4084 <include file-name="QImage" location="global"/>
4085 <include file-name="QImage" location="global"/>
4085 </extra-includes>
4086 </extra-includes>
4086 <modify-function signature="read(QImage*) ">
4087 <modify-function signature="read(QImage*) ">
4087 <remove/>
4088 <remove/>
4088 </modify-function>
4089 </modify-function>
4089 <modify-function signature="setDevice(QIODevice*)">
4090 <modify-function signature="setDevice(QIODevice*)">
4090 <modify-argument index="1">
4091 <modify-argument index="1">
4091 <reference-count action="set" variable-name="__rcDevice"/>
4092 <reference-count action="set" variable-name="__rcDevice"/>
4092 </modify-argument>
4093 </modify-argument>
4093 </modify-function>
4094 </modify-function>
4094 </object-type>
4095 </object-type>
4095
4096
4096 <object-type name="QMovie">
4097 <object-type name="QMovie">
4097 <extra-includes>
4098 <extra-includes>
4098 <include file-name="QColor" location="global"/>
4099 <include file-name="QColor" location="global"/>
4099 <include file-name="QImage" location="global"/>
4100 <include file-name="QImage" location="global"/>
4100 <include file-name="QPixmap" location="global"/>
4101 <include file-name="QPixmap" location="global"/>
4101 <include file-name="QRect" location="global"/>
4102 <include file-name="QRect" location="global"/>
4102 <include file-name="QSize" location="global"/>
4103 <include file-name="QSize" location="global"/>
4103 </extra-includes>
4104 </extra-includes>
4104 <modify-function signature="cacheMode()">
4105 <modify-function signature="cacheMode()">
4105 <remove/>
4106 <remove/>
4106 </modify-function>
4107 </modify-function>
4107 <modify-function signature="setDevice(QIODevice*)">
4108 <modify-function signature="setDevice(QIODevice*)">
4108 <modify-argument index="1">
4109 <modify-argument index="1">
4109 <reference-count action="set" variable-name="__rcDevice"/>
4110 <reference-count action="set" variable-name="__rcDevice"/>
4110 </modify-argument>
4111 </modify-argument>
4111 </modify-function>
4112 </modify-function>
4112 </object-type>
4113 </object-type>
4113
4114
4114 <object-type name="QPageSetupDialog"/>
4115 <object-type name="QPageSetupDialog"/>
4115
4116
4116 <object-type name="QTabWidget">
4117 <object-type name="QTabWidget">
4117 <modify-function signature="initStyleOption(QStyleOptionTabWidgetFrame*)const">
4118 <modify-function signature="initStyleOption(QStyleOptionTabWidgetFrame*)const">
4118 <access modifier="private"/>
4119 <access modifier="private"/>
4119 </modify-function>
4120 </modify-function>
4120 <inject-code>
4121 <inject-code>
4121 <insert-template name="gui.init_style_option">
4122 <insert-template name="gui.init_style_option">
4122 <replace from="%TYPE" to="QStyleOptionTabWidgetFrame"/>
4123 <replace from="%TYPE" to="QStyleOptionTabWidgetFrame"/>
4123 </insert-template>
4124 </insert-template>
4124 </inject-code>
4125 </inject-code>
4125 <modify-function signature="addTab(QWidget*,QIcon,QString)">
4126 <modify-function signature="addTab(QWidget*,QIcon,QString)">
4126 <modify-argument index="1">
4127 <modify-argument index="1">
4127 <reference-count action="ignore"/>
4128 <reference-count action="ignore"/>
4128 </modify-argument>
4129 </modify-argument>
4129 </modify-function>
4130 </modify-function>
4130 <modify-function signature="addTab(QWidget*,QString)">
4131 <modify-function signature="addTab(QWidget*,QString)">
4131 <modify-argument index="1">
4132 <modify-argument index="1">
4132 <reference-count action="ignore"/>
4133 <reference-count action="ignore"/>
4133 </modify-argument>
4134 </modify-argument>
4134 </modify-function>
4135 </modify-function>
4135 <modify-function signature="insertTab(int,QWidget*,QString)">
4136 <modify-function signature="insertTab(int,QWidget*,QString)">
4136 <modify-argument index="2">
4137 <modify-argument index="2">
4137 <reference-count action="ignore"/>
4138 <reference-count action="ignore"/>
4138 </modify-argument>
4139 </modify-argument>
4139 </modify-function>
4140 </modify-function>
4140 <modify-function signature="insertTab(int,QWidget*,QIcon,QString)">
4141 <modify-function signature="insertTab(int,QWidget*,QIcon,QString)">
4141 <modify-argument index="2">
4142 <modify-argument index="2">
4142 <reference-count action="ignore"/>
4143 <reference-count action="ignore"/>
4143 </modify-argument>
4144 </modify-argument>
4144 </modify-function>
4145 </modify-function>
4145 <modify-function signature="setCornerWidget(QWidget*,Qt::Corner)">
4146 <modify-function signature="setCornerWidget(QWidget*,Qt::Corner)">
4146 <modify-argument index="1">
4147 <modify-argument index="1">
4147 <reference-count action="ignore"/>
4148 <reference-count action="ignore"/>
4148 </modify-argument>
4149 </modify-argument>
4149 </modify-function>
4150 </modify-function>
4150 <modify-function signature="setCurrentWidget(QWidget*)">
4151 <modify-function signature="setCurrentWidget(QWidget*)">
4151 <modify-argument index="1">
4152 <modify-argument index="1">
4152 <reference-count action="ignore"/>
4153 <reference-count action="ignore"/>
4153 </modify-argument>
4154 </modify-argument>
4154 </modify-function>
4155 </modify-function>
4155 <modify-function signature="setTabBar(QTabBar*)">
4156 <modify-function signature="setTabBar(QTabBar*)">
4156 <modify-argument index="1">
4157 <modify-argument index="1">
4157 <reference-count action="ignore"/>
4158 <reference-count action="ignore"/>
4158 </modify-argument>
4159 </modify-argument>
4159 </modify-function>
4160 </modify-function>
4160 </object-type>
4161 </object-type>
4161 <object-type name="QDrag">
4162 <object-type name="QDrag">
4162 <extra-includes>
4163 <extra-includes>
4163 <include file-name="QPoint" location="global"/>
4164 <include file-name="QPoint" location="global"/>
4164 <include file-name="QPixmap" location="global"/>
4165 <include file-name="QPixmap" location="global"/>
4165 </extra-includes>
4166 </extra-includes>
4166 <modify-function signature="setMimeData(QMimeData*)">
4167 <modify-function signature="setMimeData(QMimeData*)">
4167 <modify-argument index="1">
4168 <modify-argument index="1">
4168 <define-ownership class="java" owner="c++"/>
4169 <define-ownership class="java" owner="c++"/>
4169 </modify-argument>
4170 </modify-argument>
4170 </modify-function>
4171 </modify-function>
4171
4172
4172 <modify-function signature="start(QFlags&lt;Qt::DropAction&gt;)" remove="all"/> <!--### Obsolete in 4.3-->
4173 <modify-function signature="start(QFlags&lt;Qt::DropAction&gt;)" remove="all"/> <!--### Obsolete in 4.3-->
4173 </object-type>
4174 </object-type>
4174
4175
4175 <object-type name="QDateTimeEdit">
4176 <object-type name="QDateTimeEdit">
4176 <modify-function signature="initStyleOption(QStyleOptionSpinBox*)const" access="private" rename="initDateTimeEditStyleOption"/>
4177 <modify-function signature="initStyleOption(QStyleOptionSpinBox*)const" access="private" rename="initDateTimeEditStyleOption"/>
4177 <modify-function signature="setCalendarWidget(QCalendarWidget*)">
4178 <modify-function signature="setCalendarWidget(QCalendarWidget*)">
4178 <modify-argument index="1">
4179 <modify-argument index="1">
4179 <!-- Safe to ignore because widget is reparented -->
4180 <!-- Safe to ignore because widget is reparented -->
4180 <reference-count action="ignore"/>
4181 <reference-count action="ignore"/>
4181 </modify-argument>
4182 </modify-argument>
4182 </modify-function>
4183 </modify-function>
4183
4184
4184 </object-type>
4185 </object-type>
4185
4186
4186 <object-type name="QSortFilterProxyModel">
4187 <object-type name="QSortFilterProxyModel">
4187 <modify-function signature="parent()const" remove="all"/>
4188 <modify-function signature="parent()const" remove="all"/>
4188 <extra-includes>
4189 <extra-includes>
4189 <include file-name="QItemSelection" location="global"/>
4190 <include file-name="QItemSelection" location="global"/>
4190 <include file-name="QStringList" location="global"/>
4191 <include file-name="QStringList" location="global"/>
4191 <include file-name="QSize" location="global"/>
4192 <include file-name="QSize" location="global"/>
4192 </extra-includes>
4193 </extra-includes>
4193
4194
4194 <modify-function signature="setSourceModel(QAbstractItemModel *)">
4195 <modify-function signature="setSourceModel(QAbstractItemModel *)">
4195 <modify-argument index="1">
4196 <modify-argument index="1">
4196 <reference-count action="set" variable-name="__rcSourceModel"/>
4197 <reference-count action="set" variable-name="__rcSourceModel"/>
4197 </modify-argument>
4198 </modify-argument>
4198 </modify-function>
4199 </modify-function>
4199
4200
4200 <modify-function signature="clear()" remove="all"/> <!--### Obsolete in 4.3-->
4201 <modify-function signature="clear()" remove="all"/> <!--### Obsolete in 4.3-->
4201 <modify-function signature="filterChanged()" remove="all"/> <!--### Obsolete in 4.3-->
4202 <modify-function signature="filterChanged()" remove="all"/> <!--### Obsolete in 4.3-->
4202 </object-type>
4203 </object-type>
4203
4204
4204 <object-type name="QSlider">
4205 <object-type name="QSlider">
4205 <modify-function signature="initStyleOption(QStyleOptionSlider*)const">
4206 <modify-function signature="initStyleOption(QStyleOptionSlider*)const">
4206 <access modifier="private"/>
4207 <access modifier="private"/>
4207 </modify-function>
4208 </modify-function>
4208 </object-type>
4209 </object-type>
4209
4210
4210 <object-type name="QInputContext">
4211 <object-type name="QInputContext">
4211 <extra-includes>
4212 <extra-includes>
4212 <include file-name="QTextFormat" location="global"/>
4213 <include file-name="QTextFormat" location="global"/>
4213 </extra-includes>
4214 </extra-includes>
4214 <modify-function signature="setFocusWidget(QWidget*)">
4215 <modify-function signature="setFocusWidget(QWidget*)">
4215 <remove/>
4216 <remove/>
4216 </modify-function>
4217 </modify-function>
4217 <modify-function signature="filterEvent(const QEvent*)">
4218 <modify-function signature="filterEvent(const QEvent*)">
4218 <modify-argument index="1" invalidate-after-use="yes"/>
4219 <modify-argument index="1" invalidate-after-use="yes"/>
4219 </modify-function>
4220 </modify-function>
4220 <modify-function signature="mouseHandler(int,QMouseEvent*)">
4221 <modify-function signature="mouseHandler(int,QMouseEvent*)">
4221 <modify-argument index="2" invalidate-after-use="yes"/>
4222 <modify-argument index="2" invalidate-after-use="yes"/>
4222 </modify-function>
4223 </modify-function>
4223
4224
4224 </object-type>
4225 </object-type>
4225
4226
4226 <object-type name="QProgressDialog">
4227 <object-type name="QProgressDialog">
4227
4228
4228 <modify-function signature="setBar(QProgressBar*)">
4229 <modify-function signature="setBar(QProgressBar*)">
4229 <modify-argument index="1">
4230 <modify-argument index="1">
4230 <define-ownership class="java" owner="c++"/>
4231 <define-ownership class="java" owner="c++"/>
4231 </modify-argument>
4232 </modify-argument>
4232 </modify-function>
4233 </modify-function>
4233 <modify-function signature="setCancelButton(QPushButton*)">
4234 <modify-function signature="setCancelButton(QPushButton*)">
4234 <modify-argument index="1">
4235 <modify-argument index="1">
4235 <!-- Safe to ignore because button is reparented -->
4236 <!-- Safe to ignore because button is reparented -->
4236 <reference-count action="ignore"/>
4237 <reference-count action="ignore"/>
4237 </modify-argument>
4238 </modify-argument>
4238 </modify-function>
4239 </modify-function>
4239 <modify-function signature="setLabel(QLabel*)">
4240 <modify-function signature="setLabel(QLabel*)">
4240 <modify-argument index="1">
4241 <modify-argument index="1">
4241 <!-- Safe to ignore because label is reparented -->
4242 <!-- Safe to ignore because label is reparented -->
4242 <reference-count action="ignore"/>
4243 <reference-count action="ignore"/>
4243 </modify-argument>
4244 </modify-argument>
4244 </modify-function>
4245 </modify-function>
4245
4246
4246 </object-type>
4247 </object-type>
4247
4248
4248 <object-type name="QLabel">
4249 <object-type name="QLabel">
4249 <modify-function signature="picture()const">
4250 <modify-function signature="picture()const">
4250 <access modifier="private"/>
4251 <access modifier="private"/>
4251 <rename to="picture_private"/>
4252 <rename to="picture_private"/>
4252 </modify-function>
4253 </modify-function>
4253
4254
4254 <modify-function signature="setBuddy(QWidget *)">
4255 <modify-function signature="setBuddy(QWidget *)">
4255 <modify-argument index="1">
4256 <modify-argument index="1">
4256 <reference-count action="set" variable-name="__rcBuddy"/>
4257 <reference-count action="set" variable-name="__rcBuddy"/>
4257 </modify-argument>
4258 </modify-argument>
4258 </modify-function>
4259 </modify-function>
4259 <modify-function signature="setMovie(QMovie *)">
4260 <modify-function signature="setMovie(QMovie *)">
4260 <modify-argument index="1">
4261 <modify-argument index="1">
4261 <reference-count action="set" variable-name="__rcMovie"/>
4262 <reference-count action="set" variable-name="__rcMovie"/>
4262 </modify-argument>
4263 </modify-argument>
4263 </modify-function>
4264 </modify-function>
4264 <modify-function signature="pixmap()const">
4265 <modify-function signature="pixmap()const">
4265 <access modifier="private"/>
4266 <access modifier="private"/>
4266 <rename to="pixmap_private"/>
4267 <rename to="pixmap_private"/>
4267 </modify-function>
4268 </modify-function>
4268 </object-type>
4269 </object-type>
4269
4270
4270 <object-type name="QFileDialog">
4271 <object-type name="QFileDialog">
4271 <extra-includes>
4272 <extra-includes>
4272 <include file-name="QUrl" location="global"/>
4273 <include file-name="QUrl" location="global"/>
4273 <include file-name="QAbstractProxyModel" location="global"/>
4274 <include file-name="QAbstractProxyModel" location="global"/>
4274 </extra-includes>
4275 </extra-includes>
4275 <!--
4276 <!--
4276 <modify-function signature="getOpenFileName(QWidget*,QString,QString,QString,QString*,QFlags&lt;QFileDialog::Option&gt;)">
4277 <modify-function signature="getOpenFileName(QWidget*,QString,QString,QString,QString*,QFlags&lt;QFileDialog::Option&gt;)">
4277 <access modifier="private"/>
4278 <access modifier="private"/>
4278 <modify-argument index="1">
4279 <modify-argument index="1">
4279 <remove-default-expression/>
4280 <remove-default-expression/>
4280 </modify-argument>
4281 </modify-argument>
4281 <modify-argument index="2">
4282 <modify-argument index="2">
4282 <remove-default-expression/>
4283 <remove-default-expression/>
4283 </modify-argument>
4284 </modify-argument>
4284 <modify-argument index="3">
4285 <modify-argument index="3">
4285 <remove-default-expression/>
4286 <remove-default-expression/>
4286 </modify-argument>
4287 </modify-argument>
4287 <modify-argument index="4">
4288 <modify-argument index="4">
4288 <remove-default-expression/>
4289 <remove-default-expression/>
4289 </modify-argument>
4290 </modify-argument>
4290 <modify-argument index="5">
4291 <modify-argument index="5">
4291 <remove-default-expression/>
4292 <remove-default-expression/>
4292 </modify-argument>
4293 </modify-argument>
4293 <modify-argument index="6">
4294 <modify-argument index="6">
4294 <remove-default-expression/>
4295 <remove-default-expression/>
4295 </modify-argument>
4296 </modify-argument>
4296 </modify-function>
4297 </modify-function>
4297
4298
4298 <modify-function signature="getOpenFileNames(QWidget*,QString,QString,QString,QString*,QFlags&lt;QFileDialog::Option&gt;)">
4299 <modify-function signature="getOpenFileNames(QWidget*,QString,QString,QString,QString*,QFlags&lt;QFileDialog::Option&gt;)">
4299 <access modifier="private"/>
4300 <access modifier="private"/>
4300 <modify-argument index="1">
4301 <modify-argument index="1">
4301 <remove-default-expression/>
4302 <remove-default-expression/>
4302 </modify-argument>
4303 </modify-argument>
4303 <modify-argument index="2">
4304 <modify-argument index="2">
4304 <remove-default-expression/>
4305 <remove-default-expression/>
4305 </modify-argument>
4306 </modify-argument>
4306 <modify-argument index="3">
4307 <modify-argument index="3">
4307 <remove-default-expression/>
4308 <remove-default-expression/>
4308 </modify-argument>
4309 </modify-argument>
4309 <modify-argument index="4">
4310 <modify-argument index="4">
4310 <remove-default-expression/>
4311 <remove-default-expression/>
4311 </modify-argument>
4312 </modify-argument>
4312 <modify-argument index="5">
4313 <modify-argument index="5">
4313 <remove-default-expression/>
4314 <remove-default-expression/>
4314 </modify-argument>
4315 </modify-argument>
4315 <modify-argument index="6">
4316 <modify-argument index="6">
4316 <remove-default-expression/>
4317 <remove-default-expression/>
4317 </modify-argument>
4318 </modify-argument>
4318 </modify-function>
4319 </modify-function>
4319
4320
4320 <modify-function signature="getSaveFileName(QWidget*,QString,QString,QString,QString*,QFlags&lt;QFileDialog::Option&gt;)">
4321 <modify-function signature="getSaveFileName(QWidget*,QString,QString,QString,QString*,QFlags&lt;QFileDialog::Option&gt;)">
4321 <access modifier="private"/>
4322 <access modifier="private"/>
4322 <modify-argument index="1">
4323 <modify-argument index="1">
4323 <remove-default-expression/>
4324 <remove-default-expression/>
4324 </modify-argument>
4325 </modify-argument>
4325 <modify-argument index="2">
4326 <modify-argument index="2">
4326 <remove-default-expression/>
4327 <remove-default-expression/>
4327 </modify-argument>
4328 </modify-argument>
4328 <modify-argument index="3">
4329 <modify-argument index="3">
4329 <remove-default-expression/>
4330 <remove-default-expression/>
4330 </modify-argument>
4331 </modify-argument>
4331 <modify-argument index="4">
4332 <modify-argument index="4">
4332 <remove-default-expression/>
4333 <remove-default-expression/>
4333 </modify-argument>
4334 </modify-argument>
4334 <modify-argument index="5">
4335 <modify-argument index="5">
4335 <remove-default-expression/>
4336 <remove-default-expression/>
4336 </modify-argument>
4337 </modify-argument>
4337 <modify-argument index="6">
4338 <modify-argument index="6">
4338 <remove-default-expression/>
4339 <remove-default-expression/>
4339 </modify-argument>
4340 </modify-argument>
4340 </modify-function>
4341 </modify-function>
4341 -->
4342 -->
4342
4343
4343 <modify-function signature="setIconProvider(QFileIconProvider*)">
4344 <modify-function signature="setIconProvider(QFileIconProvider*)">
4344 <modify-argument index="1">
4345 <modify-argument index="1">
4345 <reference-count action="set" variable-name="__rcIconProvider"/>
4346 <reference-count action="set" variable-name="__rcIconProvider"/>
4346 </modify-argument>
4347 </modify-argument>
4347 </modify-function>
4348 </modify-function>
4348
4349
4349 <modify-function signature="setItemDelegate(QAbstractItemDelegate*)">
4350 <modify-function signature="setItemDelegate(QAbstractItemDelegate*)">
4350 <modify-argument index="1">
4351 <modify-argument index="1">
4351 <reference-count action="set" variable-name="__rcItemDelegate"/>
4352 <reference-count action="set" variable-name="__rcItemDelegate"/>
4352 </modify-argument>
4353 </modify-argument>
4353 </modify-function>
4354 </modify-function>
4354
4355
4355 <modify-function signature="setProxyModel(QAbstractProxyModel*)">
4356 <modify-function signature="setProxyModel(QAbstractProxyModel*)">
4356 <modify-argument index="1">
4357 <modify-argument index="1">
4357 <!-- Reparented -->
4358 <!-- Reparented -->
4358 <reference-count action="ignore"/>
4359 <reference-count action="ignore"/>
4359 </modify-argument>
4360 </modify-argument>
4360 </modify-function>
4361 </modify-function>
4361
4362
4362 </object-type>
4363 </object-type>
4363
4364
4364 <object-type name="QErrorMessage"/>
4365 <object-type name="QErrorMessage"/>
4365
4366
4366 <object-type name="QTabBar">
4367 <object-type name="QTabBar">
4367 <extra-includes>
4368 <extra-includes>
4368 <include file-name="QIcon" location="global"/>
4369 <include file-name="QIcon" location="global"/>
4369 </extra-includes>
4370 </extra-includes>
4370 <modify-function signature="initStyleOption(QStyleOptionTab*,int)const">
4371 <modify-function signature="initStyleOption(QStyleOptionTab*,int)const">
4371 <access modifier="private"/>
4372 <access modifier="private"/>
4372 </modify-function>
4373 </modify-function>
4373 <modify-function signature="setTabButton(int,QTabBar::ButtonPosition,QWidget*)">
4374 <modify-function signature="setTabButton(int,QTabBar::ButtonPosition,QWidget*)">
4374 <modify-argument index="3">
4375 <modify-argument index="3">
4375 <reference-count action="ignore"/>
4376 <reference-count action="ignore"/>
4376 </modify-argument>
4377 </modify-argument>
4377 </modify-function>
4378 </modify-function>
4378 </object-type>
4379 </object-type>
4379
4380
4380 <object-type name="QStandardItemModel">
4381 <object-type name="QStandardItemModel">
4381 <modify-function signature="insertColumn(int,const QModelIndex &amp;)" remove="all"/>
4382 <modify-function signature="insertColumn(int,const QModelIndex &amp;)" remove="all"/>
4382 <modify-function signature="insertRow(int,const QModelIndex &amp;)" remove="all"/>
4383 <modify-function signature="insertRow(int,const QModelIndex &amp;)" remove="all"/>
4383 <modify-function signature="parent()const" remove="all"/>
4384 <modify-function signature="parent()const" remove="all"/>
4384 <extra-includes>
4385 <extra-includes>
4385 <include file-name="QStringList" location="global"/>
4386 <include file-name="QStringList" location="global"/>
4386 <include file-name="QSize" location="global"/>
4387 <include file-name="QSize" location="global"/>
4387 </extra-includes>
4388 </extra-includes>
4388
4389
4389 <modify-function signature="appendColumn(const QList&lt;QStandardItem *&gt;&amp;)">
4390 <modify-function signature="appendColumn(const QList&lt;QStandardItem *&gt;&amp;)">
4390 <modify-argument index="1">
4391 <modify-argument index="1">
4391 <define-ownership class="java" owner="c++"/>
4392 <define-ownership class="java" owner="c++"/>
4392 </modify-argument>
4393 </modify-argument>
4393 </modify-function>
4394 </modify-function>
4394 <modify-function signature="takeColumn(int)">
4395 <modify-function signature="takeColumn(int)">
4395 <modify-argument index="return">
4396 <modify-argument index="return">
4396 <define-ownership class="java" owner="default"/>
4397 <define-ownership class="java" owner="default"/>
4397 </modify-argument>
4398 </modify-argument>
4398 </modify-function>
4399 </modify-function>
4399 <modify-function signature="takeRow(int)">
4400 <modify-function signature="takeRow(int)">
4400 <modify-argument index="return">
4401 <modify-argument index="return">
4401 <define-ownership class="java" owner="default"/>
4402 <define-ownership class="java" owner="default"/>
4402 </modify-argument>
4403 </modify-argument>
4403 </modify-function>
4404 </modify-function>
4404 <modify-function signature="takeHorizontalHeaderItem(int)">
4405 <modify-function signature="takeHorizontalHeaderItem(int)">
4405 <modify-argument index="return">
4406 <modify-argument index="return">
4406 <define-ownership class="java" owner="default"/>
4407 <define-ownership class="java" owner="default"/>
4407 </modify-argument>
4408 </modify-argument>
4408 </modify-function>
4409 </modify-function>
4409 <modify-function signature="takeVerticalHeaderItem(int)">
4410 <modify-function signature="takeVerticalHeaderItem(int)">
4410 <modify-argument index="return">
4411 <modify-argument index="return">
4411 <define-ownership class="java" owner="default"/>
4412 <define-ownership class="java" owner="default"/>
4412 </modify-argument>
4413 </modify-argument>
4413 </modify-function>
4414 </modify-function>
4414 <modify-function signature="takeItem(int,int)">
4415 <modify-function signature="takeItem(int,int)">
4415 <modify-argument index="return">
4416 <modify-argument index="return">
4416 <define-ownership class="java" owner="default"/>
4417 <define-ownership class="java" owner="default"/>
4417 </modify-argument>
4418 </modify-argument>
4418 </modify-function>
4419 </modify-function>
4419 <modify-function signature="appendRow(const QList&lt;QStandardItem *&gt;&amp;)">
4420 <modify-function signature="appendRow(const QList&lt;QStandardItem *&gt;&amp;)">
4420 <modify-argument index="1">
4421 <modify-argument index="1">
4421 <define-ownership class="java" owner="c++"/>
4422 <define-ownership class="java" owner="c++"/>
4422 </modify-argument>
4423 </modify-argument>
4423 </modify-function>
4424 </modify-function>
4424 <modify-function signature="appendRow(QStandardItem *)">
4425 <modify-function signature="appendRow(QStandardItem *)">
4425 <modify-argument index="1">
4426 <modify-argument index="1">
4426 <define-ownership class="java" owner="c++"/>
4427 <define-ownership class="java" owner="c++"/>
4427 </modify-argument>
4428 </modify-argument>
4428 </modify-function>
4429 </modify-function>
4429 <modify-function signature="insertColumn(int, const QList&lt;QStandardItem *&gt;&amp;)">
4430 <modify-function signature="insertColumn(int, const QList&lt;QStandardItem *&gt;&amp;)">
4430 <modify-argument index="2">
4431 <modify-argument index="2">
4431 <define-ownership class="java" owner="c++"/>
4432 <define-ownership class="java" owner="c++"/>
4432 </modify-argument>
4433 </modify-argument>
4433 </modify-function>
4434 </modify-function>
4434 <modify-function signature="insertRow(int, const QList&lt;QStandardItem *&gt;&amp;)">
4435 <modify-function signature="insertRow(int, const QList&lt;QStandardItem *&gt;&amp;)">
4435 <modify-argument index="2">
4436 <modify-argument index="2">
4436 <define-ownership class="java" owner="c++"/>
4437 <define-ownership class="java" owner="c++"/>
4437 </modify-argument>
4438 </modify-argument>
4438 </modify-function>
4439 </modify-function>
4439 <modify-function signature="insertRow(int, QStandardItem *)">
4440 <modify-function signature="insertRow(int, QStandardItem *)">
4440 <modify-argument index="2">
4441 <modify-argument index="2">
4441 <define-ownership class="java" owner="c++"/>
4442 <define-ownership class="java" owner="c++"/>
4442 </modify-argument>
4443 </modify-argument>
4443 </modify-function>
4444 </modify-function>
4444 <modify-function signature="setHorizontalHeaderItem(int, QStandardItem *)">
4445 <modify-function signature="setHorizontalHeaderItem(int, QStandardItem *)">
4445 <modify-argument index="2">
4446 <modify-argument index="2">
4446 <define-ownership class="java" owner="c++"/>
4447 <define-ownership class="java" owner="c++"/>
4447 </modify-argument>
4448 </modify-argument>
4448 </modify-function>
4449 </modify-function>
4449 <modify-function signature="setItem(int, int, QStandardItem *)">
4450 <modify-function signature="setItem(int, int, QStandardItem *)">
4450 <modify-argument index="3">
4451 <modify-argument index="3">
4451 <define-ownership class="java" owner="c++"/>
4452 <define-ownership class="java" owner="c++"/>
4452 </modify-argument>
4453 </modify-argument>
4453 </modify-function>
4454 </modify-function>
4454 <modify-function signature="setItem(int, QStandardItem *)">
4455 <modify-function signature="setItem(int, QStandardItem *)">
4455 <modify-argument index="2">
4456 <modify-argument index="2">
4456 <define-ownership class="java" owner="c++"/>
4457 <define-ownership class="java" owner="c++"/>
4457 </modify-argument>
4458 </modify-argument>
4458 </modify-function>
4459 </modify-function>
4459 <modify-function signature="setItemPrototype(const QStandardItem *)">
4460 <modify-function signature="setItemPrototype(const QStandardItem *)">
4460 <modify-argument index="1">
4461 <modify-argument index="1">
4461 <define-ownership class="java" owner="c++"/>
4462 <define-ownership class="java" owner="c++"/>
4462 </modify-argument>
4463 </modify-argument>
4463 </modify-function>
4464 </modify-function>
4464 <modify-function signature="setVerticalHeaderItem(int, QStandardItem *)">
4465 <modify-function signature="setVerticalHeaderItem(int, QStandardItem *)">
4465 <modify-argument index="2">
4466 <modify-argument index="2">
4466 <define-ownership class="java" owner="c++"/>
4467 <define-ownership class="java" owner="c++"/>
4467 </modify-argument>
4468 </modify-argument>
4468 </modify-function>
4469 </modify-function>
4469 </object-type>
4470 </object-type>
4470
4471
4471 <object-type name="QRadioButton">
4472 <object-type name="QRadioButton">
4472 <modify-function signature="initStyleOption(QStyleOptionButton*)const">
4473 <modify-function signature="initStyleOption(QStyleOptionButton*)const">
4473 <access modifier="private"/>
4474 <access modifier="private"/>
4474 </modify-function>
4475 </modify-function>
4475 </object-type>
4476 </object-type>
4476
4477
4477 <object-type name="QScrollBar">
4478 <object-type name="QScrollBar">
4478 <modify-function signature="initStyleOption(QStyleOptionSlider*)const">
4479 <modify-function signature="initStyleOption(QStyleOptionSlider*)const">
4479 <access modifier="private"/>
4480 <access modifier="private"/>
4480 </modify-function>
4481 </modify-function>
4481 </object-type>
4482 </object-type>
4482
4483
4483 <object-type name="QClipboard">
4484 <object-type name="QClipboard">
4484 <extra-includes>
4485 <extra-includes>
4485 <include file-name="QImage" location="global"/>
4486 <include file-name="QImage" location="global"/>
4486 <include file-name="QPixmap" location="global"/>
4487 <include file-name="QPixmap" location="global"/>
4487 </extra-includes>
4488 </extra-includes>
4488 <modify-function signature="setMimeData(QMimeData *, QClipboard::Mode)">
4489 <modify-function signature="setMimeData(QMimeData *, QClipboard::Mode)">
4489 <modify-argument index="1">
4490 <modify-argument index="1">
4490 <define-ownership class="java" owner="c++"/>
4491 <define-ownership class="java" owner="c++"/>
4491 </modify-argument>
4492 </modify-argument>
4492 </modify-function>
4493 </modify-function>
4493 <modify-function signature="text(QString&amp;,QClipboard::Mode)const">
4494 <modify-function signature="text(QString&amp;,QClipboard::Mode)const">
4494 <access modifier="private"/>
4495 <access modifier="private"/>
4495 <modify-argument index="2">
4496 <modify-argument index="2">
4496 <remove-default-expression/>
4497 <remove-default-expression/>
4497 </modify-argument>
4498 </modify-argument>
4498 </modify-function>
4499 </modify-function>
4499
4500
4500 </object-type>
4501 </object-type>
4501
4502
4502 <object-type name="QAbstractScrollArea">
4503 <object-type name="QAbstractScrollArea">
4503 <modify-function signature="setupViewport(QWidget *)" access="non-final"/>
4504 <modify-function signature="setupViewport(QWidget *)" access="non-final"/>
4504 <modify-function signature="addScrollBarWidget(QWidget*,QFlags&lt;Qt::AlignmentFlag&gt;)">
4505 <modify-function signature="addScrollBarWidget(QWidget*,QFlags&lt;Qt::AlignmentFlag&gt;)">
4505 <modify-argument index="1">
4506 <modify-argument index="1">
4506 <reference-count action="ignore"/>
4507 <reference-count action="ignore"/>
4507 </modify-argument>
4508 </modify-argument>
4508 </modify-function>
4509 </modify-function>
4509 <modify-function signature="setCornerWidget(QWidget*)">
4510 <modify-function signature="setCornerWidget(QWidget*)">
4510 <modify-argument index="1">
4511 <modify-argument index="1">
4511 <reference-count action="ignore"/>
4512 <reference-count action="ignore"/>
4512 </modify-argument>
4513 </modify-argument>
4513 </modify-function>
4514 </modify-function>
4514 <modify-function signature="setHorizontalScrollBar(QScrollBar*)">
4515 <modify-function signature="setHorizontalScrollBar(QScrollBar*)">
4515 <modify-argument index="1">
4516 <modify-argument index="1">
4516 <reference-count action="ignore"/>
4517 <reference-count action="ignore"/>
4517 </modify-argument>
4518 </modify-argument>
4518 </modify-function>
4519 </modify-function>
4519
4520
4520 <modify-function signature="setVerticalScrollBar(QScrollBar*)">
4521 <modify-function signature="setVerticalScrollBar(QScrollBar*)">
4521 <modify-argument index="1">
4522 <modify-argument index="1">
4522 <reference-count action="ignore"/>
4523 <reference-count action="ignore"/>
4523 </modify-argument>
4524 </modify-argument>
4524 </modify-function>
4525 </modify-function>
4525
4526
4526 <modify-function signature="setViewport(QWidget*)">
4527 <modify-function signature="setViewport(QWidget*)">
4527 <modify-argument index="1">
4528 <modify-argument index="1">
4528 <reference-count action="ignore"/>
4529 <reference-count action="ignore"/>
4529 </modify-argument>
4530 </modify-argument>
4530 </modify-function>
4531 </modify-function>
4531
4532
4532 <modify-function signature="setupViewport(QWidget*)">
4533 <modify-function signature="setupViewport(QWidget*)">
4533 <modify-argument index="1">
4534 <modify-argument index="1">
4534 <reference-count action="ignore"/>
4535 <reference-count action="ignore"/>
4535 </modify-argument>
4536 </modify-argument>
4536 </modify-function>
4537 </modify-function>
4537
4538
4538 <modify-function signature="viewportEvent(QEvent*)">
4539 <modify-function signature="viewportEvent(QEvent*)">
4539 <modify-argument index="1" invalidate-after-use="yes"/>
4540 <modify-argument index="1" invalidate-after-use="yes"/>
4540 </modify-function>
4541 </modify-function>
4541
4542
4542 </object-type>
4543 </object-type>
4543
4544
4544 <object-type name="QPaintEngineState">
4545 <object-type name="QPaintEngineState">
4545 <extra-includes>
4546 <extra-includes>
4546 <include file-name="QPainterPath" location="global"/>
4547 <include file-name="QPainterPath" location="global"/>
4547 </extra-includes>
4548 </extra-includes>
4548 </object-type>
4549 </object-type>
4549
4550
4550 <object-type name="QRubberBand">
4551 <object-type name="QRubberBand">
4551 <modify-function signature="initStyleOption(QStyleOptionRubberBand*)const">
4552 <modify-function signature="initStyleOption(QStyleOptionRubberBand*)const">
4552 <access modifier="private"/>
4553 <access modifier="private"/>
4553 </modify-function>
4554 </modify-function>
4554 <modify-function signature="move(int,int)" rename="moveRubberBand"/>
4555 <modify-function signature="move(int,int)" rename="moveRubberBand"/>
4555 <modify-function signature="move(const QPoint &amp;)" rename="moveRubberBand"/>
4556 <modify-function signature="move(const QPoint &amp;)" rename="moveRubberBand"/>
4556 <modify-function signature="resize(int,int)" rename="resizeRubberBand"/>
4557 <modify-function signature="resize(int,int)" rename="resizeRubberBand"/>
4557 <modify-function signature="resize(const QSize &amp;)" rename="resizeRubberBand"/>
4558 <modify-function signature="resize(const QSize &amp;)" rename="resizeRubberBand"/>
4558 <modify-function signature="setGeometry(int,int,int,int)" rename="setRubberBandGeometry"/>
4559 <modify-function signature="setGeometry(int,int,int,int)" rename="setRubberBandGeometry"/>
4559 <modify-function signature="setGeometry(const QRect &amp;)" rename="setRubberBandGeometry"/>
4560 <modify-function signature="setGeometry(const QRect &amp;)" rename="setRubberBandGeometry"/>
4560 </object-type>
4561 </object-type>
4561
4562
4562 <object-type name="QTextLayout">
4563 <object-type name="QTextLayout">
4563 <extra-includes>
4564 <extra-includes>
4564 <include file-name="QTextOption" location="global"/>
4565 <include file-name="QTextOption" location="global"/>
4565 </extra-includes>
4566 </extra-includes>
4566 </object-type>
4567 </object-type>
4567
4568
4568 <object-type name="QTableWidget">
4569 <object-type name="QTableWidget">
4569 <modify-function signature="mimeData(const QList&lt;QTableWidgetItem*&gt;)const">
4570 <modify-function signature="mimeData(const QList&lt;QTableWidgetItem*&gt;)const">
4570 <modify-argument index="1" invalidate-after-use="yes"/>
4571 <modify-argument index="1" invalidate-after-use="yes"/>
4571 </modify-function>
4572 </modify-function>
4572 <modify-function signature="isSortingEnabled()const" remove="all"/>
4573 <modify-function signature="isSortingEnabled()const" remove="all"/>
4573 <modify-function signature="setSortingEnabled(bool)" remove="all"/>
4574 <modify-function signature="setSortingEnabled(bool)" remove="all"/>
4574 <modify-function signature="setHorizontalHeaderItem(int, QTableWidgetItem *)">
4575 <modify-function signature="setHorizontalHeaderItem(int, QTableWidgetItem *)">
4575 <modify-argument index="2">
4576 <modify-argument index="2">
4576 <define-ownership class="java" owner="c++"/>
4577 <define-ownership class="java" owner="c++"/>
4577 </modify-argument>
4578 </modify-argument>
4578 </modify-function>
4579 </modify-function>
4579 <modify-function signature="setItem(int, int, QTableWidgetItem *)">
4580 <modify-function signature="setItem(int, int, QTableWidgetItem *)">
4580 <modify-argument index="3">
4581 <modify-argument index="3">
4581 <define-ownership class="java" owner="c++"/>
4582 <define-ownership class="java" owner="c++"/>
4582 </modify-argument>
4583 </modify-argument>
4583 </modify-function>
4584 </modify-function>
4584 <modify-function signature="takeHorizontalHeaderItem(int)">
4585 <modify-function signature="takeHorizontalHeaderItem(int)">
4585 <modify-argument index="return">
4586 <modify-argument index="return">
4586 <define-ownership class="java" owner="default"/>
4587 <define-ownership class="java" owner="default"/>
4587 </modify-argument>
4588 </modify-argument>
4588 </modify-function>
4589 </modify-function>
4589 <modify-function signature="takeVerticalHeaderItem(int)">
4590 <modify-function signature="takeVerticalHeaderItem(int)">
4590 <modify-argument index="return">
4591 <modify-argument index="return">
4591 <define-ownership class="java" owner="default"/>
4592 <define-ownership class="java" owner="default"/>
4592 </modify-argument>
4593 </modify-argument>
4593 </modify-function>
4594 </modify-function>
4594 <modify-function signature="takeItem(int,int)">
4595 <modify-function signature="takeItem(int,int)">
4595 <modify-argument index="return">
4596 <modify-argument index="return">
4596 <define-ownership class="java" owner="default"/>
4597 <define-ownership class="java" owner="default"/>
4597 </modify-argument>
4598 </modify-argument>
4598 </modify-function>
4599 </modify-function>
4599 <modify-function signature="setItemPrototype(const QTableWidgetItem *)">
4600 <modify-function signature="setItemPrototype(const QTableWidgetItem *)">
4600 <modify-argument index="1">
4601 <modify-argument index="1">
4601 <define-ownership class="java" owner="c++"/>
4602 <define-ownership class="java" owner="c++"/>
4602 </modify-argument>
4603 </modify-argument>
4603 </modify-function>
4604 </modify-function>
4604 <modify-function signature="setVerticalHeaderItem(int, QTableWidgetItem *)">
4605 <modify-function signature="setVerticalHeaderItem(int, QTableWidgetItem *)">
4605 <modify-argument index="2">
4606 <modify-argument index="2">
4606 <define-ownership class="java" owner="c++"/>
4607 <define-ownership class="java" owner="c++"/>
4607 </modify-argument>
4608 </modify-argument>
4608 </modify-function>
4609 </modify-function>
4609 <modify-function signature="setCellWidget(int,int,QWidget*)">
4610 <modify-function signature="setCellWidget(int,int,QWidget*)">
4610 <modify-argument index="3">
4611 <modify-argument index="3">
4611 <reference-count action="ignore"/>
4612 <reference-count action="ignore"/>
4612 </modify-argument>
4613 </modify-argument>
4613 </modify-function>
4614 </modify-function>
4614 <modify-function signature="setCurrentItem(QTableWidgetItem*)">
4615 <modify-function signature="setCurrentItem(QTableWidgetItem*)">
4615 <modify-argument index="1">
4616 <modify-argument index="1">
4616 <reference-count action="ignore"/>
4617 <reference-count action="ignore"/>
4617 </modify-argument>
4618 </modify-argument>
4618 </modify-function>
4619 </modify-function>
4619 <modify-function signature="setCurrentItem(QTableWidgetItem*,QFlags&lt;QItemSelectionModel::SelectionFlag&gt;)">
4620 <modify-function signature="setCurrentItem(QTableWidgetItem*,QFlags&lt;QItemSelectionModel::SelectionFlag&gt;)">
4620 <modify-argument index="1">
4621 <modify-argument index="1">
4621 <reference-count action="ignore"/>
4622 <reference-count action="ignore"/>
4622 </modify-argument>
4623 </modify-argument>
4623 </modify-function>
4624 </modify-function>
4624 <modify-function signature="setItemSelected(const QTableWidgetItem*,bool)">
4625 <modify-function signature="setItemSelected(const QTableWidgetItem*,bool)">
4625 <remove/>
4626 <remove/>
4626 </modify-function>
4627 </modify-function>
4627 <modify-function signature="isItemSelected(const QTableWidgetItem*)const">
4628 <modify-function signature="isItemSelected(const QTableWidgetItem*)const">
4628 <remove/>
4629 <remove/>
4629 </modify-function>
4630 </modify-function>
4630 <modify-function signature="setModel(QAbstractItemModel*)">
4631 <modify-function signature="setModel(QAbstractItemModel*)">
4631 <modify-argument index="1">
4632 <modify-argument index="1">
4632 <reference-count action="ignore"/>
4633 <reference-count action="ignore"/>
4633 </modify-argument>
4634 </modify-argument>
4634 </modify-function>
4635 </modify-function>
4635
4636
4636 <modify-function signature="mimeData(const QList&lt;QTableWidgetItem*&gt;)const" remove="all"/>
4637 <modify-function signature="mimeData(const QList&lt;QTableWidgetItem*&gt;)const" remove="all"/>
4637 </object-type>
4638 </object-type>
4638 <object-type name="QTextDocument">
4639 <object-type name="QTextDocument">
4639 <extra-includes>
4640 <extra-includes>
4640 <include file-name="QTextBlock" location="global"/>
4641 <include file-name="QTextBlock" location="global"/>
4641 <include file-name="QTextFormat" location="global"/>
4642 <include file-name="QTextFormat" location="global"/>
4642 <include file-name="QTextCursor" location="global"/>
4643 <include file-name="QTextCursor" location="global"/>
4643 <include file-name="qabstracttextdocumentlayout.h" location="global"/>
4644 <include file-name="qabstracttextdocumentlayout.h" location="global"/>
4644 </extra-includes>
4645 </extra-includes>
4645 <modify-function signature="redo(QTextCursor*)">
4646 <modify-function signature="redo(QTextCursor*)">
4646 <access modifier="private"/>
4647 <access modifier="private"/>
4647 </modify-function>
4648 </modify-function>
4648 <modify-function signature="setDocumentLayout(QAbstractTextDocumentLayout*)">
4649 <modify-function signature="setDocumentLayout(QAbstractTextDocumentLayout*)">
4649 <modify-argument index="1">
4650 <modify-argument index="1">
4650 <define-ownership class="java" owner="c++"/>
4651 <define-ownership class="java" owner="c++"/>
4651 </modify-argument>
4652 </modify-argument>
4652 </modify-function>
4653 </modify-function>
4653
4654
4654 <modify-function signature="undo(QTextCursor*)">
4655 <modify-function signature="undo(QTextCursor*)">
4655 <access modifier="private"/>
4656 <access modifier="private"/>
4656 </modify-function>
4657 </modify-function>
4657 </object-type>
4658 </object-type>
4658
4659
4659 <object-type name="QTextDocumentWriter">
4660 <object-type name="QTextDocumentWriter">
4660 <modify-function signature="setCodec(QTextCodec*)">
4661 <modify-function signature="setCodec(QTextCodec*)">
4661 <modify-argument index="1">
4662 <modify-argument index="1">
4662 <reference-count action="set" variable-name="__rcCodec"/>
4663 <reference-count action="set" variable-name="__rcCodec"/>
4663 </modify-argument>
4664 </modify-argument>
4664 </modify-function>
4665 </modify-function>
4665 <modify-function signature="setDevice(QIODevice*)">
4666 <modify-function signature="setDevice(QIODevice*)">
4666 <modify-argument index="1">
4667 <modify-argument index="1">
4667 <reference-count action="set" variable-name="__rcDevice"/>
4668 <reference-count action="set" variable-name="__rcDevice"/>
4668 </modify-argument>
4669 </modify-argument>
4669 </modify-function>
4670 </modify-function>
4670 </object-type>
4671 </object-type>
4671
4672
4672 <object-type name="QSplitter">
4673 <object-type name="QSplitter">
4673
4674
4674 <modify-function signature="getRange(int,int*,int*)const">
4675 <modify-function signature="getRange(int,int*,int*)const">
4675 <access modifier="private"/>
4676 <access modifier="private"/>
4676 </modify-function>
4677 </modify-function>
4677 <modify-function signature="addWidget(QWidget *)">
4678 <modify-function signature="addWidget(QWidget *)">
4678 <modify-argument index="1">
4679 <modify-argument index="1">
4679 <reference-count action="ignore"/>
4680 <reference-count action="ignore"/>
4680 </modify-argument>
4681 </modify-argument>
4681 </modify-function>
4682 </modify-function>
4682 <modify-function signature="insertWidget(int, QWidget *)">
4683 <modify-function signature="insertWidget(int, QWidget *)">
4683 <modify-argument index="2">
4684 <modify-argument index="2">
4684 <reference-count action="ignore"/>
4685 <reference-count action="ignore"/>
4685 </modify-argument>
4686 </modify-argument>
4686 </modify-function>
4687 </modify-function>
4687 </object-type>
4688 </object-type>
4688
4689
4689 <object-type name="QGroupBox">
4690 <object-type name="QGroupBox">
4690 <modify-function signature="initStyleOption(QStyleOptionGroupBox*)const">
4691 <modify-function signature="initStyleOption(QStyleOptionGroupBox*)const">
4691 <access modifier="private"/>
4692 <access modifier="private"/>
4692 </modify-function>
4693 </modify-function>
4693 </object-type>
4694 </object-type>
4694
4695
4695 <object-type name="QStackedWidget">
4696 <object-type name="QStackedWidget">
4696 <modify-function signature="addWidget(QWidget*)">
4697 <modify-function signature="addWidget(QWidget*)">
4697 <modify-argument index="1">
4698 <modify-argument index="1">
4698 <reference-count action="ignore"/>
4699 <reference-count action="ignore"/>
4699 </modify-argument>
4700 </modify-argument>
4700 </modify-function>
4701 </modify-function>
4701 <modify-function signature="insertWidget(int,QWidget*)">
4702 <modify-function signature="insertWidget(int,QWidget*)">
4702 <modify-argument index="2">
4703 <modify-argument index="2">
4703 <reference-count action="ignore"/>
4704 <reference-count action="ignore"/>
4704 </modify-argument>
4705 </modify-argument>
4705 </modify-function>
4706 </modify-function>
4706 <modify-function signature="removeWidget(QWidget*)">
4707 <modify-function signature="removeWidget(QWidget*)">
4707 <modify-argument index="1">
4708 <modify-argument index="1">
4708 <reference-count action="ignore"/>
4709 <reference-count action="ignore"/>
4709 </modify-argument>
4710 </modify-argument>
4710 </modify-function>
4711 </modify-function>
4711 <modify-function signature="setCurrentWidget(QWidget*)">
4712 <modify-function signature="setCurrentWidget(QWidget*)">
4712 <modify-argument index="1">
4713 <modify-argument index="1">
4713 <reference-count action="ignore"/>
4714 <reference-count action="ignore"/>
4714 </modify-argument>
4715 </modify-argument>
4715 </modify-function>
4716 </modify-function>
4716 </object-type>
4717 </object-type>
4717
4718
4718 <object-type name="QSplitterHandle">
4719 <object-type name="QSplitterHandle">
4719 </object-type>
4720 </object-type>
4720
4721
4721 <object-type name="QDial">
4722 <object-type name="QDial">
4722 <modify-function signature="initStyleOption(QStyleOptionSlider*)const">
4723 <modify-function signature="initStyleOption(QStyleOptionSlider*)const">
4723 <access modifier="private"/>
4724 <access modifier="private"/>
4724 </modify-function>
4725 </modify-function>
4725 </object-type>
4726 </object-type>
4726
4727
4727 <object-type name="QLineEdit">
4728 <object-type name="QLineEdit">
4728 <modify-function signature="initStyleOption(QStyleOptionFrame*)const">
4729 <modify-function signature="initStyleOption(QStyleOptionFrame*)const">
4729 <access modifier="private"/>
4730 <access modifier="private"/>
4730 </modify-function>
4731 </modify-function>
4731 <modify-function signature="setCompleter(QCompleter *)">
4732 <modify-function signature="setCompleter(QCompleter *)">
4732 <modify-argument index="1">
4733 <modify-argument index="1">
4733 <reference-count action="set" variable-name="__rcCompleter"/>
4734 <reference-count action="set" variable-name="__rcCompleter"/>
4734 </modify-argument>
4735 </modify-argument>
4735 </modify-function>
4736 </modify-function>
4736 <modify-function signature="setValidator(const QValidator *)">
4737 <modify-function signature="setValidator(const QValidator *)">
4737 <modify-argument index="1">
4738 <modify-argument index="1">
4738 <reference-count action="set" variable-name="__rcValidator"/>
4739 <reference-count action="set" variable-name="__rcValidator"/>
4739 </modify-argument>
4740 </modify-argument>
4740 </modify-function>
4741 </modify-function>
4741 </object-type>
4742 </object-type>
4742
4743
4743 <object-type name="QLCDNumber"/>
4744 <object-type name="QLCDNumber"/>
4744
4745
4745 <object-type name="QSplashScreen">
4746 <object-type name="QSplashScreen">
4746 <modify-function signature="showMessage(const QString &amp;, int, const QColor &amp;)">
4747 <modify-function signature="showMessage(const QString &amp;, int, const QColor &amp;)">
4747 <modify-argument index="3">
4748 <modify-argument index="3">
4748 <replace-default-expression with="QColor.black"/>
4749 <replace-default-expression with="QColor.black"/>
4749 </modify-argument>
4750 </modify-argument>
4750 </modify-function>
4751 </modify-function>
4751 <modify-function signature="repaint()" remove="all"/>
4752 <modify-function signature="repaint()" remove="all"/>
4752 <modify-function signature="drawContents(QPainter*)">
4753 <modify-function signature="drawContents(QPainter*)">
4753 <modify-argument index="1" invalidate-after-use="yes"/>
4754 <modify-argument index="1" invalidate-after-use="yes"/>
4754 </modify-function>
4755 </modify-function>
4755 </object-type>
4756 </object-type>
4756
4757
4757 <object-type name="QDockWidget">
4758 <object-type name="QDockWidget">
4758 <modify-function signature="initStyleOption(QStyleOptionDockWidget*)const">
4759 <modify-function signature="initStyleOption(QStyleOptionDockWidget*)const">
4759 <access modifier="private"/>
4760 <access modifier="private"/>
4760 </modify-function>
4761 </modify-function>
4761 <inject-code>
4762 <inject-code>
4762 <insert-template name="gui.init_style_option">
4763 <insert-template name="gui.init_style_option">
4763 <replace from="%TYPE" to="QStyleOptionDockWidget"/>
4764 <replace from="%TYPE" to="QStyleOptionDockWidget"/>
4764 </insert-template>
4765 </insert-template>
4765 </inject-code>
4766 </inject-code>
4766 <modify-function signature="setTitleBarWidget(QWidget*)">
4767 <modify-function signature="setTitleBarWidget(QWidget*)">
4767 <modify-argument index="1">
4768 <modify-argument index="1">
4768 <reference-count action="ignore"/>
4769 <reference-count action="ignore"/>
4769 </modify-argument>
4770 </modify-argument>
4770 </modify-function>
4771 </modify-function>
4771 <modify-function signature="setWidget(QWidget*)">
4772 <modify-function signature="setWidget(QWidget*)">
4772 <modify-argument index="1">
4773 <modify-argument index="1">
4773 <reference-count action="ignore"/>
4774 <reference-count action="ignore"/>
4774 </modify-argument>
4775 </modify-argument>
4775 </modify-function>
4776 </modify-function>
4776 </object-type>
4777 </object-type>
4777
4778
4778 <object-type name="QAbstractProxyModel">
4779 <object-type name="QAbstractProxyModel">
4779 <extra-includes>
4780 <extra-includes>
4780 <include file-name="QItemSelection" location="global"/>
4781 <include file-name="QItemSelection" location="global"/>
4781 <include file-name="QStringList" location="global"/>
4782 <include file-name="QStringList" location="global"/>
4782 <include file-name="QSize" location="global"/>
4783 <include file-name="QSize" location="global"/>
4783 </extra-includes>
4784 </extra-includes>
4784
4785
4785 <modify-function signature="setSourceModel(QAbstractItemModel *)">
4786 <modify-function signature="setSourceModel(QAbstractItemModel *)">
4786 <modify-argument index="1">
4787 <modify-argument index="1">
4787 <reference-count action="set" variable-name="__rcSourceModel"/>
4788 <reference-count action="set" variable-name="__rcSourceModel"/>
4788 </modify-argument>
4789 </modify-argument>
4789 </modify-function>
4790 </modify-function>
4790
4791
4791 </object-type>
4792 </object-type>
4792
4793
4793 <object-type name="QDesktopWidget">
4794 <object-type name="QDesktopWidget">
4794 </object-type>
4795 </object-type>
4795
4796
4796 <object-type name="QFrame">
4797 <object-type name="QFrame">
4797 </object-type>
4798 </object-type>
4798
4799
4799 <object-type name="QTextTable">
4800 <object-type name="QTextTable">
4800 <modify-function signature="format() const">
4801 <modify-function signature="format() const">
4801 <rename to="tableFormat"/>
4802 <rename to="tableFormat"/>
4802 </modify-function>
4803 </modify-function>
4803 <extra-includes>
4804 <extra-includes>
4804 <include file-name="QTextCursor" location="global"/>
4805 <include file-name="QTextCursor" location="global"/>
4805 </extra-includes>
4806 </extra-includes>
4806 </object-type>
4807 </object-type>
4807
4808
4808 <object-type name="QSpinBox">
4809 <object-type name="QSpinBox">
4809 <modify-function signature="valueChanged(const QString &amp;)">
4810 <modify-function signature="valueChanged(const QString &amp;)">
4810 <rename to="valueStringChanged"/>
4811 <rename to="valueStringChanged"/>
4811 </modify-function>
4812 </modify-function>
4812 </object-type>
4813 </object-type>
4813
4814
4814 <object-type name="QTextBrowser">
4815 <object-type name="QTextBrowser">
4815 <modify-function signature="highlighted(const QString &amp;)">
4816 <modify-function signature="highlighted(const QString &amp;)">
4816 <rename to="highlightedString"/>
4817 <rename to="highlightedString"/>
4817 </modify-function>
4818 </modify-function>
4818 </object-type>
4819 </object-type>
4819
4820
4820 <object-type name="QDoubleSpinBox">
4821 <object-type name="QDoubleSpinBox">
4821 <modify-function signature="valueChanged(const QString &amp;)">
4822 <modify-function signature="valueChanged(const QString &amp;)">
4822 <rename to="valueStringChanged"/>
4823 <rename to="valueStringChanged"/>
4823 </modify-function>
4824 </modify-function>
4824 </object-type>
4825 </object-type>
4825
4826
4826 <object-type name="QButtonGroup">
4827 <object-type name="QButtonGroup">
4827 <modify-function signature="buttonClicked(int)">
4828 <modify-function signature="buttonClicked(int)">
4828 <rename to="buttonIdClicked"/>
4829 <rename to="buttonIdClicked"/>
4829 </modify-function>
4830 </modify-function>
4830 <modify-function signature="buttonPressed(int)">
4831 <modify-function signature="buttonPressed(int)">
4831 <rename to="buttonIdPressed"/>
4832 <rename to="buttonIdPressed"/>
4832 </modify-function>
4833 </modify-function>
4833 <modify-function signature="buttonReleased(int)">
4834 <modify-function signature="buttonReleased(int)">
4834 <rename to="buttonIdReleased"/>
4835 <rename to="buttonIdReleased"/>
4835 </modify-function>
4836 </modify-function>
4836 <modify-function signature="addButton(QAbstractButton *)">
4837 <modify-function signature="addButton(QAbstractButton *)">
4837 <modify-argument index="1">
4838 <modify-argument index="1">
4838 <reference-count action="add" variable-name="__rcButtons"/>
4839 <reference-count action="add" variable-name="__rcButtons"/>
4839 <no-null-pointer/>
4840 <no-null-pointer/>
4840 </modify-argument>
4841 </modify-argument>
4841 </modify-function>
4842 </modify-function>
4842 <modify-function signature="addButton(QAbstractButton *, int)">
4843 <modify-function signature="addButton(QAbstractButton *, int)">
4843 <modify-argument index="1">
4844 <modify-argument index="1">
4844 <reference-count action="add" variable-name="__rcButtons"/>
4845 <reference-count action="add" variable-name="__rcButtons"/>
4845 <no-null-pointer/>
4846 <no-null-pointer/>
4846 </modify-argument>
4847 </modify-argument>
4847 </modify-function>
4848 </modify-function>
4848 <modify-function signature="removeButton(QAbstractButton *)">
4849 <modify-function signature="removeButton(QAbstractButton *)">
4849 <modify-argument index="1">
4850 <modify-argument index="1">
4850 <reference-count action="remove" variable-name="__rcButtons"/>
4851 <reference-count action="remove" variable-name="__rcButtons"/>
4851 <no-null-pointer/>
4852 <no-null-pointer/>
4852 </modify-argument>
4853 </modify-argument>
4853 </modify-function>
4854 </modify-function>
4854 <modify-function signature="setId(QAbstractButton *,int)">
4855 <modify-function signature="setId(QAbstractButton *,int)">
4855 <modify-argument index="1">
4856 <modify-argument index="1">
4856 <reference-count action="ignore"/>
4857 <reference-count action="ignore"/>
4857 </modify-argument>
4858 </modify-argument>
4858 </modify-function>
4859 </modify-function>
4859 </object-type>
4860 </object-type>
4860
4861
4861 <object-type name="QToolBar">
4862 <object-type name="QToolBar">
4862 <modify-function signature="addAction(QAction *)" remove="all"/>
4863 <modify-function signature="addAction(QAction *)" remove="all"/>
4863 <modify-function signature="initStyleOption(QStyleOptionToolBar*)const">
4864 <modify-function signature="initStyleOption(QStyleOptionToolBar*)const">
4864 <access modifier="private"/>
4865 <access modifier="private"/>
4865 </modify-function>
4866 </modify-function>
4866 <modify-function signature="addAction(QIcon,QString,const QObject*,const char*)">
4867 <modify-function signature="addAction(QIcon,QString,const QObject*,const char*)">
4867 <remove/>
4868 <remove/>
4868 </modify-function>
4869 </modify-function>
4869 <modify-function signature="addAction(QString,const QObject*,const char*)">
4870 <modify-function signature="addAction(QString,const QObject*,const char*)">
4870 <remove/>
4871 <remove/>
4871 </modify-function>
4872 </modify-function>
4872 <modify-function signature="addWidget(QWidget*)">
4873 <modify-function signature="addWidget(QWidget*)">
4873 <modify-argument index="1">
4874 <modify-argument index="1">
4874 <define-ownership class="java" owner="c++"/>
4875 <define-ownership class="java" owner="c++"/>
4875 </modify-argument>
4876 </modify-argument>
4876 </modify-function>
4877 </modify-function>
4877 <modify-function signature="insertWidget(QAction*,QWidget*)">
4878 <modify-function signature="insertWidget(QAction*,QWidget*)">
4878 <modify-argument index="1">
4879 <modify-argument index="1">
4879 <reference-count action="ignore"/>
4880 <reference-count action="ignore"/>
4880 </modify-argument>
4881 </modify-argument>
4881 <modify-argument index="2">
4882 <modify-argument index="2">
4882 <define-ownership class="java" owner="c++"/>
4883 <define-ownership class="java" owner="c++"/>
4883 </modify-argument>
4884 </modify-argument>
4884 </modify-function>
4885 </modify-function>
4885 <modify-function signature="insertSeparator(QAction*)">
4886 <modify-function signature="insertSeparator(QAction*)">
4886 <modify-argument index="1">
4887 <modify-argument index="1">
4887 <reference-count action="ignore"/>
4888 <reference-count action="ignore"/>
4888 </modify-argument>
4889 </modify-argument>
4889 </modify-function>
4890 </modify-function>
4890 <inject-code class="pywrap-h">
4891
4891 QAction* addAction (QToolBar* menu, const QString &amp; text, PyObject* callable)
4892 <inject-code class="pywrap-h">
4892 {
4893 QAction* addAction (QToolBar* menu, const QString &amp; text, PyObject* callable)
4893 QAction* a = menu-&gt;addAction(text);
4894 {
4894 PythonQt::self()-&gt;addSignalHandler(a, SIGNAL(triggered(bool)), callable);
4895 QAction* a = menu-&gt;addAction(text);
4895 return a;
4896 PythonQt::self()-&gt;addSignalHandler(a, SIGNAL(triggered(bool)), callable);
4896 }
4897 return a;
4897
4898 }
4898 QAction* addAction (QToolBar* menu, const QIcon&amp; icon, const QString&amp; text, PyObject* callable)
4899
4899 {
4900 QAction* addAction (QToolBar* menu, const QIcon&amp; icon, const QString&amp; text, PyObject* callable)
4900 QAction* a = menu-&gt;addAction(text);
4901 {
4901 a-&gt;setIcon(icon);
4902 QAction* a = menu-&gt;addAction(text);
4902 PythonQt::self()-&gt;addSignalHandler(a, SIGNAL(triggered(bool)), callable);
4903 a-&gt;setIcon(icon);
4903 return a;
4904 PythonQt::self()-&gt;addSignalHandler(a, SIGNAL(triggered(bool)), callable);
4904 }
4905 return a;
4905 </inject-code>
4906 }
4907 </inject-code>
4906 </object-type>
4908 </object-type>
4907
4909
4908 <object-type name="QPaintEngine">
4910 <object-type name="QPaintEngine">
4909
4911
4910 <modify-function signature="begin(QPaintDevice*)">
4912 <modify-function signature="begin(QPaintDevice*)">
4911 <modify-argument index="1" invalidate-after-use="yes"/>
4913 <modify-argument index="1" invalidate-after-use="yes"/>
4912 </modify-function>
4914 </modify-function>
4913 <modify-function signature="updateState(QPaintEngineState)">
4915 <modify-function signature="updateState(QPaintEngineState)">
4914 <modify-argument index="1" invalidate-after-use="yes"/>
4916 <modify-argument index="1" invalidate-after-use="yes"/>
4915 </modify-function>
4917 </modify-function>
4916 <modify-function signature="drawTextItem(QPointF,QTextItem)">
4918 <modify-function signature="drawTextItem(QPointF,QTextItem)">
4917 <modify-argument index="2" invalidate-after-use="yes"/>
4919 <modify-argument index="2" invalidate-after-use="yes"/>
4918 </modify-function>
4920 </modify-function>
4919
4921
4920 <extra-includes>
4922 <extra-includes>
4921 <include file-name="QVarLengthArray" location="global"/>
4923 <include file-name="QVarLengthArray" location="global"/>
4922 </extra-includes>
4924 </extra-includes>
4923 <modify-function signature="setPaintDevice(QPaintDevice*)">
4925 <modify-function signature="setPaintDevice(QPaintDevice*)">
4924 <remove/>
4926 <remove/>
4925 </modify-function>
4927 </modify-function>
4926 <modify-field name="state" read="false" write="false"/>
4928 <modify-field name="state" read="false" write="false"/>
4927 </object-type>
4929 </object-type>
4928
4930
4929 <object-type name="QGuiSignalMapper"/>
4931 <object-type name="QGuiSignalMapper"/>
4930
4932
4931 <object-type name="QComboBox">
4933 <object-type name="QComboBox">
4932 <modify-function signature="initStyleOption(QStyleOptionComboBox*)const">
4934 <modify-function signature="initStyleOption(QStyleOptionComboBox*)const">
4933 <access modifier="private"/>
4935 <access modifier="private"/>
4934 </modify-function>
4936 </modify-function>
4935 <modify-function signature="setCompleter(QCompleter*)">
4937 <modify-function signature="setCompleter(QCompleter*)">
4936 <modify-argument index="1">
4938 <modify-argument index="1">
4937 <reference-count variable-name="__rcCompleter" action="set"/>
4939 <reference-count variable-name="__rcCompleter" action="set"/>
4938 </modify-argument>
4940 </modify-argument>
4939 </modify-function>
4941 </modify-function>
4940 <modify-function signature="setValidator(const QValidator*)">
4942 <modify-function signature="setValidator(const QValidator*)">
4941 <modify-argument index="1">
4943 <modify-argument index="1">
4942 <reference-count variable-name="__rcValidator" action="set"/>
4944 <reference-count variable-name="__rcValidator" action="set"/>
4943 </modify-argument>
4945 </modify-argument>
4944 </modify-function>
4946 </modify-function>
4945 <modify-function signature="setItemDelegate(QAbstractItemDelegate *)">
4947 <modify-function signature="setItemDelegate(QAbstractItemDelegate *)">
4946 <modify-argument index="1">
4948 <modify-argument index="1">
4947 <define-ownership class="java" owner="c++"/>
4949 <define-ownership class="java" owner="c++"/>
4948 <no-null-pointer/>
4950 <no-null-pointer/>
4949 </modify-argument>
4951 </modify-argument>
4950 </modify-function>
4952 </modify-function>
4951 <modify-function signature="setView(QAbstractItemView *)">
4953 <modify-function signature="setView(QAbstractItemView *)">
4952 <modify-argument index="1">
4954 <modify-argument index="1">
4953 <no-null-pointer/>
4955 <no-null-pointer/>
4954 <!-- Safe to ignore because combo box reparents view -->
4956 <!-- Safe to ignore because combo box reparents view -->
4955 <reference-count action="ignore"/>
4957 <reference-count action="ignore"/>
4956 </modify-argument>
4958 </modify-argument>
4957 </modify-function>
4959 </modify-function>
4958 <modify-function signature="setLineEdit(QLineEdit *)">
4960 <modify-function signature="setLineEdit(QLineEdit *)">
4959 <modify-argument index="1">
4961 <modify-argument index="1">
4960 <no-null-pointer/>
4962 <no-null-pointer/>
4961 <!-- Safe to ignore because combo box reparents line edit -->
4963 <!-- Safe to ignore because combo box reparents line edit -->
4962 <reference-count action="ignore"/>
4964 <reference-count action="ignore"/>
4963 </modify-argument>
4965 </modify-argument>
4964 </modify-function>
4966 </modify-function>
4965 <modify-function signature="setModel(QAbstractItemModel *)">
4967 <modify-function signature="setModel(QAbstractItemModel *)">
4966 <modify-argument index="1">
4968 <modify-argument index="1">
4967 <no-null-pointer/>
4969 <no-null-pointer/>
4968 <reference-count action="set" variable-name="__rcModel"/>
4970 <reference-count action="set" variable-name="__rcModel"/>
4969 </modify-argument>
4971 </modify-argument>
4970 </modify-function>
4972 </modify-function>
4971 <inject-code>
4973 <inject-code>
4972 <insert-template name="gui.init_style_option">
4974 <insert-template name="gui.init_style_option">
4973 <replace from="%TYPE" to="QStyleOptionComboBox"/>
4975 <replace from="%TYPE" to="QStyleOptionComboBox"/>
4974 </insert-template>
4976 </insert-template>
4975 </inject-code>
4977 </inject-code>
4976 <modify-function signature="activated(int)">&gt;
4978 <modify-function signature="activated(int)">&gt;
4977 <rename to="activatedIndex"/>
4979 <rename to="activatedIndex"/>
4978 </modify-function>
4980 </modify-function>
4979 <modify-function signature="currentIndexChanged(const QString &amp;)">
4981 <modify-function signature="currentIndexChanged(const QString &amp;)">
4980 <rename to="currentStringChanged"/>
4982 <rename to="currentStringChanged"/>
4981 </modify-function>
4983 </modify-function>
4982 <modify-function signature="highlighted(int)">
4984 <modify-function signature="highlighted(int)">
4983 <rename to="highlightedIndex"/>
4985 <rename to="highlightedIndex"/>
4984 </modify-function>
4986 </modify-function>
4985
4987
4986 <modify-function signature="autoCompletion()const" remove="all"/> <!--### Obsolete in 4.3-->
4988 <modify-function signature="autoCompletion()const" remove="all"/> <!--### Obsolete in 4.3-->
4987 <modify-function signature="autoCompletionCaseSensitivity()const" remove="all"/> <!--### Obsolete in 4.3-->
4989 <modify-function signature="autoCompletionCaseSensitivity()const" remove="all"/> <!--### Obsolete in 4.3-->
4988 <modify-function signature="setAutoCompletion(bool)" remove="all"/> <!--### Obsolete in 4.3-->
4990 <modify-function signature="setAutoCompletion(bool)" remove="all"/> <!--### Obsolete in 4.3-->
4989 <modify-function signature="setAutoCompletionCaseSensitivity(Qt::CaseSensitivity)" remove="all"/> <!--### Obsolete in 4.3-->
4991 <modify-function signature="setAutoCompletionCaseSensitivity(Qt::CaseSensitivity)" remove="all"/> <!--### Obsolete in 4.3-->
4990 </object-type>
4992 </object-type>
4991
4993
4992 <object-type name="QTextEdit">
4994 <object-type name="QTextEdit">
4993 <extra-includes>
4995 <extra-includes>
4994 <include file-name="QTextCursor" location="global"/>
4996 <include file-name="QTextCursor" location="global"/>
4995 </extra-includes>
4997 </extra-includes>
4996 <modify-function signature="setDocument(QTextDocument*)">
4998 <modify-function signature="setDocument(QTextDocument*)">
4997 <modify-argument index="1">
4999 <modify-argument index="1">
4998 <reference-count action="set" variable-name="__rcDocument"/>
5000 <reference-count action="set" variable-name="__rcDocument"/>
4999 </modify-argument>
5001 </modify-argument>
5000 </modify-function>
5002 </modify-function>
5001 <modify-function signature="insertFromMimeData(const QMimeData*) ">
5003 <modify-function signature="insertFromMimeData(const QMimeData*) ">
5002 <modify-argument index="1">
5004 <modify-argument index="1">
5003 <reference-count action="ignore"/>
5005 <reference-count action="ignore"/>
5004 </modify-argument>
5006 </modify-argument>
5005 </modify-function>
5007 </modify-function>
5006 </object-type>
5008 </object-type>
5007
5009
5008 <object-type name="QPrinter" delete-in-main-thread="yes">
5010 <object-type name="QPrinter" delete-in-main-thread="yes">
5009 <modify-function signature="setEngines(QPrintEngine*,QPaintEngine*)">
5011 <modify-function signature="setEngines(QPrintEngine*,QPaintEngine*)">
5010 <modify-argument index="1">
5012 <modify-argument index="1">
5011 <reference-count action="set" variable-name="__rcPrintEngine"/>
5013 <reference-count action="set" variable-name="__rcPrintEngine"/>
5012 </modify-argument>
5014 </modify-argument>
5013 <modify-argument index="2">
5015 <modify-argument index="2">
5014 <reference-count action="set" variable-name="__rcPaintEngine"/>
5016 <reference-count action="set" variable-name="__rcPaintEngine"/>
5015 </modify-argument>
5017 </modify-argument>
5016 </modify-function>
5018 </modify-function>
5017
5019
5018 <extra-includes>
5020 <extra-includes>
5019 <include file-name="QPrinterInfo" location="global"/>
5021 <include file-name="QPrinterInfo" location="global"/>
5020 </extra-includes>
5022 </extra-includes>
5021 </object-type>
5023 </object-type>
5022
5024
5023 <object-type name="QAction">
5025 <object-type name="QAction">
5024 <modify-function signature="setMenu(QMenu*)">
5026 <modify-function signature="setMenu(QMenu*)">
5025 <modify-argument index="1">
5027 <modify-argument index="1">
5026 <reference-count action="set" variable-name="__rcMenu"/>
5028 <reference-count action="set" variable-name="__rcMenu"/>
5027 </modify-argument>
5029 </modify-argument>
5028 </modify-function>
5030 </modify-function>
5029
5031
5030 </object-type>
5032 </object-type>
5031
5033
5032 <object-type name="QPainter">
5034 <object-type name="QPainter">
5033 <extra-includes>
5035 <extra-includes>
5034 <include file-name="QWidget" location="global"/>
5036 <include file-name="QWidget" location="global"/>
5035 <include file-name="QPainterPath" location="global"/>
5037 <include file-name="QPainterPath" location="global"/>
5036 <include file-name="QPixmap" location="global"/>
5038 <include file-name="QPixmap" location="global"/>
5037 </extra-includes>
5039 </extra-includes>
5038
5040
5039 <modify-function signature="drawText(const QPointF &amp;, const QString &amp;, int, int)" remove="all"/>
5041 <modify-function signature="drawText(const QPointF &amp;, const QString &amp;, int, int)" remove="all"/>
5040
5042
5041 <modify-function signature="drawConvexPolygon(const QPoint *, int)">
5043 <modify-function signature="drawConvexPolygon(const QPoint *, int)">
5042 <remove/>
5044 <remove/>
5043 </modify-function>
5045 </modify-function>
5044 <modify-function signature="drawConvexPolygon(const QPointF *, int)">
5046 <modify-function signature="drawConvexPolygon(const QPointF *, int)">
5045 <remove/>
5047 <remove/>
5046 </modify-function>
5048 </modify-function>
5047 <modify-function signature="drawLines(const QLine *, int)">
5049 <modify-function signature="drawLines(const QLine *, int)">
5048 <remove/>
5050 <remove/>
5049 </modify-function>
5051 </modify-function>
5050 <modify-function signature="drawLines(const QLineF *, int)">
5052 <modify-function signature="drawLines(const QLineF *, int)">
5051 <remove/>
5053 <remove/>
5052 </modify-function>
5054 </modify-function>
5053 <modify-function signature="drawLines(const QPoint *, int)">
5055 <modify-function signature="drawLines(const QPoint *, int)">
5054 <remove/>
5056 <remove/>
5055 </modify-function>
5057 </modify-function>
5056 <modify-function signature="drawLines(const QPointF *, int)">
5058 <modify-function signature="drawLines(const QPointF *, int)">
5057 <remove/>
5059 <remove/>
5058 </modify-function>
5060 </modify-function>
5059 <modify-function signature="drawPoints(const QPoint *, int)">
5061 <modify-function signature="drawPoints(const QPoint *, int)">
5060 <remove/>
5062 <remove/>
5061 </modify-function>
5063 </modify-function>
5062 <modify-function signature="drawPoints(const QPointF *, int)">
5064 <modify-function signature="drawPoints(const QPointF *, int)">
5063 <remove/>
5065 <remove/>
5064 </modify-function>
5066 </modify-function>
5065 <modify-function signature="drawPolygon(const QPoint *, int, Qt::FillRule)">
5067 <modify-function signature="drawPolygon(const QPoint *, int, Qt::FillRule)">
5066 <remove/>
5068 <remove/>
5067 </modify-function>
5069 </modify-function>
5068 <modify-function signature="drawPolygon(const QPointF *, int, Qt::FillRule)">
5070 <modify-function signature="drawPolygon(const QPointF *, int, Qt::FillRule)">
5069 <remove/>
5071 <remove/>
5070 </modify-function>
5072 </modify-function>
5071 <modify-function signature="drawPolyline(const QPoint *, int)">
5073 <modify-function signature="drawPolyline(const QPoint *, int)">
5072 <remove/>
5074 <remove/>
5073 </modify-function>
5075 </modify-function>
5074 <modify-function signature="drawPolyline(const QPointF *, int)">
5076 <modify-function signature="drawPolyline(const QPointF *, int)">
5075 <remove/>
5077 <remove/>
5076 </modify-function>
5078 </modify-function>
5077 <modify-function signature="drawRects(const QRect *, int)">
5079 <modify-function signature="drawRects(const QRect *, int)">
5078 <remove/>
5080 <remove/>
5079 </modify-function>
5081 </modify-function>
5080 <modify-function signature="drawRects(const QRectF *, int)">
5082 <modify-function signature="drawRects(const QRectF *, int)">
5081 <remove/>
5083 <remove/>
5082 </modify-function>
5084 </modify-function>
5083 <modify-function signature="drawLines(const QVector&lt;QPoint&gt; &amp;)">
5085 <modify-function signature="drawLines(const QVector&lt;QPoint&gt; &amp;)">
5084 <rename to="drawLinesFromPoints"/>
5086 <rename to="drawLinesFromPoints"/>
5085 </modify-function>
5087 </modify-function>
5086 <modify-function signature="drawLines(const QVector&lt;QPointF&gt; &amp;)">
5088 <modify-function signature="drawLines(const QVector&lt;QPointF&gt; &amp;)">
5087 <rename to="drawLinesFromPointsF"/>
5089 <rename to="drawLinesFromPointsF"/>
5088 </modify-function>
5090 </modify-function>
5089 <modify-function signature="drawLines(const QVector&lt;QLineF&gt; &amp;)">
5091 <modify-function signature="drawLines(const QVector&lt;QLineF&gt; &amp;)">
5090 <rename to="drawLinesF"/>
5092 <rename to="drawLinesF"/>
5091 </modify-function>
5093 </modify-function>
5092 <modify-function signature="drawRects(const QVector&lt;QRectF&gt; &amp;)">
5094 <modify-function signature="drawRects(const QVector&lt;QRectF&gt; &amp;)">
5093 <rename to="drawRectsF"/>
5095 <rename to="drawRectsF"/>
5094 </modify-function>
5096 </modify-function>
5095
5097
5096 <modify-function signature="QPainter(QPaintDevice *)">
5098 <modify-function signature="QPainter(QPaintDevice *)">
5097 <modify-argument index="1">
5099 <modify-argument index="1">
5098 <no-null-pointer/>
5100 <no-null-pointer/>
5099 </modify-argument>
5101 </modify-argument>
5100 </modify-function>
5102 </modify-function>
5101 <modify-function signature="begin(QPaintDevice *)">
5103 <modify-function signature="begin(QPaintDevice *)">
5102 <modify-argument index="1">
5104 <modify-argument index="1">
5103 <no-null-pointer/>
5105 <no-null-pointer/>
5104 </modify-argument>
5106 </modify-argument>
5105 </modify-function>
5107 </modify-function>
5106 <modify-function signature="initFrom(const QWidget *)">
5108 <modify-function signature="initFrom(const QWidget *)">
5107 <modify-argument index="1">
5109 <modify-argument index="1">
5108 <no-null-pointer/>
5110 <no-null-pointer/>
5109 </modify-argument>
5111 </modify-argument>
5110 </modify-function>
5112 </modify-function>
5111 <modify-function signature="setRedirected(const QPaintDevice *, QPaintDevice *, const QPoint &amp;)">
5113 <modify-function signature="setRedirected(const QPaintDevice *, QPaintDevice *, const QPoint &amp;)">
5112 <modify-argument index="1">
5114 <modify-argument index="1">
5113 <no-null-pointer/>
5115 <no-null-pointer/>
5114 </modify-argument>
5116 </modify-argument>
5115 </modify-function>
5117 </modify-function>
5116 <modify-function signature="restoreRedirected(const QPaintDevice *)">
5118 <modify-function signature="restoreRedirected(const QPaintDevice *)">
5117 <modify-argument index="1">
5119 <modify-argument index="1">
5118 <no-null-pointer/>
5120 <no-null-pointer/>
5119 </modify-argument>
5121 </modify-argument>
5120 </modify-function>
5122 </modify-function>
5121
5123
5122 <modify-function signature="drawText(QRect,int,QString,QRect*)">
5124 <modify-function signature="drawText(QRect,int,QString,QRect*)">
5123 <access modifier="private"/>
5125 <access modifier="private"/>
5124 <modify-argument index="4">
5126 <modify-argument index="4">
5125 <remove-default-expression/>
5127 <remove-default-expression/>
5126 </modify-argument>
5128 </modify-argument>
5127 </modify-function>
5129 </modify-function>
5128
5130
5129 <modify-function signature="drawText(QRectF,int,QString,QRectF*)">
5131 <modify-function signature="drawText(QRectF,int,QString,QRectF*)">
5130 <access modifier="private"/>
5132 <access modifier="private"/>
5131 <modify-argument index="4">
5133 <modify-argument index="4">
5132 <remove-default-expression/>
5134 <remove-default-expression/>
5133 </modify-argument>
5135 </modify-argument>
5134 </modify-function>
5136 </modify-function>
5135
5137
5136 <modify-function signature="drawText(int,int,int,int,int,QString,QRect*)">
5138 <modify-function signature="drawText(int,int,int,int,int,QString,QRect*)">
5137 <access modifier="private"/>
5139 <access modifier="private"/>
5138 <modify-argument index="7">
5140 <modify-argument index="7">
5139 <remove-default-expression/>
5141 <remove-default-expression/>
5140 </modify-argument>
5142 </modify-argument>
5141 </modify-function>
5143 </modify-function>
5142
5144
5143 <modify-function signature="redirected(const QPaintDevice*,QPoint*)">
5145 <modify-function signature="redirected(const QPaintDevice*,QPoint*)">
5144 <access modifier="private"/>
5146 <access modifier="private"/>
5145 <modify-argument index="2">
5147 <modify-argument index="2">
5146 <remove-default-expression/>
5148 <remove-default-expression/>
5147 </modify-argument>
5149 </modify-argument>
5148 </modify-function>
5150 </modify-function>
5149 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
5151 <modify-function signature="matrix()const" remove="all"/> <!--### Obsolete in 4.3-->
5150 <modify-function signature="matrixEnabled()const" remove="all"/> <!--### Obsolete in 4.3-->
5152 <modify-function signature="matrixEnabled()const" remove="all"/> <!--### Obsolete in 4.3-->
5151 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
5153 <modify-function signature="setMatrix(QMatrix, bool)" remove="all"/> <!--### Obsolete in 4.3-->
5152 <modify-function signature="setMatrixEnabled(bool)" remove="all"/> <!--### Obsolete in 4.3-->
5154 <modify-function signature="setMatrixEnabled(bool)" remove="all"/> <!--### Obsolete in 4.3-->
5153
5155
5154 <modify-function signature="fontInfo()const" remove="all"/>
5156 <modify-function signature="fontInfo()const" remove="all"/>
5155 <modify-function signature="fontMetrics()const" remove="all"/>
5157 <modify-function signature="fontMetrics()const" remove="all"/>
5156 <modify-function signature="QPainter(QPaintDevice*)" remove="all"/>
5158 <modify-function signature="QPainter(QPaintDevice*)" remove="all"/>
5157
5159
5158 <modify-function signature="begin(QPaintDevice*)">
5160 <modify-function signature="begin(QPaintDevice*)">
5159 <modify-argument index="1">
5161 <modify-argument index="1">
5160 <conversion-rule class="native">
5162 <conversion-rule class="native">
5161 <insert-template name="core.convert_pointer_arg_and_check_null">
5163 <insert-template name="core.convert_pointer_arg_and_check_null">
5162 <replace from="%TYPE%" to="QPaintDevice*"/>
5164 <replace from="%TYPE%" to="QPaintDevice*"/>
5163 <replace from="%CLASS_NAME%" to="QPainter"/>
5165 <replace from="%CLASS_NAME%" to="QPainter"/>
5164 <replace from="%FUNCTION_NAME%" to="begin"/>
5166 <replace from="%FUNCTION_NAME%" to="begin"/>
5165 </insert-template>
5167 </insert-template>
5166 </conversion-rule>
5168 </conversion-rule>
5167 </modify-argument>
5169 </modify-argument>
5168 </modify-function>
5170 </modify-function>
5169 </object-type>
5171 </object-type>
5170
5172
5171 <object-type name="QGuiApplication"/>
5173 <object-type name="QGuiApplication"/>
5172 <object-type name="QApplication">
5174 <object-type name="QApplication">
5173 <extra-includes>
5175 <extra-includes>
5174 <include file-name="QBasicTimer" location="global"/>
5176 <include file-name="QBasicTimer" location="global"/>
5175 <include file-name="QFont" location="global"/>
5177 <include file-name="QFont" location="global"/>
5176 <include file-name="QFontMetrics" location="global"/>
5178 <include file-name="QFontMetrics" location="global"/>
5177 <include file-name="QPalette" location="global"/>
5179 <include file-name="QPalette" location="global"/>
5178 <include file-name="QIcon" location="global"/>
5180 <include file-name="QIcon" location="global"/>
5179 <include file-name="QLocale" location="global"/>
5181 <include file-name="QLocale" location="global"/>
5180 </extra-includes>
5182 </extra-includes>
5181
5183
5182 <modify-function signature="QApplication(int &amp;, char **, int)">
5184 <modify-function signature="QApplication(int &amp;, char **, int)">
5183 <access modifier="private"/>
5185 <access modifier="private"/>
5184 </modify-function>
5186 </modify-function>
5185 <modify-function signature="QApplication(int &amp;, char **, QApplication::Type, int)">
5187 <modify-function signature="QApplication(int &amp;, char **, QApplication::Type, int)">
5186 <remove/>
5188 <remove/>
5187 </modify-function>
5189 </modify-function>
5188 <modify-function signature="QApplication(int &amp;, char **, bool, int)">
5190 <modify-function signature="QApplication(int &amp;, char **, bool, int)">
5189 <remove/>
5191 <remove/>
5190 </modify-function>
5192 </modify-function>
5191
5193
5192 <modify-function signature="font(const char*)">
5194 <modify-function signature="font(const char*)">
5193 <remove/>
5195 <remove/>
5194 </modify-function>
5196 </modify-function>
5195
5197
5196 <modify-function signature="palette(const char*)">
5198 <modify-function signature="palette(const char*)">
5197 <remove/>
5199 <remove/>
5198 </modify-function>
5200 </modify-function>
5199 <modify-function signature="setPalette(QPalette,const char*)">
5201 <modify-function signature="setPalette(QPalette,const char*)">
5200 <access modifier="private"/>
5202 <access modifier="private"/>
5201 <modify-argument index="2">
5203 <modify-argument index="2">
5202 <remove-default-expression/>
5204 <remove-default-expression/>
5203 </modify-argument>
5205 </modify-argument>
5204 </modify-function>
5206 </modify-function>
5205
5207
5206 <modify-function signature="overrideCursor()">
5208 <modify-function signature="overrideCursor()">
5207 <access modifier="private"/>
5209 <access modifier="private"/>
5208 <rename to="overrideCursor_private"/>
5210 <rename to="overrideCursor_private"/>
5209 </modify-function>
5211 </modify-function>
5210
5212
5211 <modify-function signature="setInputContext(QInputContext*)">
5213 <modify-function signature="setInputContext(QInputContext*)">
5212 <modify-argument index="1">
5214 <modify-argument index="1">
5213 <define-ownership class="java" owner="c++"/>
5215 <define-ownership class="java" owner="c++"/>
5214 </modify-argument>
5216 </modify-argument>
5215 </modify-function>
5217 </modify-function>
5216 <modify-function signature="setActiveWindow(QWidget*)">
5218 <modify-function signature="setActiveWindow(QWidget*)">
5217 <modify-argument index="1">
5219 <modify-argument index="1">
5218 <reference-count action="ignore"/>
5220 <reference-count action="ignore"/>
5219 </modify-argument>
5221 </modify-argument>
5220 </modify-function>
5222 </modify-function>
5221 <modify-function signature="setStyle(QStyle*)">
5223 <modify-function signature="setStyle(QStyle*)">
5222 <modify-argument index="1">
5224 <modify-argument index="1">
5223 <reference-count action="ignore"/>
5225 <reference-count action="ignore"/>
5224 </modify-argument>
5226 </modify-argument>
5225 </modify-function>
5227 </modify-function>
5226
5228
5227 <modify-function signature="QApplication(int&amp;,char**,QApplication::Type,int)" remove="all"/>
5229 <modify-function signature="QApplication(int&amp;,char**,QApplication::Type,int)" remove="all"/>
5228 <modify-function signature="QApplication(int&amp;,char**,bool,int)" remove="all"/>
5230 <modify-function signature="QApplication(int&amp;,char**,bool,int)" remove="all"/>
5229 <modify-function signature="QApplication(int&amp;,char**,int)" remove="all"/>
5231 <modify-function signature="QApplication(int&amp;,char**,int)" remove="all"/>
5230 <modify-function signature="commitData(QSessionManager&amp;)" remove="all"/>
5232 <modify-function signature="commitData(QSessionManager&amp;)" remove="all"/>
5231 <modify-function signature="saveState(QSessionManager&amp;)" remove="all"/>
5233 <modify-function signature="saveState(QSessionManager&amp;)" remove="all"/>
5232 <modify-function signature="fontMetrics()" remove="all"/>
5234 <modify-function signature="fontMetrics()" remove="all"/>
5233 <modify-function signature="setFont(QFont,const char*)">
5235 <modify-function signature="setFont(QFont,const char*)">
5234 <modify-argument index="2">
5236 <modify-argument index="2">
5235 <replace-type modified-type="QString"/>
5237 <replace-type modified-type="QString"/>
5236 <conversion-rule class="native">
5238 <conversion-rule class="native">
5237 <insert-template name="core.convert_string_arg_to_char*"/>
5239 <insert-template name="core.convert_string_arg_to_char*"/>
5238 </conversion-rule>
5240 </conversion-rule>
5239 </modify-argument>
5241 </modify-argument>
5240 </modify-function>
5242 </modify-function>
5241 <modify-function signature="setPalette(QPalette,const char*)">
5243 <modify-function signature="setPalette(QPalette,const char*)">
5242 <modify-argument index="2">
5244 <modify-argument index="2">
5243 <replace-type modified-type="QString"/>
5245 <replace-type modified-type="QString"/>
5244 <conversion-rule class="native">
5246 <conversion-rule class="native">
5245 <insert-template name="core.convert_string_arg_to_char*"/>
5247 <insert-template name="core.convert_string_arg_to_char*"/>
5246 </conversion-rule>
5248 </conversion-rule>
5247 </modify-argument>
5249 </modify-argument>
5248 </modify-function>
5250 </modify-function>
5249 </object-type>
5251 </object-type>
5250
5252
5251 <object-type name="QMouseEventTransition"/>
5253 <object-type name="QMouseEventTransition"/>
5252 <object-type name="QKeyEventTransition"/>
5254 <object-type name="QKeyEventTransition"/>
5253 <value-type name="QQuaternion"/>
5255 <value-type name="QQuaternion"/>
5254
5256
5255 <object-type name="QCommandLinkButton"/>
5257 <object-type name="QCommandLinkButton"/>
5256 <object-type name="QFileSystemModel">
5258 <object-type name="QFileSystemModel">
5257 <modify-function signature="setIconProvider(QFileIconProvider*)">
5259 <modify-function signature="setIconProvider(QFileIconProvider*)">
5258 <modify-argument index="1">
5260 <modify-argument index="1">
5259 <reference-count action="set" variable-name="__rcIconProvider"/>
5261 <reference-count action="set" variable-name="__rcIconProvider"/>
5260 </modify-argument>
5262 </modify-argument>
5261 </modify-function>
5263 </modify-function>
5262 </object-type>
5264 </object-type>
5263 <object-type name="QFormLayout">
5265 <object-type name="QFormLayout">
5264 <modify-function signature="addRow(QWidget*,QWidget*)">
5266 <modify-function signature="addRow(QWidget*,QWidget*)">
5265 <modify-argument index="1">
5267 <modify-argument index="1">
5266 <reference-count action="ignore"/>
5268 <reference-count action="ignore"/>
5267 </modify-argument>
5269 </modify-argument>
5268 <modify-argument index="2">
5270 <modify-argument index="2">
5269 <reference-count action="ignore"/>
5271 <reference-count action="ignore"/>
5270 </modify-argument>
5272 </modify-argument>
5271 </modify-function>
5273 </modify-function>
5272 <modify-function signature="addRow(QLayout*)">
5274 <modify-function signature="addRow(QLayout*)">
5273 <modify-argument index="1">
5275 <modify-argument index="1">
5274 <reference-count action="ignore"/>
5276 <reference-count action="ignore"/>
5275 </modify-argument>
5277 </modify-argument>
5276 </modify-function>
5278 </modify-function>
5277 <modify-function signature="addRow(QWidget*,QLayout*)">
5279 <modify-function signature="addRow(QWidget*,QLayout*)">
5278 <modify-argument index="1">
5280 <modify-argument index="1">
5279 <reference-count action="ignore"/>
5281 <reference-count action="ignore"/>
5280 </modify-argument>
5282 </modify-argument>
5281 <modify-argument index="2">
5283 <modify-argument index="2">
5282 <reference-count action="ignore"/>
5284 <reference-count action="ignore"/>
5283 </modify-argument>
5285 </modify-argument>
5284 </modify-function>
5286 </modify-function>
5285
5287
5286 <modify-function signature="addRow(QWidget*)">
5288 <modify-function signature="addRow(QWidget*)">
5287 <modify-argument index="1">
5289 <modify-argument index="1">
5288 <reference-count action="ignore"/>
5290 <reference-count action="ignore"/>
5289 </modify-argument>
5291 </modify-argument>
5290 </modify-function>
5292 </modify-function>
5291 <modify-function signature="addRow(QString,QLayout*)">
5293 <modify-function signature="addRow(QString,QLayout*)">
5292 <modify-argument index="2">
5294 <modify-argument index="2">
5293 <reference-count action="ignore"/>
5295 <reference-count action="ignore"/>
5294 </modify-argument>
5296 </modify-argument>
5295 </modify-function>
5297 </modify-function>
5296 <modify-function signature="addRow(QString,QWidget*)">
5298 <modify-function signature="addRow(QString,QWidget*)">
5297 <modify-argument index="2">
5299 <modify-argument index="2">
5298 <reference-count action="ignore"/>
5300 <reference-count action="ignore"/>
5299 </modify-argument>
5301 </modify-argument>
5300 </modify-function>
5302 </modify-function>
5301 <modify-function signature="insertRow(int,QLayout*)">
5303 <modify-function signature="insertRow(int,QLayout*)">
5302 <modify-argument index="2">
5304 <modify-argument index="2">
5303 <reference-count action="ignore"/>
5305 <reference-count action="ignore"/>
5304 </modify-argument>
5306 </modify-argument>
5305 </modify-function>
5307 </modify-function>
5306 <modify-function signature="insertRow(int,QWidget*,QLayout*)">
5308 <modify-function signature="insertRow(int,QWidget*,QLayout*)">
5307 <modify-argument index="2">
5309 <modify-argument index="2">
5308 <reference-count action="ignore"/>
5310 <reference-count action="ignore"/>
5309 </modify-argument>
5311 </modify-argument>
5310 <modify-argument index="3">
5312 <modify-argument index="3">
5311 <reference-count action="ignore"/>
5313 <reference-count action="ignore"/>
5312 </modify-argument>
5314 </modify-argument>
5313 </modify-function>
5315 </modify-function>
5314 <modify-function signature="insertRow(int,QWidget*,QWidget*)">
5316 <modify-function signature="insertRow(int,QWidget*,QWidget*)">
5315 <modify-argument index="2">
5317 <modify-argument index="2">
5316 <reference-count action="ignore"/>
5318 <reference-count action="ignore"/>
5317 </modify-argument>
5319 </modify-argument>
5318 <modify-argument index="3">
5320 <modify-argument index="3">
5319 <reference-count action="ignore"/>
5321 <reference-count action="ignore"/>
5320 </modify-argument>
5322 </modify-argument>
5321 </modify-function>
5323 </modify-function>
5322 <modify-function signature="insertRow(int,QWidget*)">
5324 <modify-function signature="insertRow(int,QWidget*)">
5323 <modify-argument index="2">
5325 <modify-argument index="2">
5324 <reference-count action="ignore"/>
5326 <reference-count action="ignore"/>
5325 </modify-argument>
5327 </modify-argument>
5326 </modify-function>
5328 </modify-function>
5327 <modify-function signature="insertRow(int,QString,QLayout*)">
5329 <modify-function signature="insertRow(int,QString,QLayout*)">
5328 <modify-argument index="3">
5330 <modify-argument index="3">
5329 <reference-count action="ignore"/>
5331 <reference-count action="ignore"/>
5330 </modify-argument>
5332 </modify-argument>
5331 </modify-function>
5333 </modify-function>
5332 <modify-function signature="insertRow(int,QString,QWidget*)">
5334 <modify-function signature="insertRow(int,QString,QWidget*)">
5333 <modify-argument index="3">
5335 <modify-argument index="3">
5334 <reference-count action="ignore"/>
5336 <reference-count action="ignore"/>
5335 </modify-argument>
5337 </modify-argument>
5336 </modify-function>
5338 </modify-function>
5337 <modify-function signature="setLayout(int,QFormLayout::ItemRole,QLayout*)">
5339 <modify-function signature="setLayout(int,QFormLayout::ItemRole,QLayout*)">
5338 <modify-argument index="3">
5340 <modify-argument index="3">
5339 <reference-count action="ignore"/>
5341 <reference-count action="ignore"/>
5340 </modify-argument>
5342 </modify-argument>
5341 </modify-function>
5343 </modify-function>
5342 <modify-function signature="setWidget(int,QFormLayout::ItemRole,QWidget*)">
5344 <modify-function signature="setWidget(int,QFormLayout::ItemRole,QWidget*)">
5343 <modify-argument index="3">
5345 <modify-argument index="3">
5344 <reference-count action="ignore"/>
5346 <reference-count action="ignore"/>
5345 </modify-argument>
5347 </modify-argument>
5346 </modify-function>
5348 </modify-function>
5347 <modify-function signature="setItem(int,QFormLayout::ItemRole,QLayoutItem*)" access="private" rename="setItem_private">
5349 <modify-function signature="setItem(int,QFormLayout::ItemRole,QLayoutItem*)" access="private" rename="setItem_private">
5348 <modify-argument index="3">
5350 <modify-argument index="3">
5349 <define-ownership class="java" owner="c++"/>
5351 <define-ownership class="java" owner="c++"/>
5350 </modify-argument>
5352 </modify-argument>
5351 </modify-function>
5353 </modify-function>
5352 <modify-function signature="addItem(QLayoutItem*)">
5354 <modify-function signature="addItem(QLayoutItem*)">
5353 <modify-argument index="1">
5355 <modify-argument index="1">
5354 <define-ownership class="java" owner="c++"/>
5356 <define-ownership class="java" owner="c++"/>
5355 </modify-argument>
5357 </modify-argument>
5356 </modify-function>
5358 </modify-function>
5357 </object-type>
5359 </object-type>
5358 <object-type name="QGraphicsGridLayout" delete-in-main-thread="yes">
5360 <object-type name="QGraphicsGridLayout" delete-in-main-thread="yes">
5359 <modify-function signature="addItem(QGraphicsLayoutItem*,int,int,QFlags&lt;Qt::AlignmentFlag&gt;)">
5361 <modify-function signature="addItem(QGraphicsLayoutItem*,int,int,QFlags&lt;Qt::AlignmentFlag&gt;)">
5360 <modify-argument index="1">
5362 <modify-argument index="1">
5361 <reference-count action="add" variable-name="__rcItems"/>
5363 <reference-count action="add" variable-name="__rcItems"/>
5362 </modify-argument>
5364 </modify-argument>
5363 </modify-function>
5365 </modify-function>
5364 <modify-function signature="addItem(QGraphicsLayoutItem*,int,int,int,int,QFlags&lt;Qt::AlignmentFlag&gt;)">
5366 <modify-function signature="addItem(QGraphicsLayoutItem*,int,int,int,int,QFlags&lt;Qt::AlignmentFlag&gt;)">
5365 <modify-argument index="1">
5367 <modify-argument index="1">
5366 <reference-count action="add" variable-name="__rcItems"/>
5368 <reference-count action="add" variable-name="__rcItems"/>
5367 </modify-argument>
5369 </modify-argument>
5368 </modify-function>
5370 </modify-function>
5369 <modify-function signature="setAlignment(QGraphicsLayoutItem*,QFlags&lt;Qt::AlignmentFlag&gt;)">
5371 <modify-function signature="setAlignment(QGraphicsLayoutItem*,QFlags&lt;Qt::AlignmentFlag&gt;)">
5370 <modify-argument index="1">
5372 <modify-argument index="1">
5371 <reference-count action="ignore"/>
5373 <reference-count action="ignore"/>
5372 </modify-argument>
5374 </modify-argument>
5373 </modify-function>
5375 </modify-function>
5374 </object-type>
5376 </object-type>
5375 <object-type name="QGraphicsLayout" delete-in-main-thread="yes">
5377 <object-type name="QGraphicsLayout" delete-in-main-thread="yes">
5376
5378
5377 <modify-function signature="widgetEvent(QEvent*)">
5379 <modify-function signature="widgetEvent(QEvent*)">
5378 <modify-argument index="1" invalidate-after-use="yes"/>
5380 <modify-argument index="1" invalidate-after-use="yes"/>
5379 </modify-function>
5381 </modify-function>
5380 <modify-function signature="setParentLayoutItem(QGraphicsLayoutItem*)">
5382 <modify-function signature="setParentLayoutItem(QGraphicsLayoutItem*)">
5381 <modify-argument index="1">
5383 <modify-argument index="1">
5382 <reference-count action="set" variable-name="__rcParentLayoutItem"/>
5384 <reference-count action="set" variable-name="__rcParentLayoutItem"/>
5383 </modify-argument>
5385 </modify-argument>
5384 </modify-function>
5386 </modify-function>
5385 <modify-function signature="setGraphicsItem(QGraphicsItem*)">
5387 <modify-function signature="setGraphicsItem(QGraphicsItem*)">
5386 <modify-argument index="1">
5388 <modify-argument index="1">
5387 <reference-count action="set" variable-name="__rcItem"/>
5389 <reference-count action="set" variable-name="__rcItem"/>
5388 </modify-argument>
5390 </modify-argument>
5389 </modify-function>
5391 </modify-function>
5390 </object-type>
5392 </object-type>
5391 <interface-type name="QGraphicsLayoutItem" delete-in-main-thread="yes">
5393 <interface-type name="QGraphicsLayoutItem" delete-in-main-thread="yes">
5392 <modify-function signature="setParentLayoutItem(QGraphicsLayoutItem*)">
5394 <modify-function signature="setParentLayoutItem(QGraphicsLayoutItem*)">
5393 <modify-argument index="1">
5395 <modify-argument index="1">
5394 <reference-count action="set" variable-name="__rcParentLayoutItem"/>
5396 <reference-count action="set" variable-name="__rcParentLayoutItem"/>
5395 </modify-argument>
5397 </modify-argument>
5396 </modify-function>
5398 </modify-function>
5397 <modify-function signature="setGraphicsItem(QGraphicsItem*)">
5399 <modify-function signature="setGraphicsItem(QGraphicsItem*)">
5398 <modify-argument index="1">
5400 <modify-argument index="1">
5399 <reference-count action="set" variable-name="__rcItem"/>
5401 <reference-count action="set" variable-name="__rcItem"/>
5400 </modify-argument>
5402 </modify-argument>
5401 </modify-function>
5403 </modify-function>
5402 </interface-type>
5404 </interface-type>
5403 <object-type name="QGraphicsLinearLayout" delete-in-main-thread="yes">
5405 <object-type name="QGraphicsLinearLayout" delete-in-main-thread="yes">
5404 <modify-function signature="addItem(QGraphicsLayoutItem*)">
5406 <modify-function signature="addItem(QGraphicsLayoutItem*)">
5405 <modify-argument index="1">
5407 <modify-argument index="1">
5406 <reference-count action="add" variable-name="__rcItems"/>
5408 <reference-count action="add" variable-name="__rcItems"/>
5407 </modify-argument>
5409 </modify-argument>
5408 </modify-function>
5410 </modify-function>
5409 <modify-function signature="insertItem(int,QGraphicsLayoutItem*)">
5411 <modify-function signature="insertItem(int,QGraphicsLayoutItem*)">
5410 <modify-argument index="2">
5412 <modify-argument index="2">
5411 <reference-count action="add" variable-name="__rcItems"/>
5413 <reference-count action="add" variable-name="__rcItems"/>
5412 </modify-argument>
5414 </modify-argument>
5413 </modify-function>
5415 </modify-function>
5414 <modify-function signature="removeItem(QGraphicsLayoutItem*)">
5416 <modify-function signature="removeItem(QGraphicsLayoutItem*)">
5415 <modify-argument index="1">
5417 <modify-argument index="1">
5416 <reference-count action="remove" variable-name="__rcItems"/>
5418 <reference-count action="remove" variable-name="__rcItems"/>
5417 </modify-argument>
5419 </modify-argument>
5418 </modify-function>
5420 </modify-function>
5419 <modify-function signature="setAlignment(QGraphicsLayoutItem*,QFlags&lt;Qt::AlignmentFlag&gt;)">
5421 <modify-function signature="setAlignment(QGraphicsLayoutItem*,QFlags&lt;Qt::AlignmentFlag&gt;)">
5420 <modify-argument index="1">
5422 <modify-argument index="1">
5421 <reference-count action="ignore"/>
5423 <reference-count action="ignore"/>
5422 </modify-argument>
5424 </modify-argument>
5423 </modify-function>
5425 </modify-function>
5424 <modify-function signature="setStretchFactor(QGraphicsLayoutItem*,int)">
5426 <modify-function signature="setStretchFactor(QGraphicsLayoutItem*,int)">
5425 <modify-argument index="1">
5427 <modify-argument index="1">
5426 <reference-count action="ignore"/>
5428 <reference-count action="ignore"/>
5427 </modify-argument>
5429 </modify-argument>
5428 </modify-function>
5430 </modify-function>
5429 </object-type>
5431 </object-type>
5430 <object-type name="QGraphicsProxyWidget"/> <!-- a QObject so main-thread delete redundant -->
5432 <object-type name="QGraphicsProxyWidget"/> <!-- a QObject so main-thread delete redundant -->
5431 <object-type name="QGraphicsWidget"> <!-- a QObject so main-thread delete redundant -->
5433 <object-type name="QGraphicsWidget"> <!-- a QObject so main-thread delete redundant -->
5432 <!-- Duplicate function to QObject::children() to override accidental shadowing which is not present in Jambi -->
5434 <!-- Duplicate function to QObject::children() to override accidental shadowing which is not present in Jambi -->
5433 <modify-function signature="children()const" remove="all"/>
5435 <modify-function signature="children()const" remove="all"/>
5434 <modify-function signature="setLayout(QGraphicsLayout*)">
5436 <modify-function signature="setLayout(QGraphicsLayout*)">
5435 <modify-argument index="1">
5437 <modify-argument index="1">
5436 <reference-count action="set" variable-name="__rcLayout"/>
5438 <reference-count action="set" variable-name="__rcLayout"/>
5437 </modify-argument>
5439 </modify-argument>
5438 </modify-function>
5440 </modify-function>
5439
5441
5440 <modify-function signature="addAction(QAction*)">
5442 <modify-function signature="addAction(QAction*)">
5441 <modify-argument index="1">
5443 <modify-argument index="1">
5442 <reference-count action="add" variable-name="__rcActions"/>
5444 <reference-count action="add" variable-name="__rcActions"/>
5443 </modify-argument>
5445 </modify-argument>
5444 </modify-function>
5446 </modify-function>
5445 <modify-function signature="insertAction(QAction*,QAction*)">
5447 <modify-function signature="insertAction(QAction*,QAction*)">
5446 <modify-argument index="2">
5448 <modify-argument index="2">
5447 <reference-count action="add" variable-name="__rcActions"/>
5449 <reference-count action="add" variable-name="__rcActions"/>
5448 </modify-argument>
5450 </modify-argument>
5449 </modify-function>
5451 </modify-function>
5450 <modify-function signature="insertActions(QAction*,QList&lt;QAction*&gt;)">
5452 <modify-function signature="insertActions(QAction*,QList&lt;QAction*&gt;)">
5451 <modify-argument index="2">
5453 <modify-argument index="2">
5452 <reference-count action="add" variable-name="__rcActions"/>
5454 <reference-count action="add" variable-name="__rcActions"/>
5453 </modify-argument>
5455 </modify-argument>
5454 </modify-function>
5456 </modify-function>
5455 <modify-function signature="removeAction(QAction*)">
5457 <modify-function signature="removeAction(QAction*)">
5456 <modify-argument index="1">
5458 <modify-argument index="1">
5457 <reference-count action="remove" variable-name="__rcActions"/>
5459 <reference-count action="remove" variable-name="__rcActions"/>
5458 </modify-argument>
5460 </modify-argument>
5459 </modify-function>
5461 </modify-function>
5460
5462
5461
5463
5462 <modify-function signature="changeEvent(QEvent*)">
5464 <modify-function signature="changeEvent(QEvent*)">
5463 <modify-argument index="1" invalidate-after-use="yes"/>
5465 <modify-argument index="1" invalidate-after-use="yes"/>
5464 </modify-function>
5466 </modify-function>
5465 <modify-function signature="closeEvent(QCloseEvent*)">
5467 <modify-function signature="closeEvent(QCloseEvent*)">
5466 <modify-argument index="1" invalidate-after-use="yes"/>
5468 <modify-argument index="1" invalidate-after-use="yes"/>
5467 </modify-function>
5469 </modify-function>
5468 <modify-function signature="grabKeyboardEvent(QEvent*)">
5470 <modify-function signature="grabKeyboardEvent(QEvent*)">
5469 <modify-argument index="1" invalidate-after-use="yes"/>
5471 <modify-argument index="1" invalidate-after-use="yes"/>
5470 </modify-function>
5472 </modify-function>
5471 <modify-function signature="grabMouseEvent(QEvent*)">
5473 <modify-function signature="grabMouseEvent(QEvent*)">
5472 <modify-argument index="1" invalidate-after-use="yes"/>
5474 <modify-argument index="1" invalidate-after-use="yes"/>
5473 </modify-function>
5475 </modify-function>
5474 <modify-function signature="hideEvent(QHideEvent*)">
5476 <modify-function signature="hideEvent(QHideEvent*)">
5475 <modify-argument index="1" invalidate-after-use="yes"/>
5477 <modify-argument index="1" invalidate-after-use="yes"/>
5476 </modify-function>
5478 </modify-function>
5477 <modify-function signature="moveEvent(QGraphicsSceneMoveEvent*)">
5479 <modify-function signature="moveEvent(QGraphicsSceneMoveEvent*)">
5478 <modify-argument index="1" invalidate-after-use="yes"/>
5480 <modify-argument index="1" invalidate-after-use="yes"/>
5479 </modify-function>
5481 </modify-function>
5480 <modify-function signature="paintWindowFrame(QPainter*,const QStyleOptionGraphicsItem*,QWidget*)">
5482 <modify-function signature="paintWindowFrame(QPainter*,const QStyleOptionGraphicsItem*,QWidget*)">
5481 <modify-argument index="1" invalidate-after-use="yes"/>
5483 <modify-argument index="1" invalidate-after-use="yes"/>
5482 </modify-function>
5484 </modify-function>
5483 <modify-function signature="resizeEvent(QGraphicsSceneResizeEvent*)">
5485 <modify-function signature="resizeEvent(QGraphicsSceneResizeEvent*)">
5484 <modify-argument index="1" invalidate-after-use="yes"/>
5486 <modify-argument index="1" invalidate-after-use="yes"/>
5485 </modify-function>
5487 </modify-function>
5486 <modify-function signature="showEvent(QShowEvent*)">
5488 <modify-function signature="showEvent(QShowEvent*)">
5487 <modify-argument index="1" invalidate-after-use="yes"/>
5489 <modify-argument index="1" invalidate-after-use="yes"/>
5488 </modify-function>
5490 </modify-function>
5489 <modify-function signature="ungrabKeyboardEvent(QEvent*)">
5491 <modify-function signature="ungrabKeyboardEvent(QEvent*)">
5490 <modify-argument index="1" invalidate-after-use="yes"/>
5492 <modify-argument index="1" invalidate-after-use="yes"/>
5491 </modify-function>
5493 </modify-function>
5492 <modify-function signature="ungrabMouseEvent(QEvent*)">
5494 <modify-function signature="ungrabMouseEvent(QEvent*)">
5493 <modify-argument index="1" invalidate-after-use="yes"/>
5495 <modify-argument index="1" invalidate-after-use="yes"/>
5494 </modify-function>
5496 </modify-function>
5495 <modify-function signature="windowFrameEvent(QEvent*)">
5497 <modify-function signature="windowFrameEvent(QEvent*)">
5496 <modify-argument index="1" invalidate-after-use="yes"/>
5498 <modify-argument index="1" invalidate-after-use="yes"/>
5497 </modify-function>
5499 </modify-function>
5498
5500
5499 <modify-function signature="setStyle(QStyle*)">
5501 <modify-function signature="setStyle(QStyle*)">
5500 <modify-argument index="1">
5502 <modify-argument index="1">
5501 <reference-count action="set" variable-name="__rcStyle"/>
5503 <reference-count action="set" variable-name="__rcStyle"/>
5502 </modify-argument>
5504 </modify-argument>
5503 </modify-function>
5505 </modify-function>
5504 <modify-function signature="setTabOrder(QGraphicsWidget*,QGraphicsWidget*)">
5506 <modify-function signature="setTabOrder(QGraphicsWidget*,QGraphicsWidget*)">
5505 <modify-argument index="1">
5507 <modify-argument index="1">
5506 <reference-count action="ignore"/>
5508 <reference-count action="ignore"/>
5507 </modify-argument>
5509 </modify-argument>
5508 <modify-argument index="2">
5510 <modify-argument index="2">
5509 <reference-count action="ignore"/>
5511 <reference-count action="ignore"/>
5510 </modify-argument>
5512 </modify-argument>
5511 </modify-function>
5513 </modify-function>
5512 </object-type>
5514 </object-type>
5513 <object-type name="QPlainTextDocumentLayout"/>
5515 <object-type name="QPlainTextDocumentLayout"/>
5514 <object-type name="QPlainTextEdit">
5516 <object-type name="QPlainTextEdit">
5515 <modify-function signature="setDocument(QTextDocument*)">
5517 <modify-function signature="setDocument(QTextDocument*)">
5516 <modify-argument index="1">
5518 <modify-argument index="1">
5517 <reference-count action="set" variable-name="__rcDocument"/>
5519 <reference-count action="set" variable-name="__rcDocument"/>
5518 </modify-argument>
5520 </modify-argument>
5519 </modify-function>
5521 </modify-function>
5520 <modify-function signature="insertFromMimeData(const QMimeData*)">
5522 <modify-function signature="insertFromMimeData(const QMimeData*)">
5521 <modify-argument index="1">
5523 <modify-argument index="1">
5522 <reference-count action="ignore"/>
5524 <reference-count action="ignore"/>
5523 </modify-argument>
5525 </modify-argument>
5524 </modify-function>
5526 </modify-function>
5525 </object-type>
5527 </object-type>
5526 <object-type name="QPrintPreviewDialog">
5528 <object-type name="QPrintPreviewDialog">
5527 </object-type>
5529 </object-type>
5528 <object-type name="QPrintPreviewWidget"/>
5530 <object-type name="QPrintPreviewWidget"/>
5529 <object-type name="QStyledItemDelegate">
5531 <object-type name="QStyledItemDelegate">
5530 <modify-function signature="setItemEditorFactory(QItemEditorFactory*)">
5532 <modify-function signature="setItemEditorFactory(QItemEditorFactory*)">
5531 <modify-argument index="1">
5533 <modify-argument index="1">
5532 <reference-count action="set" variable-name="__rcItemEditorFactory"/>
5534 <reference-count action="set" variable-name="__rcItemEditorFactory"/>
5533 </modify-argument>
5535 </modify-argument>
5534 </modify-function>
5536 </modify-function>
5535 <modify-function signature="setEditorData(QWidget*,QModelIndex)const">
5537 <modify-function signature="setEditorData(QWidget*,QModelIndex)const">
5536 <modify-argument index="1">
5538 <modify-argument index="1">
5537 <reference-count action="ignore"/>
5539 <reference-count action="ignore"/>
5538 </modify-argument>
5540 </modify-argument>
5539 </modify-function>
5541 </modify-function>
5540 <modify-function signature="setModelData(QWidget*,QAbstractItemModel*,QModelIndex)const">
5542 <modify-function signature="setModelData(QWidget*,QAbstractItemModel*,QModelIndex)const">
5541 <modify-argument index="1">
5543 <modify-argument index="1">
5542 <reference-count action="ignore"/>
5544 <reference-count action="ignore"/>
5543 </modify-argument>
5545 </modify-argument>
5544 </modify-function>
5546 </modify-function>
5545 </object-type>
5547 </object-type>
5546
5548
5547 <interface-type name="QIconEngineFactoryInterfaceV2" java-name="QAbstractIconEngineFactoryV2"/>
5549 <interface-type name="QIconEngineFactoryInterfaceV2" java-name="QAbstractIconEngineFactoryV2"/>
5548 <interface-type name="QImageIOHandlerFactoryInterface" java-name="QAbstractImageIOHandlerFactory"/>
5550 <interface-type name="QImageIOHandlerFactoryInterface" java-name="QAbstractImageIOHandlerFactory"/>
5549 <interface-type name="QInputContextFactoryInterface" java-name="QAbstractInputContextFactory"/>
5551 <interface-type name="QInputContextFactoryInterface" java-name="QAbstractInputContextFactory"/>
5550 <interface-type name="QStyleFactoryInterface" java-name="QAbstractStyleFactory"/>
5552 <interface-type name="QStyleFactoryInterface" java-name="QAbstractStyleFactory"/>
5551 <interface-type name="QPictureFormatInterface" java-name="QAbstractPictureFormat"/>
5553 <interface-type name="QPictureFormatInterface" java-name="QAbstractPictureFormat"/>
5552
5554
5553 <object-type name="QIconEnginePluginV2"/>
5555 <object-type name="QIconEnginePluginV2"/>
5554 <object-type name="QImageIOPlugin"/>
5556 <object-type name="QImageIOPlugin"/>
5555 <object-type name="QInputContextPlugin"/>
5557 <object-type name="QInputContextPlugin"/>
5556 <object-type name="QPictureFormatPlugin"/>
5558 <object-type name="QPictureFormatPlugin"/>
5557 <object-type name="QStylePlugin"/>
5559 <object-type name="QStylePlugin"/>
5558 <object-type name="QGesture"/>
5560 <object-type name="QGesture"/>
5559 <object-type name="QGraphicsAnchorLayout"/>
5561 <object-type name="QGraphicsAnchorLayout"/>
5560 <object-type name="QGraphicsAnchor"/>
5562 <object-type name="QGraphicsAnchor"/>
5561 <object-type name="QGraphicsBloomEffect"/>
5563 <object-type name="QGraphicsBloomEffect"/>
5562 <object-type name="QGraphicsBlurEffect"/>
5564 <object-type name="QGraphicsBlurEffect"/>
5563 <object-type name="QGraphicsColorizeEffect"/>
5565 <object-type name="QGraphicsColorizeEffect"/>
5564 <object-type name="QGraphicsDropShadowEffect"/>
5566 <object-type name="QGraphicsDropShadowEffect"/>
5565 <object-type name="QGraphicsEffect"/>
5567 <object-type name="QGraphicsEffect"/>
5566 <rejection class="QGraphicsEffectSource"/>
5568 <rejection class="QGraphicsEffectSource"/>
5567 <object-type name="QGraphicsGrayscaleEffect"/>
5569 <object-type name="QGraphicsGrayscaleEffect"/>
5568 <object-type name="QGraphicsObject">
5570 <object-type name="QGraphicsObject">
5569 <!-- Duplicate function to QObject::children() to override accidental shadowing which is not present in Jambi -->
5571 <!-- Duplicate function to QObject::children() to override accidental shadowing which is not present in Jambi -->
5570 <modify-function signature="children()const" remove="all"/>
5572 <modify-function signature="children()const" remove="all"/>
5571 <extra-includes>
5573 <extra-includes>
5572 <include file-name="QGesture" location="global"/>
5574 <include file-name="QGesture" location="global"/>
5573 </extra-includes>
5575 </extra-includes>
5574 </object-type>
5576 </object-type>
5575 <object-type name="QGraphicsOpacityEffect"/>
5577 <object-type name="QGraphicsOpacityEffect"/>
5576 <object-type name="QGraphicsPixelizeEffect"/>
5578 <object-type name="QGraphicsPixelizeEffect"/>
5577 <object-type name="QGraphicsRotation"/>
5579 <object-type name="QGraphicsRotation"/>
5578 <object-type name="QGraphicsScale"/>
5580 <object-type name="QGraphicsScale"/>
5579 <object-type name="QGraphicsTransform"/>
5581 <object-type name="QGraphicsTransform"/>
5580 <object-type name="QPanGesture"/>
5582 <object-type name="QPanGesture"/>
5581 <!-- QtScript: Doesn't compile because of redefinition of metatypeid -->
5583 <!-- QtScript: Doesn't compile because of redefinition of metatypeid -->
5582 <!-- <object-type name="QPinchGesture" /> -->
5584 <!-- <object-type name="QPinchGesture" /> -->
5583 <!-- QtScript: Doesn't compile because it's trying to call QFontMetrics default constructor -->
5585 <!-- QtScript: Doesn't compile because it's trying to call QFontMetrics default constructor -->
5584 <!-- <object-type name="QProxyStyle" /> -->
5586 <!-- <object-type name="QProxyStyle" /> -->
5585 <object-type name="QSwipeGesture"/>
5587 <object-type name="QSwipeGesture"/>
5586 <object-type name="QTouchEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::TouchBegin || %1-&gt;type() == QEvent::TouchUpdate || %1-&gt;type() == QEvent::TouchEnd"/>
5588 <object-type name="QTouchEvent" polymorphic-id-expression="%1-&gt;type() == QEvent::TouchBegin || %1-&gt;type() == QEvent::TouchUpdate || %1-&gt;type() == QEvent::TouchEnd"/>
5587
5589
5588 <enum-type name="QGesture::GestureCancelPolicy"/>
5590 <enum-type name="QGesture::GestureCancelPolicy"/>
5589 <enum-type name="QGraphicsEffect::PixmapPadMode"/>
5591 <enum-type name="QGraphicsEffect::PixmapPadMode"/>
5590 <enum-type name="QGraphicsBlurEffect::BlurHint" flags="QGraphicsBlurEffect::BlurHints"/>
5592 <enum-type name="QGraphicsBlurEffect::BlurHint" flags="QGraphicsBlurEffect::BlurHints"/>
5591 <enum-type name="QPinchGesture::ChangeFlag" flags="QPinchGesture::ChangeFlags"/>
5593 <enum-type name="QPinchGesture::ChangeFlag" flags="QPinchGesture::ChangeFlags"/>
5592 <rejection class="QAccessibleActionInterface"/>
5594 <rejection class="QAccessibleActionInterface"/>
5593 <rejection class="QAccessibleImageInterface"/>
5595 <rejection class="QAccessibleImageInterface"/>
5594 <value-type name="QMatrix3x3">
5596 <value-type name="QMatrix3x3">
5595 <modify-function signature="toGenericMatrix()const" remove="all"/>
5597 <modify-function signature="toGenericMatrix()const" remove="all"/>
5596 </value-type>
5598 </value-type>
5597
5599
5598 <!-- Inefficient hash codes -->
5600 <!-- Inefficient hash codes -->
5599 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextFrame_iterator' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5601 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextFrame_iterator' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5600 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextTableCell' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5602 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextTableCell' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5601 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextOption_Tab' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5603 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextOption_Tab' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5602 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextLength' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5604 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextLength' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5603 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextBlock_iterator' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5605 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextBlock_iterator' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5604 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextBlock' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5606 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextBlock' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5605 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextCursor' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5607 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextCursor' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5606 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QPainterPath_Element' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5608 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QPainterPath_Element' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5607 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QPainterPath' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5609 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QPainterPath' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5608 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QItemSelection' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5610 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QItemSelection' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5609 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QKeySequence' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5611 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QKeySequence' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5610 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QSizePolicy' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5612 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QSizePolicy' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5611 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextFragment' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5613 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextFragment' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5612 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QFontMetrics' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5614 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QFontMetrics' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5613 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QGradient' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5615 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QGradient' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5614 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QFontMetricsF' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5616 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QFontMetricsF' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5615 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextFormat' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5617 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QTextFormat' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5616 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QEasingCurve' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5618 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QEasingCurve' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5617 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QGenericMatrix' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5619 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QGenericMatrix' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5618 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QMatrix4x4' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5620 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QMatrix4x4' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5619 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QMargins' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5621 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QMargins' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5620 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QPixmapCache_Key' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5622 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QPixmapCache_Key' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5621 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QVector4D' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5623 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QVector4D' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5622 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QQuaternion' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5624 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QQuaternion' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5623 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QVector2D' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5625 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QVector2D' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5624 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QVector3D' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5626 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QVector3D' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
5625
5627
5626 <suppress-warning text="WARNING(MetaJavaBuilder) :: private virtual function 'eventFilter(QObject * receiver, QEvent * event)' in 'QPanGesture'"/>
5628 <suppress-warning text="WARNING(MetaJavaBuilder) :: private virtual function 'eventFilter(QObject * receiver, QEvent * event)' in 'QPanGesture'"/>
5627 <suppress-warning text="WARNING(MetaJavaBuilder) :: private virtual function 'event(QEvent * event)' in 'QPanGesture'"/>
5629 <suppress-warning text="WARNING(MetaJavaBuilder) :: private virtual function 'event(QEvent * event)' in 'QPanGesture'"/>
5628 <suppress-warning text="WARNING(MetaJavaBuilder) :: private virtual function 'eventFilter(QObject * receiver, QEvent * event)' in 'QSwipeGesture'"/>
5630 <suppress-warning text="WARNING(MetaJavaBuilder) :: private virtual function 'eventFilter(QObject * receiver, QEvent * event)' in 'QSwipeGesture'"/>
5629 <suppress-warning text="WARNING(MetaJavaBuilder) :: private virtual function 'eventFilter(QObject * receiver, QEvent * event)' in 'QPinchGesture'"/>
5631 <suppress-warning text="WARNING(MetaJavaBuilder) :: private virtual function 'eventFilter(QObject * receiver, QEvent * event)' in 'QPinchGesture'"/>
5630 <suppress-warning text="WARNING(MetaJavaBuilder) :: private virtual function 'event(QEvent * event)' in 'QPinchGesture'"/>
5632 <suppress-warning text="WARNING(MetaJavaBuilder) :: private virtual function 'event(QEvent * event)' in 'QPinchGesture'"/>
5631
5633
5632 <!-- Intentional omissions. See explanation for QtJambiTextObjectInterface class in typesystem and headers. -->
5634 <!-- Intentional omissions. See explanation for QtJambiTextObjectInterface class in typesystem and headers. -->
5633 <suppress-warning text="WARNING(MetaJavaBuilder) :: class 'QTextObjectInterface' inherits from unknown base class 'QTextObjectInterface'"/>
5635 <suppress-warning text="WARNING(MetaJavaBuilder) :: class 'QTextObjectInterface' inherits from unknown base class 'QTextObjectInterface'"/>
5634 <suppress-warning text="WARNING(MetaJavaBuilder) :: unknown interface for 'QTextObjectInterface': 'QTextObjectInterfaceInterface'"/>
5636 <suppress-warning text="WARNING(MetaJavaBuilder) :: unknown interface for 'QTextObjectInterface': 'QTextObjectInterfaceInterface'"/>
5635
5637
5636 <suppress-warning text="WARNING(MetaInfoGenerator) :: class 'QPixmapFilter' inherits from polymorphic class 'QPixmapFilter', but has no polymorphic id set"/>
5638 <suppress-warning text="WARNING(MetaInfoGenerator) :: class 'QPixmapFilter' inherits from polymorphic class 'QPixmapFilter', but has no polymorphic id set"/>
5637 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QPixmap::QPixmap', unmatched parameter type 'QPixmapData*'"/>
5639 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QPixmap::QPixmap', unmatched parameter type 'QPixmapData*'"/>
5638 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type '*Private&amp;'"/>
5640 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type '*Private&amp;'"/>
5639 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type '*Private\*'"/>
5641 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type '*Private\*'"/>
5640 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type '*Private const\*'"/>
5642 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type '*Private const\*'"/>
5641 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QTextEngine\*'"/>
5643 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QTextEngine\*'"/>
5642 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QFontEngine\*'"/>
5644 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QFontEngine\*'"/>
5643 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QPixmap::Type'"/>
5645 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QPixmap::Type'"/>
5644 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QInputDialog::Type'"/>
5646 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QInputDialog::Type'"/>
5645 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QTextFrameLayoutData\*'"/>
5647 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QTextFrameLayoutData\*'"/>
5646 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QAbstractUndoItem\*'"/>
5648 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QAbstractUndoItem\*'"/>
5647 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type '*QImageTextKeyLang*'"/>
5649 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type '*QImageTextKeyLang*'"/>
5648 <suppress-warning text="WARNING(MetaJavaBuilder) :: non-public function '*' in interface '*'"/>
5650 <suppress-warning text="WARNING(MetaJavaBuilder) :: non-public function '*' in interface '*'"/>
5649 <suppress-warning text="WARNING(MetaJavaBuilder) :: visibility of function '*' modified in class '*'"/>
5651 <suppress-warning text="WARNING(MetaJavaBuilder) :: visibility of function '*' modified in class '*'"/>
5650 <suppress-warning text="WARNING(MetaJavaBuilder) :: hiding of function '*' in class '*'"/>
5652 <suppress-warning text="WARNING(MetaJavaBuilder) :: hiding of function '*' in class '*'"/>
5651 <suppress-warning text="WARNING(MetaJavaBuilder) :: unsupported default value 'QVector&lt;FormatRange&gt;()' of argument in function '*', class '*'"/>
5653 <suppress-warning text="WARNING(MetaJavaBuilder) :: unsupported default value 'QVector&lt;FormatRange&gt;()' of argument in function '*', class '*'"/>
5652 <suppress-warning text="WARNING(MetaJavaBuilder) :: unsupported default value 'QVariantList()' of argument in function '*', class '*'"/>
5654 <suppress-warning text="WARNING(MetaJavaBuilder) :: unsupported default value 'QVariantList()' of argument in function '*', class '*'"/>
5653 <suppress-warning text="WARNING(CppImplGenerator) :: protected function '*' in final class '*'"/>
5655 <suppress-warning text="WARNING(CppImplGenerator) :: protected function '*' in final class '*'"/>
5654 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QTextLayout::QTextLayout', unmatched parameter type 'QTextEngine*'"/>
5656 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QTextLayout::QTextLayout', unmatched parameter type 'QTextEngine*'"/>
5655 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFileDialog::QFileDialog', unmatched parameter type 'QFileDialogArgs const&amp;'"/>
5657 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QFileDialog::QFileDialog', unmatched parameter type 'QFileDialogArgs const&amp;'"/>
5656 <suppress-warning text="WARNING(MetaJavaBuilder) :: unsupported default value '0., 0., 1000000000., 1000000000.' of argument in function 'update', class 'QAbstractTextDocumentLayout'"/>
5658 <suppress-warning text="WARNING(MetaJavaBuilder) :: unsupported default value '0., 0., 1000000000., 1000000000.' of argument in function 'update', class 'QAbstractTextDocumentLayout'"/>
5657 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QWidget::windowSurface', unmatched return type 'QWindowSurface*'"/>
5659 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QWidget::windowSurface', unmatched return type 'QWindowSurface*'"/>
5658 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QWidget::setWindowSurface', unmatched parameter type 'QWindowSurface*'"/>
5660 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QWidget::setWindowSurface', unmatched parameter type 'QWindowSurface*'"/>
5659 <suppress-warning text="WARNING(MetaJavaBuilder) :: enum 'QStyleOption::StyleOptionType' does not have a type entry or is not an enum"/>
5661 <suppress-warning text="WARNING(MetaJavaBuilder) :: enum 'QStyleOption::StyleOptionType' does not have a type entry or is not an enum"/>
5660 <suppress-warning text="WARNING(MetaJavaBuilder) :: unhandled enum value: ~FlagMask in QMessageBox::StandardButton"/>
5662 <suppress-warning text="WARNING(MetaJavaBuilder) :: unhandled enum value: ~FlagMask in QMessageBox::StandardButton"/>
5661 <suppress-warning text="WARNING(MetaJavaBuilder) :: unmatched enum ~FlagMask"/>
5663 <suppress-warning text="WARNING(MetaJavaBuilder) :: unmatched enum ~FlagMask"/>
5662 <suppress-warning text="WARNING(MetaInfoGenerator) :: class 'QGraphicsSceneEvent' inherits from polymorphic class 'QEvent', but has no polymorphic id set"/>
5664 <suppress-warning text="WARNING(MetaInfoGenerator) :: class 'QGraphicsSceneEvent' inherits from polymorphic class 'QEvent', but has no polymorphic id set"/>
5663 <suppress-warning text="WARNING(MetaInfoGenerator) :: class 'QInputEvent' inherits from polymorphic class 'QEvent', but has no polymorphic id set"/>
5665 <suppress-warning text="WARNING(MetaInfoGenerator) :: class 'QInputEvent' inherits from polymorphic class 'QEvent', but has no polymorphic id set"/>
5664 <suppress-warning text="WARNING(JavaGenerator) :: either add or remove specified for reference count variable '__rcMenus' in 'com.trolltech.qt.gui.QMenu' but not both"/>
5666 <suppress-warning text="WARNING(JavaGenerator) :: either add or remove specified for reference count variable '__rcMenus' in 'com.trolltech.qt.gui.QMenu' but not both"/>
5665 <suppress-warning text="WARNING(JavaGenerator) :: either add or remove specified for reference count variable '__rcMenus' in 'com.trolltech.qt.gui.QMenuBar' but not both"/>
5667 <suppress-warning text="WARNING(JavaGenerator) :: either add or remove specified for reference count variable '__rcMenus' in 'com.trolltech.qt.gui.QMenuBar' but not both"/>
5666
5668
5667 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QPixmap::pixmapData', unmatched return type 'QPixmapData*'"/>
5669 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping function 'QPixmap::pixmapData', unmatched return type 'QPixmapData*'"/>
5670 <suppress-warning text="WARNING(MetaJavaBuilder) :: object type 'QAccessible' extended by interface type 'QAbstractAccessibleFactory'. The resulting API will be less expressive than the original."/>
5668
5671
5669 <suppress-warning text="WARNING(MetaJavaBuilder) :: Rejected enum has no alternative...: QPalette::NColorRoles"/>
5672 <suppress-warning text="WARNING(MetaJavaBuilder) :: Rejected enum has no alternative...: QPalette::NColorRoles"/>
5670
5673
5671 <suppress-warning text="WARNING(MetaJavaBuilder) :: namespace 'QtSharedPointer' does not have a type entry"/>
5674 <suppress-warning text="WARNING(MetaJavaBuilder) :: namespace 'QtSharedPointer' does not have a type entry"/>
5672
5675
5673 </typesystem>
5676 </typesystem>
@@ -1,106 +1,99
1 <?xml version="1.0"?>
1 <?xml version="1.0"?>
2 <typesystem package="com.trolltech.qt.opengl"><rejection class="QGL"/><rejection class="QGLFormat"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QGLFormat' has equals operators but no qHash() function"/>
2 <typesystem package="com.trolltech.qt.opengl"><rejection class="QGL"/><rejection class="QGLFormat"/><suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QGLFormat' has equals operators but no qHash() function"/>
3 <rejection class="QGLColormap::QGLColormapData"/>
3 <rejection class="QGLColormap::QGLColormapData"/>
4 <rejection class="QGLWidget" function-name="setMouseTracking"/>
4 <rejection class="QGLWidget" function-name="setMouseTracking"/>
5
5
6 <enum-type name="QGL::FormatOption" flags="QGL::FormatOptions"/>
6 <enum-type name="QGL::FormatOption" flags="QGL::FormatOptions"/>
7 <enum-type name="QGLFormat::OpenGLVersionFlag" flags="QGLFormat::OpenGLVersionFlags"/>
7 <enum-type name="QGLFormat::OpenGLVersionFlag" flags="QGLFormat::OpenGLVersionFlags"/>
8 <enum-type name="QGLFramebufferObject::Attachment"/>
8 <enum-type name="QGLFramebufferObject::Attachment"/>
9 <enum-type name="QGLContext::BindOption" flags="QGLContext::BindOptions"/>
9 <enum-type name="QGLContext::BindOption" flags="QGLContext::BindOptions"/>
10 <enum-type name="QGLShader::ShaderTypeBit" flags="QGLShader::ShaderType"/>
10 <enum-type name="QGLShader::ShaderTypeBit" flags="QGLShader::ShaderType"/>
11
11
12 <enum-type name="QGLBuffer::Access"/>
13 <enum-type name="QGLBuffer::Type"/>
14 <enum-type name="QGLBuffer::UsagePattern"/>
15 <enum-type name="QGLFunctions::OpenGLFeature"/>
16 <enum-type name="QGLFormat::OpenGLContextProfile"/>
17
12
18 <namespace-type name="QGL">
13 <namespace-type name="QGL">
19 <include file-name="qgl.h" location="global"/>
14 <include file-name="qgl.h" location="global"/>
20 </namespace-type>
15 </namespace-type>
21
16
22 <value-type name="QGLColormap">
17 <value-type name="QGLColormap">
23 <modify-function signature="operator=(QGLColormap)" remove="all"/>
18 <modify-function signature="operator=(QGLColormap)" remove="all"/>
24
19
25 <modify-function signature="setEntries(int,const unsigned int*,int)">
20 <modify-function signature="setEntries(int,const unsigned int*,int)">
26 <access modifier="private"/>
21 <access modifier="private"/>
27 </modify-function>
22 </modify-function>
28 </value-type>
23 </value-type>
29
24
30 <value-type name="QGLFormat">
25 <value-type name="QGLFormat">
31 <modify-function signature="operator=(QGLFormat)" remove="all"/>
26 <modify-function signature="operator=(QGLFormat)" remove="all"/>
32 </value-type>
27 </value-type>
33
28
34 <value-type name="QGLFramebufferObjectFormat"/>
29 <value-type name="QGLFramebufferObjectFormat"/>
35 <object-type name="QGLFunctions"/>
36 <object-type name="QGLBuffer"/>
37 <object-type name="QGLShader"/>
30 <object-type name="QGLShader"/>
38 <object-type name="QGLShaderProgram">
31 <object-type name="QGLShaderProgram">
39 <!-- Should be disambiguated later by fixing the native pointer API -->
32 <!-- Should be disambiguated later by fixing the native pointer API -->
40 <modify-function signature="setAttributeArray(int, const QVector2D *, int)" rename="setAttributeArray_QVector2D"/>
33 <modify-function signature="setAttributeArray(int, const QVector2D *, int)" rename="setAttributeArray_QVector2D"/>
41 <modify-function signature="setAttributeArray(int, const QVector3D *, int)" rename="setAttributeArray_QVector3D"/>
34 <modify-function signature="setAttributeArray(int, const QVector3D *, int)" rename="setAttributeArray_QVector3D"/>
42 <modify-function signature="setAttributeArray(int, const QVector4D *, int)" rename="setAttributeArray_QVector4D"/>
35 <modify-function signature="setAttributeArray(int, const QVector4D *, int)" rename="setAttributeArray_QVector4D"/>
43 <modify-function signature="setAttributeArray(const char *, const QVector2D *, int)" rename="setAttributeArray_QVector2D"/>
36 <modify-function signature="setAttributeArray(const char *, const QVector2D *, int)" rename="setAttributeArray_QVector2D"/>
44 <modify-function signature="setAttributeArray(const char *, const QVector3D *, int)" rename="setAttributeArray_QVector3D"/>
37 <modify-function signature="setAttributeArray(const char *, const QVector3D *, int)" rename="setAttributeArray_QVector3D"/>
45 <modify-function signature="setAttributeArray(const char *, const QVector4D *, int)" rename="setAttributeArray_QVector4D"/>
38 <modify-function signature="setAttributeArray(const char *, const QVector4D *, int)" rename="setAttributeArray_QVector4D"/>
46 <modify-function signature="setUniformValueArray(int, const GLint *, int)" rename="setUniformValueArray_int"/>
39 <modify-function signature="setUniformValueArray(int, const GLint *, int)" rename="setUniformValueArray_int"/>
47 <modify-function signature="setUniformValueArray(int, const GLuint *, int)" rename="setUniformValueArray_uint"/>
40 <modify-function signature="setUniformValueArray(int, const GLuint *, int)" rename="setUniformValueArray_uint"/>
48 <modify-function signature="setUniformValueArray(int, const QVector2D *, int)" rename="setUniformValueArray_QVector2D"/>
41 <modify-function signature="setUniformValueArray(int, const QVector2D *, int)" rename="setUniformValueArray_QVector2D"/>
49 <modify-function signature="setUniformValueArray(int, const QVector3D *, int)" rename="setUniformValueArray_QVector3D"/>
42 <modify-function signature="setUniformValueArray(int, const QVector3D *, int)" rename="setUniformValueArray_QVector3D"/>
50 <modify-function signature="setUniformValueArray(int, const QVector4D *, int)" rename="setUniformValueArray_QVector4D"/>
43 <modify-function signature="setUniformValueArray(int, const QVector4D *, int)" rename="setUniformValueArray_QVector4D"/>
51
44
52 <modify-function signature="setUniformValueArray(const char*, const GLint *, int)" rename="setUniformValueArray_int"/>
45 <modify-function signature="setUniformValueArray(const char*, const GLint *, int)" rename="setUniformValueArray_int"/>
53 <modify-function signature="setUniformValueArray(const char*, const GLuint *, int)" remove="all"/>
46 <modify-function signature="setUniformValueArray(const char*, const GLuint *, int)" remove="all"/>
54 <modify-function signature="setUniformValueArray(const char*, const QVector2D *, int)" rename="setUniformValueArray_QVector2D"/>
47 <modify-function signature="setUniformValueArray(const char*, const QVector2D *, int)" rename="setUniformValueArray_QVector2D"/>
55 <modify-function signature="setUniformValueArray(const char*, const QVector3D *, int)" rename="setUniformValueArray_QVector3D"/>
48 <modify-function signature="setUniformValueArray(const char*, const QVector3D *, int)" rename="setUniformValueArray_QVector3D"/>
56 <modify-function signature="setUniformValueArray(const char*, const QVector4D *, int)" rename="setUniformValueArray_QVector4D"/>
49 <modify-function signature="setUniformValueArray(const char*, const QVector4D *, int)" rename="setUniformValueArray_QVector4D"/>
57 <modify-function signature="setUniformValue(int, GLuint)" remove="all"/>
50 <modify-function signature="setUniformValue(int, GLuint)" remove="all"/>
58 <modify-function signature="setUniformValue(const char*, GLuint)" remove="all"/>
51 <modify-function signature="setUniformValue(const char*, GLuint)" remove="all"/>
59 <modify-function signature="setUniformValue(int, Array)" remove="all"/>
52 <modify-function signature="setUniformValue(int, Array)" remove="all"/>
60 <modify-function signature="setUniformValue(const char*, Array)" remove="all"/>
53 <modify-function signature="setUniformValue(const char*, Array)" remove="all"/>
61 </object-type>
54 </object-type>
62 <object-type name="QGLContext">
55 <object-type name="QGLContext">
63
56
64 <modify-function signature="chooseContext(const QGLContext*)">
57 <modify-function signature="chooseContext(const QGLContext*)">
65 <modify-argument index="1" invalidate-after-use="yes"/>
58 <modify-argument index="1" invalidate-after-use="yes"/>
66 </modify-function>
59 </modify-function>
67 <modify-function signature="create(const QGLContext*)">
60 <modify-function signature="create(const QGLContext*)">
68 <modify-argument index="1" invalidate-after-use="yes"/>
61 <modify-argument index="1" invalidate-after-use="yes"/>
69 </modify-function>
62 </modify-function>
70
63
71 <modify-function signature="getProcAddress(QString)const">
64 <modify-function signature="getProcAddress(QString)const">
72 <remove/>
65 <remove/>
73 </modify-function>
66 </modify-function>
74 <modify-field name="currentCtx" read="false" write="false"/>
67 <modify-field name="currentCtx" read="false" write="false"/>
75 <modify-function signature="setDevice(QPaintDevice*)">
68 <modify-function signature="setDevice(QPaintDevice*)">
76 <remove/>
69 <remove/>
77 </modify-function>
70 </modify-function>
78 <modify-function signature="generateFontDisplayLists(QFont, int)" remove="all"/>
71 <modify-function signature="generateFontDisplayLists(QFont, int)" remove="all"/>
79 </object-type>
72 </object-type>
80 <object-type name="QGLFramebufferObject"/>
73 <object-type name="QGLFramebufferObject"/>
81 <object-type name="QGLPixelBuffer">
74 <object-type name="QGLPixelBuffer">
82 <extra-includes>
75 <extra-includes>
83 <include file-name="QImage" location="global"/>
76 <include file-name="QImage" location="global"/>
84 </extra-includes>
77 </extra-includes>
85 </object-type>
78 </object-type>
86 <object-type name="QGLWidget">
79 <object-type name="QGLWidget">
87 <extra-includes>
80 <extra-includes>
88 <include file-name="QImage" location="global"/>
81 <include file-name="QImage" location="global"/>
89 <include file-name="QPixmap" location="global"/>
82 <include file-name="QPixmap" location="global"/>
90 </extra-includes>
83 </extra-includes>
91 <modify-function signature="setContext(QGLContext*,const QGLContext*,bool)">
84 <modify-function signature="setContext(QGLContext*,const QGLContext*,bool)">
92 <remove/> <!--- Obsolete -->
85 <remove/> <!--- Obsolete -->
93 </modify-function>
86 </modify-function>
94 <modify-function signature="fontDisplayListBase(QFont, int)" remove="all"/>
87 <modify-function signature="fontDisplayListBase(QFont, int)" remove="all"/>
95 <modify-function signature="setFormat(QGLFormat)" remove="all"/>
88 <modify-function signature="setFormat(QGLFormat)" remove="all"/>
96 </object-type>
89 </object-type>
97
90
98 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QGLFormat' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
91 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QGLFormat' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
99 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QGLFramebufferObjectFormat' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
92 <suppress-warning text="WARNING(MetaJavaBuilder) :: Class 'QGLFramebufferObjectFormat' has equals operators but no qHash() function. Hashcode of objects will consistently be 0."/>
100
93
101 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QGLColormap::QGLColormapData\*'"/>
94 <suppress-warning text="WARNING(MetaJavaBuilder) :: skipping * unmatched *type 'QGLColormap::QGLColormapData\*'"/>
102 <suppress-warning text="WARNING(MetaJavaBuilder) :: visibility of function '*' modified in class '*'"/>
95 <suppress-warning text="WARNING(MetaJavaBuilder) :: visibility of function '*' modified in class '*'"/>
103 <suppress-warning text="WARNING(MetaJavaBuilder) :: hiding of function '*' in class '*'"/>
96 <suppress-warning text="WARNING(MetaJavaBuilder) :: hiding of function '*' in class '*'"/>
104 <suppress-warning text="WARNING(CppImplGenerator) :: protected function '*' in final class '*'"/>
97 <suppress-warning text="WARNING(CppImplGenerator) :: protected function '*' in final class '*'"/>
105
98
106 </typesystem>
99 </typesystem>
@@ -1,113 +1,113
1 project(PythonQt_Core)
1 project(PythonQt_Core)
2 cmake_minimum_required(VERSION 2.8.10)
2 cmake_minimum_required(VERSION 2.8.10)
3
3
4 #-----------------------------------------------------------------------------
4 #-----------------------------------------------------------------------------
5 # Sources
5 # Sources
6
6
7 set(SOURCES
7 set(SOURCES
8 PythonQtClassInfo.cpp
8 PythonQtClassInfo.cpp
9 PythonQtClassWrapper.cpp
9 PythonQtClassWrapper.cpp
10 PythonQtConversion.cpp
10 PythonQtConversion.cpp
11 PythonQt.cpp
11 PythonQt.cpp
12 PythonQtImporter.cpp
12 PythonQtImporter.cpp
13 PythonQtInstanceWrapper.cpp
13 PythonQtInstanceWrapper.cpp
14 PythonQtMethodInfo.cpp
14 PythonQtMethodInfo.cpp
15 PythonQtMisc.cpp
15 PythonQtMisc.cpp
16 PythonQtObjectPtr.cpp
16 PythonQtObjectPtr.cpp
17 PythonQtQFileImporter.cpp
17 PythonQtQFileImporter.cpp
18 PythonQtSignalReceiver.cpp
18 PythonQtSignalReceiver.cpp
19 PythonQtSlot.cpp
19 PythonQtSlot.cpp
20 PythonQtSignal.cpp
20 PythonQtSignal.cpp
21 PythonQtStdDecorators.cpp
21 PythonQtStdDecorators.cpp
22 PythonQtStdIn.cpp
22 PythonQtStdIn.cpp
23 PythonQtStdOut.cpp
23 PythonQtStdOut.cpp
24 gui/PythonQtScriptingConsole.cpp
24 gui/PythonQtScriptingConsole.cpp
25
25
26 ../generated_cpp${generated_cpp_suffix}/PythonQt_QtBindings.cpp
26 ../generated_cpp${generated_cpp_suffix}/PythonQt_QtBindings.cpp
27
27
28 ../generated_cpp${generated_cpp_suffix}/com_trolltech_qt_core_builtin/com_trolltech_qt_core_builtin0.cpp
28 ../generated_cpp${generated_cpp_suffix}/com_trolltech_qt_core_builtin/com_trolltech_qt_core_builtin0.cpp
29 ../generated_cpp${generated_cpp_suffix}/com_trolltech_qt_core_builtin/com_trolltech_qt_core_builtin_init.cpp
29 ../generated_cpp${generated_cpp_suffix}/com_trolltech_qt_core_builtin/com_trolltech_qt_core_builtin_init.cpp
30 ../generated_cpp${generated_cpp_suffix}/com_trolltech_qt_gui_builtin/com_trolltech_qt_gui_builtin0.cpp
30 ../generated_cpp${generated_cpp_suffix}/com_trolltech_qt_gui_builtin/com_trolltech_qt_gui_builtin0.cpp
31 ../generated_cpp${generated_cpp_suffix}/com_trolltech_qt_gui_builtin/com_trolltech_qt_gui_builtin_init.cpp
31 ../generated_cpp${generated_cpp_suffix}/com_trolltech_qt_gui_builtin/com_trolltech_qt_gui_builtin_init.cpp
32 )
32 )
33
33
34 #-----------------------------------------------------------------------------
34 #-----------------------------------------------------------------------------
35 # List headers. This is list is used for the install command.
35 # List headers. This is list is used for the install command.
36
36
37 set(HEADERS
37 set(HEADERS
38 PythonQtClassInfo.h
38 PythonQtClassInfo.h
39 PythonQtClassWrapper.h
39 PythonQtClassWrapper.h
40 PythonQtConversion.h
40 PythonQtConversion.h
41 PythonQtCppWrapperFactory.h
41 PythonQtCppWrapperFactory.h
42 PythonQtDoc.h
42 PythonQtDoc.h
43 PythonQt.h
43 PythonQt.h
44 PythonQtImporter.h
44 PythonQtImporter.h
45 PythonQtImportFileInterface.h
45 PythonQtImportFileInterface.h
46 PythonQtInstanceWrapper.h
46 PythonQtInstanceWrapper.h
47 PythonQtMethodInfo.h
47 PythonQtMethodInfo.h
48 PythonQtMisc.h
48 PythonQtMisc.h
49 PythonQtObjectPtr.h
49 PythonQtObjectPtr.h
50 PythonQtQFileImporter.h
50 PythonQtQFileImporter.h
51 PythonQtSignalReceiver.h
51 PythonQtSignalReceiver.h
52 PythonQtSlot.h
52 PythonQtSlot.h
53 PythonQtSignal.h
53 PythonQtSignal.h
54 PythonQtStdDecorators.h
54 PythonQtStdDecorators.h
55 PythonQtStdIn.h
55 PythonQtStdIn.h
56 PythonQtStdOut.h
56 PythonQtStdOut.h
57 PythonQtSystem.h
57 PythonQtSystem.h
58 PythonQtVariants.h
58 PythonQtVariants.h
59 PythonQtPythonInclude.h
59 PythonQtPythonInclude.h
60 ../generated_cpp${generated_cpp_suffix}/PythonQt_QtBindings.h
60 ../generated_cpp${generated_cpp_suffix}/PythonQt_QtBindings.h
61 )
61 )
62
62
63 #-----------------------------------------------------------------------------
63 #-----------------------------------------------------------------------------
64 # Headers that should run through moc
64 # Headers that should run through moc
65
65
66 set(SOURCES_MOC
66 set(SOURCES_MOC
67 PythonQt.h
67 PythonQt.h
68 PythonQtSignalReceiver.h
68 PythonQtSignalReceiver.h
69 PythonQtStdDecorators.h
69 PythonQtStdDecorators.h
70 gui/PythonQtScriptingConsole.h
70 gui/PythonQtScriptingConsole.h
71
71
72 ../generated_cpp${generated_cpp_suffix}/com_trolltech_qt_core_builtin/com_trolltech_qt_core_builtin0.h
72 ../generated_cpp${generated_cpp_suffix}/com_trolltech_qt_core_builtin/com_trolltech_qt_core_builtin0.h
73 ../generated_cpp${generated_cpp_suffix}/com_trolltech_qt_gui_builtin/com_trolltech_qt_gui_builtin0.h
73 ../generated_cpp${generated_cpp_suffix}/com_trolltech_qt_gui_builtin/com_trolltech_qt_gui_builtin0.h
74 )
74 )
75
75
76 #-----------------------------------------------------------------------------
76 #-----------------------------------------------------------------------------
77 # Resources
77 # Resources
78 set(SOURCES_QRC )
78 set(SOURCES_QRC )
79
79
80 #-----------------------------------------------------------------------------
80 #-----------------------------------------------------------------------------
81 # Do wrapping
81 # Do wrapping
82 qt_wrap_cpp(GEN_MOC ${SOURCES_MOC})
82 qt_wrap_cpp(GEN_MOC ${SOURCES_MOC})
83 qt_add_resources(GEN_QRC ${SOURCES_QRC})
83 qt_add_resources(GEN_QRC ${SOURCES_QRC})
84
84
85 #-----------------------------------------------------------------------------
85 #-----------------------------------------------------------------------------
86 # Build the library
86 # Build the library
87
87
88 include_directories(${CMAKE_CURRENT_SOURCE_DIR})
88 include_directories(${CMAKE_CURRENT_SOURCE_DIR})
89
89
90 add_definitions(-DQT_NO_KEYWORDS) # recent python versions use them :(
90 #add_definitions(-DQT_NO_KEYWORDS) # recent python versions use them :(
91
91
92 add_library(PythonQt SHARED ${SOURCES} ${GEN_MOC} ${GEN_QRC})
92 add_library(PythonQt SHARED ${SOURCES} ${GEN_MOC} ${GEN_QRC} ${HEADERS})
93 if(PythonQt_Qt5)
93 if(PythonQt_Qt5)
94 qt_use_modules(PythonQt Core Gui Widgets)
94 qt_use_modules(PythonQt Core Gui Widgets)
95 else()
95 else()
96 qt_use_modules(PythonQt Core Gui)
96 qt_use_modules(PythonQt Core Gui)
97 endif()
97 endif()
98 target_link_libraries(PythonQt ${PYTHON_LIBRARIES})
98 target_link_libraries(PythonQt ${PYTHON_LIBRARIES})
99
99
100 #
100 #
101 # That should solve linkage error on Mac when the project is used in a superbuild setup
101 # That should solve linkage error on Mac when the project is used in a superbuild setup
102 # See http://blog.onesadcookie.com/2008/01/installname-magic.html
102 # See http://blog.onesadcookie.com/2008/01/installname-magic.html
103 #
103 #
104 set_target_properties(PythonQt PROPERTIES INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib")
104 set_target_properties(PythonQt PROPERTIES INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib")
105
105
106 #-----------------------------------------------------------------------------
106 #-----------------------------------------------------------------------------
107 # Install library (on windows, put the dll in 'bin' and the archive in 'lib')
107 # Install library (on windows, put the dll in 'bin' and the archive in 'lib')
108
108
109 install(TARGETS PythonQt
109 install(TARGETS PythonQt
110 RUNTIME DESTINATION bin
110 RUNTIME DESTINATION bin
111 LIBRARY DESTINATION lib
111 LIBRARY DESTINATION lib
112 ARCHIVE DESTINATION lib)
112 ARCHIVE DESTINATION lib)
113 install(FILES ${headers} DESTINATION include/PythonQt)
113 install(FILES ${headers} DESTINATION include/PythonQt)
@@ -1,1911 +1,2064
1 /*
1 /*
2 *
2 *
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
4 *
4 *
5 * This library is free software; you can redistribute it and/or
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
8 * version 2.1 of the License, or (at your option) any later version.
9 *
9 *
10 * This library is distributed in the hope that it will be useful,
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
13 * Lesser General Public License for more details.
14 *
14 *
15 * Further, this software is distributed without any warranty that it is
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
20 * other software, or any other product whatsoever.
21 *
21 *
22 * You should have received a copy of the GNU Lesser General Public
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
25 *
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
27 * 28359 Bremen, Germany or:
27 * 28359 Bremen, Germany or:
28 *
28 *
29 * http://www.mevis.de
29 * http://www.mevis.de
30 *
30 *
31 */
31 */
32
32
33 //----------------------------------------------------------------------------------
33 //----------------------------------------------------------------------------------
34 /*!
34 /*!
35 // \file PythonQt.cpp
35 // \file PythonQt.cpp
36 // \author Florian Link
36 // \author Florian Link
37 // \author Last changed by $Author: florian $
37 // \author Last changed by $Author: florian $
38 // \date 2006-05
38 // \date 2006-05
39 */
39 */
40 //----------------------------------------------------------------------------------
40 //----------------------------------------------------------------------------------
41
41
42 #include "PythonQt.h"
42 #include "PythonQt.h"
43 #include "PythonQtImporter.h"
43 #include "PythonQtImporter.h"
44 #include "PythonQtClassInfo.h"
44 #include "PythonQtClassInfo.h"
45 #include "PythonQtMethodInfo.h"
45 #include "PythonQtMethodInfo.h"
46 #include "PythonQtSignal.h"
46 #include "PythonQtSignal.h"
47 #include "PythonQtSignalReceiver.h"
47 #include "PythonQtSignalReceiver.h"
48 #include "PythonQtConversion.h"
48 #include "PythonQtConversion.h"
49 #include "PythonQtStdIn.h"
49 #include "PythonQtStdIn.h"
50 #include "PythonQtStdOut.h"
50 #include "PythonQtStdOut.h"
51 #include "PythonQtCppWrapperFactory.h"
51 #include "PythonQtCppWrapperFactory.h"
52 #include "PythonQtVariants.h"
52 #include "PythonQtVariants.h"
53 #include "PythonQtStdDecorators.h"
53 #include "PythonQtStdDecorators.h"
54 #include "PythonQtQFileImporter.h"
54 #include "PythonQtQFileImporter.h"
55 #include <pydebug.h>
55 #include <pydebug.h>
56 #include <vector>
56 #include <vector>
57
57
58 PythonQt* PythonQt::_self = NULL;
58 PythonQt* PythonQt::_self = NULL;
59 int PythonQt::_uniqueModuleCount = 0;
59 int PythonQt::_uniqueModuleCount = 0;
60
60
61 void PythonQt_init_QtGuiBuiltin(PyObject*);
61 void PythonQt_init_QtGuiBuiltin(PyObject*);
62 void PythonQt_init_QtCoreBuiltin(PyObject*);
62 void PythonQt_init_QtCoreBuiltin(PyObject*);
63
63
64
64
65 PyObject* PythonQtConvertFromStringRef(const void* inObject, int /*metaTypeId*/)
65 PyObject* PythonQtConvertFromStringRef(const void* inObject, int /*metaTypeId*/)
66 {
66 {
67 return PythonQtConv::QStringToPyObject(((QStringRef*)inObject)->toString());
67 return PythonQtConv::QStringToPyObject(((QStringRef*)inObject)->toString());
68 }
68 }
69
69
70 void PythonQt::init(int flags, const QByteArray& pythonQtModuleName)
70 void PythonQt::init(int flags, const QByteArray& pythonQtModuleName)
71 {
71 {
72 if (!_self) {
72 if (!_self) {
73 _self = new PythonQt(flags, pythonQtModuleName);
73 _self = new PythonQt(flags, pythonQtModuleName);
74
74
75 PythonQt::priv()->setupSharedLibrarySuffixes();
75 PythonQt::priv()->setupSharedLibrarySuffixes();
76
76
77 PythonQtMethodInfo::addParameterTypeAlias("QObjectList", "QList<QObject*>");
77 PythonQtMethodInfo::addParameterTypeAlias("QObjectList", "QList<QObject*>");
78 qRegisterMetaType<QList<QObject*> >("QList<void*>");
78 qRegisterMetaType<QList<QObject*> >("QList<void*>");
79
79
80 int stringRefId = qRegisterMetaType<QStringRef>("QStringRef");
80 int stringRefId = qRegisterMetaType<QStringRef>("QStringRef");
81 PythonQtConv::registerMetaTypeToPythonConverter(stringRefId, PythonQtConvertFromStringRef);
81 PythonQtConv::registerMetaTypeToPythonConverter(stringRefId, PythonQtConvertFromStringRef);
82
82
83 PythonQtRegisterToolClassesTemplateConverter(int);
83 PythonQtRegisterToolClassesTemplateConverter(int);
84 PythonQtRegisterToolClassesTemplateConverter(float);
84 PythonQtRegisterToolClassesTemplateConverter(float);
85 PythonQtRegisterToolClassesTemplateConverter(double);
85 PythonQtRegisterToolClassesTemplateConverter(double);
86 PythonQtRegisterToolClassesTemplateConverter(qint32);
86 PythonQtRegisterToolClassesTemplateConverter(qint32);
87 PythonQtRegisterToolClassesTemplateConverter(quint32);
87 PythonQtRegisterToolClassesTemplateConverter(quint32);
88 PythonQtRegisterToolClassesTemplateConverter(qint64);
88 PythonQtRegisterToolClassesTemplateConverter(qint64);
89 PythonQtRegisterToolClassesTemplateConverter(quint64);
89 PythonQtRegisterToolClassesTemplateConverter(quint64);
90 // TODO: which other POD types should be available for QList etc.
90 // TODO: which other POD types should be available for QList etc.
91
91
92 PythonQt_init_QtCoreBuiltin(NULL);
92 PythonQt_init_QtCoreBuiltin(NULL);
93 PythonQt_init_QtGuiBuiltin(NULL);
93 PythonQt_init_QtGuiBuiltin(NULL);
94
94
95 PythonQt::self()->addDecorators(new PythonQtStdDecorators());
95 PythonQt::self()->addDecorators(new PythonQtStdDecorators());
96 PythonQt::self()->registerCPPClass("QMetaObject",0, "QtCore", PythonQtCreateObject<PythonQtWrapper_QMetaObject>);
96 PythonQt::self()->registerCPPClass("QMetaObject",0, "QtCore", PythonQtCreateObject<PythonQtWrapper_QMetaObject>);
97
97
98 PythonQtRegisterToolClassesTemplateConverter(QByteArray);
98 PythonQtRegisterToolClassesTemplateConverter(QByteArray);
99 PythonQtRegisterToolClassesTemplateConverter(QDate);
99 PythonQtRegisterToolClassesTemplateConverter(QDate);
100 PythonQtRegisterToolClassesTemplateConverter(QTime);
100 PythonQtRegisterToolClassesTemplateConverter(QTime);
101 PythonQtRegisterToolClassesTemplateConverter(QDateTime);
101 PythonQtRegisterToolClassesTemplateConverter(QDateTime);
102 PythonQtRegisterToolClassesTemplateConverter(QUrl);
102 PythonQtRegisterToolClassesTemplateConverter(QUrl);
103 PythonQtRegisterToolClassesTemplateConverter(QLocale);
103 PythonQtRegisterToolClassesTemplateConverter(QLocale);
104 PythonQtRegisterToolClassesTemplateConverter(QRect);
104 PythonQtRegisterToolClassesTemplateConverter(QRect);
105 PythonQtRegisterToolClassesTemplateConverter(QRectF);
105 PythonQtRegisterToolClassesTemplateConverter(QRectF);
106 PythonQtRegisterToolClassesTemplateConverter(QSize);
106 PythonQtRegisterToolClassesTemplateConverter(QSize);
107 PythonQtRegisterToolClassesTemplateConverter(QSizeF);
107 PythonQtRegisterToolClassesTemplateConverter(QSizeF);
108 PythonQtRegisterToolClassesTemplateConverter(QLine);
108 PythonQtRegisterToolClassesTemplateConverter(QLine);
109 PythonQtRegisterToolClassesTemplateConverter(QLineF);
109 PythonQtRegisterToolClassesTemplateConverter(QLineF);
110 PythonQtRegisterToolClassesTemplateConverter(QPoint);
110 PythonQtRegisterToolClassesTemplateConverter(QPoint);
111 PythonQtRegisterToolClassesTemplateConverter(QPointF);
111 PythonQtRegisterToolClassesTemplateConverter(QPointF);
112 PythonQtRegisterToolClassesTemplateConverter(QRegExp);
112 PythonQtRegisterToolClassesTemplateConverter(QRegExp);
113
113
114 PythonQtRegisterToolClassesTemplateConverter(QFont);
114 PythonQtRegisterToolClassesTemplateConverter(QFont);
115 PythonQtRegisterToolClassesTemplateConverter(QPixmap);
115 PythonQtRegisterToolClassesTemplateConverter(QPixmap);
116 PythonQtRegisterToolClassesTemplateConverter(QBrush);
116 PythonQtRegisterToolClassesTemplateConverter(QBrush);
117 PythonQtRegisterToolClassesTemplateConverter(QColor);
117 PythonQtRegisterToolClassesTemplateConverter(QColor);
118 PythonQtRegisterToolClassesTemplateConverter(QPalette);
118 PythonQtRegisterToolClassesTemplateConverter(QPalette);
119 PythonQtRegisterToolClassesTemplateConverter(QIcon);
119 PythonQtRegisterToolClassesTemplateConverter(QIcon);
120 PythonQtRegisterToolClassesTemplateConverter(QImage);
120 PythonQtRegisterToolClassesTemplateConverter(QImage);
121 PythonQtRegisterToolClassesTemplateConverter(QPolygon);
121 PythonQtRegisterToolClassesTemplateConverter(QPolygon);
122 PythonQtRegisterToolClassesTemplateConverter(QRegion);
122 PythonQtRegisterToolClassesTemplateConverter(QRegion);
123 PythonQtRegisterToolClassesTemplateConverter(QBitmap);
123 PythonQtRegisterToolClassesTemplateConverter(QBitmap);
124 PythonQtRegisterToolClassesTemplateConverter(QCursor);
124 PythonQtRegisterToolClassesTemplateConverter(QCursor);
125 PythonQtRegisterToolClassesTemplateConverter(QSizePolicy);
125 PythonQtRegisterToolClassesTemplateConverter(QSizePolicy);
126 PythonQtRegisterToolClassesTemplateConverter(QKeySequence);
126 PythonQtRegisterToolClassesTemplateConverter(QKeySequence);
127 PythonQtRegisterToolClassesTemplateConverter(QPen);
127 PythonQtRegisterToolClassesTemplateConverter(QPen);
128 PythonQtRegisterToolClassesTemplateConverter(QTextLength);
128 PythonQtRegisterToolClassesTemplateConverter(QTextLength);
129 PythonQtRegisterToolClassesTemplateConverter(QTextFormat);
129 PythonQtRegisterToolClassesTemplateConverter(QTextFormat);
130 PythonQtRegisterToolClassesTemplateConverter(QMatrix);
130 PythonQtRegisterToolClassesTemplateConverter(QMatrix);
131
131
132
132
133 PyObject* pack = PythonQt::priv()->packageByName("QtCore");
133 PyObject* pack = PythonQt::priv()->packageByName("QtCore");
134 PyObject* pack2 = PythonQt::priv()->packageByName("Qt");
134 PyObject* pack2 = PythonQt::priv()->packageByName("Qt");
135 PyObject* qtNamespace = PythonQt::priv()->getClassInfo("Qt")->pythonQtClassWrapper();
135 PyObject* qtNamespace = PythonQt::priv()->getClassInfo("Qt")->pythonQtClassWrapper();
136 const char* names[16] = {"SIGNAL", "SLOT", "qAbs", "qBound","qDebug","qWarning","qCritical","qFatal"
136 const char* names[16] = {"SIGNAL", "SLOT", "qAbs", "qBound","qDebug","qWarning","qCritical","qFatal"
137 ,"qFuzzyCompare", "qMax","qMin","qRound","qRound64","qVersion","qrand","qsrand"};
137 ,"qFuzzyCompare", "qMax","qMin","qRound","qRound64","qVersion","qrand","qsrand"};
138 for (unsigned int i = 0;i<16; i++) {
138 for (unsigned int i = 0;i<16; i++) {
139 PyObject* obj = PyObject_GetAttrString(qtNamespace, names[i]);
139 PyObject* obj = PyObject_GetAttrString(qtNamespace, names[i]);
140 if (obj) {
140 if (obj) {
141 PyModule_AddObject(pack, names[i], obj);
141 PyModule_AddObject(pack, names[i], obj);
142 Py_INCREF(obj);
142 Py_INCREF(obj);
143 PyModule_AddObject(pack2, names[i], obj);
143 PyModule_AddObject(pack2, names[i], obj);
144 } else {
144 } else {
145 std::cerr << "method not found " << names[i];
145 std::cerr << "method not found " << names[i];
146 }
146 }
147 }
147 }
148 }
148 }
149 }
149 }
150
150
151 void PythonQt::cleanup()
151 void PythonQt::cleanup()
152 {
152 {
153 if (_self) {
153 if (_self) {
154 delete _self;
154 delete _self;
155 _self = NULL;
155 _self = NULL;
156 }
156 }
157 }
157 }
158
158
159 PythonQt* PythonQt::self() { return _self; }
159 PythonQt* PythonQt::self() { return _self; }
160
160
161 PythonQt::PythonQt(int flags, const QByteArray& pythonQtModuleName)
161 PythonQt::PythonQt(int flags, const QByteArray& pythonQtModuleName)
162 {
162 {
163 _p = new PythonQtPrivate;
163 _p = new PythonQtPrivate;
164 _p->_initFlags = flags;
164 _p->_initFlags = flags;
165
165
166 _p->_PythonQtObjectPtr_metaId = qRegisterMetaType<PythonQtObjectPtr>("PythonQtObjectPtr");
166 _p->_PythonQtObjectPtr_metaId = qRegisterMetaType<PythonQtObjectPtr>("PythonQtObjectPtr");
167
167
168 if ((flags & PythonAlreadyInitialized) == 0) {
168 if ((flags & PythonAlreadyInitialized) == 0) {
169 #ifdef PY3K
170 Py_SetProgramName(const_cast<wchar_t*>(L"PythonQt"));
171 #else
169 Py_SetProgramName(const_cast<char*>("PythonQt"));
172 Py_SetProgramName(const_cast<char*>("PythonQt"));
173 #endif
170 if (flags & IgnoreSiteModule) {
174 if (flags & IgnoreSiteModule) {
171 // this prevents the automatic importing of Python site files
175 // this prevents the automatic importing of Python site files
172 Py_NoSiteFlag = 1;
176 Py_NoSiteFlag = 1;
173 }
177 }
174 Py_Initialize();
178 Py_Initialize();
175 }
179 }
176
180
177 // add our own python object types for qt object slots
181 // add our own python object types for qt object slots
178 if (PyType_Ready(&PythonQtSlotFunction_Type) < 0) {
182 if (PyType_Ready(&PythonQtSlotFunction_Type) < 0) {
179 std::cerr << "could not initialize PythonQtSlotFunction_Type" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
183 std::cerr << "could not initialize PythonQtSlotFunction_Type" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
180 }
184 }
181 Py_INCREF(&PythonQtSlotFunction_Type);
185 Py_INCREF(&PythonQtSlotFunction_Type);
182
186
183 if (PyType_Ready(&PythonQtSignalFunction_Type) < 0) {
187 if (PyType_Ready(&PythonQtSignalFunction_Type) < 0) {
184 std::cerr << "could not initialize PythonQtSignalFunction_Type" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
188 std::cerr << "could not initialize PythonQtSignalFunction_Type" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
185 }
189 }
186 Py_INCREF(&PythonQtSignalFunction_Type);
190 Py_INCREF(&PythonQtSignalFunction_Type);
187
191
188 // according to Python docs, set the type late here, since it can not safely be stored in the struct when declaring it
192 // according to Python docs, set the type late here, since it can not safely be stored in the struct when declaring it
189 PythonQtClassWrapper_Type.tp_base = &PyType_Type;
193 PythonQtClassWrapper_Type.tp_base = &PyType_Type;
190 // add our own python object types for classes
194 // add our own python object types for classes
191 if (PyType_Ready(&PythonQtClassWrapper_Type) < 0) {
195 if (PyType_Ready(&PythonQtClassWrapper_Type) < 0) {
192 std::cerr << "could not initialize PythonQtClassWrapper_Type" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
196 std::cerr << "could not initialize PythonQtClassWrapper_Type" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
193 }
197 }
194 Py_INCREF(&PythonQtClassWrapper_Type);
198 Py_INCREF(&PythonQtClassWrapper_Type);
195
199
196 // add our own python object types for CPP instances
200 // add our own python object types for CPP instances
197 if (PyType_Ready(&PythonQtInstanceWrapper_Type) < 0) {
201 if (PyType_Ready(&PythonQtInstanceWrapper_Type) < 0) {
198 PythonQt::handleError();
202 PythonQt::handleError();
199 std::cerr << "could not initialize PythonQtInstanceWrapper_Type" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
203 std::cerr << "could not initialize PythonQtInstanceWrapper_Type" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
200 }
204 }
201 Py_INCREF(&PythonQtInstanceWrapper_Type);
205 Py_INCREF(&PythonQtInstanceWrapper_Type);
202
206
203 // add our own python object types for redirection of stdout
207 // add our own python object types for redirection of stdout
204 if (PyType_Ready(&PythonQtStdOutRedirectType) < 0) {
208 if (PyType_Ready(&PythonQtStdOutRedirectType) < 0) {
205 std::cerr << "could not initialize PythonQtStdOutRedirectType" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
209 std::cerr << "could not initialize PythonQtStdOutRedirectType" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
206 }
210 }
207 Py_INCREF(&PythonQtStdOutRedirectType);
211 Py_INCREF(&PythonQtStdOutRedirectType);
208
212
209 // add our own python object types for redirection of stdin
213 // add our own python object types for redirection of stdin
210 if (PyType_Ready(&PythonQtStdInRedirectType) < 0) {
214 if (PyType_Ready(&PythonQtStdInRedirectType) < 0) {
211 std::cerr << "could not initialize PythonQtStdInRedirectType" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
215 std::cerr << "could not initialize PythonQtStdInRedirectType" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
212 }
216 }
213 Py_INCREF(&PythonQtStdInRedirectType);
217 Py_INCREF(&PythonQtStdInRedirectType);
214
218
215 initPythonQtModule(flags & RedirectStdOut, pythonQtModuleName);
219 initPythonQtModule(flags & RedirectStdOut, pythonQtModuleName);
216
220
217 }
221 }
218
222
219 PythonQt::~PythonQt() {
223 PythonQt::~PythonQt() {
220 delete _p;
224 delete _p;
221 _p = NULL;
225 _p = NULL;
222 }
226 }
223
227
224 PythonQtPrivate::~PythonQtPrivate() {
228 PythonQtPrivate::~PythonQtPrivate() {
225 delete _defaultImporter;
229 delete _defaultImporter;
226 _defaultImporter = NULL;
230 _defaultImporter = NULL;
227
231
228 {
232 {
229 QHashIterator<QByteArray, PythonQtClassInfo *> i(_knownClassInfos);
233 QHashIterator<QByteArray, PythonQtClassInfo *> i(_knownClassInfos);
230 while (i.hasNext()) {
234 while (i.hasNext()) {
231 delete i.next().value();
235 delete i.next().value();
232 }
236 }
233 }
237 }
234 PythonQtConv::global_valueStorage.clear();
238 PythonQtConv::global_valueStorage.clear();
235 PythonQtConv::global_ptrStorage.clear();
239 PythonQtConv::global_ptrStorage.clear();
236 PythonQtConv::global_variantStorage.clear();
240 PythonQtConv::global_variantStorage.clear();
237
241
238 PythonQtMethodInfo::cleanupCachedMethodInfos();
242 PythonQtMethodInfo::cleanupCachedMethodInfos();
239 }
243 }
240
244
241 void PythonQt::setRedirectStdInCallback(PythonQtInputChangedCB* callback, void * callbackData)
245 void PythonQt::setRedirectStdInCallback(PythonQtInputChangedCB* callback, void * callbackData)
242 {
246 {
243 if (!callback)
247 if (!callback)
244 {
248 {
245 std::cerr << "PythonQt::setRedirectStdInCallback - callback parameter is NULL !" << std::endl;
249 std::cerr << "PythonQt::setRedirectStdInCallback - callback parameter is NULL !" << std::endl;
246 return;
250 return;
247 }
251 }
248
252
249 PythonQtObjectPtr sys;
253 PythonQtObjectPtr sys;
250 PythonQtObjectPtr in;
254 PythonQtObjectPtr in;
251 sys.setNewRef(PyImport_ImportModule("sys"));
255 sys.setNewRef(PyImport_ImportModule("sys"));
252
256
253 // Backup original 'sys.stdin' if not yet done
257 // Backup original 'sys.stdin' if not yet done
254 if( !PyObject_HasAttrString(sys.object(), "pythonqt_original_stdin") )
258 if( !PyObject_HasAttrString(sys.object(), "pythonqt_original_stdin") )
255 PyObject_SetAttrString(sys.object(), "pythonqt_original_stdin", PyObject_GetAttrString(sys.object(), "stdin"));
259 PyObject_SetAttrString(sys.object(), "pythonqt_original_stdin", PyObject_GetAttrString(sys.object(), "stdin"));
256
260
257 in = PythonQtStdInRedirectType.tp_new(&PythonQtStdInRedirectType, NULL, NULL);
261 in = PythonQtStdInRedirectType.tp_new(&PythonQtStdInRedirectType, NULL, NULL);
258 ((PythonQtStdInRedirect*)in.object())->_cb = callback;
262 ((PythonQtStdInRedirect*)in.object())->_cb = callback;
259 ((PythonQtStdInRedirect*)in.object())->_callData = callbackData;
263 ((PythonQtStdInRedirect*)in.object())->_callData = callbackData;
260 // replace the built in file objects with our own objects
264 // replace the built in file objects with our own objects
261 PyModule_AddObject(sys.object(), "stdin", in);
265 PyModule_AddObject(sys.object(), "stdin", in);
262
266
263 // Backup custom 'stdin' into 'pythonqt_stdin'
267 // Backup custom 'stdin' into 'pythonqt_stdin'
264 Py_IncRef(in);
268 Py_IncRef(in);
265 PyModule_AddObject(sys.object(), "pythonqt_stdin", in);
269 PyModule_AddObject(sys.object(), "pythonqt_stdin", in);
266 }
270 }
267
271
268 void PythonQt::setRedirectStdInCallbackEnabled(bool enabled)
272 void PythonQt::setRedirectStdInCallbackEnabled(bool enabled)
269 {
273 {
270 PythonQtObjectPtr sys;
274 PythonQtObjectPtr sys;
271 sys.setNewRef(PyImport_ImportModule("sys"));
275 sys.setNewRef(PyImport_ImportModule("sys"));
272
276
273 if (enabled)
277 if (enabled)
274 {
278 {
275 if( !PyObject_HasAttrString(sys.object(), "pythonqt_stdin") )
279 if( !PyObject_HasAttrString(sys.object(), "pythonqt_stdin") )
276 PyObject_SetAttrString(sys.object(), "stdin", PyObject_GetAttrString(sys.object(), "pythonqt_stdin"));
280 PyObject_SetAttrString(sys.object(), "stdin", PyObject_GetAttrString(sys.object(), "pythonqt_stdin"));
277 }
281 }
278 else
282 else
279 {
283 {
280 if( !PyObject_HasAttrString(sys.object(), "pythonqt_original_stdin") )
284 if( !PyObject_HasAttrString(sys.object(), "pythonqt_original_stdin") )
281 PyObject_SetAttrString(sys.object(), "stdin", PyObject_GetAttrString(sys.object(), "pythonqt_original_stdin"));
285 PyObject_SetAttrString(sys.object(), "stdin", PyObject_GetAttrString(sys.object(), "pythonqt_original_stdin"));
282 }
286 }
283 }
287 }
284
288
285 PythonQtImportFileInterface* PythonQt::importInterface()
289 PythonQtImportFileInterface* PythonQt::importInterface()
286 {
290 {
287 return _self->_p->_importInterface?_self->_p->_importInterface:_self->_p->_defaultImporter;
291 return _self->_p->_importInterface?_self->_p->_importInterface:_self->_p->_defaultImporter;
288 }
292 }
289
293
290 void PythonQt::qObjectNoLongerWrappedCB(QObject* o)
294 void PythonQt::qObjectNoLongerWrappedCB(QObject* o)
291 {
295 {
292 if (_self->_p->_noLongerWrappedCB) {
296 if (_self->_p->_noLongerWrappedCB) {
293 (*_self->_p->_noLongerWrappedCB)(o);
297 (*_self->_p->_noLongerWrappedCB)(o);
294 };
298 };
295 }
299 }
296
300
297 void PythonQt::registerClass(const QMetaObject* metaobject, const char* package, PythonQtQObjectCreatorFunctionCB* wrapperCreator, PythonQtShellSetInstanceWrapperCB* shell)
301 void PythonQt::registerClass(const QMetaObject* metaobject, const char* package, PythonQtQObjectCreatorFunctionCB* wrapperCreator, PythonQtShellSetInstanceWrapperCB* shell)
298 {
302 {
299 _p->registerClass(metaobject, package, wrapperCreator, shell);
303 _p->registerClass(metaobject, package, wrapperCreator, shell);
300 }
304 }
301
305
302 void PythonQtPrivate::registerClass(const QMetaObject* metaobject, const char* package, PythonQtQObjectCreatorFunctionCB* wrapperCreator, PythonQtShellSetInstanceWrapperCB* shell, PyObject* module, int typeSlots)
306 void PythonQtPrivate::registerClass(const QMetaObject* metaobject, const char* package, PythonQtQObjectCreatorFunctionCB* wrapperCreator, PythonQtShellSetInstanceWrapperCB* shell, PyObject* module, int typeSlots)
303 {
307 {
304 // we register all classes in the hierarchy
308 // we register all classes in the hierarchy
305 const QMetaObject* m = metaobject;
309 const QMetaObject* m = metaobject;
306 bool first = true;
310 bool first = true;
307 while (m) {
311 while (m) {
308 PythonQtClassInfo* info = lookupClassInfoAndCreateIfNotPresent(m->className());
312 PythonQtClassInfo* info = lookupClassInfoAndCreateIfNotPresent(m->className());
309 if (!info->pythonQtClassWrapper()) {
313 if (!info->pythonQtClassWrapper()) {
310 info->setTypeSlots(typeSlots);
314 info->setTypeSlots(typeSlots);
311 info->setupQObject(m);
315 info->setupQObject(m);
312 createPythonQtClassWrapper(info, package, module);
316 createPythonQtClassWrapper(info, package, module);
313 if (m->superClass()) {
317 if (m->superClass()) {
314 PythonQtClassInfo* parentInfo = lookupClassInfoAndCreateIfNotPresent(m->superClass()->className());
318 PythonQtClassInfo* parentInfo = lookupClassInfoAndCreateIfNotPresent(m->superClass()->className());
315 info->addParentClass(PythonQtClassInfo::ParentClassInfo(parentInfo));
319 info->addParentClass(PythonQtClassInfo::ParentClassInfo(parentInfo));
316 }
320 }
317 } else if (first && module) {
321 } else if (first && module) {
318 // There is a wrapper already, but if we got a module, we want to place the wrapper into that module as well,
322 // There is a wrapper already, but if we got a module, we want to place the wrapper into that module as well,
319 // since it might have been placed into "private" earlier on.
323 // since it might have been placed into "private" earlier on.
320 // If the wrapper was already added to module before, it is just readded, which does no harm.
324 // If the wrapper was already added to module before, it is just readded, which does no harm.
321 PyObject* classWrapper = info->pythonQtClassWrapper();
325 PyObject* classWrapper = info->pythonQtClassWrapper();
322 // AddObject steals a reference, so we need to INCREF
326 // AddObject steals a reference, so we need to INCREF
323 Py_INCREF(classWrapper);
327 Py_INCREF(classWrapper);
324 PyModule_AddObject(module, info->className(), classWrapper);
328 PyModule_AddObject(module, info->className(), classWrapper);
325 }
329 }
326 if (first) {
330 if (first) {
327 first = false;
331 first = false;
328 if (wrapperCreator) {
332 if (wrapperCreator) {
329 info->setDecoratorProvider(wrapperCreator);
333 info->setDecoratorProvider(wrapperCreator);
330 }
334 }
331 if (shell) {
335 if (shell) {
332 info->setShellSetInstanceWrapperCB(shell);
336 info->setShellSetInstanceWrapperCB(shell);
333 }
337 }
334 }
338 }
335 m = m->superClass();
339 m = m->superClass();
336 }
340 }
337 }
341 }
338
342
339 void PythonQtPrivate::createPythonQtClassWrapper(PythonQtClassInfo* info, const char* package, PyObject* module)
343 void PythonQtPrivate::createPythonQtClassWrapper(PythonQtClassInfo* info, const char* package, PyObject* module)
340 {
344 {
341 PyObject* pack = module?module:packageByName(package);
345 PyObject* pack = module?module:packageByName(package);
342 PyObject* pyobj = (PyObject*)createNewPythonQtClassWrapper(info, pack);
346 PyObject* pyobj = (PyObject*)createNewPythonQtClassWrapper(info, pack);
343 PyModule_AddObject(pack, info->className(), pyobj);
347 PyModule_AddObject(pack, info->className(), pyobj);
344 if (!module && package && strncmp(package,"Qt",2)==0) {
348 if (!module && package && strncmp(package,"Qt",2)==0) {
345 // since PyModule_AddObject steals the reference, we need a incref once more...
349 // since PyModule_AddObject steals the reference, we need a incref once more...
346 Py_INCREF(pyobj);
350 Py_INCREF(pyobj);
347 // put all qt objects into Qt as well
351 // put all qt objects into Qt as well
348 PyModule_AddObject(packageByName("Qt"), info->className(), pyobj);
352 PyModule_AddObject(packageByName("Qt"), info->className(), pyobj);
349 }
353 }
350 info->setPythonQtClassWrapper(pyobj);
354 info->setPythonQtClassWrapper(pyobj);
351 }
355 }
352
356
353 PyObject* PythonQtPrivate::wrapQObject(QObject* obj)
357 PyObject* PythonQtPrivate::wrapQObject(QObject* obj)
354 {
358 {
355 if (!obj) {
359 if (!obj) {
356 Py_INCREF(Py_None);
360 Py_INCREF(Py_None);
357 return Py_None;
361 return Py_None;
358 }
362 }
359 PythonQtInstanceWrapper* wrap = findWrapperAndRemoveUnused(obj);
363 PythonQtInstanceWrapper* wrap = findWrapperAndRemoveUnused(obj);
360 if (wrap && wrap->_wrappedPtr) {
364 if (wrap && wrap->_wrappedPtr) {
361 // uh oh, we want to wrap a QObject, but have a C++ wrapper at that
365 // uh oh, we want to wrap a QObject, but have a C++ wrapper at that
362 // address, so probably that C++ wrapper has been deleted earlier and
366 // address, so probably that C++ wrapper has been deleted earlier and
363 // now we see a QObject with the same address.
367 // now we see a QObject with the same address.
364 // Do not use the old wrapper anymore.
368 // Do not use the old wrapper anymore.
365 wrap = NULL;
369 wrap = NULL;
366 }
370 }
367 if (!wrap) {
371 if (!wrap) {
368 // smuggling it in...
372 // smuggling it in...
369 PythonQtClassInfo* classInfo = _knownClassInfos.value(obj->metaObject()->className());
373 PythonQtClassInfo* classInfo = _knownClassInfos.value(obj->metaObject()->className());
370 if (!classInfo || classInfo->pythonQtClassWrapper()==NULL) {
374 if (!classInfo || classInfo->pythonQtClassWrapper()==NULL) {
371 registerClass(obj->metaObject());
375 registerClass(obj->metaObject());
372 classInfo = _knownClassInfos.value(obj->metaObject()->className());
376 classInfo = _knownClassInfos.value(obj->metaObject()->className());
373 }
377 }
374 wrap = createNewPythonQtInstanceWrapper(obj, classInfo);
378 wrap = createNewPythonQtInstanceWrapper(obj, classInfo);
375 // mlabDebugConst("MLABPython","new qobject wrapper added " << " " << wrap->_obj->className() << " " << wrap->classInfo()->wrappedClassName().latin1());
379 // mlabDebugConst("MLABPython","new qobject wrapper added " << " " << wrap->_obj->className() << " " << wrap->classInfo()->wrappedClassName().latin1());
376 } else {
380 } else {
377 Py_INCREF(wrap);
381 Py_INCREF(wrap);
378 // mlabDebugConst("MLABPython","qobject wrapper reused " << wrap->_obj->className() << " " << wrap->classInfo()->wrappedClassName().latin1());
382 // mlabDebugConst("MLABPython","qobject wrapper reused " << wrap->_obj->className() << " " << wrap->classInfo()->wrappedClassName().latin1());
379 }
383 }
380 return (PyObject*)wrap;
384 return (PyObject*)wrap;
381 }
385 }
382
386
383 PyObject* PythonQtPrivate::wrapPtr(void* ptr, const QByteArray& name)
387 PyObject* PythonQtPrivate::wrapPtr(void* ptr, const QByteArray& name)
384 {
388 {
385 if (!ptr) {
389 if (!ptr) {
386 Py_INCREF(Py_None);
390 Py_INCREF(Py_None);
387 return Py_None;
391 return Py_None;
388 }
392 }
389
393
390 PythonQtInstanceWrapper* wrap = findWrapperAndRemoveUnused(ptr);
394 PythonQtInstanceWrapper* wrap = findWrapperAndRemoveUnused(ptr);
391 PythonQtInstanceWrapper* possibleStillAliveWrapper = NULL;
395 PythonQtInstanceWrapper* possibleStillAliveWrapper = NULL;
392 if (wrap && wrap->_wrappedPtr) {
396 if (wrap && wrap->_wrappedPtr) {
393 // we have a previous C++ wrapper... if the wrapper is for a C++ object,
397 // we have a previous C++ wrapper... if the wrapper is for a C++ object,
394 // we are not sure if it may have been deleted earlier and we just see the same C++
398 // we are not sure if it may have been deleted earlier and we just see the same C++
395 // pointer once again. To make sure that we do not reuse a wrapper of the wrong type,
399 // pointer once again. To make sure that we do not reuse a wrapper of the wrong type,
396 // we compare the classInfo() pointer and only reuse the wrapper if it has the same
400 // we compare the classInfo() pointer and only reuse the wrapper if it has the same
397 // info. This is only needed for non-QObjects, since we know it when a QObject gets deleted.
401 // info. This is only needed for non-QObjects, since we know it when a QObject gets deleted.
398 possibleStillAliveWrapper = wrap;
402 possibleStillAliveWrapper = wrap;
399 wrap = NULL;
403 wrap = NULL;
400 }
404 }
401 if (!wrap) {
405 if (!wrap) {
402 PythonQtClassInfo* info = _knownClassInfos.value(name);
406 PythonQtClassInfo* info = _knownClassInfos.value(name);
403 if (!info) {
407 if (!info) {
404 // maybe it is a PyObject, which we can return directly
408 // maybe it is a PyObject, which we can return directly
405 if (name == "PyObject") {
409 if (name == "PyObject") {
406 PyObject* p = (PyObject*)ptr;
410 PyObject* p = (PyObject*)ptr;
407 Py_INCREF(p);
411 Py_INCREF(p);
408 return p;
412 return p;
409 }
413 }
410
414
411 // we do not know the metaobject yet, but we might know it by its name:
415 // we do not know the metaobject yet, but we might know it by its name:
412 if (_knownQObjectClassNames.find(name)!=_knownQObjectClassNames.end()) {
416 if (_knownQObjectClassNames.find(name)!=_knownQObjectClassNames.end()) {
413 // yes, we know it, so we can convert to QObject
417 // yes, we know it, so we can convert to QObject
414 QObject* qptr = (QObject*)ptr;
418 QObject* qptr = (QObject*)ptr;
415 registerClass(qptr->metaObject());
419 registerClass(qptr->metaObject());
416 info = _knownClassInfos.value(qptr->metaObject()->className());
420 info = _knownClassInfos.value(qptr->metaObject()->className());
417 }
421 }
418 }
422 }
419 if (info && info->isQObject()) {
423 if (info && info->isQObject()) {
420 QObject* qptr = (QObject*)ptr;
424 QObject* qptr = (QObject*)ptr;
421 // if the object is a derived object, we want to switch the class info to the one of the derived class:
425 // if the object is a derived object, we want to switch the class info to the one of the derived class:
422 if (name!=(qptr->metaObject()->className())) {
426 if (name!=(qptr->metaObject()->className())) {
423 info = _knownClassInfos.value(qptr->metaObject()->className());
427 info = _knownClassInfos.value(qptr->metaObject()->className());
424 if (!info) {
428 if (!info) {
425 registerClass(qptr->metaObject());
429 registerClass(qptr->metaObject());
426 info = _knownClassInfos.value(qptr->metaObject()->className());
430 info = _knownClassInfos.value(qptr->metaObject()->className());
427 }
431 }
428 }
432 }
429 wrap = createNewPythonQtInstanceWrapper(qptr, info);
433 wrap = createNewPythonQtInstanceWrapper(qptr, info);
430 // mlabDebugConst("MLABPython","new qobject wrapper added " << " " << wrap->_obj->className() << " " << wrap->classInfo()->wrappedClassName().latin1());
434 // mlabDebugConst("MLABPython","new qobject wrapper added " << " " << wrap->_obj->className() << " " << wrap->classInfo()->wrappedClassName().latin1());
431 return (PyObject*)wrap;
435 return (PyObject*)wrap;
432 }
436 }
433
437
434 // not a known QObject, try to wrap via foreign wrapper factories
438 // not a known QObject, try to wrap via foreign wrapper factories
435 PyObject* foreignWrapper = NULL;
439 PyObject* foreignWrapper = NULL;
436 for (int i=0; i<_foreignWrapperFactories.size(); i++) {
440 for (int i=0; i<_foreignWrapperFactories.size(); i++) {
437 foreignWrapper = _foreignWrapperFactories.at(i)->wrap(name, ptr);
441 foreignWrapper = _foreignWrapperFactories.at(i)->wrap(name, ptr);
438 if (foreignWrapper) {
442 if (foreignWrapper) {
439 return foreignWrapper;
443 return foreignWrapper;
440 }
444 }
441 }
445 }
442
446
443 // not a known QObject, so try our wrapper factory:
447 // not a known QObject, so try our wrapper factory:
444 QObject* wrapper = NULL;
448 QObject* wrapper = NULL;
445 for (int i=0; i<_cppWrapperFactories.size(); i++) {
449 for (int i=0; i<_cppWrapperFactories.size(); i++) {
446 wrapper = _cppWrapperFactories.at(i)->create(name, ptr);
450 wrapper = _cppWrapperFactories.at(i)->create(name, ptr);
447 if (wrapper) {
451 if (wrapper) {
448 break;
452 break;
449 }
453 }
450 }
454 }
451
455
452 if (info) {
456 if (info) {
453 // try to downcast in the class hierarchy, which will modify info and ptr if it is successfull
457 // try to downcast in the class hierarchy, which will modify info and ptr if it is successfull
454 ptr = info->castDownIfPossible(ptr, &info);
458 ptr = info->castDownIfPossible(ptr, &info);
455
459
456 // if downcasting found out that the object is a QObject,
460 // if downcasting found out that the object is a QObject,
457 // handle it like one:
461 // handle it like one:
458 if (info && info->isQObject()) {
462 if (info && info->isQObject()) {
459 QObject* qptr = (QObject*)ptr;
463 QObject* qptr = (QObject*)ptr;
460 // if the object is a derived object, we want to switch the class info to the one of the derived class:
464 // if the object is a derived object, we want to switch the class info to the one of the derived class:
461 if (name!=(qptr->metaObject()->className())) {
465 if (name!=(qptr->metaObject()->className())) {
462 registerClass(qptr->metaObject());
466 registerClass(qptr->metaObject());
463 info = _knownClassInfos.value(qptr->metaObject()->className());
467 info = _knownClassInfos.value(qptr->metaObject()->className());
464 }
468 }
465 wrap = createNewPythonQtInstanceWrapper(qptr, info);
469 wrap = createNewPythonQtInstanceWrapper(qptr, info);
466 // mlabDebugConst("MLABPython","new qobject wrapper added " << " " << wrap->_obj->className() << " " << wrap->classInfo()->wrappedClassName().latin1());
470 // mlabDebugConst("MLABPython","new qobject wrapper added " << " " << wrap->_obj->className() << " " << wrap->classInfo()->wrappedClassName().latin1());
467 return (PyObject*)wrap;
471 return (PyObject*)wrap;
468 }
472 }
469 }
473 }
470
474
471 if (!info || info->pythonQtClassWrapper()==NULL) {
475 if (!info || info->pythonQtClassWrapper()==NULL) {
472 // still unknown, register as CPP class
476 // still unknown, register as CPP class
473 registerCPPClass(name.constData());
477 registerCPPClass(name.constData());
474 info = _knownClassInfos.value(name);
478 info = _knownClassInfos.value(name);
475 }
479 }
476 if (wrapper && (info->metaObject() != wrapper->metaObject())) {
480 if (wrapper && (info->metaObject() != wrapper->metaObject())) {
477 // if we a have a QObject wrapper and the metaobjects do not match, set the metaobject again!
481 // if we a have a QObject wrapper and the metaobjects do not match, set the metaobject again!
478 info->setMetaObject(wrapper->metaObject());
482 info->setMetaObject(wrapper->metaObject());
479 }
483 }
480
484
481 if (possibleStillAliveWrapper && possibleStillAliveWrapper->classInfo() == info) {
485 if (possibleStillAliveWrapper && possibleStillAliveWrapper->classInfo() == info) {
482 wrap = possibleStillAliveWrapper;
486 wrap = possibleStillAliveWrapper;
483 Py_INCREF(wrap);
487 Py_INCREF(wrap);
484 } else {
488 } else {
485 wrap = createNewPythonQtInstanceWrapper(wrapper, info, ptr);
489 wrap = createNewPythonQtInstanceWrapper(wrapper, info, ptr);
486 }
490 }
487 // mlabDebugConst("MLABPython","new c++ wrapper added " << wrap->_wrappedPtr << " " << wrap->_obj->className() << " " << wrap->classInfo()->wrappedClassName().latin1());
491 // mlabDebugConst("MLABPython","new c++ wrapper added " << wrap->_wrappedPtr << " " << wrap->_obj->className() << " " << wrap->classInfo()->wrappedClassName().latin1());
488 } else {
492 } else {
489 Py_INCREF(wrap);
493 Py_INCREF(wrap);
490 //mlabDebugConst("MLABPython","c++ wrapper reused " << wrap->_wrappedPtr << " " << wrap->_obj->className() << " " << wrap->classInfo()->wrappedClassName().latin1());
494 //mlabDebugConst("MLABPython","c++ wrapper reused " << wrap->_wrappedPtr << " " << wrap->_obj->className() << " " << wrap->classInfo()->wrappedClassName().latin1());
491 }
495 }
492 return (PyObject*)wrap;
496 return (PyObject*)wrap;
493 }
497 }
494
498
495 PyObject* PythonQtPrivate::dummyTuple() {
499 PyObject* PythonQtPrivate::dummyTuple() {
496 static PyObject* dummyTuple = NULL;
500 static PyObject* dummyTuple = NULL;
497 if (dummyTuple==NULL) {
501 if (dummyTuple==NULL) {
498 dummyTuple = PyTuple_New(1);
502 dummyTuple = PyTuple_New(1);
503 #ifdef PY3K
504 PyTuple_SET_ITEM(dummyTuple, 0, PyUnicode_FromString("dummy"));
505 #else
499 PyTuple_SET_ITEM(dummyTuple, 0 , PyString_FromString("dummy"));
506 PyTuple_SET_ITEM(dummyTuple, 0 , PyString_FromString("dummy"));
507 #endif
500 }
508 }
501 return dummyTuple;
509 return dummyTuple;
502 }
510 }
503
511
504
512
505 PythonQtInstanceWrapper* PythonQtPrivate::createNewPythonQtInstanceWrapper(QObject* obj, PythonQtClassInfo* info, void* wrappedPtr) {
513 PythonQtInstanceWrapper* PythonQtPrivate::createNewPythonQtInstanceWrapper(QObject* obj, PythonQtClassInfo* info, void* wrappedPtr) {
506 // call the associated class type to create a new instance...
514 // call the associated class type to create a new instance...
507 PythonQtInstanceWrapper* result = (PythonQtInstanceWrapper*)PyObject_Call(info->pythonQtClassWrapper(), dummyTuple(), NULL);
515 PythonQtInstanceWrapper* result = (PythonQtInstanceWrapper*)PyObject_Call(info->pythonQtClassWrapper(), dummyTuple(), NULL);
508
516
509 result->setQObject(obj);
517 result->setQObject(obj);
510 result->_wrappedPtr = wrappedPtr;
518 result->_wrappedPtr = wrappedPtr;
511 result->_ownedByPythonQt = false;
519 result->_ownedByPythonQt = false;
512 result->_useQMetaTypeDestroy = false;
520 result->_useQMetaTypeDestroy = false;
513
521
514 if (wrappedPtr) {
522 if (wrappedPtr) {
515 _wrappedObjects.insert(wrappedPtr, result);
523 _wrappedObjects.insert(wrappedPtr, result);
516 } else {
524 } else {
517 _wrappedObjects.insert(obj, result);
525 _wrappedObjects.insert(obj, result);
518 if (obj->parent()== NULL && _wrappedCB) {
526 if (obj->parent()== NULL && _wrappedCB) {
519 // tell someone who is interested that the qobject is wrapped the first time, if it has no parent
527 // tell someone who is interested that the qobject is wrapped the first time, if it has no parent
520 (*_wrappedCB)(obj);
528 (*_wrappedCB)(obj);
521 }
529 }
522 }
530 }
523 return result;
531 return result;
524 }
532 }
525
533
526 PythonQtClassWrapper* PythonQtPrivate::createNewPythonQtClassWrapper(PythonQtClassInfo* info, PyObject* parentModule) {
534 PythonQtClassWrapper* PythonQtPrivate::createNewPythonQtClassWrapper(PythonQtClassInfo* info, PyObject* parentModule) {
527 PythonQtClassWrapper* result;
535 PythonQtClassWrapper* result;
528
536
537 #ifdef PY3K
538 PyObject* className = PyUnicode_FromString(info->className());
539 #else
529 PyObject* className = PyString_FromString(info->className());
540 PyObject* className = PyString_FromString(info->className());
541 #endif
530
542
531 PyObject* baseClasses = PyTuple_New(1);
543 PyObject* baseClasses = PyTuple_New(1);
532 PyTuple_SET_ITEM(baseClasses, 0, (PyObject*)&PythonQtInstanceWrapper_Type);
544 PyTuple_SET_ITEM(baseClasses, 0, (PyObject*)&PythonQtInstanceWrapper_Type);
533
545
534 PyObject* typeDict = PyDict_New();
546 PyObject* typeDict = PyDict_New();
535 PyObject* moduleName = PyObject_GetAttrString(parentModule, "__name__");
547 PyObject* moduleName = PyObject_GetAttrString(parentModule, "__name__");
536 PyDict_SetItemString(typeDict, "__module__", moduleName);
548 PyDict_SetItemString(typeDict, "__module__", moduleName);
537
549
538 PyObject* args = Py_BuildValue("OOO", className, baseClasses, typeDict);
550 PyObject* args = Py_BuildValue("OOO", className, baseClasses, typeDict);
539
551
540 // set the class info so that PythonQtClassWrapper_new can read it
552 // set the class info so that PythonQtClassWrapper_new can read it
541 _currentClassInfoForClassWrapperCreation = info;
553 _currentClassInfoForClassWrapperCreation = info;
542 // create the new type object by calling the type
554 // create the new type object by calling the type
543 result = (PythonQtClassWrapper *)PyObject_Call((PyObject *)&PythonQtClassWrapper_Type, args, NULL);
555 result = (PythonQtClassWrapper *)PyObject_Call((PyObject *)&PythonQtClassWrapper_Type, args, NULL);
544
556
545 Py_DECREF(baseClasses);
557 Py_DECREF(baseClasses);
546 Py_DECREF(typeDict);
558 Py_DECREF(typeDict);
547 Py_DECREF(args);
559 Py_DECREF(args);
548 Py_DECREF(className);
560 Py_DECREF(className);
549
561
550 return result;
562 return result;
551 }
563 }
552
564
553 PyObject* PythonQtPrivate::createEnumValueInstance(PyObject* enumType, unsigned int enumValue)
565 PyObject* PythonQtPrivate::createEnumValueInstance(PyObject* enumType, unsigned int enumValue)
554 {
566 {
555 PyObject* args = Py_BuildValue("(i)", enumValue);
567 PyObject* args = Py_BuildValue("(i)", enumValue);
556 PyObject* result = PyObject_Call(enumType, args, NULL);
568 PyObject* result = PyObject_Call(enumType, args, NULL);
557 Py_DECREF(args);
569 Py_DECREF(args);
558 return result;
570 return result;
559 }
571 }
560
572
561 PyObject* PythonQtPrivate::createNewPythonQtEnumWrapper(const char* enumName, PyObject* parentObject) {
573 PyObject* PythonQtPrivate::createNewPythonQtEnumWrapper(const char* enumName, PyObject* parentObject) {
562 PyObject* result;
574 PyObject* result;
563
575
576 #ifdef PY3K
577 PyObject* className = PyUnicode_FromString(enumName);
578 #else
564 PyObject* className = PyString_FromString(enumName);
579 PyObject* className = PyString_FromString(enumName);
580 #endif
565
581
566 PyObject* baseClasses = PyTuple_New(1);
582 PyObject* baseClasses = PyTuple_New(1);
583 #ifdef PY3K
584 PyTuple_SET_ITEM(baseClasses, 0, (PyObject*)&PyLong_Type);
585 #else
567 PyTuple_SET_ITEM(baseClasses, 0, (PyObject*)&PyInt_Type);
586 PyTuple_SET_ITEM(baseClasses, 0, (PyObject*)&PyInt_Type);
587 #endif
568
588
569 PyObject* module = PyObject_GetAttrString(parentObject, "__module__");
589 PyObject* module = PyObject_GetAttrString(parentObject, "__module__");
570 PyObject* typeDict = PyDict_New();
590 PyObject* typeDict = PyDict_New();
571 PyDict_SetItemString(typeDict, "__module__", module);
591 PyDict_SetItemString(typeDict, "__module__", module);
572
592
573 PyObject* args = Py_BuildValue("OOO", className, baseClasses, typeDict);
593 PyObject* args = Py_BuildValue("OOO", className, baseClasses, typeDict);
574
594
575 // create the new int derived type object by calling the core type
595 // create the new int derived type object by calling the core type
576 result = PyObject_Call((PyObject *)&PyType_Type, args, NULL);
596 result = PyObject_Call((PyObject *)&PyType_Type, args, NULL);
577
597
578 Py_DECREF(baseClasses);
598 Py_DECREF(baseClasses);
579 Py_DECREF(typeDict);
599 Py_DECREF(typeDict);
580 Py_DECREF(args);
600 Py_DECREF(args);
581 Py_DECREF(className);
601 Py_DECREF(className);
582
602
583 return result;
603 return result;
584 }
604 }
585
605
586 PythonQtSignalReceiver* PythonQt::getSignalReceiver(QObject* obj)
606 PythonQtSignalReceiver* PythonQt::getSignalReceiver(QObject* obj)
587 {
607 {
588 PythonQtSignalReceiver* r = _p->_signalReceivers[obj];
608 PythonQtSignalReceiver* r = _p->_signalReceivers[obj];
589 if (!r) {
609 if (!r) {
590 r = new PythonQtSignalReceiver(obj);
610 r = new PythonQtSignalReceiver(obj);
591 _p->_signalReceivers.insert(obj, r);
611 _p->_signalReceivers.insert(obj, r);
592 }
612 }
593 return r;
613 return r;
594 }
614 }
595
615
596 bool PythonQt::addSignalHandler(QObject* obj, const char* signal, PyObject* module, const QString& objectname)
616 bool PythonQt::addSignalHandler(QObject* obj, const char* signal, PyObject* module, const QString& objectname)
597 {
617 {
598 bool flag = false;
618 bool flag = false;
599 PythonQtObjectPtr callable = lookupCallable(module, objectname);
619 PythonQtObjectPtr callable = lookupCallable(module, objectname);
600 if (callable) {
620 if (callable) {
601 PythonQtSignalReceiver* r = getSignalReceiver(obj);
621 PythonQtSignalReceiver* r = getSignalReceiver(obj);
602 flag = r->addSignalHandler(signal, callable);
622 flag = r->addSignalHandler(signal, callable);
603 if (!flag) {
623 if (!flag) {
604 // signal not found
624 // signal not found
605 }
625 }
606 } else {
626 } else {
607 // callable not found
627 // callable not found
608 }
628 }
609 return flag;
629 return flag;
610 }
630 }
611
631
612 bool PythonQt::addSignalHandler(QObject* obj, const char* signal, PyObject* receiver)
632 bool PythonQt::addSignalHandler(QObject* obj, const char* signal, PyObject* receiver)
613 {
633 {
614 bool flag = false;
634 bool flag = false;
615 PythonQtSignalReceiver* r = getSignalReceiver(obj);
635 PythonQtSignalReceiver* r = getSignalReceiver(obj);
616 if (r) {
636 if (r) {
617 flag = r->addSignalHandler(signal, receiver);
637 flag = r->addSignalHandler(signal, receiver);
618 }
638 }
619 return flag;
639 return flag;
620 }
640 }
621
641
622 bool PythonQt::removeSignalHandler(QObject* obj, const char* signal, PyObject* module, const QString& objectname)
642 bool PythonQt::removeSignalHandler(QObject* obj, const char* signal, PyObject* module, const QString& objectname)
623 {
643 {
624 bool flag = false;
644 bool flag = false;
625 PythonQtObjectPtr callable = lookupCallable(module, objectname);
645 PythonQtObjectPtr callable = lookupCallable(module, objectname);
626 if (callable) {
646 if (callable) {
627 PythonQtSignalReceiver* r = _p->_signalReceivers[obj];
647 PythonQtSignalReceiver* r = _p->_signalReceivers[obj];
628 if (r) {
648 if (r) {
629 flag = r->removeSignalHandler(signal, callable);
649 flag = r->removeSignalHandler(signal, callable);
630 }
650 }
631 } else {
651 } else {
632 // callable not found
652 // callable not found
633 }
653 }
634 return flag;
654 return flag;
635 }
655 }
636
656
637 bool PythonQt::removeSignalHandler(QObject* obj, const char* signal, PyObject* receiver)
657 bool PythonQt::removeSignalHandler(QObject* obj, const char* signal, PyObject* receiver)
638 {
658 {
639 bool flag = false;
659 bool flag = false;
640 PythonQtSignalReceiver* r = _p->_signalReceivers[obj];
660 PythonQtSignalReceiver* r = _p->_signalReceivers[obj];
641 if (r) {
661 if (r) {
642 flag = r->removeSignalHandler(signal, receiver);
662 flag = r->removeSignalHandler(signal, receiver);
643 }
663 }
644 return flag;
664 return flag;
645 }
665 }
646
666
647 PythonQtObjectPtr PythonQt::lookupCallable(PyObject* module, const QString& name)
667 PythonQtObjectPtr PythonQt::lookupCallable(PyObject* module, const QString& name)
648 {
668 {
649 PythonQtObjectPtr p = lookupObject(module, name);
669 PythonQtObjectPtr p = lookupObject(module, name);
650 if (p) {
670 if (p) {
651 if (PyCallable_Check(p)) {
671 if (PyCallable_Check(p)) {
652 return p;
672 return p;
653 }
673 }
654 }
674 }
655 PyErr_Clear();
675 PyErr_Clear();
656 return NULL;
676 return NULL;
657 }
677 }
658
678
659 PythonQtObjectPtr PythonQt::lookupObject(PyObject* module, const QString& name)
679 PythonQtObjectPtr PythonQt::lookupObject(PyObject* module, const QString& name)
660 {
680 {
661 QStringList l = name.split('.');
681 QStringList l = name.split('.');
662 PythonQtObjectPtr p = module;
682 PythonQtObjectPtr p = module;
663 PythonQtObjectPtr prev;
683 PythonQtObjectPtr prev;
664 QByteArray b;
684 QByteArray b;
665 for (QStringList::ConstIterator i = l.begin(); i!=l.end() && p; ++i) {
685 for (QStringList::ConstIterator i = l.begin(); i!=l.end() && p; ++i) {
666 prev = p;
686 prev = p;
667 b = (*i).toLatin1();
687 b = (*i).toLatin1();
668 if (PyDict_Check(p)) {
688 if (PyDict_Check(p)) {
669 p = PyDict_GetItemString(p, b.data());
689 p = PyDict_GetItemString(p, b.data());
670 } else {
690 } else {
671 p.setNewRef(PyObject_GetAttrString(p, b.data()));
691 p.setNewRef(PyObject_GetAttrString(p, b.data()));
672 }
692 }
673 }
693 }
674 PyErr_Clear();
694 PyErr_Clear();
675 return p;
695 return p;
676 }
696 }
677
697
678 PythonQtObjectPtr PythonQt::getMainModule() {
698 PythonQtObjectPtr PythonQt::getMainModule() {
679 //both borrowed
699 //both borrowed
680 PythonQtObjectPtr dict = PyImport_GetModuleDict();
700 PythonQtObjectPtr dict = PyImport_GetModuleDict();
681 return PyDict_GetItemString(dict, "__main__");
701 return PyDict_GetItemString(dict, "__main__");
682 }
702 }
683
703
684 PythonQtObjectPtr PythonQt::importModule(const QString& name)
704 PythonQtObjectPtr PythonQt::importModule(const QString& name)
685 {
705 {
686 PythonQtObjectPtr mod;
706 PythonQtObjectPtr mod;
687 mod.setNewRef(PyImport_ImportModule(name.toLatin1().constData()));
707 mod.setNewRef(PyImport_ImportModule(name.toLatin1().constData()));
688 return mod;
708 return mod;
689 }
709 }
690
710
691
711
692 QVariant PythonQt::evalCode(PyObject* object, PyObject* pycode) {
712 QVariant PythonQt::evalCode(PyObject* object, PyObject* pycode) {
693 QVariant result;
713 QVariant result;
694 clearError();
714 clearError();
695 if (pycode) {
715 if (pycode) {
696 PyObject* dict = NULL;
716 PyObject* dict = NULL;
697 PyObject* globals = NULL;
717 PyObject* globals = NULL;
698 if (PyModule_Check(object)) {
718 if (PyModule_Check(object)) {
699 dict = PyModule_GetDict(object);
719 dict = PyModule_GetDict(object);
700 globals = dict;
720 globals = dict;
701 } else if (PyDict_Check(object)) {
721 } else if (PyDict_Check(object)) {
702 dict = object;
722 dict = object;
703 globals = dict;
723 globals = dict;
704 } else {
724 } else {
705 dict = PyObject_GetAttrString(object, "__dict__");
725 dict = PyObject_GetAttrString(object, "__dict__");
706 globals = PyObject_GetAttrString(PyImport_ImportModule(PyString_AS_STRING(PyObject_GetAttrString(object, "__module__"))),"__dict__");
726 globals = PyObject_GetAttrString(PyImport_ImportModule(
727 #ifdef PY3K
728 PyUnicode_AsUTF8(
729 #else
730 PyString_AS_STRING(
731 #endif
732 PyObject_GetAttrString(object, "__module__"))),"__dict__");
707 }
733 }
708 PyObject* r = NULL;
734 PyObject* r = NULL;
709 if (dict) {
735 if (dict) {
736 #ifdef PY3K
737 r = PyEval_EvalCode(pycode, globals, dict);
738 #else
710 r = PyEval_EvalCode((PyCodeObject*)pycode, globals , dict);
739 r = PyEval_EvalCode((PyCodeObject*)pycode, globals , dict);
740 #endif
711 }
741 }
712 if (r) {
742 if (r) {
713 result = PythonQtConv::PyObjToQVariant(r);
743 result = PythonQtConv::PyObjToQVariant(r);
714 Py_DECREF(r);
744 Py_DECREF(r);
715 } else {
745 } else {
716 handleError();
746 handleError();
717 }
747 }
718 } else {
748 } else {
719 handleError();
749 handleError();
720 }
750 }
721 return result;
751 return result;
722 }
752 }
723
753
724 QVariant PythonQt::evalScript(PyObject* object, const QString& script, int start)
754 QVariant PythonQt::evalScript(PyObject* object, const QString& script, int start)
725 {
755 {
726 QVariant result;
756 QVariant result;
727 PythonQtObjectPtr p;
757 PythonQtObjectPtr p;
728 PyObject* dict = NULL;
758 PyObject* dict = NULL;
729 clearError();
759 clearError();
730 if (PyModule_Check(object)) {
760 if (PyModule_Check(object)) {
731 dict = PyModule_GetDict(object);
761 dict = PyModule_GetDict(object);
732 } else if (PyDict_Check(object)) {
762 } else if (PyDict_Check(object)) {
733 dict = object;
763 dict = object;
734 }
764 }
735 if (dict) {
765 if (dict) {
736 p.setNewRef(PyRun_String(script.toLatin1().data(), start, dict, dict));
766 p.setNewRef(PyRun_String(script.toLatin1().data(), start, dict, dict));
737 }
767 }
738 if (p) {
768 if (p) {
739 result = PythonQtConv::PyObjToQVariant(p);
769 result = PythonQtConv::PyObjToQVariant(p);
740 } else {
770 } else {
741 handleError();
771 handleError();
742 }
772 }
743 return result;
773 return result;
744 }
774 }
745
775
746 void PythonQt::evalFile(PyObject* module, const QString& filename)
776 void PythonQt::evalFile(PyObject* module, const QString& filename)
747 {
777 {
748 PythonQtObjectPtr code = parseFile(filename);
778 PythonQtObjectPtr code = parseFile(filename);
749 clearError();
779 clearError();
750 if (code) {
780 if (code) {
751 evalCode(module, code);
781 evalCode(module, code);
752 } else {
782 } else {
753 handleError();
783 handleError();
754 }
784 }
755 }
785 }
756
786
757 PythonQtObjectPtr PythonQt::parseFile(const QString& filename)
787 PythonQtObjectPtr PythonQt::parseFile(const QString& filename)
758 {
788 {
759 PythonQtObjectPtr p;
789 PythonQtObjectPtr p;
760 p.setNewRef(PythonQtImport::getCodeFromPyc(filename));
790 p.setNewRef(PythonQtImport::getCodeFromPyc(filename));
761 clearError();
791 clearError();
762 if (!p) {
792 if (!p) {
763 handleError();
793 handleError();
764 }
794 }
765 return p;
795 return p;
766 }
796 }
767
797
768 PythonQtObjectPtr PythonQt::createModuleFromFile(const QString& name, const QString& filename)
798 PythonQtObjectPtr PythonQt::createModuleFromFile(const QString& name, const QString& filename)
769 {
799 {
770 PythonQtObjectPtr code = parseFile(filename);
800 PythonQtObjectPtr code = parseFile(filename);
771 PythonQtObjectPtr module = _p->createModule(name, code);
801 PythonQtObjectPtr module = _p->createModule(name, code);
772 return module;
802 return module;
773 }
803 }
774
804
775 PythonQtObjectPtr PythonQt::createModuleFromScript(const QString& name, const QString& script)
805 PythonQtObjectPtr PythonQt::createModuleFromScript(const QString& name, const QString& script)
776 {
806 {
777 PyErr_Clear();
807 PyErr_Clear();
778 QString scriptCode = script;
808 QString scriptCode = script;
779 if (scriptCode.isEmpty()) {
809 if (scriptCode.isEmpty()) {
780 // we always need at least a linefeed
810 // we always need at least a linefeed
781 scriptCode = "\n";
811 scriptCode = "\n";
782 }
812 }
783 PythonQtObjectPtr pycode;
813 PythonQtObjectPtr pycode;
784 pycode.setNewRef(Py_CompileString((char*)scriptCode.toLatin1().data(), "", Py_file_input));
814 pycode.setNewRef(Py_CompileString((char*)scriptCode.toLatin1().data(), "", Py_file_input));
785 PythonQtObjectPtr module = _p->createModule(name, pycode);
815 PythonQtObjectPtr module = _p->createModule(name, pycode);
786 return module;
816 return module;
787 }
817 }
788
818
789 PythonQtObjectPtr PythonQt::createUniqueModule()
819 PythonQtObjectPtr PythonQt::createUniqueModule()
790 {
820 {
791 static QString pyQtStr("PythonQt_module");
821 static QString pyQtStr("PythonQt_module");
792 QString moduleName = pyQtStr+QString::number(_uniqueModuleCount++);
822 QString moduleName = pyQtStr+QString::number(_uniqueModuleCount++);
793 return createModuleFromScript(moduleName);
823 return createModuleFromScript(moduleName);
794 }
824 }
795
825
796 void PythonQt::addObject(PyObject* object, const QString& name, QObject* qObject)
826 void PythonQt::addObject(PyObject* object, const QString& name, QObject* qObject)
797 {
827 {
798 if (PyModule_Check(object)) {
828 if (PyModule_Check(object)) {
799 PyModule_AddObject(object, name.toLatin1().data(), _p->wrapQObject(qObject));
829 PyModule_AddObject(object, name.toLatin1().data(), _p->wrapQObject(qObject));
800 } else if (PyDict_Check(object)) {
830 } else if (PyDict_Check(object)) {
801 PyDict_SetItemString(object, name.toLatin1().data(), _p->wrapQObject(qObject));
831 PyDict_SetItemString(object, name.toLatin1().data(), _p->wrapQObject(qObject));
802 } else {
832 } else {
803 PyObject_SetAttrString(object, name.toLatin1().data(), _p->wrapQObject(qObject));
833 PyObject_SetAttrString(object, name.toLatin1().data(), _p->wrapQObject(qObject));
804 }
834 }
805 }
835 }
806
836
807 void PythonQt::addVariable(PyObject* object, const QString& name, const QVariant& v)
837 void PythonQt::addVariable(PyObject* object, const QString& name, const QVariant& v)
808 {
838 {
809 if (PyModule_Check(object)) {
839 if (PyModule_Check(object)) {
810 PyModule_AddObject(object, name.toLatin1().data(), PythonQtConv::QVariantToPyObject(v));
840 PyModule_AddObject(object, name.toLatin1().data(), PythonQtConv::QVariantToPyObject(v));
811 } else if (PyDict_Check(object)) {
841 } else if (PyDict_Check(object)) {
812 PyDict_SetItemString(object, name.toLatin1().data(), PythonQtConv::QVariantToPyObject(v));
842 PyDict_SetItemString(object, name.toLatin1().data(), PythonQtConv::QVariantToPyObject(v));
813 } else {
843 } else {
814 PyObject_SetAttrString(object, name.toLatin1().data(), PythonQtConv::QVariantToPyObject(v));
844 PyObject_SetAttrString(object, name.toLatin1().data(), PythonQtConv::QVariantToPyObject(v));
815 }
845 }
816 }
846 }
817
847
818 void PythonQt::removeVariable(PyObject* object, const QString& name)
848 void PythonQt::removeVariable(PyObject* object, const QString& name)
819 {
849 {
820 if (PyDict_Check(object)) {
850 if (PyDict_Check(object)) {
821 PyDict_DelItemString(object, name.toLatin1().data());
851 PyDict_DelItemString(object, name.toLatin1().data());
822 } else {
852 } else {
823 PyObject_DelAttrString(object, name.toLatin1().data());
853 PyObject_DelAttrString(object, name.toLatin1().data());
824 }
854 }
825 }
855 }
826
856
827 QVariant PythonQt::getVariable(PyObject* object, const QString& objectname)
857 QVariant PythonQt::getVariable(PyObject* object, const QString& objectname)
828 {
858 {
829 QVariant result;
859 QVariant result;
830 PythonQtObjectPtr obj = lookupObject(object, objectname);
860 PythonQtObjectPtr obj = lookupObject(object, objectname);
831 if (obj) {
861 if (obj) {
832 result = PythonQtConv::PyObjToQVariant(obj);
862 result = PythonQtConv::PyObjToQVariant(obj);
833 }
863 }
834 return result;
864 return result;
835 }
865 }
836
866
837 QStringList PythonQt::introspection(PyObject* module, const QString& objectname, PythonQt::ObjectType type)
867 QStringList PythonQt::introspection(PyObject* module, const QString& objectname, PythonQt::ObjectType type)
838 {
868 {
839 QStringList results;
869 QStringList results;
840
870
841 PythonQtObjectPtr object;
871 PythonQtObjectPtr object;
842 if (objectname.isEmpty()) {
872 if (objectname.isEmpty()) {
843 object = module;
873 object = module;
844 } else {
874 } else {
845 object = lookupObject(module, objectname);
875 object = lookupObject(module, objectname);
846 if (!object && type == CallOverloads) {
876 if (!object && type == CallOverloads) {
847 PyObject* dict = lookupObject(module, "__builtins__");
877 PyObject* dict = lookupObject(module, "__builtins__");
848 if (dict) {
878 if (dict) {
849 object = PyDict_GetItemString(dict, objectname.toLatin1().constData());
879 object = PyDict_GetItemString(dict, objectname.toLatin1().constData());
850 }
880 }
851 }
881 }
852 }
882 }
853
883
854 if (object) {
884 if (object) {
855 results = introspectObject(object, type);
885 results = introspectObject(object, type);
856 }
886 }
857
887
858 return results;
888 return results;
859 }
889 }
860
890
861 QStringList PythonQt::introspectObject(PyObject* object, ObjectType type)
891 QStringList PythonQt::introspectObject(PyObject* object, ObjectType type)
862 {
892 {
863 QStringList results;
893 QStringList results;
864
894
865 if (type == CallOverloads) {
895 if (type == CallOverloads) {
866 if (PythonQtSlotFunction_Check(object)) {
896 if (PythonQtSlotFunction_Check(object)) {
867 PythonQtSlotFunctionObject* o = (PythonQtSlotFunctionObject*)object;
897 PythonQtSlotFunctionObject* o = (PythonQtSlotFunctionObject*)object;
868 PythonQtSlotInfo* info = o->m_ml;
898 PythonQtSlotInfo* info = o->m_ml;
869
899
870 while (info) {
900 while (info) {
871 results << info->fullSignature();
901 results << info->fullSignature();
872 info = info->nextInfo();
902 info = info->nextInfo();
873 }
903 }
874 } else if (PythonQtSignalFunction_Check(object)) {
904 } else if (PythonQtSignalFunction_Check(object)) {
875 PythonQtSignalFunctionObject* o = (PythonQtSignalFunctionObject*)object;
905 PythonQtSignalFunctionObject* o = (PythonQtSignalFunctionObject*)object;
876 PythonQtSlotInfo* info = o->m_ml;
906 PythonQtSlotInfo* info = o->m_ml;
877
907
878 while (info) {
908 while (info) {
879 results << info->fullSignature();
909 results << info->fullSignature();
880 info = info->nextInfo();
910 info = info->nextInfo();
881 }
911 }
882 } else if (object->ob_type == &PythonQtClassWrapper_Type) {
912 } else if (object->ob_type == &PythonQtClassWrapper_Type) {
883 PythonQtClassWrapper* o = (PythonQtClassWrapper*)object;
913 PythonQtClassWrapper* o = (PythonQtClassWrapper*)object;
884 PythonQtSlotInfo* info = o->classInfo()->constructors();
914 PythonQtSlotInfo* info = o->classInfo()->constructors();
885
915
886 while (info) {
916 while (info) {
887 results << info->fullSignature();
917 results << info->fullSignature();
888 info = info->nextInfo();
918 info = info->nextInfo();
889 }
919 }
890 } else {
920 } else {
891 QString signature = _p->getSignature(object);
921 QString signature = _p->getSignature(object);
892 if (!signature.isEmpty()) {
922 if (!signature.isEmpty()) {
893 results << signature;
923 results << signature;
894 } else {
924 } else {
895 PyObject* doc = PyObject_GetAttrString(object, "__doc__");
925 PyObject* doc = PyObject_GetAttrString(object, "__doc__");
896 if (doc) {
926 if (doc) {
927 #ifdef PY3K
928 results << PyUnicode_AsUTF8(doc);
929 #else
897 results << PyString_AsString(doc);
930 results << PyString_AsString(doc);
931 #endif
898 Py_DECREF(doc);
932 Py_DECREF(doc);
899 }
933 }
900 }
934 }
901 }
935 }
902 } else {
936 } else {
903 PyObject* keys = NULL;
937 PyObject* keys = NULL;
904 bool isDict = false;
938 bool isDict = false;
905 if (PyDict_Check(object)) {
939 if (PyDict_Check(object)) {
906 keys = PyDict_Keys(object);
940 keys = PyDict_Keys(object);
907 isDict = true;
941 isDict = true;
908 } else {
942 } else {
909 keys = PyObject_Dir(object);
943 keys = PyObject_Dir(object);
910 }
944 }
911 if (keys) {
945 if (keys) {
912 int count = PyList_Size(keys);
946 int count = PyList_Size(keys);
913 PyObject* key;
947 PyObject* key;
914 PyObject* value;
948 PyObject* value;
915 QString keystr;
949 QString keystr;
916 for (int i = 0;i<count;i++) {
950 for (int i = 0;i<count;i++) {
917 key = PyList_GetItem(keys,i);
951 key = PyList_GetItem(keys,i);
918 if (isDict) {
952 if (isDict) {
919 value = PyDict_GetItem(object, key);
953 value = PyDict_GetItem(object, key);
920 Py_INCREF(value);
954 Py_INCREF(value);
921 } else {
955 } else {
922 value = PyObject_GetAttr(object, key);
956 value = PyObject_GetAttr(object, key);
923 }
957 }
924 if (!value) continue;
958 if (!value) continue;
959 #ifdef PY3K
960 keystr = PyUnicode_AsUTF8(key);
961 #else
925 keystr = PyString_AsString(key);
962 keystr = PyString_AsString(key);
963 #endif
926 static const QString underscoreStr("__tmp");
964 static const QString underscoreStr("__tmp");
927 if (!keystr.startsWith(underscoreStr)) {
965 if (!keystr.startsWith(underscoreStr)) {
928 switch (type) {
966 switch (type) {
929 case Anything:
967 case Anything:
930 results << keystr;
968 results << keystr;
931 break;
969 break;
932 case Class:
970 case Class:
971 #ifdef PY3K
972 if(PyType_Check(value)) {
973 #else
933 if (value->ob_type == &PyClass_Type || value->ob_type == &PyType_Type) {
974 if (value->ob_type == &PyClass_Type || value->ob_type == &PyType_Type) {
975 #endif
934 results << keystr;
976 results << keystr;
935 }
977 }
936 break;
978 break;
937 case Variable:
979 case Variable:
938 if (value->ob_type != &PyClass_Type
980 if (
939 && value->ob_type != &PyCFunction_Type
981 #ifndef PY3K
940 && value->ob_type != &PyFunction_Type
982 value->ob_type != &PyClass_Type &&
941 && value->ob_type != &PyMethod_Type
983 #endif
942 && value->ob_type != &PyModule_Type
984 value->ob_type != &PyCFunction_Type &&
943 && value->ob_type != &PyType_Type
985 value->ob_type != &PyFunction_Type &&
944 && value->ob_type != &PythonQtSlotFunction_Type
986 value->ob_type != &PyMethod_Type &&
987 value->ob_type != &PyModule_Type &&
988 value->ob_type != &PyType_Type &&
989 value->ob_type != &PythonQtSlotFunction_Type
945 ) {
990 ) {
946 results << keystr;
991 results << keystr;
947 }
992 }
948 break;
993 break;
949 case Function:
994 case Function:
950 if (value->ob_type == &PyCFunction_Type ||
995 if (value->ob_type == &PyCFunction_Type ||
951 value->ob_type == &PyFunction_Type ||
996 value->ob_type == &PyFunction_Type ||
952 value->ob_type == &PyMethod_Type ||
997 value->ob_type == &PyMethod_Type ||
953 value->ob_type == &PythonQtSlotFunction_Type
998 value->ob_type == &PythonQtSlotFunction_Type
954 ) {
999 ) {
955 results << keystr;
1000 results << keystr;
956 }
1001 }
957 break;
1002 break;
958 case Module:
1003 case Module:
959 if (value->ob_type == &PyModule_Type) {
1004 if (value->ob_type == &PyModule_Type) {
960 results << keystr;
1005 results << keystr;
961 }
1006 }
962 break;
1007 break;
963 default:
1008 default:
964 std::cerr << "PythonQt: introspection: unknown case" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
1009 std::cerr << "PythonQt: introspection: unknown case" << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
965 }
1010 }
966 }
1011 }
967 Py_DECREF(value);
1012 Py_DECREF(value);
968 }
1013 }
969 Py_DECREF(keys);
1014 Py_DECREF(keys);
970 }
1015 }
971 if ((type == Anything) || (type == Variable)) {
1016 if ((type == Anything) || (type == Variable)) {
972 if (object->ob_type == &PythonQtClassWrapper_Type) {
1017 if (object->ob_type == &PythonQtClassWrapper_Type) {
973 PythonQtClassWrapper* o = (PythonQtClassWrapper*)object;
1018 PythonQtClassWrapper* o = (PythonQtClassWrapper*)object;
974 PythonQtClassInfo* info = o->classInfo();
1019 PythonQtClassInfo* info = o->classInfo();
975 results += info->propertyList();
1020 results += info->propertyList();
976 }
1021 }
977 }
1022 }
978 }
1023 }
979 return results;
1024 return results;
980 }
1025 }
981
1026
982 PyObject* PythonQt::getObjectByType(const QString& typeName)
1027 PyObject* PythonQt::getObjectByType(const QString& typeName)
983 {
1028 {
984 PythonQtObjectPtr sys;
1029 PythonQtObjectPtr sys;
985 sys.setNewRef(PyImport_ImportModule("sys"));
1030 sys.setNewRef(PyImport_ImportModule("sys"));
986 PythonQtObjectPtr modules = lookupObject(sys, "modules");
1031 PythonQtObjectPtr modules = lookupObject(sys, "modules");
987 Q_ASSERT(PyDict_Check(modules));
1032 Q_ASSERT(PyDict_Check(modules));
988
1033
989 QStringList tmp = typeName.split(".");
1034 QStringList tmp = typeName.split(".");
990 QString simpleTypeName = tmp.takeLast();
1035 QString simpleTypeName = tmp.takeLast();
991 QString moduleName = tmp.join(".");
1036 QString moduleName = tmp.join(".");
992
1037
993 PyObject* object = NULL;
1038 PyObject* object = NULL;
994 PyObject* moduleObject = PyDict_GetItemString(modules, moduleName.toLatin1().constData());
1039 PyObject* moduleObject = PyDict_GetItemString(modules, moduleName.toLatin1().constData());
995 if (moduleObject) {
1040 if (moduleObject) {
996 object = PyObject_GetAttrString(moduleObject, simpleTypeName.toLatin1().constData());
1041 object = PyObject_GetAttrString(moduleObject, simpleTypeName.toLatin1().constData());
997 }
1042 }
998
1043
999 if (!object) {
1044 if (!object) {
1000 moduleObject = PyDict_GetItemString(modules, "__builtin__");
1045 moduleObject = PyDict_GetItemString(modules, "__builtin__");
1001 if (moduleObject) {
1046 if (moduleObject) {
1002 object = PyObject_GetAttrString(moduleObject, simpleTypeName.toLatin1().constData());
1047 object = PyObject_GetAttrString(moduleObject, simpleTypeName.toLatin1().constData());
1003 }
1048 }
1004 }
1049 }
1005
1050
1006 return object;
1051 return object;
1007 }
1052 }
1008
1053
1009 QStringList PythonQt::introspectType(const QString& typeName, ObjectType type)
1054 QStringList PythonQt::introspectType(const QString& typeName, ObjectType type)
1010 {
1055 {
1011 QStringList results;
1056 QStringList results;
1012 PyObject* object = getObjectByType(typeName);
1057 PyObject* object = getObjectByType(typeName);
1013 if (!object) {
1058 if (!object) {
1014 // the last item may be a member, split it away and try again
1059 // the last item may be a member, split it away and try again
1015 QStringList tmp = typeName.split(".");
1060 QStringList tmp = typeName.split(".");
1016 QString memberName = tmp.takeLast();
1061 QString memberName = tmp.takeLast();
1017 QString typeName;
1062 QString typeName;
1018 if (tmp.isEmpty()) {
1063 if (tmp.isEmpty()) {
1019 typeName = memberName;
1064 typeName = memberName;
1020 memberName.clear();
1065 memberName.clear();
1021 } else {
1066 } else {
1022 typeName = tmp.takeLast();
1067 typeName = tmp.takeLast();
1023 }
1068 }
1024 PyObject* typeObject = getObjectByType(typeName);
1069 PyObject* typeObject = getObjectByType(typeName);
1025 if (typeObject) {
1070 if (typeObject) {
1026 object = PyObject_GetAttrString(typeObject, memberName.toLatin1().constData());
1071 object = PyObject_GetAttrString(typeObject, memberName.toLatin1().constData());
1027 }
1072 }
1028 }
1073 }
1029 if (object) {
1074 if (object) {
1030 results = introspectObject(object, type);
1075 results = introspectObject(object, type);
1031 Py_DECREF(object);
1076 Py_DECREF(object);
1032 }
1077 }
1033 return results;
1078 return results;
1034 }
1079 }
1035
1080
1036 QVariant PythonQt::call(PyObject* object, const QString& name, const QVariantList& args, const QVariantMap& kwargs)
1081 QVariant PythonQt::call(PyObject* object, const QString& name, const QVariantList& args, const QVariantMap& kwargs)
1037 {
1082 {
1038 PythonQtObjectPtr callable = lookupCallable(object, name);
1083 PythonQtObjectPtr callable = lookupCallable(object, name);
1039 if (callable) {
1084 if (callable) {
1040 return call(callable, args, kwargs);
1085 return call(callable, args, kwargs);
1041 } else {
1086 } else {
1042 return QVariant();
1087 return QVariant();
1043 }
1088 }
1044 }
1089 }
1045
1090
1046 QVariant PythonQt::call(PyObject* callable, const QVariantList& args, const QVariantMap& kwargs)
1091 QVariant PythonQt::call(PyObject* callable, const QVariantList& args, const QVariantMap& kwargs)
1047 {
1092 {
1048 QVariant r;
1093 QVariant r;
1049 PythonQtObjectPtr result;
1094 PythonQtObjectPtr result;
1050 result.setNewRef(callAndReturnPyObject(callable, args, kwargs));
1095 result.setNewRef(callAndReturnPyObject(callable, args, kwargs));
1051 clearError();
1096 clearError();
1052 if (result) {
1097 if (result) {
1053 r = PythonQtConv::PyObjToQVariant(result);
1098 r = PythonQtConv::PyObjToQVariant(result);
1054 } else {
1099 } else {
1055 PythonQt::self()->handleError();
1100 PythonQt::self()->handleError();
1056 }
1101 }
1057 return r;
1102 return r;
1058 }
1103 }
1059
1104
1060 PyObject* PythonQt::callAndReturnPyObject(PyObject* callable, const QVariantList& args, const QVariantMap& kwargs)
1105 PyObject* PythonQt::callAndReturnPyObject(PyObject* callable, const QVariantList& args, const QVariantMap& kwargs)
1061 {
1106 {
1062 PyObject* result = NULL;
1107 PyObject* result = NULL;
1063 if (callable) {
1108 if (callable) {
1064 bool err = false;
1109 bool err = false;
1065 PythonQtObjectPtr pargs;
1110 PythonQtObjectPtr pargs;
1066 int count = args.size();
1111 int count = args.size();
1067 if ((count > 0) || (kwargs.count() > 0)) { // create empty tuple if kwargs are given
1112 if ((count > 0) || (kwargs.count() > 0)) { // create empty tuple if kwargs are given
1068 pargs.setNewRef(PyTuple_New(count));
1113 pargs.setNewRef(PyTuple_New(count));
1069
1114
1070 // transform QVariant arguments to Python
1115 // transform QVariant arguments to Python
1071 for (int i = 0; i < count; i++) {
1116 for (int i = 0; i < count; i++) {
1072 PyObject* arg = PythonQtConv::QVariantToPyObject(args.at(i));
1117 PyObject* arg = PythonQtConv::QVariantToPyObject(args.at(i));
1073 if (arg) {
1118 if (arg) {
1074 // steals reference, no unref
1119 // steals reference, no unref
1075 PyTuple_SetItem(pargs, i,arg);
1120 PyTuple_SetItem(pargs, i,arg);
1076 } else {
1121 } else {
1077 err = true;
1122 err = true;
1078 break;
1123 break;
1079 }
1124 }
1080 }
1125 }
1081 }
1126 }
1082 if (!err) {
1127 if (!err) {
1083 if (kwargs.isEmpty()) {
1128 if (kwargs.isEmpty()) {
1084 // do a direct call if we have no keyword arguments
1129 // do a direct call if we have no keyword arguments
1085 PyErr_Clear();
1130 PyErr_Clear();
1086 result = PyObject_CallObject(callable, pargs);
1131 result = PyObject_CallObject(callable, pargs);
1087 } else {
1132 } else {
1088 // convert keyword arguments to Python
1133 // convert keyword arguments to Python
1089 PythonQtObjectPtr pkwargs;
1134 PythonQtObjectPtr pkwargs;
1090 pkwargs.setNewRef(PyDict_New());
1135 pkwargs.setNewRef(PyDict_New());
1091 QMapIterator<QString, QVariant> it(kwargs);
1136 QMapIterator<QString, QVariant> it(kwargs);
1092 while (it.hasNext()) {
1137 while (it.hasNext()) {
1093 it.next();
1138 it.next();
1094 PyObject* arg = PythonQtConv::QVariantToPyObject(it.value());
1139 PyObject* arg = PythonQtConv::QVariantToPyObject(it.value());
1095 if (arg) {
1140 if (arg) {
1096 PyDict_SetItemString(pkwargs, it.key().toLatin1().constData(), arg);
1141 PyDict_SetItemString(pkwargs, it.key().toLatin1().constData(), arg);
1097 } else {
1142 } else {
1098 err = true;
1143 err = true;
1099 break;
1144 break;
1100 }
1145 }
1101 }
1146 }
1102 if (!err) {
1147 if (!err) {
1103 // call with arguments and keyword arguments
1148 // call with arguments and keyword arguments
1104 PyErr_Clear();
1149 PyErr_Clear();
1105 result = PyObject_Call(callable, pargs, pkwargs);
1150 result = PyObject_Call(callable, pargs, pkwargs);
1106 }
1151 }
1107 }
1152 }
1108 }
1153 }
1109 }
1154 }
1110 return result;
1155 return result;
1111 }
1156 }
1112
1157
1113 void PythonQt::addInstanceDecorators(QObject* o)
1158 void PythonQt::addInstanceDecorators(QObject* o)
1114 {
1159 {
1115 _p->addDecorators(o, PythonQtPrivate::InstanceDecorator);
1160 _p->addDecorators(o, PythonQtPrivate::InstanceDecorator);
1116 }
1161 }
1117
1162
1118 void PythonQt::addClassDecorators(QObject* o)
1163 void PythonQt::addClassDecorators(QObject* o)
1119 {
1164 {
1120 _p->addDecorators(o, PythonQtPrivate::StaticDecorator | PythonQtPrivate::ConstructorDecorator | PythonQtPrivate::DestructorDecorator);
1165 _p->addDecorators(o, PythonQtPrivate::StaticDecorator | PythonQtPrivate::ConstructorDecorator | PythonQtPrivate::DestructorDecorator);
1121 }
1166 }
1122
1167
1123 void PythonQt::addDecorators(QObject* o)
1168 void PythonQt::addDecorators(QObject* o)
1124 {
1169 {
1125 _p->addDecorators(o, PythonQtPrivate::AllDecorators);
1170 _p->addDecorators(o, PythonQtPrivate::AllDecorators);
1126 }
1171 }
1127
1172
1128 void PythonQt::registerQObjectClassNames(const QStringList& names)
1173 void PythonQt::registerQObjectClassNames(const QStringList& names)
1129 {
1174 {
1130 _p->registerQObjectClassNames(names);
1175 _p->registerQObjectClassNames(names);
1131 }
1176 }
1132
1177
1133 void PythonQt::setImporter(PythonQtImportFileInterface* importInterface)
1178 void PythonQt::setImporter(PythonQtImportFileInterface* importInterface)
1134 {
1179 {
1135 _p->_importInterface = importInterface;
1180 _p->_importInterface = importInterface;
1136 PythonQtImport::init();
1181 PythonQtImport::init();
1137 }
1182 }
1138
1183
1139 void PythonQt::setImporterIgnorePaths(const QStringList& paths)
1184 void PythonQt::setImporterIgnorePaths(const QStringList& paths)
1140 {
1185 {
1141 _p->_importIgnorePaths = paths;
1186 _p->_importIgnorePaths = paths;
1142 }
1187 }
1143
1188
1144 const QStringList& PythonQt::getImporterIgnorePaths()
1189 const QStringList& PythonQt::getImporterIgnorePaths()
1145 {
1190 {
1146 return _p->_importIgnorePaths;
1191 return _p->_importIgnorePaths;
1147 }
1192 }
1148
1193
1149 void PythonQt::addWrapperFactory(PythonQtCppWrapperFactory* factory)
1194 void PythonQt::addWrapperFactory(PythonQtCppWrapperFactory* factory)
1150 {
1195 {
1151 _p->_cppWrapperFactories.append(factory);
1196 _p->_cppWrapperFactories.append(factory);
1152 }
1197 }
1153
1198
1154 void PythonQt::addWrapperFactory( PythonQtForeignWrapperFactory* factory )
1199 void PythonQt::addWrapperFactory( PythonQtForeignWrapperFactory* factory )
1155 {
1200 {
1156 _p->_foreignWrapperFactories.append(factory);
1201 _p->_foreignWrapperFactories.append(factory);
1157 }
1202 }
1158
1203
1159 //---------------------------------------------------------------------------------------------------
1204 //---------------------------------------------------------------------------------------------------
1160 PythonQtPrivate::PythonQtPrivate()
1205 PythonQtPrivate::PythonQtPrivate()
1161 {
1206 {
1162 _importInterface = NULL;
1207 _importInterface = NULL;
1163 _defaultImporter = new PythonQtQFileImporter;
1208 _defaultImporter = new PythonQtQFileImporter;
1164 _noLongerWrappedCB = NULL;
1209 _noLongerWrappedCB = NULL;
1165 _wrappedCB = NULL;
1210 _wrappedCB = NULL;
1166 _currentClassInfoForClassWrapperCreation = NULL;
1211 _currentClassInfoForClassWrapperCreation = NULL;
1167 _profilingCB = NULL;
1212 _profilingCB = NULL;
1168 _hadError = false;
1213 _hadError = false;
1169 _systemExitExceptionHandlerEnabled = false;
1214 _systemExitExceptionHandlerEnabled = false;
1170 }
1215 }
1171
1216
1172 void PythonQtPrivate::setupSharedLibrarySuffixes()
1217 void PythonQtPrivate::setupSharedLibrarySuffixes()
1173 {
1218 {
1174 _sharedLibrarySuffixes.clear();
1219 _sharedLibrarySuffixes.clear();
1175 PythonQtObjectPtr imp;
1220 PythonQtObjectPtr imp;
1176 imp.setNewRef(PyImport_ImportModule("imp"));
1221 imp.setNewRef(PyImport_ImportModule("imp"));
1177 int cExtensionCode = imp.getVariable("C_EXTENSION").toInt();
1222 int cExtensionCode = imp.getVariable("C_EXTENSION").toInt();
1178 QVariant result = imp.call("get_suffixes");
1223 QVariant result = imp.call("get_suffixes");
1179 #ifdef __linux
1224 #ifdef __linux
1180 #ifdef _DEBUG
1225 #ifdef _DEBUG
1181 // First look for shared libraries with the '_d' suffix in debug mode on Linux.
1226 // First look for shared libraries with the '_d' suffix in debug mode on Linux.
1182 // This is a workaround, because python does not append the '_d' suffix on Linux
1227 // This is a workaround, because python does not append the '_d' suffix on Linux
1183 // and would always load the release library otherwise.
1228 // and would always load the release library otherwise.
1184 _sharedLibrarySuffixes << "_d.so";
1229 _sharedLibrarySuffixes << "_d.so";
1185 #endif
1230 #endif
1186 #endif
1231 #endif
1187 Q_FOREACH (QVariant entry, result.toList()) {
1232 Q_FOREACH (QVariant entry, result.toList()) {
1188 QVariantList suffixEntry = entry.toList();
1233 QVariantList suffixEntry = entry.toList();
1189 if (suffixEntry.count()==3) {
1234 if (suffixEntry.count()==3) {
1190 int code = suffixEntry.at(2).toInt();
1235 int code = suffixEntry.at(2).toInt();
1191 if (code == cExtensionCode) {
1236 if (code == cExtensionCode) {
1192 _sharedLibrarySuffixes << suffixEntry.at(0).toString();
1237 _sharedLibrarySuffixes << suffixEntry.at(0).toString();
1193 }
1238 }
1194 }
1239 }
1195 }
1240 }
1196 }
1241 }
1197
1242
1198 PythonQtClassInfo* PythonQtPrivate::currentClassInfoForClassWrapperCreation()
1243 PythonQtClassInfo* PythonQtPrivate::currentClassInfoForClassWrapperCreation()
1199 {
1244 {
1200 PythonQtClassInfo* info = _currentClassInfoForClassWrapperCreation;
1245 PythonQtClassInfo* info = _currentClassInfoForClassWrapperCreation;
1201 _currentClassInfoForClassWrapperCreation = NULL;
1246 _currentClassInfoForClassWrapperCreation = NULL;
1202 return info;
1247 return info;
1203 }
1248 }
1204
1249
1205 void PythonQtPrivate::addDecorators(QObject* o, int decoTypes)
1250 void PythonQtPrivate::addDecorators(QObject* o, int decoTypes)
1206 {
1251 {
1207 o->setParent(this);
1252 o->setParent(this);
1208 int numMethods = o->metaObject()->methodCount();
1253 int numMethods = o->metaObject()->methodCount();
1209 for (int i = 0; i < numMethods; i++) {
1254 for (int i = 0; i < numMethods; i++) {
1210 QMetaMethod m = o->metaObject()->method(i);
1255 QMetaMethod m = o->metaObject()->method(i);
1211 if ((m.methodType() == QMetaMethod::Method ||
1256 if ((m.methodType() == QMetaMethod::Method ||
1212 m.methodType() == QMetaMethod::Slot) && m.access() == QMetaMethod::Public) {
1257 m.methodType() == QMetaMethod::Slot) && m.access() == QMetaMethod::Public) {
1213 // QMetaMethod::signature changed to QMetaMethod::methodSignature in QT5
1258 // QMetaMethod::signature changed to QMetaMethod::methodSignature in QT5
1214 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
1259 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
1215 QByteArray signature = m.methodSignature();
1260 QByteArray signature = m.methodSignature();
1216 #else
1261 #else
1217 QByteArray signature = m.signature();
1262 QByteArray signature = m.signature();
1218 #endif
1263 #endif
1219 if (signature.startsWith("new_")) {
1264 if (signature.startsWith("new_")) {
1220 if ((decoTypes & ConstructorDecorator) == 0) continue;
1265 if ((decoTypes & ConstructorDecorator) == 0) continue;
1221 const PythonQtMethodInfo* info = PythonQtMethodInfo::getCachedMethodInfo(m, NULL);
1266 const PythonQtMethodInfo* info = PythonQtMethodInfo::getCachedMethodInfo(m, NULL);
1222 if (info->parameters().at(0).pointerCount == 1) {
1267 if (info->parameters().at(0).pointerCount == 1) {
1223 QByteArray nameOfClass = signature.mid(4, signature.indexOf('(')-4);
1268 QByteArray nameOfClass = signature.mid(4, signature.indexOf('(')-4);
1224 PythonQtClassInfo* classInfo = lookupClassInfoAndCreateIfNotPresent(nameOfClass);
1269 PythonQtClassInfo* classInfo = lookupClassInfoAndCreateIfNotPresent(nameOfClass);
1225 PythonQtSlotInfo* newSlot = new PythonQtSlotInfo(NULL, m, i, o, PythonQtSlotInfo::ClassDecorator);
1270 PythonQtSlotInfo* newSlot = new PythonQtSlotInfo(NULL, m, i, o, PythonQtSlotInfo::ClassDecorator);
1226 classInfo->addConstructor(newSlot);
1271 classInfo->addConstructor(newSlot);
1227 }
1272 }
1228 } else if (signature.startsWith("delete_")) {
1273 } else if (signature.startsWith("delete_")) {
1229 if ((decoTypes & DestructorDecorator) == 0) continue;
1274 if ((decoTypes & DestructorDecorator) == 0) continue;
1230 QByteArray nameOfClass = signature.mid(7, signature.indexOf('(')-7);
1275 QByteArray nameOfClass = signature.mid(7, signature.indexOf('(')-7);
1231 PythonQtClassInfo* classInfo = lookupClassInfoAndCreateIfNotPresent(nameOfClass);
1276 PythonQtClassInfo* classInfo = lookupClassInfoAndCreateIfNotPresent(nameOfClass);
1232 PythonQtSlotInfo* newSlot = new PythonQtSlotInfo(NULL, m, i, o, PythonQtSlotInfo::ClassDecorator);
1277 PythonQtSlotInfo* newSlot = new PythonQtSlotInfo(NULL, m, i, o, PythonQtSlotInfo::ClassDecorator);
1233 classInfo->setDestructor(newSlot);
1278 classInfo->setDestructor(newSlot);
1234 } else if (signature.startsWith("static_")) {
1279 } else if (signature.startsWith("static_")) {
1235 if ((decoTypes & StaticDecorator) == 0) continue;
1280 if ((decoTypes & StaticDecorator) == 0) continue;
1236 QByteArray nameOfClass = signature.mid(7);
1281 QByteArray nameOfClass = signature.mid(7);
1237 nameOfClass = nameOfClass.mid(0, nameOfClass.indexOf('_'));
1282 nameOfClass = nameOfClass.mid(0, nameOfClass.indexOf('_'));
1238 PythonQtClassInfo* classInfo = lookupClassInfoAndCreateIfNotPresent(nameOfClass);
1283 PythonQtClassInfo* classInfo = lookupClassInfoAndCreateIfNotPresent(nameOfClass);
1239 PythonQtSlotInfo* newSlot = new PythonQtSlotInfo(NULL, m, i, o, PythonQtSlotInfo::ClassDecorator);
1284 PythonQtSlotInfo* newSlot = new PythonQtSlotInfo(NULL, m, i, o, PythonQtSlotInfo::ClassDecorator);
1240 classInfo->addDecoratorSlot(newSlot);
1285 classInfo->addDecoratorSlot(newSlot);
1241 } else {
1286 } else {
1242 if ((decoTypes & InstanceDecorator) == 0) continue;
1287 if ((decoTypes & InstanceDecorator) == 0) continue;
1243 const PythonQtMethodInfo* info = PythonQtMethodInfo::getCachedMethodInfo(m, NULL);
1288 const PythonQtMethodInfo* info = PythonQtMethodInfo::getCachedMethodInfo(m, NULL);
1244 if (info->parameters().count()>1) {
1289 if (info->parameters().count()>1) {
1245 PythonQtMethodInfo::ParameterInfo p = info->parameters().at(1);
1290 PythonQtMethodInfo::ParameterInfo p = info->parameters().at(1);
1246 if (p.pointerCount==1) {
1291 if (p.pointerCount==1) {
1247 PythonQtClassInfo* classInfo = lookupClassInfoAndCreateIfNotPresent(p.name);
1292 PythonQtClassInfo* classInfo = lookupClassInfoAndCreateIfNotPresent(p.name);
1248 PythonQtSlotInfo* newSlot = new PythonQtSlotInfo(NULL, m, i, o, PythonQtSlotInfo::InstanceDecorator);
1293 PythonQtSlotInfo* newSlot = new PythonQtSlotInfo(NULL, m, i, o, PythonQtSlotInfo::InstanceDecorator);
1249 classInfo->addDecoratorSlot(newSlot);
1294 classInfo->addDecoratorSlot(newSlot);
1250 }
1295 }
1251 }
1296 }
1252 }
1297 }
1253 }
1298 }
1254 }
1299 }
1255 }
1300 }
1256
1301
1257 void PythonQtPrivate::registerQObjectClassNames(const QStringList& names)
1302 void PythonQtPrivate::registerQObjectClassNames(const QStringList& names)
1258 {
1303 {
1259 Q_FOREACH(QString name, names) {
1304 Q_FOREACH(QString name, names) {
1260 _knownQObjectClassNames.insert(name.toLatin1(), true);
1305 _knownQObjectClassNames.insert(name.toLatin1(), true);
1261 }
1306 }
1262 }
1307 }
1263
1308
1264 void PythonQtPrivate::removeSignalEmitter(QObject* obj)
1309 void PythonQtPrivate::removeSignalEmitter(QObject* obj)
1265 {
1310 {
1266 _signalReceivers.remove(obj);
1311 _signalReceivers.remove(obj);
1267 }
1312 }
1268
1313
1269 namespace
1314 namespace
1270 {
1315 {
1271 //! adapted from python source file "pythonrun.c", function "handle_system_exit"
1316 //! adapted from python source file "pythonrun.c", function "handle_system_exit"
1272 //! return the exitcode instead of calling "Py_Exit".
1317 //! return the exitcode instead of calling "Py_Exit".
1273 //! it gives the application an opportunity to properly terminate.
1318 //! it gives the application an opportunity to properly terminate.
1274 int custom_system_exit_exception_handler()
1319 int custom_system_exit_exception_handler()
1275 {
1320 {
1276 PyObject *exception, *value, *tb;
1321 PyObject *exception, *value, *tb;
1277 int exitcode = 0;
1322 int exitcode = 0;
1278
1323
1279 // if (Py_InspectFlag)
1324 // if (Py_InspectFlag)
1280 // /* Don't exit if -i flag was given. This flag is set to 0
1325 // /* Don't exit if -i flag was given. This flag is set to 0
1281 // * when entering interactive mode for inspecting. */
1326 // * when entering interactive mode for inspecting. */
1282 // return exitcode;
1327 // return exitcode;
1283
1328
1284 PyErr_Fetch(&exception, &value, &tb);
1329 PyErr_Fetch(&exception, &value, &tb);
1330 #ifdef PY3K
1331 std::cout << std::endl;
1332 #else
1285 if (Py_FlushLine())
1333 if (Py_FlushLine())
1286 PyErr_Clear();
1334 PyErr_Clear();
1335 #endif
1287 fflush(stdout);
1336 fflush(stdout);
1288 if (value == NULL || value == Py_None)
1337 if (value == NULL || value == Py_None)
1289 goto done;
1338 goto done;
1290 if (PyExceptionInstance_Check(value)) {
1339 if (PyExceptionInstance_Check(value)) {
1291 /* The error code should be in the `code' attribute. */
1340 /* The error code should be in the `code' attribute. */
1292 PyObject *code = PyObject_GetAttrString(value, "code");
1341 PyObject *code = PyObject_GetAttrString(value, "code");
1293 if (code) {
1342 if (code) {
1294 Py_DECREF(value);
1343 Py_DECREF(value);
1295 value = code;
1344 value = code;
1296 if (value == Py_None)
1345 if (value == Py_None)
1297 goto done;
1346 goto done;
1298 }
1347 }
1299 /* If we failed to dig out the 'code' attribute,
1348 /* If we failed to dig out the 'code' attribute,
1300 just let the else clause below print the error. */
1349 just let the else clause below print the error. */
1301 }
1350 }
1351 #ifdef PY3K
1352 if (PyLong_Check(value))
1353 exitcode = (int)PyLong_AsLong(value);
1354 #else
1302 if (PyInt_Check(value))
1355 if (PyInt_Check(value))
1303 exitcode = (int)PyInt_AsLong(value);
1356 exitcode = (int)PyInt_AsLong(value);
1357 #endif
1304 else {
1358 else {
1305 PyObject *sys_stderr = PySys_GetObject(const_cast<char*>("stderr"));
1359 PyObject *sys_stderr = PySys_GetObject(const_cast<char*>("stderr"));
1306 if (sys_stderr != NULL && sys_stderr != Py_None) {
1360 if (sys_stderr != NULL && sys_stderr != Py_None) {
1307 PyFile_WriteObject(value, sys_stderr, Py_PRINT_RAW);
1361 PyFile_WriteObject(value, sys_stderr, Py_PRINT_RAW);
1308 } else {
1362 } else {
1309 PyObject_Print(value, stderr, Py_PRINT_RAW);
1363 PyObject_Print(value, stderr, Py_PRINT_RAW);
1310 fflush(stderr);
1364 fflush(stderr);
1311 }
1365 }
1312 PySys_WriteStderr("\n");
1366 PySys_WriteStderr("\n");
1313 exitcode = 1;
1367 exitcode = 1;
1314 }
1368 }
1315 done:
1369 done:
1316 /* Restore and clear the exception info, in order to properly decref
1370 /* Restore and clear the exception info, in order to properly decref
1317 * the exception, value, and traceback. If we just exit instead,
1371 * the exception, value, and traceback. If we just exit instead,
1318 * these leak, which confuses PYTHONDUMPREFS output, and may prevent
1372 * these leak, which confuses PYTHONDUMPREFS output, and may prevent
1319 * some finalizers from running.
1373 * some finalizers from running.
1320 */
1374 */
1321 PyErr_Restore(exception, value, tb);
1375 PyErr_Restore(exception, value, tb);
1322 PyErr_Clear();
1376 PyErr_Clear();
1323 return exitcode;
1377 return exitcode;
1324 //Py_Exit(exitcode);
1378 //Py_Exit(exitcode);
1325 }
1379 }
1326 }
1380 }
1327
1381
1328 bool PythonQt::handleError()
1382 bool PythonQt::handleError()
1329 {
1383 {
1330 bool flag = false;
1384 bool flag = false;
1331 if (PyErr_Occurred()) {
1385 if (PyErr_Occurred()) {
1332
1386
1333 if (_p->_systemExitExceptionHandlerEnabled &&
1387 if (_p->_systemExitExceptionHandlerEnabled &&
1334 PyErr_ExceptionMatches(PyExc_SystemExit)) {
1388 PyErr_ExceptionMatches(PyExc_SystemExit)) {
1335 int exitcode = custom_system_exit_exception_handler();
1389 int exitcode = custom_system_exit_exception_handler();
1336 Q_EMIT PythonQt::self()->systemExitExceptionRaised(exitcode);
1390 Q_EMIT PythonQt::self()->systemExitExceptionRaised(exitcode);
1337 }
1391 }
1338 else
1392 else
1339 {
1393 {
1340 // currently we just print the error and the stderr handler parses the errors
1394 // currently we just print the error and the stderr handler parses the errors
1341 PyErr_Print();
1395 PyErr_Print();
1342
1396
1343 /*
1397 /*
1344 // EXTRA: the format of the ptype and ptraceback is not really documented, so I use PyErr_Print() above
1398 // EXTRA: the format of the ptype and ptraceback is not really documented, so I use PyErr_Print() above
1345 PyObject *ptype;
1399 PyObject *ptype;
1346 PyObject *pvalue;
1400 PyObject *pvalue;
1347 PyObject *ptraceback;
1401 PyObject *ptraceback;
1348 PyErr_Fetch( &ptype, &pvalue, &ptraceback);
1402 PyErr_Fetch( &ptype, &pvalue, &ptraceback);
1349
1403
1350 Py_XDECREF(ptype);
1404 Py_XDECREF(ptype);
1351 Py_XDECREF(pvalue);
1405 Py_XDECREF(pvalue);
1352 Py_XDECREF(ptraceback);
1406 Py_XDECREF(ptraceback);
1353 */
1407 */
1354 PyErr_Clear();
1408 PyErr_Clear();
1355 }
1409 }
1356 flag = true;
1410 flag = true;
1357 }
1411 }
1358 _p->_hadError = flag;
1412 _p->_hadError = flag;
1359 return flag;
1413 return flag;
1360 }
1414 }
1361
1415
1362 bool PythonQt::hadError()const
1416 bool PythonQt::hadError()const
1363 {
1417 {
1364 return _p->_hadError;
1418 return _p->_hadError;
1365 }
1419 }
1366
1420
1367 void PythonQt::clearError()
1421 void PythonQt::clearError()
1368 {
1422 {
1369 _p->_hadError = false;
1423 _p->_hadError = false;
1370 }
1424 }
1371
1425
1372 void PythonQt::setSystemExitExceptionHandlerEnabled(bool value)
1426 void PythonQt::setSystemExitExceptionHandlerEnabled(bool value)
1373 {
1427 {
1374 _p->_systemExitExceptionHandlerEnabled = value;
1428 _p->_systemExitExceptionHandlerEnabled = value;
1375 }
1429 }
1376
1430
1377 bool PythonQt::systemExitExceptionHandlerEnabled() const
1431 bool PythonQt::systemExitExceptionHandlerEnabled() const
1378 {
1432 {
1379 return _p->_systemExitExceptionHandlerEnabled;
1433 return _p->_systemExitExceptionHandlerEnabled;
1380 }
1434 }
1381
1435
1382 void PythonQt::addSysPath(const QString& path)
1436 void PythonQt::addSysPath(const QString& path)
1383 {
1437 {
1384 PythonQtObjectPtr sys;
1438 PythonQtObjectPtr sys;
1385 sys.setNewRef(PyImport_ImportModule("sys"));
1439 sys.setNewRef(PyImport_ImportModule("sys"));
1386 PythonQtObjectPtr obj = lookupObject(sys, "path");
1440 PythonQtObjectPtr obj = lookupObject(sys, "path");
1387 PyList_Insert(obj, 0, PythonQtConv::QStringToPyObject(path));
1441 PyList_Insert(obj, 0, PythonQtConv::QStringToPyObject(path));
1388 }
1442 }
1389
1443
1390 void PythonQt::overwriteSysPath(const QStringList& paths)
1444 void PythonQt::overwriteSysPath(const QStringList& paths)
1391 {
1445 {
1392 PythonQtObjectPtr sys;
1446 PythonQtObjectPtr sys;
1393 sys.setNewRef(PyImport_ImportModule("sys"));
1447 sys.setNewRef(PyImport_ImportModule("sys"));
1394 PyModule_AddObject(sys, "path", PythonQtConv::QStringListToPyList(paths));
1448 PyModule_AddObject(sys, "path", PythonQtConv::QStringListToPyList(paths));
1395 }
1449 }
1396
1450
1397 void PythonQt::setModuleImportPath(PyObject* module, const QStringList& paths)
1451 void PythonQt::setModuleImportPath(PyObject* module, const QStringList& paths)
1398 {
1452 {
1399 PyModule_AddObject(module, "__path__", PythonQtConv::QStringListToPyList(paths));
1453 PyModule_AddObject(module, "__path__", PythonQtConv::QStringListToPyList(paths));
1400 }
1454 }
1401
1455
1402 void PythonQt::stdOutRedirectCB(const QString& str)
1456 void PythonQt::stdOutRedirectCB(const QString& str)
1403 {
1457 {
1404 if (!PythonQt::self()) {
1458 if (!PythonQt::self()) {
1405 std::cout << str.toLatin1().data() << std::endl;
1459 std::cout << str.toLatin1().data() << std::endl;
1406 return;
1460 return;
1407 }
1461 }
1408 Q_EMIT PythonQt::self()->pythonStdOut(str);
1462 Q_EMIT PythonQt::self()->pythonStdOut(str);
1409 }
1463 }
1410
1464
1411 void PythonQt::stdErrRedirectCB(const QString& str)
1465 void PythonQt::stdErrRedirectCB(const QString& str)
1412 {
1466 {
1413 if (!PythonQt::self()) {
1467 if (!PythonQt::self()) {
1414 std::cerr << str.toLatin1().data() << std::endl;
1468 std::cerr << str.toLatin1().data() << std::endl;
1415 return;
1469 return;
1416 }
1470 }
1417 Q_EMIT PythonQt::self()->pythonStdErr(str);
1471 Q_EMIT PythonQt::self()->pythonStdErr(str);
1418 }
1472 }
1419
1473
1420 void PythonQt::setQObjectWrappedCallback(PythonQtQObjectWrappedCB* cb)
1474 void PythonQt::setQObjectWrappedCallback(PythonQtQObjectWrappedCB* cb)
1421 {
1475 {
1422 _p->_wrappedCB = cb;
1476 _p->_wrappedCB = cb;
1423 }
1477 }
1424
1478
1425 void PythonQt::setQObjectNoLongerWrappedCallback(PythonQtQObjectNoLongerWrappedCB* cb)
1479 void PythonQt::setQObjectNoLongerWrappedCallback(PythonQtQObjectNoLongerWrappedCB* cb)
1426 {
1480 {
1427 _p->_noLongerWrappedCB = cb;
1481 _p->_noLongerWrappedCB = cb;
1428 }
1482 }
1429
1483
1430 void PythonQt::setProfilingCallback(ProfilingCB* cb)
1484 void PythonQt::setProfilingCallback(ProfilingCB* cb)
1431 {
1485 {
1432 _p->_profilingCB = cb;
1486 _p->_profilingCB = cb;
1433 }
1487 }
1434
1488
1435
1489
1436 static PyMethodDef PythonQtMethods[] = {
1490 static PyMethodDef PythonQtMethods[] = {
1437 {NULL, NULL, 0, NULL}
1491 {NULL, NULL, 0, NULL}
1438 };
1492 };
1439
1493
1494 #ifdef PY3K
1495 static PyModuleDef PythonQtModule = {
1496 PyModuleDef_HEAD_INIT,
1497 "",
1498 NULL,
1499 -1,
1500 PythonQtMethods,
1501 NULL,
1502 NULL,
1503 NULL,
1504 NULL
1505 };
1506 #endif
1507
1440 void PythonQt::initPythonQtModule(bool redirectStdOut, const QByteArray& pythonQtModuleName)
1508 void PythonQt::initPythonQtModule(bool redirectStdOut, const QByteArray& pythonQtModuleName)
1441 {
1509 {
1442 QByteArray name = "PythonQt";
1510 QByteArray name = "PythonQt";
1443 if (!pythonQtModuleName.isEmpty()) {
1511 if (!pythonQtModuleName.isEmpty()) {
1444 name = pythonQtModuleName;
1512 name = pythonQtModuleName;
1445 }
1513 }
1514 #ifdef PY3K
1515 PythonQtModule.m_name = name.constData();
1516 _p->_pythonQtModule = PyModule_Create(&PythonQtModule);
1517 #else
1446 _p->_pythonQtModule = Py_InitModule(name.constData(), PythonQtMethods);
1518 _p->_pythonQtModule = Py_InitModule(name.constData(), PythonQtMethods);
1519 #endif
1447 _p->_pythonQtModuleName = name;
1520 _p->_pythonQtModuleName = name;
1448
1521
1449 if (redirectStdOut) {
1522 if (redirectStdOut) {
1450 PythonQtObjectPtr sys;
1523 PythonQtObjectPtr sys;
1451 PythonQtObjectPtr out;
1524 PythonQtObjectPtr out;
1452 PythonQtObjectPtr err;
1525 PythonQtObjectPtr err;
1453 sys.setNewRef(PyImport_ImportModule("sys"));
1526 sys.setNewRef(PyImport_ImportModule("sys"));
1454 // create a redirection object for stdout and stderr
1527 // create a redirection object for stdout and stderr
1455 out = PythonQtStdOutRedirectType.tp_new(&PythonQtStdOutRedirectType,NULL, NULL);
1528 out = PythonQtStdOutRedirectType.tp_new(&PythonQtStdOutRedirectType,NULL, NULL);
1456 ((PythonQtStdOutRedirect*)out.object())->_cb = stdOutRedirectCB;
1529 ((PythonQtStdOutRedirect*)out.object())->_cb = stdOutRedirectCB;
1457 err = PythonQtStdOutRedirectType.tp_new(&PythonQtStdOutRedirectType,NULL, NULL);
1530 err = PythonQtStdOutRedirectType.tp_new(&PythonQtStdOutRedirectType,NULL, NULL);
1458 ((PythonQtStdOutRedirect*)err.object())->_cb = stdErrRedirectCB;
1531 ((PythonQtStdOutRedirect*)err.object())->_cb = stdErrRedirectCB;
1459 // replace the built in file objects with our own objects
1532 // replace the built in file objects with our own objects
1460 PyModule_AddObject(sys, "stdout", out);
1533 PyModule_AddObject(sys, "stdout", out);
1461 PyModule_AddObject(sys, "stderr", err);
1534 PyModule_AddObject(sys, "stderr", err);
1462 }
1535 }
1463
1536
1464 // add PythonQt to the list of builtin module names
1537 // add PythonQt to the list of builtin module names
1465 PythonQtObjectPtr sys;
1538 PythonQtObjectPtr sys;
1466 sys.setNewRef(PyImport_ImportModule("sys"));
1539 sys.setNewRef(PyImport_ImportModule("sys"));
1467 PyObject *old_module_names = PyObject_GetAttrString(sys.object(),"builtin_module_names");
1540 PyObject *old_module_names = PyObject_GetAttrString(sys.object(),"builtin_module_names");
1468 Py_ssize_t old_size = PyTuple_Size(old_module_names);
1541 Py_ssize_t old_size = PyTuple_Size(old_module_names);
1469 PyObject *module_names = PyTuple_New(old_size+1);
1542 PyObject *module_names = PyTuple_New(old_size+1);
1470 for(Py_ssize_t i = 0; i < old_size; i++)
1543 for(Py_ssize_t i = 0; i < old_size; i++)
1471 PyTuple_SetItem(module_names, i, PyTuple_GetItem(old_module_names, i));
1544 PyTuple_SetItem(module_names, i, PyTuple_GetItem(old_module_names, i));
1545 #ifdef PY3K
1546 PyTuple_SetItem(module_names, old_size, PyUnicode_FromString(name.constData()));
1547 #else
1472 PyTuple_SetItem(module_names, old_size, PyString_FromString(name.constData()));
1548 PyTuple_SetItem(module_names, old_size, PyString_FromString(name.constData()));
1549 #endif
1473 PyModule_AddObject(sys.object(),"builtin_module_names",module_names);
1550 PyModule_AddObject(sys.object(),"builtin_module_names",module_names);
1474 Py_DecRef(old_module_names);
1551 Py_DecRef(old_module_names);
1475 }
1552 }
1476
1553
1477 QString PythonQt::getReturnTypeOfWrappedMethod(PyObject* module, const QString& name)
1554 QString PythonQt::getReturnTypeOfWrappedMethod(PyObject* module, const QString& name)
1478 {
1555 {
1479 QStringList tmp = name.split(".");
1556 QStringList tmp = name.split(".");
1480 QString methodName = tmp.takeLast();
1557 QString methodName = tmp.takeLast();
1481 QString variableName = tmp.join(".");
1558 QString variableName = tmp.join(".");
1482 // TODO: the variableName may be a type name, this needs to be handled differently,
1559 // TODO: the variableName may be a type name, this needs to be handled differently,
1483 // because it is not necessarily known in the module context
1560 // because it is not necessarily known in the module context
1484 PythonQtObjectPtr variableObject = lookupObject(module, variableName);
1561 PythonQtObjectPtr variableObject = lookupObject(module, variableName);
1485 if (variableObject.isNull()) {
1562 if (variableObject.isNull()) {
1486 return "";
1563 return "";
1487 }
1564 }
1488
1565
1489 return getReturnTypeOfWrappedMethodHelper(variableObject, methodName, name);
1566 return getReturnTypeOfWrappedMethodHelper(variableObject, methodName, name);
1490 }
1567 }
1491
1568
1492 QString PythonQt::getReturnTypeOfWrappedMethod(const QString& typeName, const QString& methodName)
1569 QString PythonQt::getReturnTypeOfWrappedMethod(const QString& typeName, const QString& methodName)
1493 {
1570 {
1494 PythonQtObjectPtr typeObject = getObjectByType(typeName);
1571 PythonQtObjectPtr typeObject = getObjectByType(typeName);
1495 if (typeObject.isNull()) {
1572 if (typeObject.isNull()) {
1496 return "";
1573 return "";
1497 }
1574 }
1498 return getReturnTypeOfWrappedMethodHelper(typeObject, methodName, typeName + "." + methodName);
1575 return getReturnTypeOfWrappedMethodHelper(typeObject, methodName, typeName + "." + methodName);
1499 }
1576 }
1500
1577
1501 QString PythonQt::getReturnTypeOfWrappedMethodHelper(const PythonQtObjectPtr& variableObject, const QString& methodName, const QString& context)
1578 QString PythonQt::getReturnTypeOfWrappedMethodHelper(const PythonQtObjectPtr& variableObject, const QString& methodName, const QString& context)
1502 {
1579 {
1503 PythonQtObjectPtr methodObject;
1580 PythonQtObjectPtr methodObject;
1504 if (PyDict_Check(variableObject)) {
1581 if (PyDict_Check(variableObject)) {
1505 methodObject = PyDict_GetItemString(variableObject, methodName.toLatin1().constData());
1582 methodObject = PyDict_GetItemString(variableObject, methodName.toLatin1().constData());
1506 } else {
1583 } else {
1507 methodObject.setNewRef(PyObject_GetAttrString(variableObject, methodName.toLatin1().constData()));
1584 methodObject.setNewRef(PyObject_GetAttrString(variableObject, methodName.toLatin1().constData()));
1508 }
1585 }
1509 if (methodObject.isNull()) {
1586 if (methodObject.isNull()) {
1510 return "";
1587 return "";
1511 }
1588 }
1512
1589
1513 QString type;
1590 QString type;
1514
1591
1592 #ifdef PY3K
1593 if (PyType_Check(methodObject)) {
1594 #else
1515 if (methodObject->ob_type == &PyClass_Type || methodObject->ob_type == &PyType_Type) {
1595 if (methodObject->ob_type == &PyClass_Type || methodObject->ob_type == &PyType_Type) {
1596 #endif
1516 // the methodObject is not a method, but the name of a type/class. This means
1597 // the methodObject is not a method, but the name of a type/class. This means
1517 // a constructor is called. Return the context.
1598 // a constructor is called. Return the context.
1518 type = context;
1599 type = context;
1519 } else if (methodObject->ob_type == &PythonQtSlotFunction_Type) {
1600 } else if (methodObject->ob_type == &PythonQtSlotFunction_Type) {
1520 QString className;
1601 QString className;
1521
1602
1522 if (PyObject_TypeCheck(variableObject, &PythonQtInstanceWrapper_Type)) {
1603 if (PyObject_TypeCheck(variableObject, &PythonQtInstanceWrapper_Type)) {
1523 // the type name of wrapped instance is the class name
1604 // the type name of wrapped instance is the class name
1524 className = variableObject->ob_type->tp_name;
1605 className = variableObject->ob_type->tp_name;
1525 } else {
1606 } else {
1526 PyObject* classNameObject = PyObject_GetAttrString(variableObject, "__name__");
1607 PyObject* classNameObject = PyObject_GetAttrString(variableObject, "__name__");
1527 if (classNameObject) {
1608 if (classNameObject) {
1609 #ifdef PY3K
1610 Q_ASSERT(PyUnicode_Check(classNameObject));
1611 className = PyUnicode_AsUTF8(classNameObject);
1612 #else
1528 Q_ASSERT(PyString_Check(classNameObject));
1613 Q_ASSERT(PyString_Check(classNameObject));
1529 className = PyString_AsString(classNameObject);
1614 className = PyString_AsString(classNameObject);
1615 #endif
1530 Py_DECREF(classNameObject);
1616 Py_DECREF(classNameObject);
1531 }
1617 }
1532 }
1618 }
1533
1619
1534 if (!className.isEmpty()) {
1620 if (!className.isEmpty()) {
1535 PythonQtClassInfo* info = _p->_knownClassInfos.value(className.toLatin1().constData());
1621 PythonQtClassInfo* info = _p->_knownClassInfos.value(className.toLatin1().constData());
1536 if (info) {
1622 if (info) {
1537 PythonQtSlotInfo* slotInfo = info->member(methodName.toLatin1().constData())._slot;
1623 PythonQtSlotInfo* slotInfo = info->member(methodName.toLatin1().constData())._slot;
1538 if (slotInfo) {
1624 if (slotInfo) {
1539 if (slotInfo->metaMethod()) {
1625 if (slotInfo->metaMethod()) {
1540 type = slotInfo->metaMethod()->typeName();
1626 type = slotInfo->metaMethod()->typeName();
1541 if (!type.isEmpty()) {
1627 if (!type.isEmpty()) {
1542 QChar c = type.at(type.length()-1);
1628 QChar c = type.at(type.length()-1);
1543 while (c == '*' || c == '&') {
1629 while (c == '*' || c == '&') {
1544 type.truncate(type.length()-1);
1630 type.truncate(type.length()-1);
1545 if (!type.isEmpty()) {
1631 if (!type.isEmpty()) {
1546 c = type.at(type.length()-1);
1632 c = type.at(type.length()-1);
1547 } else {
1633 } else {
1548 break;
1634 break;
1549 }
1635 }
1550 }
1636 }
1551 // split away template arguments
1637 // split away template arguments
1552 type = type.split("<").first();
1638 type = type.split("<").first();
1553 // split away const
1639 // split away const
1554 type = type.split(" ").last().trimmed();
1640 type = type.split(" ").last().trimmed();
1555
1641
1556 // if the type is a known class info, then create the full type name, i.e. include the
1642 // if the type is a known class info, then create the full type name, i.e. include the
1557 // module name. For example, the slot may return a QDate, then this looks up the
1643 // module name. For example, the slot may return a QDate, then this looks up the
1558 // name _PythonQt.QtCore.QDate.
1644 // name _PythonQt.QtCore.QDate.
1559 PythonQtClassInfo* typeInfo = _p->_knownClassInfos.value(type.toLatin1().constData());
1645 PythonQtClassInfo* typeInfo = _p->_knownClassInfos.value(type.toLatin1().constData());
1560 if (typeInfo && typeInfo->pythonQtClassWrapper()) {
1646 if (typeInfo && typeInfo->pythonQtClassWrapper()) {
1561 PyObject* s = PyObject_GetAttrString(typeInfo->pythonQtClassWrapper(), "__module__");
1647 PyObject* s = PyObject_GetAttrString(typeInfo->pythonQtClassWrapper(), "__module__");
1648 #ifdef PY3K
1649 Q_ASSERT(PyUnicode_Check(s));
1650 type = QString(PyUnicode_AsUTF8(s));
1651 #else
1562 Q_ASSERT(PyString_Check(s));
1652 Q_ASSERT(PyString_Check(s));
1563 type = QString(PyString_AsString(s)) + "." + type;
1653 type = QString(PyString_AsString(s)) + "." + type;
1654 #endif
1564 Py_DECREF(s);
1655 Py_DECREF(s);
1565 s = PyObject_GetAttrString(typeInfo->pythonQtClassWrapper(), "__name__");
1656 s = PyObject_GetAttrString(typeInfo->pythonQtClassWrapper(), "__name__");
1657 #ifdef PY3K
1658 Q_ASSERT(PyUnicode_Check(s));
1659 #else
1566 Q_ASSERT(PyString_Check(s));
1660 Q_ASSERT(PyString_Check(s));
1661 #endif
1567 Py_DECREF(s);
1662 Py_DECREF(s);
1568 }
1663 }
1569 }
1664 }
1570 }
1665 }
1571 }
1666 }
1572 }
1667 }
1573 }
1668 }
1574 }
1669 }
1575 return type;
1670 return type;
1576 }
1671 }
1577
1672
1578 void PythonQt::registerCPPClass(const char* typeName, const char* parentTypeName, const char* package, PythonQtQObjectCreatorFunctionCB* wrapperCreator, PythonQtShellSetInstanceWrapperCB* shell)
1673 void PythonQt::registerCPPClass(const char* typeName, const char* parentTypeName, const char* package, PythonQtQObjectCreatorFunctionCB* wrapperCreator, PythonQtShellSetInstanceWrapperCB* shell)
1579 {
1674 {
1580 _p->registerCPPClass(typeName, parentTypeName, package, wrapperCreator, shell);
1675 _p->registerCPPClass(typeName, parentTypeName, package, wrapperCreator, shell);
1581 }
1676 }
1582
1677
1583
1678
1584 PythonQtClassInfo* PythonQtPrivate::lookupClassInfoAndCreateIfNotPresent(const char* typeName)
1679 PythonQtClassInfo* PythonQtPrivate::lookupClassInfoAndCreateIfNotPresent(const char* typeName)
1585 {
1680 {
1586 PythonQtClassInfo* info = _knownClassInfos.value(typeName);
1681 PythonQtClassInfo* info = _knownClassInfos.value(typeName);
1587 if (!info) {
1682 if (!info) {
1588 info = new PythonQtClassInfo();
1683 info = new PythonQtClassInfo();
1589 info->setupCPPObject(typeName);
1684 info->setupCPPObject(typeName);
1590 _knownClassInfos.insert(typeName, info);
1685 _knownClassInfos.insert(typeName, info);
1591 }
1686 }
1592 return info;
1687 return info;
1593 }
1688 }
1594
1689
1595 void PythonQt::addPolymorphicHandler(const char* typeName, PythonQtPolymorphicHandlerCB* cb)
1690 void PythonQt::addPolymorphicHandler(const char* typeName, PythonQtPolymorphicHandlerCB* cb)
1596 {
1691 {
1597 _p->addPolymorphicHandler(typeName, cb);
1692 _p->addPolymorphicHandler(typeName, cb);
1598 }
1693 }
1599
1694
1600 void PythonQtPrivate::addPolymorphicHandler(const char* typeName, PythonQtPolymorphicHandlerCB* cb)
1695 void PythonQtPrivate::addPolymorphicHandler(const char* typeName, PythonQtPolymorphicHandlerCB* cb)
1601 {
1696 {
1602 PythonQtClassInfo* info = lookupClassInfoAndCreateIfNotPresent(typeName);
1697 PythonQtClassInfo* info = lookupClassInfoAndCreateIfNotPresent(typeName);
1603 info->addPolymorphicHandler(cb);
1698 info->addPolymorphicHandler(cb);
1604 }
1699 }
1605
1700
1606 bool PythonQt::addParentClass(const char* typeName, const char* parentTypeName, int upcastingOffset)
1701 bool PythonQt::addParentClass(const char* typeName, const char* parentTypeName, int upcastingOffset)
1607 {
1702 {
1608 return _p->addParentClass(typeName, parentTypeName, upcastingOffset);
1703 return _p->addParentClass(typeName, parentTypeName, upcastingOffset);
1609 }
1704 }
1610
1705
1611 bool PythonQtPrivate::addParentClass(const char* typeName, const char* parentTypeName, int upcastingOffset)
1706 bool PythonQtPrivate::addParentClass(const char* typeName, const char* parentTypeName, int upcastingOffset)
1612 {
1707 {
1613 PythonQtClassInfo* info = _knownClassInfos.value(typeName);
1708 PythonQtClassInfo* info = _knownClassInfos.value(typeName);
1614 if (info) {
1709 if (info) {
1615 PythonQtClassInfo* parentInfo = lookupClassInfoAndCreateIfNotPresent(parentTypeName);
1710 PythonQtClassInfo* parentInfo = lookupClassInfoAndCreateIfNotPresent(parentTypeName);
1616 info->addParentClass(PythonQtClassInfo::ParentClassInfo(parentInfo, upcastingOffset));
1711 info->addParentClass(PythonQtClassInfo::ParentClassInfo(parentInfo, upcastingOffset));
1617 return true;
1712 return true;
1618 } else {
1713 } else {
1619 return false;
1714 return false;
1620 }
1715 }
1621 }
1716 }
1622
1717
1623 void PythonQtPrivate::registerCPPClass(const char* typeName, const char* parentTypeName, const char* package, PythonQtQObjectCreatorFunctionCB* wrapperCreator, PythonQtShellSetInstanceWrapperCB* shell, PyObject* module, int typeSlots)
1718 void PythonQtPrivate::registerCPPClass(const char* typeName, const char* parentTypeName, const char* package, PythonQtQObjectCreatorFunctionCB* wrapperCreator, PythonQtShellSetInstanceWrapperCB* shell, PyObject* module, int typeSlots)
1624 {
1719 {
1625 PythonQtClassInfo* info = lookupClassInfoAndCreateIfNotPresent(typeName);
1720 PythonQtClassInfo* info = lookupClassInfoAndCreateIfNotPresent(typeName);
1626 if (!info->pythonQtClassWrapper()) {
1721 if (!info->pythonQtClassWrapper()) {
1627 info->setTypeSlots(typeSlots);
1722 info->setTypeSlots(typeSlots);
1628 info->setupCPPObject(typeName);
1723 info->setupCPPObject(typeName);
1629 createPythonQtClassWrapper(info, package, module);
1724 createPythonQtClassWrapper(info, package, module);
1630 }
1725 }
1631 if (parentTypeName && strcmp(parentTypeName,"")!=0) {
1726 if (parentTypeName && strcmp(parentTypeName,"")!=0) {
1632 addParentClass(typeName, parentTypeName, 0);
1727 addParentClass(typeName, parentTypeName, 0);
1633 }
1728 }
1634 if (wrapperCreator) {
1729 if (wrapperCreator) {
1635 info->setDecoratorProvider(wrapperCreator);
1730 info->setDecoratorProvider(wrapperCreator);
1636 }
1731 }
1637 if (shell) {
1732 if (shell) {
1638 info->setShellSetInstanceWrapperCB(shell);
1733 info->setShellSetInstanceWrapperCB(shell);
1639 }
1734 }
1640 }
1735 }
1641
1736
1642 PyObject* PythonQtPrivate::packageByName(const char* name)
1737 PyObject* PythonQtPrivate::packageByName(const char* name)
1643 {
1738 {
1644 if (name==NULL || name[0]==0) {
1739 if (name==NULL || name[0]==0) {
1645 name = "private";
1740 name = "private";
1646 }
1741 }
1647 PyObject* v = _packages.value(name);
1742 PyObject* v = _packages.value(name);
1648 if (!v) {
1743 if (!v) {
1649 v = PyImport_AddModule((_pythonQtModuleName + "." + name).constData());
1744 v = PyImport_AddModule((_pythonQtModuleName + "." + name).constData());
1650 _packages.insert(name, v);
1745 _packages.insert(name, v);
1651 // AddObject steals the reference, so increment it!
1746 // AddObject steals the reference, so increment it!
1652 Py_INCREF(v);
1747 Py_INCREF(v);
1653 PyModule_AddObject(_pythonQtModule, name, v);
1748 PyModule_AddObject(_pythonQtModule, name, v);
1654 }
1749 }
1655 return v;
1750 return v;
1656 }
1751 }
1657
1752
1658 void PythonQtPrivate::handleVirtualOverloadReturnError(const char* signature, const PythonQtMethodInfo* methodInfo, PyObject* result)
1753 void PythonQtPrivate::handleVirtualOverloadReturnError(const char* signature, const PythonQtMethodInfo* methodInfo, PyObject* result)
1659 {
1754 {
1660 QString error = "Return value '" + PythonQtConv::PyObjGetString(result) + "' can not be converted to expected C++ type '" + methodInfo->parameters().at(0).name + "' as return value of virtual method " + signature;
1755 QString error = "Return value '" + PythonQtConv::PyObjGetString(result) + "' can not be converted to expected C++ type '" + methodInfo->parameters().at(0).name + "' as return value of virtual method " + signature;
1661 PyErr_SetString(PyExc_AttributeError, error.toLatin1().data());
1756 PyErr_SetString(PyExc_AttributeError, error.toLatin1().data());
1662 PythonQt::self()->handleError();
1757 PythonQt::self()->handleError();
1663 }
1758 }
1664
1759
1665 PyObject* PythonQt::helpCalled(PythonQtClassInfo* info)
1760 PyObject* PythonQt::helpCalled(PythonQtClassInfo* info)
1666 {
1761 {
1667 if (_p->_initFlags & ExternalHelp) {
1762 if (_p->_initFlags & ExternalHelp) {
1668 Q_EMIT pythonHelpRequest(QByteArray(info->className()));
1763 Q_EMIT pythonHelpRequest(QByteArray(info->className()));
1669 return Py_BuildValue("");
1764 return Py_BuildValue("");
1670 } else {
1765 } else {
1766 #ifdef PY3K
1767 return PyUnicode_FromString(info->help().toLatin1().data());
1768 #else
1671 return PyString_FromString(info->help().toLatin1().data());
1769 return PyString_FromString(info->help().toLatin1().data());
1770 #endif
1672 }
1771 }
1673 }
1772 }
1674
1773
1675 void PythonQt::clearNotFoundCachedMembers()
1774 void PythonQt::clearNotFoundCachedMembers()
1676 {
1775 {
1677 Q_FOREACH(PythonQtClassInfo* info, _p->_knownClassInfos) {
1776 Q_FOREACH(PythonQtClassInfo* info, _p->_knownClassInfos) {
1678 info->clearNotFoundCachedMembers();
1777 info->clearNotFoundCachedMembers();
1679 }
1778 }
1680 }
1779 }
1681
1780
1682 void PythonQt::removeWrapperFactory( PythonQtCppWrapperFactory* factory )
1781 void PythonQt::removeWrapperFactory( PythonQtCppWrapperFactory* factory )
1683 {
1782 {
1684 _p->_cppWrapperFactories.removeAll(factory);
1783 _p->_cppWrapperFactories.removeAll(factory);
1685 }
1784 }
1686
1785
1687 void PythonQt::removeWrapperFactory( PythonQtForeignWrapperFactory* factory )
1786 void PythonQt::removeWrapperFactory( PythonQtForeignWrapperFactory* factory )
1688 {
1787 {
1689 _p->_foreignWrapperFactories.removeAll(factory);
1788 _p->_foreignWrapperFactories.removeAll(factory);
1690 }
1789 }
1691
1790
1692 void PythonQtPrivate::removeWrapperPointer(void* obj)
1791 void PythonQtPrivate::removeWrapperPointer(void* obj)
1693 {
1792 {
1694 _wrappedObjects.remove(obj);
1793 _wrappedObjects.remove(obj);
1695 }
1794 }
1696
1795
1697 void PythonQtPrivate::addWrapperPointer(void* obj, PythonQtInstanceWrapper* wrapper)
1796 void PythonQtPrivate::addWrapperPointer(void* obj, PythonQtInstanceWrapper* wrapper)
1698 {
1797 {
1699 _wrappedObjects.insert(obj, wrapper);
1798 _wrappedObjects.insert(obj, wrapper);
1700 }
1799 }
1701
1800
1702 PythonQtInstanceWrapper* PythonQtPrivate::findWrapperAndRemoveUnused(void* obj)
1801 PythonQtInstanceWrapper* PythonQtPrivate::findWrapperAndRemoveUnused(void* obj)
1703 {
1802 {
1704 PythonQtInstanceWrapper* wrap = _wrappedObjects.value(obj);
1803 PythonQtInstanceWrapper* wrap = _wrappedObjects.value(obj);
1705 if (wrap && !wrap->_wrappedPtr && wrap->_obj == NULL) {
1804 if (wrap && !wrap->_wrappedPtr && wrap->_obj == NULL) {
1706 // this is a wrapper whose QObject was already removed due to destruction
1805 // this is a wrapper whose QObject was already removed due to destruction
1707 // so the obj pointer has to be a new QObject with the same address...
1806 // so the obj pointer has to be a new QObject with the same address...
1708 // we remove the old one and set the copy to NULL
1807 // we remove the old one and set the copy to NULL
1709 wrap->_objPointerCopy = NULL;
1808 wrap->_objPointerCopy = NULL;
1710 removeWrapperPointer(obj);
1809 removeWrapperPointer(obj);
1711 wrap = NULL;
1810 wrap = NULL;
1712 }
1811 }
1713 return wrap;
1812 return wrap;
1714 }
1813 }
1715
1814
1716 PythonQtObjectPtr PythonQtPrivate::createModule(const QString& name, PyObject* pycode)
1815 PythonQtObjectPtr PythonQtPrivate::createModule(const QString& name, PyObject* pycode)
1717 {
1816 {
1718 PythonQtObjectPtr result;
1817 PythonQtObjectPtr result;
1719 PythonQt::self()->clearError();
1818 PythonQt::self()->clearError();
1720 if (pycode) {
1819 if (pycode) {
1721 result.setNewRef(PyImport_ExecCodeModule((char*)name.toLatin1().data(), pycode));
1820 result.setNewRef(PyImport_ExecCodeModule((char*)name.toLatin1().data(), pycode));
1722 } else {
1821 } else {
1723 PythonQt::self()->handleError();
1822 PythonQt::self()->handleError();
1724 }
1823 }
1725 return result;
1824 return result;
1726 }
1825 }
1727
1826
1728 void* PythonQtPrivate::unwrapForeignWrapper( const QByteArray& classname, PyObject* obj )
1827 void* PythonQtPrivate::unwrapForeignWrapper( const QByteArray& classname, PyObject* obj )
1729 {
1828 {
1730 void* foreignObject = NULL;
1829 void* foreignObject = NULL;
1731 for (int i=0; i<_foreignWrapperFactories.size(); i++) {
1830 for (int i=0; i<_foreignWrapperFactories.size(); i++) {
1732 foreignObject = _foreignWrapperFactories.at(i)->unwrap(classname, obj);
1831 foreignObject = _foreignWrapperFactories.at(i)->unwrap(classname, obj);
1733 if (foreignObject) {
1832 if (foreignObject) {
1734 return foreignObject;
1833 return foreignObject;
1735 }
1834 }
1736 }
1835 }
1737 return NULL;
1836 return NULL;
1738 }
1837 }
1739
1838
1740 bool PythonQtPrivate::isMethodDescriptor(PyObject* object) const
1839 bool PythonQtPrivate::isMethodDescriptor(PyObject* object) const
1741 {
1840 {
1742 // This implementation is the same as in inspect.ismethoddescriptor(), inspect.py.
1841 // This implementation is the same as in inspect.ismethoddescriptor(), inspect.py.
1743 if (PyObject_HasAttrString(object, "__get__") &&
1842 if (PyObject_HasAttrString(object, "__get__") &&
1744 !PyObject_HasAttrString(object, "__set__") &&
1843 !PyObject_HasAttrString(object, "__set__") &&
1745 !PyMethod_Check(object) &&
1844 !PyMethod_Check(object) &&
1746 !PyFunction_Check(object) &&
1845 !PyFunction_Check(object)
1747 !PyClass_Check(object)) {
1846 #ifndef PY3K
1847 && !PyClass_Check(object)
1848 #endif
1849 ) {
1748 return true;
1850 return true;
1749 }
1851 }
1750 return false;
1852 return false;
1751 }
1853 }
1752
1854
1753 QString PythonQtPrivate::getSignature(PyObject* object)
1855 QString PythonQtPrivate::getSignature(PyObject* object)
1754 {
1856 {
1755 QString signature;
1857 QString signature;
1756
1858
1757 if (object) {
1859 if (object) {
1758 PyMethodObject* method = NULL;
1860 PyMethodObject* method = NULL;
1759 PyFunctionObject* func = NULL;
1861 PyFunctionObject* func = NULL;
1760
1862
1761 bool decrefMethod = false;
1863 bool decrefMethod = false;
1762
1864
1865 #ifdef PY3K
1866 if (PyType_Check(object)) {
1867 #else
1763 if (object->ob_type == &PyClass_Type || object->ob_type == &PyType_Type) {
1868 if (object->ob_type == &PyClass_Type || object->ob_type == &PyType_Type) {
1869 #endif
1764 method = (PyMethodObject*)PyObject_GetAttrString(object, "__init__");
1870 method = (PyMethodObject*)PyObject_GetAttrString(object, "__init__");
1765 decrefMethod = true;
1871 decrefMethod = true;
1766 } else if (object->ob_type == &PyFunction_Type) {
1872 } else if (object->ob_type == &PyFunction_Type) {
1767 func = (PyFunctionObject*)object;
1873 func = (PyFunctionObject*)object;
1768 } else if (object->ob_type == &PyMethod_Type) {
1874 } else if (object->ob_type == &PyMethod_Type) {
1769 method = (PyMethodObject*)object;
1875 method = (PyMethodObject*)object;
1770 }
1876 }
1771 if (method) {
1877 if (method) {
1772 if (PyFunction_Check(method->im_func)) {
1878 if (PyFunction_Check(method->im_func)) {
1773 func = (PyFunctionObject*)method->im_func;
1879 func = (PyFunctionObject*)method->im_func;
1774 } else if (isMethodDescriptor((PyObject*)method)) {
1880 } else if (isMethodDescriptor((PyObject*)method)) {
1775 QString docstr;
1881 QString docstr;
1776 PyObject* doc = PyObject_GetAttrString(object, "__doc__");
1882 PyObject* doc = PyObject_GetAttrString(object, "__doc__");
1777 if (doc) {
1883 if (doc) {
1884 #ifdef PY3K
1885 docstr = PyUnicode_AsUTF8(doc);
1886 #else
1778 docstr = PyString_AsString(doc);
1887 docstr = PyString_AsString(doc);
1888 #endif
1779 Py_DECREF(doc);
1889 Py_DECREF(doc);
1780 }
1890 }
1781
1891
1782 PyObject* s = PyObject_GetAttrString(object, "__name__");
1892 PyObject* s = PyObject_GetAttrString(object, "__name__");
1783 if (s) {
1893 if (s) {
1894 #ifdef PY3K
1895 Q_ASSERT(PyUnicode_Check(s));
1896 signature = PyUnicode_AsUTF8(s);
1897 #else
1784 Q_ASSERT(PyString_Check(s));
1898 Q_ASSERT(PyString_Check(s));
1785 signature = PyString_AsString(s);
1899 signature = PyString_AsString(s);
1900 #endif
1786 if (docstr.startsWith(signature + "(")) {
1901 if (docstr.startsWith(signature + "(")) {
1787 signature = docstr;
1902 signature = docstr;
1788 } else {
1903 } else {
1789 signature += "(...)";
1904 signature += "(...)";
1790 if (!docstr.isEmpty()) {
1905 if (!docstr.isEmpty()) {
1791 signature += "\n\n" + docstr;
1906 signature += "\n\n" + docstr;
1792 }
1907 }
1793 }
1908 }
1794 Py_DECREF(s);
1909 Py_DECREF(s);
1795 }
1910 }
1796 }
1911 }
1797 }
1912 }
1798
1913
1799 if (func) {
1914 if (func) {
1800 QString funcName;
1915 QString funcName;
1801 PyObject* s = PyObject_GetAttrString((PyObject*)func, "__name__");
1916 PyObject* s = PyObject_GetAttrString((PyObject*)func, "__name__");
1802 if (s) {
1917 if (s) {
1918 #ifdef PY3K
1919 Q_ASSERT(PyUnicode_Check(s));
1920 funcName = PyUnicode_AsUTF8(s);
1921 #else
1803 Q_ASSERT(PyString_Check(s));
1922 Q_ASSERT(PyString_Check(s));
1804 funcName = PyString_AsString(s);
1923 funcName = PyString_AsString(s);
1924 #endif
1805 Py_DECREF(s);
1925 Py_DECREF(s);
1806 }
1926 }
1807 if (method && funcName == "__init__") {
1927 if (method && funcName == "__init__") {
1808 PyObject* s = PyObject_GetAttrString(object, "__name__");
1928 PyObject* s = PyObject_GetAttrString(object, "__name__");
1809 if (s) {
1929 if (s) {
1930 #ifdef PY3K
1931 Q_ASSERT(PyUnicode_Check(s));
1932 funcName = PyUnicode_AsUTF8(s);
1933 #else
1810 Q_ASSERT(PyString_Check(s));
1934 Q_ASSERT(PyString_Check(s));
1811 funcName = PyString_AsString(s);
1935 funcName = PyString_AsString(s);
1936 #endif
1812 Py_DECREF(s);
1937 Py_DECREF(s);
1813 }
1938 }
1814 }
1939 }
1815
1940
1816 QStringList arguments;
1941 QStringList arguments;
1817 QStringList defaults;
1942 QStringList defaults;
1818 QString varargs;
1943 QString varargs;
1819 QString varkeywords;
1944 QString varkeywords;
1820 // NOTE: This implementation is based on function getargs() in inspect.py.
1945 // NOTE: This implementation is based on function getargs() in inspect.py.
1821 // inspect.getargs() can handle anonymous (tuple) arguments, while this code does not.
1946 // inspect.getargs() can handle anonymous (tuple) arguments, while this code does not.
1822 // It can be implemented, but it may be rarely needed and not necessary.
1947 // It can be implemented, but it may be rarely needed and not necessary.
1823 PyCodeObject* code = (PyCodeObject*)func->func_code;
1948 PyCodeObject* code = (PyCodeObject*)func->func_code;
1824 if (code->co_varnames) {
1949 if (code->co_varnames) {
1825 int nargs = code->co_argcount;
1950 int nargs = code->co_argcount;
1826 Q_ASSERT(PyTuple_Check(code->co_varnames));
1951 Q_ASSERT(PyTuple_Check(code->co_varnames));
1827 for (int i=0; i<nargs; i++) {
1952 for (int i=0; i<nargs; i++) {
1828 PyObject* name = PyTuple_GetItem(code->co_varnames, i);
1953 PyObject* name = PyTuple_GetItem(code->co_varnames, i);
1954 #ifdef PY3K
1955 Q_ASSERT(PyUnicode_Check(name));
1956 arguments << PyUnicode_AsUTF8(name);
1957 #else
1829 Q_ASSERT(PyString_Check(name));
1958 Q_ASSERT(PyString_Check(name));
1830 arguments << PyString_AsString(name);
1959 arguments << PyString_AsString(name);
1960 #endif
1831 }
1961 }
1832 if (code->co_flags & CO_VARARGS) {
1962 if (code->co_flags & CO_VARARGS) {
1833 PyObject* s = PyTuple_GetItem(code->co_varnames, nargs);
1963 PyObject* s = PyTuple_GetItem(code->co_varnames, nargs);
1964 #ifdef PY3K
1965 Q_ASSERT(PyUnicode_Check(s));
1966 varargs = PyUnicode_AsUTF8(s);
1967 #else
1834 Q_ASSERT(PyString_Check(s));
1968 Q_ASSERT(PyString_Check(s));
1835 varargs = PyString_AsString(s);
1969 varargs = PyString_AsString(s);
1970 #endif
1836 nargs += 1;
1971 nargs += 1;
1837 }
1972 }
1838 if (code->co_flags & CO_VARKEYWORDS) {
1973 if (code->co_flags & CO_VARKEYWORDS) {
1839 PyObject* s = PyTuple_GetItem(code->co_varnames, nargs);
1974 PyObject* s = PyTuple_GetItem(code->co_varnames, nargs);
1975 #ifdef PY3K
1976 Q_ASSERT(PyUnicode_Check(s));
1977 varkeywords = PyUnicode_AsUTF8(s);
1978 #else
1840 Q_ASSERT(PyString_Check(s));
1979 Q_ASSERT(PyString_Check(s));
1841 varkeywords = PyString_AsString(s);
1980 varkeywords = PyString_AsString(s);
1981 #endif
1842 }
1982 }
1843 }
1983 }
1844
1984
1845 PyObject* defaultsTuple = func->func_defaults;
1985 PyObject* defaultsTuple = func->func_defaults;
1846 if (defaultsTuple) {
1986 if (defaultsTuple) {
1847 Q_ASSERT(PyTuple_Check(defaultsTuple));
1987 Q_ASSERT(PyTuple_Check(defaultsTuple));
1848 for (Py_ssize_t i=0; i<PyTuple_Size(defaultsTuple); i++) {
1988 for (Py_ssize_t i=0; i<PyTuple_Size(defaultsTuple); i++) {
1849 PyObject* d = PyTuple_GetItem(defaultsTuple, i);
1989 PyObject* d = PyTuple_GetItem(defaultsTuple, i);
1850 PyObject* s = PyObject_Repr(d);
1990 PyObject* s = PyObject_Repr(d);
1991 #ifdef PY3K
1992 Q_ASSERT(PyUnicode_Check(s));
1993 defaults << PyUnicode_AsUTF8(s);
1994 #else
1851 Q_ASSERT(PyString_Check(s));
1995 Q_ASSERT(PyString_Check(s));
1852 defaults << PyString_AsString(s);
1996 defaults << PyString_AsString(s);
1997 #endif
1853 Py_DECREF(s);
1998 Py_DECREF(s);
1854 }
1999 }
1855 }
2000 }
1856
2001
1857 int firstdefault = arguments.size() - defaults.size();
2002 int firstdefault = arguments.size() - defaults.size();
1858 for (int i=0; i<arguments.size(); i++) {
2003 for (int i=0; i<arguments.size(); i++) {
1859 if (!signature.isEmpty()) { signature += ", "; }
2004 if (!signature.isEmpty()) { signature += ", "; }
1860 if (!method || i>0 || arguments[i] != "self") {
2005 if (!method || i>0 || arguments[i] != "self") {
1861 signature += arguments[i];
2006 signature += arguments[i];
1862 if (i >= firstdefault) {
2007 if (i >= firstdefault) {
1863 signature += "=" + defaults[i-firstdefault];
2008 signature += "=" + defaults[i-firstdefault];
1864 }
2009 }
1865 }
2010 }
1866 }
2011 }
1867 if (!varargs.isEmpty()) {
2012 if (!varargs.isEmpty()) {
1868 if (!signature.isEmpty()) { signature += ", "; }
2013 if (!signature.isEmpty()) { signature += ", "; }
1869 signature += "*" + varargs;
2014 signature += "*" + varargs;
1870 }
2015 }
1871 if (!varkeywords.isEmpty()) {
2016 if (!varkeywords.isEmpty()) {
1872 if (!signature.isEmpty()) { signature += ", "; }
2017 if (!signature.isEmpty()) { signature += ", "; }
1873 signature += "**" + varkeywords;
2018 signature += "**" + varkeywords;
1874 }
2019 }
1875 signature = funcName + "(" + signature + ")";
2020 signature = funcName + "(" + signature + ")";
1876 }
2021 }
1877
2022
1878 if (method && decrefMethod) {
2023 if (method && decrefMethod) {
1879 Py_DECREF(method);
2024 Py_DECREF(method);
1880 }
2025 }
1881 }
2026 }
1882
2027
1883 return signature;
2028 return signature;
1884 }
2029 }
1885
2030
1886 void PythonQtPrivate::shellClassDeleted( void* shellClass )
2031 void PythonQtPrivate::shellClassDeleted( void* shellClass )
1887 {
2032 {
1888 PythonQtInstanceWrapper* wrap = _wrappedObjects.value(shellClass);
2033 PythonQtInstanceWrapper* wrap = _wrappedObjects.value(shellClass);
1889 if (wrap && wrap->_wrappedPtr) {
2034 if (wrap && wrap->_wrappedPtr) {
1890 // this is a pure C++ wrapper and the shell has gone, so we need
2035 // this is a pure C++ wrapper and the shell has gone, so we need
1891 // to set the _wrappedPtr to NULL on the wrapper
2036 // to set the _wrappedPtr to NULL on the wrapper
1892 wrap->_wrappedPtr = NULL;
2037 wrap->_wrappedPtr = NULL;
1893 // and then we remove the wrapper, since the wrapped class is gone
2038 // and then we remove the wrapper, since the wrapped class is gone
1894 _wrappedObjects.remove(shellClass);
2039 _wrappedObjects.remove(shellClass);
1895 }
2040 }
1896 // if the wrapper is a QObject, we do not handle this here,
2041 // if the wrapper is a QObject, we do not handle this here,
1897 // it will be handled by the QPointer<> to the QObject, which becomes NULL
2042 // it will be handled by the QPointer<> to the QObject, which becomes NULL
1898 // via the QObject destructor.
2043 // via the QObject destructor.
1899 }
2044 }
1900
2045
1901 PyObject* PythonQtPrivate::wrapMemoryAsBuffer( const void* data, Py_ssize_t size )
2046 PyObject* PythonQtPrivate::wrapMemoryAsBuffer( const void* data, Py_ssize_t size )
1902 {
2047 {
1903 // P3K port needed later on!
2048 // P3K port needed later on! -- not anymore :D
1904 return PyBuffer_FromMemory((void*)data, size);
2049 #ifdef PY3K
2050 return PyMemoryView_FromMemory((char*)data, size, PyBUF_READ);
2051 #else
2052 return PyBuffer_FromMemory((char*)data, size);
2053 #endif
1905 }
2054 }
1906
2055
1907 PyObject* PythonQtPrivate::wrapMemoryAsBuffer( void* data, Py_ssize_t size )
2056 PyObject* PythonQtPrivate::wrapMemoryAsBuffer( void* data, Py_ssize_t size )
1908 {
2057 {
1909 // P3K port needed later on!
2058 // P3K port needed later on! -- not anymore :D
1910 return PyBuffer_FromReadWriteMemory(data, size);
2059 #ifdef PY3K
2060 return PyMemoryView_FromMemory((char*)data, size, PyBUF_READ | PyBUF_WRITE);
2061 #else
2062 return PyBuffer_FromReadWriteMemory((char*)data, size);
2063 #endif
1911 }
2064 }
@@ -1,481 +1,504
1 /*
1 /*
2 *
2 *
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
4 *
4 *
5 * This library is free software; you can redistribute it and/or
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
8 * version 2.1 of the License, or (at your option) any later version.
9 *
9 *
10 * This library is distributed in the hope that it will be useful,
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
13 * Lesser General Public License for more details.
14 *
14 *
15 * Further, this software is distributed without any warranty that it is
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
20 * other software, or any other product whatsoever.
21 *
21 *
22 * You should have received a copy of the GNU Lesser General Public
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
25 *
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
27 * 28359 Bremen, Germany or:
27 * 28359 Bremen, Germany or:
28 *
28 *
29 * http://www.mevis.de
29 * http://www.mevis.de
30 *
30 *
31 */
31 */
32
32
33 //----------------------------------------------------------------------------------
33 //----------------------------------------------------------------------------------
34 /*!
34 /*!
35 // \file PythonQtClassWrapper.cpp
35 // \file PythonQtClassWrapper.cpp
36 // \author Florian Link
36 // \author Florian Link
37 // \author Last changed by $Author: florian $
37 // \author Last changed by $Author: florian $
38 // \date 2006-05
38 // \date 2006-05
39 */
39 */
40 //----------------------------------------------------------------------------------
40 //----------------------------------------------------------------------------------
41
41
42 #include "PythonQtClassWrapper.h"
42 #include "PythonQtClassWrapper.h"
43 #include <QObject>
43 #include <QObject>
44
44
45 #include "PythonQt.h"
45 #include "PythonQt.h"
46 #include "PythonQtSlot.h"
46 #include "PythonQtSlot.h"
47 #include "PythonQtSignal.h"
47 #include "PythonQtSignal.h"
48 #include "PythonQtClassInfo.h"
48 #include "PythonQtClassInfo.h"
49 #include "PythonQtConversion.h"
49 #include "PythonQtConversion.h"
50 #include "PythonQtInstanceWrapper.h"
50 #include "PythonQtInstanceWrapper.h"
51
51
52 static PyObject* PythonQtInstanceWrapper_invert(PythonQtInstanceWrapper* wrapper)
52 static PyObject* PythonQtInstanceWrapper_invert(PythonQtInstanceWrapper* wrapper)
53 {
53 {
54 PyObject* result = NULL;
54 PyObject* result = NULL;
55 static QByteArray memberName = "__invert__";
55 static QByteArray memberName = "__invert__";
56 PythonQtMemberInfo opSlot = wrapper->classInfo()->member(memberName);
56 PythonQtMemberInfo opSlot = wrapper->classInfo()->member(memberName);
57 if (opSlot._type == PythonQtMemberInfo::Slot) {
57 if (opSlot._type == PythonQtMemberInfo::Slot) {
58 result = PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, opSlot._slot, NULL, NULL, wrapper->_wrappedPtr);
58 result = PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, opSlot._slot, NULL, NULL, wrapper->_wrappedPtr);
59 }
59 }
60 return result;
60 return result;
61 }
61 }
62
62
63 static int PythonQtInstanceWrapper_nonzero(PythonQtInstanceWrapper* wrapper)
63 static int PythonQtInstanceWrapper_nonzero(PythonQtInstanceWrapper* wrapper)
64 {
64 {
65 int result = (wrapper->_wrappedPtr == NULL && wrapper->_obj == NULL)?0:1;
65 int result = (wrapper->_wrappedPtr == NULL && wrapper->_obj == NULL)?0:1;
66 if (result) {
66 if (result) {
67 static QByteArray memberName = "__nonzero__";
67 static QByteArray memberName = "__nonzero__";
68 PythonQtMemberInfo opSlot = wrapper->classInfo()->member(memberName);
68 PythonQtMemberInfo opSlot = wrapper->classInfo()->member(memberName);
69 if (opSlot._type == PythonQtMemberInfo::Slot) {
69 if (opSlot._type == PythonQtMemberInfo::Slot) {
70 PyObject* resultObj = PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, opSlot._slot, NULL, NULL, wrapper->_wrappedPtr);
70 PyObject* resultObj = PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, opSlot._slot, NULL, NULL, wrapper->_wrappedPtr);
71 if (resultObj == Py_False) {
71 if (resultObj == Py_False) {
72 result = 0;
72 result = 0;
73 }
73 }
74 Py_XDECREF(resultObj);
74 Py_XDECREF(resultObj);
75 }
75 }
76 }
76 }
77 return result;
77 return result;
78 }
78 }
79
79
80
80
81 static PyObject* PythonQtInstanceWrapper_binaryfunc(PyObject* self, PyObject* other, const QByteArray& opName, const QByteArray& fallbackOpName = QByteArray())
81 static PyObject* PythonQtInstanceWrapper_binaryfunc(PyObject* self, PyObject* other, const QByteArray& opName, const QByteArray& fallbackOpName = QByteArray())
82 {
82 {
83 // since we disabled type checking, we can receive any object as self, but we currently only support
83 // since we disabled type checking, we can receive any object as self, but we currently only support
84 // different objects on the right. Otherwise we would need to generate __radd__ etc. methods.
84 // different objects on the right. Otherwise we would need to generate __radd__ etc. methods.
85 if (!PyObject_TypeCheck(self, &PythonQtInstanceWrapper_Type)) {
85 if (!PyObject_TypeCheck(self, &PythonQtInstanceWrapper_Type)) {
86 QString error = "Unsupported operation " + opName + "(" + self->ob_type->tp_name + ", " + other->ob_type->tp_name + ")";
86 QString error = "Unsupported operation " + opName + "(" + self->ob_type->tp_name + ", " + other->ob_type->tp_name + ")";
87 PyErr_SetString(PyExc_ArithmeticError, error.toLatin1().data());
87 PyErr_SetString(PyExc_ArithmeticError, error.toLatin1().data());
88 return NULL;
88 return NULL;
89 }
89 }
90 PythonQtInstanceWrapper* wrapper = (PythonQtInstanceWrapper*)self;
90 PythonQtInstanceWrapper* wrapper = (PythonQtInstanceWrapper*)self;
91 PyObject* result = NULL;
91 PyObject* result = NULL;
92 PythonQtMemberInfo opSlot = wrapper->classInfo()->member(opName);
92 PythonQtMemberInfo opSlot = wrapper->classInfo()->member(opName);
93 if (opSlot._type == PythonQtMemberInfo::Slot) {
93 if (opSlot._type == PythonQtMemberInfo::Slot) {
94 // TODO get rid of tuple
94 // TODO get rid of tuple
95 PyObject* args = PyTuple_New(1);
95 PyObject* args = PyTuple_New(1);
96 Py_INCREF(other);
96 Py_INCREF(other);
97 PyTuple_SET_ITEM(args, 0, other);
97 PyTuple_SET_ITEM(args, 0, other);
98 result = PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, opSlot._slot, args, NULL, wrapper->_wrappedPtr);
98 result = PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, opSlot._slot, args, NULL, wrapper->_wrappedPtr);
99 Py_DECREF(args);
99 Py_DECREF(args);
100 if (!result && !fallbackOpName.isEmpty()) {
100 if (!result && !fallbackOpName.isEmpty()) {
101 // try fallback if we did not get a result
101 // try fallback if we did not get a result
102 result = PythonQtInstanceWrapper_binaryfunc(self, other, fallbackOpName);
102 result = PythonQtInstanceWrapper_binaryfunc(self, other, fallbackOpName);
103 }
103 }
104 }
104 }
105 return result;
105 return result;
106 }
106 }
107
107
108 #define BINARY_OP(NAME) \
108 #define BINARY_OP(NAME) \
109 static PyObject* PythonQtInstanceWrapper_ ## NAME(PyObject* self, PyObject* other) \
109 static PyObject* PythonQtInstanceWrapper_ ## NAME(PyObject* self, PyObject* other) \
110 { \
110 { \
111 static const QByteArray opName("__" #NAME "__"); \
111 static const QByteArray opName("__" #NAME "__"); \
112 return PythonQtInstanceWrapper_binaryfunc(self, other, opName); \
112 return PythonQtInstanceWrapper_binaryfunc(self, other, opName); \
113 }
113 }
114
114
115 #define BINARY_OP_INPLACE(NAME) \
115 #define BINARY_OP_INPLACE(NAME) \
116 static PyObject* PythonQtInstanceWrapper_i ## NAME(PyObject* self, PyObject* other) \
116 static PyObject* PythonQtInstanceWrapper_i ## NAME(PyObject* self, PyObject* other) \
117 { \
117 { \
118 static const QByteArray opName("__i" #NAME "__"); \
118 static const QByteArray opName("__i" #NAME "__"); \
119 static const QByteArray fallbackName("__" #NAME "__"); \
119 static const QByteArray fallbackName("__" #NAME "__"); \
120 return PythonQtInstanceWrapper_binaryfunc(self, other, opName, fallbackName); \
120 return PythonQtInstanceWrapper_binaryfunc(self, other, opName, fallbackName); \
121 }
121 }
122
122
123 BINARY_OP(add)
123 BINARY_OP(add)
124 BINARY_OP(sub)
124 BINARY_OP(sub)
125 BINARY_OP(mul)
125 BINARY_OP(mul)
126 BINARY_OP(div)
126 BINARY_OP(div)
127 BINARY_OP(and)
127 BINARY_OP(and)
128 BINARY_OP(or)
128 BINARY_OP(or)
129 BINARY_OP(xor)
129 BINARY_OP(xor)
130 BINARY_OP(mod)
130 BINARY_OP(mod)
131 BINARY_OP(lshift)
131 BINARY_OP(lshift)
132 BINARY_OP(rshift)
132 BINARY_OP(rshift)
133
133
134 BINARY_OP_INPLACE(add)
134 BINARY_OP_INPLACE(add)
135 BINARY_OP_INPLACE(sub)
135 BINARY_OP_INPLACE(sub)
136 BINARY_OP_INPLACE(mul)
136 BINARY_OP_INPLACE(mul)
137 BINARY_OP_INPLACE(div)
137 BINARY_OP_INPLACE(div)
138 BINARY_OP_INPLACE(and)
138 BINARY_OP_INPLACE(and)
139 BINARY_OP_INPLACE(or)
139 BINARY_OP_INPLACE(or)
140 BINARY_OP_INPLACE(xor)
140 BINARY_OP_INPLACE(xor)
141 BINARY_OP_INPLACE(mod)
141 BINARY_OP_INPLACE(mod)
142 BINARY_OP_INPLACE(lshift)
142 BINARY_OP_INPLACE(lshift)
143 BINARY_OP_INPLACE(rshift)
143 BINARY_OP_INPLACE(rshift)
144
144
145 static void initializeSlots(PythonQtClassWrapper* wrap)
145 static void initializeSlots(PythonQtClassWrapper* wrap)
146 {
146 {
147 int typeSlots = wrap->classInfo()->typeSlots();
147 int typeSlots = wrap->classInfo()->typeSlots();
148 if (typeSlots) {
148 if (typeSlots) {
149 if (typeSlots & PythonQt::Type_Add) {
149 if (typeSlots & PythonQt::Type_Add) {
150 wrap->_base.as_number.nb_add = (binaryfunc)PythonQtInstanceWrapper_add;
150 wrap->_base.as_number.nb_add = (binaryfunc)PythonQtInstanceWrapper_add;
151 }
151 }
152 if (typeSlots & PythonQt::Type_Subtract) {
152 if (typeSlots & PythonQt::Type_Subtract) {
153 wrap->_base.as_number.nb_subtract = (binaryfunc)PythonQtInstanceWrapper_sub;
153 wrap->_base.as_number.nb_subtract = (binaryfunc)PythonQtInstanceWrapper_sub;
154 }
154 }
155 if (typeSlots & PythonQt::Type_Multiply) {
155 if (typeSlots & PythonQt::Type_Multiply) {
156 wrap->_base.as_number.nb_multiply = (binaryfunc)PythonQtInstanceWrapper_mul;
156 wrap->_base.as_number.nb_multiply = (binaryfunc)PythonQtInstanceWrapper_mul;
157 }
157 }
158 if (typeSlots & PythonQt::Type_Divide) {
158 if (typeSlots & PythonQt::Type_Divide) {
159 #ifndef PY3K
159 wrap->_base.as_number.nb_divide = (binaryfunc)PythonQtInstanceWrapper_div;
160 wrap->_base.as_number.nb_divide = (binaryfunc)PythonQtInstanceWrapper_div;
161 #endif
160 wrap->_base.as_number.nb_true_divide = (binaryfunc)PythonQtInstanceWrapper_div;
162 wrap->_base.as_number.nb_true_divide = (binaryfunc)PythonQtInstanceWrapper_div;
161 }
163 }
162 if (typeSlots & PythonQt::Type_And) {
164 if (typeSlots & PythonQt::Type_And) {
163 wrap->_base.as_number.nb_and = (binaryfunc)PythonQtInstanceWrapper_and;
165 wrap->_base.as_number.nb_and = (binaryfunc)PythonQtInstanceWrapper_and;
164 }
166 }
165 if (typeSlots & PythonQt::Type_Or) {
167 if (typeSlots & PythonQt::Type_Or) {
166 wrap->_base.as_number.nb_or = (binaryfunc)PythonQtInstanceWrapper_or;
168 wrap->_base.as_number.nb_or = (binaryfunc)PythonQtInstanceWrapper_or;
167 }
169 }
168 if (typeSlots & PythonQt::Type_Xor) {
170 if (typeSlots & PythonQt::Type_Xor) {
169 wrap->_base.as_number.nb_xor = (binaryfunc)PythonQtInstanceWrapper_xor;
171 wrap->_base.as_number.nb_xor = (binaryfunc)PythonQtInstanceWrapper_xor;
170 }
172 }
171 if (typeSlots & PythonQt::Type_Mod) {
173 if (typeSlots & PythonQt::Type_Mod) {
172 wrap->_base.as_number.nb_remainder = (binaryfunc)PythonQtInstanceWrapper_mod;
174 wrap->_base.as_number.nb_remainder = (binaryfunc)PythonQtInstanceWrapper_mod;
173 }
175 }
174 if (typeSlots & PythonQt::Type_LShift) {
176 if (typeSlots & PythonQt::Type_LShift) {
175 wrap->_base.as_number.nb_lshift = (binaryfunc)PythonQtInstanceWrapper_lshift;
177 wrap->_base.as_number.nb_lshift = (binaryfunc)PythonQtInstanceWrapper_lshift;
176 }
178 }
177 if (typeSlots & PythonQt::Type_RShift) {
179 if (typeSlots & PythonQt::Type_RShift) {
178 wrap->_base.as_number.nb_rshift = (binaryfunc)PythonQtInstanceWrapper_rshift;
180 wrap->_base.as_number.nb_rshift = (binaryfunc)PythonQtInstanceWrapper_rshift;
179 }
181 }
180
182
181 if (typeSlots & PythonQt::Type_InplaceAdd) {
183 if (typeSlots & PythonQt::Type_InplaceAdd) {
182 wrap->_base.as_number.nb_add = (binaryfunc)PythonQtInstanceWrapper_iadd;
184 wrap->_base.as_number.nb_add = (binaryfunc)PythonQtInstanceWrapper_iadd;
183 }
185 }
184 if (typeSlots & PythonQt::Type_InplaceSubtract) {
186 if (typeSlots & PythonQt::Type_InplaceSubtract) {
185 wrap->_base.as_number.nb_subtract = (binaryfunc)PythonQtInstanceWrapper_isub;
187 wrap->_base.as_number.nb_subtract = (binaryfunc)PythonQtInstanceWrapper_isub;
186 }
188 }
187 if (typeSlots & PythonQt::Type_InplaceMultiply) {
189 if (typeSlots & PythonQt::Type_InplaceMultiply) {
188 wrap->_base.as_number.nb_multiply = (binaryfunc)PythonQtInstanceWrapper_imul;
190 wrap->_base.as_number.nb_multiply = (binaryfunc)PythonQtInstanceWrapper_imul;
189 }
191 }
190 if (typeSlots & PythonQt::Type_InplaceDivide) {
192 if (typeSlots & PythonQt::Type_InplaceDivide) {
193 #ifndef PY3K
191 wrap->_base.as_number.nb_inplace_divide = (binaryfunc)PythonQtInstanceWrapper_idiv;
194 wrap->_base.as_number.nb_inplace_divide = (binaryfunc)PythonQtInstanceWrapper_idiv;
195 #endif
192 wrap->_base.as_number.nb_inplace_true_divide = (binaryfunc)PythonQtInstanceWrapper_idiv;
196 wrap->_base.as_number.nb_inplace_true_divide = (binaryfunc)PythonQtInstanceWrapper_idiv;
193 }
197 }
194 if (typeSlots & PythonQt::Type_InplaceAnd) {
198 if (typeSlots & PythonQt::Type_InplaceAnd) {
195 wrap->_base.as_number.nb_inplace_and = (binaryfunc)PythonQtInstanceWrapper_iand;
199 wrap->_base.as_number.nb_inplace_and = (binaryfunc)PythonQtInstanceWrapper_iand;
196 }
200 }
197 if (typeSlots & PythonQt::Type_InplaceOr) {
201 if (typeSlots & PythonQt::Type_InplaceOr) {
198 wrap->_base.as_number.nb_inplace_or = (binaryfunc)PythonQtInstanceWrapper_ior;
202 wrap->_base.as_number.nb_inplace_or = (binaryfunc)PythonQtInstanceWrapper_ior;
199 }
203 }
200 if (typeSlots & PythonQt::Type_InplaceXor) {
204 if (typeSlots & PythonQt::Type_InplaceXor) {
201 wrap->_base.as_number.nb_inplace_xor = (binaryfunc)PythonQtInstanceWrapper_ixor;
205 wrap->_base.as_number.nb_inplace_xor = (binaryfunc)PythonQtInstanceWrapper_ixor;
202 }
206 }
203 if (typeSlots & PythonQt::Type_InplaceMod) {
207 if (typeSlots & PythonQt::Type_InplaceMod) {
204 wrap->_base.as_number.nb_inplace_remainder = (binaryfunc)PythonQtInstanceWrapper_imod;
208 wrap->_base.as_number.nb_inplace_remainder = (binaryfunc)PythonQtInstanceWrapper_imod;
205 }
209 }
206 if (typeSlots & PythonQt::Type_InplaceLShift) {
210 if (typeSlots & PythonQt::Type_InplaceLShift) {
207 wrap->_base.as_number.nb_inplace_lshift = (binaryfunc)PythonQtInstanceWrapper_ilshift;
211 wrap->_base.as_number.nb_inplace_lshift = (binaryfunc)PythonQtInstanceWrapper_ilshift;
208 }
212 }
209 if (typeSlots & PythonQt::Type_InplaceRShift) {
213 if (typeSlots & PythonQt::Type_InplaceRShift) {
210 wrap->_base.as_number.nb_inplace_rshift = (binaryfunc)PythonQtInstanceWrapper_irshift;
214 wrap->_base.as_number.nb_inplace_rshift = (binaryfunc)PythonQtInstanceWrapper_irshift;
211 }
215 }
212 if (typeSlots & PythonQt::Type_Invert) {
216 if (typeSlots & PythonQt::Type_Invert) {
213 wrap->_base.as_number.nb_invert = (unaryfunc)PythonQtInstanceWrapper_invert;
217 wrap->_base.as_number.nb_invert = (unaryfunc)PythonQtInstanceWrapper_invert;
214 }
218 }
215 if (typeSlots & PythonQt::Type_NonZero) {
219 if (typeSlots & PythonQt::Type_NonZero) {
220 #ifdef PY3K
221 wrap->_base.as_number.nb_bool = (inquiry)PythonQtInstanceWrapper_nonzero;
222 #else
216 wrap->_base.as_number.nb_nonzero = (inquiry)PythonQtInstanceWrapper_nonzero;
223 wrap->_base.as_number.nb_nonzero = (inquiry)PythonQtInstanceWrapper_nonzero;
224 #endif
217 }
225 }
218 }
226 }
219 }
227 }
220
228
221 static PyObject* PythonQtClassWrapper_alloc(PyTypeObject *self, Py_ssize_t nitems)
229 static PyObject* PythonQtClassWrapper_alloc(PyTypeObject *self, Py_ssize_t nitems)
222 {
230 {
223 // call the default type alloc
231 // call the default type alloc
224 PyObject* obj = PyType_Type.tp_alloc(self, nitems);
232 PyObject* obj = PyType_Type.tp_alloc(self, nitems);
225
233
226 // take current class type, if we are called via newPythonQtClassWrapper()
234 // take current class type, if we are called via newPythonQtClassWrapper()
227 PythonQtClassWrapper* wrap = (PythonQtClassWrapper*)obj;
235 PythonQtClassWrapper* wrap = (PythonQtClassWrapper*)obj;
228 wrap->_classInfo = PythonQt::priv()->currentClassInfoForClassWrapperCreation();
236 wrap->_classInfo = PythonQt::priv()->currentClassInfoForClassWrapperCreation();
229 if (wrap->_classInfo) {
237 if (wrap->_classInfo) {
230 initializeSlots(wrap);
238 initializeSlots(wrap);
231 }
239 }
232
240
233 return obj;
241 return obj;
234 }
242 }
235
243
236
244
237 static int PythonQtClassWrapper_init(PythonQtClassWrapper* self, PyObject* args, PyObject* kwds)
245 static int PythonQtClassWrapper_init(PythonQtClassWrapper* self, PyObject* args, PyObject* kwds)
238 {
246 {
239 // call the default type init
247 // call the default type init
240 if (PyType_Type.tp_init((PyObject *)self, args, kwds) < 0) {
248 if (PyType_Type.tp_init((PyObject *)self, args, kwds) < 0) {
241 return -1;
249 return -1;
242 }
250 }
243
251
244 // if we have no CPP class information, try our base class
252 // if we have no CPP class information, try our base class
245 if (!self->classInfo()) {
253 if (!self->classInfo()) {
246 PyTypeObject* superType = ((PyTypeObject *)self)->tp_base;
254 PyTypeObject* superType = ((PyTypeObject *)self)->tp_base;
247
255
248 // recursively search for PythonQtClassWrapper superclass,
256 // recursively search for PythonQtClassWrapper superclass,
249 // this is needed for multiple levels of inheritance in python,
257 // this is needed for multiple levels of inheritance in python,
250 // e.g.
258 // e.g.
251 // class MyWidgetBase(QWidget):
259 // class MyWidgetBase(QWidget):
252 // ...
260 // ...
253 // class MyWidget(MyWidgetBase):
261 // class MyWidget(MyWidgetBase):
254 // ...
262 // ...
255 while( superType && superType->ob_type != &PythonQtClassWrapper_Type )
263 while( superType && Py_TYPE(superType) != &PythonQtClassWrapper_Type )
256 superType = superType->tp_base;
264 superType = superType->tp_base;
257
265
258 if (!superType || (superType->ob_type != &PythonQtClassWrapper_Type)) {
266 if (!superType || (Py_TYPE(superType) != &PythonQtClassWrapper_Type)) {
259 PyErr_Format(PyExc_TypeError, "type %s is not derived from PythonQtClassWrapper", ((PyTypeObject*)self)->tp_name);
267 PyErr_Format(PyExc_TypeError, "type %s is not derived from PythonQtClassWrapper", ((PyTypeObject*)self)->tp_name);
260 return -1;
268 return -1;
261 }
269 }
262
270
263 // take the class info from the superType
271 // take the class info from the superType
264 self->_classInfo = ((PythonQtClassWrapper*)superType)->classInfo();
272 self->_classInfo = ((PythonQtClassWrapper*)superType)->classInfo();
265 }
273 }
266
274
267 return 0;
275 return 0;
268 }
276 }
269
277
270 static PyObject *PythonQtClassWrapper_classname(PythonQtClassWrapper* type)
278 static PyObject *PythonQtClassWrapper_classname(PythonQtClassWrapper* type)
271 {
279 {
280 #ifdef PY3K
281 return PyUnicode_FromString((QString("Class_") + type->classInfo()->className()).toLatin1().data());
282 #else
272 return PyString_FromString((QString("Class_") + type->classInfo()->className()).toLatin1().data());
283 return PyString_FromString((QString("Class_") + type->classInfo()->className()).toLatin1().data());
284 #endif
273 }
285 }
274
286
275 static PyObject *PythonQtClassWrapper_help(PythonQtClassWrapper* type)
287 static PyObject *PythonQtClassWrapper_help(PythonQtClassWrapper* type)
276 {
288 {
277 return PythonQt::self()->helpCalled(type->classInfo());
289 return PythonQt::self()->helpCalled(type->classInfo());
278 }
290 }
279
291
280 PyObject *PythonQtClassWrapper_delete(PythonQtClassWrapper *type, PyObject *args)
292 PyObject *PythonQtClassWrapper_delete(PythonQtClassWrapper *type, PyObject *args)
281 {
293 {
282 Q_UNUSED(type);
294 Q_UNUSED(type);
283
295
284 Py_ssize_t argc = PyTuple_Size(args);
296 Py_ssize_t argc = PyTuple_Size(args);
285 if (argc>0) {
297 if (argc>0) {
286 PyObject* self = PyTuple_GET_ITEM(args, 0);
298 PyObject* self = PyTuple_GET_ITEM(args, 0);
287 if (PyObject_TypeCheck(self, &PythonQtInstanceWrapper_Type)) {
299 if (PyObject_TypeCheck(self, &PythonQtInstanceWrapper_Type)) {
288 return PythonQtInstanceWrapper_delete((PythonQtInstanceWrapper*)self);
300 return PythonQtInstanceWrapper_delete((PythonQtInstanceWrapper*)self);
289 }
301 }
290 }
302 }
291 return NULL;
303 return NULL;
292 }
304 }
293
305
294 PyObject *PythonQtClassWrapper_inherits(PythonQtClassWrapper *type, PyObject *args)
306 PyObject *PythonQtClassWrapper_inherits(PythonQtClassWrapper *type, PyObject *args)
295 {
307 {
296 Q_UNUSED(type);
308 Q_UNUSED(type);
297 PythonQtInstanceWrapper* wrapper = NULL;
309 PythonQtInstanceWrapper* wrapper = NULL;
298 char *name = NULL;
310 char *name = NULL;
299 if (!PyArg_ParseTuple(args, "O!s:PythonQtClassWrapper.inherits",&PythonQtInstanceWrapper_Type, &wrapper, &name)) {
311 if (!PyArg_ParseTuple(args, "O!s:PythonQtClassWrapper.inherits",&PythonQtInstanceWrapper_Type, &wrapper, &name)) {
300 return NULL;
312 return NULL;
301 }
313 }
302 return PythonQtConv::GetPyBool(wrapper->classInfo()->inherits(name));
314 return PythonQtConv::GetPyBool(wrapper->classInfo()->inherits(name));
303 }
315 }
304
316
305
317
306 static PyMethodDef PythonQtClassWrapper_methods[] = {
318 static PyMethodDef PythonQtClassWrapper_methods[] = {
307 {"className", (PyCFunction)PythonQtClassWrapper_classname, METH_NOARGS,
319 {"className", (PyCFunction)PythonQtClassWrapper_classname, METH_NOARGS,
308 "Return the classname of the object"
320 "Return the classname of the object"
309 },
321 },
310 {"inherits", (PyCFunction)PythonQtClassWrapper_inherits, METH_VARARGS,
322 {"inherits", (PyCFunction)PythonQtClassWrapper_inherits, METH_VARARGS,
311 "Returns if the class inherits or is of given type name"
323 "Returns if the class inherits or is of given type name"
312 },
324 },
313 {"help", (PyCFunction)PythonQtClassWrapper_help, METH_NOARGS,
325 {"help", (PyCFunction)PythonQtClassWrapper_help, METH_NOARGS,
314 "Shows the help of available methods for this class"
326 "Shows the help of available methods for this class"
315 },
327 },
316 {"delete", (PyCFunction)PythonQtClassWrapper_delete, METH_VARARGS,
328 {"delete", (PyCFunction)PythonQtClassWrapper_delete, METH_VARARGS,
317 "Deletes the given C++ object"
329 "Deletes the given C++ object"
318 },
330 },
319 {NULL, NULL, 0 , NULL} /* Sentinel */
331 {NULL, NULL, 0 , NULL} /* Sentinel */
320 };
332 };
321
333
322
334
323 static PyObject *PythonQtClassWrapper_getattro(PyObject *obj, PyObject *name)
335 static PyObject *PythonQtClassWrapper_getattro(PyObject *obj, PyObject *name)
324 {
336 {
325 const char *attributeName;
337 const char *attributeName;
326 PythonQtClassWrapper *wrapper = (PythonQtClassWrapper *)obj;
338 PythonQtClassWrapper *wrapper = (PythonQtClassWrapper *)obj;
327
339
340 #ifdef PY3K
341 if ((attributeName = PyUnicode_AsUTF8(name)) == NULL) {
342 #else
328 if ((attributeName = PyString_AsString(name)) == NULL) {
343 if ((attributeName = PyString_AsString(name)) == NULL) {
344 #endif
329 return NULL;
345 return NULL;
330 }
346 }
331 if (obj == (PyObject*)&PythonQtInstanceWrapper_Type) {
347 if (obj == (PyObject*)&PythonQtInstanceWrapper_Type) {
332 return NULL;
348 return NULL;
333 }
349 }
334
350
335 if (qstrcmp(attributeName, "__dict__")==0) {
351 if (qstrcmp(attributeName, "__dict__")==0) {
336 PyObject* objectDict = ((PyTypeObject *)wrapper)->tp_dict;
352 PyObject* objectDict = ((PyTypeObject *)wrapper)->tp_dict;
337 if (!wrapper->classInfo()) {
353 if (!wrapper->classInfo()) {
338 Py_INCREF(objectDict);
354 Py_INCREF(objectDict);
339 return objectDict;
355 return objectDict;
340 }
356 }
341 PyObject* dict = PyDict_New();
357 PyObject* dict = PyDict_New();
342
358
343 QStringList l = wrapper->classInfo()->memberList();
359 QStringList l = wrapper->classInfo()->memberList();
344 Q_FOREACH (QString name, l) {
360 Q_FOREACH (QString name, l) {
345 PyObject* o = PyObject_GetAttrString(obj, name.toLatin1().data());
361 PyObject* o = PyObject_GetAttrString(obj, name.toLatin1().data());
346 if (o) {
362 if (o) {
347 PyDict_SetItemString(dict, name.toLatin1().data(), o);
363 PyDict_SetItemString(dict, name.toLatin1().data(), o);
348 Py_DECREF(o);
364 Py_DECREF(o);
349 } else {
365 } else {
350 // it must have been a property or child, which we do not know as a class object...
366 // it must have been a property or child, which we do not know as a class object...
351 PyErr_Clear();
367 PyErr_Clear();
352 }
368 }
353 }
369 }
354 if (wrapper->classInfo()->constructors()) {
370 if (wrapper->classInfo()->constructors()) {
371 #ifdef PY3K
372 PyObject* initName = PyUnicode_FromString("__init__");
373 #else
355 PyObject* initName = PyString_FromString("__init__");
374 PyObject* initName = PyString_FromString("__init__");
375 #endif
356 PyObject* func = PyType_Type.tp_getattro(obj, initName);
376 PyObject* func = PyType_Type.tp_getattro(obj, initName);
357 Py_DECREF(initName);
377 Py_DECREF(initName);
358 PyDict_SetItemString(dict, "__init__", func);
378 PyDict_SetItemString(dict, "__init__", func);
359 Py_DECREF(func);
379 Py_DECREF(func);
360 }
380 }
361 for (int i = 0; PythonQtClassWrapper_methods[i].ml_name != NULL; i++) {
381 for (int i = 0; PythonQtClassWrapper_methods[i].ml_name != NULL; i++) {
362 PyObject* func = PyCFunction_New(&PythonQtClassWrapper_methods[i], obj);
382 PyObject* func = PyCFunction_New(&PythonQtClassWrapper_methods[i], obj);
363 PyDict_SetItemString(dict, PythonQtClassWrapper_methods[i].ml_name, func);
383 PyDict_SetItemString(dict, PythonQtClassWrapper_methods[i].ml_name, func);
364 Py_DECREF(func);
384 Py_DECREF(func);
365 }
385 }
366
386
367 PyDict_Update(dict, objectDict);
387 PyDict_Update(dict, objectDict);
368 return dict;
388 return dict;
369 }
389 }
370
390
371 // look in Python to support derived Python classes
391 // look in Python to support derived Python classes
392 #ifdef PY3K
393 return PyObject_GenericGetAttr(obj, name);
394 #else
372 PyObject* superAttr = PyType_Type.tp_getattro(obj, name);
395 PyObject* superAttr = PyType_Type.tp_getattro(obj, name);
373 if (superAttr) {
396 if (superAttr) {
374 return superAttr;
397 return superAttr;
375 }
398 }
376 PyErr_Clear();
399 PyErr_Clear();
377
400
378 if (wrapper->classInfo()) {
401 if (wrapper->classInfo()) {
379 PythonQtMemberInfo member = wrapper->classInfo()->member(attributeName);
402 PythonQtMemberInfo member = wrapper->classInfo()->member(attributeName);
380 if (member._type == PythonQtMemberInfo::EnumValue) {
403 if (member._type == PythonQtMemberInfo::EnumValue) {
381 PyObject* enumValue = member._enumValue;
404 PyObject* enumValue = member._enumValue;
382 Py_INCREF(enumValue);
405 Py_INCREF(enumValue);
383 return enumValue;
406 return enumValue;
384 } else if (member._type == PythonQtMemberInfo::EnumWrapper) {
407 } else if (member._type == PythonQtMemberInfo::EnumWrapper) {
385 PyObject* enumWrapper = member._enumWrapper;
408 PyObject* enumWrapper = member._enumWrapper;
386 Py_INCREF(enumWrapper);
409 Py_INCREF(enumWrapper);
387 return enumWrapper;
410 return enumWrapper;
388 } else if (member._type == PythonQtMemberInfo::Slot) {
411 } else if (member._type == PythonQtMemberInfo::Slot) {
389 // we return all slots, even the instance slots, since they are callable as unbound slots with self argument
412 // we return all slots, even the instance slots, since they are callable as unbound slots with self argument
390 return PythonQtSlotFunction_New(member._slot, obj, NULL);
413 return PythonQtSlotFunction_New(member._slot, obj, NULL);
391 } else if (member._type == PythonQtMemberInfo::Signal) {
414 } else if (member._type == PythonQtMemberInfo::Signal) {
392 // we return all signals, even the instance signals, since they are callable as unbound signals with self argument
415 // we return all signals, even the instance signals, since they are callable as unbound signals with self argument
393 return PythonQtSignalFunction_New(member._slot, obj, NULL);
416 return PythonQtSignalFunction_New(member._slot, obj, NULL);
394 }
417 }
395 }
418 }
396
419
397 // look for the internal methods (className(), help())
420 // look for the internal methods (className(), help())
398 PyObject* internalMethod = Py_FindMethod( PythonQtClassWrapper_methods, obj, (char*)attributeName);
421 PyObject* internalMethod = Py_FindMethod( PythonQtClassWrapper_methods, obj, (char*)attributeName);
399 if (internalMethod) {
422 if (internalMethod) {
400 return internalMethod;
423 return internalMethod;
401 }
424 }
402
425
403 QString error = QString(wrapper->classInfo()->className()) + " has no attribute named '" + QString(attributeName) + "'";
426 QString error = QString(wrapper->classInfo()->className()) + " has no attribute named '" + QString(attributeName) + "'";
404 PyErr_SetString(PyExc_AttributeError, error.toLatin1().data());
427 PyErr_SetString(PyExc_AttributeError, error.toLatin1().data());
405 return NULL;
428 return NULL;
429 #endif
406 }
430 }
407
431
408 static int PythonQtClassWrapper_setattro(PyObject *obj,PyObject *name,PyObject *value)
432 static int PythonQtClassWrapper_setattro(PyObject *obj,PyObject *name,PyObject *value)
409 {
433 {
410 return PyType_Type.tp_setattro(obj,name,value);
434 return PyType_Type.tp_setattro(obj,name,value);
411 }
435 }
412
436
413 /*
437 /*
414 static PyObject * PythonQtClassWrapper_repr(PyObject * obj)
438 static PyObject * PythonQtClassWrapper_repr(PyObject * obj)
415 {
439 {
416 PythonQtClassWrapper* wrapper = (PythonQtClassWrapper*)obj;
440 PythonQtClassWrapper* wrapper = (PythonQtClassWrapper*)obj;
417 if (wrapper->classInfo()->isCPPWrapper()) {
441 if (wrapper->classInfo()->isCPPWrapper()) {
418 const QMetaObject* meta = wrapper->classInfo()->metaObject();
442 const QMetaObject* meta = wrapper->classInfo()->metaObject();
419 if (!meta) {
443 if (!meta) {
420 QObject* decorator = wrapper->classInfo()->decorator();
444 QObject* decorator = wrapper->classInfo()->decorator();
421 if (decorator) {
445 if (decorator) {
422 meta = decorator->metaObject();
446 meta = decorator->metaObject();
423 }
447 }
424 }
448 }
425 if (meta) {
449 if (meta) {
426 return PyString_FromFormat("%s Class (C++ wrapped by %s)", wrapper->classInfo()->className(), meta->className());
450 return PyString_FromFormat("%s Class (C++ wrapped by %s)", wrapper->classInfo()->className(), meta->className());
427 } else {
451 } else {
428 return PyString_FromFormat("%s Class (C++ unwrapped)", wrapper->classInfo()->className());
452 return PyString_FromFormat("%s Class (C++ unwrapped)", wrapper->classInfo()->className());
429 }
453 }
430 } else {
454 } else {
431 return PyString_FromFormat("%s Class", wrapper->classInfo()->className());
455 return PyString_FromFormat("%s Class", wrapper->classInfo()->className());
432 }
456 }
433 }
457 }
434
458
435 */
459 */
436
460
437 PyTypeObject PythonQtClassWrapper_Type = {
461 PyTypeObject PythonQtClassWrapper_Type = {
438 PyObject_HEAD_INIT(NULL)
462 PyVarObject_HEAD_INIT(NULL, 0)
439 0, /*ob_size*/
440 "PythonQt.PythonQtClassWrapper", /*tp_name*/
463 "PythonQt.PythonQtClassWrapper", /*tp_name*/
441 sizeof(PythonQtClassWrapper), /*tp_basicsize*/
464 sizeof(PythonQtClassWrapper), /*tp_basicsize*/
442 0, /*tp_itemsize*/
465 0, /*tp_itemsize*/
443 0, /*tp_dealloc*/
466 0, /*tp_dealloc*/
444 0, /*tp_print*/
467 0, /*tp_print*/
445 0, /*tp_getattr*/
468 0, /*tp_getattr*/
446 0, /*tp_setattr*/
469 0, /*tp_setattr*/
447 0, /*tp_compare*/
470 0, /*tp_compare*/
448 0, //PythonQtClassWrapper_repr, /*tp_repr*/
471 0, //PythonQtClassWrapper_repr, /*tp_repr*/
449 0, /*tp_as_number*/
472 0, /*tp_as_number*/
450 0, /*tp_as_sequence*/
473 0, /*tp_as_sequence*/
451 0, /*tp_as_mapping*/
474 0, /*tp_as_mapping*/
452 0, /*tp_hash */
475 0, /*tp_hash */
453 0, /*tp_call*/
476 0, /*tp_call*/
454 0, /*tp_str*/
477 0, /*tp_str*/
455 PythonQtClassWrapper_getattro, /*tp_getattro*/
478 PythonQtClassWrapper_getattro, /*tp_getattro*/
456 PythonQtClassWrapper_setattro, /*tp_setattro*/
479 PythonQtClassWrapper_setattro, /*tp_setattro*/
457 0, /*tp_as_buffer*/
480 0, /*tp_as_buffer*/
458 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, /*tp_flags*/
481 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, /*tp_flags*/
459 0, /* tp_doc */
482 0, /* tp_doc */
460 0, /* tp_traverse */
483 0, /* tp_traverse */
461 0, /* tp_clear */
484 0, /* tp_clear */
462 0, /* tp_richcompare */
485 0, /* tp_richcompare */
463 0, /* tp_weaklistoffset */
486 0, /* tp_weaklistoffset */
464 0, /* tp_iter */
487 0, /* tp_iter */
465 0, /* tp_iternext */
488 0, /* tp_iternext */
466 0, /* tp_methods */
489 0, /* tp_methods */
467 0, /* tp_members */
490 0, /* tp_members */
468 0, /* tp_getset */
491 0, /* tp_getset */
469 0, /* tp_base */
492 0, /* tp_base */
470 0, /* tp_dict */
493 0, /* tp_dict */
471 0, /* tp_descr_get */
494 0, /* tp_descr_get */
472 0, /* tp_descr_set */
495 0, /* tp_descr_set */
473 0, /* tp_dictoffset */
496 0, /* tp_dictoffset */
474 (initproc)PythonQtClassWrapper_init, /* tp_init */
497 (initproc)PythonQtClassWrapper_init, /* tp_init */
475 PythonQtClassWrapper_alloc, /* tp_alloc */
498 PythonQtClassWrapper_alloc, /* tp_alloc */
476 0, /* tp_new */
499 0, /* tp_new */
477 0, /* tp_free */
500 0, /* tp_free */
478 };
501 };
479
502
480 //-------------------------------------------------------
503 //-------------------------------------------------------
481
504
@@ -1,1295 +1,1378
1 /*
1 /*
2 *
2 *
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
4 *
4 *
5 * This library is free software; you can redistribute it and/or
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
8 * version 2.1 of the License, or (at your option) any later version.
9 *
9 *
10 * This library is distributed in the hope that it will be useful,
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
13 * Lesser General Public License for more details.
14 *
14 *
15 * Further, this software is distributed without any warranty that it is
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
20 * other software, or any other product whatsoever.
21 *
21 *
22 * You should have received a copy of the GNU Lesser General Public
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
25 *
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
27 * 28359 Bremen, Germany or:
27 * 28359 Bremen, Germany or:
28 *
28 *
29 * http://www.mevis.de
29 * http://www.mevis.de
30 *
30 *
31 */
31 */
32
32
33 //----------------------------------------------------------------------------------
33 //----------------------------------------------------------------------------------
34 /*!
34 /*!
35 // \file PythonQtConversion.cpp
35 // \file PythonQtConversion.cpp
36 // \author Florian Link
36 // \author Florian Link
37 // \author Last changed by $Author: florian $
37 // \author Last changed by $Author: florian $
38 // \date 2006-05
38 // \date 2006-05
39 */
39 */
40 //----------------------------------------------------------------------------------
40 //----------------------------------------------------------------------------------
41
41
42 #include "PythonQtConversion.h"
42 #include "PythonQtConversion.h"
43 #include "PythonQtVariants.h"
43 #include "PythonQtVariants.h"
44 #include <QDateTime>
44 #include <QDateTime>
45 #include <QTime>
45 #include <QTime>
46 #include <QDate>
46 #include <QDate>
47
47
48 #if PY_MAJOR_VERSION >= 3
49 #define PY3K
50 #endif
51
48 PythonQtValueStorage<qint64, 128> PythonQtConv::global_valueStorage;
52 PythonQtValueStorage<qint64, 128> PythonQtConv::global_valueStorage;
49 PythonQtValueStorage<void*, 128> PythonQtConv::global_ptrStorage;
53 PythonQtValueStorage<void*, 128> PythonQtConv::global_ptrStorage;
50 PythonQtValueStorageWithCleanup<QVariant, 128> PythonQtConv::global_variantStorage;
54 PythonQtValueStorageWithCleanup<QVariant, 128> PythonQtConv::global_variantStorage;
51
55
52 QHash<int, PythonQtConvertMetaTypeToPythonCB*> PythonQtConv::_metaTypeToPythonConverters;
56 QHash<int, PythonQtConvertMetaTypeToPythonCB*> PythonQtConv::_metaTypeToPythonConverters;
53 QHash<int, PythonQtConvertPythonToMetaTypeCB*> PythonQtConv::_pythonToMetaTypeConverters;
57 QHash<int, PythonQtConvertPythonToMetaTypeCB*> PythonQtConv::_pythonToMetaTypeConverters;
54
58
55 PyObject* PythonQtConv::GetPyBool(bool val)
59 PyObject* PythonQtConv::GetPyBool(bool val)
56 {
60 {
57 PyObject* r = val?Py_True:Py_False;
61 PyObject* r = val?Py_True:Py_False;
58 Py_INCREF(r);
62 Py_INCREF(r);
59 return r;
63 return r;
60 }
64 }
61
65
62 PyObject* PythonQtConv::ConvertQtValueToPython(const PythonQtMethodInfo::ParameterInfo& info, const void* data) {
66 PyObject* PythonQtConv::ConvertQtValueToPython(const PythonQtMethodInfo::ParameterInfo& info, const void* data) {
63 // is it an enum value?
67 // is it an enum value?
64 if (info.enumWrapper) {
68 if (info.enumWrapper) {
65 if (info.pointerCount==0) {
69 if (info.pointerCount==0) {
66 return PythonQtPrivate::createEnumValueInstance(info.enumWrapper, *((unsigned int*)data));
70 return PythonQtPrivate::createEnumValueInstance(info.enumWrapper, *((unsigned int*)data));
67 } else {
71 } else {
68 // we do not support pointers to enums (who needs them?)
72 // we do not support pointers to enums (who needs them?)
69 Py_INCREF(Py_None);
73 Py_INCREF(Py_None);
70 return Py_None;
74 return Py_None;
71 }
75 }
72 }
76 }
73
77
74 if (info.typeId == QMetaType::Void) {
78 if (info.typeId == QMetaType::Void) {
75 Py_INCREF(Py_None);
79 Py_INCREF(Py_None);
76 return Py_None;
80 return Py_None;
77 } else if ((info.pointerCount == 1) && (info.typeId == QMetaType::Char)) {
81 } else if ((info.pointerCount == 1) && (info.typeId == QMetaType::Char)) {
78 // a char ptr will probably be a null terminated string, so we support that:
82 // a char ptr will probably be a null terminated string, so we support that:
79 char* charPtr = *((char**)data);
83 char* charPtr = *((char**)data);
80 if (charPtr) {
84 if (charPtr) {
85 #ifdef PY3K
86 return PyUnicode_FromString(charPtr);
87 #else
81 return PyString_FromString(charPtr);
88 return PyString_FromString(charPtr);
89 #endif
82 } else {
90 } else {
83 Py_INCREF(Py_None);
91 Py_INCREF(Py_None);
84 return Py_None;
92 return Py_None;
85 }
93 }
86 } else if ((info.typeId == PythonQtMethodInfo::Unknown || info.typeId >= QMetaType::User) &&
94 } else if ((info.typeId == PythonQtMethodInfo::Unknown || info.typeId >= QMetaType::User) &&
87 info.name.startsWith("QList<")) {
95 info.name.startsWith("QList<")) {
88 // it is a QList template:
96 // it is a QList template:
89 QByteArray innerType = info.name.mid(6,info.name.length()-7);
97 QByteArray innerType = info.name.mid(6,info.name.length()-7);
90 if (innerType.endsWith("*")) {
98 if (innerType.endsWith("*")) {
91 innerType.truncate(innerType.length()-1);
99 innerType.truncate(innerType.length()-1);
92 QList<void*>* listPtr = NULL;
100 QList<void*>* listPtr = NULL;
93 if (info.pointerCount == 1) {
101 if (info.pointerCount == 1) {
94 listPtr = *((QList<void*>**)data);
102 listPtr = *((QList<void*>**)data);
95 } else if (info.pointerCount == 0) {
103 } else if (info.pointerCount == 0) {
96 listPtr = (QList<void*>*)data;
104 listPtr = (QList<void*>*)data;
97 }
105 }
98 if (listPtr) {
106 if (listPtr) {
99 return ConvertQListOfPointerTypeToPythonList(listPtr, innerType);
107 return ConvertQListOfPointerTypeToPythonList(listPtr, innerType);
100 } else {
108 } else {
101 return NULL;
109 return NULL;
102 }
110 }
103 }
111 }
104 }
112 }
105
113
106 if (info.typeId >= QMetaType::User) {
114 if (info.typeId >= QMetaType::User) {
107 // if a converter is registered, we use is:
115 // if a converter is registered, we use is:
108 PythonQtConvertMetaTypeToPythonCB* converter = _metaTypeToPythonConverters.value(info.typeId);
116 PythonQtConvertMetaTypeToPythonCB* converter = _metaTypeToPythonConverters.value(info.typeId);
109 if (converter) {
117 if (converter) {
110 return (*converter)(data, info.typeId);
118 return (*converter)(data, info.typeId);
111 }
119 }
112 }
120 }
113
121
114 // special handling did not match, so we convert the usual way (either pointer or value version):
122 // special handling did not match, so we convert the usual way (either pointer or value version):
115 if (info.pointerCount == 1) {
123 if (info.pointerCount == 1) {
116 // convert the pointer to a Python Object (we can handle ANY C++ object, in the worst case we just know the type and the pointer)
124 // convert the pointer to a Python Object (we can handle ANY C++ object, in the worst case we just know the type and the pointer)
117 return PythonQt::priv()->wrapPtr(*((void**)data), info.name);
125 return PythonQt::priv()->wrapPtr(*((void**)data), info.name);
118 } else if (info.pointerCount == 0) {
126 } else if (info.pointerCount == 0) {
119 // handle values that are not yet handled and not pointers
127 // handle values that are not yet handled and not pointers
120 return ConvertQtValueToPythonInternal(info.typeId, data);
128 return ConvertQtValueToPythonInternal(info.typeId, data);
121 } else {
129 } else {
122 return NULL;
130 return NULL;
123 }
131 }
124 }
132 }
125
133
126 PyObject* PythonQtConv::ConvertQtValueToPythonInternal(int type, const void* data) {
134 PyObject* PythonQtConv::ConvertQtValueToPythonInternal(int type, const void* data) {
127 switch (type) {
135 switch (type) {
128 case QMetaType::Void:
136 case QMetaType::Void:
129 Py_INCREF(Py_None);
137 Py_INCREF(Py_None);
130 return Py_None;
138 return Py_None;
131 case QMetaType::Char:
139 case QMetaType::Char:
132 return PyInt_FromLong(*((char*)data));
140 return PyLong_FromLong(*((char*)data));
133 case QMetaType::UChar:
141 case QMetaType::UChar:
134 return PyInt_FromLong(*((unsigned char*)data));
142 return PyLong_FromLong(*((unsigned char*)data));
135 case QMetaType::Short:
143 case QMetaType::Short:
136 return PyInt_FromLong(*((short*)data));
144 return PyLong_FromLong(*((short*)data));
137 case QMetaType::UShort:
145 case QMetaType::UShort:
138 return PyInt_FromLong(*((unsigned short*)data));
146 return PyLong_FromLong(*((unsigned short*)data));
139 case QMetaType::Long:
147 case QMetaType::Long:
140 return PyInt_FromLong(*((long*)data));
148 return PyLong_FromLong(*((long*)data));
141 case QMetaType::ULong:
149 case QMetaType::ULong:
142 // does not fit into simple int of python
150 // does not fit into simple int of python
143 return PyLong_FromUnsignedLong(*((unsigned long*)data));
151 return PyLong_FromUnsignedLong(*((unsigned long*)data));
144 case QMetaType::Bool:
152 case QMetaType::Bool:
145 return PythonQtConv::GetPyBool(*((bool*)data));
153 return PythonQtConv::GetPyBool(*((bool*)data));
146 case QMetaType::Int:
154 case QMetaType::Int:
147 return PyInt_FromLong(*((int*)data));
155 return PyLong_FromLong(*((int*)data));
148 case QMetaType::UInt:
156 case QMetaType::UInt:
149 // does not fit into simple int of python
157 // does not fit into simple int of python
150 return PyLong_FromUnsignedLong(*((unsigned int*)data));
158 return PyLong_FromUnsignedLong(*((unsigned int*)data));
151 case QMetaType::QChar:
159 case QMetaType::QChar:
152 return PyInt_FromLong(*((short*)data));
160 return PyLong_FromLong(*((short*)data));
153 case QMetaType::Float:
161 case QMetaType::Float:
154 return PyFloat_FromDouble(*((float*)data));
162 return PyFloat_FromDouble(*((float*)data));
155 case QMetaType::Double:
163 case QMetaType::Double:
156 return PyFloat_FromDouble(*((double*)data));
164 return PyFloat_FromDouble(*((double*)data));
157 case QMetaType::LongLong:
165 case QMetaType::LongLong:
158 return PyLong_FromLongLong(*((qint64*)data));
166 return PyLong_FromLongLong(*((qint64*)data));
159 case QMetaType::ULongLong:
167 case QMetaType::ULongLong:
160 return PyLong_FromUnsignedLongLong(*((quint64*)data));
168 return PyLong_FromUnsignedLongLong(*((quint64*)data));
161 // implicit conversion from QByteArray to str has been removed:
169 // implicit conversion from QByteArray to str has been removed:
162 //case QMetaType::QByteArray: {
170 //case QMetaType::QByteArray: {
163 // QByteArray* v = (QByteArray*) data;
171 // QByteArray* v = (QByteArray*) data;
164 // return PyString_FromStringAndSize(*v, v->size());
172 // return PyString_FromStringAndSize(*v, v->size());
165 // }
173 // }
166 case QMetaType::QVariantMap:
174 case QMetaType::QVariantMap:
167 return PythonQtConv::QVariantMapToPyObject(*((QVariantMap*)data));
175 return PythonQtConv::QVariantMapToPyObject(*((QVariantMap*)data));
168 case QMetaType::QVariantList:
176 case QMetaType::QVariantList:
169 return PythonQtConv::QVariantListToPyObject(*((QVariantList*)data));
177 return PythonQtConv::QVariantListToPyObject(*((QVariantList*)data));
170 case QMetaType::QString:
178 case QMetaType::QString:
171 return PythonQtConv::QStringToPyObject(*((QString*)data));
179 return PythonQtConv::QStringToPyObject(*((QString*)data));
172 case QMetaType::QStringList:
180 case QMetaType::QStringList:
173 return PythonQtConv::QStringListToPyObject(*((QStringList*)data));
181 return PythonQtConv::QStringListToPyObject(*((QStringList*)data));
174
182
175 case PythonQtMethodInfo::Variant:
183 case PythonQtMethodInfo::Variant:
176 return PythonQtConv::QVariantToPyObject(*((QVariant*)data));
184 return PythonQtConv::QVariantToPyObject(*((QVariant*)data));
177 case QMetaType::QObjectStar:
185 case QMetaType::QObjectStar:
178 #if( QT_VERSION < QT_VERSION_CHECK(5,0,0) )
186 #if( QT_VERSION < QT_VERSION_CHECK(5,0,0) )
179 case QMetaType::QWidgetStar:
187 case QMetaType::QWidgetStar:
180 #endif
188 #endif
181 return PythonQt::priv()->wrapQObject(*((QObject**)data));
189 return PythonQt::priv()->wrapQObject(*((QObject**)data));
182
190
183 default:
191 default:
184 if (PythonQt::priv()->isPythonQtObjectPtrMetaId(type)) {
192 if (PythonQt::priv()->isPythonQtObjectPtrMetaId(type)) {
185 // special case, it is a PythonQtObjectPtr which contains a PyObject, take it directly:
193 // special case, it is a PythonQtObjectPtr which contains a PyObject, take it directly:
186 PyObject* o = ((PythonQtObjectPtr*)data)->object();
194 PyObject* o = ((PythonQtObjectPtr*)data)->object();
187 Py_INCREF(o);
195 Py_INCREF(o);
188 return o;
196 return o;
189 } else {
197 } else {
190 if (type > 0) {
198 if (type > 0) {
191 // if the type is known, we can construct it via QMetaType::construct
199 // if the type is known, we can construct it via QMetaType::construct
192 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
200 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
193 void* newCPPObject = QMetaType::create(type, data);
201 void* newCPPObject = QMetaType::create(type, data);
194 #else
202 #else
195 void* newCPPObject = QMetaType::construct(type, data);
203 void* newCPPObject = QMetaType::construct(type, data);
196 #endif
204 #endif
197 // XXX this could be optimized by using metatypeid directly
205 // XXX this could be optimized by using metatypeid directly
198 PythonQtInstanceWrapper* wrap = (PythonQtInstanceWrapper*)PythonQt::priv()->wrapPtr(newCPPObject, QMetaType::typeName(type));
206 PythonQtInstanceWrapper* wrap = (PythonQtInstanceWrapper*)PythonQt::priv()->wrapPtr(newCPPObject, QMetaType::typeName(type));
199 wrap->_ownedByPythonQt = true;
207 wrap->_ownedByPythonQt = true;
200 wrap->_useQMetaTypeDestroy = true;
208 wrap->_useQMetaTypeDestroy = true;
201 return (PyObject*)wrap;
209 return (PyObject*)wrap;
202 }
210 }
203 std::cerr << "Unknown type that can not be converted to Python: " << type << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
211 std::cerr << "Unknown type that can not be converted to Python: " << type << ", in " << __FILE__ << ":" << __LINE__ << std::endl;
204 }
212 }
205 }
213 }
206 Py_INCREF(Py_None);
214 Py_INCREF(Py_None);
207 return Py_None;
215 return Py_None;
208 }
216 }
209
217
210 void* PythonQtConv::CreateQtReturnValue(const PythonQtMethodInfo::ParameterInfo& info) {
218 void* PythonQtConv::CreateQtReturnValue(const PythonQtMethodInfo::ParameterInfo& info) {
211 void* ptr = NULL;
219 void* ptr = NULL;
212 if (info.pointerCount>1) {
220 if (info.pointerCount>1) {
213 return NULL;
221 return NULL;
214 } else if (info.pointerCount==1) {
222 } else if (info.pointerCount==1) {
215 PythonQtValueStorage_ADD_VALUE(global_ptrStorage, void*, NULL, ptr);
223 PythonQtValueStorage_ADD_VALUE(global_ptrStorage, void*, NULL, ptr);
216 } else if (info.enumWrapper) {
224 } else if (info.enumWrapper) {
217 // create enum return value
225 // create enum return value
218 PythonQtValueStorage_ADD_VALUE(PythonQtConv::global_valueStorage, long, 0, ptr);
226 PythonQtValueStorage_ADD_VALUE(PythonQtConv::global_valueStorage, long, 0, ptr);
219 } else {
227 } else {
220 switch (info.typeId) {
228 switch (info.typeId) {
221 case QMetaType::Char:
229 case QMetaType::Char:
222 case QMetaType::UChar:
230 case QMetaType::UChar:
223 case QMetaType::Short:
231 case QMetaType::Short:
224 case QMetaType::UShort:
232 case QMetaType::UShort:
225 case QMetaType::Long:
233 case QMetaType::Long:
226 case QMetaType::ULong:
234 case QMetaType::ULong:
227 case QMetaType::Bool:
235 case QMetaType::Bool:
228 case QMetaType::Int:
236 case QMetaType::Int:
229 case QMetaType::UInt:
237 case QMetaType::UInt:
230 case QMetaType::QChar:
238 case QMetaType::QChar:
231 case QMetaType::Float:
239 case QMetaType::Float:
232 case QMetaType::Double:
240 case QMetaType::Double:
233 PythonQtValueStorage_ADD_VALUE(global_valueStorage, qint64, 0, ptr);
241 PythonQtValueStorage_ADD_VALUE(global_valueStorage, qint64, 0, ptr);
234 break;
242 break;
235 case PythonQtMethodInfo::Variant:
243 case PythonQtMethodInfo::Variant:
236 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, 0, ptr);
244 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, 0, ptr);
237 // return the ptr to the variant
245 // return the ptr to the variant
238 break;
246 break;
239 default:
247 default:
240 if (info.typeId == PythonQtMethodInfo::Unknown) {
248 if (info.typeId == PythonQtMethodInfo::Unknown) {
241 // check if we have a QList of pointers, which we can circumvent with a QList<void*>
249 // check if we have a QList of pointers, which we can circumvent with a QList<void*>
242 if (info.name.startsWith("QList<")) {
250 if (info.name.startsWith("QList<")) {
243 QByteArray innerType = info.name.mid(6,info.name.length()-7);
251 QByteArray innerType = info.name.mid(6,info.name.length()-7);
244 if (innerType.endsWith("*")) {
252 if (innerType.endsWith("*")) {
245 static int id = QMetaType::type("QList<void*>");
253 static int id = QMetaType::type("QList<void*>");
246 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QVariant::Type(id), ptr);
254 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QVariant::Type(id), ptr);
247 // return the constData pointer that will be filled with the result value later on
255 // return the constData pointer that will be filled with the result value later on
248 ptr = (void*)((QVariant*)ptr)->constData();
256 ptr = (void*)((QVariant*)ptr)->constData();
249 }
257 }
250 }
258 }
251 }
259 }
252
260
253 if (!ptr && info.typeId!=PythonQtMethodInfo::Unknown) {
261 if (!ptr && info.typeId!=PythonQtMethodInfo::Unknown) {
254 // everything else is stored in a QVariant, if we know the meta type...
262 // everything else is stored in a QVariant, if we know the meta type...
255 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QVariant::Type(info.typeId), ptr);
263 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QVariant::Type(info.typeId), ptr);
256 // return the constData pointer that will be filled with the result value later on
264 // return the constData pointer that will be filled with the result value later on
257 ptr = (void*)((QVariant*)ptr)->constData();
265 ptr = (void*)((QVariant*)ptr)->constData();
258 }
266 }
259 }
267 }
260 }
268 }
261 return ptr;
269 return ptr;
262 }
270 }
263
271
264 void* PythonQtConv::castWrapperTo(PythonQtInstanceWrapper* wrapper, const QByteArray& className, bool& ok)
272 void* PythonQtConv::castWrapperTo(PythonQtInstanceWrapper* wrapper, const QByteArray& className, bool& ok)
265 {
273 {
266 void* object;
274 void* object;
267 if (wrapper->classInfo()->isCPPWrapper()) {
275 if (wrapper->classInfo()->isCPPWrapper()) {
268 object = wrapper->_wrappedPtr;
276 object = wrapper->_wrappedPtr;
269 } else {
277 } else {
270 QObject* tmp = wrapper->_obj;
278 QObject* tmp = wrapper->_obj;
271 object = tmp;
279 object = tmp;
272 }
280 }
273 if (object) {
281 if (object) {
274 // if we can be upcasted to the given name, we pass the casted pointer in:
282 // if we can be upcasted to the given name, we pass the casted pointer in:
275 object = wrapper->classInfo()->castTo(object, className);
283 object = wrapper->classInfo()->castTo(object, className);
276 ok = object!=NULL;
284 ok = object!=NULL;
277 } else {
285 } else {
278 // if it is a NULL ptr, we need to check if it inherits, so that we might pass the NULL ptr
286 // if it is a NULL ptr, we need to check if it inherits, so that we might pass the NULL ptr
279 ok = wrapper->classInfo()->inherits(className);
287 ok = wrapper->classInfo()->inherits(className);
280 }
288 }
281 return object;
289 return object;
282 }
290 }
283
291
284 void* PythonQtConv::handlePythonToQtAutoConversion(int typeId, PyObject* obj, void* alreadyAllocatedCPPObject)
292 void* PythonQtConv::handlePythonToQtAutoConversion(int typeId, PyObject* obj, void* alreadyAllocatedCPPObject)
285 {
293 {
286 void* ptr = alreadyAllocatedCPPObject;
294 void* ptr = alreadyAllocatedCPPObject;
287
295
288 static int penId = QMetaType::type("QPen");
296 static int penId = QMetaType::type("QPen");
289 static int brushId = QMetaType::type("QBrush");
297 static int brushId = QMetaType::type("QBrush");
290 static int cursorId = QMetaType::type("QCursor");
298 static int cursorId = QMetaType::type("QCursor");
291 static int colorId = QMetaType::type("QColor");
299 static int colorId = QMetaType::type("QColor");
292 static PyObject* qtGlobalColorEnum = PythonQtClassInfo::findEnumWrapper("Qt::GlobalColor", NULL);
300 static PyObject* qtGlobalColorEnum = PythonQtClassInfo::findEnumWrapper("Qt::GlobalColor", NULL);
293 if (typeId == cursorId) {
301 if (typeId == cursorId) {
294 static PyObject* qtCursorShapeEnum = PythonQtClassInfo::findEnumWrapper("Qt::CursorShape", NULL);
302 static PyObject* qtCursorShapeEnum = PythonQtClassInfo::findEnumWrapper("Qt::CursorShape", NULL);
295 if ((PyObject*)obj->ob_type == qtCursorShapeEnum) {
303 if ((PyObject*)obj->ob_type == qtCursorShapeEnum) {
296 Qt::CursorShape val = (Qt::CursorShape)PyInt_AS_LONG(obj);
304 Qt::CursorShape val = (Qt::CursorShape)PyLong_AsLong(obj);
297 if (!ptr) {
305 if (!ptr) {
298 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QCursor(), ptr);
306 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QCursor(), ptr);
299 ptr = (void*)((QVariant*)ptr)->constData();
307 ptr = (void*)((QVariant*)ptr)->constData();
300 }
308 }
301 *((QCursor*)ptr) = QCursor(val);
309 *((QCursor*)ptr) = QCursor(val);
302 return ptr;
310 return ptr;
303 }
311 }
304 } else if (typeId == penId) {
312 } else if (typeId == penId) {
305 // brushes can be created from QColor and from Qt::GlobalColor (and from brushes, but that's the default)
313 // brushes can be created from QColor and from Qt::GlobalColor (and from brushes, but that's the default)
306 static PyObject* qtColorClass = PythonQt::priv()->getClassInfo("QColor")->pythonQtClassWrapper();
314 static PyObject* qtColorClass = PythonQt::priv()->getClassInfo("QColor")->pythonQtClassWrapper();
307 if ((PyObject*)obj->ob_type == qtGlobalColorEnum) {
315 if ((PyObject*)obj->ob_type == qtGlobalColorEnum) {
308 Qt::GlobalColor val = (Qt::GlobalColor)PyInt_AS_LONG(obj);
316 Qt::GlobalColor val = (Qt::GlobalColor)PyLong_AsLong(obj);
309 if (!ptr) {
317 if (!ptr) {
310 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QPen(), ptr);
318 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QPen(), ptr);
311 ptr = (void*)((QVariant*)ptr)->constData();
319 ptr = (void*)((QVariant*)ptr)->constData();
312 }
320 }
313 *((QPen*)ptr) = QPen(QColor(val));
321 *((QPen*)ptr) = QPen(QColor(val));
314 return ptr;
322 return ptr;
315 } else if ((PyObject*)obj->ob_type == qtColorClass) {
323 } else if ((PyObject*)obj->ob_type == qtColorClass) {
316 if (!ptr) {
324 if (!ptr) {
317 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QPen(), ptr);
325 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QPen(), ptr);
318 ptr = (void*)((QVariant*)ptr)->constData();
326 ptr = (void*)((QVariant*)ptr)->constData();
319 }
327 }
320 *((QPen*)ptr) = QPen(*((QColor*)((PythonQtInstanceWrapper*)obj)->_wrappedPtr));
328 *((QPen*)ptr) = QPen(*((QColor*)((PythonQtInstanceWrapper*)obj)->_wrappedPtr));
321 return ptr;
329 return ptr;
322 }
330 }
323 } else if (typeId == brushId) {
331 } else if (typeId == brushId) {
324 // brushes can be created from QColor and from Qt::GlobalColor (and from brushes, but that's the default)
332 // brushes can be created from QColor and from Qt::GlobalColor (and from brushes, but that's the default)
325 static PyObject* qtColorClass = PythonQt::priv()->getClassInfo("QColor")->pythonQtClassWrapper();
333 static PyObject* qtColorClass = PythonQt::priv()->getClassInfo("QColor")->pythonQtClassWrapper();
326 if ((PyObject*)obj->ob_type == qtGlobalColorEnum) {
334 if ((PyObject*)obj->ob_type == qtGlobalColorEnum) {
327 Qt::GlobalColor val = (Qt::GlobalColor)PyInt_AS_LONG(obj);
335 Qt::GlobalColor val = (Qt::GlobalColor)PyLong_AsLong(obj);
328 if (!ptr) {
336 if (!ptr) {
329 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QBrush(), ptr);
337 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QBrush(), ptr);
330 ptr = (void*)((QVariant*)ptr)->constData();
338 ptr = (void*)((QVariant*)ptr)->constData();
331 }
339 }
332 *((QBrush*)ptr) = QBrush(QColor(val));
340 *((QBrush*)ptr) = QBrush(QColor(val));
333 return ptr;
341 return ptr;
334 } else if ((PyObject*)obj->ob_type == qtColorClass) {
342 } else if ((PyObject*)obj->ob_type == qtColorClass) {
335 if (!ptr) {
343 if (!ptr) {
336 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QBrush(), ptr);
344 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QBrush(), ptr);
337 ptr = (void*)((QVariant*)ptr)->constData();
345 ptr = (void*)((QVariant*)ptr)->constData();
338 }
346 }
339 *((QBrush*)ptr) = QBrush(*((QColor*)((PythonQtInstanceWrapper*)obj)->_wrappedPtr));
347 *((QBrush*)ptr) = QBrush(*((QColor*)((PythonQtInstanceWrapper*)obj)->_wrappedPtr));
340 return ptr;
348 return ptr;
341 }
349 }
342 } else if (typeId == colorId) {
350 } else if (typeId == colorId) {
343 // colors can be created from Qt::GlobalColor (and from colors, but that's the default)
351 // colors can be created from Qt::GlobalColor (and from colors, but that's the default)
344 if ((PyObject*)obj->ob_type == qtGlobalColorEnum) {
352 if ((PyObject*)obj->ob_type == qtGlobalColorEnum) {
345 Qt::GlobalColor val = (Qt::GlobalColor)PyInt_AS_LONG(obj);
353 Qt::GlobalColor val = (Qt::GlobalColor)PyLong_AsLong(obj);
346 if (!ptr) {
354 if (!ptr) {
347 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QColor(), ptr);
355 PythonQtValueStorage_ADD_VALUE(global_variantStorage, QVariant, QColor(), ptr);
348 ptr = (void*)((QVariant*)ptr)->constData();
356 ptr = (void*)((QVariant*)ptr)->constData();
349 }
357 }
350 *((QColor*)ptr) = QColor(val);
358 *((QColor*)ptr) = QColor(val);
351 return ptr;
359 return ptr;
352 }
360 }
353 }
361 }
354 return NULL;
362 return NULL;
355 }
363 }
356
364
357 void* PythonQtConv::ConvertPythonToQt(const PythonQtMethodInfo::ParameterInfo& info, PyObject* obj, bool strict, PythonQtClassInfo* /*classInfo*/, void* alreadyAllocatedCPPObject)
365 void* PythonQtConv::ConvertPythonToQt(const PythonQtMethodInfo::ParameterInfo& info, PyObject* obj, bool strict, PythonQtClassInfo* /*classInfo*/, void* alreadyAllocatedCPPObject)
358 {
366 {
359 bool ok = false;
367 bool ok = false;
360 void* ptr = NULL;
368 void* ptr = NULL;
361
369
362 // autoconversion of QPen/QBrush/QCursor/QColor from different type
370 // autoconversion of QPen/QBrush/QCursor/QColor from different type
363 if (info.pointerCount==0 && !strict) {
371 if (info.pointerCount==0 && !strict) {
364 ptr = handlePythonToQtAutoConversion(info.typeId, obj, alreadyAllocatedCPPObject);
372 ptr = handlePythonToQtAutoConversion(info.typeId, obj, alreadyAllocatedCPPObject);
365 if (ptr) {
373 if (ptr) {
366 return ptr;
374 return ptr;
367 }
375 }
368 }
376 }
369
377
370 if (PyObject_TypeCheck(obj, &PythonQtInstanceWrapper_Type) && info.typeId != PythonQtMethodInfo::Variant) {
378 if (PyObject_TypeCheck(obj, &PythonQtInstanceWrapper_Type) && info.typeId != PythonQtMethodInfo::Variant) {
371 // if we have a Qt wrapper object and if we do not need a QVariant, we do the following:
379 // if we have a Qt wrapper object and if we do not need a QVariant, we do the following:
372 // (the Variant case is handled below in a switch)
380 // (the Variant case is handled below in a switch)
373
381
374 // a C++ wrapper (can be passed as pointer or reference)
382 // a C++ wrapper (can be passed as pointer or reference)
375 PythonQtInstanceWrapper* wrap = (PythonQtInstanceWrapper*)obj;
383 PythonQtInstanceWrapper* wrap = (PythonQtInstanceWrapper*)obj;
376 void* object = castWrapperTo(wrap, info.name, ok);
384 void* object = castWrapperTo(wrap, info.name, ok);
377 if (ok) {
385 if (ok) {
378 if (info.pointerCount==1) {
386 if (info.pointerCount==1) {
379 // store the wrapped pointer in an extra pointer and let ptr point to the extra pointer
387 // store the wrapped pointer in an extra pointer and let ptr point to the extra pointer
380 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, object, ptr);
388 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, object, ptr);
381 } else if (info.pointerCount==0) {
389 } else if (info.pointerCount==0) {
382 // store the wrapped pointer directly, since we are a reference
390 // store the wrapped pointer directly, since we are a reference
383 ptr = object;
391 ptr = object;
384 }
392 }
385 } else {
393 } else {
386 // not matching, maybe a PyObject*?
394 // not matching, maybe a PyObject*?
387 if (info.name == "PyObject" && info.pointerCount==1) {
395 if (info.name == "PyObject" && info.pointerCount==1) {
388 // handle low level PyObject directly
396 // handle low level PyObject directly
389 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, obj, ptr);
397 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, obj, ptr);
390 }
398 }
391 }
399 }
392 } else if (info.pointerCount == 1) {
400 } else if (info.pointerCount == 1) {
393 // a pointer
401 // a pointer
394 if (info.typeId == QMetaType::Char || info.typeId == QMetaType::UChar)
402 if (info.typeId == QMetaType::Char || info.typeId == QMetaType::UChar)
395 {
403 {
404 #ifdef PY3K
405 if (PyUnicode_Check(obj)) {
406 QByteArray bytes(PyUnicode_AsUTF8(obj));
407 void* ptr2 = NULL;
408 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(NULL,global_variantStorage, QVariant, QVariant(bytes), ptr2);
409 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, (((QByteArray*)((QVariant*)ptr2)->constData())->data()), ptr);
410 #else
396 if (obj->ob_type == &PyString_Type) {
411 if (obj->ob_type == &PyString_Type) {
397 // take direct reference to string data
412 // take direct reference to string data
398 const char* data = PyString_AS_STRING(obj);
413 const char* data = PyString_AS_STRING(obj);
399 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, (void*)data, ptr);
414 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, (void*)data, ptr);
415 #endif
400 } else {
416 } else {
401 // convert to string
417 // convert to string
402 QString str = PyObjGetString(obj, strict, ok);
418 QString str = PyObjGetString(obj, strict, ok);
403 if (ok) {
419 if (ok) {
404 QByteArray bytes;
420 QByteArray bytes;
405 bytes = str.toUtf8();
421 bytes = str.toUtf8();
406 if (ok) {
422 if (ok) {
407 void* ptr2 = NULL;
423 void* ptr2 = NULL;
408 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(NULL,global_variantStorage, QVariant, QVariant(bytes), ptr2);
424 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(NULL,global_variantStorage, QVariant, QVariant(bytes), ptr2);
409 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, (((QByteArray*)((QVariant*)ptr2)->constData())->data()), ptr);
425 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, (((QByteArray*)((QVariant*)ptr2)->constData())->data()), ptr);
410 }
426 }
411 }
427 }
412 }
428 }
413 } else if (info.typeId == QMetaType::QString) {
429 } else if (info.typeId == QMetaType::QString) {
414 // TODO: this is a special case for bad Qt APIs which take a QString*, like QtGui.QFileDialog.getSaveFileName
430 // TODO: this is a special case for bad Qt APIs which take a QString*, like QtGui.QFileDialog.getSaveFileName
415 // In general we would need to decide to either support * args for all basic types (ignoring the fact that the
431 // In general we would need to decide to either support * args for all basic types (ignoring the fact that the
416 // result value is not useable in Python), or if all these APIs need to be wrapped manually/differently, like PyQt/PySide do.
432 // result value is not useable in Python), or if all these APIs need to be wrapped manually/differently, like PyQt/PySide do.
417 QString str = PyObjGetString(obj, strict, ok);
433 QString str = PyObjGetString(obj, strict, ok);
418 if (ok) {
434 if (ok) {
419 void* ptr2 = NULL;
435 void* ptr2 = NULL;
420 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(NULL,global_variantStorage, QVariant, QVariant(str), ptr2);
436 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(NULL,global_variantStorage, QVariant, QVariant(str), ptr2);
421 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, (void*)((QVariant*)ptr2)->constData(), ptr);
437 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, (void*)((QVariant*)ptr2)->constData(), ptr);
422 }
438 }
423 } else if (info.name == "PyObject") {
439 } else if (info.name == "PyObject") {
424 // handle low level PyObject directly
440 // handle low level PyObject directly
425 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, obj, ptr);
441 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, obj, ptr);
426 } else if (obj == Py_None) {
442 } else if (obj == Py_None) {
427 // None is treated as a NULL ptr
443 // None is treated as a NULL ptr
428 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, NULL, ptr);
444 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, NULL, ptr);
429 } else {
445 } else {
430 void* foreignWrapper = PythonQt::priv()->unwrapForeignWrapper(info.name, obj);
446 void* foreignWrapper = PythonQt::priv()->unwrapForeignWrapper(info.name, obj);
431 if (foreignWrapper) {
447 if (foreignWrapper) {
432 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, foreignWrapper, ptr);
448 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, foreignWrapper, ptr);
433 } else {
449 } else {
434 // if we are not strict, we try if we are passed a 0 integer
450 // if we are not strict, we try if we are passed a 0 integer
435 if (!strict) {
451 if (!strict) {
436 bool ok;
452 bool ok;
437 int value = PyObjGetInt(obj, true, ok);
453 int value = PyObjGetInt(obj, true, ok);
438 if (ok && value==0) {
454 if (ok && value==0) {
439 // TODOXXX is this wise? or should it be expected from the programmer to use None?
455 // TODOXXX is this wise? or should it be expected from the programmer to use None?
440 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, NULL, ptr);
456 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_ptrStorage, void*, NULL, ptr);
441 }
457 }
442 }
458 }
443 }
459 }
444 }
460 }
445 } else if (info.pointerCount == 0) {
461 } else if (info.pointerCount == 0) {
446 // not a pointer
462 // not a pointer
447 switch (info.typeId) {
463 switch (info.typeId) {
448 case QMetaType::Char:
464 case QMetaType::Char:
449 {
465 {
450 int val = PyObjGetInt(obj, strict, ok);
466 int val = PyObjGetInt(obj, strict, ok);
451 if (ok) {
467 if (ok) {
452 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, char, val, ptr);
468 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, char, val, ptr);
453 }
469 }
454 }
470 }
455 break;
471 break;
456 case QMetaType::UChar:
472 case QMetaType::UChar:
457 {
473 {
458 int val = PyObjGetInt(obj, strict, ok);
474 int val = PyObjGetInt(obj, strict, ok);
459 if (ok) {
475 if (ok) {
460 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, unsigned char, val, ptr);
476 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, unsigned char, val, ptr);
461 }
477 }
462 }
478 }
463 break;
479 break;
464 case QMetaType::Short:
480 case QMetaType::Short:
465 {
481 {
466 int val = PyObjGetInt(obj, strict, ok);
482 int val = PyObjGetInt(obj, strict, ok);
467 if (ok) {
483 if (ok) {
468 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, short, val, ptr);
484 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, short, val, ptr);
469 }
485 }
470 }
486 }
471 break;
487 break;
472 case QMetaType::UShort:
488 case QMetaType::UShort:
473 {
489 {
474 int val = PyObjGetInt(obj, strict, ok);
490 int val = PyObjGetInt(obj, strict, ok);
475 if (ok) {
491 if (ok) {
476 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, unsigned short, val, ptr);
492 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, unsigned short, val, ptr);
477 }
493 }
478 }
494 }
479 break;
495 break;
480 case QMetaType::Long:
496 case QMetaType::Long:
481 {
497 {
482 long val = (long)PyObjGetLongLong(obj, strict, ok);
498 long val = (long)PyObjGetLongLong(obj, strict, ok);
483 if (ok) {
499 if (ok) {
484 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, long, val, ptr);
500 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, long, val, ptr);
485 }
501 }
486 }
502 }
487 break;
503 break;
488 case QMetaType::ULong:
504 case QMetaType::ULong:
489 {
505 {
490 unsigned long val = (unsigned long)PyObjGetLongLong(obj, strict, ok);
506 unsigned long val = (unsigned long)PyObjGetLongLong(obj, strict, ok);
491 if (ok) {
507 if (ok) {
492 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, unsigned long, val, ptr);
508 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, unsigned long, val, ptr);
493 }
509 }
494 }
510 }
495 break;
511 break;
496 case QMetaType::Bool:
512 case QMetaType::Bool:
497 {
513 {
498 bool val = PyObjGetBool(obj, strict, ok);
514 bool val = PyObjGetBool(obj, strict, ok);
499 if (ok) {
515 if (ok) {
500 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, bool, val, ptr);
516 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, bool, val, ptr);
501 }
517 }
502 }
518 }
503 break;
519 break;
504 case QMetaType::Int:
520 case QMetaType::Int:
505 {
521 {
506 int val = PyObjGetInt(obj, strict, ok);
522 int val = PyObjGetInt(obj, strict, ok);
507 if (ok) {
523 if (ok) {
508 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, int, val, ptr);
524 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, int, val, ptr);
509 }
525 }
510 }
526 }
511 break;
527 break;
512 case QMetaType::UInt:
528 case QMetaType::UInt:
513 {
529 {
514 unsigned int val = (unsigned int)PyObjGetLongLong(obj, strict, ok);
530 unsigned int val = (unsigned int)PyObjGetLongLong(obj, strict, ok);
515 if (ok) {
531 if (ok) {
516 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, unsigned int, val, ptr);
532 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, unsigned int, val, ptr);
517 }
533 }
518 }
534 }
519 break;
535 break;
520 case QMetaType::QChar:
536 case QMetaType::QChar:
521 {
537 {
522 int val = PyObjGetInt(obj, strict, ok);
538 int val = PyObjGetInt(obj, strict, ok);
523 if (ok) {
539 if (ok) {
524 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, short, val, ptr);
540 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, short, val, ptr);
525 }
541 }
526 }
542 }
527 break;
543 break;
528 case QMetaType::Float:
544 case QMetaType::Float:
529 {
545 {
530 float val = (float)PyObjGetDouble(obj, strict, ok);
546 float val = (float)PyObjGetDouble(obj, strict, ok);
531 if (ok) {
547 if (ok) {
532 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, float, val, ptr);
548 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, float, val, ptr);
533 }
549 }
534 }
550 }
535 break;
551 break;
536 case QMetaType::Double:
552 case QMetaType::Double:
537 {
553 {
538 double val = (double)PyObjGetDouble(obj, strict, ok);
554 double val = (double)PyObjGetDouble(obj, strict, ok);
539 if (ok) {
555 if (ok) {
540 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, double, val, ptr);
556 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, double, val, ptr);
541 }
557 }
542 }
558 }
543 break;
559 break;
544 case QMetaType::LongLong:
560 case QMetaType::LongLong:
545 {
561 {
546 qint64 val = PyObjGetLongLong(obj, strict, ok);
562 qint64 val = PyObjGetLongLong(obj, strict, ok);
547 if (ok) {
563 if (ok) {
548 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, qint64, val, ptr);
564 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, qint64, val, ptr);
549 }
565 }
550 }
566 }
551 break;
567 break;
552 case QMetaType::ULongLong:
568 case QMetaType::ULongLong:
553 {
569 {
554 quint64 val = PyObjGetULongLong(obj, strict, ok);
570 quint64 val = PyObjGetULongLong(obj, strict, ok);
555 if (ok) {
571 if (ok) {
556 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, quint64, val, ptr);
572 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, quint64, val, ptr);
557 }
573 }
558 }
574 }
559 break;
575 break;
560 case QMetaType::QByteArray:
576 case QMetaType::QByteArray:
561 {
577 {
562 QByteArray bytes = PyObjGetBytes(obj, strict, ok);
578 QByteArray bytes = PyObjGetBytes(obj, strict, ok);
563 if (ok) {
579 if (ok) {
564 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, QVariant(bytes), ptr);
580 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, QVariant(bytes), ptr);
565 ptr = (void*)((QVariant*)ptr)->constData();
581 ptr = (void*)((QVariant*)ptr)->constData();
566 }
582 }
567 }
583 }
568 break;
584 break;
569 case QMetaType::QString:
585 case QMetaType::QString:
570 {
586 {
571 QString str = PyObjGetString(obj, strict, ok);
587 QString str = PyObjGetString(obj, strict, ok);
572 if (ok) {
588 if (ok) {
573 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, QVariant(str), ptr);
589 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, QVariant(str), ptr);
574 ptr = (void*)((QVariant*)ptr)->constData();
590 ptr = (void*)((QVariant*)ptr)->constData();
575 }
591 }
576 }
592 }
577 break;
593 break;
578 case QMetaType::QStringList:
594 case QMetaType::QStringList:
579 {
595 {
580 QStringList l = PyObjToStringList(obj, strict, ok);
596 QStringList l = PyObjToStringList(obj, strict, ok);
581 if (ok) {
597 if (ok) {
582 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, QVariant(l), ptr);
598 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, QVariant(l), ptr);
583 ptr = (void*)((QVariant*)ptr)->constData();
599 ptr = (void*)((QVariant*)ptr)->constData();
584 }
600 }
585 }
601 }
586 break;
602 break;
587
603
588 case PythonQtMethodInfo::Variant:
604 case PythonQtMethodInfo::Variant:
589 {
605 {
590 QVariant v = PyObjToQVariant(obj);
606 QVariant v = PyObjToQVariant(obj);
591 // the only case where conversion can fail it None and we want to pass that to, e.g. setProperty(),
607 // the only case where conversion can fail it None and we want to pass that to, e.g. setProperty(),
592 // so we do not check v.isValid() here
608 // so we do not check v.isValid() here
593 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, v, ptr);
609 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, v, ptr);
594 }
610 }
595 break;
611 break;
596 default:
612 default:
597 {
613 {
598 // check for enum case
614 // check for enum case
599 if (info.enumWrapper) {
615 if (info.enumWrapper) {
600 unsigned int val;
616 unsigned int val;
601 ok = false;
617 ok = false;
602 if ((PyObject*)obj->ob_type == info.enumWrapper) {
618 if ((PyObject*)obj->ob_type == info.enumWrapper) {
603 // we have a exact enum type match:
619 // we have a exact enum type match:
604 val = PyInt_AS_LONG(obj);
620 val = PyLong_AsLong(obj);
605 ok = true;
621 ok = true;
606 } else if (!strict) {
622 } else if (!strict) {
607 // we try to get any integer, when not being strict. If we are strict, integers are not wanted because
623 // we try to get any integer, when not being strict. If we are strict, integers are not wanted because
608 // we want an integer overload to be taken first!
624 // we want an integer overload to be taken first!
609 val = (unsigned int)PyObjGetLongLong(obj, false, ok);
625 val = (unsigned int)PyObjGetLongLong(obj, false, ok);
610 }
626 }
611 if (ok) {
627 if (ok) {
612 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, unsigned int, val, ptr);
628 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_valueStorage, unsigned int, val, ptr);
613 return ptr;
629 return ptr;
614 } else {
630 } else {
615 return NULL;
631 return NULL;
616 }
632 }
617 }
633 }
618
634
619 if (info.typeId == PythonQtMethodInfo::Unknown || info.typeId >= QMetaType::User) {
635 if (info.typeId == PythonQtMethodInfo::Unknown || info.typeId >= QMetaType::User) {
620 // check for QList<AnyPtr*> case, where we will use a QList<void*> QVariant
636 // check for QList<AnyPtr*> case, where we will use a QList<void*> QVariant
621 if (info.name.startsWith("QList<")) {
637 if (info.name.startsWith("QList<")) {
622 QByteArray innerType = info.name.mid(6,info.name.length()-7);
638 QByteArray innerType = info.name.mid(6,info.name.length()-7);
623 if (innerType.endsWith("*")) {
639 if (innerType.endsWith("*")) {
624 innerType.truncate(innerType.length()-1);
640 innerType.truncate(innerType.length()-1);
625 static int id = QMetaType::type("QList<void*>");
641 static int id = QMetaType::type("QList<void*>");
626 if (!alreadyAllocatedCPPObject) {
642 if (!alreadyAllocatedCPPObject) {
627 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, QVariant::Type(id), ptr);
643 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, QVariant::Type(id), ptr);
628 ptr = (void*)((QVariant*)ptr)->constData();
644 ptr = (void*)((QVariant*)ptr)->constData();
629 } else {
645 } else {
630 ptr = alreadyAllocatedCPPObject;
646 ptr = alreadyAllocatedCPPObject;
631 }
647 }
632 ok = ConvertPythonListToQListOfPointerType(obj, (QList<void*>*)ptr, innerType, strict);
648 ok = ConvertPythonListToQListOfPointerType(obj, (QList<void*>*)ptr, innerType, strict);
633 if (ok) {
649 if (ok) {
634 return ptr;
650 return ptr;
635 } else {
651 } else {
636 return NULL;
652 return NULL;
637 }
653 }
638 }
654 }
639 }
655 }
640 }
656 }
641
657
642 // We only do this for registered type > QMetaType::User for performance reasons.
658 // We only do this for registered type > QMetaType::User for performance reasons.
643 if (info.typeId >= QMetaType::User) {
659 if (info.typeId >= QMetaType::User) {
644 // Maybe we have a special converter that is registered for that type:
660 // Maybe we have a special converter that is registered for that type:
645 PythonQtConvertPythonToMetaTypeCB* converter = _pythonToMetaTypeConverters.value(info.typeId);
661 PythonQtConvertPythonToMetaTypeCB* converter = _pythonToMetaTypeConverters.value(info.typeId);
646 if (converter) {
662 if (converter) {
647 if (!alreadyAllocatedCPPObject) {
663 if (!alreadyAllocatedCPPObject) {
648 // create a new empty variant of concrete type:
664 // create a new empty variant of concrete type:
649 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, QVariant::Type(info.typeId), ptr);
665 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, QVariant::Type(info.typeId), ptr);
650 ptr = (void*)((QVariant*)ptr)->constData();
666 ptr = (void*)((QVariant*)ptr)->constData();
651 } else {
667 } else {
652 ptr = alreadyAllocatedCPPObject;
668 ptr = alreadyAllocatedCPPObject;
653 }
669 }
654 // now call the converter, passing the internal object of the variant
670 // now call the converter, passing the internal object of the variant
655 ok = (*converter)(obj, ptr, info.typeId, strict);
671 ok = (*converter)(obj, ptr, info.typeId, strict);
656 if (ok) {
672 if (ok) {
657 return ptr;
673 return ptr;
658 } else {
674 } else {
659 return NULL;
675 return NULL;
660 }
676 }
661 }
677 }
662 }
678 }
663 // if no type id is available, conversion to a QVariant makes no sense/is not possible
679 // if no type id is available, conversion to a QVariant makes no sense/is not possible
664 if (info.typeId != PythonQtMethodInfo::Unknown) {
680 if (info.typeId != PythonQtMethodInfo::Unknown) {
665 // for all other types, we use the same qvariant conversion and pass out the constData of the variant:
681 // for all other types, we use the same qvariant conversion and pass out the constData of the variant:
666 QVariant v = PyObjToQVariant(obj, info.typeId);
682 QVariant v = PyObjToQVariant(obj, info.typeId);
667 if (v.isValid()) {
683 if (v.isValid()) {
668 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, v, ptr);
684 PythonQtValueStorage_ADD_VALUE_IF_NEEDED(alreadyAllocatedCPPObject,global_variantStorage, QVariant, v, ptr);
669 ptr = (void*)((QVariant*)ptr)->constData();
685 ptr = (void*)((QVariant*)ptr)->constData();
670 }
686 }
671 }
687 }
672 }
688 }
673 }
689 }
674 }
690 }
675 return ptr;
691 return ptr;
676 }
692 }
677
693
678
694
679 QStringList PythonQtConv::PyObjToStringList(PyObject* val, bool strict, bool& ok) {
695 QStringList PythonQtConv::PyObjToStringList(PyObject* val, bool strict, bool& ok) {
680 QStringList v;
696 QStringList v;
681 ok = false;
697 ok = false;
682 // if we are strict, we do not want to convert a string to a stringlist
698 // if we are strict, we do not want to convert a string to a stringlist
683 // (strings in python are detected to be sequences)
699 // (strings in python are detected to be sequences)
684 if (strict &&
700 if (strict && (
685 (val->ob_type == &PyString_Type ||
701 #ifndef PY3K
702 val->ob_type == &PyString_Type ||
703 #endif
686 PyUnicode_Check(val))) {
704 PyUnicode_Check(val))) {
687 ok = false;
705 ok = false;
688 return v;
706 return v;
689 }
707 }
690 if (PySequence_Check(val)) {
708 if (PySequence_Check(val)) {
691 int count = PySequence_Size(val);
709 int count = PySequence_Size(val);
692 for (int i = 0;i<count;i++) {
710 for (int i = 0;i<count;i++) {
693 PyObject* value = PySequence_GetItem(val,i);
711 PyObject* value = PySequence_GetItem(val,i);
694 v.append(PyObjGetString(value,false,ok));
712 v.append(PyObjGetString(value,false,ok));
695 }
713 }
696 ok = true;
714 ok = true;
697 }
715 }
698 return v;
716 return v;
699 }
717 }
700
718
701 QString PythonQtConv::PyObjGetRepresentation(PyObject* val)
719 QString PythonQtConv::PyObjGetRepresentation(PyObject* val)
702 {
720 {
703 QString r;
721 QString r;
704 PyObject* str = PyObject_Repr(val);
722 PyObject* str = PyObject_Repr(val);
705 if (str) {
723 if (str) {
724 #ifdef PY3K
725 Py_UCS4 *x = PyUnicode_AsUCS4Copy(str);
726 r = QString::fromUcs4(x, PyUnicode_GetLength(str));
727 PyMem_Free(x);
728 #else
706 r = QString(PyString_AS_STRING(str));
729 r = QString(PyString_AS_STRING(str));
730 #endif
707 Py_DECREF(str);
731 Py_DECREF(str);
708 }
732 }
709 return r;
733 return r;
710 }
734 }
711
735
712 QString PythonQtConv::PyObjGetString(PyObject* val, bool strict, bool& ok) {
736 QString PythonQtConv::PyObjGetString(PyObject* val, bool strict, bool& ok) {
713 QString r;
737 QString r;
714 ok = true;
738 ok = true;
715 if (val->ob_type == &PyString_Type) {
739 #ifndef PY3K
740 if (Py_TYPE(val) == &PyString_Type) {
716 r = QString(PyString_AS_STRING(val));
741 r = QString(PyString_AS_STRING(val));
717 } else if (PyUnicode_Check(val)) {
742 } else
743 #endif
744 if (PyUnicode_Check(val)) {
745 #ifdef PY3K
746 Py_UCS4 *x = PyUnicode_AsUCS4Copy(val);
747 r = QString::fromUcs4(x, PyUnicode_GetLength(val));
748 PyMem_Free(x);
749 #else
718 PyObject *ptmp = PyUnicode_AsUTF8String(val);
750 PyObject *ptmp = PyUnicode_AsUTF8String(val);
719 if(ptmp) {
751 if(ptmp) {
720 r = QString::fromUtf8(PyString_AS_STRING(ptmp));
752 r = QString::fromUtf8(PyString_AS_STRING(ptmp));
721 Py_DECREF(ptmp);
753 Py_DECREF(ptmp);
722 }
754 }
755 #endif
723 } else if (!strict) {
756 } else if (!strict) {
724 // EXTRA: could also use _Unicode, but why should we?
757 // EXTRA: could also use _Unicode, but why should we?
725 PyObject* str = PyObject_Str(val);
758 PyObject* str = PyObject_Str(val);
726 if (str) {
759 if (str) {
760 #ifdef PY3K
761 Py_UCS4 *x = PyUnicode_AsUCS4Copy(str);
762 r = QString::fromUcs4(x, PyUnicode_GetLength(str));
763 PyMem_Free(x);
764 #else
727 r = QString(PyString_AS_STRING(str));
765 r = QString(PyString_AS_STRING(str));
766 #endif
728 Py_DECREF(str);
767 Py_DECREF(str);
729 } else {
768 } else {
730 ok = false;
769 ok = false;
731 }
770 }
732 } else {
771 } else {
733 ok = false;
772 ok = false;
734 }
773 }
735 return r;
774 return r;
736 }
775 }
737
776
738 QByteArray PythonQtConv::PyObjGetBytes(PyObject* val, bool /*strict*/, bool& ok) {
777 QByteArray PythonQtConv::PyObjGetBytes(PyObject* val, bool /*strict*/, bool& ok) {
739 // TODO: support buffer objects in general
778 // TODO: support buffer objects in general
740 QByteArray r;
779 QByteArray r;
741 ok = true;
780 ok = true;
742 if (val->ob_type == &PyString_Type) {
781 #ifdef PY3K
782 if (PyBytes_Check(val)) {
783 r = QByteArray(PyBytes_AS_STRING(val), PyBytes_GET_SIZE(val));
784 #else
785 if (Py_TYPE(val) == &PyString_Type) {
743 long size = PyString_GET_SIZE(val);
786 long size = PyString_GET_SIZE(val);
744 r = QByteArray(PyString_AS_STRING(val), size);
787 r = QByteArray(PyString_AS_STRING(val), size);
788 #endif
745 } else {
789 } else {
746 ok = false;
790 ok = false;
747 }
791 }
748 return r;
792 return r;
749 }
793 }
750
794
751 bool PythonQtConv::PyObjGetBool(PyObject* val, bool strict, bool &ok) {
795 bool PythonQtConv::PyObjGetBool(PyObject* val, bool strict, bool &ok) {
752 bool d = false;
796 bool d = false;
753 ok = false;
797 ok = false;
754 if (val == Py_False) {
798 if (val == Py_False) {
755 d = false;
799 d = false;
756 ok = true;
800 ok = true;
757 } else if (val == Py_True) {
801 } else if (val == Py_True) {
758 d = true;
802 d = true;
759 ok = true;
803 ok = true;
760 } else if (!strict) {
804 } else if (!strict) {
761 int result = PyObject_IsTrue(val);
805 int result = PyObject_IsTrue(val);
762 d = (result == 1);
806 d = (result == 1);
763 // the result is -1 if an error occurred, handle this:
807 // the result is -1 if an error occurred, handle this:
764 ok = (result != -1);
808 ok = (result != -1);
765 }
809 }
766 return d;
810 return d;
767 }
811 }
768
812
769 int PythonQtConv::PyObjGetInt(PyObject* val, bool strict, bool &ok) {
813 int PythonQtConv::PyObjGetInt(PyObject* val, bool strict, bool &ok) {
770 int d = 0;
814 int d = 0;
771 ok = true;
815 ok = true;
816 #ifndef PY3K
772 if (val->ob_type == &PyInt_Type) {
817 if (val->ob_type == &PyInt_Type) {
773 d = PyInt_AS_LONG(val);
818 d = PyInt_AS_LONG(val);
819 } else
820 #endif
821 if (Py_TYPE(val) == &PyLong_Type) {
822 // handle error on overflow!
823 d = PyLong_AsLong(val);
774 } else if (!strict) {
824 } else if (!strict) {
825 #ifndef PY3K
775 if (PyObject_TypeCheck(val, &PyInt_Type)) {
826 if (PyObject_TypeCheck(val, &PyInt_Type)) {
776 // support for derived int classes, e.g. for our enums
827 // support for derived int classes, e.g. for our enums
777 d = PyInt_AS_LONG(val);
828 d = PyInt_AS_LONG(val);
778 } else if (val->ob_type == &PyFloat_Type) {
829 } else
779 d = floor(PyFloat_AS_DOUBLE(val));
830 #endif
780 } else if (val->ob_type == &PyLong_Type) {
831 if (PyObject_TypeCheck(val, &PyLong_Type)) {
781 // handle error on overflow!
782 d = PyLong_AsLong(val);
832 d = PyLong_AsLong(val);
833 } else if (Py_TYPE(val) == &PyFloat_Type) {
834 d = floor(PyFloat_AS_DOUBLE(val));
783 } else if (val == Py_False) {
835 } else if (val == Py_False) {
784 d = 0;
836 d = 0;
785 } else if (val == Py_True) {
837 } else if (val == Py_True) {
786 d = 1;
838 d = 1;
787 } else {
839 } else {
788 PyErr_Clear();
840 PyErr_Clear();
789 // PyInt_AsLong will try conversion to an int if the object is not an int:
841 // PyInt_AsLong will try conversion to an int if the object is not an int:
790 d = PyInt_AsLong(val);
842 d = PyLong_AsLong(val);
791 if (PyErr_Occurred()) {
843 if (PyErr_Occurred()) {
792 ok = false;
844 ok = false;
793 PyErr_Clear();
845 PyErr_Clear();
794 }
846 }
795 }
847 }
796 } else {
848 } else {
797 ok = false;
849 ok = false;
798 }
850 }
799 return d;
851 return d;
800 }
852 }
801
853
802 qint64 PythonQtConv::PyObjGetLongLong(PyObject* val, bool strict, bool &ok) {
854 qint64 PythonQtConv::PyObjGetLongLong(PyObject* val, bool strict, bool &ok) {
803 qint64 d = 0;
855 qint64 d = 0;
804 ok = true;
856 ok = true;
857 #ifndef PY3K
805 if (val->ob_type == &PyInt_Type) {
858 if (val->ob_type == &PyInt_Type) {
806 d = PyInt_AS_LONG(val);
859 d = PyInt_AS_LONG(val);
807 } else if (val->ob_type == &PyLong_Type) {
860 } else
861 #endif
862 if (Py_TYPE(val) == &PyLong_Type) {
808 d = PyLong_AsLongLong(val);
863 d = PyLong_AsLongLong(val);
809 } else if (!strict) {
864 } else if (!strict) {
865 #ifndef PY3K
810 if (PyObject_TypeCheck(val, &PyInt_Type)) {
866 if (PyObject_TypeCheck(val, &PyInt_Type)) {
811 // support for derived int classes, e.g. for our enums
867 // support for derived int classes, e.g. for our enums
812 d = PyInt_AS_LONG(val);
868 d = PyInt_AS_LONG(val);
813 } else if (val->ob_type == &PyFloat_Type) {
869 } else
870 #endif
871 if (PyObject_TypeCheck(val, &PyLong_Type)) {
872 d = PyLong_AsLong(val);
873 } else if (Py_TYPE(val) == &PyFloat_Type) {
814 d = floor(PyFloat_AS_DOUBLE(val));
874 d = floor(PyFloat_AS_DOUBLE(val));
815 } else if (val == Py_False) {
875 } else if (val == Py_False) {
816 d = 0;
876 d = 0;
817 } else if (val == Py_True) {
877 } else if (val == Py_True) {
818 d = 1;
878 d = 1;
819 } else {
879 } else {
820 PyErr_Clear();
880 PyErr_Clear();
821 // PyLong_AsLongLong will try conversion to an int if the object is not an int:
881 // PyLong_AsLongLong will try conversion to an int if the object is not an int:
822 d = PyLong_AsLongLong(val);
882 d = PyLong_AsLongLong(val);
823 if (PyErr_Occurred()) {
883 if (PyErr_Occurred()) {
824 ok = false;
884 ok = false;
825 PyErr_Clear();
885 PyErr_Clear();
826 }
886 }
827 }
887 }
828 } else {
888 } else {
829 ok = false;
889 ok = false;
830 }
890 }
831 return d;
891 return d;
832 }
892 }
833
893
834 quint64 PythonQtConv::PyObjGetULongLong(PyObject* val, bool strict, bool &ok) {
894 quint64 PythonQtConv::PyObjGetULongLong(PyObject* val, bool strict, bool &ok) {
835 quint64 d = 0;
895 quint64 d = 0;
836 ok = true;
896 ok = true;
837 if (PyObject_TypeCheck(val, &PyInt_Type)) {
897 #ifndef PY3K
898 if (Py_TYPE(val) == &PyInt_Type) {
838 d = PyInt_AS_LONG(val);
899 d = PyInt_AS_LONG(val);
839 } else if (val->ob_type == &PyLong_Type) {
900 } else
901 #endif
902 if (Py_TYPE(val) == &PyLong_Type) {
840 d = PyLong_AsLongLong(val);
903 d = PyLong_AsLongLong(val);
841 } else if (!strict) {
904 } else if (!strict) {
905 #ifndef PY3K
842 if (PyObject_TypeCheck(val, &PyInt_Type)) {
906 if (PyObject_TypeCheck(val, &PyInt_Type)) {
843 // support for derived int classes, e.g. for our enums
907 // support for derived int classes, e.g. for our enums
844 d = PyInt_AS_LONG(val);
908 d = PyInt_AS_LONG(val);
845 } else if (val->ob_type == &PyFloat_Type) {
909 } else
910 #endif
911 if (PyObject_TypeCheck(val, &PyLong_Type)) {
912 d = PyLong_AsLong(val);
913 } else if (Py_TYPE(val) == &PyFloat_Type) {
846 d = floor(PyFloat_AS_DOUBLE(val));
914 d = floor(PyFloat_AS_DOUBLE(val));
847 } else if (val == Py_False) {
915 } else if (val == Py_False) {
848 d = 0;
916 d = 0;
849 } else if (val == Py_True) {
917 } else if (val == Py_True) {
850 d = 1;
918 d = 1;
851 } else {
919 } else {
852 PyErr_Clear();
920 PyErr_Clear();
853 // PyLong_AsLongLong will try conversion to an int if the object is not an int:
921 // PyLong_AsLongLong will try conversion to an int if the object is not an int:
854 d = PyLong_AsLongLong(val);
922 d = PyLong_AsLongLong(val);
855 if (PyErr_Occurred()) {
923 if (PyErr_Occurred()) {
856 PyErr_Clear();
924 PyErr_Clear();
857 ok = false;
925 ok = false;
858 }
926 }
859 }
927 }
860 } else {
928 } else {
861 ok = false;
929 ok = false;
862 }
930 }
863 return d;
931 return d;
864 }
932 }
865
933
866 double PythonQtConv::PyObjGetDouble(PyObject* val, bool strict, bool &ok) {
934 double PythonQtConv::PyObjGetDouble(PyObject* val, bool strict, bool &ok) {
867 double d = 0;
935 double d = 0;
868 ok = true;
936 ok = true;
869 if (val->ob_type == &PyFloat_Type) {
937 if (val->ob_type == &PyFloat_Type) {
870 d = PyFloat_AS_DOUBLE(val);
938 d = PyFloat_AS_DOUBLE(val);
871 } else if (!strict) {
939 } else if (!strict) {
940 #ifndef PY3K
872 if (PyObject_TypeCheck(val, &PyInt_Type)) {
941 if (PyObject_TypeCheck(val, &PyInt_Type)) {
873 d = PyInt_AS_LONG(val);
942 d = PyInt_AS_LONG(val);
874 } else if (val->ob_type == &PyLong_Type) {
943 } else
944 #endif
945 if (PyLong_Check(val)) {
875 d = PyLong_AsLong(val);
946 d = PyLong_AsLong(val);
876 } else if (val == Py_False) {
947 } else if (val == Py_False) {
877 d = 0;
948 d = 0;
878 } else if (val == Py_True) {
949 } else if (val == Py_True) {
879 d = 1;
950 d = 1;
880 } else {
951 } else {
881 PyErr_Clear();
952 PyErr_Clear();
882 // PyFloat_AsDouble will try conversion to a double if the object is not a float:
953 // PyFloat_AsDouble will try conversion to a double if the object is not a float:
883 d = PyFloat_AsDouble(val);
954 d = PyFloat_AsDouble(val);
884 if (PyErr_Occurred()) {
955 if (PyErr_Occurred()) {
885 PyErr_Clear();
956 PyErr_Clear();
886 ok = false;
957 ok = false;
887 }
958 }
888 }
959 }
889 } else {
960 } else {
890 ok = false;
961 ok = false;
891 }
962 }
892 return d;
963 return d;
893 }
964 }
894
965
895 QVariant PythonQtConv::PyObjToQVariant(PyObject* val, int type)
966 QVariant PythonQtConv::PyObjToQVariant(PyObject* val, int type)
896 {
967 {
897 QVariant v;
968 QVariant v;
898 bool ok = true;
969 bool ok = true;
899
970
900 if (type==-1) {
971 if (type==-1) {
901 // no special type requested
972 // no special type requested
973 #ifdef PY3K
974 if (PyBytes_Check(val)) {
975 type = QVariant::ByteArray;
976 } else if (PyUnicode_Check(val)) {
977 #else
902 if (val->ob_type==&PyString_Type || val->ob_type==&PyUnicode_Type) {
978 if (val->ob_type==&PyString_Type || val->ob_type==&PyUnicode_Type) {
979 #endif
903 type = QVariant::String;
980 type = QVariant::String;
904 } else if (val == Py_False || val == Py_True) {
981 } else if (val == Py_False || val == Py_True) {
905 type = QVariant::Bool;
982 type = QVariant::Bool;
983 #ifndef PY3K
906 } else if (PyObject_TypeCheck(val, &PyInt_Type)) {
984 } else if (PyObject_TypeCheck(val, &PyInt_Type)) {
907 type = QVariant::Int;
985 type = QVariant::Int;
908 } else if (val->ob_type==&PyLong_Type) {
986 #endif
987 } else if (PyLong_Check(val)) {
909 type = QVariant::LongLong;
988 type = QVariant::LongLong;
910 } else if (val->ob_type==&PyFloat_Type) {
989 } else if (PyFloat_Check(val)) {
911 type = QVariant::Double;
990 type = QVariant::Double;
912 } else if (PyObject_TypeCheck(val, &PythonQtInstanceWrapper_Type)) {
991 } else if (PyObject_TypeCheck(val, &PythonQtInstanceWrapper_Type)) {
913 PythonQtInstanceWrapper* wrap = (PythonQtInstanceWrapper*)val;
992 PythonQtInstanceWrapper* wrap = (PythonQtInstanceWrapper*)val;
914 // c++ wrapper, check if the class names of the c++ objects match
993 // c++ wrapper, check if the class names of the c++ objects match
915 if (wrap->classInfo()->isCPPWrapper()) {
994 if (wrap->classInfo()->isCPPWrapper()) {
916 if (wrap->classInfo()->metaTypeId()>0) {
995 if (wrap->classInfo()->metaTypeId()>0) {
917 // construct a new variant from the C++ object if it has a meta type (this will COPY the object!)
996 // construct a new variant from the C++ object if it has a meta type (this will COPY the object!)
918 v = QVariant(wrap->classInfo()->metaTypeId(), wrap->_wrappedPtr);
997 v = QVariant(wrap->classInfo()->metaTypeId(), wrap->_wrappedPtr);
919 } else {
998 } else {
920 // TODOXXX we could as well check if there is a registered meta type for "classname*", so that we may pass
999 // TODOXXX we could as well check if there is a registered meta type for "classname*", so that we may pass
921 // the pointer here...
1000 // the pointer here...
922 // is this worth anything? we loose the knowledge of the cpp object type
1001 // is this worth anything? we loose the knowledge of the cpp object type
923 v = qVariantFromValue(wrap->_wrappedPtr);
1002 v = qVariantFromValue(wrap->_wrappedPtr);
924 }
1003 }
925 } else {
1004 } else {
926 // this gives us a QObject pointer
1005 // this gives us a QObject pointer
927 QObject* myObject = wrap->_obj;
1006 QObject* myObject = wrap->_obj;
928 v = qVariantFromValue(myObject);
1007 v = qVariantFromValue(myObject);
929 }
1008 }
930 return v;
1009 return v;
931 } else if (val->ob_type==&PyDict_Type) {
1010 } else if (PyDict_Check(val)) {
932 type = QVariant::Map;
1011 type = QVariant::Map;
933 } else if (val->ob_type==&PyList_Type || val->ob_type==&PyTuple_Type || PySequence_Check(val)) {
1012 } else if (PyList_Check(val) || PyTuple_Check(val) || PySequence_Check(val)) {
934 type = QVariant::List;
1013 type = QVariant::List;
935 } else if (val == Py_None) {
1014 } else if (val == Py_None) {
936 // none is invalid
1015 // none is invalid
937 type = QVariant::Invalid;
1016 type = QVariant::Invalid;
938 } else {
1017 } else {
939 // this used to be:
1018 // this used to be:
940 // type = QVariant::String;
1019 // type = QVariant::String;
941 // but now we want to transport the Python Objects directly:
1020 // but now we want to transport the Python Objects directly:
942 PythonQtObjectPtr o(val);
1021 PythonQtObjectPtr o(val);
943 v = qVariantFromValue(o);
1022 v = qVariantFromValue(o);
944 return v;
1023 return v;
945 }
1024 }
946 }
1025 }
947 // special type request:
1026 // special type request:
948 switch (type) {
1027 switch (type) {
949 case QVariant::Invalid:
1028 case QVariant::Invalid:
950 return v;
1029 return v;
951 break;
1030 break;
952 case QVariant::Int:
1031 case QVariant::Int:
953 {
1032 {
954 int d = PyObjGetInt(val, false, ok);
1033 int d = PyObjGetInt(val, false, ok);
955 if (ok) return QVariant(d);
1034 if (ok) return QVariant(d);
956 }
1035 }
957 break;
1036 break;
958 case QVariant::UInt:
1037 case QVariant::UInt:
959 {
1038 {
960 int d = PyObjGetInt(val, false,ok);
1039 int d = PyObjGetInt(val, false,ok);
961 if (ok) v = QVariant((unsigned int)d);
1040 if (ok) v = QVariant((unsigned int)d);
962 }
1041 }
963 break;
1042 break;
964 case QVariant::Bool:
1043 case QVariant::Bool:
965 {
1044 {
966 int d = PyObjGetBool(val,false,ok);
1045 int d = PyObjGetBool(val,false,ok);
967 if (ok) v = QVariant((bool)(d!=0));
1046 if (ok) v = QVariant((bool)(d!=0));
968 }
1047 }
969 break;
1048 break;
970 case QVariant::Double:
1049 case QVariant::Double:
971 {
1050 {
972 double d = PyObjGetDouble(val,false,ok);
1051 double d = PyObjGetDouble(val,false,ok);
973 if (ok) v = QVariant(d);
1052 if (ok) v = QVariant(d);
974 break;
1053 break;
975 }
1054 }
976 case QMetaType::Float:
1055 case QMetaType::Float:
977 {
1056 {
978 float d = (float) PyObjGetDouble(val,false,ok);
1057 float d = (float) PyObjGetDouble(val,false,ok);
979 if (ok) v = qVariantFromValue(d);
1058 if (ok) v = qVariantFromValue(d);
980 break;
1059 break;
981 }
1060 }
982 case QMetaType::Long:
1061 case QMetaType::Long:
983 {
1062 {
984 long d = (long) PyObjGetLongLong(val,false,ok);
1063 long d = (long) PyObjGetLongLong(val,false,ok);
985 if (ok) v = qVariantFromValue(d);
1064 if (ok) v = qVariantFromValue(d);
986 break;
1065 break;
987 }
1066 }
988 case QMetaType::ULong:
1067 case QMetaType::ULong:
989 {
1068 {
990 unsigned long d = (unsigned long) PyObjGetLongLong(val,false,ok);
1069 unsigned long d = (unsigned long) PyObjGetLongLong(val,false,ok);
991 if (ok) v = qVariantFromValue(d);
1070 if (ok) v = qVariantFromValue(d);
992 break;
1071 break;
993 }
1072 }
994 case QMetaType::LongLong:
1073 case QMetaType::LongLong:
995 {
1074 {
996 qint64 d = PyObjGetLongLong(val, false, ok);
1075 qint64 d = PyObjGetLongLong(val, false, ok);
997 if (ok) v = qVariantFromValue(d);
1076 if (ok) v = qVariantFromValue(d);
998 }
1077 }
999 break;
1078 break;
1000 case QMetaType::ULongLong:
1079 case QMetaType::ULongLong:
1001 {
1080 {
1002 quint64 d = PyObjGetULongLong(val, false, ok);
1081 quint64 d = PyObjGetULongLong(val, false, ok);
1003 if (ok) v = qVariantFromValue(d);
1082 if (ok) v = qVariantFromValue(d);
1004 }
1083 }
1005 break;
1084 break;
1006 case QMetaType::Short:
1085 case QMetaType::Short:
1007 {
1086 {
1008 short d = (short) PyObjGetInt(val,false,ok);
1087 short d = (short) PyObjGetInt(val,false,ok);
1009 if (ok) v = qVariantFromValue(d);
1088 if (ok) v = qVariantFromValue(d);
1010 break;
1089 break;
1011 }
1090 }
1012 case QMetaType::UShort:
1091 case QMetaType::UShort:
1013 {
1092 {
1014 unsigned short d = (unsigned short) PyObjGetInt(val,false,ok);
1093 unsigned short d = (unsigned short) PyObjGetInt(val,false,ok);
1015 if (ok) v = qVariantFromValue(d);
1094 if (ok) v = qVariantFromValue(d);
1016 break;
1095 break;
1017 }
1096 }
1018 case QMetaType::Char:
1097 case QMetaType::Char:
1019 {
1098 {
1020 char d = (char) PyObjGetInt(val,false,ok);
1099 char d = (char) PyObjGetInt(val,false,ok);
1021 if (ok) v = qVariantFromValue(d);
1100 if (ok) v = qVariantFromValue(d);
1022 break;
1101 break;
1023 }
1102 }
1024 case QMetaType::UChar:
1103 case QMetaType::UChar:
1025 {
1104 {
1026 unsigned char d = (unsigned char) PyObjGetInt(val,false,ok);
1105 unsigned char d = (unsigned char) PyObjGetInt(val,false,ok);
1027 if (ok) v = qVariantFromValue(d);
1106 if (ok) v = qVariantFromValue(d);
1028 break;
1107 break;
1029 }
1108 }
1030
1109
1031 case QVariant::ByteArray:
1110 case QVariant::ByteArray:
1032 case QVariant::String:
1111 case QVariant::String:
1033 {
1112 {
1034 bool ok;
1113 bool ok;
1035 v = QVariant(PyObjGetString(val, false, ok));
1114 v = QVariant(PyObjGetString(val, false, ok));
1036 }
1115 }
1037 break;
1116 break;
1038
1117
1039 // these are important for MeVisLab
1118 // these are important for MeVisLab
1040 case QVariant::Map:
1119 case QVariant::Map:
1041 {
1120 {
1042 if (PyMapping_Check(val)) {
1121 if (PyMapping_Check(val)) {
1043 QMap<QString,QVariant> map;
1122 QMap<QString,QVariant> map;
1044 PyObject* items = PyMapping_Items(val);
1123 PyObject* items = PyMapping_Items(val);
1045 if (items) {
1124 if (items) {
1046 int count = PyList_Size(items);
1125 int count = PyList_Size(items);
1047 PyObject* value;
1126 PyObject* value;
1048 PyObject* key;
1127 PyObject* key;
1049 PyObject* tuple;
1128 PyObject* tuple;
1050 for (int i = 0;i<count;i++) {
1129 for (int i = 0;i<count;i++) {
1051 tuple = PyList_GetItem(items,i);
1130 tuple = PyList_GetItem(items,i);
1052 key = PyTuple_GetItem(tuple, 0);
1131 key = PyTuple_GetItem(tuple, 0);
1053 value = PyTuple_GetItem(tuple, 1);
1132 value = PyTuple_GetItem(tuple, 1);
1054 map.insert(PyObjGetString(key), PyObjToQVariant(value,-1));
1133 map.insert(PyObjGetString(key), PyObjToQVariant(value,-1));
1055 }
1134 }
1056 Py_DECREF(items);
1135 Py_DECREF(items);
1057 v = map;
1136 v = map;
1058 }
1137 }
1059 }
1138 }
1060 }
1139 }
1061 break;
1140 break;
1062 case QVariant::List:
1141 case QVariant::List:
1063 if (PySequence_Check(val)) {
1142 if (PySequence_Check(val)) {
1064 QVariantList list;
1143 QVariantList list;
1065 int count = PySequence_Size(val);
1144 int count = PySequence_Size(val);
1066 PyObject* value;
1145 PyObject* value;
1067 for (int i = 0;i<count;i++) {
1146 for (int i = 0;i<count;i++) {
1068 value = PySequence_GetItem(val,i);
1147 value = PySequence_GetItem(val,i);
1069 list.append(PyObjToQVariant(value, -1));
1148 list.append(PyObjToQVariant(value, -1));
1070 }
1149 }
1071 v = list;
1150 v = list;
1072 }
1151 }
1073 break;
1152 break;
1074 case QVariant::StringList:
1153 case QVariant::StringList:
1075 {
1154 {
1076 bool ok;
1155 bool ok;
1077 QStringList l = PyObjToStringList(val, false, ok);
1156 QStringList l = PyObjToStringList(val, false, ok);
1078 if (ok) {
1157 if (ok) {
1079 v = l;
1158 v = l;
1080 }
1159 }
1081 }
1160 }
1082 break;
1161 break;
1083
1162
1084 default:
1163 default:
1085 if (PyObject_TypeCheck(val, &PythonQtInstanceWrapper_Type)) {
1164 if (PyObject_TypeCheck(val, &PythonQtInstanceWrapper_Type)) {
1086 PythonQtInstanceWrapper* wrap = (PythonQtInstanceWrapper*)val;
1165 PythonQtInstanceWrapper* wrap = (PythonQtInstanceWrapper*)val;
1087 if (wrap->classInfo()->isCPPWrapper() && wrap->classInfo()->metaTypeId() == type) {
1166 if (wrap->classInfo()->isCPPWrapper() && wrap->classInfo()->metaTypeId() == type) {
1088 // construct a new variant from the C++ object if it has the same meta type
1167 // construct a new variant from the C++ object if it has the same meta type
1089 v = QVariant(type, wrap->_wrappedPtr);
1168 v = QVariant(type, wrap->_wrappedPtr);
1090 } else {
1169 } else {
1091 v = QVariant();
1170 v = QVariant();
1092 }
1171 }
1093 } else {
1172 } else {
1094 v = QVariant();
1173 v = QVariant();
1095 }
1174 }
1096 }
1175 }
1097 return v;
1176 return v;
1098 }
1177 }
1099
1178
1100 PyObject* PythonQtConv::QStringToPyObject(const QString& str)
1179 PyObject* PythonQtConv::QStringToPyObject(const QString& str)
1101 {
1180 {
1102 if (str.isNull()) {
1181 if (str.isNull()) {
1182 #ifdef PY3K
1183 return PyUnicode_New(0, 0);
1184 #else
1103 return PyString_FromString("");
1185 return PyString_FromString("");
1186 #endif
1104 } else {
1187 } else {
1105 return PyUnicode_DecodeUTF16((const char*)str.utf16(), str.length()*2, NULL, NULL);
1188 return PyUnicode_DecodeUTF16((const char*)str.utf16(), str.length()*2, NULL, NULL);
1106 }
1189 }
1107 }
1190 }
1108
1191
1109 PyObject* PythonQtConv::QStringListToPyObject(const QStringList& list)
1192 PyObject* PythonQtConv::QStringListToPyObject(const QStringList& list)
1110 {
1193 {
1111 PyObject* result = PyTuple_New(list.count());
1194 PyObject* result = PyTuple_New(list.count());
1112 int i = 0;
1195 int i = 0;
1113 QString str;
1196 QString str;
1114 Q_FOREACH (str, list) {
1197 Q_FOREACH (str, list) {
1115 PyTuple_SET_ITEM(result, i, PythonQtConv::QStringToPyObject(str));
1198 PyTuple_SET_ITEM(result, i, PythonQtConv::QStringToPyObject(str));
1116 i++;
1199 i++;
1117 }
1200 }
1118 // why is the error state bad after this?
1201 // why is the error state bad after this?
1119 PyErr_Clear();
1202 PyErr_Clear();
1120 return result;
1203 return result;
1121 }
1204 }
1122
1205
1123 PyObject* PythonQtConv::QStringListToPyList(const QStringList& list)
1206 PyObject* PythonQtConv::QStringListToPyList(const QStringList& list)
1124 {
1207 {
1125 PyObject* result = PyList_New(list.count());
1208 PyObject* result = PyList_New(list.count());
1126 int i = 0;
1209 int i = 0;
1127 for (QStringList::ConstIterator it = list.begin(); it!=list.end(); ++it) {
1210 for (QStringList::ConstIterator it = list.begin(); it!=list.end(); ++it) {
1128 PyList_SET_ITEM(result, i, PythonQtConv::QStringToPyObject(*it));
1211 PyList_SET_ITEM(result, i, PythonQtConv::QStringToPyObject(*it));
1129 i++;
1212 i++;
1130 }
1213 }
1131 return result;
1214 return result;
1132 }
1215 }
1133
1216
1134 PyObject* PythonQtConv::QVariantToPyObject(const QVariant& v)
1217 PyObject* PythonQtConv::QVariantToPyObject(const QVariant& v)
1135 {
1218 {
1136 return ConvertQtValueToPythonInternal(v.userType(), (void*)v.constData());
1219 return ConvertQtValueToPythonInternal(v.userType(), (void*)v.constData());
1137 }
1220 }
1138
1221
1139 PyObject* PythonQtConv::QVariantMapToPyObject(const QVariantMap& m) {
1222 PyObject* PythonQtConv::QVariantMapToPyObject(const QVariantMap& m) {
1140 PyObject* result = PyDict_New();
1223 PyObject* result = PyDict_New();
1141 QVariantMap::const_iterator t = m.constBegin();
1224 QVariantMap::const_iterator t = m.constBegin();
1142 PyObject* key;
1225 PyObject* key;
1143 PyObject* val;
1226 PyObject* val;
1144 for (;t!=m.end();t++) {
1227 for (;t!=m.end();t++) {
1145 key = QStringToPyObject(t.key());
1228 key = QStringToPyObject(t.key());
1146 val = QVariantToPyObject(t.value());
1229 val = QVariantToPyObject(t.value());
1147 PyDict_SetItem(result, key, val);
1230 PyDict_SetItem(result, key, val);
1148 Py_DECREF(key);
1231 Py_DECREF(key);
1149 Py_DECREF(val);
1232 Py_DECREF(val);
1150 }
1233 }
1151 return result;
1234 return result;
1152 }
1235 }
1153
1236
1154 PyObject* PythonQtConv::QVariantListToPyObject(const QVariantList& l) {
1237 PyObject* PythonQtConv::QVariantListToPyObject(const QVariantList& l) {
1155 PyObject* result = PyTuple_New(l.count());
1238 PyObject* result = PyTuple_New(l.count());
1156 int i = 0;
1239 int i = 0;
1157 QVariant v;
1240 QVariant v;
1158 Q_FOREACH (v, l) {
1241 Q_FOREACH (v, l) {
1159 PyTuple_SET_ITEM(result, i, PythonQtConv::QVariantToPyObject(v));
1242 PyTuple_SET_ITEM(result, i, PythonQtConv::QVariantToPyObject(v));
1160 i++;
1243 i++;
1161 }
1244 }
1162 // why is the error state bad after this?
1245 // why is the error state bad after this?
1163 PyErr_Clear();
1246 PyErr_Clear();
1164 return result;
1247 return result;
1165 }
1248 }
1166
1249
1167 PyObject* PythonQtConv::ConvertQListOfPointerTypeToPythonList(QList<void*>* list, const QByteArray& typeName)
1250 PyObject* PythonQtConv::ConvertQListOfPointerTypeToPythonList(QList<void*>* list, const QByteArray& typeName)
1168 {
1251 {
1169 PyObject* result = PyTuple_New(list->count());
1252 PyObject* result = PyTuple_New(list->count());
1170 int i = 0;
1253 int i = 0;
1171 Q_FOREACH (void* value, *list) {
1254 Q_FOREACH (void* value, *list) {
1172 PyTuple_SET_ITEM(result, i, PythonQt::priv()->wrapPtr(value, typeName));
1255 PyTuple_SET_ITEM(result, i, PythonQt::priv()->wrapPtr(value, typeName));
1173 i++;
1256 i++;
1174 }
1257 }
1175 return result;
1258 return result;
1176 }
1259 }
1177
1260
1178 bool PythonQtConv::ConvertPythonListToQListOfPointerType(PyObject* obj, QList<void*>* list, const QByteArray& type, bool /*strict*/)
1261 bool PythonQtConv::ConvertPythonListToQListOfPointerType(PyObject* obj, QList<void*>* list, const QByteArray& type, bool /*strict*/)
1179 {
1262 {
1180 bool result = false;
1263 bool result = false;
1181 if (PySequence_Check(obj)) {
1264 if (PySequence_Check(obj)) {
1182 result = true;
1265 result = true;
1183 int count = PySequence_Size(obj);
1266 int count = PySequence_Size(obj);
1184 PyObject* value;
1267 PyObject* value;
1185 for (int i = 0;i<count;i++) {
1268 for (int i = 0;i<count;i++) {
1186 value = PySequence_GetItem(obj,i);
1269 value = PySequence_GetItem(obj,i);
1187 if (PyObject_TypeCheck(value, &PythonQtInstanceWrapper_Type)) {
1270 if (PyObject_TypeCheck(value, &PythonQtInstanceWrapper_Type)) {
1188 PythonQtInstanceWrapper* wrap = (PythonQtInstanceWrapper*)value;
1271 PythonQtInstanceWrapper* wrap = (PythonQtInstanceWrapper*)value;
1189 bool ok;
1272 bool ok;
1190 void* object = castWrapperTo(wrap, type, ok);
1273 void* object = castWrapperTo(wrap, type, ok);
1191 if (ok) {
1274 if (ok) {
1192 list->append(object);
1275 list->append(object);
1193 } else {
1276 } else {
1194 result = false;
1277 result = false;
1195 break;
1278 break;
1196 }
1279 }
1197 }
1280 }
1198 }
1281 }
1199 }
1282 }
1200 return result;
1283 return result;
1201 }
1284 }
1202
1285
1203 int PythonQtConv::getInnerTemplateMetaType(const QByteArray& typeName)
1286 int PythonQtConv::getInnerTemplateMetaType(const QByteArray& typeName)
1204 {
1287 {
1205 int idx = typeName.indexOf("<");
1288 int idx = typeName.indexOf("<");
1206 if (idx>0) {
1289 if (idx>0) {
1207 int idx2 = typeName.indexOf(">");
1290 int idx2 = typeName.indexOf(">");
1208 if (idx2>0) {
1291 if (idx2>0) {
1209 QByteArray innerType = typeName.mid(idx+1,idx2-idx-1);
1292 QByteArray innerType = typeName.mid(idx+1,idx2-idx-1);
1210 return QMetaType::type(innerType.constData());
1293 return QMetaType::type(innerType.constData());
1211 }
1294 }
1212 }
1295 }
1213 return QMetaType::Void;
1296 return QMetaType::Void;
1214 }
1297 }
1215
1298
1216
1299
1217 QString PythonQtConv::CPPObjectToString(int type, const void* data) {
1300 QString PythonQtConv::CPPObjectToString(int type, const void* data) {
1218 QString r;
1301 QString r;
1219 switch (type) {
1302 switch (type) {
1220 case QVariant::Size: {
1303 case QVariant::Size: {
1221 const QSize* s = static_cast<const QSize*>(data);
1304 const QSize* s = static_cast<const QSize*>(data);
1222 r = QString::number(s->width()) + ", " + QString::number(s->height());
1305 r = QString::number(s->width()) + ", " + QString::number(s->height());
1223 }
1306 }
1224 break;
1307 break;
1225 case QVariant::SizeF: {
1308 case QVariant::SizeF: {
1226 const QSizeF* s = static_cast<const QSizeF*>(data);
1309 const QSizeF* s = static_cast<const QSizeF*>(data);
1227 r = QString::number(s->width()) + ", " + QString::number(s->height());
1310 r = QString::number(s->width()) + ", " + QString::number(s->height());
1228 }
1311 }
1229 break;
1312 break;
1230 case QVariant::Point: {
1313 case QVariant::Point: {
1231 const QPoint* s = static_cast<const QPoint*>(data);
1314 const QPoint* s = static_cast<const QPoint*>(data);
1232 r = QString::number(s->x()) + ", " + QString::number(s->y());
1315 r = QString::number(s->x()) + ", " + QString::number(s->y());
1233 }
1316 }
1234 break;
1317 break;
1235 case QVariant::PointF: {
1318 case QVariant::PointF: {
1236 const QPointF* s = static_cast<const QPointF*>(data);
1319 const QPointF* s = static_cast<const QPointF*>(data);
1237 r = QString::number(s->x()) + ", " + QString::number(s->y());
1320 r = QString::number(s->x()) + ", " + QString::number(s->y());
1238 }
1321 }
1239 break;
1322 break;
1240 case QVariant::Rect: {
1323 case QVariant::Rect: {
1241 const QRect* s = static_cast<const QRect*>(data);
1324 const QRect* s = static_cast<const QRect*>(data);
1242 r = QString::number(s->x()) + ", " + QString::number(s->y());
1325 r = QString::number(s->x()) + ", " + QString::number(s->y());
1243 r += ", " + QString::number(s->width()) + ", " + QString::number(s->height());
1326 r += ", " + QString::number(s->width()) + ", " + QString::number(s->height());
1244 }
1327 }
1245 break;
1328 break;
1246 case QVariant::RectF: {
1329 case QVariant::RectF: {
1247 const QRectF* s = static_cast<const QRectF*>(data);
1330 const QRectF* s = static_cast<const QRectF*>(data);
1248 r = QString::number(s->x()) + ", " + QString::number(s->y());
1331 r = QString::number(s->x()) + ", " + QString::number(s->y());
1249 r += ", " + QString::number(s->width()) + ", " + QString::number(s->height());
1332 r += ", " + QString::number(s->width()) + ", " + QString::number(s->height());
1250 }
1333 }
1251 break;
1334 break;
1252 case QVariant::Date: {
1335 case QVariant::Date: {
1253 const QDate* s = static_cast<const QDate*>(data);
1336 const QDate* s = static_cast<const QDate*>(data);
1254 r = s->toString(Qt::ISODate);
1337 r = s->toString(Qt::ISODate);
1255 }
1338 }
1256 break;
1339 break;
1257 case QVariant::DateTime: {
1340 case QVariant::DateTime: {
1258 const QDateTime* s = static_cast<const QDateTime*>(data);
1341 const QDateTime* s = static_cast<const QDateTime*>(data);
1259 r = s->toString(Qt::ISODate);
1342 r = s->toString(Qt::ISODate);
1260 }
1343 }
1261 break;
1344 break;
1262 case QVariant::Time: {
1345 case QVariant::Time: {
1263 const QTime* s = static_cast<const QTime*>(data);
1346 const QTime* s = static_cast<const QTime*>(data);
1264 r = s->toString(Qt::ISODate);
1347 r = s->toString(Qt::ISODate);
1265 }
1348 }
1266 break;
1349 break;
1267 case QVariant::Pixmap:
1350 case QVariant::Pixmap:
1268 {
1351 {
1269 const QPixmap* s = static_cast<const QPixmap*>(data);
1352 const QPixmap* s = static_cast<const QPixmap*>(data);
1270 r = QString("Pixmap ") + QString::number(s->width()) + ", " + QString::number(s->height());
1353 r = QString("Pixmap ") + QString::number(s->width()) + ", " + QString::number(s->height());
1271 }
1354 }
1272 break;
1355 break;
1273 case QVariant::Image:
1356 case QVariant::Image:
1274 {
1357 {
1275 const QImage* s = static_cast<const QImage*>(data);
1358 const QImage* s = static_cast<const QImage*>(data);
1276 r = QString("Image ") + QString::number(s->width()) + ", " + QString::number(s->height());
1359 r = QString("Image ") + QString::number(s->width()) + ", " + QString::number(s->height());
1277 }
1360 }
1278 break;
1361 break;
1279 case QVariant::Url:
1362 case QVariant::Url:
1280 {
1363 {
1281 const QUrl* s = static_cast<const QUrl*>(data);
1364 const QUrl* s = static_cast<const QUrl*>(data);
1282 r = s->toString();
1365 r = s->toString();
1283 }
1366 }
1284 break;
1367 break;
1285 //TODO: add more printing for other variant types
1368 //TODO: add more printing for other variant types
1286 default:
1369 default:
1287 // this creates a copy, but that should not be expensive for typical simple variants
1370 // this creates a copy, but that should not be expensive for typical simple variants
1288 // (but we do not want to do this for our won user types!
1371 // (but we do not want to do this for our won user types!
1289 if (type>0 && type < (int)QVariant::UserType) {
1372 if (type>0 && type < (int)QVariant::UserType) {
1290 QVariant v(type, data);
1373 QVariant v(type, data);
1291 r = v.toString();
1374 r = v.toString();
1292 }
1375 }
1293 }
1376 }
1294 return r;
1377 return r;
1295 }
1378 }
@@ -1,828 +1,853
1 /*
1 /*
2 *
2 *
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
4 *
4 *
5 * This library is free software; you can redistribute it and/or
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
8 * version 2.1 of the License, or (at your option) any later version.
9 *
9 *
10 * This library is distributed in the hope that it will be useful,
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
13 * Lesser General Public License for more details.
14 *
14 *
15 * Further, this software is distributed without any warranty that it is
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
20 * other software, or any other product whatsoever.
21 *
21 *
22 * You should have received a copy of the GNU Lesser General Public
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
25 *
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
27 * 28359 Bremen, Germany or:
27 * 28359 Bremen, Germany or:
28 *
28 *
29 * http://www.mevis.de
29 * http://www.mevis.de
30 *
30 *
31 */
31 */
32
32
33 //----------------------------------------------------------------------------------
33 //----------------------------------------------------------------------------------
34 /*!
34 /*!
35 // \file PythonQtImporter.h
35 // \file PythonQtImporter.h
36 // \author Florian Link
36 // \author Florian Link
37 // \author Last changed by $Author: florian $
37 // \author Last changed by $Author: florian $
38 // \date 2006-05
38 // \date 2006-05
39 */
39 */
40 // This module was inspired by the zipimport.c module of the original
40 // This module was inspired by the zipimport.c module of the original
41 // Python distribution. Most of the functions are identical or slightly
41 // Python distribution. Most of the functions are identical or slightly
42 // modified to do all the loading of Python files via an external file interface.
42 // modified to do all the loading of Python files via an external file interface.
43 // In contrast to zipimport.c, this module also writes *.pyc files
43 // In contrast to zipimport.c, this module also writes *.pyc files
44 // automatically if it has write access/is not inside of a zip file.
44 // automatically if it has write access/is not inside of a zip file.
45 //----------------------------------------------------------------------------------
45 //----------------------------------------------------------------------------------
46
46
47 #include "PythonQtImporter.h"
47 #include "PythonQtImporter.h"
48 #include "PythonQtImportFileInterface.h"
48 #include "PythonQtImportFileInterface.h"
49 #include "PythonQt.h"
49 #include "PythonQt.h"
50 #include "PythonQtConversion.h"
50 #include "PythonQtConversion.h"
51 #include <QFile>
51 #include <QFile>
52 #include <QFileInfo>
52 #include <QFileInfo>
53
53
54 #if PY_MAJOR_VERSION >= 3
55 #define PY3K
56 #endif
57
54 #define IS_SOURCE 0x0
58 #define IS_SOURCE 0x0
55 #define IS_BYTECODE 0x1
59 #define IS_BYTECODE 0x1
56 #define IS_PACKAGE 0x2
60 #define IS_PACKAGE 0x2
57
61
58 struct st_mlab_searchorder {
62 struct st_mlab_searchorder {
59 char suffix[14];
63 char suffix[14];
60 int type;
64 int type;
61 };
65 };
62
66
63 /* mlab_searchorder defines how we search for a module in the Zip
67 /* mlab_searchorder defines how we search for a module in the Zip
64 archive: we first search for a package __init__, then for
68 archive: we first search for a package __init__, then for
65 non-package .pyc, .pyo and .py entries. The .pyc and .pyo entries
69 non-package .pyc, .pyo and .py entries. The .pyc and .pyo entries
66 are swapped by initmlabimport() if we run in optimized mode. Also,
70 are swapped by initmlabimport() if we run in optimized mode. Also,
67 '/' is replaced by SEP there. */
71 '/' is replaced by SEP there. */
68 struct st_mlab_searchorder mlab_searchorder[] = {
72 struct st_mlab_searchorder mlab_searchorder[] = {
69 {"/__init__.pyc", IS_PACKAGE | IS_BYTECODE},
73 {"/__init__.pyc", IS_PACKAGE | IS_BYTECODE},
70 {"/__init__.pyo", IS_PACKAGE | IS_BYTECODE},
74 {"/__init__.pyo", IS_PACKAGE | IS_BYTECODE},
71 {"/__init__.py", IS_PACKAGE | IS_SOURCE},
75 {"/__init__.py", IS_PACKAGE | IS_SOURCE},
72 {".pyc", IS_BYTECODE},
76 {".pyc", IS_BYTECODE},
73 {".pyo", IS_BYTECODE},
77 {".pyo", IS_BYTECODE},
74 {".py", IS_SOURCE},
78 {".py", IS_SOURCE},
75 {"", 0}
79 {"", 0}
76 };
80 };
77
81
78 extern PyTypeObject PythonQtImporter_Type;
82 extern PyTypeObject PythonQtImporter_Type;
79 PyObject *PythonQtImportError;
83 PyObject *PythonQtImportError;
80
84
81 QString PythonQtImport::getSubName(const QString& str)
85 QString PythonQtImport::getSubName(const QString& str)
82 {
86 {
83 int idx = str.lastIndexOf('.');
87 int idx = str.lastIndexOf('.');
84 if (idx!=-1) {
88 if (idx!=-1) {
85 return str.mid(idx+1);
89 return str.mid(idx+1);
86 } else {
90 } else {
87 return str;
91 return str;
88 }
92 }
89 }
93 }
90
94
91 PythonQtImport::ModuleInfo PythonQtImport::getModuleInfo(PythonQtImporter* self, const QString& fullname)
95 PythonQtImport::ModuleInfo PythonQtImport::getModuleInfo(PythonQtImporter* self, const QString& fullname)
92 {
96 {
93 ModuleInfo info;
97 ModuleInfo info;
94 QString subname;
98 QString subname;
95 struct st_mlab_searchorder *zso;
99 struct st_mlab_searchorder *zso;
96
100
97 subname = getSubName(fullname);
101 subname = getSubName(fullname);
98 QString path = *self->_path + "/" + subname;
102 QString path = *self->_path + "/" + subname;
99
103
100 QString test;
104 QString test;
101 for (zso = mlab_searchorder; *zso->suffix; zso++) {
105 for (zso = mlab_searchorder; *zso->suffix; zso++) {
102 test = path + zso->suffix;
106 test = path + zso->suffix;
103 if (PythonQt::importInterface()->exists(test)) {
107 if (PythonQt::importInterface()->exists(test)) {
104 info.fullPath = test;
108 info.fullPath = test;
105 info.moduleName = subname;
109 info.moduleName = subname;
106 info.type = (zso->type & IS_PACKAGE)?MI_PACKAGE:MI_MODULE;
110 info.type = (zso->type & IS_PACKAGE)?MI_PACKAGE:MI_MODULE;
107 return info;
111 return info;
108 }
112 }
109 }
113 }
110 // test if it is a shared library
114 // test if it is a shared library
111 Q_FOREACH(const QString& suffix, PythonQt::priv()->sharedLibrarySuffixes()) {
115 Q_FOREACH(const QString& suffix, PythonQt::priv()->sharedLibrarySuffixes()) {
112 test = path+suffix;
116 test = path+suffix;
113 if (PythonQt::importInterface()->exists(test)) {
117 if (PythonQt::importInterface()->exists(test)) {
114 info.fullPath = test;
118 info.fullPath = test;
115 info.moduleName = subname;
119 info.moduleName = subname;
116 info.type = MI_SHAREDLIBRARY;
120 info.type = MI_SHAREDLIBRARY;
117 return info;
121 return info;
118 }
122 }
119 }
123 }
120 return info;
124 return info;
121 }
125 }
122
126
123
127
124 /* PythonQtImporter.__init__
128 /* PythonQtImporter.__init__
125 Just store the path argument (or reject if it is in the ignorePaths list
129 Just store the path argument (or reject if it is in the ignorePaths list
126 */
130 */
127 int PythonQtImporter_init(PythonQtImporter *self, PyObject *args, PyObject * /*kwds*/)
131 int PythonQtImporter_init(PythonQtImporter *self, PyObject *args, PyObject * /*kwds*/)
128 {
132 {
129 self->_path = NULL;
133 self->_path = NULL;
130
134
131 const char* cpath;
135 const char* cpath;
132 if (!PyArg_ParseTuple(args, "s",
136 if (!PyArg_ParseTuple(args, "s",
133 &cpath))
137 &cpath))
134 return -1;
138 return -1;
135
139
136 QString path(cpath);
140 QString path(cpath);
137 if (PythonQt::importInterface()->exists(path)) {
141 if (PythonQt::importInterface()->exists(path)) {
138 const QStringList& ignorePaths = PythonQt::self()->getImporterIgnorePaths();
142 const QStringList& ignorePaths = PythonQt::self()->getImporterIgnorePaths();
139 Q_FOREACH(QString ignorePath, ignorePaths) {
143 Q_FOREACH(QString ignorePath, ignorePaths) {
140 if (path.startsWith(ignorePath)) {
144 if (path.startsWith(ignorePath)) {
141 PyErr_SetString(PythonQtImportError,
145 PyErr_SetString(PythonQtImportError,
142 "path ignored");
146 "path ignored");
143 return -1;
147 return -1;
144 }
148 }
145 }
149 }
146
150
147 self->_path = new QString(path);
151 self->_path = new QString(path);
148 return 0;
152 return 0;
149 } else {
153 } else {
150 PyErr_SetString(PythonQtImportError,
154 PyErr_SetString(PythonQtImportError,
151 "path does not exist error");
155 "path does not exist error");
152 return -1;
156 return -1;
153 }
157 }
154 }
158 }
155
159
156 void
160 void
157 PythonQtImporter_dealloc(PythonQtImporter *self)
161 PythonQtImporter_dealloc(PythonQtImporter *self)
158 {
162 {
159 // free the stored path
163 // free the stored path
160 if (self->_path) delete self->_path;
164 if (self->_path) delete self->_path;
161 // free ourself
165 // free ourself
162 self->ob_type->tp_free((PyObject *)self);
166 Py_TYPE(self)->tp_free((PyObject *)self);
163 }
167 }
164
168
165
169
166 /* Check whether we can satisfy the import of the module named by
170 /* Check whether we can satisfy the import of the module named by
167 'fullname'. Return self if we can, None if we can't. */
171 'fullname'. Return self if we can, None if we can't. */
168 PyObject *
172 PyObject *
169 PythonQtImporter_find_module(PyObject *obj, PyObject *args)
173 PythonQtImporter_find_module(PyObject *obj, PyObject *args)
170 {
174 {
171 PythonQtImporter *self = (PythonQtImporter *)obj;
175 PythonQtImporter *self = (PythonQtImporter *)obj;
172 PyObject *path = NULL;
176 PyObject *path = NULL;
173 char *fullname;
177 char *fullname;
174
178
175 if (!PyArg_ParseTuple(args, "s|O:PythonQtImporter.find_module",
179 if (!PyArg_ParseTuple(args, "s|O:PythonQtImporter.find_module",
176 &fullname, &path))
180 &fullname, &path))
177 return NULL;
181 return NULL;
178
182
179 //qDebug() << "looking for " << fullname << " at " << *self->_path;
183 //qDebug() << "looking for " << fullname << " at " << *self->_path;
180
184
181 PythonQtImport::ModuleInfo info = PythonQtImport::getModuleInfo(self, fullname);
185 PythonQtImport::ModuleInfo info = PythonQtImport::getModuleInfo(self, fullname);
182 if (info.type != PythonQtImport::MI_NOT_FOUND) {
186 if (info.type != PythonQtImport::MI_NOT_FOUND) {
183 Py_INCREF(self);
187 Py_INCREF(self);
184 return (PyObject *)self;
188 return (PyObject *)self;
185 } else {
189 } else {
186 Py_INCREF(Py_None);
190 Py_INCREF(Py_None);
187 return Py_None;
191 return Py_None;
188 }
192 }
189 }
193 }
190
194
191 /* Load and return the module named by 'fullname'. */
195 /* Load and return the module named by 'fullname'. */
192 PyObject *
196 PyObject *
193 PythonQtImporter_load_module(PyObject *obj, PyObject *args)
197 PythonQtImporter_load_module(PyObject *obj, PyObject *args)
194 {
198 {
195 PythonQtImporter *self = (PythonQtImporter *)obj;
199 PythonQtImporter *self = (PythonQtImporter *)obj;
196 PyObject *code = NULL, *mod = NULL, *dict = NULL;
200 PyObject *code = NULL, *mod = NULL, *dict = NULL;
197 char *fullname;
201 char *fullname;
198
202
199 if (!PyArg_ParseTuple(args, "s:PythonQtImporter.load_module",
203 if (!PyArg_ParseTuple(args, "s:PythonQtImporter.load_module",
200 &fullname))
204 &fullname))
201 return NULL;
205 return NULL;
202
206
203 PythonQtImport::ModuleInfo info = PythonQtImport::getModuleInfo(self, fullname);
207 PythonQtImport::ModuleInfo info = PythonQtImport::getModuleInfo(self, fullname);
204 if (info.type == PythonQtImport::MI_NOT_FOUND) {
208 if (info.type == PythonQtImport::MI_NOT_FOUND) {
205 return NULL;
209 return NULL;
206 }
210 }
207
211
208 if (info.type == PythonQtImport::MI_PACKAGE || info.type == PythonQtImport::MI_MODULE) {
212 if (info.type == PythonQtImport::MI_PACKAGE || info.type == PythonQtImport::MI_MODULE) {
209 QString fullPath;
213 QString fullPath;
210 code = PythonQtImport::getModuleCode(self, fullname, fullPath);
214 code = PythonQtImport::getModuleCode(self, fullname, fullPath);
211 if (code == NULL) {
215 if (code == NULL) {
212 return NULL;
216 return NULL;
213 }
217 }
214
218
215 mod = PyImport_AddModule(fullname);
219 mod = PyImport_AddModule(fullname);
216 if (mod == NULL) {
220 if (mod == NULL) {
217 Py_DECREF(code);
221 Py_DECREF(code);
218 return NULL;
222 return NULL;
219 }
223 }
220 dict = PyModule_GetDict(mod);
224 dict = PyModule_GetDict(mod);
221
225
222 if (PyDict_SetItemString(dict, "__loader__", (PyObject *)self) != 0) {
226 if (PyDict_SetItemString(dict, "__loader__", (PyObject *)self) != 0) {
223 Py_DECREF(code);
227 Py_DECREF(code);
224 Py_DECREF(mod);
228 Py_DECREF(mod);
225 return NULL;
229 return NULL;
226 }
230 }
227
231
228 if (info.type == PythonQtImport::MI_PACKAGE) {
232 if (info.type == PythonQtImport::MI_PACKAGE) {
229 PyObject *pkgpath, *fullpath;
233 PyObject *pkgpath, *fullpath;
230 QString subname = info.moduleName;
234 QString subname = info.moduleName;
231 int err;
235 int err;
232
236
237 #ifdef PY3K
238 fullpath = PyUnicode_FromFormat("%s%c%s",
239 #else
233 fullpath = PyString_FromFormat("%s%c%s",
240 fullpath = PyString_FromFormat("%s%c%s",
241 #endif
234 self->_path->toLatin1().constData(),
242 self->_path->toLatin1().constData(),
235 SEP,
243 SEP,
236 subname.toLatin1().constData());
244 subname.toLatin1().constData());
237 if (fullpath == NULL) {
245 if (fullpath == NULL) {
238 Py_DECREF(code);
246 Py_DECREF(code);
239 Py_DECREF(mod);
247 Py_DECREF(mod);
240 return NULL;
248 return NULL;
241 }
249 }
242
250
243 pkgpath = Py_BuildValue("[O]", fullpath);
251 pkgpath = Py_BuildValue("[O]", fullpath);
244 Py_DECREF(fullpath);
252 Py_DECREF(fullpath);
245 if (pkgpath == NULL) {
253 if (pkgpath == NULL) {
246 Py_DECREF(code);
254 Py_DECREF(code);
247 Py_DECREF(mod);
255 Py_DECREF(mod);
248 return NULL;
256 return NULL;
249 }
257 }
250 err = PyDict_SetItemString(dict, "__path__", pkgpath);
258 err = PyDict_SetItemString(dict, "__path__", pkgpath);
251 Py_DECREF(pkgpath);
259 Py_DECREF(pkgpath);
252 if (err != 0) {
260 if (err != 0) {
253 Py_DECREF(code);
261 Py_DECREF(code);
254 Py_DECREF(mod);
262 Py_DECREF(mod);
255 return NULL;
263 return NULL;
256 }
264 }
257 }
265 }
258
266
259 mod = PyImport_ExecCodeModuleEx(fullname, code, fullPath.toLatin1().data());
267 mod = PyImport_ExecCodeModuleEx(fullname, code, fullPath.toLatin1().data());
260
268
261 if (PythonQt::importInterface()) {
269 if (PythonQt::importInterface()) {
262 PythonQt::importInterface()->importedModule(fullname);
270 PythonQt::importInterface()->importedModule(fullname);
263 }
271 }
264
272
265 Py_DECREF(code);
273 Py_DECREF(code);
266 if (Py_VerboseFlag) {
274 if (Py_VerboseFlag) {
267 PySys_WriteStderr("import %s # loaded from %s\n",
275 PySys_WriteStderr("import %s # loaded from %s\n",
268 fullname, fullPath.toLatin1().constData());
276 fullname, fullPath.toLatin1().constData());
269 }
277 }
270 } else {
278 } else {
271 PythonQtObjectPtr imp;
279 PythonQtObjectPtr imp;
272 imp.setNewRef(PyImport_ImportModule("imp"));
280 imp.setNewRef(PyImport_ImportModule("imp"));
273
281
274 // Create a PyList with the current path as its single element,
282 // Create a PyList with the current path as its single element,
275 // which is required for find_module (it won't accept a tuple...)
283 // which is required for find_module (it won't accept a tuple...)
276 PythonQtObjectPtr pathList;
284 PythonQtObjectPtr pathList;
277 pathList.setNewRef(PythonQtConv::QStringListToPyList(QStringList() << *self->_path));
285 pathList.setNewRef(PythonQtConv::QStringListToPyList(QStringList() << *self->_path));
278
286
279 QVariantList args;
287 QVariantList args;
280 // Pass the module name without the package prefix
288 // Pass the module name without the package prefix
281 args.append(info.moduleName);
289 args.append(info.moduleName);
282 // And the path where we know that the shared library is
290 // And the path where we know that the shared library is
283 args.append(QVariant::fromValue(pathList));
291 args.append(QVariant::fromValue(pathList));
284 QVariant result = imp.call("find_module", args);
292 QVariant result = imp.call("find_module", args);
285 if (result.isValid()) {
293 if (result.isValid()) {
286 // This will return a tuple with (file, pathname, description=(suffix,mode,type))
294 // This will return a tuple with (file, pathname, description=(suffix,mode,type))
287 QVariantList list = result.toList();
295 QVariantList list = result.toList();
288 if (list.count()==3) {
296 if (list.count()==3) {
289 // We prepend the full module name (including package prefix)
297 // We prepend the full module name (including package prefix)
290 list.prepend(fullname);
298 list.prepend(fullname);
291 #ifdef __linux
299 #ifdef __linux
292 #ifdef _DEBUG
300 #ifdef _DEBUG
293 // imp_find_module() does not respect the debug suffix '_d' on Linux,
301 // imp_find_module() does not respect the debug suffix '_d' on Linux,
294 // so it does not return the correct file path and we correct it now
302 // so it does not return the correct file path and we correct it now
295 // find_module opened a file to the release library, but that file handle is
303 // find_module opened a file to the release library, but that file handle is
296 // ignored on Linux and Windows, maybe on MacOS also.
304 // ignored on Linux and Windows, maybe on MacOS also.
297 list[2] = info.fullPath;
305 list[2] = info.fullPath;
298 #endif
306 #endif
299 #endif
307 #endif
300 // And call "load_module" with (fullname, file, pathname, description=(suffix,mode,type))
308 // And call "load_module" with (fullname, file, pathname, description=(suffix,mode,type))
301 PythonQtObjectPtr module = imp.call("load_module", list);
309 PythonQtObjectPtr module = imp.call("load_module", list);
302 mod = module.object();
310 mod = module.object();
303 if (mod) {
311 if (mod) {
304 Py_INCREF(mod);
312 Py_INCREF(mod);
305 }
313 }
306
314
307 // Finally, we need to close the file again, which find_module opened for us
315 // Finally, we need to close the file again, which find_module opened for us
308 PythonQtObjectPtr file = list.at(1);
316 PythonQtObjectPtr file = list.at(1);
309 file.call("close");
317 file.call("close");
310 }
318 }
311 }
319 }
312 }
320 }
313 return mod;
321 return mod;
314 }
322 }
315
323
316
324
317 PyObject *
325 PyObject *
318 PythonQtImporter_get_data(PyObject* /*obj*/, PyObject* /*args*/)
326 PythonQtImporter_get_data(PyObject* /*obj*/, PyObject* /*args*/)
319 {
327 {
320 // EXTRA, NOT YET IMPLEMENTED
328 // EXTRA, NOT YET IMPLEMENTED
321 return NULL;
329 return NULL;
322 }
330 }
323
331
324 PyObject *
332 PyObject *
325 PythonQtImporter_get_code(PyObject *obj, PyObject *args)
333 PythonQtImporter_get_code(PyObject *obj, PyObject *args)
326 {
334 {
327 PythonQtImporter *self = (PythonQtImporter *)obj;
335 PythonQtImporter *self = (PythonQtImporter *)obj;
328 char *fullname;
336 char *fullname;
329
337
330 if (!PyArg_ParseTuple(args, "s:PythonQtImporter.get_code", &fullname))
338 if (!PyArg_ParseTuple(args, "s:PythonQtImporter.get_code", &fullname))
331 return NULL;
339 return NULL;
332
340
333 QString notused;
341 QString notused;
334 return PythonQtImport::getModuleCode(self, fullname, notused);
342 return PythonQtImport::getModuleCode(self, fullname, notused);
335 }
343 }
336
344
337 PyObject *
345 PyObject *
338 PythonQtImporter_get_source(PyObject * /*obj*/, PyObject * /*args*/)
346 PythonQtImporter_get_source(PyObject * /*obj*/, PyObject * /*args*/)
339 {
347 {
340 // EXTRA, NOT YET IMPLEMENTED
348 // EXTRA, NOT YET IMPLEMENTED
341 return NULL;
349 return NULL;
342 }
350 }
343
351
344 PyDoc_STRVAR(doc_find_module,
352 PyDoc_STRVAR(doc_find_module,
345 "find_module(fullname, path=None) -> self or None.\n\
353 "find_module(fullname, path=None) -> self or None.\n\
346 \n\
354 \n\
347 Search for a module specified by 'fullname'. 'fullname' must be the\n\
355 Search for a module specified by 'fullname'. 'fullname' must be the\n\
348 fully qualified (dotted) module name. It returns the PythonQtImporter\n\
356 fully qualified (dotted) module name. It returns the PythonQtImporter\n\
349 instance itself if the module was found, or None if it wasn't.\n\
357 instance itself if the module was found, or None if it wasn't.\n\
350 The optional 'path' argument is ignored -- it's there for compatibility\n\
358 The optional 'path' argument is ignored -- it's there for compatibility\n\
351 with the importer protocol.");
359 with the importer protocol.");
352
360
353 PyDoc_STRVAR(doc_load_module,
361 PyDoc_STRVAR(doc_load_module,
354 "load_module(fullname) -> module.\n\
362 "load_module(fullname) -> module.\n\
355 \n\
363 \n\
356 Load the module specified by 'fullname'. 'fullname' must be the\n\
364 Load the module specified by 'fullname'. 'fullname' must be the\n\
357 fully qualified (dotted) module name. It returns the imported\n\
365 fully qualified (dotted) module name. It returns the imported\n\
358 module, or raises PythonQtImportError if it wasn't found.");
366 module, or raises PythonQtImportError if it wasn't found.");
359
367
360 PyDoc_STRVAR(doc_get_data,
368 PyDoc_STRVAR(doc_get_data,
361 "get_data(pathname) -> string with file data.\n\
369 "get_data(pathname) -> string with file data.\n\
362 \n\
370 \n\
363 Return the data associated with 'pathname'. Raise IOError if\n\
371 Return the data associated with 'pathname'. Raise IOError if\n\
364 the file wasn't found.");
372 the file wasn't found.");
365
373
366 PyDoc_STRVAR(doc_get_code,
374 PyDoc_STRVAR(doc_get_code,
367 "get_code(fullname) -> code object.\n\
375 "get_code(fullname) -> code object.\n\
368 \n\
376 \n\
369 Return the code object for the specified module. Raise PythonQtImportError\n\
377 Return the code object for the specified module. Raise PythonQtImportError\n\
370 is the module couldn't be found.");
378 is the module couldn't be found.");
371
379
372 PyDoc_STRVAR(doc_get_source,
380 PyDoc_STRVAR(doc_get_source,
373 "get_source(fullname) -> source string.\n\
381 "get_source(fullname) -> source string.\n\
374 \n\
382 \n\
375 Return the source code for the specified module. Raise PythonQtImportError\n\
383 Return the source code for the specified module. Raise PythonQtImportError\n\
376 is the module couldn't be found, return None if the archive does\n\
384 is the module couldn't be found, return None if the archive does\n\
377 contain the module, but has no source for it.");
385 contain the module, but has no source for it.");
378
386
379 PyMethodDef PythonQtImporter_methods[] = {
387 PyMethodDef PythonQtImporter_methods[] = {
380 {"find_module", PythonQtImporter_find_module, METH_VARARGS,
388 {"find_module", PythonQtImporter_find_module, METH_VARARGS,
381 doc_find_module},
389 doc_find_module},
382 {"load_module", PythonQtImporter_load_module, METH_VARARGS,
390 {"load_module", PythonQtImporter_load_module, METH_VARARGS,
383 doc_load_module},
391 doc_load_module},
384 {"get_data", PythonQtImporter_get_data, METH_VARARGS,
392 {"get_data", PythonQtImporter_get_data, METH_VARARGS,
385 doc_get_data},
393 doc_get_data},
386 {"get_code", PythonQtImporter_get_code, METH_VARARGS,
394 {"get_code", PythonQtImporter_get_code, METH_VARARGS,
387 doc_get_code},
395 doc_get_code},
388 {"get_source", PythonQtImporter_get_source, METH_VARARGS,
396 {"get_source", PythonQtImporter_get_source, METH_VARARGS,
389 doc_get_source},
397 doc_get_source},
390 {NULL, NULL, 0 , NULL} /* sentinel */
398 {NULL, NULL, 0 , NULL} /* sentinel */
391 };
399 };
392
400
393
401
394 PyDoc_STRVAR(PythonQtImporter_doc,
402 PyDoc_STRVAR(PythonQtImporter_doc,
395 "PythonQtImporter(path) -> PythonQtImporter object\n\
403 "PythonQtImporter(path) -> PythonQtImporter object\n\
396 \n\
404 \n\
397 Create a new PythonQtImporter instance. 'path' must be a valid path on disk/or inside of a zip file known to MeVisLab\n\
405 Create a new PythonQtImporter instance. 'path' must be a valid path on disk/or inside of a zip file known to MeVisLab\n\
398 . Every path is accepted.");
406 . Every path is accepted.");
399
407
400 #define DEFERRED_ADDRESS(ADDR) 0
408 #define DEFERRED_ADDRESS(ADDR) 0
401
409
402 PyTypeObject PythonQtImporter_Type = {
410 PyTypeObject PythonQtImporter_Type = {
403 PyObject_HEAD_INIT(DEFERRED_ADDRESS(&PyType_Type))
411 PyVarObject_HEAD_INIT(DEFERRED_ADDRESS(&PyType_Type), 0)
404 0,
405 "PythonQtImport.PythonQtImporter",
412 "PythonQtImport.PythonQtImporter",
406 sizeof(PythonQtImporter),
413 sizeof(PythonQtImporter),
407 0, /* tp_itemsize */
414 0, /* tp_itemsize */
408 (destructor)PythonQtImporter_dealloc, /* tp_dealloc */
415 (destructor)PythonQtImporter_dealloc, /* tp_dealloc */
409 0, /* tp_print */
416 0, /* tp_print */
410 0, /* tp_getattr */
417 0, /* tp_getattr */
411 0, /* tp_setattr */
418 0, /* tp_setattr */
412 0, /* tp_compare */
419 0, /* tp_compare */
413 0, /* tp_repr */
420 0, /* tp_repr */
414 0, /* tp_as_number */
421 0, /* tp_as_number */
415 0, /* tp_as_sequence */
422 0, /* tp_as_sequence */
416 0, /* tp_as_mapping */
423 0, /* tp_as_mapping */
417 0, /* tp_hash */
424 0, /* tp_hash */
418 0, /* tp_call */
425 0, /* tp_call */
419 0, /* tp_str */
426 0, /* tp_str */
420 PyObject_GenericGetAttr, /* tp_getattro */
427 PyObject_GenericGetAttr, /* tp_getattro */
421 0, /* tp_setattro */
428 0, /* tp_setattro */
422 0, /* tp_as_buffer */
429 0, /* tp_as_buffer */
423 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE , /* tp_flags */
430 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE , /* tp_flags */
424 PythonQtImporter_doc, /* tp_doc */
431 PythonQtImporter_doc, /* tp_doc */
425 0, /* tp_traverse */
432 0, /* tp_traverse */
426 0, /* tp_clear */
433 0, /* tp_clear */
427 0, /* tp_richcompare */
434 0, /* tp_richcompare */
428 0, /* tp_weaklistoffset */
435 0, /* tp_weaklistoffset */
429 0, /* tp_iter */
436 0, /* tp_iter */
430 0, /* tp_iternext */
437 0, /* tp_iternext */
431 PythonQtImporter_methods, /* tp_methods */
438 PythonQtImporter_methods, /* tp_methods */
432 0, /* tp_members */
439 0, /* tp_members */
433 0, /* tp_getset */
440 0, /* tp_getset */
434 0, /* tp_base */
441 0, /* tp_base */
435 0, /* tp_dict */
442 0, /* tp_dict */
436 0, /* tp_descr_get */
443 0, /* tp_descr_get */
437 0, /* tp_descr_set */
444 0, /* tp_descr_set */
438 0, /* tp_dictoffset */
445 0, /* tp_dictoffset */
439 (initproc)PythonQtImporter_init, /* tp_init */
446 (initproc)PythonQtImporter_init, /* tp_init */
440 PyType_GenericAlloc, /* tp_alloc */
447 PyType_GenericAlloc, /* tp_alloc */
441 PyType_GenericNew, /* tp_new */
448 PyType_GenericNew, /* tp_new */
442 PyObject_Del, /* tp_free */
449 PyObject_Del, /* tp_free */
443 };
450 };
444
451
445
452
446 /* Given a buffer, return the long that is represented by the first
453 /* Given a buffer, return the long that is represented by the first
447 4 bytes, encoded as little endian. This partially reimplements
454 4 bytes, encoded as little endian. This partially reimplements
448 marshal.c:r_long() */
455 marshal.c:r_long() */
449 long
456 long
450 PythonQtImport::getLong(unsigned char *buf)
457 PythonQtImport::getLong(unsigned char *buf)
451 {
458 {
452 long x;
459 long x;
453 x = buf[0];
460 x = buf[0];
454 x |= (long)buf[1] << 8;
461 x |= (long)buf[1] << 8;
455 x |= (long)buf[2] << 16;
462 x |= (long)buf[2] << 16;
456 x |= (long)buf[3] << 24;
463 x |= (long)buf[3] << 24;
457 #if SIZEOF_LONG > 4
464 #if SIZEOF_LONG > 4
458 /* Sign extension for 64-bit machines */
465 /* Sign extension for 64-bit machines */
459 x |= -(x & 0x80000000L);
466 x |= -(x & 0x80000000L);
460 #endif
467 #endif
461 return x;
468 return x;
462 }
469 }
463
470
464 FILE *
471 FILE *
465 open_exclusive(const QString& filename)
472 open_exclusive(const QString& filename)
466 {
473 {
467 #if defined(O_EXCL)&&defined(O_CREAT)&&defined(O_WRONLY)&&defined(O_TRUNC)
474 #if defined(O_EXCL)&&defined(O_CREAT)&&defined(O_WRONLY)&&defined(O_TRUNC)
468 /* Use O_EXCL to avoid a race condition when another process tries to
475 /* Use O_EXCL to avoid a race condition when another process tries to
469 write the same file. When that happens, our open() call fails,
476 write the same file. When that happens, our open() call fails,
470 which is just fine (since it's only a cache).
477 which is just fine (since it's only a cache).
471 XXX If the file exists and is writable but the directory is not
478 XXX If the file exists and is writable but the directory is not
472 writable, the file will never be written. Oh well.
479 writable, the file will never be written. Oh well.
473 */
480 */
474 QFile::remove(filename);
481 QFile::remove(filename);
475
482
476 int fd;
483 int fd;
477 int flags = O_EXCL|O_CREAT|O_WRONLY|O_TRUNC;
484 int flags = O_EXCL|O_CREAT|O_WRONLY|O_TRUNC;
478 #ifdef O_BINARY
485 #ifdef O_BINARY
479 flags |= O_BINARY; /* necessary for Windows */
486 flags |= O_BINARY; /* necessary for Windows */
480 #endif
487 #endif
481 #ifdef WIN32
488 #ifdef WIN32
482 fd = _wopen(filename.ucs2(), flags, 0666);
489 fd = _wopen(filename.ucs2(), flags, 0666);
483 #else
490 #else
484 fd = open(filename.local8Bit(), flags, 0666);
491 fd = open(filename.local8Bit(), flags, 0666);
485 #endif
492 #endif
486 if (fd < 0)
493 if (fd < 0)
487 return NULL;
494 return NULL;
488 return fdopen(fd, "wb");
495 return fdopen(fd, "wb");
489 #else
496 #else
490 /* Best we can do -- on Windows this can't happen anyway */
497 /* Best we can do -- on Windows this can't happen anyway */
491 return fopen(filename.toLocal8Bit().constData(), "wb");
498 return fopen(filename.toLocal8Bit().constData(), "wb");
492 #endif
499 #endif
493 }
500 }
494
501
495
502
496 void PythonQtImport::writeCompiledModule(PyCodeObject *co, const QString& filename, long mtime)
503 void PythonQtImport::writeCompiledModule(PyCodeObject *co, const QString& filename, long mtime)
497 {
504 {
498 FILE *fp;
505 FILE *fp;
499 // we do not want to write Qt resources to disk, do we?
506 // we do not want to write Qt resources to disk, do we?
500 if (filename.startsWith(":")) {
507 if (filename.startsWith(":")) {
501 return;
508 return;
502 }
509 }
503 fp = open_exclusive(filename);
510 fp = open_exclusive(filename);
504 if (fp == NULL) {
511 if (fp == NULL) {
505 if (Py_VerboseFlag)
512 if (Py_VerboseFlag)
506 PySys_WriteStderr(
513 PySys_WriteStderr(
507 "# can't create %s\n", filename.toLatin1().constData());
514 "# can't create %s\n", filename.toLatin1().constData());
508 return;
515 return;
509 }
516 }
510 #if PY_VERSION_HEX < 0x02040000
517 #if PY_VERSION_HEX < 0x02040000
511 PyMarshal_WriteLongToFile(PyImport_GetMagicNumber(), fp);
518 PyMarshal_WriteLongToFile(PyImport_GetMagicNumber(), fp);
512 #else
519 #else
513 PyMarshal_WriteLongToFile(PyImport_GetMagicNumber(), fp, Py_MARSHAL_VERSION);
520 PyMarshal_WriteLongToFile(PyImport_GetMagicNumber(), fp, Py_MARSHAL_VERSION);
514 #endif
521 #endif
515 /* First write a 0 for mtime */
522 /* First write a 0 for mtime */
516 #if PY_VERSION_HEX < 0x02040000
523 #if PY_VERSION_HEX < 0x02040000
517 PyMarshal_WriteLongToFile(0L, fp);
524 PyMarshal_WriteLongToFile(0L, fp);
518 #else
525 #else
519 PyMarshal_WriteLongToFile(0L, fp, Py_MARSHAL_VERSION);
526 PyMarshal_WriteLongToFile(0L, fp, Py_MARSHAL_VERSION);
520 #endif
527 #endif
521 #if PY_VERSION_HEX < 0x02040000
528 #if PY_VERSION_HEX < 0x02040000
522 PyMarshal_WriteObjectToFile((PyObject *)co, fp);
529 PyMarshal_WriteObjectToFile((PyObject *)co, fp);
523 #else
530 #else
524 PyMarshal_WriteObjectToFile((PyObject *)co, fp, Py_MARSHAL_VERSION);
531 PyMarshal_WriteObjectToFile((PyObject *)co, fp, Py_MARSHAL_VERSION);
525 #endif
532 #endif
526 if (ferror(fp)) {
533 if (ferror(fp)) {
527 if (Py_VerboseFlag)
534 if (Py_VerboseFlag)
528 PySys_WriteStderr("# can't write %s\n", filename.toLatin1().constData());
535 PySys_WriteStderr("# can't write %s\n", filename.toLatin1().constData());
529 /* Don't keep partial file */
536 /* Don't keep partial file */
530 fclose(fp);
537 fclose(fp);
531 QFile::remove(filename);
538 QFile::remove(filename);
532 return;
539 return;
533 }
540 }
534 /* Now write the true mtime */
541 /* Now write the true mtime */
535 fseek(fp, 4L, 0);
542 fseek(fp, 4L, 0);
536 #if PY_VERSION_HEX < 0x02040000
543 #if PY_VERSION_HEX < 0x02040000
537 PyMarshal_WriteLongToFile(mtime, fp);
544 PyMarshal_WriteLongToFile(mtime, fp);
538 #else
545 #else
539 PyMarshal_WriteLongToFile(mtime, fp, Py_MARSHAL_VERSION);
546 PyMarshal_WriteLongToFile(mtime, fp, Py_MARSHAL_VERSION);
540 #endif
547 #endif
541 fflush(fp);
548 fflush(fp);
542 fclose(fp);
549 fclose(fp);
543 if (Py_VerboseFlag)
550 if (Py_VerboseFlag)
544 PySys_WriteStderr("# wrote %s\n", filename.toLatin1().constData());
551 PySys_WriteStderr("# wrote %s\n", filename.toLatin1().constData());
545 //#ifdef macintosh
552 //#ifdef macintosh
546 // PyMac_setfiletype(cpathname, 'Pyth', 'PYC ');
553 // PyMac_setfiletype(cpathname, 'Pyth', 'PYC ');
547 //#endif
554 //#endif
548 }
555 }
549
556
550 /* Given the contents of a .py[co] file in a buffer, unmarshal the data
557 /* Given the contents of a .py[co] file in a buffer, unmarshal the data
551 and return the code object. Return None if it the magic word doesn't
558 and return the code object. Return None if it the magic word doesn't
552 match (we do this instead of raising an exception as we fall back
559 match (we do this instead of raising an exception as we fall back
553 to .py if available and we don't want to mask other errors).
560 to .py if available and we don't want to mask other errors).
554 Returns a new reference. */
561 Returns a new reference. */
555 PyObject *
562 PyObject *
556 PythonQtImport::unmarshalCode(const QString& path, const QByteArray& data, time_t mtime)
563 PythonQtImport::unmarshalCode(const QString& path, const QByteArray& data, time_t mtime)
557 {
564 {
558 PyObject *code;
565 PyObject *code;
559 // ugly cast, but Python API is not const safe
566 // ugly cast, but Python API is not const safe
560 char *buf = (char*) data.constData();
567 char *buf = (char*) data.constData();
561 int size = data.size();
568 int size = data.size();
562
569
563 if (size <= 9) {
570 if (size <= 9) {
564 PySys_WriteStderr("# %s has bad pyc data\n",
571 PySys_WriteStderr("# %s has bad pyc data\n",
565 path.toLatin1().constData());
572 path.toLatin1().constData());
566 Py_INCREF(Py_None);
573 Py_INCREF(Py_None);
567 return Py_None;
574 return Py_None;
568 }
575 }
569
576
570 if (getLong((unsigned char *)buf) != PyImport_GetMagicNumber()) {
577 if (getLong((unsigned char *)buf) != PyImport_GetMagicNumber()) {
571 if (Py_VerboseFlag)
578 if (Py_VerboseFlag)
572 PySys_WriteStderr("# %s has bad magic\n",
579 PySys_WriteStderr("# %s has bad magic\n",
573 path.toLatin1().constData());
580 path.toLatin1().constData());
574 Py_INCREF(Py_None);
581 Py_INCREF(Py_None);
575 return Py_None;
582 return Py_None;
576 }
583 }
577
584
578 if (mtime != 0) {
585 if (mtime != 0) {
579 time_t timeDiff = getLong((unsigned char *)buf + 4) - mtime;
586 time_t timeDiff = getLong((unsigned char *)buf + 4) - mtime;
580 if (timeDiff<0) { timeDiff = -timeDiff; }
587 if (timeDiff<0) { timeDiff = -timeDiff; }
581 if (timeDiff > 1) {
588 if (timeDiff > 1) {
582 if (Py_VerboseFlag)
589 if (Py_VerboseFlag)
583 PySys_WriteStderr("# %s has bad mtime\n",
590 PySys_WriteStderr("# %s has bad mtime\n",
584 path.toLatin1().constData());
591 path.toLatin1().constData());
585 Py_INCREF(Py_None);
592 Py_INCREF(Py_None);
586 return Py_None;
593 return Py_None;
587 }
594 }
588 }
595 }
589
596
590 code = PyMarshal_ReadObjectFromString(buf + 8, size - 8);
597 code = PyMarshal_ReadObjectFromString(buf + 8, size - 8);
591 if (code == NULL)
598 if (code == NULL)
592 return NULL;
599 return NULL;
593 if (!PyCode_Check(code)) {
600 if (!PyCode_Check(code)) {
594 Py_DECREF(code);
601 Py_DECREF(code);
595 PyErr_Format(PyExc_TypeError,
602 PyErr_Format(PyExc_TypeError,
596 "compiled module %.200s is not a code object",
603 "compiled module %.200s is not a code object",
597 path.toLatin1().constData());
604 path.toLatin1().constData());
598 return NULL;
605 return NULL;
599 }
606 }
600 return code;
607 return code;
601 }
608 }
602
609
603
610
604 /* Given a string buffer containing Python source code, compile it
611 /* Given a string buffer containing Python source code, compile it
605 return and return a code object as a new reference. */
612 return and return a code object as a new reference. */
606 PyObject *
613 PyObject *
607 PythonQtImport::compileSource(const QString& path, const QByteArray& data)
614 PythonQtImport::compileSource(const QString& path, const QByteArray& data)
608 {
615 {
609 PyObject *code;
616 PyObject *code;
610 QByteArray data1 = data;
617 QByteArray data1 = data;
611 // in qt4, data is null terminated
618 // in qt4, data is null terminated
612 // data1.resize(data.size()+1);
619 // data1.resize(data.size()+1);
613 // data1.data()[data.size()-1] = 0;
620 // data1.data()[data.size()-1] = 0;
614 code = Py_CompileString(data.data(), path.toLatin1().constData(),
621 code = Py_CompileString(data.data(), path.toLatin1().constData(),
615 Py_file_input);
622 Py_file_input);
616 return code;
623 return code;
617 }
624 }
618
625
619
626
620 /* Return the code object for the module named by 'fullname' from the
627 /* Return the code object for the module named by 'fullname' from the
621 Zip archive as a new reference. */
628 Zip archive as a new reference. */
622 PyObject *
629 PyObject *
623 PythonQtImport::getCodeFromData(const QString& path, int isbytecode,int /*ispackage*/, time_t mtime)
630 PythonQtImport::getCodeFromData(const QString& path, int isbytecode,int /*ispackage*/, time_t mtime)
624 {
631 {
625 PyObject *code;
632 PyObject *code;
626
633
627 QByteArray qdata;
634 QByteArray qdata;
628 if (!isbytecode) {
635 if (!isbytecode) {
629 // mlabDebugConst("MLABPython", "reading source " << path);
636 // mlabDebugConst("MLABPython", "reading source " << path);
630 bool ok;
637 bool ok;
631 qdata = PythonQt::importInterface()->readSourceFile(path, ok);
638 qdata = PythonQt::importInterface()->readSourceFile(path, ok);
632 if (!ok) {
639 if (!ok) {
633 // mlabErrorConst("PythonQtImporter","File could not be verified" << path);
640 // mlabErrorConst("PythonQtImporter","File could not be verified" << path);
634 return NULL;
641 return NULL;
635 }
642 }
636 if (qdata == " ") {
643 if (qdata == " ") {
637 qdata.clear();
644 qdata.clear();
638 }
645 }
639 } else {
646 } else {
640 qdata = PythonQt::importInterface()->readFileAsBytes(path);
647 qdata = PythonQt::importInterface()->readFileAsBytes(path);
641 }
648 }
642
649
643 if (isbytecode) {
650 if (isbytecode) {
644 // mlabDebugConst("MLABPython", "reading bytecode " << path);
651 // mlabDebugConst("MLABPython", "reading bytecode " << path);
645 code = unmarshalCode(path, qdata, mtime);
652 code = unmarshalCode(path, qdata, mtime);
646 }
653 }
647 else {
654 else {
648 // mlabDebugConst("MLABPython", "compiling source " << path);
655 // mlabDebugConst("MLABPython", "compiling source " << path);
649 code = compileSource(path, qdata);
656 code = compileSource(path, qdata);
650 if (code) {
657 if (code) {
651 // save a pyc file if possible
658 // save a pyc file if possible
652 QDateTime time;
659 QDateTime time;
653 time = PythonQt::importInterface()->lastModifiedDate(path);
660 time = PythonQt::importInterface()->lastModifiedDate(path);
654 writeCompiledModule((PyCodeObject*)code, path+"c", time.toTime_t());
661 writeCompiledModule((PyCodeObject*)code, path+"c", time.toTime_t());
655 }
662 }
656 }
663 }
657 return code;
664 return code;
658 }
665 }
659
666
660 time_t
667 time_t
661 PythonQtImport::getMTimeOfSource(const QString& path)
668 PythonQtImport::getMTimeOfSource(const QString& path)
662 {
669 {
663 time_t mtime = 0;
670 time_t mtime = 0;
664 QString path2 = path;
671 QString path2 = path;
665 path2.truncate(path.length()-1);
672 path2.truncate(path.length()-1);
666
673
667 if (PythonQt::importInterface()->exists(path2)) {
674 if (PythonQt::importInterface()->exists(path2)) {
668 QDateTime t = PythonQt::importInterface()->lastModifiedDate(path2);
675 QDateTime t = PythonQt::importInterface()->lastModifiedDate(path2);
669 if (t.isValid()) {
676 if (t.isValid()) {
670 mtime = t.toTime_t();
677 mtime = t.toTime_t();
671 }
678 }
672 }
679 }
673
680
674 return mtime;
681 return mtime;
675 }
682 }
676
683
677 /* Get the code object associated with the module specified by
684 /* Get the code object associated with the module specified by
678 'fullname'. */
685 'fullname'. */
679 PyObject *
686 PyObject *
680 PythonQtImport::getModuleCode(PythonQtImporter *self, const char* fullname, QString& modpath)
687 PythonQtImport::getModuleCode(PythonQtImporter *self, const char* fullname, QString& modpath)
681 {
688 {
682 QString subname;
689 QString subname;
683 struct st_mlab_searchorder *zso;
690 struct st_mlab_searchorder *zso;
684
691
685 subname = getSubName(fullname);
692 subname = getSubName(fullname);
686 QString path = *self->_path + "/" + subname;
693 QString path = *self->_path + "/" + subname;
687
694
688 QString test;
695 QString test;
689 for (zso = mlab_searchorder; *zso->suffix; zso++) {
696 for (zso = mlab_searchorder; *zso->suffix; zso++) {
690 PyObject *code = NULL;
697 PyObject *code = NULL;
691 test = path + zso->suffix;
698 test = path + zso->suffix;
692
699
693 if (Py_VerboseFlag > 1)
700 if (Py_VerboseFlag > 1)
694 PySys_WriteStderr("# trying %s\n",
701 PySys_WriteStderr("# trying %s\n",
695 test.toLatin1().constData());
702 test.toLatin1().constData());
696 if (PythonQt::importInterface()->exists(test)) {
703 if (PythonQt::importInterface()->exists(test)) {
697 time_t mtime = 0;
704 time_t mtime = 0;
698 int ispackage = zso->type & IS_PACKAGE;
705 int ispackage = zso->type & IS_PACKAGE;
699 int isbytecode = zso->type & IS_BYTECODE;
706 int isbytecode = zso->type & IS_BYTECODE;
700
707
701 // if ignoreUpdatedPythonSourceFiles() returns true, then mtime stays 0
708 // if ignoreUpdatedPythonSourceFiles() returns true, then mtime stays 0
702 // and unmarshalCode() in getCodeFromData() will always read an existing *.pyc file,
709 // and unmarshalCode() in getCodeFromData() will always read an existing *.pyc file,
703 // even if a newer *.py file exists. This is a release optimization where
710 // even if a newer *.py file exists. This is a release optimization where
704 // typically only *.pyc files are delivered without *.py files and reading file
711 // typically only *.pyc files are delivered without *.py files and reading file
705 // modification time is slow.
712 // modification time is slow.
706 if (isbytecode && !PythonQt::importInterface()->ignoreUpdatedPythonSourceFiles()) {
713 if (isbytecode && !PythonQt::importInterface()->ignoreUpdatedPythonSourceFiles()) {
707 mtime = getMTimeOfSource(test);
714 mtime = getMTimeOfSource(test);
708 }
715 }
709 code = getCodeFromData(test, isbytecode, ispackage, mtime);
716 code = getCodeFromData(test, isbytecode, ispackage, mtime);
710 if (code == Py_None) {
717 if (code == Py_None) {
711 Py_DECREF(code);
718 Py_DECREF(code);
712 continue;
719 continue;
713 }
720 }
714 if (code != NULL) {
721 if (code != NULL) {
715 modpath = test;
722 modpath = test;
716 }
723 }
717 return code;
724 return code;
718 }
725 }
719 }
726 }
720 PyErr_Format(PythonQtImportError, "can't find module '%.200s'", fullname);
727 PyErr_Format(PythonQtImportError, "can't find module '%.200s'", fullname);
721
728
722 return NULL;
729 return NULL;
723 }
730 }
724
731
725 QString PythonQtImport::replaceExtension(const QString& str, const QString& ext)
732 QString PythonQtImport::replaceExtension(const QString& str, const QString& ext)
726 {
733 {
727 QString r;
734 QString r;
728 int i = str.lastIndexOf('.');
735 int i = str.lastIndexOf('.');
729 if (i!=-1) {
736 if (i!=-1) {
730 r = str.mid(0,i) + "." + ext;
737 r = str.mid(0,i) + "." + ext;
731 } else {
738 } else {
732 r = str + "." + ext;
739 r = str + "." + ext;
733 }
740 }
734 return r;
741 return r;
735 }
742 }
736
743
737 PyObject* PythonQtImport::getCodeFromPyc(const QString& file)
744 PyObject* PythonQtImport::getCodeFromPyc(const QString& file)
738 {
745 {
739 PyObject* code;
746 PyObject* code;
740 const static QString pycStr("pyc");
747 const static QString pycStr("pyc");
741 QString pyc = replaceExtension(file, pycStr);
748 QString pyc = replaceExtension(file, pycStr);
742 if (PythonQt::importInterface()->exists(pyc)) {
749 if (PythonQt::importInterface()->exists(pyc)) {
743 time_t mtime = 0;
750 time_t mtime = 0;
744 // if ignoreUpdatedPythonSourceFiles() returns true, then mtime stays 0
751 // if ignoreUpdatedPythonSourceFiles() returns true, then mtime stays 0
745 // and unmarshalCode() in getCodeFromData() will always read an existing *.pyc file,
752 // and unmarshalCode() in getCodeFromData() will always read an existing *.pyc file,
746 // even if a newer *.py file exists. This is a release optimization where
753 // even if a newer *.py file exists. This is a release optimization where
747 // typically only *.pyc files are delivered without *.py files and reading file
754 // typically only *.pyc files are delivered without *.py files and reading file
748 // modification time is slow.
755 // modification time is slow.
749 if (!PythonQt::importInterface()->ignoreUpdatedPythonSourceFiles()) {
756 if (!PythonQt::importInterface()->ignoreUpdatedPythonSourceFiles()) {
750 mtime = getMTimeOfSource(pyc);
757 mtime = getMTimeOfSource(pyc);
751 }
758 }
752 code = getCodeFromData(pyc, true, false, mtime);
759 code = getCodeFromData(pyc, true, false, mtime);
753 if (code != Py_None && code != NULL) {
760 if (code != Py_None && code != NULL) {
754 return code;
761 return code;
755 }
762 }
756 if (code) {
763 if (code) {
757 Py_DECREF(code);
764 Py_DECREF(code);
758 }
765 }
759 }
766 }
760 code = getCodeFromData(file,false,false,0);
767 code = getCodeFromData(file,false,false,0);
761 return code;
768 return code;
762 }
769 }
763
770
764 /* Module init */
771 /* Module init */
765
772
766 PyDoc_STRVAR(mlabimport_doc,
773 PyDoc_STRVAR(mlabimport_doc,
767 "Imports python files into PythonQt, completely replaces internal python import");
774 "Imports python files into PythonQt, completely replaces internal python import");
768
775
776 #ifdef PY3K
777 static struct PyModuleDef PythonQtImport_def = {
778 PyModuleDef_HEAD_INIT,
779 "PythonQtImport", /* m_name */
780 mlabimport_doc, /* m_doc */
781 -1, /* m_size */
782 NULL, /* m_methods */
783 NULL, /* m_reload */
784 NULL, /* m_traverse */
785 NULL, /* m_clear */
786 NULL /* m_free */
787 };
788 #endif
789
769 void PythonQtImport::init()
790 void PythonQtImport::init()
770 {
791 {
771 static bool first = true;
792 static bool first = true;
772 if (!first) {
793 if (!first) {
773 return;
794 return;
774 }
795 }
775 first = false;
796 first = false;
776
797
777 PyObject *mod;
798 PyObject *mod;
778
799
779 if (PyType_Ready(&PythonQtImporter_Type) < 0)
800 if (PyType_Ready(&PythonQtImporter_Type) < 0)
780 return;
801 return;
781
802
782 /* Correct directory separator */
803 /* Correct directory separator */
783 mlab_searchorder[0].suffix[0] = SEP;
804 mlab_searchorder[0].suffix[0] = SEP;
784 mlab_searchorder[1].suffix[0] = SEP;
805 mlab_searchorder[1].suffix[0] = SEP;
785 mlab_searchorder[2].suffix[0] = SEP;
806 mlab_searchorder[2].suffix[0] = SEP;
786 if (Py_OptimizeFlag) {
807 if (Py_OptimizeFlag) {
787 /* Reverse *.pyc and *.pyo */
808 /* Reverse *.pyc and *.pyo */
788 struct st_mlab_searchorder tmp;
809 struct st_mlab_searchorder tmp;
789 tmp = mlab_searchorder[0];
810 tmp = mlab_searchorder[0];
790 mlab_searchorder[0] = mlab_searchorder[1];
811 mlab_searchorder[0] = mlab_searchorder[1];
791 mlab_searchorder[1] = tmp;
812 mlab_searchorder[1] = tmp;
792 tmp = mlab_searchorder[3];
813 tmp = mlab_searchorder[3];
793 mlab_searchorder[3] = mlab_searchorder[4];
814 mlab_searchorder[3] = mlab_searchorder[4];
794 mlab_searchorder[4] = tmp;
815 mlab_searchorder[4] = tmp;
795 }
816 }
796
817
818 #ifdef PY3K
819 mod = PyModule_Create(&PythonQtImport_def);
820 #else
797 mod = Py_InitModule4("PythonQtImport", NULL, mlabimport_doc,
821 mod = Py_InitModule4("PythonQtImport", NULL, mlabimport_doc,
798 NULL, PYTHON_API_VERSION);
822 NULL, PYTHON_API_VERSION);
823 #endif
799
824
800 PythonQtImportError = PyErr_NewException(const_cast<char*>("PythonQtImport.PythonQtImportError"),
825 PythonQtImportError = PyErr_NewException(const_cast<char*>("PythonQtImport.PythonQtImportError"),
801 PyExc_ImportError, NULL);
826 PyExc_ImportError, NULL);
802 if (PythonQtImportError == NULL)
827 if (PythonQtImportError == NULL)
803 return;
828 return;
804
829
805 Py_INCREF(PythonQtImportError);
830 Py_INCREF(PythonQtImportError);
806 if (PyModule_AddObject(mod, "PythonQtImportError",
831 if (PyModule_AddObject(mod, "PythonQtImportError",
807 PythonQtImportError) < 0)
832 PythonQtImportError) < 0)
808 return;
833 return;
809
834
810 Py_INCREF(&PythonQtImporter_Type);
835 Py_INCREF(&PythonQtImporter_Type);
811 if (PyModule_AddObject(mod, "PythonQtImporter",
836 if (PyModule_AddObject(mod, "PythonQtImporter",
812 (PyObject *)&PythonQtImporter_Type) < 0)
837 (PyObject *)&PythonQtImporter_Type) < 0)
813 return;
838 return;
814
839
815 // set our importer into the path_hooks to handle all path on sys.path
840 // set our importer into the path_hooks to handle all path on sys.path
816 PyObject* classobj = PyDict_GetItemString(PyModule_GetDict(mod), "PythonQtImporter");
841 PyObject* classobj = PyDict_GetItemString(PyModule_GetDict(mod), "PythonQtImporter");
817 PyObject* path_hooks = PySys_GetObject(const_cast<char*>("path_hooks"));
842 PyObject* path_hooks = PySys_GetObject(const_cast<char*>("path_hooks"));
818 PyList_Append(path_hooks, classobj);
843 PyList_Append(path_hooks, classobj);
819
844
820 #ifndef WIN32
845 #ifndef WIN32
821 // reload the encodings module, because it might fail to custom import requirements (e.g. encryption).
846 // reload the encodings module, because it might fail to custom import requirements (e.g. encryption).
822 PyObject* modules = PyImport_GetModuleDict();
847 PyObject* modules = PyImport_GetModuleDict();
823 PyObject* encodingsModule = PyDict_GetItemString(modules, "encodings");
848 PyObject* encodingsModule = PyDict_GetItemString(modules, "encodings");
824 if (encodingsModule != NULL) {
849 if (encodingsModule != NULL) {
825 PyImport_ReloadModule(encodingsModule);
850 PyImport_ReloadModule(encodingsModule);
826 }
851 }
827 #endif
852 #endif
828 }
853 }
@@ -1,774 +1,848
1 /*
1 /*
2 *
2 *
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
4 *
4 *
5 * This library is free software; you can redistribute it and/or
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
8 * version 2.1 of the License, or (at your option) any later version.
9 *
9 *
10 * This library is distributed in the hope that it will be useful,
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
13 * Lesser General Public License for more details.
14 *
14 *
15 * Further, this software is distributed without any warranty that it is
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
20 * other software, or any other product whatsoever.
21 *
21 *
22 * You should have received a copy of the GNU Lesser General Public
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
25 *
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
27 * 28359 Bremen, Germany or:
27 * 28359 Bremen, Germany or:
28 *
28 *
29 * http://www.mevis.de
29 * http://www.mevis.de
30 *
30 *
31 */
31 */
32
32
33 //----------------------------------------------------------------------------------
33 //----------------------------------------------------------------------------------
34 /*!
34 /*!
35 // \file PythonQtInstanceWrapper.cpp
35 // \file PythonQtInstanceWrapper.cpp
36 // \author Florian Link
36 // \author Florian Link
37 // \author Last changed by $Author: florian $
37 // \author Last changed by $Author: florian $
38 // \date 2006-05
38 // \date 2006-05
39 */
39 */
40 //----------------------------------------------------------------------------------
40 //----------------------------------------------------------------------------------
41
41
42 #include "PythonQtInstanceWrapper.h"
42 #include "PythonQtInstanceWrapper.h"
43 #include <QObject>
43 #include <QObject>
44 #include "PythonQt.h"
44 #include "PythonQt.h"
45 #include "PythonQtSlot.h"
45 #include "PythonQtSlot.h"
46 #include "PythonQtSignal.h"
46 #include "PythonQtSignal.h"
47 #include "PythonQtClassInfo.h"
47 #include "PythonQtClassInfo.h"
48 #include "PythonQtConversion.h"
48 #include "PythonQtConversion.h"
49 #include "PythonQtClassWrapper.h"
49 #include "PythonQtClassWrapper.h"
50
50
51 #if PY_MAJOR_VERSION >= 3
52 #define PY3K
53 #endif
54
51 PythonQtClassInfo* PythonQtInstanceWrapperStruct::classInfo()
55 PythonQtClassInfo* PythonQtInstanceWrapperStruct::classInfo()
52 {
56 {
53 // take the class info from our type object
57 // take the class info from our type object
54 return ((PythonQtClassWrapper*)ob_type)->_classInfo;
58 return ((PythonQtClassWrapper*)Py_TYPE(this))->_classInfo;
55 }
59 }
56
60
57 static void PythonQtInstanceWrapper_deleteObject(PythonQtInstanceWrapper* self, bool force = false) {
61 static void PythonQtInstanceWrapper_deleteObject(PythonQtInstanceWrapper* self, bool force = false) {
58
62
59 // is this a C++ wrapper?
63 // is this a C++ wrapper?
60 if (self->_wrappedPtr) {
64 if (self->_wrappedPtr) {
61 //mlabDebugConst("Python","c++ wrapper removed " << self->_wrappedPtr << " " << self->_obj->className() << " " << self->classInfo()->wrappedClassName().latin1());
65 //mlabDebugConst("Python","c++ wrapper removed " << self->_wrappedPtr << " " << self->_obj->className() << " " << self->classInfo()->wrappedClassName().latin1());
62
66
63 PythonQt::priv()->removeWrapperPointer(self->_wrappedPtr);
67 PythonQt::priv()->removeWrapperPointer(self->_wrappedPtr);
64 // we own our qobject, so we delete it now:
68 // we own our qobject, so we delete it now:
65 delete self->_obj;
69 delete self->_obj;
66 self->_obj = NULL;
70 self->_obj = NULL;
67 if (force || self->_ownedByPythonQt) {
71 if (force || self->_ownedByPythonQt) {
68 int type = self->classInfo()->metaTypeId();
72 int type = self->classInfo()->metaTypeId();
69 if (self->_useQMetaTypeDestroy && type>=0) {
73 if (self->_useQMetaTypeDestroy && type>=0) {
70 // use QMetaType to destroy the object
74 // use QMetaType to destroy the object
71 QMetaType::destroy(type, self->_wrappedPtr);
75 QMetaType::destroy(type, self->_wrappedPtr);
72 } else {
76 } else {
73 PythonQtSlotInfo* slot = self->classInfo()->destructor();
77 PythonQtSlotInfo* slot = self->classInfo()->destructor();
74 if (slot) {
78 if (slot) {
75 void* args[2];
79 void* args[2];
76 args[0] = NULL;
80 args[0] = NULL;
77 args[1] = &self->_wrappedPtr;
81 args[1] = &self->_wrappedPtr;
78 slot->decorator()->qt_metacall(QMetaObject::InvokeMetaMethod, slot->slotIndex(), args);
82 slot->decorator()->qt_metacall(QMetaObject::InvokeMetaMethod, slot->slotIndex(), args);
79 self->_wrappedPtr = NULL;
83 self->_wrappedPtr = NULL;
80 } else {
84 } else {
81 if (type>=0) {
85 if (type>=0) {
82 // use QMetaType to destroy the object
86 // use QMetaType to destroy the object
83 QMetaType::destroy(type, self->_wrappedPtr);
87 QMetaType::destroy(type, self->_wrappedPtr);
84 } else {
88 } else {
85 // TODO: warn about not being able to destroy the object?
89 // TODO: warn about not being able to destroy the object?
86 }
90 }
87 }
91 }
88 }
92 }
89 }
93 }
90 } else {
94 } else {
91 //mlabDebugConst("Python","qobject wrapper removed " << self->_obj->className() << " " << self->classInfo()->wrappedClassName().latin1());
95 //mlabDebugConst("Python","qobject wrapper removed " << self->_obj->className() << " " << self->classInfo()->wrappedClassName().latin1());
92 if (self->_objPointerCopy) {
96 if (self->_objPointerCopy) {
93 PythonQt::priv()->removeWrapperPointer(self->_objPointerCopy);
97 PythonQt::priv()->removeWrapperPointer(self->_objPointerCopy);
94 }
98 }
95 if (self->_obj) {
99 if (self->_obj) {
96 if (force || self->_ownedByPythonQt) {
100 if (force || self->_ownedByPythonQt) {
97 if (force || !self->_obj->parent()) {
101 if (force || !self->_obj->parent()) {
98 delete self->_obj;
102 delete self->_obj;
99 }
103 }
100 } else {
104 } else {
101 if (self->_obj->parent()==NULL) {
105 if (self->_obj->parent()==NULL) {
102 // tell someone who is interested that the qobject is no longer wrapped, if it has no parent
106 // tell someone who is interested that the qobject is no longer wrapped, if it has no parent
103 PythonQt::qObjectNoLongerWrappedCB(self->_obj);
107 PythonQt::qObjectNoLongerWrappedCB(self->_obj);
104 }
108 }
105 }
109 }
106 }
110 }
107 }
111 }
108 self->_obj = NULL;
112 self->_obj = NULL;
109 }
113 }
110
114
111 static void PythonQtInstanceWrapper_dealloc(PythonQtInstanceWrapper* self)
115 static void PythonQtInstanceWrapper_dealloc(PythonQtInstanceWrapper* self)
112 {
116 {
113 PythonQtInstanceWrapper_deleteObject(self);
117 PythonQtInstanceWrapper_deleteObject(self);
114 self->_obj.~QPointer<QObject>();
118 self->_obj.~QPointer<QObject>();
115 self->ob_type->tp_free((PyObject*)self);
119 Py_TYPE(self)->tp_free((PyObject*)self);
116 }
120 }
117
121
118 static PyObject* PythonQtInstanceWrapper_new(PyTypeObject *type, PyObject * /*args*/, PyObject * /*kwds*/)
122 static PyObject* PythonQtInstanceWrapper_new(PyTypeObject *type, PyObject * /*args*/, PyObject * /*kwds*/)
119 {
123 {
120 //PythonQtClassWrapper *classType = (PythonQtClassWrapper*)type;
124 //PythonQtClassWrapper *classType = (PythonQtClassWrapper*)type;
121 PythonQtInstanceWrapper *self;
125 PythonQtInstanceWrapper *self;
122 static PyObject* emptyTuple = NULL;
126 static PyObject* emptyTuple = NULL;
123 if (emptyTuple==NULL) {
127 if (emptyTuple==NULL) {
124 emptyTuple = PyTuple_New(0);
128 emptyTuple = PyTuple_New(0);
125 }
129 }
126
130
127 self = (PythonQtInstanceWrapper*)PyBaseObject_Type.tp_new(type, emptyTuple, NULL);
131 self = (PythonQtInstanceWrapper*)PyBaseObject_Type.tp_new(type, emptyTuple, NULL);
128
132
129 if (self != NULL) {
133 if (self != NULL) {
130 new (&self->_obj) QPointer<QObject>();
134 new (&self->_obj) QPointer<QObject>();
131 self->_wrappedPtr = NULL;
135 self->_wrappedPtr = NULL;
132 self->_ownedByPythonQt = false;
136 self->_ownedByPythonQt = false;
133 self->_useQMetaTypeDestroy = false;
137 self->_useQMetaTypeDestroy = false;
134 self->_isShellInstance = false;
138 self->_isShellInstance = false;
135 }
139 }
136 return (PyObject *)self;
140 return (PyObject *)self;
137 }
141 }
138
142
139 int PythonQtInstanceWrapper_init(PythonQtInstanceWrapper * self, PyObject * args, PyObject * kwds)
143 int PythonQtInstanceWrapper_init(PythonQtInstanceWrapper * self, PyObject * args, PyObject * kwds)
140 {
144 {
141 if (args == PythonQtPrivate::dummyTuple()) {
145 if (args == PythonQtPrivate::dummyTuple()) {
142 // we are called from the internal PythonQt API, so our data will be filled later on...
146 // we are called from the internal PythonQt API, so our data will be filled later on...
143 return 0;
147 return 0;
144 }
148 }
145
149
146 // we are called from python, try to construct our object
150 // we are called from python, try to construct our object
147 if (self->classInfo()->constructors()) {
151 if (self->classInfo()->constructors()) {
148 void* directCPPPointer = NULL;
152 void* directCPPPointer = NULL;
149 PythonQtSlotFunction_CallImpl(self->classInfo(), NULL, self->classInfo()->constructors(), args, kwds, NULL, &directCPPPointer);
153 PythonQtSlotFunction_CallImpl(self->classInfo(), NULL, self->classInfo()->constructors(), args, kwds, NULL, &directCPPPointer);
150 if (PyErr_Occurred()) {
154 if (PyErr_Occurred()) {
151 return -1;
155 return -1;
152 }
156 }
153 if (directCPPPointer) {
157 if (directCPPPointer) {
154 // change ownershipflag to be owned by PythonQt
158 // change ownershipflag to be owned by PythonQt
155 self->_ownedByPythonQt = true;
159 self->_ownedByPythonQt = true;
156 self->_useQMetaTypeDestroy = false;
160 self->_useQMetaTypeDestroy = false;
157 if (self->classInfo()->isCPPWrapper()) {
161 if (self->classInfo()->isCPPWrapper()) {
158 self->_wrappedPtr = directCPPPointer;
162 self->_wrappedPtr = directCPPPointer;
159 // TODO xxx: if there is a wrapper factory, we might want to generate a wrapper for our class?!
163 // TODO xxx: if there is a wrapper factory, we might want to generate a wrapper for our class?!
160 } else {
164 } else {
161 self->setQObject((QObject*)directCPPPointer);
165 self->setQObject((QObject*)directCPPPointer);
162 }
166 }
163 // register with PythonQt
167 // register with PythonQt
164 PythonQt::priv()->addWrapperPointer(directCPPPointer, self);
168 PythonQt::priv()->addWrapperPointer(directCPPPointer, self);
165
169
166 PythonQtShellSetInstanceWrapperCB* cb = self->classInfo()->shellSetInstanceWrapperCB();
170 PythonQtShellSetInstanceWrapperCB* cb = self->classInfo()->shellSetInstanceWrapperCB();
167 if (cb) {
171 if (cb) {
168 // if we are a derived python class, we set the wrapper
172 // if we are a derived python class, we set the wrapper
169 // to activate the shell class, otherwise we just ignore that it is a shell...
173 // to activate the shell class, otherwise we just ignore that it is a shell...
170 // we detect it be checking if the type does not have PythonQtInstanceWrapper_Type as direct base class,
174 // we detect it be checking if the type does not have PythonQtInstanceWrapper_Type as direct base class,
171 // which is the case for all non-python derived types
175 // which is the case for all non-python derived types
172 if (((PyObject*)self)->ob_type->tp_base != &PythonQtInstanceWrapper_Type) {
176 if (((PyObject*)self)->ob_type->tp_base != &PythonQtInstanceWrapper_Type) {
173 // set the wrapper and remember that we have a shell instance!
177 // set the wrapper and remember that we have a shell instance!
174 (*cb)(directCPPPointer, self);
178 (*cb)(directCPPPointer, self);
175 self->_isShellInstance = true;
179 self->_isShellInstance = true;
176 }
180 }
177 }
181 }
178 }
182 }
179 } else {
183 } else {
180 QString error = QString("No constructors available for ") + self->classInfo()->className();
184 QString error = QString("No constructors available for ") + self->classInfo()->className();
181 PyErr_SetString(PyExc_ValueError, error.toLatin1().data());
185 PyErr_SetString(PyExc_ValueError, error.toLatin1().data());
182 return -1;
186 return -1;
183 }
187 }
184 return 0;
188 return 0;
185 }
189 }
186
190
187 static PyObject *PythonQtInstanceWrapper_richcompare(PythonQtInstanceWrapper* wrapper, PyObject* other, int code)
191 static PyObject *PythonQtInstanceWrapper_richcompare(PythonQtInstanceWrapper* wrapper, PyObject* other, int code)
188 {
192 {
189 bool validPtrs = false;
193 bool validPtrs = false;
190 bool areSamePtrs = false;
194 bool areSamePtrs = false;
191 if (PyObject_TypeCheck((PyObject*)wrapper, &PythonQtInstanceWrapper_Type)) {
195 if (PyObject_TypeCheck((PyObject*)wrapper, &PythonQtInstanceWrapper_Type)) {
192 if (PyObject_TypeCheck(other, &PythonQtInstanceWrapper_Type)) {
196 if (PyObject_TypeCheck(other, &PythonQtInstanceWrapper_Type)) {
193 validPtrs = true;
197 validPtrs = true;
194 PythonQtInstanceWrapper* w1 = wrapper;
198 PythonQtInstanceWrapper* w1 = wrapper;
195 PythonQtInstanceWrapper* w2 = (PythonQtInstanceWrapper*)other;
199 PythonQtInstanceWrapper* w2 = (PythonQtInstanceWrapper*)other;
196 // check pointers directly
200 // check pointers directly
197 if (w1->_wrappedPtr != NULL) {
201 if (w1->_wrappedPtr != NULL) {
198 if (w1->_wrappedPtr == w2->_wrappedPtr) {
202 if (w1->_wrappedPtr == w2->_wrappedPtr) {
199 areSamePtrs = true;
203 areSamePtrs = true;
200 }
204 }
201 } else if (w1->_obj == w2->_obj) {
205 } else if (w1->_obj == w2->_obj) {
202 areSamePtrs = true;
206 areSamePtrs = true;
203 }
207 }
204 } else if (other == Py_None) {
208 } else if (other == Py_None) {
205 validPtrs = true;
209 validPtrs = true;
206 if (wrapper->_obj || wrapper->_wrappedPtr) {
210 if (wrapper->_obj || wrapper->_wrappedPtr) {
207 areSamePtrs = false;
211 areSamePtrs = false;
208 } else {
212 } else {
209 areSamePtrs = true;
213 areSamePtrs = true;
210 }
214 }
211 }
215 }
212 }
216 }
213
217
214 if ((wrapper->classInfo()->typeSlots() & PythonQt::Type_RichCompare) == 0) {
218 if ((wrapper->classInfo()->typeSlots() & PythonQt::Type_RichCompare) == 0) {
215 // shortcut if richcompare is not supported:
219 // shortcut if richcompare is not supported:
216 if (validPtrs && code == Py_EQ) {
220 if (validPtrs && code == Py_EQ) {
217 return PythonQtConv::GetPyBool(areSamePtrs);
221 return PythonQtConv::GetPyBool(areSamePtrs);
218 } else if (validPtrs && code == Py_NE) {
222 } else if (validPtrs && code == Py_NE) {
219 return PythonQtConv::GetPyBool(!areSamePtrs);
223 return PythonQtConv::GetPyBool(!areSamePtrs);
220 }
224 }
221 Py_INCREF(Py_NotImplemented);
225 Py_INCREF(Py_NotImplemented);
222 return Py_NotImplemented;
226 return Py_NotImplemented;
223 }
227 }
224
228
225 QByteArray memberName;
229 QByteArray memberName;
226 switch (code) {
230 switch (code) {
227 case Py_LT:
231 case Py_LT:
228 {
232 {
229 static QByteArray name = "__lt__";
233 static QByteArray name = "__lt__";
230 memberName = name;
234 memberName = name;
231 }
235 }
232 break;
236 break;
233
237
234 case Py_LE:
238 case Py_LE:
235 {
239 {
236 static QByteArray name = "__le__";
240 static QByteArray name = "__le__";
237 memberName = name;
241 memberName = name;
238 }
242 }
239 break;
243 break;
240
244
241 case Py_EQ:
245 case Py_EQ:
242 {
246 {
243 static QByteArray name = "__eq__";
247 static QByteArray name = "__eq__";
244 memberName = name;
248 memberName = name;
245 }
249 }
246 break;
250 break;
247
251
248 case Py_NE:
252 case Py_NE:
249 {
253 {
250 static QByteArray name = "__ne__";
254 static QByteArray name = "__ne__";
251 memberName = name;
255 memberName = name;
252 }
256 }
253 break;
257 break;
254
258
255 case Py_GT:
259 case Py_GT:
256 {
260 {
257 static QByteArray name = "__gt__";
261 static QByteArray name = "__gt__";
258 memberName = name;
262 memberName = name;
259 }
263 }
260 break;
264 break;
261
265
262 case Py_GE:
266 case Py_GE:
263 {
267 {
264 static QByteArray name = "__ge__";
268 static QByteArray name = "__ge__";
265 memberName = name;
269 memberName = name;
266 }
270 }
267 break;
271 break;
268 }
272 }
269
273
270 PythonQtMemberInfo opSlot = wrapper->classInfo()->member(memberName);
274 PythonQtMemberInfo opSlot = wrapper->classInfo()->member(memberName);
271 if (opSlot._type == PythonQtMemberInfo::Slot) {
275 if (opSlot._type == PythonQtMemberInfo::Slot) {
272 // TODO get rid of tuple
276 // TODO get rid of tuple
273 PyObject* args = PyTuple_New(1);
277 PyObject* args = PyTuple_New(1);
274 Py_INCREF(other);
278 Py_INCREF(other);
275 PyTuple_SET_ITEM(args, 0, other);
279 PyTuple_SET_ITEM(args, 0, other);
276 PyObject* result = PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, opSlot._slot, args, NULL, wrapper->_wrappedPtr);
280 PyObject* result = PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, opSlot._slot, args, NULL, wrapper->_wrappedPtr);
277 Py_DECREF(args);
281 Py_DECREF(args);
278 return result;
282 return result;
279 } else {
283 } else {
280 // not implemented, let python try something else!
284 // not implemented, let python try something else!
281 Py_INCREF(Py_NotImplemented);
285 Py_INCREF(Py_NotImplemented);
282 return Py_NotImplemented;
286 return Py_NotImplemented;
283 }
287 }
284 }
288 }
285
289
286
290
287 static PyObject *PythonQtInstanceWrapper_classname(PythonQtInstanceWrapper* obj)
291 static PyObject *PythonQtInstanceWrapper_classname(PythonQtInstanceWrapper* obj)
288 {
292 {
289 return PyString_FromString(obj->ob_type->tp_name);
293 #ifdef PY3K
294 return PyUnicode_FromString(Py_TYPE(obj)->tp_name);
295 #else
296 return PyString_FromString(Py_TYPE(obj)->tp_name);
297 #endif
290 }
298 }
291
299
292 PyObject *PythonQtInstanceWrapper_inherits(PythonQtInstanceWrapper* obj, PyObject *args)
300 PyObject *PythonQtInstanceWrapper_inherits(PythonQtInstanceWrapper* obj, PyObject *args)
293 {
301 {
294 char *name = NULL;
302 char *name = NULL;
295 if (!PyArg_ParseTuple(args, "s:PythonQtInstanceWrapper.inherits",&name)) {
303 if (!PyArg_ParseTuple(args, "s:PythonQtInstanceWrapper.inherits",&name)) {
296 return NULL;
304 return NULL;
297 }
305 }
298 return PythonQtConv::GetPyBool(obj->classInfo()->inherits(name));
306 return PythonQtConv::GetPyBool(obj->classInfo()->inherits(name));
299 }
307 }
300
308
301 static PyObject *PythonQtInstanceWrapper_help(PythonQtInstanceWrapper* obj)
309 static PyObject *PythonQtInstanceWrapper_help(PythonQtInstanceWrapper* obj)
302 {
310 {
303 return PythonQt::self()->helpCalled(obj->classInfo());
311 return PythonQt::self()->helpCalled(obj->classInfo());
304 }
312 }
305
313
306 PyObject *PythonQtInstanceWrapper_delete(PythonQtInstanceWrapper * self)
314 PyObject *PythonQtInstanceWrapper_delete(PythonQtInstanceWrapper * self)
307 {
315 {
308 PythonQtInstanceWrapper_deleteObject(self, true);
316 PythonQtInstanceWrapper_deleteObject(self, true);
309 Py_INCREF(Py_None);
317 Py_INCREF(Py_None);
310 return Py_None;
318 return Py_None;
311 }
319 }
312
320
313
321
314 static PyMethodDef PythonQtInstanceWrapper_methods[] = {
322 static PyMethodDef PythonQtInstanceWrapper_methods[] = {
315 {"className", (PyCFunction)PythonQtInstanceWrapper_classname, METH_NOARGS,
323 {"className", (PyCFunction)PythonQtInstanceWrapper_classname, METH_NOARGS,
316 "Return the classname of the object"
324 "Return the classname of the object"
317 },
325 },
318 {"inherits", (PyCFunction)PythonQtInstanceWrapper_inherits, METH_VARARGS,
326 {"inherits", (PyCFunction)PythonQtInstanceWrapper_inherits, METH_VARARGS,
319 "Returns if the class inherits or is of given type name"
327 "Returns if the class inherits or is of given type name"
320 },
328 },
321 {"help", (PyCFunction)PythonQtInstanceWrapper_help, METH_NOARGS,
329 {"help", (PyCFunction)PythonQtInstanceWrapper_help, METH_NOARGS,
322 "Shows the help of available methods for this class"
330 "Shows the help of available methods for this class"
323 },
331 },
324 {"delete", (PyCFunction)PythonQtInstanceWrapper_delete, METH_NOARGS,
332 {"delete", (PyCFunction)PythonQtInstanceWrapper_delete, METH_NOARGS,
325 "Deletes the C++ object (at your own risk, my friend!)"
333 "Deletes the C++ object (at your own risk, my friend!)"
326 },
334 },
327 {NULL, NULL, 0, NULL} /* Sentinel */
335 {NULL, NULL, 0, NULL} /* Sentinel */
328 };
336 };
329
337
330
338
331 static PyObject *PythonQtInstanceWrapper_getattro(PyObject *obj,PyObject *name)
339 static PyObject *PythonQtInstanceWrapper_getattro(PyObject *obj,PyObject *name)
332 {
340 {
333 const char *attributeName;
341 const char *attributeName;
334 PythonQtInstanceWrapper *wrapper = (PythonQtInstanceWrapper *)obj;
342 PythonQtInstanceWrapper *wrapper = (PythonQtInstanceWrapper *)obj;
335
343
344 #ifdef PY3K
345 if ((attributeName = PyUnicode_AsUTF8(name)) == NULL) {
346 #else
336 if ((attributeName = PyString_AsString(name)) == NULL) {
347 if ((attributeName = PyString_AsString(name)) == NULL) {
348 #endif
337 return NULL;
349 return NULL;
338 }
350 }
339
351
340 if (qstrcmp(attributeName, "__dict__")==0) {
352 if (qstrcmp(attributeName, "__dict__")==0) {
341 PyObject* dict = PyBaseObject_Type.tp_getattro(obj, name);
353 PyObject* dict = PyBaseObject_Type.tp_getattro(obj, name);
342 dict = PyDict_Copy(dict);
354 dict = PyDict_Copy(dict);
343
355
344 if (wrapper->_obj) {
356 if (wrapper->_obj) {
345 // only the properties are missing, the rest is already available from
357 // only the properties are missing, the rest is already available from
346 // PythonQtClassWrapper...
358 // PythonQtClassWrapper...
347 QStringList l = wrapper->classInfo()->propertyList();
359 QStringList l = wrapper->classInfo()->propertyList();
348 Q_FOREACH (QString name, l) {
360 Q_FOREACH (QString name, l) {
349 PyObject* o = PyObject_GetAttrString(obj, name.toLatin1().data());
361 PyObject* o = PyObject_GetAttrString(obj, name.toLatin1().data());
350 if (o) {
362 if (o) {
351 PyDict_SetItemString(dict, name.toLatin1().data(), o);
363 PyDict_SetItemString(dict, name.toLatin1().data(), o);
352 Py_DECREF(o);
364 Py_DECREF(o);
353 } else {
365 } else {
354 std::cerr << "PythonQtInstanceWrapper: something is wrong, could not get attribute " << name.toLatin1().data();
366 std::cerr << "PythonQtInstanceWrapper: something is wrong, could not get attribute " << name.toLatin1().data();
355 }
367 }
356 }
368 }
357
369
358 QList<QByteArray> dynamicProps = wrapper->_obj->dynamicPropertyNames();
370 QList<QByteArray> dynamicProps = wrapper->_obj->dynamicPropertyNames();
359 Q_FOREACH (QByteArray name, dynamicProps) {
371 Q_FOREACH (QByteArray name, dynamicProps) {
360 PyObject* o = PyObject_GetAttrString(obj, name.data());
372 PyObject* o = PyObject_GetAttrString(obj, name.data());
361 if (o) {
373 if (o) {
362 PyDict_SetItemString(dict, name.data(), o);
374 PyDict_SetItemString(dict, name.data(), o);
363 Py_DECREF(o);
375 Py_DECREF(o);
364 } else {
376 } else {
365 std::cerr << "PythonQtInstanceWrapper: dynamic property could not be read " << name.data();
377 std::cerr << "PythonQtInstanceWrapper: dynamic property could not be read " << name.data();
366 }
378 }
367 }
379 }
368 }
380 }
369 // Note: we do not put children into the dict, is would look confusing?!
381 // Note: we do not put children into the dict, is would look confusing?!
370 return dict;
382 return dict;
371 }
383 }
372
384
373 // first look in super, to return derived methods from base object first
385 // first look in super, to return derived methods from base object first
374 PyObject* superAttr = PyBaseObject_Type.tp_getattro(obj, name);
386 PyObject* superAttr = PyBaseObject_Type.tp_getattro(obj, name);
375 if (superAttr) {
387 if (superAttr) {
376 return superAttr;
388 return superAttr;
377 }
389 }
378 PyErr_Clear();
390 PyErr_Clear();
379
391
380 // mlabDebugConst("Python","get " << attributeName);
392 // mlabDebugConst("Python","get " << attributeName);
381
393
382 PythonQtMemberInfo member = wrapper->classInfo()->member(attributeName);
394 PythonQtMemberInfo member = wrapper->classInfo()->member(attributeName);
383 switch (member._type) {
395 switch (member._type) {
384 case PythonQtMemberInfo::Property:
396 case PythonQtMemberInfo::Property:
385 if (wrapper->_obj) {
397 if (wrapper->_obj) {
386 if (member._property.userType() != QVariant::Invalid) {
398 if (member._property.userType() != QVariant::Invalid) {
387
399
388 PythonQt::ProfilingCB* profilingCB = PythonQt::priv()->profilingCB();
400 PythonQt::ProfilingCB* profilingCB = PythonQt::priv()->profilingCB();
389 if (profilingCB) {
401 if (profilingCB) {
390 QString methodName = "getProperty(";
402 QString methodName = "getProperty(";
391 methodName += attributeName;
403 methodName += attributeName;
392 methodName += ")";
404 methodName += ")";
393 profilingCB(PythonQt::Enter, wrapper->_obj->metaObject()->className(), methodName.toLatin1());
405 profilingCB(PythonQt::Enter, wrapper->_obj->metaObject()->className(), methodName.toLatin1());
394 }
406 }
395
407
396 PyObject* value = PythonQtConv::QVariantToPyObject(member._property.read(wrapper->_obj));
408 PyObject* value = PythonQtConv::QVariantToPyObject(member._property.read(wrapper->_obj));
397
409
398 if (profilingCB) {
410 if (profilingCB) {
399 profilingCB(PythonQt::Leave, NULL, NULL);
411 profilingCB(PythonQt::Leave, NULL, NULL);
400 }
412 }
401
413
402 return value;
414 return value;
403
415
404 } else {
416 } else {
405 Py_INCREF(Py_None);
417 Py_INCREF(Py_None);
406 return Py_None;
418 return Py_None;
407 }
419 }
408 } else {
420 } else {
409 QString error = QString("Trying to read property '") + attributeName + "' from a destroyed " + wrapper->classInfo()->className() + " object";
421 QString error = QString("Trying to read property '") + attributeName + "' from a destroyed " + wrapper->classInfo()->className() + " object";
410 PyErr_SetString(PyExc_ValueError, error.toLatin1().data());
422 PyErr_SetString(PyExc_ValueError, error.toLatin1().data());
411 return NULL;
423 return NULL;
412 }
424 }
413 break;
425 break;
414 case PythonQtMemberInfo::Slot:
426 case PythonQtMemberInfo::Slot:
415 return PythonQtSlotFunction_New(member._slot, obj, NULL);
427 return PythonQtSlotFunction_New(member._slot, obj, NULL);
416 break;
428 break;
417 case PythonQtMemberInfo::Signal:
429 case PythonQtMemberInfo::Signal:
418 return PythonQtSignalFunction_New(member._slot, obj, NULL);
430 return PythonQtSignalFunction_New(member._slot, obj, NULL);
419 break;
431 break;
420 case PythonQtMemberInfo::EnumValue:
432 case PythonQtMemberInfo::EnumValue:
421 {
433 {
422 PyObject* enumValue = member._enumValue;
434 PyObject* enumValue = member._enumValue;
423 Py_INCREF(enumValue);
435 Py_INCREF(enumValue);
424 return enumValue;
436 return enumValue;
425 }
437 }
426 break;
438 break;
427 case PythonQtMemberInfo::EnumWrapper:
439 case PythonQtMemberInfo::EnumWrapper:
428 {
440 {
429 PyObject* enumWrapper = member._enumWrapper;
441 PyObject* enumWrapper = member._enumWrapper;
430 Py_INCREF(enumWrapper);
442 Py_INCREF(enumWrapper);
431 return enumWrapper;
443 return enumWrapper;
432 }
444 }
433 break;
445 break;
434 case PythonQtMemberInfo::NotFound:
446 case PythonQtMemberInfo::NotFound:
435 {
447 {
436 static const QByteArray getterString("py_get_");
448 static const QByteArray getterString("py_get_");
437 // check for a getter slot
449 // check for a getter slot
438 PythonQtMemberInfo member = wrapper->classInfo()->member(getterString + attributeName);
450 PythonQtMemberInfo member = wrapper->classInfo()->member(getterString + attributeName);
439 if (member._type == PythonQtMemberInfo::Slot) {
451 if (member._type == PythonQtMemberInfo::Slot) {
440 return PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, member._slot, NULL, NULL, wrapper->_wrappedPtr);
452 return PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, member._slot, NULL, NULL, wrapper->_wrappedPtr);
441 }
453 }
442
454
443 // handle dynamic properties
455 // handle dynamic properties
444 if (wrapper->_obj) {
456 if (wrapper->_obj) {
445 QVariant v = wrapper->_obj->property(attributeName);
457 QVariant v = wrapper->_obj->property(attributeName);
446 if (v.isValid()) {
458 if (v.isValid()) {
447 return PythonQtConv::QVariantToPyObject(v);
459 return PythonQtConv::QVariantToPyObject(v);
448 }
460 }
449 }
461 }
450 }
462 }
451 break;
463 break;
452 default:
464 default:
453 // is an invalid type, go on
465 // is an invalid type, go on
454 break;
466 break;
455 }
467 }
456
468
457 // look for the internal methods (className(), help())
469 // look for the internal methods (className(), help())
470 #ifdef PY3K
471 PyObject* internalMethod = PyObject_GenericGetAttr(obj, name);
472 #else
458 PyObject* internalMethod = Py_FindMethod( PythonQtInstanceWrapper_methods, obj, (char*)attributeName);
473 PyObject* internalMethod = Py_FindMethod( PythonQtInstanceWrapper_methods, obj, (char*)attributeName);
474 #endif
459 if (internalMethod) {
475 if (internalMethod) {
460 return internalMethod;
476 return internalMethod;
461 }
477 }
462 PyErr_Clear();
478 PyErr_Clear();
463
479
464 if (wrapper->_obj) {
480 if (wrapper->_obj) {
465 // look for a child
481 // look for a child
466 QObjectList children = wrapper->_obj->children();
482 QObjectList children = wrapper->_obj->children();
467 for (int i = 0; i < children.count(); i++) {
483 for (int i = 0; i < children.count(); i++) {
468 QObject *child = children.at(i);
484 QObject *child = children.at(i);
469 if (child->objectName() == attributeName) {
485 if (child->objectName() == attributeName) {
470 return PythonQt::priv()->wrapQObject(child);
486 return PythonQt::priv()->wrapQObject(child);
471 }
487 }
472 }
488 }
473 }
489 }
474
490
475 QString error = QString(wrapper->classInfo()->className()) + " has no attribute named '" + QString(attributeName) + "'";
491 QString error = QString(wrapper->classInfo()->className()) + " has no attribute named '" + QString(attributeName) + "'";
476 PyErr_SetString(PyExc_AttributeError, error.toLatin1().data());
492 PyErr_SetString(PyExc_AttributeError, error.toLatin1().data());
477 return NULL;
493 return NULL;
478 }
494 }
479
495
480 static int PythonQtInstanceWrapper_setattro(PyObject *obj,PyObject *name,PyObject *value)
496 static int PythonQtInstanceWrapper_setattro(PyObject *obj,PyObject *name,PyObject *value)
481 {
497 {
482 QString error;
498 QString error;
483 const char *attributeName;
499 const char *attributeName;
484 PythonQtInstanceWrapper *wrapper = (PythonQtInstanceWrapper *)obj;
500 PythonQtInstanceWrapper *wrapper = (PythonQtInstanceWrapper *)obj;
485
501
502 #ifdef PY3K
503 if ((attributeName = PyUnicode_AsUTF8(name)) == NULL)
504 #else
486 if ((attributeName = PyString_AsString(name)) == NULL)
505 if ((attributeName = PyString_AsString(name)) == NULL)
506 #endif
487 return -1;
507 return -1;
488
508
489 PythonQtMemberInfo member = wrapper->classInfo()->member(attributeName);
509 PythonQtMemberInfo member = wrapper->classInfo()->member(attributeName);
490 if (member._type == PythonQtMemberInfo::Property) {
510 if (member._type == PythonQtMemberInfo::Property) {
491
511
492 if (!wrapper->_obj) {
512 if (!wrapper->_obj) {
493 error = QString("Trying to set property '") + attributeName + "' on a destroyed " + wrapper->classInfo()->className() + " object";
513 error = QString("Trying to set property '") + attributeName + "' on a destroyed " + wrapper->classInfo()->className() + " object";
494 PyErr_SetString(PyExc_AttributeError, error.toLatin1().data());
514 PyErr_SetString(PyExc_AttributeError, error.toLatin1().data());
495 return -1;
515 return -1;
496 }
516 }
497
517
498 QMetaProperty prop = member._property;
518 QMetaProperty prop = member._property;
499 if (prop.isWritable()) {
519 if (prop.isWritable()) {
500 QVariant v;
520 QVariant v;
501 if (prop.isEnumType()) {
521 if (prop.isEnumType()) {
502 // this will give us either a string or an int, everything else will probably be an error
522 // this will give us either a string or an int, everything else will probably be an error
503 v = PythonQtConv::PyObjToQVariant(value);
523 v = PythonQtConv::PyObjToQVariant(value);
504 } else {
524 } else {
505 int t = prop.userType();
525 int t = prop.userType();
506 v = PythonQtConv::PyObjToQVariant(value, t);
526 v = PythonQtConv::PyObjToQVariant(value, t);
507 }
527 }
508 bool success = false;
528 bool success = false;
509 if (v.isValid()) {
529 if (v.isValid()) {
510 PythonQt::ProfilingCB* profilingCB = PythonQt::priv()->profilingCB();
530 PythonQt::ProfilingCB* profilingCB = PythonQt::priv()->profilingCB();
511 if (profilingCB) {
531 if (profilingCB) {
512 QString methodName = "setProperty(";
532 QString methodName = "setProperty(";
513 methodName += attributeName;
533 methodName += attributeName;
514 methodName += ")";
534 methodName += ")";
515 profilingCB(PythonQt::Enter, wrapper->_obj->metaObject()->className(), methodName.toLatin1());
535 profilingCB(PythonQt::Enter, wrapper->_obj->metaObject()->className(), methodName.toLatin1());
516 }
536 }
517
537
518 success = prop.write(wrapper->_obj, v);
538 success = prop.write(wrapper->_obj, v);
519
539
520 if (profilingCB) {
540 if (profilingCB) {
521 profilingCB(PythonQt::Leave, NULL, NULL);
541 profilingCB(PythonQt::Leave, NULL, NULL);
522 }
542 }
523 }
543 }
524 if (success) {
544 if (success) {
525 return 0;
545 return 0;
526 } else {
546 } else {
527 error = QString("Property '") + attributeName + "' of type '" +
547 error = QString("Property '") + attributeName + "' of type '" +
528 prop.typeName() + "' does not accept an object of type "
548 prop.typeName() + "' does not accept an object of type "
529 + QString(value->ob_type->tp_name) + " (" + PythonQtConv::PyObjGetRepresentation(value) + ")";
549 + QString(value->ob_type->tp_name) + " (" + PythonQtConv::PyObjGetRepresentation(value) + ")";
530 }
550 }
531 } else {
551 } else {
532 error = QString("Property '") + attributeName + "' of " + obj->ob_type->tp_name + " object is not writable";
552 error = QString("Property '") + attributeName + "' of " + obj->ob_type->tp_name + " object is not writable";
533 }
553 }
534 } else if (member._type == PythonQtMemberInfo::Slot) {
554 } else if (member._type == PythonQtMemberInfo::Slot) {
535 error = QString("Slot '") + attributeName + "' can not be overwritten on " + obj->ob_type->tp_name + " object";
555 error = QString("Slot '") + attributeName + "' can not be overwritten on " + obj->ob_type->tp_name + " object";
536 } else if (member._type == PythonQtMemberInfo::Signal) {
556 } else if (member._type == PythonQtMemberInfo::Signal) {
537 error = QString("Signal '") + attributeName + "' can not be overwritten on " + obj->ob_type->tp_name + " object";
557 error = QString("Signal '") + attributeName + "' can not be overwritten on " + obj->ob_type->tp_name + " object";
538 } else if (member._type == PythonQtMemberInfo::EnumValue) {
558 } else if (member._type == PythonQtMemberInfo::EnumValue) {
539 error = QString("EnumValue '") + attributeName + "' can not be overwritten on " + obj->ob_type->tp_name + " object";
559 error = QString("EnumValue '") + attributeName + "' can not be overwritten on " + obj->ob_type->tp_name + " object";
540 } else if (member._type == PythonQtMemberInfo::EnumWrapper) {
560 } else if (member._type == PythonQtMemberInfo::EnumWrapper) {
541 error = QString("Enum '") + attributeName + "' can not be overwritten on " + obj->ob_type->tp_name + " object";
561 error = QString("Enum '") + attributeName + "' can not be overwritten on " + obj->ob_type->tp_name + " object";
542 } else if (member._type == PythonQtMemberInfo::NotFound) {
562 } else if (member._type == PythonQtMemberInfo::NotFound) {
543 // check for a setter slot
563 // check for a setter slot
544 static const QByteArray setterString("py_set_");
564 static const QByteArray setterString("py_set_");
545 PythonQtMemberInfo setter = wrapper->classInfo()->member(setterString + attributeName);
565 PythonQtMemberInfo setter = wrapper->classInfo()->member(setterString + attributeName);
546 if (setter._type == PythonQtMemberInfo::Slot) {
566 if (setter._type == PythonQtMemberInfo::Slot) {
547 // call the setter and ignore the result value
567 // call the setter and ignore the result value
548 void* result;
568 void* result;
549 PyObject* args = PyTuple_New(1);
569 PyObject* args = PyTuple_New(1);
550 Py_INCREF(value);
570 Py_INCREF(value);
551 PyTuple_SET_ITEM(args, 0, value);
571 PyTuple_SET_ITEM(args, 0, value);
552 PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, setter._slot, args, NULL, wrapper->_wrappedPtr, &result);
572 PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, setter._slot, args, NULL, wrapper->_wrappedPtr, &result);
553 Py_DECREF(args);
573 Py_DECREF(args);
554 return 0;
574 return 0;
555 }
575 }
556
576
557 // handle dynamic properties
577 // handle dynamic properties
558 if (wrapper->_obj) {
578 if (wrapper->_obj) {
559 QVariant prop = wrapper->_obj->property(attributeName);
579 QVariant prop = wrapper->_obj->property(attributeName);
560 if (prop.isValid()) {
580 if (prop.isValid()) {
561 QVariant v = PythonQtConv::PyObjToQVariant(value);
581 QVariant v = PythonQtConv::PyObjToQVariant(value);
562 if (v.isValid()) {
582 if (v.isValid()) {
563 wrapper->_obj->setProperty(attributeName, v);
583 wrapper->_obj->setProperty(attributeName, v);
564 return 0;
584 return 0;
565 } else {
585 } else {
566 error = QString("Dynamic property '") + attributeName + "' does not accept an object of type "
586 error = QString("Dynamic property '") + attributeName + "' does not accept an object of type "
567 + QString(value->ob_type->tp_name) + " (" + PythonQtConv::PyObjGetRepresentation(value) + ")";
587 + QString(value->ob_type->tp_name) + " (" + PythonQtConv::PyObjGetRepresentation(value) + ")";
568 PyErr_SetString(PyExc_AttributeError, error.toLatin1().data());
588 PyErr_SetString(PyExc_AttributeError, error.toLatin1().data());
569 return -1;
589 return -1;
570 }
590 }
571 }
591 }
572 }
592 }
573
593
574 // if we are a derived python class, we allow setting attributes.
594 // if we are a derived python class, we allow setting attributes.
575 // if we are a direct CPP wrapper, we do NOT allow it, since
595 // if we are a direct CPP wrapper, we do NOT allow it, since
576 // it would be confusing to allow it because a wrapper will go away when it is not seen by python anymore
596 // it would be confusing to allow it because a wrapper will go away when it is not seen by python anymore
577 // and when it is recreated from a CPP pointer the attributes are gone...
597 // and when it is recreated from a CPP pointer the attributes are gone...
578 if (obj->ob_type->tp_base != &PythonQtInstanceWrapper_Type) {
598 if (obj->ob_type->tp_base != &PythonQtInstanceWrapper_Type) {
579 return PyBaseObject_Type.tp_setattro(obj,name,value);
599 return PyBaseObject_Type.tp_setattro(obj,name,value);
580 } else {
600 } else {
581 error = QString("'") + attributeName + "' does not exist on " + obj->ob_type->tp_name + " and creating new attributes on C++ objects is not allowed";
601 error = QString("'") + attributeName + "' does not exist on " + obj->ob_type->tp_name + " and creating new attributes on C++ objects is not allowed";
582 }
602 }
583 }
603 }
584
604
585 PyErr_SetString(PyExc_AttributeError, error.toLatin1().data());
605 PyErr_SetString(PyExc_AttributeError, error.toLatin1().data());
586 return -1;
606 return -1;
587 }
607 }
588
608
589 static QString getStringFromObject(PythonQtInstanceWrapper* wrapper) {
609 static QString getStringFromObject(PythonQtInstanceWrapper* wrapper) {
590 QString result;
610 QString result;
591 if (wrapper->_wrappedPtr) {
611 if (wrapper->_wrappedPtr) {
592 // first try some manually string conversions for some variants
612 // first try some manually string conversions for some variants
593 int metaid = wrapper->classInfo()->metaTypeId();
613 int metaid = wrapper->classInfo()->metaTypeId();
594 result = PythonQtConv::CPPObjectToString(metaid, wrapper->_wrappedPtr);
614 result = PythonQtConv::CPPObjectToString(metaid, wrapper->_wrappedPtr);
595 if (!result.isEmpty()) {
615 if (!result.isEmpty()) {
596 return result;
616 return result;
597 }
617 }
598 }
618 }
599 if (wrapper->_wrappedPtr || wrapper->_obj) {
619 if (wrapper->_wrappedPtr || wrapper->_obj) {
600 // next, try to call py_toString
620 // next, try to call py_toString
601 PythonQtMemberInfo info = wrapper->classInfo()->member("py_toString");
621 PythonQtMemberInfo info = wrapper->classInfo()->member("py_toString");
602 if (info._type == PythonQtMemberInfo::Slot) {
622 if (info._type == PythonQtMemberInfo::Slot) {
603 PyObject* resultObj = PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, info._slot, NULL, NULL, wrapper->_wrappedPtr);
623 PyObject* resultObj = PythonQtSlotFunction_CallImpl(wrapper->classInfo(), wrapper->_obj, info._slot, NULL, NULL, wrapper->_wrappedPtr);
604 if (resultObj) {
624 if (resultObj) {
605 // TODO this is one conversion too much, would be nicer to call the slot directly...
625 // TODO this is one conversion too much, would be nicer to call the slot directly...
606 result = PythonQtConv::PyObjGetString(resultObj);
626 result = PythonQtConv::PyObjGetString(resultObj);
607 Py_DECREF(resultObj);
627 Py_DECREF(resultObj);
608 }
628 }
609 }
629 }
610 }
630 }
611 return result;
631 return result;
612 }
632 }
613
633
614 static PyObject * PythonQtInstanceWrapper_str(PyObject * obj)
634 static PyObject * PythonQtInstanceWrapper_str(PyObject * obj)
615 {
635 {
616 PythonQtInstanceWrapper* wrapper = (PythonQtInstanceWrapper*)obj;
636 PythonQtInstanceWrapper* wrapper = (PythonQtInstanceWrapper*)obj;
617
637
618 // QByteArray should be directly returned as a str
638 // QByteArray should be directly returned as a str
619 if (wrapper->classInfo()->metaTypeId()==QVariant::ByteArray) {
639 if (wrapper->classInfo()->metaTypeId()==QVariant::ByteArray) {
620 QByteArray* b = (QByteArray*) wrapper->_wrappedPtr;
640 QByteArray* b = (QByteArray*) wrapper->_wrappedPtr;
621 if (b->data()) {
641 if (b->data()) {
642 #ifdef PY3K
643 return PyUnicode_FromStringAndSize(b->data(), b->size());
644 #else
622 return PyString_FromStringAndSize(b->data(), b->size());
645 return PyString_FromStringAndSize(b->data(), b->size());
646 #endif
623 } else {
647 } else {
648 #ifdef PY3K
649 return PyUnicode_New(0, 0);
650 #else
624 return PyString_FromString("");
651 return PyString_FromString("");
652 #endif
625 }
653 }
626 }
654 }
627
655
628 const char* typeName = obj->ob_type->tp_name;
656 const char* typeName = obj->ob_type->tp_name;
629 QObject *qobj = wrapper->_obj;
657 QObject *qobj = wrapper->_obj;
630 QString str = getStringFromObject(wrapper);
658 QString str = getStringFromObject(wrapper);
631 if (!str.isEmpty()) {
659 if (!str.isEmpty()) {
660 #ifdef PY3K
661 return PyUnicode_FromFormat("%s", str.toLatin1().constData());
662 #else
632 return PyString_FromFormat("%s", str.toLatin1().constData());
663 return PyString_FromFormat("%s", str.toLatin1().constData());
664 #endif
633 }
665 }
634 if (wrapper->_wrappedPtr) {
666 if (wrapper->_wrappedPtr) {
635 if (wrapper->_obj) {
667 if (wrapper->_obj) {
636 return PyString_FromFormat("%s (C++ Object %p wrapped by %s %p))", typeName, wrapper->_wrappedPtr, wrapper->_obj->metaObject()->className(), qobj);
668 #ifdef PY3K
669 return PyUnicode_FromFormat("%s (C++ Object %p wrapped by %s %p)", typeName, wrapper->_wrappedPtr, wrapper->_obj->metaObject()->className(), qobj);
670 #else
671 return PyString_FromFormat("%s (C++ Object %p wrapped by %s %p)", typeName, wrapper->_wrappedPtr, wrapper->_obj->metaObject()->className(), qobj);
672 #endif
637 } else {
673 } else {
674 #ifdef PY3K
675 return PyUnicode_FromFormat("%s (C++ Object %p)", typeName, wrapper->_wrappedPtr);
676 #else
638 return PyString_FromFormat("%s (C++ Object %p)", typeName, wrapper->_wrappedPtr);
677 return PyString_FromFormat("%s (C++ Object %p)", typeName, wrapper->_wrappedPtr);
678 #endif
639 }
679 }
640 } else {
680 } else {
681 #ifdef PY3K
682 return PyUnicode_FromFormat("%s (QObject %p)", typeName, qobj);
683 #else
641 return PyString_FromFormat("%s (QObject %p)", typeName, qobj);
684 return PyString_FromFormat("%s (QObject %p)", typeName, qobj);
685 #endif
642 }
686 }
643 }
687 }
644
688
645 static PyObject * PythonQtInstanceWrapper_repr(PyObject * obj)
689 static PyObject * PythonQtInstanceWrapper_repr(PyObject * obj)
646 {
690 {
647 PythonQtInstanceWrapper* wrapper = (PythonQtInstanceWrapper*)obj;
691 PythonQtInstanceWrapper* wrapper = (PythonQtInstanceWrapper*)obj;
648 const char* typeName = obj->ob_type->tp_name;
692 const char* typeName = obj->ob_type->tp_name;
649
693
650 QObject *qobj = wrapper->_obj;
694 QObject *qobj = wrapper->_obj;
651 QString str = getStringFromObject(wrapper);
695 QString str = getStringFromObject(wrapper);
652 if (!str.isEmpty()) {
696 if (!str.isEmpty()) {
653 if (str.startsWith(typeName)) {
697 if (str.startsWith(typeName)) {
698 #ifdef PY3K
699 return PyUnicode_FromFormat("%s", str.toLatin1().constData());
700 #else
654 return PyString_FromFormat("%s", str.toLatin1().constData());
701 return PyString_FromFormat("%s", str.toLatin1().constData());
702 #endif
655 } else {
703 } else {
704 #ifdef PY3K
705 return PyUnicode_FromFormat("%s (%s, at: %p)", typeName, str.toLatin1().constData(), wrapper->_wrappedPtr ? wrapper->_wrappedPtr : qobj);
706 #else
656 return PyString_FromFormat("%s (%s, at: %p)", typeName, str.toLatin1().constData(), wrapper->_wrappedPtr ? wrapper->_wrappedPtr : qobj);
707 return PyString_FromFormat("%s (%s, at: %p)", typeName, str.toLatin1().constData(), wrapper->_wrappedPtr ? wrapper->_wrappedPtr : qobj);
708 #endif
657 }
709 }
658 }
710 }
659 if (wrapper->_wrappedPtr) {
711 if (wrapper->_wrappedPtr) {
660 if (wrapper->_obj) {
712 if (wrapper->_obj) {
713 #ifdef PY3K
714 return PyUnicode_FromFormat("%s (C++ object at: %p wrapped by %s at: %p)", typeName, wrapper->_wrappedPtr, wrapper->_obj->metaObject()->className(), qobj);
715 #else
661 return PyString_FromFormat("%s (C++ object at: %p wrapped by %s at: %p)", typeName, wrapper->_wrappedPtr, wrapper->_obj->metaObject()->className(), qobj);
716 return PyString_FromFormat("%s (C++ object at: %p wrapped by %s at: %p)", typeName, wrapper->_wrappedPtr, wrapper->_obj->metaObject()->className(), qobj);
717 #endif
662 } else {
718 } else {
719 #ifdef PY3K
720 return PyUnicode_FromFormat("%s (C++ object at: %p)", typeName, wrapper->_wrappedPtr);
721 #else
663 return PyString_FromFormat("%s (C++ object at: %p)", typeName, wrapper->_wrappedPtr);
722 return PyString_FromFormat("%s (C++ object at: %p)", typeName, wrapper->_wrappedPtr);
723 #endif
664 }
724 }
665 } else {
725 } else {
726 #ifdef PY3K
727 return PyUnicode_FromFormat("%s (%s at: %p)", typeName, wrapper->classInfo()->className(), qobj);
728 #else
666 return PyString_FromFormat("%s (%s at: %p)", typeName, wrapper->classInfo()->className(), qobj);
729 return PyString_FromFormat("%s (%s at: %p)", typeName, wrapper->classInfo()->className(), qobj);
730 #endif
667 }
731 }
668 }
732 }
669
733
670 static int PythonQtInstanceWrapper_builtin_nonzero(PyObject *obj)
734 static int PythonQtInstanceWrapper_builtin_nonzero(PyObject *obj)
671 {
735 {
672 PythonQtInstanceWrapper* wrapper = (PythonQtInstanceWrapper*)obj;
736 PythonQtInstanceWrapper* wrapper = (PythonQtInstanceWrapper*)obj;
673 return (wrapper->_wrappedPtr == NULL && wrapper->_obj == NULL)?0:1;
737 return (wrapper->_wrappedPtr == NULL && wrapper->_obj == NULL)?0:1;
674 }
738 }
675
739
676
740
677 static long PythonQtInstanceWrapper_hash(PythonQtInstanceWrapper *obj)
741 static long PythonQtInstanceWrapper_hash(PythonQtInstanceWrapper *obj)
678 {
742 {
679 if (obj->_wrappedPtr != NULL) {
743 if (obj->_wrappedPtr != NULL) {
680 return reinterpret_cast<long>(obj->_wrappedPtr);
744 return reinterpret_cast<long>(obj->_wrappedPtr);
681 } else {
745 } else {
682 QObject* qobj = obj->_obj; // get pointer from QPointer wrapper
746 QObject* qobj = obj->_obj; // get pointer from QPointer wrapper
683 return reinterpret_cast<long>(qobj);
747 return reinterpret_cast<long>(qobj);
684 }
748 }
685 }
749 }
686
750
687
751
688
752
689 // we override nb_nonzero, so that one can do 'if' expressions to test for a NULL ptr
753 // we override nb_nonzero, so that one can do 'if' expressions to test for a NULL ptr
690 static PyNumberMethods PythonQtInstanceWrapper_as_number = {
754 static PyNumberMethods PythonQtInstanceWrapper_as_number = {
691 0, /* nb_add */
755 0, /* nb_add */
692 0, /* nb_subtract */
756 0, /* nb_subtract */
693 0, /* nb_multiply */
757 0, /* nb_multiply */
758 #ifndef PY3K
694 0, /* nb_divide */
759 0, /* nb_divide */
760 #endif
695 0, /* nb_remainder */
761 0, /* nb_remainder */
696 0, /* nb_divmod */
762 0, /* nb_divmod */
697 0, /* nb_power */
763 0, /* nb_power */
698 0, /* nb_negative */
764 0, /* nb_negative */
699 0, /* nb_positive */
765 0, /* nb_positive */
700 0, /* nb_absolute */
766 0, /* nb_absolute */
701 PythonQtInstanceWrapper_builtin_nonzero, /* nb_nonzero */
767 PythonQtInstanceWrapper_builtin_nonzero, /* nb_nonzero / nb_bool in Py3K */
702 0, /* nb_invert */
768 0, /* nb_invert */
703 0, /* nb_lshift */
769 0, /* nb_lshift */
704 0, /* nb_rshift */
770 0, /* nb_rshift */
705 0, /* nb_and */
771 0, /* nb_and */
706 0, /* nb_xor */
772 0, /* nb_xor */
707 0, /* nb_or */
773 0, /* nb_or */
774 #ifndef PY3K
708 0, /* nb_coerce */
775 0, /* nb_coerce */
776 #endif
709 0, /* nb_int */
777 0, /* nb_int */
710 0, /* nb_long */
778 0, /* nb_long / nb_reserved in Py3K */
711 0, /* nb_float */
779 0, /* nb_float */
780 #ifndef PY3K
712 0, /* nb_oct */
781 0, /* nb_oct */
713 0, /* nb_hex */
782 0, /* nb_hex */
783 #endif
714 0, /* nb_inplace_add */
784 0, /* nb_inplace_add */
715 0, /* nb_inplace_subtract */
785 0, /* nb_inplace_subtract */
716 0, /* nb_inplace_multiply */
786 0, /* nb_inplace_multiply */
787 #ifndef PY3K
717 0, /* nb_inplace_divide */
788 0, /* nb_inplace_divide */
789 #endif
718 0, /* nb_inplace_remainder */
790 0, /* nb_inplace_remainder */
719 0, /* nb_inplace_power */
791 0, /* nb_inplace_power */
720 0, /* nb_inplace_lshift */
792 0, /* nb_inplace_lshift */
721 0, /* nb_inplace_rshift */
793 0, /* nb_inplace_rshift */
722 0, /* nb_inplace_and */
794 0, /* nb_inplace_and */
723 0, /* nb_inplace_xor */
795 0, /* nb_inplace_xor */
724 0, /* nb_inplace_or */
796 0, /* nb_inplace_or */
725 0, /* nb_floor_divide */
797 0, /* nb_floor_divide */
726 0, /* nb_true_divide */
798 0, /* nb_true_divide */
727 0, /* nb_inplace_floor_divide */
799 0, /* nb_inplace_floor_divide */
728 0, /* nb_inplace_true_divide */
800 0, /* nb_inplace_true_divide */
801 #ifdef PY3K
802 0, /* nb_index in Py3K */
803 #endif
729 };
804 };
730
805
731 PyTypeObject PythonQtInstanceWrapper_Type = {
806 PyTypeObject PythonQtInstanceWrapper_Type = {
732 PyObject_HEAD_INIT(&PythonQtClassWrapper_Type)
807 PyVarObject_HEAD_INIT(&PythonQtClassWrapper_Type, 0)
733 0, /*ob_size*/
734 "PythonQt.PythonQtInstanceWrapper", /*tp_name*/
808 "PythonQt.PythonQtInstanceWrapper", /*tp_name*/
735 sizeof(PythonQtInstanceWrapper), /*tp_basicsize*/
809 sizeof(PythonQtInstanceWrapper), /*tp_basicsize*/
736 0, /*tp_itemsize*/
810 0, /*tp_itemsize*/
737 (destructor)PythonQtInstanceWrapper_dealloc, /*tp_dealloc*/
811 (destructor)PythonQtInstanceWrapper_dealloc, /*tp_dealloc*/
738 0, /*tp_print*/
812 0, /*tp_print*/
739 0, /*tp_getattr*/
813 0, /*tp_getattr*/
740 0, /*tp_setattr*/
814 0, /*tp_setattr*/
741 0, /*tp_compare*/
815 0, /*tp_compare*/
742 PythonQtInstanceWrapper_repr, /*tp_repr*/
816 PythonQtInstanceWrapper_repr, /*tp_repr*/
743 &PythonQtInstanceWrapper_as_number, /*tp_as_number*/
817 &PythonQtInstanceWrapper_as_number, /*tp_as_number*/
744 0, /*tp_as_sequence*/
818 0, /*tp_as_sequence*/
745 0, /*tp_as_mapping*/
819 0, /*tp_as_mapping*/
746 (hashfunc)PythonQtInstanceWrapper_hash, /*tp_hash */
820 (hashfunc)PythonQtInstanceWrapper_hash, /*tp_hash */
747 0, /*tp_call*/
821 0, /*tp_call*/
748 PythonQtInstanceWrapper_str, /*tp_str*/
822 PythonQtInstanceWrapper_str, /*tp_str*/
749 PythonQtInstanceWrapper_getattro, /*tp_getattro*/
823 PythonQtInstanceWrapper_getattro, /*tp_getattro*/
750 PythonQtInstanceWrapper_setattro, /*tp_setattro*/
824 PythonQtInstanceWrapper_setattro, /*tp_setattro*/
751 0, /*tp_as_buffer*/
825 0, /*tp_as_buffer*/
752 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE | Py_TPFLAGS_CHECKTYPES, /*tp_flags*/
826 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE /*| Py_TPFLAGS_CHECKTYPES FIXME Py_TPFLAGS_CHECKTYPES removal */, /*tp_flags*/
753 "PythonQtInstanceWrapper object", /* tp_doc */
827 "PythonQtInstanceWrapper object", /* tp_doc */
754 0, /* tp_traverse */
828 0, /* tp_traverse */
755 0, /* tp_clear */
829 0, /* tp_clear */
756 (richcmpfunc)PythonQtInstanceWrapper_richcompare, /* tp_richcompare */
830 (richcmpfunc)PythonQtInstanceWrapper_richcompare, /* tp_richcompare */
757 0, /* tp_weaklistoffset */
831 0, /* tp_weaklistoffset */
758 0, /* tp_iter */
832 0, /* tp_iter */
759 0, /* tp_iternext */
833 0, /* tp_iternext */
760 0, /* tp_methods */
834 0, /* tp_methods */
761 0, /* tp_members */
835 0, /* tp_members */
762 0, /* tp_getset */
836 0, /* tp_getset */
763 0, /* tp_base */
837 0, /* tp_base */
764 0, /* tp_dict */
838 0, /* tp_dict */
765 0, /* tp_descr_get */
839 0, /* tp_descr_get */
766 0, /* tp_descr_set */
840 0, /* tp_descr_set */
767 0, /* tp_dictoffset */
841 0, /* tp_dictoffset */
768 (initproc)PythonQtInstanceWrapper_init, /* tp_init */
842 (initproc)PythonQtInstanceWrapper_init, /* tp_init */
769 0, /* tp_alloc */
843 0, /* tp_alloc */
770 PythonQtInstanceWrapper_new, /* tp_new */
844 PythonQtInstanceWrapper_new, /* tp_new */
771 };
845 };
772
846
773 //-------------------------------------------------------
847 //-------------------------------------------------------
774
848
@@ -1,56 +1,72
1 /*
1 /*
2 *
2 *
3 * Copyright (C) 2011 MeVis Medical Solutions AG All Rights Reserved.
3 * Copyright (C) 2011 MeVis Medical Solutions AG All Rights Reserved.
4 *
4 *
5 * This library is free software; you can redistribute it and/or
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
8 * version 2.1 of the License, or (at your option) any later version.
9 *
9 *
10 * This library is distributed in the hope that it will be useful,
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
13 * Lesser General Public License for more details.
14 *
14 *
15 * Further, this software is distributed without any warranty that it is
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
20 * other software, or any other product whatsoever.
21 *
21 *
22 * You should have received a copy of the GNU Lesser General Public
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
25 *
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
27 * 28359 Bremen, Germany or:
27 * 28359 Bremen, Germany or:
28 *
28 *
29 * http://www.mevis.de
29 * http://www.mevis.de
30 *
30 *
31 */
31 */
32
32
33 #ifndef __PythonQtPythonInclude_h
33 #ifndef __PythonQtPythonInclude_h
34 #define __PythonQtPythonInclude_h
34 #define __PythonQtPythonInclude_h
35
35
36 // Undefine macros that Python.h defines to avoid redefinition warning.
36 // Undefine macros that Python.h defines to avoid redefinition warning.
37 #undef _POSIX_C_SOURCE
37 #undef _POSIX_C_SOURCE
38 #undef _POSIX_THREADS
38 #undef _POSIX_THREADS
39 #undef _XOPEN_SOURCE
39 #undef _XOPEN_SOURCE
40
40
41 // Undefine Qt keywords that conflict with Python headers
42 #ifdef slots
43 #undef slots
44 #define PYTHONQT_RESTORE_KEYWORDS
45 #endif
46
41 // If PYTHONQT_USE_RELEASE_PYTHON_FALLBACK is enabled, try to link
47 // If PYTHONQT_USE_RELEASE_PYTHON_FALLBACK is enabled, try to link
42 // release Python DLL if it is available by undefining _DEBUG while
48 // release Python DLL if it is available by undefining _DEBUG while
43 // including Python.h
49 // including Python.h
44 #if defined(PYTHONQT_USE_RELEASE_PYTHON_FALLBACK) && defined(_DEBUG)
50 #if defined(PYTHONQT_USE_RELEASE_PYTHON_FALLBACK) && defined(_DEBUG)
45 #undef _DEBUG
51 #undef _DEBUG
46 #if defined(_MSC_VER) && _MSC_VER >= 1400
52 #if defined(_MSC_VER) && _MSC_VER >= 1400
47 #define _CRT_NOFORCE_MANIFEST 1
53 #define _CRT_NOFORCE_MANIFEST 1
48 #define _STL_NOFORCE_MANIFEST 1
54 #define _STL_NOFORCE_MANIFEST 1
49 #endif
55 #endif
50 #include <Python.h>
56 #include <Python.h>
51 #define _DEBUG
57 #define _DEBUG
52 #else
58 #else
53 #include <Python.h>
59 #include <Python.h>
54 #endif
60 #endif
55
61
62 // get Qt keywords back
63 #ifdef PYTHONQT_RESTORE_KEYWORDS
64 #define slots Q_SLOTS
65 #undef PYTHONQT_RESTORE_KEYWORDS
66 #endif
67
68 #if PY_MAJOR_VERSION >= 3
69 #define PY3K
70 #endif
71
56 #endif
72 #endif
@@ -1,366 +1,410
1 /*
1 /*
2 *
2 *
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
4 *
4 *
5 * This library is free software; you can redistribute it and/or
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
8 * version 2.1 of the License, or (at your option) any later version.
9 *
9 *
10 * This library is distributed in the hope that it will be useful,
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
13 * Lesser General Public License for more details.
14 *
14 *
15 * Further, this software is distributed without any warranty that it is
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
20 * other software, or any other product whatsoever.
21 *
21 *
22 * You should have received a copy of the GNU Lesser General Public
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
25 *
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
27 * 28359 Bremen, Germany or:
27 * 28359 Bremen, Germany or:
28 *
28 *
29 * http://www.mevis.de
29 * http://www.mevis.de
30 *
30 *
31 */
31 */
32
32
33 //----------------------------------------------------------------------------------
33 //----------------------------------------------------------------------------------
34 /*!
34 /*!
35 // \file PythonQtSignal.cpp
35 // \file PythonQtSignal.cpp
36 // \author Florian Link
36 // \author Florian Link
37 // \author Last changed by $Author: florian $
37 // \author Last changed by $Author: florian $
38 // \date 2012-02
38 // \date 2012-02
39 */
39 */
40 //----------------------------------------------------------------------------------
40 //----------------------------------------------------------------------------------
41
41
42 #include "PythonQt.h"
42 #include "PythonQt.h"
43 #include "PythonQtSignal.h"
43 #include "PythonQtSignal.h"
44 #include "PythonQtInstanceWrapper.h"
44 #include "PythonQtInstanceWrapper.h"
45 #include "PythonQtClassInfo.h"
45 #include "PythonQtClassInfo.h"
46 #include "PythonQtMisc.h"
46 #include "PythonQtMisc.h"
47 #include "PythonQtConversion.h"
47 #include "PythonQtConversion.h"
48 #include "PythonQtSlot.h"
48 #include "PythonQtSlot.h"
49
49
50 #include <iostream>
50 #include <iostream>
51
51
52 #include <exception>
52 #include <exception>
53 #include <stdexcept>
53 #include <stdexcept>
54
54
55 #include <QByteArray>
55 #include <QByteArray>
56
56
57 //-----------------------------------------------------------------------------------
57 //-----------------------------------------------------------------------------------
58
58
59 static PythonQtSignalFunctionObject *PythonQtSignal_free_list = NULL;
59 static PythonQtSignalFunctionObject *PythonQtSignal_free_list = NULL;
60
60
61 PyObject *PythonQtSignalFunction_Call(PyObject *func, PyObject *args, PyObject *kw)
61 PyObject *PythonQtSignalFunction_Call(PyObject *func, PyObject *args, PyObject *kw)
62 {
62 {
63 PythonQtSignalFunctionObject* f = (PythonQtSignalFunctionObject*)func;
63 PythonQtSignalFunctionObject* f = (PythonQtSignalFunctionObject*)func;
64 return PythonQtMemberFunction_Call(f->m_ml, f->m_self, args, kw);
64 return PythonQtMemberFunction_Call(f->m_ml, f->m_self, args, kw);
65 }
65 }
66
66
67 PyObject *
67 PyObject *
68 PythonQtSignalFunction_New(PythonQtSlotInfo *ml, PyObject *self, PyObject *module)
68 PythonQtSignalFunction_New(PythonQtSlotInfo *ml, PyObject *self, PyObject *module)
69 {
69 {
70 PythonQtSignalFunctionObject *op;
70 PythonQtSignalFunctionObject *op;
71 op = PythonQtSignal_free_list;
71 op = PythonQtSignal_free_list;
72 if (op != NULL) {
72 if (op != NULL) {
73 PythonQtSignal_free_list = (PythonQtSignalFunctionObject *)(op->m_self);
73 PythonQtSignal_free_list = (PythonQtSignalFunctionObject *)(op->m_self);
74 PyObject_INIT(op, &PythonQtSignalFunction_Type);
74 PyObject_INIT(op, &PythonQtSignalFunction_Type);
75 }
75 }
76 else {
76 else {
77 op = PyObject_GC_New(PythonQtSignalFunctionObject, &PythonQtSignalFunction_Type);
77 op = PyObject_GC_New(PythonQtSignalFunctionObject, &PythonQtSignalFunction_Type);
78 if (op == NULL)
78 if (op == NULL)
79 return NULL;
79 return NULL;
80 }
80 }
81 op->m_ml = ml;
81 op->m_ml = ml;
82 Py_XINCREF(self);
82 Py_XINCREF(self);
83 op->m_self = self;
83 op->m_self = self;
84 Py_XINCREF(module);
84 Py_XINCREF(module);
85 op->m_module = module;
85 op->m_module = module;
86 PyObject_GC_Track(op);
86 PyObject_GC_Track(op);
87 return (PyObject *)op;
87 return (PyObject *)op;
88 }
88 }
89
89
90 /* Methods (the standard built-in methods, that is) */
90 /* Methods (the standard built-in methods, that is) */
91
91
92 static void
92 static void
93 meth_dealloc(PythonQtSignalFunctionObject *m)
93 meth_dealloc(PythonQtSignalFunctionObject *m)
94 {
94 {
95 PyObject_GC_UnTrack(m);
95 PyObject_GC_UnTrack(m);
96 Py_XDECREF(m->m_self);
96 Py_XDECREF(m->m_self);
97 Py_XDECREF(m->m_module);
97 Py_XDECREF(m->m_module);
98 m->m_self = (PyObject *)PythonQtSignal_free_list;
98 m->m_self = (PyObject *)PythonQtSignal_free_list;
99 PythonQtSignal_free_list = m;
99 PythonQtSignal_free_list = m;
100 }
100 }
101
101
102 static PyObject *
102 static PyObject *
103 meth_get__doc__(PythonQtSignalFunctionObject * /*m*/, void * /*closure*/)
103 meth_get__doc__(PythonQtSignalFunctionObject * /*m*/, void * /*closure*/)
104 {
104 {
105 Py_INCREF(Py_None);
105 Py_INCREF(Py_None);
106 return Py_None;
106 return Py_None;
107 }
107 }
108
108
109 static PyObject *
109 static PyObject *
110 meth_get__name__(PythonQtSignalFunctionObject *m, void * /*closure*/)
110 meth_get__name__(PythonQtSignalFunctionObject *m, void * /*closure*/)
111 {
111 {
112 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
112 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
113 #ifdef PY3K
114 return PyUnicode_FromString(m->m_ml->metaMethod()->methodSignature());
115 #else
113 return PyString_FromString(m->m_ml->metaMethod()->methodSignature());
116 return PyString_FromString(m->m_ml->metaMethod()->methodSignature());
117 #endif
118 #else
119 #ifdef PY3K
120 return PyUnicode_FromString(m->m_ml->metaMethod()->signature());
114 #else
121 #else
115 return PyString_FromString(m->m_ml->metaMethod()->signature());
122 return PyString_FromString(m->m_ml->metaMethod()->signature());
116 #endif
123 #endif
124 #endif
117 }
125 }
118
126
119 static int
127 static int
120 meth_traverse(PythonQtSignalFunctionObject *m, visitproc visit, void *arg)
128 meth_traverse(PythonQtSignalFunctionObject *m, visitproc visit, void *arg)
121 {
129 {
122 int err;
130 int err;
123 if (m->m_self != NULL) {
131 if (m->m_self != NULL) {
124 err = visit(m->m_self, arg);
132 err = visit(m->m_self, arg);
125 if (err)
133 if (err)
126 return err;
134 return err;
127 }
135 }
128 if (m->m_module != NULL) {
136 if (m->m_module != NULL) {
129 err = visit(m->m_module, arg);
137 err = visit(m->m_module, arg);
130 if (err)
138 if (err)
131 return err;
139 return err;
132 }
140 }
133 return 0;
141 return 0;
134 }
142 }
135
143
136 static PyObject *
144 static PyObject *
137 meth_get__self__(PythonQtSignalFunctionObject *m, void * /*closure*/)
145 meth_get__self__(PythonQtSignalFunctionObject *m, void * /*closure*/)
138 {
146 {
139 PyObject *self;
147 PyObject *self;
148 #ifndef PY3K
140 if (PyEval_GetRestricted()) {
149 if (PyEval_GetRestricted()) {
141 PyErr_SetString(PyExc_RuntimeError,
150 PyErr_SetString(PyExc_RuntimeError,
142 "method.__self__ not accessible in restricted mode");
151 "method.__self__ not accessible in restricted mode");
143 return NULL;
152 return NULL;
144 }
153 }
154 #endif
145 self = m->m_self;
155 self = m->m_self;
146 if (self == NULL)
156 if (self == NULL)
147 self = Py_None;
157 self = Py_None;
148 Py_INCREF(self);
158 Py_INCREF(self);
149 return self;
159 return self;
150 }
160 }
151
161
152 static PyGetSetDef meth_getsets [] = {
162 static PyGetSetDef meth_getsets [] = {
153 {const_cast<char*>("__doc__"), (getter)meth_get__doc__, NULL, NULL},
163 {const_cast<char*>("__doc__"), (getter)meth_get__doc__, NULL, NULL},
154 {const_cast<char*>("__name__"), (getter)meth_get__name__, NULL, NULL},
164 {const_cast<char*>("__name__"), (getter)meth_get__name__, NULL, NULL},
155 {const_cast<char*>("__self__"), (getter)meth_get__self__, NULL, NULL},
165 {const_cast<char*>("__self__"), (getter)meth_get__self__, NULL, NULL},
156 {NULL, NULL, NULL,NULL},
166 {NULL, NULL, NULL,NULL},
157 };
167 };
158
168
159 #if PY_MAJOR_VERSION == 2 && PY_MINOR_VERSION < 6
169 #if PY_MAJOR_VERSION == 2 && PY_MINOR_VERSION < 6
160 #define PY_WRITE_RESTRICTED WRITE_RESTRICTED
170 #define PY_WRITE_RESTRICTED WRITE_RESTRICTED
161 #endif
171 #endif
162
172
163 #define OFF(x) offsetof(PythonQtSignalFunctionObject, x)
173 #define OFF(x) offsetof(PythonQtSignalFunctionObject, x)
164
174
165 static PyMemberDef meth_members[] = {
175 static PyMemberDef meth_members[] = {
166 {const_cast<char*>("__module__"), T_OBJECT, OFF(m_module), PY_WRITE_RESTRICTED},
176 {const_cast<char*>("__module__"), T_OBJECT, OFF(m_module), PY_WRITE_RESTRICTED},
167 {NULL}
177 {NULL}
168 };
178 };
169
179
170 static PyObject *PythonQtSignalFunction_parameterTypes(PythonQtSignalFunctionObject* type)
180 static PyObject *PythonQtSignalFunction_parameterTypes(PythonQtSignalFunctionObject* type)
171 {
181 {
172 return PythonQtMemberFunction_parameterTypes(type->m_ml);
182 return PythonQtMemberFunction_parameterTypes(type->m_ml);
173 }
183 }
174
184
175 static PyObject *PythonQtSignalFunction_parameterNames(PythonQtSignalFunctionObject* type)
185 static PyObject *PythonQtSignalFunction_parameterNames(PythonQtSignalFunctionObject* type)
176 {
186 {
177 return PythonQtMemberFunction_parameterNames(type->m_ml);
187 return PythonQtMemberFunction_parameterNames(type->m_ml);
178 }
188 }
179
189
180 static PyObject *PythonQtSignalFunction_typeName(PythonQtSignalFunctionObject* type)
190 static PyObject *PythonQtSignalFunction_typeName(PythonQtSignalFunctionObject* type)
181 {
191 {
182 return PythonQtMemberFunction_typeName(type->m_ml);
192 return PythonQtMemberFunction_typeName(type->m_ml);
183 }
193 }
184
194
185 static PyObject *PythonQtSignalFunction_connect(PythonQtSignalFunctionObject* type, PyObject *args)
195 static PyObject *PythonQtSignalFunction_connect(PythonQtSignalFunctionObject* type, PyObject *args)
186 {
196 {
187 if (PyObject_TypeCheck(type->m_self, &PythonQtInstanceWrapper_Type)) {
197 if (PyObject_TypeCheck(type->m_self, &PythonQtInstanceWrapper_Type)) {
188 PythonQtInstanceWrapper* self = (PythonQtInstanceWrapper*) type->m_self;
198 PythonQtInstanceWrapper* self = (PythonQtInstanceWrapper*) type->m_self;
189 if (self->_obj) {
199 if (self->_obj) {
190 Py_ssize_t argc = PyTuple_Size(args);
200 Py_ssize_t argc = PyTuple_Size(args);
191 if (argc==1) {
201 if (argc==1) {
192 // connect with Python callable
202 // connect with Python callable
193 PyObject* callable = PyTuple_GET_ITEM(args, 0);
203 PyObject* callable = PyTuple_GET_ITEM(args, 0);
194 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
204 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
195 bool result = PythonQt::self()->addSignalHandler(self->_obj, QByteArray("2") + type->m_ml->metaMethod()->methodSignature(), callable);
205 bool result = PythonQt::self()->addSignalHandler(self->_obj, QByteArray("2") + type->m_ml->metaMethod()->methodSignature(), callable);
196 #else
206 #else
197 bool result = PythonQt::self()->addSignalHandler(self->_obj, QByteArray("2") + type->m_ml->metaMethod()->signature(), callable);
207 bool result = PythonQt::self()->addSignalHandler(self->_obj, QByteArray("2") + type->m_ml->metaMethod()->signature(), callable);
198 #endif
208 #endif
199 return PythonQtConv::GetPyBool(result);
209 return PythonQtConv::GetPyBool(result);
200 } else {
210 } else {
201 PyErr_SetString(PyExc_ValueError, "Called connect with wrong number of arguments");
211 PyErr_SetString(PyExc_ValueError, "Called connect with wrong number of arguments");
202 }
212 }
203 }
213 }
204 }
214 }
205 return NULL;
215 return NULL;
206 }
216 }
207
217
208 static PyObject *PythonQtSignalFunction_disconnect(PythonQtSignalFunctionObject* type, PyObject *args)
218 static PyObject *PythonQtSignalFunction_disconnect(PythonQtSignalFunctionObject* type, PyObject *args)
209 {
219 {
210 if (PyObject_TypeCheck(type->m_self, &PythonQtInstanceWrapper_Type)) {
220 if (PyObject_TypeCheck(type->m_self, &PythonQtInstanceWrapper_Type)) {
211 PythonQtInstanceWrapper* self = (PythonQtInstanceWrapper*) type->m_self;
221 PythonQtInstanceWrapper* self = (PythonQtInstanceWrapper*) type->m_self;
212 if (self->_obj) {
222 if (self->_obj) {
213 Py_ssize_t argc = PyTuple_Size(args);
223 Py_ssize_t argc = PyTuple_Size(args);
214 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
224 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
215 QByteArray signal = QByteArray("2") + type->m_ml->metaMethod()->methodSignature();
225 QByteArray signal = QByteArray("2") + type->m_ml->metaMethod()->methodSignature();
216 #else
226 #else
217 QByteArray signal = QByteArray("2") + type->m_ml->metaMethod()->signature();
227 QByteArray signal = QByteArray("2") + type->m_ml->metaMethod()->signature();
218 #endif
228 #endif
219 if (argc==1) {
229 if (argc==1) {
220 // disconnect with Python callable
230 // disconnect with Python callable
221 PyObject* callable = PyTuple_GET_ITEM(args, 0);
231 PyObject* callable = PyTuple_GET_ITEM(args, 0);
222 bool result = PythonQt::self()->removeSignalHandler(self->_obj, signal, callable);
232 bool result = PythonQt::self()->removeSignalHandler(self->_obj, signal, callable);
223 return PythonQtConv::GetPyBool(result);
233 return PythonQtConv::GetPyBool(result);
224 } else if (argc==0) {
234 } else if (argc==0) {
225 bool result = PythonQt::self()->removeSignalHandler(self->_obj, signal, NULL);
235 bool result = PythonQt::self()->removeSignalHandler(self->_obj, signal, NULL);
226 result |= QObject::disconnect(self->_obj, signal, NULL, NULL);
236 result |= QObject::disconnect(self->_obj, signal, NULL, NULL);
227 return PythonQtConv::GetPyBool(result);
237 return PythonQtConv::GetPyBool(result);
228 } else {
238 } else {
229 PyErr_SetString(PyExc_ValueError, "Called disconnect with wrong number of arguments");
239 PyErr_SetString(PyExc_ValueError, "Called disconnect with wrong number of arguments");
230 }
240 }
231 }
241 }
232 }
242 }
233 return NULL;
243 return NULL;
234 }
244 }
235
245
236 static PyObject *PythonQtSignalFunction_emit(PythonQtSignalFunctionObject* func, PyObject *args)
246 static PyObject *PythonQtSignalFunction_emit(PythonQtSignalFunctionObject* func, PyObject *args)
237 {
247 {
238 PythonQtSignalFunctionObject* f = (PythonQtSignalFunctionObject*)func;
248 PythonQtSignalFunctionObject* f = (PythonQtSignalFunctionObject*)func;
239 return PythonQtMemberFunction_Call(f->m_ml, f->m_self, args, NULL);
249 return PythonQtMemberFunction_Call(f->m_ml, f->m_self, args, NULL);
240 }
250 }
241
251
242 static PyMethodDef meth_methods[] = {
252 static PyMethodDef meth_methods[] = {
243 {"parameterTypes", (PyCFunction)PythonQtSignalFunction_parameterTypes, METH_NOARGS,
253 {"parameterTypes", (PyCFunction)PythonQtSignalFunction_parameterTypes, METH_NOARGS,
244 "Returns a tuple of tuples of the C++ parameter types for all overloads of the signal"
254 "Returns a tuple of tuples of the C++ parameter types for all overloads of the signal"
245 },
255 },
246 {"parameterNames", (PyCFunction)PythonQtSignalFunction_parameterNames, METH_NOARGS,
256 {"parameterNames", (PyCFunction)PythonQtSignalFunction_parameterNames, METH_NOARGS,
247 "Returns a tuple of tuples of the C++ parameter type names (if available), for all overloads of the signal"
257 "Returns a tuple of tuples of the C++ parameter type names (if available), for all overloads of the signal"
248 },
258 },
249 {"typeName", (PyCFunction)PythonQtSignalFunction_typeName, METH_NOARGS,
259 {"typeName", (PyCFunction)PythonQtSignalFunction_typeName, METH_NOARGS,
250 "Returns a tuple of the C++ return value types of each signal overload"
260 "Returns a tuple of the C++ return value types of each signal overload"
251 },
261 },
252 {"connect", (PyCFunction)PythonQtSignalFunction_connect, METH_VARARGS,
262 {"connect", (PyCFunction)PythonQtSignalFunction_connect, METH_VARARGS,
253 "Connects the signal to the Python callable"
263 "Connects the signal to the Python callable"
254 },
264 },
255 {"disconnect", (PyCFunction)PythonQtSignalFunction_disconnect, METH_VARARGS,
265 {"disconnect", (PyCFunction)PythonQtSignalFunction_disconnect, METH_VARARGS,
256 "Disconnects the signal from the given Python callable or disconnects all if no argument is passed."
266 "Disconnects the signal from the given Python callable or disconnects all if no argument is passed."
257 },
267 },
258 {"emit", (PyCFunction)PythonQtSignalFunction_emit, METH_VARARGS,
268 {"emit", (PyCFunction)PythonQtSignalFunction_emit, METH_VARARGS,
259 "Emits the signal with given arguments"
269 "Emits the signal with given arguments"
260 },
270 },
261 {NULL, NULL, 0 , NULL} /* Sentinel */
271 {NULL, NULL, 0 , NULL} /* Sentinel */
262 };
272 };
263
273
264 static PyObject *
274 static PyObject *
265 meth_repr(PythonQtSignalFunctionObject *f)
275 meth_repr(PythonQtSignalFunctionObject *f)
266 {
276 {
267 if (f->m_self->ob_type == &PythonQtClassWrapper_Type) {
277 if (f->m_self->ob_type == &PythonQtClassWrapper_Type) {
268 PythonQtClassWrapper* self = (PythonQtClassWrapper*) f->m_self;
278 PythonQtClassWrapper* self = (PythonQtClassWrapper*) f->m_self;
279 #ifdef PY3K
280 return PyUnicode_FromFormat("<unbound qt signal %s of %s type>",
281 #else
269 return PyString_FromFormat("<unbound qt signal %s of %s type>",
282 return PyString_FromFormat("<unbound qt signal %s of %s type>",
283 #endif
270 f->m_ml->slotName().data(),
284 f->m_ml->slotName().data(),
271 self->classInfo()->className());
285 self->classInfo()->className());
272 } else {
286 } else {
287 #ifdef PY3K
288 return PyUnicode_FromFormat("<qt signal %s of %s instance at %p>",
289 #else
273 return PyString_FromFormat("<qt signal %s of %s instance at %p>",
290 return PyString_FromFormat("<qt signal %s of %s instance at %p>",
291 #endif
274 f->m_ml->slotName().data(),
292 f->m_ml->slotName().data(),
275 f->m_self->ob_type->tp_name,
293 f->m_self->ob_type->tp_name,
276 f->m_self);
294 f->m_self);
277 }
295 }
278 }
296 }
279
297
280 static int
298 static int
281 meth_compare(PythonQtSignalFunctionObject *a, PythonQtSignalFunctionObject *b)
299 meth_compare(PythonQtSignalFunctionObject *a, PythonQtSignalFunctionObject *b)
282 {
300 {
283 if (a->m_self != b->m_self)
301 if (a->m_self != b->m_self)
284 return (a->m_self < b->m_self) ? -1 : 1;
302 return (a->m_self < b->m_self) ? -1 : 1;
285 if (a->m_ml == b->m_ml)
303 if (a->m_ml == b->m_ml)
286 return 0;
304 return 0;
287 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
305 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
288 if (strcmp(a->m_ml->metaMethod()->methodSignature(), b->m_ml->metaMethod()->methodSignature()) < 0)
306 if (strcmp(a->m_ml->metaMethod()->methodSignature(), b->m_ml->metaMethod()->methodSignature()) < 0)
289 #else
307 #else
290 if (strcmp(a->m_ml->metaMethod()->signature(), b->m_ml->metaMethod()->signature()) < 0)
308 if (strcmp(a->m_ml->metaMethod()->signature(), b->m_ml->metaMethod()->signature()) < 0)
291 #endif
309 #endif
292 return -1;
310 return -1;
293 else
311 else
294 return 1;
312 return 1;
295 }
313 }
296
314
297 static long
315 static long
298 meth_hash(PythonQtSignalFunctionObject *a)
316 meth_hash(PythonQtSignalFunctionObject *a)
299 {
317 {
300 long x,y;
318 long x,y;
301 if (a->m_self == NULL)
319 if (a->m_self == NULL)
302 x = 0;
320 x = 0;
303 else {
321 else {
304 x = PyObject_Hash(a->m_self);
322 x = PyObject_Hash(a->m_self);
305 if (x == -1)
323 if (x == -1)
306 return -1;
324 return -1;
307 }
325 }
308 y = _Py_HashPointer((void*)(a->m_ml));
326 y = _Py_HashPointer((void*)(a->m_ml));
309 if (y == -1)
327 if (y == -1)
310 return -1;
328 return -1;
311 x ^= y;
329 x ^= y;
312 if (x == -1)
330 if (x == -1)
313 x = -2;
331 x = -2;
314 return x;
332 return x;
315 }
333 }
316
334
335 // for python 3.x
336 static PyObject*
337 meth_richcompare(PythonQtSignalFunctionObject *a, PythonQtSignalFunctionObject *b, int op)
338 {
339 int x = meth_compare(a, b);
340 bool r;
341 if (op == Py_LT)
342 r = x < 0;
343 else if (op == Py_LE)
344 r = x < 1;
345 else if (op == Py_EQ)
346 r = x == 0;
347 else if (op == Py_NE)
348 r = x != 0;
349 else if (op == Py_GE)
350 r = x > -1;
351 else if (op == Py_GT)
352 r = x > 0;
353 if (r)
354 Py_RETURN_TRUE;
355 else
356 Py_RETURN_FALSE;
357 }
317
358
318 PyTypeObject PythonQtSignalFunction_Type = {
359 PyTypeObject PythonQtSignalFunction_Type = {
319 PyObject_HEAD_INIT(&PyType_Type)
360 PyVarObject_HEAD_INIT(&PyType_Type, 0)
320 0,
321 "builtin_qt_signal",
361 "builtin_qt_signal",
322 sizeof(PythonQtSignalFunctionObject),
362 sizeof(PythonQtSignalFunctionObject),
323 0,
363 0,
324 (destructor)meth_dealloc, /* tp_dealloc */
364 (destructor)meth_dealloc, /* tp_dealloc */
325 0, /* tp_print */
365 0, /* tp_print */
326 0, /* tp_getattr */
366 0, /* tp_getattr */
327 0, /* tp_setattr */
367 0, /* tp_setattr */
368 #ifdef PY3K
369 0,
370 #else
328 (cmpfunc)meth_compare, /* tp_compare */
371 (cmpfunc)meth_compare, /* tp_compare */
372 #endif
329 (reprfunc)meth_repr, /* tp_repr */
373 (reprfunc)meth_repr, /* tp_repr */
330 0, /* tp_as_number */
374 0, /* tp_as_number */
331 0, /* tp_as_sequence */
375 0, /* tp_as_sequence */
332 // TODO: implement tp_as_mapping to support overload resolution on the signal
376 // TODO: implement tp_as_mapping to support overload resolution on the signal
333 0, /* tp_as_mapping */
377 0, /* tp_as_mapping */
334 (hashfunc)meth_hash, /* tp_hash */
378 (hashfunc)meth_hash, /* tp_hash */
335 PythonQtSignalFunction_Call, /* tp_call */
379 PythonQtSignalFunction_Call, /* tp_call */
336 0, /* tp_str */
380 0, /* tp_str */
337 PyObject_GenericGetAttr, /* tp_getattro */
381 PyObject_GenericGetAttr, /* tp_getattro */
338 0, /* tp_setattro */
382 0, /* tp_setattro */
339 0, /* tp_as_buffer */
383 0, /* tp_as_buffer */
340 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_HAVE_GC,/* tp_flags */
384 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_HAVE_GC,/* tp_flags */
341 0, /* tp_doc */
385 0, /* tp_doc */
342 (traverseproc)meth_traverse, /* tp_traverse */
386 (traverseproc)meth_traverse, /* tp_traverse */
343 0, /* tp_clear */
387 0, /* tp_clear */
344 0, /* tp_richcompare */
388 (richcmpfunc)meth_richcompare, /* tp_richcompare */
345 0, /* tp_weaklistoffset */
389 0, /* tp_weaklistoffset */
346 0, /* tp_iter */
390 0, /* tp_iter */
347 0, /* tp_iternext */
391 0, /* tp_iternext */
348 meth_methods, /* tp_methods */
392 meth_methods, /* tp_methods */
349 meth_members, /* tp_members */
393 meth_members, /* tp_members */
350 meth_getsets, /* tp_getset */
394 meth_getsets, /* tp_getset */
351 0, /* tp_base */
395 0, /* tp_base */
352 0, /* tp_dict */
396 0, /* tp_dict */
353 };
397 };
354
398
355 /* Clear out the free list */
399 /* Clear out the free list */
356
400
357 void
401 void
358 PythonQtSignalFunction_Fini(void)
402 PythonQtSignalFunction_Fini(void)
359 {
403 {
360 while (PythonQtSignal_free_list) {
404 while (PythonQtSignal_free_list) {
361 PythonQtSignalFunctionObject *v = PythonQtSignal_free_list;
405 PythonQtSignalFunctionObject *v = PythonQtSignal_free_list;
362 PythonQtSignal_free_list = (PythonQtSignalFunctionObject *)(v->m_self);
406 PythonQtSignal_free_list = (PythonQtSignalFunctionObject *)(v->m_self);
363 PyObject_GC_Del(v);
407 PyObject_GC_Del(v);
364 }
408 }
365 }
409 }
366
410
@@ -1,273 +1,277
1 /*
1 /*
2 *
2 *
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
4 *
4 *
5 * This library is free software; you can redistribute it and/or
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
8 * version 2.1 of the License, or (at your option) any later version.
9 *
9 *
10 * This library is distributed in the hope that it will be useful,
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
13 * Lesser General Public License for more details.
14 *
14 *
15 * Further, this software is distributed without any warranty that it is
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
20 * other software, or any other product whatsoever.
21 *
21 *
22 * You should have received a copy of the GNU Lesser General Public
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
25 *
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
27 * 28359 Bremen, Germany or:
27 * 28359 Bremen, Germany or:
28 *
28 *
29 * http://www.mevis.de
29 * http://www.mevis.de
30 *
30 *
31 */
31 */
32
32
33 //----------------------------------------------------------------------------------
33 //----------------------------------------------------------------------------------
34 /*!
34 /*!
35 // \file PythonQtSignalReceiver.cpp
35 // \file PythonQtSignalReceiver.cpp
36 // \author Florian Link
36 // \author Florian Link
37 // \author Last changed by $Author: florian $
37 // \author Last changed by $Author: florian $
38 // \date 2006-05
38 // \date 2006-05
39 */
39 */
40 //----------------------------------------------------------------------------------
40 //----------------------------------------------------------------------------------
41
41
42 #include "PythonQtSignalReceiver.h"
42 #include "PythonQtSignalReceiver.h"
43 #include "PythonQtClassInfo.h"
43 #include "PythonQtClassInfo.h"
44 #include "PythonQtMethodInfo.h"
44 #include "PythonQtMethodInfo.h"
45 #include "PythonQtConversion.h"
45 #include "PythonQtConversion.h"
46 #include <QMetaObject>
46 #include <QMetaObject>
47 #include <QMetaMethod>
47 #include <QMetaMethod>
48 #include "funcobject.h"
48 #include "funcobject.h"
49
49
50 // use -2 to signal that the variable is uninitialized
50 // use -2 to signal that the variable is uninitialized
51 int PythonQtSignalReceiver::_destroyedSignal1Id = -2;
51 int PythonQtSignalReceiver::_destroyedSignal1Id = -2;
52 int PythonQtSignalReceiver::_destroyedSignal2Id = -2;
52 int PythonQtSignalReceiver::_destroyedSignal2Id = -2;
53
53
54 void PythonQtSignalTarget::call(void **arguments) const {
54 void PythonQtSignalTarget::call(void **arguments) const {
55 PyObject* result = call(_callable, methodInfo(), arguments);
55 PyObject* result = call(_callable, methodInfo(), arguments);
56 if (result) {
56 if (result) {
57 Py_DECREF(result);
57 Py_DECREF(result);
58 }
58 }
59 }
59 }
60
60
61 PyObject* PythonQtSignalTarget::call(PyObject* callable, const PythonQtMethodInfo* methodInfos, void **arguments, bool skipFirstArgumentOfMethodInfo)
61 PyObject* PythonQtSignalTarget::call(PyObject* callable, const PythonQtMethodInfo* methodInfos, void **arguments, bool skipFirstArgumentOfMethodInfo)
62 {
62 {
63 Q_UNUSED(skipFirstArgumentOfMethodInfo)
63 Q_UNUSED(skipFirstArgumentOfMethodInfo)
64
64
65 // Note: we check if the callable is a PyFunctionObject and has a fixed number of arguments
65 // Note: we check if the callable is a PyFunctionObject and has a fixed number of arguments
66 // if that is the case, we only pass these arguments to python and skip the additional arguments from the signal
66 // if that is the case, we only pass these arguments to python and skip the additional arguments from the signal
67
67
68 int numPythonArgs = -1;
68 int numPythonArgs = -1;
69 if (PyFunction_Check(callable)) {
69 if (PyFunction_Check(callable)) {
70 PyObject* o = callable;
70 PyObject* o = callable;
71 PyFunctionObject* func = (PyFunctionObject*)o;
71 PyFunctionObject* func = (PyFunctionObject*)o;
72 PyCodeObject* code = (PyCodeObject*)func->func_code;
72 PyCodeObject* code = (PyCodeObject*)func->func_code;
73 if (!(code->co_flags & CO_VARARGS)) {
73 if (!(code->co_flags & CO_VARARGS)) {
74 numPythonArgs = code->co_argcount;
74 numPythonArgs = code->co_argcount;
75 } else {
75 } else {
76 // variable numbers of arguments allowed
76 // variable numbers of arguments allowed
77 }
77 }
78 } else if (PyMethod_Check(callable)) {
78 } else if (PyMethod_Check(callable)) {
79 PyObject* o = callable;
79 PyObject* o = callable;
80 PyMethodObject* method = (PyMethodObject*)o;
80 PyMethodObject* method = (PyMethodObject*)o;
81 if (PyFunction_Check(method->im_func)) {
81 if (PyFunction_Check(method->im_func)) {
82 PyFunctionObject* func = (PyFunctionObject*)method->im_func;
82 PyFunctionObject* func = (PyFunctionObject*)method->im_func;
83 PyCodeObject* code = (PyCodeObject*)func->func_code;
83 PyCodeObject* code = (PyCodeObject*)func->func_code;
84 if (!(code->co_flags & CO_VARARGS)) {
84 if (!(code->co_flags & CO_VARARGS)) {
85 numPythonArgs = code->co_argcount - 1; // we subtract one because the first is "self"
85 numPythonArgs = code->co_argcount - 1; // we subtract one because the first is "self"
86 } else {
86 } else {
87 // variable numbers of arguments allowed
87 // variable numbers of arguments allowed
88 }
88 }
89 }
89 }
90 }
90 }
91
91
92 const PythonQtMethodInfo* m = methodInfos;
92 const PythonQtMethodInfo* m = methodInfos;
93 // parameterCount includes return value:
93 // parameterCount includes return value:
94 int count = m->parameterCount();
94 int count = m->parameterCount();
95 if (numPythonArgs!=-1) {
95 if (numPythonArgs!=-1) {
96 if (count>numPythonArgs+1) {
96 if (count>numPythonArgs+1) {
97 // take less arguments
97 // take less arguments
98 count = numPythonArgs+1;
98 count = numPythonArgs+1;
99 }
99 }
100 }
100 }
101
101
102 PyObject* pargs = NULL;
102 PyObject* pargs = NULL;
103 if (count>1) {
103 if (count>1) {
104 pargs = PyTuple_New(count-1);
104 pargs = PyTuple_New(count-1);
105 }
105 }
106 bool err = false;
106 bool err = false;
107 // transform Qt values to Python
107 // transform Qt values to Python
108 const QList<PythonQtMethodInfo::ParameterInfo>& params = m->parameters();
108 const QList<PythonQtMethodInfo::ParameterInfo>& params = m->parameters();
109 for (int i = 1; i < count; i++) {
109 for (int i = 1; i < count; i++) {
110 const PythonQtMethodInfo::ParameterInfo& param = params.at(i);
110 const PythonQtMethodInfo::ParameterInfo& param = params.at(i);
111 PyObject* arg = PythonQtConv::ConvertQtValueToPython(param, arguments[i]);
111 PyObject* arg = PythonQtConv::ConvertQtValueToPython(param, arguments[i]);
112 if (arg) {
112 if (arg) {
113 // steals reference, no unref
113 // steals reference, no unref
114 PyTuple_SetItem(pargs, i-1,arg);
114 PyTuple_SetItem(pargs, i-1,arg);
115 } else {
115 } else {
116 err = true;
116 err = true;
117 break;
117 break;
118 }
118 }
119 }
119 }
120
120
121 PyObject* result = NULL;
121 PyObject* result = NULL;
122 if (!err) {
122 if (!err) {
123 PyErr_Clear();
123 PyErr_Clear();
124 result = PyObject_CallObject(callable, pargs);
124 result = PyObject_CallObject(callable, pargs);
125 if (result) {
125 if (result) {
126 // ok
126 // ok
127 } else {
127 } else {
128 PythonQt::self()->handleError();
128 PythonQt::self()->handleError();
129 }
129 }
130 }
130 }
131 if (pargs) {
131 if (pargs) {
132 // free the arguments again
132 // free the arguments again
133 Py_DECREF(pargs);
133 Py_DECREF(pargs);
134 }
134 }
135
135
136 return result;
136 return result;
137 }
137 }
138
138
139 bool PythonQtSignalTarget::isSame( int signalId, PyObject* callable ) const
139 bool PythonQtSignalTarget::isSame( int signalId, PyObject* callable ) const
140 {
140 {
141 #ifdef PY3K
142 return PyObject_RichCompareBool(callable, _callable, Py_EQ) && signalId == _signalId;
143 #else
141 return PyObject_Compare(callable, _callable) == 0 && signalId==_signalId;
144 return PyObject_Compare(callable, _callable) == 0 && signalId==_signalId;
145 #endif
142 }
146 }
143
147
144 //------------------------------------------------------------------------------
148 //------------------------------------------------------------------------------
145
149
146 PythonQtSignalReceiver::PythonQtSignalReceiver(QObject* obj):PythonQtSignalReceiverBase(obj)
150 PythonQtSignalReceiver::PythonQtSignalReceiver(QObject* obj):PythonQtSignalReceiverBase(obj)
147 {
151 {
148 if (_destroyedSignal1Id == -2) {
152 if (_destroyedSignal1Id == -2) {
149 // initialize these once
153 // initialize these once
150 _destroyedSignal1Id = QObject::staticMetaObject.indexOfSignal("destroyed()");
154 _destroyedSignal1Id = QObject::staticMetaObject.indexOfSignal("destroyed()");
151 _destroyedSignal2Id = QObject::staticMetaObject.indexOfSignal("destroyed(QObject*)");
155 _destroyedSignal2Id = QObject::staticMetaObject.indexOfSignal("destroyed(QObject*)");
152 if (_destroyedSignal1Id == -1 || _destroyedSignal2Id == -1) {
156 if (_destroyedSignal1Id == -1 || _destroyedSignal2Id == -1) {
153 std::cerr << "PythonQt: could not find destroyed signal index, should never happen!" << std::endl;
157 std::cerr << "PythonQt: could not find destroyed signal index, should never happen!" << std::endl;
154 }
158 }
155 }
159 }
156
160
157 _destroyedSignalCount = 0;
161 _destroyedSignalCount = 0;
158 _obj = obj;
162 _obj = obj;
159
163
160 // fetch the class info for object, since we will need to for correct enum resolution in
164 // fetch the class info for object, since we will need to for correct enum resolution in
161 // signals
165 // signals
162 _objClassInfo = PythonQt::priv()->getClassInfo(obj->metaObject());
166 _objClassInfo = PythonQt::priv()->getClassInfo(obj->metaObject());
163 if (!_objClassInfo || !_objClassInfo->isQObject()) {
167 if (!_objClassInfo || !_objClassInfo->isQObject()) {
164 PythonQt::self()->registerClass(obj->metaObject());
168 PythonQt::self()->registerClass(obj->metaObject());
165 _objClassInfo = PythonQt::priv()->getClassInfo(obj->metaObject());
169 _objClassInfo = PythonQt::priv()->getClassInfo(obj->metaObject());
166 }
170 }
167 // force decorator/enum creation
171 // force decorator/enum creation
168 _objClassInfo->decorator();
172 _objClassInfo->decorator();
169
173
170 _slotCount = staticMetaObject.methodOffset();
174 _slotCount = staticMetaObject.methodOffset();
171 }
175 }
172
176
173 PythonQtSignalReceiver::~PythonQtSignalReceiver()
177 PythonQtSignalReceiver::~PythonQtSignalReceiver()
174 {
178 {
175 PythonQt::priv()->removeSignalEmitter(_obj);
179 PythonQt::priv()->removeSignalEmitter(_obj);
176 }
180 }
177
181
178
182
179 bool PythonQtSignalReceiver::addSignalHandler(const char* signal, PyObject* callable)
183 bool PythonQtSignalReceiver::addSignalHandler(const char* signal, PyObject* callable)
180 {
184 {
181 bool flag = false;
185 bool flag = false;
182 int sigId = getSignalIndex(signal);
186 int sigId = getSignalIndex(signal);
183 if (sigId>=0) {
187 if (sigId>=0) {
184 // create PythonQtMethodInfo from signal
188 // create PythonQtMethodInfo from signal
185 QMetaMethod meta = _obj->metaObject()->method(sigId);
189 QMetaMethod meta = _obj->metaObject()->method(sigId);
186 const PythonQtMethodInfo* signalInfo = PythonQtMethodInfo::getCachedMethodInfo(meta, _objClassInfo);
190 const PythonQtMethodInfo* signalInfo = PythonQtMethodInfo::getCachedMethodInfo(meta, _objClassInfo);
187 PythonQtSignalTarget t(sigId, signalInfo, _slotCount, callable);
191 PythonQtSignalTarget t(sigId, signalInfo, _slotCount, callable);
188 _targets.append(t);
192 _targets.append(t);
189 // now connect to ourselves with the new slot id
193 // now connect to ourselves with the new slot id
190 QMetaObject::connect(_obj, sigId, this, _slotCount, Qt::AutoConnection, 0);
194 QMetaObject::connect(_obj, sigId, this, _slotCount, Qt::AutoConnection, 0);
191
195
192 _slotCount++;
196 _slotCount++;
193 flag = true;
197 flag = true;
194
198
195 if (sigId == _destroyedSignal1Id || sigId == _destroyedSignal2Id) {
199 if (sigId == _destroyedSignal1Id || sigId == _destroyedSignal2Id) {
196 _destroyedSignalCount++;
200 _destroyedSignalCount++;
197 if (_destroyedSignalCount==1) {
201 if (_destroyedSignalCount==1) {
198 // make ourself parent of PythonQt, to not get deleted as a child of the QObject we are
202 // make ourself parent of PythonQt, to not get deleted as a child of the QObject we are
199 // listening to, since we do that manually when we receive the destroyed signal
203 // listening to, since we do that manually when we receive the destroyed signal
200 this->setParent(PythonQt::priv());
204 this->setParent(PythonQt::priv());
201 }
205 }
202 }
206 }
203 }
207 }
204 return flag;
208 return flag;
205 }
209 }
206
210
207 bool PythonQtSignalReceiver::removeSignalHandler(const char* signal, PyObject* callable)
211 bool PythonQtSignalReceiver::removeSignalHandler(const char* signal, PyObject* callable)
208 {
212 {
209 int foundCount = 0;
213 int foundCount = 0;
210 int sigId = getSignalIndex(signal);
214 int sigId = getSignalIndex(signal);
211 if (sigId>=0) {
215 if (sigId>=0) {
212 QMutableListIterator<PythonQtSignalTarget> i(_targets);
216 QMutableListIterator<PythonQtSignalTarget> i(_targets);
213 if (callable) {
217 if (callable) {
214 while (i.hasNext()) {
218 while (i.hasNext()) {
215 if (i.next().isSame(sigId, callable)) {
219 if (i.next().isSame(sigId, callable)) {
216 i.remove();
220 i.remove();
217 foundCount++;
221 foundCount++;
218 break;
222 break;
219 }
223 }
220 }
224 }
221 } else {
225 } else {
222 while (i.hasNext()) {
226 while (i.hasNext()) {
223 if (i.next().signalId() == sigId) {
227 if (i.next().signalId() == sigId) {
224 i.remove();
228 i.remove();
225 foundCount++;
229 foundCount++;
226 }
230 }
227 }
231 }
228 }
232 }
229 }
233 }
230 if ((foundCount>0) && (sigId == _destroyedSignal1Id) || (sigId == _destroyedSignal2Id)) {
234 if ((foundCount>0) && (sigId == _destroyedSignal1Id) || (sigId == _destroyedSignal2Id)) {
231 _destroyedSignalCount -= foundCount;
235 _destroyedSignalCount -= foundCount;
232 if (_destroyedSignalCount==0) {
236 if (_destroyedSignalCount==0) {
233 // make ourself child of QObject again, to get deleted when the object gets deleted
237 // make ourself child of QObject again, to get deleted when the object gets deleted
234 this->setParent(_obj);
238 this->setParent(_obj);
235 }
239 }
236 }
240 }
237 return foundCount>0;
241 return foundCount>0;
238 }
242 }
239
243
240 int PythonQtSignalReceiver::getSignalIndex(const char* signal)
244 int PythonQtSignalReceiver::getSignalIndex(const char* signal)
241 {
245 {
242 int sigId = _obj->metaObject()->indexOfSignal(signal+1);
246 int sigId = _obj->metaObject()->indexOfSignal(signal+1);
243 if (sigId<0) {
247 if (sigId<0) {
244 QByteArray tmpSig = QMetaObject::normalizedSignature(signal+1);
248 QByteArray tmpSig = QMetaObject::normalizedSignature(signal+1);
245 sigId = _obj->metaObject()->indexOfSignal(tmpSig);
249 sigId = _obj->metaObject()->indexOfSignal(tmpSig);
246 }
250 }
247 return sigId;
251 return sigId;
248 }
252 }
249
253
250 int PythonQtSignalReceiver::qt_metacall(QMetaObject::Call c, int id, void **arguments)
254 int PythonQtSignalReceiver::qt_metacall(QMetaObject::Call c, int id, void **arguments)
251 {
255 {
252 // mlabDebugConst("PythonQt", "PythonQtSignalReceiver invoke " << _obj->className() << " " << _obj->name() << " " << id);
256 // mlabDebugConst("PythonQt", "PythonQtSignalReceiver invoke " << _obj->className() << " " << _obj->name() << " " << id);
253 if (c != QMetaObject::InvokeMetaMethod) {
257 if (c != QMetaObject::InvokeMetaMethod) {
254 QObject::qt_metacall(c, id, arguments);
258 QObject::qt_metacall(c, id, arguments);
255 }
259 }
256
260
257 Q_FOREACH(const PythonQtSignalTarget& t, _targets) {
261 Q_FOREACH(const PythonQtSignalTarget& t, _targets) {
258 if (t.slotId() == id) {
262 if (t.slotId() == id) {
259 t.call(arguments);
263 t.call(arguments);
260 // if the signal is the last destroyed signal, we delete ourselves
264 // if the signal is the last destroyed signal, we delete ourselves
261 int sigId = t.signalId();
265 int sigId = t.signalId();
262 if ((sigId == _destroyedSignal1Id) || (sigId == _destroyedSignal2Id)) {
266 if ((sigId == _destroyedSignal1Id) || (sigId == _destroyedSignal2Id)) {
263 _destroyedSignalCount--;
267 _destroyedSignalCount--;
264 if (_destroyedSignalCount == 0) {
268 if (_destroyedSignalCount == 0) {
265 delete this;
269 delete this;
266 }
270 }
267 }
271 }
268 break;
272 break;
269 }
273 }
270 }
274 }
271 return 0;
275 return 0;
272 }
276 }
273
277
@@ -1,670 +1,735
1 /*
1 /*
2 *
2 *
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
4 *
4 *
5 * This library is free software; you can redistribute it and/or
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
8 * version 2.1 of the License, or (at your option) any later version.
9 *
9 *
10 * This library is distributed in the hope that it will be useful,
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
13 * Lesser General Public License for more details.
14 *
14 *
15 * Further, this software is distributed without any warranty that it is
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
20 * other software, or any other product whatsoever.
21 *
21 *
22 * You should have received a copy of the GNU Lesser General Public
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
25 *
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
27 * 28359 Bremen, Germany or:
27 * 28359 Bremen, Germany or:
28 *
28 *
29 * http://www.mevis.de
29 * http://www.mevis.de
30 *
30 *
31 */
31 */
32
32
33 //----------------------------------------------------------------------------------
33 //----------------------------------------------------------------------------------
34 /*!
34 /*!
35 // \file PythonQtSlot.cpp
35 // \file PythonQtSlot.cpp
36 // \author Florian Link
36 // \author Florian Link
37 // \author Last changed by $Author: florian $
37 // \author Last changed by $Author: florian $
38 // \date 2006-05
38 // \date 2006-05
39 */
39 */
40 //----------------------------------------------------------------------------------
40 //----------------------------------------------------------------------------------
41
41
42 #include "PythonQt.h"
42 #include "PythonQt.h"
43 #include "PythonQtSlot.h"
43 #include "PythonQtSlot.h"
44 #include "PythonQtInstanceWrapper.h"
44 #include "PythonQtInstanceWrapper.h"
45 #include "PythonQtClassInfo.h"
45 #include "PythonQtClassInfo.h"
46 #include "PythonQtMisc.h"
46 #include "PythonQtMisc.h"
47 #include "PythonQtConversion.h"
47 #include "PythonQtConversion.h"
48 #include <iostream>
48 #include <iostream>
49
49
50 #include <exception>
50 #include <exception>
51 #include <stdexcept>
51 #include <stdexcept>
52
52
53 #include <QByteArray>
53 #include <QByteArray>
54
54
55 #if PY_MAJOR_VERSION >= 3
56 #define PY3K
57 #endif
58
55 #define PYTHONQT_MAX_ARGS 32
59 #define PYTHONQT_MAX_ARGS 32
56
60
57
61
58 bool PythonQtCallSlot(PythonQtClassInfo* classInfo, QObject* objectToCall, PyObject* args, bool strict, PythonQtSlotInfo* info, void* firstArgument, PyObject** pythonReturnValue, void** directReturnValuePointer)
62 bool PythonQtCallSlot(PythonQtClassInfo* classInfo, QObject* objectToCall, PyObject* args, bool strict, PythonQtSlotInfo* info, void* firstArgument, PyObject** pythonReturnValue, void** directReturnValuePointer)
59 {
63 {
60 static unsigned int recursiveEntry = 0;
64 static unsigned int recursiveEntry = 0;
61
65
62 if (directReturnValuePointer) {
66 if (directReturnValuePointer) {
63 *directReturnValuePointer = NULL;
67 *directReturnValuePointer = NULL;
64 }
68 }
65 // store the current storage position, so that we can get back to this state after a slot is called
69 // store the current storage position, so that we can get back to this state after a slot is called
66 // (do this locally, so that we have all positions on the stack
70 // (do this locally, so that we have all positions on the stack
67 PythonQtValueStoragePosition globalValueStoragePos;
71 PythonQtValueStoragePosition globalValueStoragePos;
68 PythonQtValueStoragePosition globalPtrStoragePos;
72 PythonQtValueStoragePosition globalPtrStoragePos;
69 PythonQtValueStoragePosition globalVariantStoragePos;
73 PythonQtValueStoragePosition globalVariantStoragePos;
70 PythonQtConv::global_valueStorage.getPos(globalValueStoragePos);
74 PythonQtConv::global_valueStorage.getPos(globalValueStoragePos);
71 PythonQtConv::global_ptrStorage.getPos(globalPtrStoragePos);
75 PythonQtConv::global_ptrStorage.getPos(globalPtrStoragePos);
72 PythonQtConv::global_variantStorage.getPos(globalVariantStoragePos);
76 PythonQtConv::global_variantStorage.getPos(globalVariantStoragePos);
73
77
74 recursiveEntry++;
78 recursiveEntry++;
75
79
76 // the arguments that are passed to qt_metacall
80 // the arguments that are passed to qt_metacall
77 void* argList[PYTHONQT_MAX_ARGS];
81 void* argList[PYTHONQT_MAX_ARGS];
78 PyObject* result = NULL;
82 PyObject* result = NULL;
79 int argc = info->parameterCount();
83 int argc = info->parameterCount();
80 const QList<PythonQtSlotInfo::ParameterInfo>& params = info->parameters();
84 const QList<PythonQtSlotInfo::ParameterInfo>& params = info->parameters();
81
85
82 const PythonQtSlotInfo::ParameterInfo& returnValueParam = params.at(0);
86 const PythonQtSlotInfo::ParameterInfo& returnValueParam = params.at(0);
83 // set return argument to NULL
87 // set return argument to NULL
84 argList[0] = NULL;
88 argList[0] = NULL;
85
89
86 bool ok = true;
90 bool ok = true;
87 bool skipFirst = false;
91 bool skipFirst = false;
88 if (info->isInstanceDecorator()) {
92 if (info->isInstanceDecorator()) {
89 skipFirst = true;
93 skipFirst = true;
90
94
91 // for decorators on CPP objects, we take the cpp ptr, for QObjects we take the QObject pointer
95 // for decorators on CPP objects, we take the cpp ptr, for QObjects we take the QObject pointer
92 void* arg1 = firstArgument;
96 void* arg1 = firstArgument;
93 if (!arg1) {
97 if (!arg1) {
94 arg1 = objectToCall;
98 arg1 = objectToCall;
95 }
99 }
96 if (arg1) {
100 if (arg1) {
97 // upcast to correct parent class
101 // upcast to correct parent class
98 arg1 = ((char*)arg1)+info->upcastingOffset();
102 arg1 = ((char*)arg1)+info->upcastingOffset();
99 }
103 }
100
104
101 argList[1] = &arg1;
105 argList[1] = &arg1;
102 if (ok) {
106 if (ok) {
103 for (int i = 2; i<argc && ok; i++) {
107 for (int i = 2; i<argc && ok; i++) {
104 const PythonQtSlotInfo::ParameterInfo& param = params.at(i);
108 const PythonQtSlotInfo::ParameterInfo& param = params.at(i);
105 argList[i] = PythonQtConv::ConvertPythonToQt(param, PyTuple_GET_ITEM(args, i-2), strict, classInfo);
109 argList[i] = PythonQtConv::ConvertPythonToQt(param, PyTuple_GET_ITEM(args, i-2), strict, classInfo);
106 if (argList[i]==NULL) {
110 if (argList[i]==NULL) {
107 ok = false;
111 ok = false;
108 break;
112 break;
109 }
113 }
110 }
114 }
111 }
115 }
112 } else {
116 } else {
113 for (int i = 1; i<argc && ok; i++) {
117 for (int i = 1; i<argc && ok; i++) {
114 const PythonQtSlotInfo::ParameterInfo& param = params.at(i);
118 const PythonQtSlotInfo::ParameterInfo& param = params.at(i);
115 argList[i] = PythonQtConv::ConvertPythonToQt(param, PyTuple_GET_ITEM(args, i-1), strict, classInfo);
119 argList[i] = PythonQtConv::ConvertPythonToQt(param, PyTuple_GET_ITEM(args, i-1), strict, classInfo);
116 if (argList[i]==NULL) {
120 if (argList[i]==NULL) {
117 ok = false;
121 ok = false;
118 break;
122 break;
119 }
123 }
120 }
124 }
121 }
125 }
122
126
123 if (ok) {
127 if (ok) {
124 // parameters are ok, now create the qt return value which is assigned to by metacall
128 // parameters are ok, now create the qt return value which is assigned to by metacall
125 if (returnValueParam.typeId != QMetaType::Void) {
129 if (returnValueParam.typeId != QMetaType::Void) {
126 // create empty default value for the return value
130 // create empty default value for the return value
127 if (!directReturnValuePointer) {
131 if (!directReturnValuePointer) {
128 // create empty default value for the return value
132 // create empty default value for the return value
129 argList[0] = PythonQtConv::CreateQtReturnValue(returnValueParam);
133 argList[0] = PythonQtConv::CreateQtReturnValue(returnValueParam);
130 if (argList[0]==NULL) {
134 if (argList[0]==NULL) {
131 // return value could not be created, maybe we have a registered class with a default constructor, so that we can construct the pythonqt wrapper object and
135 // return value could not be created, maybe we have a registered class with a default constructor, so that we can construct the pythonqt wrapper object and
132 // pass its internal pointer
136 // pass its internal pointer
133 PythonQtClassInfo* info = PythonQt::priv()->getClassInfo(returnValueParam.name);
137 PythonQtClassInfo* info = PythonQt::priv()->getClassInfo(returnValueParam.name);
134 if (info && info->pythonQtClassWrapper()) {
138 if (info && info->pythonQtClassWrapper()) {
135 PyObject* emptyTuple = PyTuple_New(0);
139 PyObject* emptyTuple = PyTuple_New(0);
136 // 1) default construct an empty object as python object (owned by PythonQt), by calling the meta class with empty arguments
140 // 1) default construct an empty object as python object (owned by PythonQt), by calling the meta class with empty arguments
137 result = PyObject_Call((PyObject*)info->pythonQtClassWrapper(), emptyTuple, NULL);
141 result = PyObject_Call((PyObject*)info->pythonQtClassWrapper(), emptyTuple, NULL);
138 if (result) {
142 if (result) {
139 argList[0] = ((PythonQtInstanceWrapper*)result)->_wrappedPtr;
143 argList[0] = ((PythonQtInstanceWrapper*)result)->_wrappedPtr;
140 }
144 }
141 Py_DECREF(emptyTuple);
145 Py_DECREF(emptyTuple);
142 }
146 }
143 }
147 }
144 } else {
148 } else {
145 // we can use our pointer directly!
149 // we can use our pointer directly!
146 argList[0] = directReturnValuePointer;
150 argList[0] = directReturnValuePointer;
147 }
151 }
148 }
152 }
149
153
150
154
151 PythonQt::ProfilingCB* profilingCB = PythonQt::priv()->profilingCB();
155 PythonQt::ProfilingCB* profilingCB = PythonQt::priv()->profilingCB();
152 if (profilingCB) {
156 if (profilingCB) {
153 const char* className = NULL;
157 const char* className = NULL;
154 if (info->decorator()) {
158 if (info->decorator()) {
155 className = info->decorator()->metaObject()->className();
159 className = info->decorator()->metaObject()->className();
156 } else {
160 } else {
157 className = objectToCall->metaObject()->className();
161 className = objectToCall->metaObject()->className();
158 }
162 }
159
163
160 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
164 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
161 profilingCB(PythonQt::Enter, className, info->metaMethod()->methodSignature());
165 profilingCB(PythonQt::Enter, className, info->metaMethod()->methodSignature());
162 #else
166 #else
163 profilingCB(PythonQt::Enter, className, info->metaMethod()->signature());
167 profilingCB(PythonQt::Enter, className, info->metaMethod()->signature());
164 #endif
168 #endif
165 }
169 }
166
170
167 // invoke the slot via metacall
171 // invoke the slot via metacall
168 bool hadException = false;
172 bool hadException = false;
169 QObject* obj = info->decorator()?info->decorator():objectToCall;
173 QObject* obj = info->decorator()?info->decorator():objectToCall;
170 if (!obj) {
174 if (!obj) {
171 hadException = true;
175 hadException = true;
172 PyErr_SetString(PyExc_RuntimeError, "Trying to call a slot on a deleted QObject!");
176 PyErr_SetString(PyExc_RuntimeError, "Trying to call a slot on a deleted QObject!");
173 } else {
177 } else {
174 try {
178 try {
175 obj->qt_metacall(QMetaObject::InvokeMetaMethod, info->slotIndex(), argList);
179 obj->qt_metacall(QMetaObject::InvokeMetaMethod, info->slotIndex(), argList);
176 } catch (std::bad_alloc & e) {
180 } catch (std::bad_alloc & e) {
177 hadException = true;
181 hadException = true;
178 QByteArray what("std::bad_alloc: ");
182 QByteArray what("std::bad_alloc: ");
179 what += e.what();
183 what += e.what();
180 PyErr_SetString(PyExc_MemoryError, what.constData());
184 PyErr_SetString(PyExc_MemoryError, what.constData());
181 } catch (std::runtime_error & e) {
185 } catch (std::runtime_error & e) {
182 hadException = true;
186 hadException = true;
183 QByteArray what("std::runtime_error: ");
187 QByteArray what("std::runtime_error: ");
184 what += e.what();
188 what += e.what();
185 PyErr_SetString(PyExc_RuntimeError, what.constData());
189 PyErr_SetString(PyExc_RuntimeError, what.constData());
186 } catch (std::logic_error & e) {
190 } catch (std::logic_error & e) {
187 hadException = true;
191 hadException = true;
188 QByteArray what("std::logic_error: ");
192 QByteArray what("std::logic_error: ");
189 what += e.what();
193 what += e.what();
190 PyErr_SetString(PyExc_RuntimeError, what.constData());
194 PyErr_SetString(PyExc_RuntimeError, what.constData());
191 } catch (std::exception& e) {
195 } catch (std::exception& e) {
192 hadException = true;
196 hadException = true;
193 QByteArray what("std::exception: ");
197 QByteArray what("std::exception: ");
194 what += e.what();
198 what += e.what();
199 #ifdef PY3K
200 PyErr_SetString(PyExc_RuntimeError, what.constData());
201 #else
195 PyErr_SetString(PyExc_StandardError, what.constData());
202 PyErr_SetString(PyExc_StandardError, what.constData());
203 #endif
196 }
204 }
197 }
205 }
198
206
199 if (profilingCB) {
207 if (profilingCB) {
200 profilingCB(PythonQt::Leave, NULL, NULL);
208 profilingCB(PythonQt::Leave, NULL, NULL);
201 }
209 }
202
210
203 // handle the return value (which in most cases still needs to be converted to a Python object)
211 // handle the return value (which in most cases still needs to be converted to a Python object)
204 if (!hadException) {
212 if (!hadException) {
205 if (argList[0] || returnValueParam.typeId == QMetaType::Void) {
213 if (argList[0] || returnValueParam.typeId == QMetaType::Void) {
206 if (directReturnValuePointer) {
214 if (directReturnValuePointer) {
207 result = NULL;
215 result = NULL;
208 } else {
216 } else {
209 // the resulting object maybe present already, because we created it above at 1)...
217 // the resulting object maybe present already, because we created it above at 1)...
210 if (!result) {
218 if (!result) {
211 result = PythonQtConv::ConvertQtValueToPython(returnValueParam, argList[0]);
219 result = PythonQtConv::ConvertQtValueToPython(returnValueParam, argList[0]);
212 }
220 }
213 }
221 }
214 } else {
222 } else {
215 QString e = QString("Called ") + info->fullSignature() + ", return type '" + returnValueParam.name + "' is ignored because it is unknown to PythonQt. Probably you should register it using qRegisterMetaType() or add a default constructor decorator to the class.";
223 QString e = QString("Called ") + info->fullSignature() + ", return type '" + returnValueParam.name + "' is ignored because it is unknown to PythonQt. Probably you should register it using qRegisterMetaType() or add a default constructor decorator to the class.";
216 PyErr_SetString(PyExc_ValueError, e.toLatin1().data());
224 PyErr_SetString(PyExc_ValueError, e.toLatin1().data());
217 result = NULL;
225 result = NULL;
218 }
226 }
219 } else {
227 } else {
220 result = NULL;
228 result = NULL;
221 }
229 }
222 }
230 }
223 recursiveEntry--;
231 recursiveEntry--;
224
232
225 // reset the parameter storage position to the stored pos to "pop" the parameter stack
233 // reset the parameter storage position to the stored pos to "pop" the parameter stack
226 PythonQtConv::global_valueStorage.setPos(globalValueStoragePos);
234 PythonQtConv::global_valueStorage.setPos(globalValueStoragePos);
227 PythonQtConv::global_ptrStorage.setPos(globalPtrStoragePos);
235 PythonQtConv::global_ptrStorage.setPos(globalPtrStoragePos);
228 PythonQtConv::global_variantStorage.setPos(globalVariantStoragePos);
236 PythonQtConv::global_variantStorage.setPos(globalVariantStoragePos);
229
237
230 *pythonReturnValue = result;
238 *pythonReturnValue = result;
231 // NOTE: it is important to only return here, otherwise the stack will not be popped!!!
239 // NOTE: it is important to only return here, otherwise the stack will not be popped!!!
232 return result || (directReturnValuePointer && *directReturnValuePointer);
240 return result || (directReturnValuePointer && *directReturnValuePointer);
233 }
241 }
234
242
235 //-----------------------------------------------------------------------------------
243 //-----------------------------------------------------------------------------------
236
244
237 static PythonQtSlotFunctionObject *pythonqtslot_free_list = NULL;
245 static PythonQtSlotFunctionObject *pythonqtslot_free_list = NULL;
238
246
239 PyObject *PythonQtSlotFunction_Call(PyObject *func, PyObject *args, PyObject *kw)
247 PyObject *PythonQtSlotFunction_Call(PyObject *func, PyObject *args, PyObject *kw)
240 {
248 {
241 PythonQtSlotFunctionObject* f = (PythonQtSlotFunctionObject*)func;
249 PythonQtSlotFunctionObject* f = (PythonQtSlotFunctionObject*)func;
242 return PythonQtMemberFunction_Call(f->m_ml, f->m_self, args, kw);
250 return PythonQtMemberFunction_Call(f->m_ml, f->m_self, args, kw);
243 }
251 }
244
252
245 PyObject *PythonQtMemberFunction_Call(PythonQtSlotInfo* info, PyObject* m_self, PyObject *args, PyObject *kw)
253 PyObject *PythonQtMemberFunction_Call(PythonQtSlotInfo* info, PyObject* m_self, PyObject *args, PyObject *kw)
246 {
254 {
247 if (PyObject_TypeCheck(m_self, &PythonQtInstanceWrapper_Type)) {
255 if (PyObject_TypeCheck(m_self, &PythonQtInstanceWrapper_Type)) {
248 PythonQtInstanceWrapper* self = (PythonQtInstanceWrapper*) m_self;
256 PythonQtInstanceWrapper* self = (PythonQtInstanceWrapper*) m_self;
249 if (!info->isClassDecorator() && (self->_obj==NULL && self->_wrappedPtr==NULL)) {
257 if (!info->isClassDecorator() && (self->_obj==NULL && self->_wrappedPtr==NULL)) {
250 QString error = QString("Trying to call '") + info->slotName() + "' on a destroyed " + self->classInfo()->className() + " object";
258 QString error = QString("Trying to call '") + info->slotName() + "' on a destroyed " + self->classInfo()->className() + " object";
251 PyErr_SetString(PyExc_ValueError, error.toLatin1().data());
259 PyErr_SetString(PyExc_ValueError, error.toLatin1().data());
252 return NULL;
260 return NULL;
253 } else {
261 } else {
254 return PythonQtSlotFunction_CallImpl(self->classInfo(), self->_obj, info, args, kw, self->_wrappedPtr);
262 return PythonQtSlotFunction_CallImpl(self->classInfo(), self->_obj, info, args, kw, self->_wrappedPtr);
255 }
263 }
256 } else if (m_self->ob_type == &PythonQtClassWrapper_Type) {
264 } else if (m_self->ob_type == &PythonQtClassWrapper_Type) {
257 PythonQtClassWrapper* type = (PythonQtClassWrapper*) m_self;
265 PythonQtClassWrapper* type = (PythonQtClassWrapper*) m_self;
258 if (info->isClassDecorator()) {
266 if (info->isClassDecorator()) {
259 return PythonQtSlotFunction_CallImpl(type->classInfo(), NULL, info, args, kw);
267 return PythonQtSlotFunction_CallImpl(type->classInfo(), NULL, info, args, kw);
260 } else {
268 } else {
261 // otherwise, it is an unbound call and we have an instanceDecorator or normal slot...
269 // otherwise, it is an unbound call and we have an instanceDecorator or normal slot...
262 Py_ssize_t argc = PyTuple_Size(args);
270 Py_ssize_t argc = PyTuple_Size(args);
263 if (argc>0) {
271 if (argc>0) {
264 PyObject* firstArg = PyTuple_GET_ITEM(args, 0);
272 PyObject* firstArg = PyTuple_GET_ITEM(args, 0);
265 if (PyObject_TypeCheck(firstArg, (PyTypeObject*)&PythonQtInstanceWrapper_Type)
273 if (PyObject_TypeCheck(firstArg, (PyTypeObject*)&PythonQtInstanceWrapper_Type)
266 && ((PythonQtInstanceWrapper*)firstArg)->classInfo()->inherits(type->classInfo())) {
274 && ((PythonQtInstanceWrapper*)firstArg)->classInfo()->inherits(type->classInfo())) {
267 PythonQtInstanceWrapper* self = (PythonQtInstanceWrapper*)firstArg;
275 PythonQtInstanceWrapper* self = (PythonQtInstanceWrapper*)firstArg;
268 if (!info->isClassDecorator() && (self->_obj==NULL && self->_wrappedPtr==NULL)) {
276 if (!info->isClassDecorator() && (self->_obj==NULL && self->_wrappedPtr==NULL)) {
269 QString error = QString("Trying to call '") + info->slotName() + "' on a destroyed " + self->classInfo()->className() + " object";
277 QString error = QString("Trying to call '") + info->slotName() + "' on a destroyed " + self->classInfo()->className() + " object";
270 PyErr_SetString(PyExc_ValueError, error.toLatin1().data());
278 PyErr_SetString(PyExc_ValueError, error.toLatin1().data());
271 return NULL;
279 return NULL;
272 }
280 }
273 // strip the first argument...
281 // strip the first argument...
274 PyObject* newargs = PyTuple_GetSlice(args, 1, argc);
282 PyObject* newargs = PyTuple_GetSlice(args, 1, argc);
275 PyObject* result = PythonQtSlotFunction_CallImpl(self->classInfo(), self->_obj, info, newargs, kw, self->_wrappedPtr);
283 PyObject* result = PythonQtSlotFunction_CallImpl(self->classInfo(), self->_obj, info, newargs, kw, self->_wrappedPtr);
276 Py_DECREF(newargs);
284 Py_DECREF(newargs);
277 return result;
285 return result;
278 } else {
286 } else {
279 // first arg is not of correct type!
287 // first arg is not of correct type!
280 QString error = "slot " + info->fullSignature() + " requires " + type->classInfo()->className() + " instance as first argument, got " + firstArg->ob_type->tp_name;
288 QString error = "slot " + info->fullSignature() + " requires " + type->classInfo()->className() + " instance as first argument, got " + firstArg->ob_type->tp_name;
281 PyErr_SetString(PyExc_ValueError, error.toLatin1().data());
289 PyErr_SetString(PyExc_ValueError, error.toLatin1().data());
282 return NULL;
290 return NULL;
283 }
291 }
284 } else {
292 } else {
285 // wrong number of args
293 // wrong number of args
286 QString error = "slot " + info->fullSignature() + " requires " + type->classInfo()->className() + " instance as first argument.";
294 QString error = "slot " + info->fullSignature() + " requires " + type->classInfo()->className() + " instance as first argument.";
287 PyErr_SetString(PyExc_ValueError, error.toLatin1().data());
295 PyErr_SetString(PyExc_ValueError, error.toLatin1().data());
288 return NULL;
296 return NULL;
289 }
297 }
290 }
298 }
291 }
299 }
292 return NULL;
300 return NULL;
293 }
301 }
294
302
295 PyObject *PythonQtSlotFunction_CallImpl(PythonQtClassInfo* classInfo, QObject* objectToCall, PythonQtSlotInfo* info, PyObject *args, PyObject * /*kw*/, void* firstArg, void** directReturnValuePointer)
303 PyObject *PythonQtSlotFunction_CallImpl(PythonQtClassInfo* classInfo, QObject* objectToCall, PythonQtSlotInfo* info, PyObject *args, PyObject * /*kw*/, void* firstArg, void** directReturnValuePointer)
296 {
304 {
297 int argc = args?PyTuple_Size(args):0;
305 int argc = args?PyTuple_Size(args):0;
298
306
299 #ifdef PYTHONQT_DEBUG
307 #ifdef PYTHONQT_DEBUG
300 std::cout << "called " << info->metaMethod()->typeName() << " " << info->metaMethod()->signature() << std::endl;
308 std::cout << "called " << info->metaMethod()->typeName() << " " << info->metaMethod()->signature() << std::endl;
301 #endif
309 #endif
302
310
303 PyObject* r = NULL;
311 PyObject* r = NULL;
304 bool ok = false;
312 bool ok = false;
305 if (directReturnValuePointer) {
313 if (directReturnValuePointer) {
306 *directReturnValuePointer = NULL;
314 *directReturnValuePointer = NULL;
307 }
315 }
308 if (info->nextInfo()) {
316 if (info->nextInfo()) {
309 // overloaded slot call, try on all slots with strict conversion first
317 // overloaded slot call, try on all slots with strict conversion first
310 bool strict = true;
318 bool strict = true;
311 PythonQtSlotInfo* i = info;
319 PythonQtSlotInfo* i = info;
312 while (i) {
320 while (i) {
313 bool skipFirst = i->isInstanceDecorator();
321 bool skipFirst = i->isInstanceDecorator();
314 if (i->parameterCount()-1-(skipFirst?1:0) == argc) {
322 if (i->parameterCount()-1-(skipFirst?1:0) == argc) {
315 PyErr_Clear();
323 PyErr_Clear();
316 ok = PythonQtCallSlot(classInfo, objectToCall, args, strict, i, firstArg, &r, directReturnValuePointer);
324 ok = PythonQtCallSlot(classInfo, objectToCall, args, strict, i, firstArg, &r, directReturnValuePointer);
317 if (PyErr_Occurred() || ok) break;
325 if (PyErr_Occurred() || ok) break;
318 }
326 }
319 i = i->nextInfo();
327 i = i->nextInfo();
320 if (!i) {
328 if (!i) {
321 if (strict) {
329 if (strict) {
322 // one more run without being strict
330 // one more run without being strict
323 strict = false;
331 strict = false;
324 i = info;
332 i = info;
325 }
333 }
326 }
334 }
327 }
335 }
328 if (!ok && !PyErr_Occurred()) {
336 if (!ok && !PyErr_Occurred()) {
329 QString e = QString("Could not find matching overload for given arguments:\n" + PythonQtConv::PyObjGetString(args) + "\n The following slots are available:\n");
337 QString e = QString("Could not find matching overload for given arguments:\n" + PythonQtConv::PyObjGetString(args) + "\n The following slots are available:\n");
330 PythonQtSlotInfo* i = info;
338 PythonQtSlotInfo* i = info;
331 while (i) {
339 while (i) {
332 e += QString(i->fullSignature()) + "\n";
340 e += QString(i->fullSignature()) + "\n";
333 i = i->nextInfo();
341 i = i->nextInfo();
334 }
342 }
335 PyErr_SetString(PyExc_ValueError, e.toLatin1().data());
343 PyErr_SetString(PyExc_ValueError, e.toLatin1().data());
336 }
344 }
337 } else {
345 } else {
338 // simple (non-overloaded) slot call
346 // simple (non-overloaded) slot call
339 bool skipFirst = info->isInstanceDecorator();
347 bool skipFirst = info->isInstanceDecorator();
340 if (info->parameterCount()-1-(skipFirst?1:0) == argc) {
348 if (info->parameterCount()-1-(skipFirst?1:0) == argc) {
341 PyErr_Clear();
349 PyErr_Clear();
342 ok = PythonQtCallSlot(classInfo, objectToCall, args, false, info, firstArg, &r, directReturnValuePointer);
350 ok = PythonQtCallSlot(classInfo, objectToCall, args, false, info, firstArg, &r, directReturnValuePointer);
343 if (!ok && !PyErr_Occurred()) {
351 if (!ok && !PyErr_Occurred()) {
344 QString e = QString("Called ") + info->fullSignature() + " with wrong arguments: " + PythonQtConv::PyObjGetString(args);
352 QString e = QString("Called ") + info->fullSignature() + " with wrong arguments: " + PythonQtConv::PyObjGetString(args);
345 PyErr_SetString(PyExc_ValueError, e.toLatin1().data());
353 PyErr_SetString(PyExc_ValueError, e.toLatin1().data());
346 }
354 }
347 } else {
355 } else {
348 QString e = QString("Called ") + info->fullSignature() + " with wrong number of arguments: " + PythonQtConv::PyObjGetString(args);
356 QString e = QString("Called ") + info->fullSignature() + " with wrong number of arguments: " + PythonQtConv::PyObjGetString(args);
349 PyErr_SetString(PyExc_ValueError, e.toLatin1().data());
357 PyErr_SetString(PyExc_ValueError, e.toLatin1().data());
350 }
358 }
351 }
359 }
352
360
353 return r;
361 return r;
354 }
362 }
355
363
356 PyObject *
364 PyObject *
357 PythonQtSlotFunction_New(PythonQtSlotInfo *ml, PyObject *self, PyObject *module)
365 PythonQtSlotFunction_New(PythonQtSlotInfo *ml, PyObject *self, PyObject *module)
358 {
366 {
359 PythonQtSlotFunctionObject *op;
367 PythonQtSlotFunctionObject *op;
360 op = pythonqtslot_free_list;
368 op = pythonqtslot_free_list;
361 if (op != NULL) {
369 if (op != NULL) {
362 pythonqtslot_free_list = (PythonQtSlotFunctionObject *)(op->m_self);
370 pythonqtslot_free_list = (PythonQtSlotFunctionObject *)(op->m_self);
363 PyObject_INIT(op, &PythonQtSlotFunction_Type);
371 PyObject_INIT(op, &PythonQtSlotFunction_Type);
364 }
372 }
365 else {
373 else {
366 op = PyObject_GC_New(PythonQtSlotFunctionObject, &PythonQtSlotFunction_Type);
374 op = PyObject_GC_New(PythonQtSlotFunctionObject, &PythonQtSlotFunction_Type);
367 if (op == NULL)
375 if (op == NULL)
368 return NULL;
376 return NULL;
369 }
377 }
370 op->m_ml = ml;
378 op->m_ml = ml;
371 Py_XINCREF(self);
379 Py_XINCREF(self);
372 op->m_self = self;
380 op->m_self = self;
373 Py_XINCREF(module);
381 Py_XINCREF(module);
374 op->m_module = module;
382 op->m_module = module;
375 PyObject_GC_Track(op);
383 PyObject_GC_Track(op);
376 return (PyObject *)op;
384 return (PyObject *)op;
377 }
385 }
378
386
379 PythonQtSlotInfo*
387 PythonQtSlotInfo*
380 PythonQtSlotFunction_GetSlotInfo(PyObject *op)
388 PythonQtSlotFunction_GetSlotInfo(PyObject *op)
381 {
389 {
382 if (!PythonQtSlotFunction_Check(op)) {
390 if (!PythonQtSlotFunction_Check(op)) {
383 PyErr_Format(PyExc_SystemError, "%s:%d: bad argument to internal function", __FILE__, __LINE__);
391 PyErr_Format(PyExc_SystemError, "%s:%d: bad argument to internal function", __FILE__, __LINE__);
384 return NULL;
392 return NULL;
385 }
393 }
386 return ((PythonQtSlotFunctionObject *)op) -> m_ml;
394 return ((PythonQtSlotFunctionObject *)op) -> m_ml;
387 }
395 }
388
396
389 PyObject *
397 PyObject *
390 PythonQtSlotFunction_GetSelf(PyObject *op)
398 PythonQtSlotFunction_GetSelf(PyObject *op)
391 {
399 {
392 if (!PythonQtSlotFunction_Check(op)) {
400 if (!PythonQtSlotFunction_Check(op)) {
393 PyErr_Format(PyExc_SystemError, "%s:%d: bad argument to internal function", __FILE__, __LINE__);
401 PyErr_Format(PyExc_SystemError, "%s:%d: bad argument to internal function", __FILE__, __LINE__);
394 return NULL;
402 return NULL;
395 }
403 }
396 return ((PythonQtSlotFunctionObject *)op) -> m_self;
404 return ((PythonQtSlotFunctionObject *)op) -> m_self;
397 }
405 }
398
406
399 /* Methods (the standard built-in methods, that is) */
407 /* Methods (the standard built-in methods, that is) */
400
408
401 static void
409 static void
402 meth_dealloc(PythonQtSlotFunctionObject *m)
410 meth_dealloc(PythonQtSlotFunctionObject *m)
403 {
411 {
404 PyObject_GC_UnTrack(m);
412 PyObject_GC_UnTrack(m);
405 Py_XDECREF(m->m_self);
413 Py_XDECREF(m->m_self);
406 Py_XDECREF(m->m_module);
414 Py_XDECREF(m->m_module);
407 m->m_self = (PyObject *)pythonqtslot_free_list;
415 m->m_self = (PyObject *)pythonqtslot_free_list;
408 pythonqtslot_free_list = m;
416 pythonqtslot_free_list = m;
409 }
417 }
410
418
411 static PyObject *
419 static PyObject *
412 meth_get__doc__(PythonQtSlotFunctionObject * /*m*/, void * /*closure*/)
420 meth_get__doc__(PythonQtSlotFunctionObject * /*m*/, void * /*closure*/)
413 {
421 {
414 Py_INCREF(Py_None);
422 Py_INCREF(Py_None);
415 return Py_None;
423 return Py_None;
416 }
424 }
417
425
418 static PyObject *
426 static PyObject *
419 meth_get__name__(PythonQtSlotFunctionObject *m, void * /*closure*/)
427 meth_get__name__(PythonQtSlotFunctionObject *m, void * /*closure*/)
420 {
428 {
421 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
429 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
430 #ifdef PY3K
431 return PyUnicode_FromString(m->m_ml->metaMethod()->methodSignature());
432 #else
422 return PyString_FromString(m->m_ml->metaMethod()->methodSignature());
433 return PyString_FromString(m->m_ml->metaMethod()->methodSignature());
434 #endif
435 #else
436 #ifdef PY3K
437 return PyUnicode_FromString(m->m_ml->metaMethod()->signature());
423 #else
438 #else
424 return PyString_FromString(m->m_ml->metaMethod()->signature());
439 return PyString_FromString(m->m_ml->metaMethod()->signature());
425 #endif
440 #endif
441 #endif
426 }
442 }
427
443
428 static int
444 static int
429 meth_traverse(PythonQtSlotFunctionObject *m, visitproc visit, void *arg)
445 meth_traverse(PythonQtSlotFunctionObject *m, visitproc visit, void *arg)
430 {
446 {
431 int err;
447 int err;
432 if (m->m_self != NULL) {
448 if (m->m_self != NULL) {
433 err = visit(m->m_self, arg);
449 err = visit(m->m_self, arg);
434 if (err)
450 if (err)
435 return err;
451 return err;
436 }
452 }
437 if (m->m_module != NULL) {
453 if (m->m_module != NULL) {
438 err = visit(m->m_module, arg);
454 err = visit(m->m_module, arg);
439 if (err)
455 if (err)
440 return err;
456 return err;
441 }
457 }
442 return 0;
458 return 0;
443 }
459 }
444
460
445 static PyObject *
461 static PyObject *
446 meth_get__self__(PythonQtSlotFunctionObject *m, void * /*closure*/)
462 meth_get__self__(PythonQtSlotFunctionObject *m, void * /*closure*/)
447 {
463 {
448 PyObject *self;
464 PyObject *self;
465 #ifndef PY3K
449 if (PyEval_GetRestricted()) {
466 if (PyEval_GetRestricted()) {
450 PyErr_SetString(PyExc_RuntimeError,
467 PyErr_SetString(PyExc_RuntimeError,
451 "method.__self__ not accessible in restricted mode");
468 "method.__self__ not accessible in restricted mode");
452 return NULL;
469 return NULL;
453 }
470 }
471 #endif
454 self = m->m_self;
472 self = m->m_self;
455 if (self == NULL)
473 if (self == NULL)
456 self = Py_None;
474 self = Py_None;
457 Py_INCREF(self);
475 Py_INCREF(self);
458 return self;
476 return self;
459 }
477 }
460
478
461 static PyGetSetDef meth_getsets [] = {
479 static PyGetSetDef meth_getsets [] = {
462 {const_cast<char*>("__doc__"), (getter)meth_get__doc__, NULL, NULL},
480 {const_cast<char*>("__doc__"), (getter)meth_get__doc__, NULL, NULL},
463 {const_cast<char*>("__name__"), (getter)meth_get__name__, NULL, NULL},
481 {const_cast<char*>("__name__"), (getter)meth_get__name__, NULL, NULL},
464 {const_cast<char*>("__self__"), (getter)meth_get__self__, NULL, NULL},
482 {const_cast<char*>("__self__"), (getter)meth_get__self__, NULL, NULL},
465 {NULL, NULL, NULL,NULL},
483 {NULL, NULL, NULL,NULL},
466 };
484 };
467
485
468 #if PY_MAJOR_VERSION == 2 && PY_MINOR_VERSION < 6
486 #if PY_MAJOR_VERSION == 2 && PY_MINOR_VERSION < 6
469 #define PY_WRITE_RESTRICTED WRITE_RESTRICTED
487 #define PY_WRITE_RESTRICTED WRITE_RESTRICTED
470 #endif
488 #endif
471
489
472 #define OFF(x) offsetof(PythonQtSlotFunctionObject, x)
490 #define OFF(x) offsetof(PythonQtSlotFunctionObject, x)
473
491
474 static PyMemberDef meth_members[] = {
492 static PyMemberDef meth_members[] = {
475 {const_cast<char*>("__module__"), T_OBJECT, OFF(m_module), PY_WRITE_RESTRICTED},
493 {const_cast<char*>("__module__"), T_OBJECT, OFF(m_module), PY_WRITE_RESTRICTED},
476 {NULL}
494 {NULL}
477 };
495 };
478
496
479 static PyObject *PythonQtSlotFunction_parameterTypes(PythonQtSlotFunctionObject* type)
497 static PyObject *PythonQtSlotFunction_parameterTypes(PythonQtSlotFunctionObject* type)
480 {
498 {
481 return PythonQtMemberFunction_parameterTypes(type->m_ml);
499 return PythonQtMemberFunction_parameterTypes(type->m_ml);
482 }
500 }
483
501
484 static PyObject *PythonQtSlotFunction_parameterNames(PythonQtSlotFunctionObject* type)
502 static PyObject *PythonQtSlotFunction_parameterNames(PythonQtSlotFunctionObject* type)
485 {
503 {
486 return PythonQtMemberFunction_parameterNames(type->m_ml);
504 return PythonQtMemberFunction_parameterNames(type->m_ml);
487 }
505 }
488
506
489 static PyObject *PythonQtSlotFunction_typeName(PythonQtSlotFunctionObject* type)
507 static PyObject *PythonQtSlotFunction_typeName(PythonQtSlotFunctionObject* type)
490 {
508 {
491 return PythonQtMemberFunction_typeName(type->m_ml);
509 return PythonQtMemberFunction_typeName(type->m_ml);
492 }
510 }
493
511
494 PyObject *PythonQtMemberFunction_parameterTypes(PythonQtSlotInfo* theInfo)
512 PyObject *PythonQtMemberFunction_parameterTypes(PythonQtSlotInfo* theInfo)
495 {
513 {
496 PythonQtSlotInfo* info = theInfo;
514 PythonQtSlotInfo* info = theInfo;
497 int count = 0;
515 int count = 0;
498 while (info) {
516 while (info) {
499 info = info->nextInfo();
517 info = info->nextInfo();
500 count++;
518 count++;
501 }
519 }
502 info = theInfo;
520 info = theInfo;
503 PyObject* result = PyTuple_New(count);
521 PyObject* result = PyTuple_New(count);
504 for (int j = 0;j<count;j++) {
522 for (int j = 0;j<count;j++) {
505 QList<QByteArray> types = info->metaMethod()->parameterTypes();
523 QList<QByteArray> types = info->metaMethod()->parameterTypes();
506 PyObject* tuple = PyTuple_New(types.count());
524 PyObject* tuple = PyTuple_New(types.count());
507 for (int i = 0; i<types.count();i++) {
525 for (int i = 0; i<types.count();i++) {
526 #ifdef PY3K
527 PyTuple_SET_ITEM(tuple, i, PyUnicode_FromString(types.at(i).constData()));
528 #else
508 PyTuple_SET_ITEM(tuple, i, PyString_FromString(types.at(i).constData()));
529 PyTuple_SET_ITEM(tuple, i, PyString_FromString(types.at(i).constData()));
530 #endif
509 }
531 }
510 info = info->nextInfo();
532 info = info->nextInfo();
511 PyTuple_SET_ITEM(result, j, tuple);
533 PyTuple_SET_ITEM(result, j, tuple);
512 }
534 }
513 return result;
535 return result;
514 }
536 }
515
537
516 PyObject *PythonQtMemberFunction_parameterNames(PythonQtSlotInfo* theInfo)
538 PyObject *PythonQtMemberFunction_parameterNames(PythonQtSlotInfo* theInfo)
517 {
539 {
518 PythonQtSlotInfo* info = theInfo;
540 PythonQtSlotInfo* info = theInfo;
519 int count = 0;
541 int count = 0;
520 while (info) {
542 while (info) {
521 info = info->nextInfo();
543 info = info->nextInfo();
522 count++;
544 count++;
523 }
545 }
524 info = theInfo;
546 info = theInfo;
525 PyObject* result = PyTuple_New(count);
547 PyObject* result = PyTuple_New(count);
526 for (int j = 0;j<count;j++) {
548 for (int j = 0;j<count;j++) {
527 QList<QByteArray> names = info->metaMethod()->parameterNames();
549 QList<QByteArray> names = info->metaMethod()->parameterNames();
528 PyObject* tuple = PyTuple_New(names.count());
550 PyObject* tuple = PyTuple_New(names.count());
529 for (int i = 0; i<names.count();i++) {
551 for (int i = 0; i<names.count();i++) {
552 #ifdef PY3K
553 PyTuple_SET_ITEM(tuple, i, PyUnicode_FromString(names.at(i).constData()));
554 #else
530 PyTuple_SET_ITEM(tuple, i, PyString_FromString(names.at(i).constData()));
555 PyTuple_SET_ITEM(tuple, i, PyString_FromString(names.at(i).constData()));
556 #endif
531 }
557 }
532 info = info->nextInfo();
558 info = info->nextInfo();
533 PyTuple_SET_ITEM(result, j, tuple);
559 PyTuple_SET_ITEM(result, j, tuple);
534 }
560 }
535 return result;
561 return result;
536 }
562 }
537
563
538 PyObject *PythonQtMemberFunction_typeName(PythonQtSlotInfo* theInfo)
564 PyObject *PythonQtMemberFunction_typeName(PythonQtSlotInfo* theInfo)
539 {
565 {
540 PythonQtSlotInfo* info = theInfo;
566 PythonQtSlotInfo* info = theInfo;
541 int count = 0;
567 int count = 0;
542 while (info) {
568 while (info) {
543 info = info->nextInfo();
569 info = info->nextInfo();
544 count++;
570 count++;
545 }
571 }
546 info = theInfo;
572 info = theInfo;
547 PyObject* result = PyTuple_New(count);
573 PyObject* result = PyTuple_New(count);
548 for (int j = 0;j<count;j++) {
574 for (int j = 0;j<count;j++) {
549 QByteArray name = info->metaMethod()->typeName();
575 QByteArray name = info->metaMethod()->typeName();
576 #ifdef PY3K
577 PyTuple_SET_ITEM(result, j, PyUnicode_FromString(name.constData()));
578 #else
550 PyTuple_SET_ITEM(result, j, PyString_FromString(name.constData()));
579 PyTuple_SET_ITEM(result, j, PyString_FromString(name.constData()));
580 #endif
551 info = info->nextInfo();
581 info = info->nextInfo();
552 }
582 }
553 return result;
583 return result;
554 }
584 }
555
585
556 static PyMethodDef meth_methods[] = {
586 static PyMethodDef meth_methods[] = {
557 {"parameterTypes", (PyCFunction)PythonQtSlotFunction_parameterTypes, METH_NOARGS,
587 {"parameterTypes", (PyCFunction)PythonQtSlotFunction_parameterTypes, METH_NOARGS,
558 "Returns a tuple of tuples of the C++ parameter types for all overloads of the slot"
588 "Returns a tuple of tuples of the C++ parameter types for all overloads of the slot"
559 },
589 },
560 {"parameterNames", (PyCFunction)PythonQtSlotFunction_parameterNames, METH_NOARGS,
590 {"parameterNames", (PyCFunction)PythonQtSlotFunction_parameterNames, METH_NOARGS,
561 "Returns a tuple of tuples of the C++ parameter type names (if available), for all overloads of the slot"
591 "Returns a tuple of tuples of the C++ parameter type names (if available), for all overloads of the slot"
562 },
592 },
563 {"typeName", (PyCFunction)PythonQtSlotFunction_typeName, METH_NOARGS,
593 {"typeName", (PyCFunction)PythonQtSlotFunction_typeName, METH_NOARGS,
564 "Returns a tuple of the C++ return value types of each slot overload"
594 "Returns a tuple of the C++ return value types of each slot overload"
565 },
595 },
566 {NULL, NULL, 0 , NULL} /* Sentinel */
596 {NULL, NULL, 0 , NULL} /* Sentinel */
567 };
597 };
568
598
569 static PyObject *
599 static PyObject *
570 meth_repr(PythonQtSlotFunctionObject *f)
600 meth_repr(PythonQtSlotFunctionObject *f)
571 {
601 {
572 if (f->m_self->ob_type == &PythonQtClassWrapper_Type) {
602 if (f->m_self->ob_type == &PythonQtClassWrapper_Type) {
573 PythonQtClassWrapper* self = (PythonQtClassWrapper*) f->m_self;
603 PythonQtClassWrapper* self = (PythonQtClassWrapper*) f->m_self;
604 #ifdef PY3K
605 return PyUnicode_FromFormat("<unbound qt slot %s of %s type>",
606 #else
574 return PyString_FromFormat("<unbound qt slot %s of %s type>",
607 return PyString_FromFormat("<unbound qt slot %s of %s type>",
608 #endif
575 f->m_ml->slotName().data(),
609 f->m_ml->slotName().data(),
576 self->classInfo()->className());
610 self->classInfo()->className());
577 } else {
611 } else {
612 #ifdef PY3K
613 return PyUnicode_FromFormat("<qt slot %s of %s instance at %p",
614 #else
578 return PyString_FromFormat("<qt slot %s of %s instance at %p>",
615 return PyString_FromFormat("<qt slot %s of %s instance at %p>",
616 #endif
579 f->m_ml->slotName().data(),
617 f->m_ml->slotName().data(),
580 f->m_self->ob_type->tp_name,
618 f->m_self->ob_type->tp_name,
581 f->m_self);
619 f->m_self);
582 }
620 }
583 }
621 }
584
622
585 static int
623 static int
586 meth_compare(PythonQtSlotFunctionObject *a, PythonQtSlotFunctionObject *b)
624 meth_compare(PythonQtSlotFunctionObject *a, PythonQtSlotFunctionObject *b)
587 {
625 {
588 if (a->m_self != b->m_self)
626 if (a->m_self != b->m_self)
589 return (a->m_self < b->m_self) ? -1 : 1;
627 return (a->m_self < b->m_self) ? -1 : 1;
590 if (a->m_ml == b->m_ml)
628 if (a->m_ml == b->m_ml)
591 return 0;
629 return 0;
592 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
630 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
593 if (strcmp(a->m_ml->metaMethod()->methodSignature(), b->m_ml->metaMethod()->methodSignature()) < 0)
631 if (strcmp(a->m_ml->metaMethod()->methodSignature(), b->m_ml->metaMethod()->methodSignature()) < 0)
594 #else
632 #else
595 if (strcmp(a->m_ml->metaMethod()->signature(), b->m_ml->metaMethod()->signature()) < 0)
633 if (strcmp(a->m_ml->metaMethod()->signature(), b->m_ml->metaMethod()->signature()) < 0)
596 #endif
634 #endif
597 return -1;
635 return -1;
598 else
636 else
599 return 1;
637 return 1;
600 }
638 }
601
639
602 static long
640 static long
603 meth_hash(PythonQtSlotFunctionObject *a)
641 meth_hash(PythonQtSlotFunctionObject *a)
604 {
642 {
605 long x,y;
643 long x,y;
606 if (a->m_self == NULL)
644 if (a->m_self == NULL)
607 x = 0;
645 x = 0;
608 else {
646 else {
609 x = PyObject_Hash(a->m_self);
647 x = PyObject_Hash(a->m_self);
610 if (x == -1)
648 if (x == -1)
611 return -1;
649 return -1;
612 }
650 }
613 y = _Py_HashPointer((void*)(a->m_ml));
651 y = _Py_HashPointer((void*)(a->m_ml));
614 if (y == -1)
652 if (y == -1)
615 return -1;
653 return -1;
616 x ^= y;
654 x ^= y;
617 if (x == -1)
655 if (x == -1)
618 x = -2;
656 x = -2;
619 return x;
657 return x;
620 }
658 }
621
659
660 // for python 3.x
661 static PyObject*
662 meth_richcompare(PythonQtSlotFunctionObject *a, PythonQtSlotFunctionObject *b, int op)
663 {
664 int x = meth_compare(a, b);
665 bool r;
666 if (op == Py_LT)
667 r = x < 0;
668 else if (op == Py_LE)
669 r = x < 1;
670 else if (op == Py_EQ)
671 r = x == 0;
672 else if (op == Py_NE)
673 r = x != 0;
674 else if (op == Py_GE)
675 r = x > -1;
676 else if (op == Py_GT)
677 r = x > 0;
678 if (r)
679 Py_RETURN_TRUE;
680 else
681 Py_RETURN_FALSE;
682 }
683
622
684
623 PyTypeObject PythonQtSlotFunction_Type = {
685 PyTypeObject PythonQtSlotFunction_Type = {
624 PyObject_HEAD_INIT(&PyType_Type)
686 PyVarObject_HEAD_INIT(&PyType_Type, 0)
625 0,
626 "builtin_qt_slot",
687 "builtin_qt_slot",
627 sizeof(PythonQtSlotFunctionObject),
688 sizeof(PythonQtSlotFunctionObject),
628 0,
689 0,
629 (destructor)meth_dealloc, /* tp_dealloc */
690 (destructor)meth_dealloc, /* tp_dealloc */
630 0, /* tp_print */
691 0, /* tp_print */
631 0, /* tp_getattr */
692 0, /* tp_getattr */
632 0, /* tp_setattr */
693 0, /* tp_setattr */
694 #ifdef PY3K
695 0,
696 #else
633 (cmpfunc)meth_compare, /* tp_compare */
697 (cmpfunc)meth_compare, /* tp_compare */
698 #endif
634 (reprfunc)meth_repr, /* tp_repr */
699 (reprfunc)meth_repr, /* tp_repr */
635 0, /* tp_as_number */
700 0, /* tp_as_number */
636 0, /* tp_as_sequence */
701 0, /* tp_as_sequence */
637 0, /* tp_as_mapping */
702 0, /* tp_as_mapping */
638 (hashfunc)meth_hash, /* tp_hash */
703 (hashfunc)meth_hash, /* tp_hash */
639 PythonQtSlotFunction_Call, /* tp_call */
704 PythonQtSlotFunction_Call, /* tp_call */
640 0, /* tp_str */
705 0, /* tp_str */
641 PyObject_GenericGetAttr, /* tp_getattro */
706 PyObject_GenericGetAttr, /* tp_getattro */
642 0, /* tp_setattro */
707 0, /* tp_setattro */
643 0, /* tp_as_buffer */
708 0, /* tp_as_buffer */
644 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_HAVE_GC,/* tp_flags */
709 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_HAVE_GC,/* tp_flags */
645 0, /* tp_doc */
710 0, /* tp_doc */
646 (traverseproc)meth_traverse, /* tp_traverse */
711 (traverseproc)meth_traverse, /* tp_traverse */
647 0, /* tp_clear */
712 0, /* tp_clear */
648 0, /* tp_richcompare */
713 (richcmpfunc)meth_richcompare, /* tp_richcompare */
649 0, /* tp_weaklistoffset */
714 0, /* tp_weaklistoffset */
650 0, /* tp_iter */
715 0, /* tp_iter */
651 0, /* tp_iternext */
716 0, /* tp_iternext */
652 meth_methods, /* tp_methods */
717 meth_methods, /* tp_methods */
653 meth_members, /* tp_members */
718 meth_members, /* tp_members */
654 meth_getsets, /* tp_getset */
719 meth_getsets, /* tp_getset */
655 0, /* tp_base */
720 0, /* tp_base */
656 0, /* tp_dict */
721 0, /* tp_dict */
657 };
722 };
658
723
659 /* Clear out the free list */
724 /* Clear out the free list */
660
725
661 void
726 void
662 PythonQtSlotFunction_Fini(void)
727 PythonQtSlotFunction_Fini(void)
663 {
728 {
664 while (pythonqtslot_free_list) {
729 while (pythonqtslot_free_list) {
665 PythonQtSlotFunctionObject *v = pythonqtslot_free_list;
730 PythonQtSlotFunctionObject *v = pythonqtslot_free_list;
666 pythonqtslot_free_list = (PythonQtSlotFunctionObject *)(v->m_self);
731 pythonqtslot_free_list = (PythonQtSlotFunctionObject *)(v->m_self);
667 PyObject_GC_Del(v);
732 PyObject_GC_Del(v);
668 }
733 }
669 }
734 }
670
735
@@ -1,327 +1,342
1 /*
1 /*
2 *
2 *
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
4 *
4 *
5 * This library is free software; you can redistribute it and/or
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
8 * version 2.1 of the License, or (at your option) any later version.
9 *
9 *
10 * This library is distributed in the hope that it will be useful,
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
13 * Lesser General Public License for more details.
14 *
14 *
15 * Further, this software is distributed without any warranty that it is
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
20 * other software, or any other product whatsoever.
21 *
21 *
22 * You should have received a copy of the GNU Lesser General Public
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
25 *
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
27 * 28359 Bremen, Germany or:
27 * 28359 Bremen, Germany or:
28 *
28 *
29 * http://www.mevis.de
29 * http://www.mevis.de
30 *
30 *
31 */
31 */
32
32
33 //----------------------------------------------------------------------------------
33 //----------------------------------------------------------------------------------
34 /*!
34 /*!
35 // \file PythonQtStdDecorators.cpp
35 // \file PythonQtStdDecorators.cpp
36 // \author Florian Link
36 // \author Florian Link
37 // \author Last changed by $Author: florian $
37 // \author Last changed by $Author: florian $
38 // \date 2007-04
38 // \date 2007-04
39 */
39 */
40 //----------------------------------------------------------------------------------
40 //----------------------------------------------------------------------------------
41
41
42 #include "PythonQtStdDecorators.h"
42 #include "PythonQtStdDecorators.h"
43 #include "PythonQt.h"
43 #include "PythonQt.h"
44 #include "PythonQtClassInfo.h"
44 #include "PythonQtClassInfo.h"
45 #include <QCoreApplication>
45 #include <QCoreApplication>
46
46
47 bool PythonQtStdDecorators::connect(QObject* sender, const QByteArray& signal, PyObject* callable)
47 bool PythonQtStdDecorators::connect(QObject* sender, const QByteArray& signal, PyObject* callable)
48 {
48 {
49 bool result = false;
49 bool result = false;
50 QByteArray signalTmp;
50 QByteArray signalTmp;
51 char first = signal.at(0);
51 char first = signal.at(0);
52 if (first>='0' && first<='9') {
52 if (first>='0' && first<='9') {
53 signalTmp = signal;
53 signalTmp = signal;
54 } else {
54 } else {
55 signalTmp = "2" + signal;
55 signalTmp = "2" + signal;
56 }
56 }
57
57
58 if (sender) {
58 if (sender) {
59 result = PythonQt::self()->addSignalHandler(sender, signalTmp, callable);
59 result = PythonQt::self()->addSignalHandler(sender, signalTmp, callable);
60 if (!result) {
60 if (!result) {
61 if (sender->metaObject()->indexOfSignal(QMetaObject::normalizedSignature(signalTmp.constData()+1)) == -1) {
61 if (sender->metaObject()->indexOfSignal(QMetaObject::normalizedSignature(signalTmp.constData()+1)) == -1) {
62 qWarning("PythonQt: QObject::connect() signal '%s' does not exist on %s", signal.constData(), sender->metaObject()->className());
62 qWarning("PythonQt: QObject::connect() signal '%s' does not exist on %s", signal.constData(), sender->metaObject()->className());
63 }
63 }
64 }
64 }
65 }
65 }
66 return result;
66 return result;
67 }
67 }
68
68
69 bool PythonQtStdDecorators::connect(QObject* sender, const QByteArray& signal, QObject* receiver, const QByteArray& slot, Qt::ConnectionType type)
69 bool PythonQtStdDecorators::connect(QObject* sender, const QByteArray& signal, QObject* receiver, const QByteArray& slot, Qt::ConnectionType type)
70 {
70 {
71 bool r = false;
71 bool r = false;
72 if (sender && receiver) {
72 if (sender && receiver) {
73 QByteArray signalTmp;
73 QByteArray signalTmp;
74 char first = signal.at(0);
74 char first = signal.at(0);
75 if (first>='0' && first<='9') {
75 if (first>='0' && first<='9') {
76 signalTmp = signal;
76 signalTmp = signal;
77 } else {
77 } else {
78 signalTmp = "2" + signal;
78 signalTmp = "2" + signal;
79 }
79 }
80
80
81 QByteArray slotTmp;
81 QByteArray slotTmp;
82 first = slot.at(0);
82 first = slot.at(0);
83 if (first>='0' && first<='9') {
83 if (first>='0' && first<='9') {
84 slotTmp = slot;
84 slotTmp = slot;
85 } else {
85 } else {
86 slotTmp = "1" + slot;
86 slotTmp = "1" + slot;
87 }
87 }
88 r = QObject::connect(sender, signalTmp, receiver, slotTmp, type);
88 r = QObject::connect(sender, signalTmp, receiver, slotTmp, type);
89 }
89 }
90 return r;
90 return r;
91 }
91 }
92
92
93 bool PythonQtStdDecorators::disconnect(QObject* sender, const QByteArray& signal, PyObject* callable)
93 bool PythonQtStdDecorators::disconnect(QObject* sender, const QByteArray& signal, PyObject* callable)
94 {
94 {
95 bool result = false;
95 bool result = false;
96 QByteArray signalTmp;
96 QByteArray signalTmp;
97 char first = signal.at(0);
97 char first = signal.at(0);
98 if (first>='0' && first<='9') {
98 if (first>='0' && first<='9') {
99 signalTmp = signal;
99 signalTmp = signal;
100 } else {
100 } else {
101 signalTmp = "2" + signal;
101 signalTmp = "2" + signal;
102 }
102 }
103 if (sender) {
103 if (sender) {
104 result = PythonQt::self()->removeSignalHandler(sender, signalTmp, callable);
104 result = PythonQt::self()->removeSignalHandler(sender, signalTmp, callable);
105 if (callable == NULL) {
105 if (callable == NULL) {
106 result |= QObject::disconnect(sender, signalTmp, NULL, NULL);
106 result |= QObject::disconnect(sender, signalTmp, NULL, NULL);
107 }
107 }
108 if (!result) {
108 if (!result) {
109 if (sender->metaObject()->indexOfSignal(QMetaObject::normalizedSignature(signalTmp.constData()+1)) == -1) {
109 if (sender->metaObject()->indexOfSignal(QMetaObject::normalizedSignature(signalTmp.constData()+1)) == -1) {
110 qWarning("PythonQt: QObject::disconnect() signal '%s' does not exist on %s", signal.constData(), sender->metaObject()->className());
110 qWarning("PythonQt: QObject::disconnect() signal '%s' does not exist on %s", signal.constData(), sender->metaObject()->className());
111 }
111 }
112 }
112 }
113 }
113 }
114 return result;
114 return result;
115 }
115 }
116
116
117 bool PythonQtStdDecorators::disconnect(QObject* sender, const QByteArray& signal, QObject* receiver, const QByteArray& slot)
117 bool PythonQtStdDecorators::disconnect(QObject* sender, const QByteArray& signal, QObject* receiver, const QByteArray& slot)
118 {
118 {
119 bool r = false;
119 bool r = false;
120 if (sender && receiver) {
120 if (sender && receiver) {
121 QByteArray signalTmp;
121 QByteArray signalTmp;
122 char first = signal.at(0);
122 char first = signal.at(0);
123 if (first>='0' && first<='9') {
123 if (first>='0' && first<='9') {
124 signalTmp = signal;
124 signalTmp = signal;
125 } else {
125 } else {
126 signalTmp = "2" + signal;
126 signalTmp = "2" + signal;
127 }
127 }
128
128
129 QByteArray slotTmp;
129 QByteArray slotTmp;
130 first = slot.at(0);
130 first = slot.at(0);
131 if (first>='0' && first<='9') {
131 if (first>='0' && first<='9') {
132 slotTmp = slot;
132 slotTmp = slot;
133 } else {
133 } else {
134 slotTmp = "1" + slot;
134 slotTmp = "1" + slot;
135 }
135 }
136
136
137 r = QObject::disconnect(sender, signalTmp, receiver, slotTmp);
137 r = QObject::disconnect(sender, signalTmp, receiver, slotTmp);
138 }
138 }
139 return r;
139 return r;
140 }
140 }
141
141
142 QObject* PythonQtStdDecorators::parent(QObject* o) {
142 QObject* PythonQtStdDecorators::parent(QObject* o) {
143 return o->parent();
143 return o->parent();
144 }
144 }
145
145
146 void PythonQtStdDecorators::setParent(QObject* o, QObject* parent)
146 void PythonQtStdDecorators::setParent(QObject* o, QObject* parent)
147 {
147 {
148 o->setParent(parent);
148 o->setParent(parent);
149 }
149 }
150
150
151 const QObjectList* PythonQtStdDecorators::children(QObject* o)
151 const QObjectList* PythonQtStdDecorators::children(QObject* o)
152 {
152 {
153 return &o->children();
153 return &o->children();
154 }
154 }
155
155
156 bool PythonQtStdDecorators::setProperty(QObject* o, const char* name, const QVariant& value)
156 bool PythonQtStdDecorators::setProperty(QObject* o, const char* name, const QVariant& value)
157 {
157 {
158 return o->setProperty(name, value);
158 return o->setProperty(name, value);
159 }
159 }
160
160
161 QVariant PythonQtStdDecorators::property(QObject* o, const char* name)
161 QVariant PythonQtStdDecorators::property(QObject* o, const char* name)
162 {
162 {
163 return o->property(name);
163 return o->property(name);
164 }
164 }
165
165
166 QString PythonQtStdDecorators::tr(QObject* obj, const QByteArray& text, const QByteArray& ambig, int n)
166 QString PythonQtStdDecorators::tr(QObject* obj, const QByteArray& text, const QByteArray& ambig, int n)
167 {
167 {
168 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
168 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
169 return QCoreApplication::translate(obj->metaObject()->className(), text.constData(), ambig.constData(), n);
169 return QCoreApplication::translate(obj->metaObject()->className(), text.constData(), ambig.constData(), n);
170 #else
170 #else
171 return QCoreApplication::translate(obj->metaObject()->className(), text.constData(), ambig.constData(), QCoreApplication::CodecForTr, n);
171 return QCoreApplication::translate(obj->metaObject()->className(), text.constData(), ambig.constData(), QCoreApplication::CodecForTr, n);
172 #endif
172 #endif
173 }
173 }
174
174
175 QObject* PythonQtStdDecorators::findChild(QObject* parent, PyObject* type, const QString& name)
175 QObject* PythonQtStdDecorators::findChild(QObject* parent, PyObject* type, const QString& name)
176 {
176 {
177 const QMetaObject* meta = NULL;
177 const QMetaObject* meta = NULL;
178 const char* typeName = NULL;
178 const char* typeName = NULL;
179
179
180 if (PyObject_TypeCheck(type, &PythonQtClassWrapper_Type)) {
180 if (PyObject_TypeCheck(type, &PythonQtClassWrapper_Type)) {
181 meta = ((PythonQtClassWrapper*)type)->classInfo()->metaObject();
181 meta = ((PythonQtClassWrapper*)type)->classInfo()->metaObject();
182 } else if (PyObject_TypeCheck(type, &PythonQtInstanceWrapper_Type)) {
182 } else if (PyObject_TypeCheck(type, &PythonQtInstanceWrapper_Type)) {
183 meta = ((PythonQtInstanceWrapper*)type)->classInfo()->metaObject();
183 meta = ((PythonQtInstanceWrapper*)type)->classInfo()->metaObject();
184 #ifdef PY3K
185 } else if (PyUnicode_Check(type)) {
186 typeName = PyUnicode_AsUTF8(type);
187 #else
184 } else if (PyString_Check(type)) {
188 } else if (PyString_Check(type)) {
185 typeName = PyString_AsString(type);
189 typeName = PyString_AsString(type);
190 #endif
186 }
191 }
187
192
188 if (!typeName && !meta)
193 if (!typeName && !meta)
189 return NULL;
194 return NULL;
190
195
191 return findChild(parent, typeName, meta, name);
196 return findChild(parent, typeName, meta, name);
192 }
197 }
193
198
194 QList<QObject*> PythonQtStdDecorators::findChildren(QObject* parent, PyObject* type, const QString& name)
199 QList<QObject*> PythonQtStdDecorators::findChildren(QObject* parent, PyObject* type, const QString& name)
195 {
200 {
196 const QMetaObject* meta = NULL;
201 const QMetaObject* meta = NULL;
197 const char* typeName = NULL;
202 const char* typeName = NULL;
198
203
199 if (PyObject_TypeCheck(type, &PythonQtClassWrapper_Type)) {
204 if (PyObject_TypeCheck(type, &PythonQtClassWrapper_Type)) {
200 meta = ((PythonQtClassWrapper*)type)->classInfo()->metaObject();
205 meta = ((PythonQtClassWrapper*)type)->classInfo()->metaObject();
201 } else if (PyObject_TypeCheck(type, &PythonQtInstanceWrapper_Type)) {
206 } else if (PyObject_TypeCheck(type, &PythonQtInstanceWrapper_Type)) {
202 meta = ((PythonQtInstanceWrapper*)type)->classInfo()->metaObject();
207 meta = ((PythonQtInstanceWrapper*)type)->classInfo()->metaObject();
208 #ifdef PY3K
209 } else if (PyUnicode_Check(type)) {
210 typeName = PyUnicode_AsUTF8(type);
211 #else
203 } else if (PyString_Check(type)) {
212 } else if (PyString_Check(type)) {
204 typeName = PyString_AsString(type);
213 typeName = PyString_AsString(type);
214 #endif
205 }
215 }
206
216
207 QList<QObject*> list;
217 QList<QObject*> list;
208
218
209 if (!typeName && !meta)
219 if (!typeName && !meta)
210 return list;
220 return list;
211
221
212 findChildren(parent, typeName, meta, name, list);
222 findChildren(parent, typeName, meta, name, list);
213
223
214 return list;
224 return list;
215 }
225 }
216
226
217 QList<QObject*> PythonQtStdDecorators::findChildren(QObject* parent, PyObject* type, const QRegExp& regExp)
227 QList<QObject*> PythonQtStdDecorators::findChildren(QObject* parent, PyObject* type, const QRegExp& regExp)
218 {
228 {
219 const QMetaObject* meta = NULL;
229 const QMetaObject* meta = NULL;
220 const char* typeName = NULL;
230 const char* typeName = NULL;
221
231
222 if (PyObject_TypeCheck(type, &PythonQtClassWrapper_Type)) {
232 if (PyObject_TypeCheck(type, &PythonQtClassWrapper_Type)) {
223 meta = ((PythonQtClassWrapper*)type)->classInfo()->metaObject();
233 meta = ((PythonQtClassWrapper*)type)->classInfo()->metaObject();
224 } else if (PyObject_TypeCheck(type, &PythonQtInstanceWrapper_Type)) {
234 } else if (PyObject_TypeCheck(type, &PythonQtInstanceWrapper_Type)) {
225 meta = ((PythonQtInstanceWrapper*)type)->classInfo()->metaObject();
235 meta = ((PythonQtInstanceWrapper*)type)->classInfo()->metaObject();
236 #ifdef PY3K
237 } else if (PyUnicode_Check(type)) {
238 typeName = PyUnicode_AsUTF8(type);
239 #else
226 } else if (PyString_Check(type)) {
240 } else if (PyString_Check(type)) {
227 typeName = PyString_AsString(type);
241 typeName = PyString_AsString(type);
242 #endif
228 }
243 }
229
244
230 QList<QObject*> list;
245 QList<QObject*> list;
231
246
232 if (!typeName && !meta)
247 if (!typeName && !meta)
233 return list;
248 return list;
234
249
235 findChildren(parent, typeName, meta, regExp, list);
250 findChildren(parent, typeName, meta, regExp, list);
236
251
237 return list;
252 return list;
238 }
253 }
239
254
240 QObject* PythonQtStdDecorators::findChild(QObject* parent, const char* typeName, const QMetaObject* meta, const QString& name)
255 QObject* PythonQtStdDecorators::findChild(QObject* parent, const char* typeName, const QMetaObject* meta, const QString& name)
241 {
256 {
242 const QObjectList &children = parent->children();
257 const QObjectList &children = parent->children();
243
258
244 int i;
259 int i;
245 for (i = 0; i < children.size(); ++i) {
260 for (i = 0; i < children.size(); ++i) {
246 QObject* obj = children.at(i);
261 QObject* obj = children.at(i);
247
262
248 if (!obj)
263 if (!obj)
249 return NULL;
264 return NULL;
250
265
251 // Skip if the name doesn't match.
266 // Skip if the name doesn't match.
252 if (!name.isNull() && obj->objectName() != name)
267 if (!name.isNull() && obj->objectName() != name)
253 continue;
268 continue;
254
269
255 if ((typeName && obj->inherits(typeName)) ||
270 if ((typeName && obj->inherits(typeName)) ||
256 (meta && meta->cast(obj)))
271 (meta && meta->cast(obj)))
257 return obj;
272 return obj;
258 }
273 }
259
274
260 for (i = 0; i < children.size(); ++i) {
275 for (i = 0; i < children.size(); ++i) {
261 QObject* obj = findChild(children.at(i), typeName, meta, name);
276 QObject* obj = findChild(children.at(i), typeName, meta, name);
262
277
263 if (obj != NULL)
278 if (obj != NULL)
264 return obj;
279 return obj;
265 }
280 }
266
281
267 return NULL;
282 return NULL;
268 }
283 }
269
284
270 int PythonQtStdDecorators::findChildren(QObject* parent, const char* typeName, const QMetaObject* meta, const QString& name, QList<QObject*>& list)
285 int PythonQtStdDecorators::findChildren(QObject* parent, const char* typeName, const QMetaObject* meta, const QString& name, QList<QObject*>& list)
271 {
286 {
272 const QObjectList& children = parent->children();
287 const QObjectList& children = parent->children();
273 int i;
288 int i;
274
289
275 for (i = 0; i < children.size(); ++i) {
290 for (i = 0; i < children.size(); ++i) {
276 QObject* obj = children.at(i);
291 QObject* obj = children.at(i);
277
292
278 if (!obj)
293 if (!obj)
279 return -1;
294 return -1;
280
295
281 // Skip if the name doesn't match.
296 // Skip if the name doesn't match.
282 if (!name.isNull() && obj->objectName() != name)
297 if (!name.isNull() && obj->objectName() != name)
283 continue;
298 continue;
284
299
285 if ((typeName && obj->inherits(typeName)) ||
300 if ((typeName && obj->inherits(typeName)) ||
286 (meta && meta->cast(obj))) {
301 (meta && meta->cast(obj))) {
287 list += obj;
302 list += obj;
288 }
303 }
289
304
290 if (findChildren(obj, typeName, meta, name, list) < 0)
305 if (findChildren(obj, typeName, meta, name, list) < 0)
291 return -1;
306 return -1;
292 }
307 }
293
308
294 return 0;
309 return 0;
295 }
310 }
296
311
297 int PythonQtStdDecorators::findChildren(QObject* parent, const char* typeName, const QMetaObject* meta, const QRegExp& regExp, QList<QObject*>& list)
312 int PythonQtStdDecorators::findChildren(QObject* parent, const char* typeName, const QMetaObject* meta, const QRegExp& regExp, QList<QObject*>& list)
298 {
313 {
299 const QObjectList& children = parent->children();
314 const QObjectList& children = parent->children();
300 int i;
315 int i;
301
316
302 for (i = 0; i < children.size(); ++i) {
317 for (i = 0; i < children.size(); ++i) {
303 QObject* obj = children.at(i);
318 QObject* obj = children.at(i);
304
319
305 if (!obj)
320 if (!obj)
306 return -1;
321 return -1;
307
322
308 // Skip if the name doesn't match.
323 // Skip if the name doesn't match.
309 if (regExp.indexIn(obj->objectName()) == -1)
324 if (regExp.indexIn(obj->objectName()) == -1)
310 continue;
325 continue;
311
326
312 if ((typeName && obj->inherits(typeName)) ||
327 if ((typeName && obj->inherits(typeName)) ||
313 (meta && meta->cast(obj))) {
328 (meta && meta->cast(obj))) {
314 list += obj;
329 list += obj;
315 }
330 }
316
331
317 if (findChildren(obj, typeName, meta, regExp, list) < 0)
332 if (findChildren(obj, typeName, meta, regExp, list) < 0)
318 return -1;
333 return -1;
319 }
334 }
320
335
321 return 0;
336 return 0;
322 }
337 }
323
338
324 const QMetaObject* PythonQtStdDecorators::metaObject( QObject* obj )
339 const QMetaObject* PythonQtStdDecorators::metaObject( QObject* obj )
325 {
340 {
326 return obj->metaObject();
341 return obj->metaObject();
327 } No newline at end of file
342 }
@@ -1,118 +1,117
1 /*
1 /*
2 *
2 *
3 * Copyright (C) 2011 MeVis Medical Solutions AG All Rights Reserved.
3 * Copyright (C) 2011 MeVis Medical Solutions AG All Rights Reserved.
4 *
4 *
5 * This library is free software; you can redistribute it and/or
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
8 * version 2.1 of the License, or (at your option) any later version.
9 *
9 *
10 * This library is distributed in the hope that it will be useful,
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
13 * Lesser General Public License for more details.
14 *
14 *
15 * Further, this software is distributed without any warranty that it is
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
20 * other software, or any other product whatsoever.
21 *
21 *
22 * You should have received a copy of the GNU Lesser General Public
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
25 *
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
27 * 28359 Bremen, Germany or:
27 * 28359 Bremen, Germany or:
28 *
28 *
29 * http://www.mevis.de
29 * http://www.mevis.de
30 *
30 *
31 */
31 */
32
32
33 //----------------------------------------------------------------------------------
33 //----------------------------------------------------------------------------------
34 /*!
34 /*!
35 // \file PythonQtStdIn.cpp
35 // \file PythonQtStdIn.cpp
36 // \author Jean-Christophe Fillion-Robin
36 // \author Jean-Christophe Fillion-Robin
37 // \author Last changed by $Author: jcfr $
37 // \author Last changed by $Author: jcfr $
38 // \date 2011
38 // \date 2011
39 */
39 */
40 //----------------------------------------------------------------------------------
40 //----------------------------------------------------------------------------------
41
41
42 #include "PythonQtStdIn.h"
42 #include "PythonQtStdIn.h"
43
43
44 static PyObject *PythonQtStdInRedirect_new(PyTypeObject *type, PyObject * /*args*/, PyObject * /*kwds*/)
44 static PyObject *PythonQtStdInRedirect_new(PyTypeObject *type, PyObject * /*args*/, PyObject * /*kwds*/)
45 {
45 {
46 PythonQtStdInRedirect *self;
46 PythonQtStdInRedirect *self;
47 self = (PythonQtStdInRedirect *)type->tp_alloc(type, 0);
47 self = (PythonQtStdInRedirect *)type->tp_alloc(type, 0);
48 self->_cb = NULL;
48 self->_cb = NULL;
49 self->_callData = NULL;
49 self->_callData = NULL;
50
50
51 return (PyObject *)self;
51 return (PyObject *)self;
52 }
52 }
53
53
54 static PyObject *PythonQtStdInRedirect_readline(PyObject * self, PyObject * args)
54 static PyObject *PythonQtStdInRedirect_readline(PyObject * self, PyObject * args)
55 {
55 {
56 PythonQtStdInRedirect* s = (PythonQtStdInRedirect*)self;
56 PythonQtStdInRedirect* s = (PythonQtStdInRedirect*)self;
57 QString string;
57 QString string;
58 if (s->_cb) {
58 if (s->_cb) {
59 string = (*s->_cb)(s->_callData);
59 string = (*s->_cb)(s->_callData);
60 }
60 }
61 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
61 #if( QT_VERSION >= QT_VERSION_CHECK(5,0,0) )
62 return Py_BuildValue(const_cast<char*>("s"), const_cast<char*>(string.toLatin1().data()));
62 return Py_BuildValue(const_cast<char*>("s"), const_cast<char*>(string.toLatin1().data()));
63 #else
63 #else
64 return Py_BuildValue(const_cast<char*>("s"), const_cast<char*>(string.toAscii().data()));
64 return Py_BuildValue(const_cast<char*>("s"), const_cast<char*>(string.toAscii().data()));
65 #endif
65 #endif
66 }
66 }
67
67
68 static PyMethodDef PythonQtStdInRedirect_methods[] = {
68 static PyMethodDef PythonQtStdInRedirect_methods[] = {
69 {"readline", (PyCFunction)PythonQtStdInRedirect_readline, METH_VARARGS,
69 {"readline", (PyCFunction)PythonQtStdInRedirect_readline, METH_VARARGS,
70 "read input line"},
70 "read input line"},
71 {NULL, NULL, 0 , NULL} /* sentinel */
71 {NULL, NULL, 0 , NULL} /* sentinel */
72 };
72 };
73
73
74 static PyMemberDef PythonQtStdInRedirect_members[] = {
74 static PyMemberDef PythonQtStdInRedirect_members[] = {
75 {NULL} /* Sentinel */
75 {NULL} /* Sentinel */
76 };
76 };
77
77
78 PyTypeObject PythonQtStdInRedirectType = {
78 PyTypeObject PythonQtStdInRedirectType = {
79 PyObject_HEAD_INIT(NULL)
79 PyVarObject_HEAD_INIT(NULL, 0)
80 0, /*ob_size*/
81 "PythonQtStdInRedirect", /*tp_name*/
80 "PythonQtStdInRedirect", /*tp_name*/
82 sizeof(PythonQtStdInRedirect), /*tp_basicsize*/
81 sizeof(PythonQtStdInRedirect), /*tp_basicsize*/
83 0, /*tp_itemsize*/
82 0, /*tp_itemsize*/
84 0, /*tp_dealloc*/
83 0, /*tp_dealloc*/
85 0, /*tp_print*/
84 0, /*tp_print*/
86 0, /*tp_getattr*/
85 0, /*tp_getattr*/
87 0, /*tp_setattr*/
86 0, /*tp_setattr*/
88 0, /*tp_compare*/
87 0, /*tp_compare*/
89 0, /*tp_repr*/
88 0, /*tp_repr*/
90 0, /*tp_as_number*/
89 0, /*tp_as_number*/
91 0, /*tp_as_sequence*/
90 0, /*tp_as_sequence*/
92 0, /*tp_as_mapping*/
91 0, /*tp_as_mapping*/
93 0, /*tp_hash */
92 0, /*tp_hash */
94 0, /*tp_call*/
93 0, /*tp_call*/
95 0, /*tp_str*/
94 0, /*tp_str*/
96 0, /*tp_getattro*/
95 0, /*tp_getattro*/
97 0, /*tp_setattro*/
96 0, /*tp_setattro*/
98 0, /*tp_as_buffer*/
97 0, /*tp_as_buffer*/
99 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, /*tp_flags*/
98 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, /*tp_flags*/
100 "PythonQtStdInRedirect", /* tp_doc */
99 "PythonQtStdInRedirect", /* tp_doc */
101 0, /* tp_traverse */
100 0, /* tp_traverse */
102 0, /* tp_clear */
101 0, /* tp_clear */
103 0, /* tp_richcompare */
102 0, /* tp_richcompare */
104 0, /* tp_weaklistoffset */
103 0, /* tp_weaklistoffset */
105 0, /* tp_iter */
104 0, /* tp_iter */
106 0, /* tp_iternext */
105 0, /* tp_iternext */
107 PythonQtStdInRedirect_methods, /* tp_methods */
106 PythonQtStdInRedirect_methods, /* tp_methods */
108 PythonQtStdInRedirect_members, /* tp_members */
107 PythonQtStdInRedirect_members, /* tp_members */
109 0, /* tp_getset */
108 0, /* tp_getset */
110 0, /* tp_base */
109 0, /* tp_base */
111 0, /* tp_dict */
110 0, /* tp_dict */
112 0, /* tp_descr_get */
111 0, /* tp_descr_get */
113 0, /* tp_descr_set */
112 0, /* tp_descr_set */
114 0, /* tp_dictoffset */
113 0, /* tp_dictoffset */
115 0, /* tp_init */
114 0, /* tp_init */
116 0, /* tp_alloc */
115 0, /* tp_alloc */
117 PythonQtStdInRedirect_new, /* tp_new */
116 PythonQtStdInRedirect_new, /* tp_new */
118 };
117 };
@@ -1,159 +1,164
1 /*
1 /*
2 *
2 *
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
3 * Copyright (C) 2010 MeVis Medical Solutions AG All Rights Reserved.
4 *
4 *
5 * This library is free software; you can redistribute it and/or
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
8 * version 2.1 of the License, or (at your option) any later version.
9 *
9 *
10 * This library is distributed in the hope that it will be useful,
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
13 * Lesser General Public License for more details.
14 *
14 *
15 * Further, this software is distributed without any warranty that it is
15 * Further, this software is distributed without any warranty that it is
16 * free of the rightful claim of any third person regarding infringement
16 * free of the rightful claim of any third person regarding infringement
17 * or the like. Any license provided herein, whether implied or
17 * or the like. Any license provided herein, whether implied or
18 * otherwise, applies only to this software file. Patent licenses, if
18 * otherwise, applies only to this software file. Patent licenses, if
19 * any, provided herein do not apply to combinations of this program with
19 * any, provided herein do not apply to combinations of this program with
20 * other software, or any other product whatsoever.
20 * other software, or any other product whatsoever.
21 *
21 *
22 * You should have received a copy of the GNU Lesser General Public
22 * You should have received a copy of the GNU Lesser General Public
23 * License along with this library; if not, write to the Free Software
23 * License along with this library; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
25 *
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
26 * Contact information: MeVis Medical Solutions AG, Universitaetsallee 29,
27 * 28359 Bremen, Germany or:
27 * 28359 Bremen, Germany or:
28 *
28 *
29 * http://www.mevis.de
29 * http://www.mevis.de
30 *
30 *
31 */
31 */
32
32
33 //----------------------------------------------------------------------------------
33 //----------------------------------------------------------------------------------
34 /*!
34 /*!
35 // \file PythonQtStdOut.cpp
35 // \file PythonQtStdOut.cpp
36 // \author Florian Link
36 // \author Florian Link
37 // \author Last changed by $Author: florian $
37 // \author Last changed by $Author: florian $
38 // \date 2006-05
38 // \date 2006-05
39 */
39 */
40 //----------------------------------------------------------------------------------
40 //----------------------------------------------------------------------------------
41
41
42 #include "PythonQtStdOut.h"
42 #include "PythonQtStdOut.h"
43
43
44 static PyObject *PythonQtStdOutRedirect_new(PyTypeObject *type, PyObject * /*args*/, PyObject * /*kwds*/)
44 static PyObject *PythonQtStdOutRedirect_new(PyTypeObject *type, PyObject * /*args*/, PyObject * /*kwds*/)
45 {
45 {
46 PythonQtStdOutRedirect *self;
46 PythonQtStdOutRedirect *self;
47 self = (PythonQtStdOutRedirect *)type->tp_alloc(type, 0);
47 self = (PythonQtStdOutRedirect *)type->tp_alloc(type, 0);
48
48
49 self->softspace = 0;
49 self->softspace = 0;
50 self->_cb = NULL;
50 self->_cb = NULL;
51
51
52 return (PyObject *)self;
52 return (PyObject *)self;
53 }
53 }
54
54
55 static PyObject *PythonQtStdOutRedirect_write(PyObject *self, PyObject *args)
55 static PyObject *PythonQtStdOutRedirect_write(PyObject *self, PyObject *args)
56 {
56 {
57 PythonQtStdOutRedirect* s = (PythonQtStdOutRedirect*)self;
57 PythonQtStdOutRedirect* s = (PythonQtStdOutRedirect*)self;
58 if (s->_cb) {
58 if (s->_cb) {
59 QString output;
59 QString output;
60 if (PyTuple_GET_SIZE(args)>=1) {
60 if (PyTuple_GET_SIZE(args)>=1) {
61 PyObject* obj = PyTuple_GET_ITEM(args,0);
61 PyObject* obj = PyTuple_GET_ITEM(args,0);
62 if (PyUnicode_Check(obj)) {
62 if (PyUnicode_Check(obj)) {
63 #ifdef PY3K
64 Py_UCS4 *x = PyUnicode_AsUCS4Copy(obj);
65 output = QString::fromUcs4(x, PyUnicode_GetLength(obj));
66 PyMem_Free(x);
67 #else
63 PyObject *tmp = PyUnicode_AsUTF8String(obj);
68 PyObject *tmp = PyUnicode_AsUTF8String(obj);
64 if(tmp) {
69 if(tmp) {
65 output = QString::fromUtf8(PyString_AS_STRING(tmp));
70 output = QString::fromUtf8(PyString_AS_STRING(tmp));
66 Py_DECREF(tmp);
71 Py_DECREF(tmp);
67 } else {
72 } else {
68 return NULL;
73 return NULL;
69 }
74 }
75 #endif
70 } else {
76 } else {
71 char *string;
77 char *string;
72 if (!PyArg_ParseTuple(args, "s", &string)) {
78 if (!PyArg_ParseTuple(args, "s", &string)) {
73 return NULL;
79 return NULL;
74 }
80 }
75 output = QString::fromLatin1(string);
81 output = QString::fromLatin1(string);
76 }
82 }
77 }
83 }
78
84
79 if (s->softspace > 0) {
85 if (s->softspace > 0) {
80 (*s->_cb)(QString(""));
86 (*s->_cb)(QString(""));
81 s->softspace = 0;
87 s->softspace = 0;
82 }
88 }
83
89
84 (*s->_cb)(output);
90 (*s->_cb)(output);
85 }
91 }
86 return Py_BuildValue("");
92 return Py_BuildValue("");
87 }
93 }
88
94
89 static PyObject *PythonQtStdOutRedirect_flush(PyObject * /*self*/, PyObject * /*args*/)
95 static PyObject *PythonQtStdOutRedirect_flush(PyObject * /*self*/, PyObject * /*args*/)
90 {
96 {
91 return Py_BuildValue("");
97 return Py_BuildValue("");
92 }
98 }
93
99
94 static PyObject *PythonQtStdOutRedirect_isatty(PyObject * /*self*/, PyObject * /*args*/)
100 static PyObject *PythonQtStdOutRedirect_isatty(PyObject * /*self*/, PyObject * /*args*/)
95 {
101 {
96 Py_INCREF(Py_False);
102 Py_INCREF(Py_False);
97 return Py_False;
103 return Py_False;
98 }
104 }
99
105
100 static PyMethodDef PythonQtStdOutRedirect_methods[] = {
106 static PyMethodDef PythonQtStdOutRedirect_methods[] = {
101 {"write", (PyCFunction)PythonQtStdOutRedirect_write, METH_VARARGS,
107 {"write", (PyCFunction)PythonQtStdOutRedirect_write, METH_VARARGS,
102 "redirect the writing to a callback"},
108 "redirect the writing to a callback"},
103 {"flush", (PyCFunction)PythonQtStdOutRedirect_flush, METH_VARARGS,
109 {"flush", (PyCFunction)PythonQtStdOutRedirect_flush, METH_VARARGS,
104 "flush the output, currently not implemented but needed for logging framework"
110 "flush the output, currently not implemented but needed for logging framework"
105 },
111 },
106 {"isatty", (PyCFunction)PythonQtStdOutRedirect_isatty, METH_NOARGS,
112 {"isatty", (PyCFunction)PythonQtStdOutRedirect_isatty, METH_NOARGS,
107 "return False since this object is not a tty-like device. Needed for logging framework"
113 "return False since this object is not a tty-like device. Needed for logging framework"
108 },
114 },
109 {NULL, NULL, 0 , NULL} /* sentinel */
115 {NULL, NULL, 0 , NULL} /* sentinel */
110 };
116 };
111
117
112 static PyMemberDef PythonQtStdOutRedirect_members[] = {
118 static PyMemberDef PythonQtStdOutRedirect_members[] = {
113 {const_cast<char*>("softspace"), T_INT, offsetof(PythonQtStdOutRedirect, softspace), 0,
119 {const_cast<char*>("softspace"), T_INT, offsetof(PythonQtStdOutRedirect, softspace), 0,
114 const_cast<char*>("soft space flag")
120 const_cast<char*>("soft space flag")
115 },
121 },
116 {NULL} /* Sentinel */
122 {NULL} /* Sentinel */
117 };
123 };
118
124
119 PyTypeObject PythonQtStdOutRedirectType = {
125 PyTypeObject PythonQtStdOutRedirectType = {
120 PyObject_HEAD_INIT(NULL)
126 PyVarObject_HEAD_INIT(NULL, 0)
121 0, /*ob_size*/
122 "PythonQtStdOutRedirect", /*tp_name*/
127 "PythonQtStdOutRedirect", /*tp_name*/
123 sizeof(PythonQtStdOutRedirect), /*tp_basicsize*/
128 sizeof(PythonQtStdOutRedirect), /*tp_basicsize*/
124 0, /*tp_itemsize*/
129 0, /*tp_itemsize*/
125 0, /*tp_dealloc*/
130 0, /*tp_dealloc*/
126 0, /*tp_print*/
131 0, /*tp_print*/
127 0, /*tp_getattr*/
132 0, /*tp_getattr*/
128 0, /*tp_setattr*/
133 0, /*tp_setattr*/
129 0, /*tp_compare*/
134 0, /*tp_compare*/
130 0, /*tp_repr*/
135 0, /*tp_repr*/
131 0, /*tp_as_number*/
136 0, /*tp_as_number*/
132 0, /*tp_as_sequence*/
137 0, /*tp_as_sequence*/
133 0, /*tp_as_mapping*/
138 0, /*tp_as_mapping*/
134 0, /*tp_hash */
139 0, /*tp_hash */
135 0, /*tp_call*/
140 0, /*tp_call*/
136 0, /*tp_str*/
141 0, /*tp_str*/
137 0, /*tp_getattro*/
142 0, /*tp_getattro*/
138 0, /*tp_setattro*/
143 0, /*tp_setattro*/
139 0, /*tp_as_buffer*/
144 0, /*tp_as_buffer*/
140 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, /*tp_flags*/
145 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, /*tp_flags*/
141 "PythonQtStdOutRedirect", /* tp_doc */
146 "PythonQtStdOutRedirect", /* tp_doc */
142 0, /* tp_traverse */
147 0, /* tp_traverse */
143 0, /* tp_clear */
148 0, /* tp_clear */
144 0, /* tp_richcompare */
149 0, /* tp_richcompare */
145 0, /* tp_weaklistoffset */
150 0, /* tp_weaklistoffset */
146 0, /* tp_iter */
151 0, /* tp_iter */
147 0, /* tp_iternext */
152 0, /* tp_iternext */
148 PythonQtStdOutRedirect_methods, /* tp_methods */
153 PythonQtStdOutRedirect_methods, /* tp_methods */
149 PythonQtStdOutRedirect_members, /* tp_members */
154 PythonQtStdOutRedirect_members, /* tp_members */
150 0, /* tp_getset */
155 0, /* tp_getset */
151 0, /* tp_base */
156 0, /* tp_base */
152 0, /* tp_dict */
157 0, /* tp_dict */
153 0, /* tp_descr_get */
158 0, /* tp_descr_get */
154 0, /* tp_descr_set */
159 0, /* tp_descr_set */
155 0, /* tp_dictoffset */
160 0, /* tp_dictoffset */
156 0, /* tp_init */
161 0, /* tp_init */
157 0, /* tp_alloc */
162 0, /* tp_alloc */
158 PythonQtStdOutRedirect_new, /* tp_new */
163 PythonQtStdOutRedirect_new, /* tp_new */
159 };
164 };
General Comments 0
You need to be logged in to leave comments. Login now