| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This commit restructures and enhances the description of the file
filters in QFileDialog. The commit adds info on MIME type filters and
clarifies the case sensitivity of file filters on various
platforms.
Fixes: QTBUG-135381
Pick-to: 6.10 6.8
Change-Id: I1fa7eeefb0e242285ee3bc4a86f29b76f72abe8f
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Alexei Cazacov <alexei.cazacov@qt.io>
|
| |
|
|
|
|
|
|
|
| |
Only small fixes in code snippets related to indentation and scopes.
Also added them to the build system with the necessary conditions
Task-number: QTBUG-137566
Change-Id: I0a5e3636d501fb33179a940de56f608552c99ce1
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
| |
Created a new CMakeLists.txt for the widgets snippets code directory.
Added snippets to the build system and fixed related issues.
Task-number: QTBUG-137566
Change-Id: I1ec39266c6c0d14e513ffa604374ae2789d06b52
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
The snippets in dialog.cpp use deprecated APIs, so fail to build with
QT_DISABLE_DEPRECATED_UP_TO set to a relevant Qt version.
Fix by guarding the deprecated APIs with proper ifdefs.
Amends 67086b4149da86427666967d11f3c0f33330b5b3.
Change-Id: I3bef2323ac2adad4748869950ef377615a3647bf
Reviewed-by: Oleksii Zbykovskyi <Oleksii.Zbykovskyi@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Private CMake API like qt_internal_extend_target should not be used in
public doc snippets. While most of the CMakeLists.txt doc snippets
might not appear in the documentation right now, they might in the
future (just like the CMake API doc snippets).
In addition, using private CMake API for doc snippets targets causes
issues with SBOM generation, because the original targets are not
created with private API (e.g. qt_internal_add_module vs
qt_add_library), and thus important sbom meta information is missing,
causing errors at cmake configure time when sbom generation is
enabled.
Pick-to: 6.8 6.9 6.10
Change-Id: I2ef80f617ba8b745520408d22dd2e6be5ee4c5e0
Reviewed-by: Oleksii Zbykovskyi <Oleksii.Zbykovskyi@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
|
| |
|
|
|
|
|
|
| |
In several snippets, the TableModel class is created and used.
I included a header file to avoid code repetition.
Change-Id: Ie6318606cc89a2f5f1c137a36195fe290b6c1be6
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Made minor adjustments to the indentation in the qtreewidget-using
example to ensure clarity and consistency in the code snippets.
At the same time, combine snippets 10 and 11 because they are only used
together. Updated related documentation to reflect these changes.
Amends 1cf7d9f34f1bc3ddc5fa97ff57a95dd8083f9ae8
Change-Id: I7446341cf4e498004199c1ec9d08e31df9ae5b7f
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
| |
MainWindow class was created and used all around widgets snippets.
I made a seperated header file for all of these cases to avoid
repetitive code.
Change-Id: Ic403fc7d5278f77e62d8b5265c4184a154fef1b6
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
| |
Most of the snippets in widgets have indentation problems.
So I refactored them to have a consistent indentation.
Change-Id: I94422c222aa7a72cb2352f8cfb41ffe207c74904
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
| |
Snippets 0 and 1 are used only together and may be combined.
Change-Id: Ib138d321116b9eaf4152690dbfbe3a9b20217203
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
Customstyle has two functions, and each of them contains two snippet blocks.
These blocks are not used separately, so I combined each of them into one
and fixed the related documentation.
Task-number: QTBUG-137566
Change-Id: I539940c85970a8dfdb63daf531335ae4bf9d754b
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
| |
Removed useless CMakefiles and move their contents to the main
CMakeLists file.
Task-number: QTBUG-137566
Change-Id: Ibeb162ce43243d9af7732f39935325cbb52ecdec
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
Created a CMakeLists.txt file in the widgets folder and added snippets
to it.
Fixed related issues with missing includes and compilation errors.
Task-number: QTBUG-137566
Change-Id: Ief61c3675d8b4d5935bbb0cb951d3a9e82f437f7
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
| |
Improve the documentation for QDialog and QMessageBox.
Clarifies example usage and the optional nature of the parent parameter without implying a required guideline.
Fixes: QTBUG-123902
Change-Id: I30749a0c13de55f41ce9c944542cf3c6356fd6bd
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
| |
Change the remaining calls to QIcon::pixmap() to pass a valid
devicePixelRatio parameter.
Pick-to: 6.9
Change-Id: I0e71e20c8109e296446e9e13cddba31d53c05df9
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
| |
Pick-to: 6.8
Task-number: QTBUG-126463
Change-Id: Ib5d207e72c0de436b4daec29efd8baec8a998103
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
idx.data(role) is much nicer to read than idx.model()->data(idx, role)
As a drive-by, mark some QVariants const.
Pick-to: 6.8
Change-Id: I00c0a5ac311a03095050b2542a5c396a6c1c2c6a
Reviewed-by: Marc Mutz <marc.mutz@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit introduces a new `qt_add_ui` CMake API to be used instead
of AUTOUIC, due to several hard-to-fix bugs it has.
* Resolves the issue where Ninja required two passes to correctly build
`.ui` files.
* Avoids build folder leakage, in contrast to `AUTOUIC`
* Prevents unnecessary recompilation of unchanged source files when a
`.ui` file is modified with Ninja.
* Since `qt_add_ui` does not scan source files, it provides a faster
build than `AUTOUIC`.
These changes aim to streamline the build process and improve
efficiency when working with `.ui` files.
This addresses the following issues:
https://gitlab.kitware.com/cmake/cmake/-/issues/16776
https://gitlab.kitware.com/cmake/cmake/-/issues/25436
https://gitlab.kitware.com/cmake/cmake/-/issues/25195
Task-number: QTBUG-110369
Fixes: QTBUG-114563
Change-Id: I34cd3df70542becf6e08502f0cbcd1c11eeeadd6
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
The color editor factory example is removed and part of the codes are
used as snippets.
Fixes: QTBUG-119985
Pick-to: 6.7 6.6
Change-Id: I421e473e7db09a5af7543b80b87a338d8ff2ab7e
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Remove the Group Box Example from the repository, eliminating the
associated example codes, screenshot, and documentation file. The
only relevant portion used in the QGroupBox class has been relocated
to the existing snippet file. Additionally, all references to this
example across other files have been removed.
Fixes: QTBUG-119980
Pick-to: 6.7 6.6
Change-Id: I66f9dd9dab1fe64f2d20424af3acd135201827d2
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
| |
QMouseEvent::globalPos() is deprecated - replace it with
QMouseEvent::globalPosition().toPoint()
Pick-to: 6.7 6.6 6.5
Fixes: QTBUG-124343
Change-Id: I6f862a9a640da11d756dae58ffae8c6d7fc24e02
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Reviewed-by: Safiyyah Moosa <safiyyah.moosa@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
All file under doc/snippet should be
license as Documentation snippets
and according to QUIP-18 [1]
this is LicenseRef-Qt-Commercial OR BSD-3-Clause
[1]: https://contribute.qt-project.org/quips/18
Pick-to: 6.7
Task-number: QTBUG-121787
Change-Id: I76eedfb6b15c4091f726a5652e3530001d7cdaf7
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
According to QUIP-18 [1], all doc snippet files should be
LicenseRef-Qt-Commercial OR BSD-3-Clause
[1]: https://contribute.qt-project.org/quips/18
Pick-to: 6.7
Task-number: QTBUG-121787
Change-Id: I6e5bc9d05a5d510cc07a15abafe2257034562510
Reviewed-by: Kai Köhne <kai.koehne@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
| |
According to QUIP-18 [1], all .qdoc files should be
LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
[1]: https://contribute.qt-project.org/quips/18
Pick-to: 6.7
Change-Id: I4559af21fc9069efa9bf0cbd29c5e86cfdac9082
Reviewed-by: Kai Köhne <kai.koehne@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add the setting of the layout's size constraint to 'fixed' back to the
snippet, so that the dialog automatically resizes when the extension
gets hidden. The user won't be able to resize the dialog, but allowing
the user to resize the dialog and to show and hide the extension anyway
leads to unpredictable results for the user.
Amends 11da92ba94570e5eec01597fe09f0a9a48acc677.
Pick-to: 6.7 6.6
Change-Id: Ie74ca36eaa1a8e9567e0d5826f91f8633e5cbc05
Reviewed-by: David Faure <david.faure@kdab.com>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
The essence of the example was already fully quoted in the
model/view documentation. Move the code into a snippet
source, and update the screenshot.
Fixes: QTBUG-119976
Pick-to: 6.7 6.6
Change-Id: Id2f10bb26a650419969bbfa9b76cb74babd3319e
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Reviewed-by: Andreas Eliasson <andreas.eliasson@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Added breaks in List of Stylable Widgets table.
Changed List of Properties table into sections.
Added list of Qt-specific properties in beg of List of Properties chapter.
Moved snippet comments to different rows.
Task-number: QTBUG-118446
Pick-to: 6.6
Change-Id: I494401058c7982c0a0ada18c8c94429beabba348
Reviewed-by: Mats Honkamaa <mats.honkamaa@qt.io>
|
| |
|
|
|
|
|
| |
The horizontal parts were missing colons.
Change-Id: Ibc3657d87d38af76d0736f9880eb711f52723de1
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
|
| |
|
|
|
|
|
|
|
| |
The important bits from the example are ~10 lines of code, no need
for building a poor-man's version of a graphics or item view.
Pick-to: 6.6
Change-Id: I7874c66765c5b46230c92846ee3de1ee83f47e45
Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
All these TUs relied on transitive includes of qpointer.h, maybe to a
large extent via qevent.h, though, given that qevent.h is more or less
the only public QtBase header that includes qpointer.h, something else
seems to be at play here.
Said qevent.h actually needs QPointer in-name-only, so a forward
declaration would suffice. Prepare for qevent.h dropping the include.
The algorithm I used was:
If the TU mentions 'passiveGrabbers', the name of the QEvent function
that returns QPointers, and the TU doesn't have qpointer.h included
explicitly, include it. That may produce False Positives, but better
safe than sorry. Otherwise, in src/, add an include to all source and
header files which mention QPointer. Exception: if foo.h of a foo.cpp
already includes it, don't include again.
Task-number: QTBUG-117670
Change-Id: I3321cccdb41ce0ba6d8a709cea92427aba398254
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
| |
|
|
|
|
| |
Task-number: QTBUG-113331
Change-Id: I8baa697b4997b05f52acdee0e08d3c368fde5bc2
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
|
| |
|
|
|
|
| |
Pick-to: 6.5 6.6
Change-Id: I08f44448f96a61f780c21d628954879c7b28dce3
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
| |
Pick-to: 6.5 6.6
Change-Id: I81a6e9d52e858c3f733d4c527c70408772813b56
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
| |
Pick-to: 6.5
Task-number: QTBUG-108751
Change-Id: I8ca4e058b832674dc0c8b84024cb70a667ee8db4
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
|
| |
Changes code snippets that are visible in the docs.
Task-number: QTBUG-113116
Pick-to: 6.5
Change-Id: If743234bfe6947acf02307bf1144daad4fba5d73
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Modules:
- Core
- Gui
- Widgets
- Open(Widgets)
- PrintSupport
- Sql
- Network
- Concurrent
- Testlib
Pick-to: 6.5
Change-Id: I63e58c01bec4bd162486020f0085227fdaa83b18
Reviewed-by: Ahmad Samir <a.samirh78@gmail.com>
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
The "two widgets at a time" API to set the tab order is awkward and
easily misused (as the documentation explicitly explains). Add an inline
overload that takes an initializer_list, and call the existing function
for each consecutive pair of widgets in the list.
Add documentation with snippet, and a test.
Change-Id: I8e6f14a242866e3ee7cfb8ecade4697d6bdfb4d4
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
| |
|
|
|
|
|
|
|
| |
QstyleOption has no init() member, only initFrom().
Fixes: QTBUG-107770
Pick-to: 6.5 6.4 6.2 5.15
Change-Id: I00ff0b980fbfac813f113a7052bd3df32c7912b6
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
Remove clashing enumeration value ColumnCount and exclude
file in snippets.
Task-number: QTBUG-109394
Pick-to: 6.5
Change-Id: Ibd8a72d9d87e3dcbbb221c364d6b4c4f59b315df
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
|
| |
This is a follow up from commit 1e904ab342c1aaa; changing more
documentation to pass a widget * in the ctor of a layout, rather
than creating a parent-less layout then calling setLayout().
Change-Id: I4fc59c6cfa46ccd279a153acd67335a6daf22ff9
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We've been requiring C++17 since Qt 6.0, and our qAsConst use finally
starts to bother us (QTBUG-99313), so time to port away from it
now.
Since qAsConst has exactly the same semantics as std::as_const (down
to rvalue treatment, constexpr'ness and noexcept'ness), there's really
nothing more to it than a global search-and-replace, with manual
unstaging of the actual definition and documentation in dist/,
src/corelib/doc/ and src/corelib/global/.
Task-number: QTBUG-99313
Change-Id: I4c7114444a325ad4e62d0fcbfd347d2bbfb21541
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
|
| |
|
|
|
|
|
|
|
| |
The placeholder text was given its own QPalette color role in Qt 5.12,
but there has been no way to specify it from a Qt style sheet.
Fixes: QTBUG-93009
Change-Id: If58ca844c19c65b7eee14c6d5730a4ba27640c33
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
| |
The snippet for QFileDialog::saveFileContent is wrong - the parameters
used are in wrong order.
Pick-to: 6.4 6.2 5.15
Change-Id: I022e8ed2ef5aeea5a44e9b10ac211893a3e24c0f
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
| |
Task-number: QTBUG-105718
Change-Id: I5d3ef70a31235868b9be6cb479b7621bf2a8ba39
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
The code introduced by 54d5ca0c2766e915c960fa437cee6c20a324c1a7
did not work since the variables parentIndex/numRows
were local to the lambda and the outer code would not wait.
Move the widgets population into the lambda to fix this.
Modernize the remaining code a bit.
Pick-to: 6.4 6.3 6.2
Change-Id: I2a09878987df9edb9ff04f0ac4ad82af1a8b52c8
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
CMakeLists.txt and .cmake files of significant size
(more than 2 lines according to our check in tst_license.pl)
now have the copyright and license header.
Existing copyright statements remain intact
Task-number: QTBUG-88621
Change-Id: I3b98cdc55ead806ec81ce09af9271f9b95af97fa
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
|
| |
|
|
|
| |
Change-Id: I8ef0ff5a499f796ebf76447caab27ff6b2556570
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Replace the current license disclaimer in files by
a SPDX-License-Identifier.
Files that have to be modified by hand are modified.
License files are organized under LICENSES directory.
Task-number: QTBUG-67283
Change-Id: Id880c92784c40f3bbde861c0d93f58151c18b9f1
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
|
| |
|
|
|
|
| |
Task-number: QTBUG-98434
Change-Id: I310ea8f19d73a79d985ebfb8bfbff7a02c424360
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
| |
Required for porting away from QLatin1Char/QLatin1String in scope of
QTBUG-98434.
As a drive-by, fix qsizetype -> int narrowing conversion warnings for
the touched lines.
Change-Id: I133b80334b66e0a5ab9546dd8e1ff0631e79601e
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|