| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Avoid copying complex types by using const ref
- Use isEmpty() to check for container emptyness
- Use range-based for
- Use Q_DISABLE_COPY in 'public:' area
- Fix spelling error
- Use '= default' for trivial constructors/destructors
- Remove non-null checks before deletion
- Fix misleading indentation
- Fix else after return
- Simplify boolean expressions
- Fix unused parameters, streamline code
Change-Id: I8c6cadd8653e220ba8e5bdb4dd55524d13a81768
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|
|
|
|
|
|
|
| |
Apply Fixits by Qt Creator with some amendments.
Remove iterator types by using auto instead.
Change-Id: I8a75323da6ae5cdcc6b67af8be9376408953986b
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|
|
|
|
|
|
| |
Apply Fixits by Qt Creator with some amendments.
Change-Id: Ib2be1012ef7e8a2ad0e6cd130371bf1e941c4264
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|
|
|
|
|
|
| |
Apply Fixits by Qt Creator with some amendments.
Change-Id: Ie8300ddb834adb8b649324562f2c912a4e8cf4ce
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|
|
|
|
|
|
|
|
| |
Use member initialization, use default bodies for constructors.
Initialize missing members as reported by clang.
Change-Id: Ibc51e46a37b310912ec8f274543092dfdda78e1b
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|
|
|
|
| |
Change-Id: Icb2d3702972a2dc49ee296b2111811ff75b162fc
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
For types, QObjects are equivalent to objects, there is no need to
differentiate. Remove the code trying to find whether a type is a
QObject.
Only AbstractMetaClass needs to know whether it inherits QObject. Add
a simple check recursing down the base classes.
Change-Id: I2365b451c8873f044b06c09b58aff29e2db3c5b7
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
Extract the <brief> element from the WebXML class description and
place it at the top with an internal reference (More...) to the
detailed description. For this purpose, extend QtXmlToSphinx by a
<rst> element to be able to pass through rst elements as is, which
might come in handy for other purposes as well.
Change-Id: I8e3fd9e3ead99b205afdd5f4be948c0d34336a94
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
|
|
|
|
|
|
|
| |
Strip the module names.
Change-Id: I7b123acc30e15e0954fe88f3a5b677e9aa736732
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
|
|
|
|
|
|
|
|
|
| |
Add a deprecation note to deprecated functions and classes.
There is a standard deprecated directive, but it takes the version
as a mandatory parameter, which we are unable to obtain from Clang.
Change-Id: Ice27b297fbd86def41d99b0f3505551ed301077f
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Replace the note directive previously used for \since by the standard
versionadd directive which takes less space.
Move it below the function parameters and indent it along with the
parameters correctly as otherwise the formatting is messed up.
Change writeFunctionSignature() to return a QString which is more
convenient for indenting.
Remove the bool writeDoc parameter from
QtDocGenerator::writeFunction() and spell out the formatting in
writeConstructors() since it all needs to be indented properly (using
the new indenter helper).
Change-Id: I2294ba457ed05f431be295f9d42489aeb6805a8a
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix warnings appearing in Qt 5.13:
sources/shiboken2/generator/shiboken2/shibokengenerator.cpp:873:25: warning: ‘QString::null’ is deprecated: use QString() [-Wdeprecated-declarations]
sources/shiboken2/generator/shiboken2/shibokengenerator.cpp:873:25: warning: ‘QString::null’ is deprecated: use QString() [-Wdeprecated-declarations]
sources/shiboken2/generator/shiboken2/shibokengenerator.cpp:880:25: warning: ‘QString::null’ is deprecated: use QString() [-Wdeprecated-declarations]
sources/shiboken2/generator/shiboken2/shibokengenerator.cpp:880:25: warning: ‘QString::null’ is deprecated: use QString() [-Wdeprecated-declarations]
sources/shiboken2/generator/shiboken2/cppgenerator.cpp:5060:34: warning: ‘QString::null’ is deprecated: use QString() [-Wdeprecated-declarations]
sources/shiboken2/generator/shiboken2/cppgenerator.cpp:5060:34: warning: ‘QString::null’ is deprecated: use QString() [-Wdeprecated-declarations]
Change-Id: I7c938df64babf824b58bf5c785b281a88d5111db
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix warnings occurring in 5.13:
sources/shiboken2/ApiExtractor/abstractmetalang.cpp:1431:66: warning: ‘void qSort(RandomAccessIterator, RandomAccessIterator, LessThan) [with RandomAccessIterator = AbstractMetaFunction**; LessThan = bool (*)(AbstractMetaFunction*, AbstractMetaFunction*)]’ is deprecated: Use std::sort [-Wdeprecated-declarations]
sources/shiboken2/generator/shiboken2/cppgenerator.cpp:358:43: warning: ‘void qSort(RandomAccessIterator, RandomAccessIterator) [with RandomAccessIterator = Include*]’ is deprecated: Use std::sort [-Wdeprecated-declarations]
sources/shiboken2/generator/shiboken2/cppgenerator.cpp:1683:55: warning: ‘void qSort(RandomAccessIterator, RandomAccessIterator) [with RandomAccessIterator = QList<QString>::iterator]’ is deprecated: Use std::sort [-Wdeprecated-declarations]
sources/shiboken2/generator/shiboken2/cppgenerator.cpp:5500:53: warning: ‘void qSort(RandomAccessIterator, RandomAccessIterator) [with RandomAccessIterator = Include*]’ is deprecated: Use std::sort [-Wdeprecated-declarations]
sources/shiboken2/generator/qtdoc/qtdocgenerator.cpp:1585:65: warning: ‘void qSort(RandomAccessIterator, RandomAccessIterator, LessThan) [with RandomAccessIterator = AbstractMetaFunction**; LessThan = bool (*)(const AbstractMetaFunction*, const AbstractMetaFunction*)]’ is deprecated: Use std::sort [-Wdeprecated-declarations]
sources/shiboken2/generator/qtdoc/qtdocgenerator.cpp:1681:24: warning: ‘void qSort(Container&) [with Container = QStringList]’ is deprecated: Use std::sort [-Wdeprecated-declarations]
sources/shiboken2/generator/qtdoc/qtdocgenerator.cpp:2054:25: warning: ‘void qSort(Container&) [with Container = QStringList]’ is deprecated: Use std::sort [-Wdeprecated-declarations]
Change-Id: If6940941ac31327597ce362a31b27773f4d5b94c
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|
|
|
|
|
| |
Task-number: PYSIDE-903
Change-Id: I4dc2cce4741c87e08b8b3d0dc911c62d044ee054
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
|
|
|
|
|
|
|
|
|
| |
This makes it easier to maintain a consistent style,
unclutters the source and allows for re-using formatting helpers.
Change-Id: I4f29637a22afb457f629272e2d86f14bedb36008
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|
|
|
|
|
|
|
|
|
| |
Make visibility more restricted by moving definitions to the
private/protected section.
Remove virtual from Generator::moduleName() since it is not overridden.
Change-Id: I6b43f9679741fa8a5c453b339d9bb4228d74c04c
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|\
| |
| |
| | |
Change-Id: Ie8025300580981c5349b31d4846a7f659481991d
|
| |
| |
| |
| |
| |
| | |
Change-Id: I13226628db54479cc01aab215bb52063684f23c9
Reviewed-by: Christian Tismer <tismer@stackless.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Do not rely on row 0 to obtain the maximum number of columns,
search all instead.
Change-Id: I6ddda89c191d1823b346e9e564f31a61de523426
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
- 'else if' after return/break/continue
- Use const ref for complex arguments passed by value where possible
- Fix 'if (foo) delete foo' to 'delete foo'
- Use container.isEmpty() instead of container.size() in checks
- Use ' = default' for trivial constructors/destructors
- Use range based for where possible
- Complete constructor initializer lists
- Fix invocations of static methods
- Replace some reinterpret_cast by static_cast
- Remove unused variables/fields
- Use initializer lists for return types
Change-Id: Id5b44a2f9d429f66ef069d532a1cd31df796d38e
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The one-character path options only take one path argument.
Add parameter to the doc generator options.
Task-number: PYSIDE-363
Change-Id: Ia1a0c1552a5d1e3ec86609e9899e985628874545
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|/
|
|
|
|
|
|
|
|
|
| |
In main, replace the class ArgsHandler by plain QMap handling.
Remove the args parameter of Generator::doSetup() and
add a new virtual handleOption(key, value) to the generators
instead. Add missing initialization.
Change-Id: I9bc844172a81244f729d87a3d4262545e6433904
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
| |
Replace .cpp by .py and try to find the snippet. Fall back to .cpp.
Task-number: PYSIDE-363
Change-Id: I82b23df9894e626c97b44dc5a841f5fa70ae1d57
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
|
|
|
|
|
|
|
| |
Output line and column.
Change-Id: Ide890b93c47ef0fc9ebe3209356da100e0cbde4e
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
| |
Introduce a simple [] notation for target directories.
Task-number: PYSIDE-363
Change-Id: I3a0cd255faf84f564a64992cba88244ae14c2452
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Forward declare QtXmlToSphinx::LinkContext as a public struct
and move the definition to the source file.
Replace the linkTag/linkTagEnding strings by an enumeration for the
type and flags for storing the bold/italic state.
Move the formatting to an operator<<(QTextStream,LinkContext)
for clarity.
Streamline the code checking the link text against the reference
in handleLinkText(), avoiding some unnecessary tests.
Add an 'External' type for external pages which do not have a role
keyword.
This fixes:
- Undoes a breakage introduced by c5582d3120249a902681454b2319df765ffa2cd8
converting all link refs to RST labels, clobbering the '~' used for some
function references. This is now limited to page type links.
- Broken handling of links within italic/bold: The assignment
to the linkTag variable by type would clobber the previously assigned
italic/bold markers
- Enable external links without role
Task-number: PYSIDE-363
Change-Id: I2e9a8cd80df93a77f3c6c9f8593243b35eeeb56e
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Removing the word 'project' from all the headers,
and changing the PySide reference from the examples
to Qt for Python:
The following line was used inside the source/ and
build_scripts/ directory:
for i in $(grep -r "the Qt for Python project" * |grep -v "pyside2-tools" | awk '{print $1}' | sed 's/:.*//g');do sed -i 's/the\ Qt\ for\ Python\ project/Qt\ for\ Python/g' $i;done
and the following line was used inside the examples/ directory:
for i in $(grep -r "of the PySide" * |grep -v "pyside2-tools" | awk '{print $1}' | sed 's/:.*//g');do sed -i 's/of\ the\ PySide/of\ the\ Qt\ for\ Python/g' $i;done
Change-Id: Ic480714686ad62ac4d81c670f87f1c2033d4ffa1
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
|
|
|
|
|
|
|
|
|
| |
Add support for <target> and <page> elements for the additional
documentation sections.
Task-number: PYSIDE-363
Change-Id: I0b04106fbe6ae1779625de333368e18bbc31b962
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Add utility functions to remove invalid characters and a helper
for streaming
Task-number: PYSIDE-363
Change-Id: I45eb33ed60deed82912262a99551436c538eee22
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Add an option taking a list of files under the webxml directory
that are run though the Sphinx converter to create .rst files.
This can be used for tutorials and example descriptions.
Task-number: PYSIDE-363
Change-Id: Ifa6df32517a2b336cd3f755523947d70c5c24f2e
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
| |
When referring to the project one should use "Qt for Python"
and for the module "PySide2"
Change-Id: I36497df245c9f6dd60d6e160e2fc805e48cefcae
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Introduce an enumeration for the list type and handle
ordered lists like bullet lists with a different separator.
Task-number: PYSIDE-640
Change-Id: I2e770f2dd56958627e423822b8f4b1c23fdd4e16
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
smart-pointer-type is a special type for making getter method
and type known to shiboken. It should not be documented.
Fixes a lot of warnings when trying to generate documentation
for QtQuick.QSharedPointer.
Task-number: PYSIDE-363
Change-Id: Icb26fa3e16cd74ae5115cdd1cbe32cb48ab5445b
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
| |
Print option descriptions indented by 8 below the option
instead of beside the option at column 38 and add some newlines
to avoid wrapping.
Change-Id: I63295a40aaac588f761c5964b68dbaff8d013c95
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|
|
|
|
|
|
|
|
| |
Limit the number of added cells to the rowcount.
Task-number: PYSIDE-363
Change-Id: I2b05ce97962d56650112b66fe99de0f5ea693abb
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
|
|
|
|
|
|
| |
Change-Id: Ic4ee9c0e36bb727225bccfa7a72bee38a63d17c2
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
| |
Change-Id: If7464f643fca74aa06099ca4b9905b34bd077193
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Change TypeSystemEntry::m_version from double to
QVersionNumber.
- Determine version at the beginning of the start element
processing of the parser and use that.
- Remove AddedFunction::m_version which is not needed.
- Remove unused parameter double vr from
AbstractMetaBuilderPrivate::translateType().
Change-Id: I2941667ba565f8c11aa0c14446ec7d6934da99dc
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The rst ::image elements do not work inline, they require a line
each.
Work around as recommended by using rst substitution references
instead, using a tag enclosed in '|' and defining it below.
Split out a separate inline image handler and store the references
to be written out later.
Fixes warnings like:
WARNING: image file not readable: PySide2/QtCore/images/cursor-cross.pngAcrosshaircursor,typicallyusedtohelptheuseraccuratelyselectapointonthescreen.
Task-number: PYSIDE-363
Change-Id: I860875957688885ca48038aa3aa96bd9c38da709
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Fix several warnings:
Inline literal start-string without end-string.
Task-number: PYSIDE-363
Change-Id: Iadd753d9e8c46b6f00e915e494b01f763e6ce035
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
Fixing numerous warnings:
WARNING: Could not import class '...' specified for inheritance diagram
Task-number: PYSIDE-363
Task-number: PYSIDE-617
Change-Id: I84013d8be442c43212f0726a141ce0dc9b51c92c
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Reviewed-by: Christian Tismer <tismer@stackless.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
"See also" links may appear in the qdoc WebXML output as nested links:
<see-also>QAbstractXmlReceiver<link raw="isValid()" href="qxmlquery.html#isValid" type="function">isValid()</link>
which was handled in handleLinkTag(), or as direct text:
<see-also>rootIsDecorated()</see-also>
which was not handled, causing numerous warnings:
.../QAbstractXmlNodeModel.rst:448: WARNING: Content block expected for the "seealso" directive; none found.
Refactor and split QtXmlToSphinx::handleLinkTag() into several functions
to operate on a struct LinkContext and keep 2 instances for
nested link tags and directly embedded links.
Task-number: PYSIDE-363
Change-Id: I734884267209f3621bfc5db4bf4347b838eb0de6
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
| |
Fix warnings:
Content block expected for the "container" directive; none found
Task-number: PYSIDE-363
Change-Id: Ie855ac355478060c0d280413a31dffcb03cf3935
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix warnings like:
warning: Undefined substitution referenced: "Constant |Description"
on tables like:
*amplitude**period* +-------------------------+-----------+
|Constant |Description|
+=========================+===========+
|QEasingCurve.InOutElastic| |
+-------------------------+-----------+
Task-number: PYSIDE-363
Change-Id: I56cd9b73dacbfd84260c059a8916db5540029816
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
| |
Fix sphinx warnings:
warning: Explicit markup ends without a blank line; unexpected unindent
Task-number: PYSIDE-363
Change-Id: Iec9d8b35317dc9c1009db468284cb7b7a88104a0
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Move code from shouldSkip() helper of the doc generator
into the doc parser and use that for the qdoc/doxygen parsers.
The additional checks (most importantly the check for
declaringClass != ownerClass excluding the virtual functions
added by AbstractMetaClass::fixFunctions() to derived classes)
avoid running unneeded XPATH queries.
Task-number: PYSIDE-363
Change-Id: Ib1141a348c96b269a50c63dd94fe93931c12d1ec
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Introduce a streamable class that does the escaping and some
helpers for QString/QStringRef.
Task-number: PYSIDE-363
Change-Id: Ica6d8a2ab43eeb597b4e9080330dc2ce700e0ed2
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
| |
Change-Id: I4bbaa7d46bab2526906655c5f03bbd25a142bbc4
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Fix a warning about a malformed table (qcursor.cpp) whose
last row has too few columns.
Task-number: PYSIDE-363
Change-Id: I5eec88226e48064ee54e3abe1247d9dc06dc1d82
Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
|
|
|
|
|
|
|
| |
Use splitRef() where applicable or rewrite.
Task-number: PYSIDE-363
Change-Id: I08dcafbba82327f6ff4c02f582341083b4b48755
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|