summaryrefslogtreecommitdiffstats
path: root/src/widgets
Commit message (Collapse)AuthorAgeFilesLines
* Fix: style sheet styling of background of triangular QTabWidget tabsEirik Aavitsland2019-05-091-2/+2
| | | | | | | | | | The triangular tab shape is not reproducible with setting style border options, so it should be painted with the usual code path, also when a custom background has been set. Fixes: QTBUG-72096 Change-Id: I7bc1c0579386b8ea7266ce6456534c2519d9addf Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* Doc: replace even more null/0/nullptr with \nullptr macroChristian Ehrlicher2019-05-0811-27/+27
| | | | | | | | Try to replace all wordings like '.. to 0' with '.. to \nullptr'. Also checked for 'null pointer' and similar. Change-Id: I73341f59ba51e0798e816a8b1a532c7c7374b74a Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-05-063-1/+9
|\ | | | | | | Change-Id: Iaad9509712c848ed42ada2c25065162a6fc5a930
| * fix compilation with various -no-feature-* optionsNick Shaforostov2019-05-053-1/+9
| | | | | | | | | | Change-Id: Ic1975db497613e3efe50be4246c167efe10d8e31 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Liang Qi2019-05-032-14/+10
|\| | | | | | | | | | | | | Conflicts: src/3rdparty/pcre2/qt_attribution.json Change-Id: Ibae941cb12662f27bd6962ee02bc235971c59a15
| * Reduce amount of tracepoints required for event trackingMilian Wolff2019-05-022-14/+10
| | | | | | | | | | | | | | | | | | Encode the consumed/filtered state in the _exit tracepoint and remove the separate tracking of receiver event handling. Combined, this reduces the size of the trace file. Change-Id: Icb3cb2dd47798543905cea450046d6fad559a15b Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Liang Qi2019-05-021-1/+1
|\| | | | | | | | | | | | | Conflicts: src/corelib/kernel/qobject.cpp Change-Id: I8ca1163a1fa8072dcd16ea4426c58219149599fd
| * Don't pass scope args to _exit trace pointsMilian Wolff2019-04-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When we trace a scope, then we pass the scope args to the _entry trace point. There is no need to do that also for the _exit trace points, it just blows up the trace data for no obvious gain. Any decent tracing consumer can easily find the args for the _exit call by matching it to its _entry call. Note that this is standard practice in trace points, and also done like this in the Linux Kernel trace points for example. Change-Id: I273293b0c7e799767acc1960b50ab675fc765a36 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Fix -Wdeprecated-copy warningsAllan Sandfeld Jensen2019-05-011-0/+23
| | | | | | | | | | | | | | | | | | | | Implicit copy constructors or methods are considered deprecated for classes that has one of the two or a destructor. The warning is enabled with -Wextra in gcc 9 Change-Id: Ic9be654f2a142fb186a4d5a7d6b4f7d6f4e611d8 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-242-22/+57
|\| | | | | | | Change-Id: I26da00aa71b0f0b91c9bfb4a9e8550345ee62875
| * QSystemTrayIcon/X11: Create tray icon window when system tray appearsAlexander Volkov2019-04-232-22/+57
| | | | | | | | | | | | | | | | | | | | ... and destroy it otherwise. Fixes: QTBUG-61898 Fixes: QTBUG-73459 Done-with: Gatis Paeglis <gatis.paeglis@qt.io> Change-Id: I6bd8f397f7ccdb123f6a60d4fa466f7b0d760dfc Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* | QListWidgetItem constructors: don't emit dataChanged(invalid, invalid)David Faure2019-04-231-2/+6
| | | | | | | | | | | | | | | | | | | | | | This is a regression introduced by 63967313f57add which blocked signals on the view, but not on the model. Change-Id: Ib2f93fe6ef842264aaba200c98ee4a19065ca220 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Konstantin Shegunov <kshegunov@gmail.com> Reviewed-by: Laurent Montel <laurent.montel@kdab.com> Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* | QHeaderView: fix assert when restoring section sizes over less columnsDavid Faure2019-04-231-7/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | If columns are removed and we get notified via layoutChanged, the code tries to restore old section sizes, and went out of bounds, leading to an assert in QVector. Simply add an if() to skip restoring out-of-bounds columns. This comes from https://bugs.kde.org/show_bug.cgi?id=395181, which translates into the unittest that is part of this commit. Change-Id: Ide42176a758f87b21957c40508127d67f1d5a2d9 Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de> Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Liang Qi2019-04-167-16/+46
|\| | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/tools/qlocale.qdoc tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp Done-with: Edward Welbourne <edward.welbourne@qt.io> Done-with: Volker Hilsheimer <volker.hilsheimer@qt.io> Change-Id: I88e0757b2d020f0a244714c87844631df4b3fd13
| * QStyleSheetStyle::repolish: only run on direct childrenFrederik Gladhorn2019-04-121-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | When re-parenting, some widgets change their children. For example QLabel, when set to rich text, will not update, until receiving a polish call, at which time getting a list of all children recursively and then trying to call functions on them will crash, since the children change in the middle of this operation. Fixes: QTBUG-69204 Fixes: QTBUG-74667 Change-Id: I95dd83ebeed14c017e22552ddd47658ae8a09353 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * Fix effects for highdpi graphical itemsAlexander Volkov2019-04-103-6/+9
| | | | | | | | | | | | | | | | Create a highdpi pixmap as a source for graphical effects. Fixes: QTBUG-74963 Change-Id: Ie144df3dbe61421fb28e639e640857aca6e6320f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| * Doc: Note Q[Plain]TextEdit keeping formatting in some casesKai Koehne2019-04-102-8/+31
| | | | | | | | | | | | Fixes: QTBUG-72427 Change-Id: Ifddabb175c480b64282bd8c8fdb9edab4c7ecf44 Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
| * Fix context loss in QOpenGLWidget upon tlw change with AA_ShareOpenGLContextsLaszlo Agocs2019-04-091-1/+2
| | | | | | | | | | | | | | | | | | | | The logic introduced in 2ea90c56 has an issue: it resets (destroy the context and co.) upong TLW change even when AA_ShareOpenGLContexts is set, and that is just wrong and goes against what the docs claim. Fixes: QTBUG-74307 Change-Id: Ib519045c1d9842664cbe602d4e6425660cf638b5 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Merge "Merge remote-tracking branch 'origin/5.12' into 5.13" into ↵Liang Qi2019-04-106-48/+31
|\ \ | | | | | | | | | refs/staging/5.13
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-106-48/+31
| |\| | | | | | | | | | Change-Id: I44eda44bf424fdcffab048a2534905d6162e5559
| | * QTableView: don't draw additional grid lines top and leftChristian Ehrlicher2019-04-091-23/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QTableView drew additional grid lines on the top and left side when the corresponding header was not visible and the ScrollMode was ScrollPerItem. After 8f2bacea41443af8564ff78f284016b6615a001b they were also drawn for ScrolPerPixel for consistency. But they are not needed at all and only create visual artifacts. Therefore remove the drawing of the additional lines completely. Fixes: QTBUG-74706 Change-Id: I5c77d53a2eeefab9b9bfe0efea6439f5afede4ac Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Andy Shaw <andy.shaw@qt.io>
| | * QTableView: fix Ctrl+End behavior with disabled columnsChristian Ehrlicher2019-04-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ctrl+End moves the visual index to the bottom left index. This does not work correctly when the item in the bottom left is disabled. It should be fixed with 7863be311570fa219066df5fe8720d5b92ddb680 but does not due to a typo. Fix the typo by using the newly calculated visualColumn instead the initial column. There are cases where the algorithm still does not work as expected when there are more disabled items but fixing them would add a lot of complexity with no (much) gain. Fixes: QTBUG-72400 Change-Id: Ie90f6b3e41e00f54e826c2b4e7303e85ac1e4115 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
| | * QMenu/QComboBox: Extract helper for determining the pop up geometryFriedemann Kleint2019-04-085-24/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move the code returning whether a popup should use the full screen to QStylePrivate and use for QMenu and QComboBox. Task-number: QTBUG-73231 Change-Id: I1901ecedfa90edf16329ce3b13ef4abea5ab44e8 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | | Update precompiled headersAllan Sandfeld Jensen2019-04-091-31/+7
|/ / | | | | | | | | | | | | | | Include many headers that are commonly used now, and avoid listing them twice. Change-Id: I679dc24cff2cb3a3c9c18585ec78007ab3550743 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-091-2/+0
|\| | | | | | | Change-Id: I05d14a40e17554691bad369d0363e88413afd9b3
| * Merge remote-tracking branch 'origin/5.12.3' into 5.12Qt Forward Merge Bot2019-04-081-2/+0
| |\ | | | | | | | | | Change-Id: Id60d508c0f25fd5e67be07daafd2d4c56ae73934
| | * Drag'n'Drop: fix dnd regressionGatis Paeglis2019-03-261-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | DragEnter events always should start with the default state, which is accepted = false. This was a copy-and-paste error introduced by f8944a7f07112c85dc4f66848cabb490514cd28e. Fixes: QTBUG-73977 Change-Id: I34b3ea97c9b4f4fc040a9e6f1befd6124533361d Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-062-1/+8
|\| | | | | | | | | | | Change-Id: Iec860bb703f983b7438e67c695b9c454e72b3e0f
| * | Add missing _exit tracepoints for event handlingMilian Wolff2019-04-052-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows tools that look for matching `foo_entry/exit` pairs in the trace data to work properly. An unmatched `_entry` would otherwise confuse them, making them think that the call stack is continuously increasing. Change-Id: Idff7f587ea25c46ec86ad623cc82d503db34a194 Reviewed-by: Christoph Sterz <christoph.sterz@kdab.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * | Forward declare all types required for compilation with `-trace`Milian Wolff2019-04-051-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes compilation with `-trace lttng` or `-trace etw`. We need to forward declare QEvent, QImageReader etc., otherwise the types will be unknown while compiling the trace points. In order to handle this generically, the tracegen utility is extended to support a 'prefix text' in the `*.tracepoints` input files. Any text within curly braces will be embedded as-is in the generated file. This can then be used to add forward declarations for the types we need, including potential namespaces and such. Change-Id: I5cb16763ce0fcb48ce3ea4577578d468ff3a4f4b Reviewed-by: Konstantin Tokarev <annulen@yandex.ru>
* | | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-051-2/+0
|\| | | | | | | | | | | Change-Id: I010a6322d12e038fdce247a58dfb05e204c2ff3b
| * | Remove superfluous inclusion of qtwidgets-config.priJoerg Bornemann2019-04-041-2/+0
| | | | | | | | | | | | | | | | | | | | | Every module already includes its own config. Change-Id: I1ef630092f61f118d79dc9b39ce38f4bdea14f43 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* | | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-042-2/+2
|\| | | | | | | | | | | Change-Id: Ia7328524f2cd9d5995ac8705f0fe0bf570b2e831
| * | Doc: Use the \nullptr macro instead of 0Venugopal Shivashankar2019-04-022-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | This enables overriding the macro so that it translates to 'None' in the Qt for Python context. Change-Id: Ib3cecf57eeb0405a1929309b71e9f012a07f11cf Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* | | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-021-1/+8
|\| | | | | | | | | | | Change-Id: Ia5d893e57deb78bc32e2053a5a79543ff847fe32
| * | QMacStyle - fix PE_InticatorTabClose handlingTimur Pocheptsov2019-04-011-1/+8
| |/ | | | | | | | | | | | | | | | | | | | | | | | | for the case a custom style sheet is in use and QStyleSheetStyle replaces the widget (close button) with its parent (QTabBar). We still need this button though to compare against tabButton on a hovered tab. This allows us to have, indeed, native-looking tabs as documented (aka similar to Safari or the "Terminal" application). Change-Id: I53ff78699e705db6d7c7b84774b8e188a1277535 Fixes: QTBUG-61092 Fixes: QTBUG-74689 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* | QListWidget: don't hide setBackgroundColor with QT_DISABLE_DEPRECATED_SINCEChristian Ehrlicher2019-03-311-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | QListWidget::setBackgroundColor() is a virtual function. Hiding this function when compiling/linking against QtWidgets when QT_DISABLE_DEPRECATED_SINCE is set will therefore screw up the vtable and it will crash on runtime. Therefore don't surround them with QT_DEPRECATED_SINCE macro. Fixes: QTBUG-74665 Change-Id: Icb0f253117a1e55a338d2d6969ec2d59fbd0679d Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> Reviewed-by: David Faure <david.faure@kdab.com>
* | QDoubleSpinBox: reset size hint when prefix is setChristian Ehrlicher2019-03-261-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | QDoubleSpinBox did not resize when setPrefix() was called because the cached size hint was not reset. Fix it by resetting the cached size hints and update the geometry the same way it's done for QSpinBox::setPrefix(). Fixes: QTBUG-74520 Change-Id: I6f42a24ab0a4ce987ecbe1505a634d929474436b Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Friedemann Kleint2019-03-261-1/+6
|\| | | | | | | Change-Id: I71cc71881fb638e207d83a8733bad8f267701c0f
| * Windows: Fix tooltip flicker on GL surfacesFriedemann Kleint2019-03-211-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QPlatformWindow::initialGeometry() would assign a default height to the initial geometry of the QRollEffectClassWindow since it has height of 0. This causes the obtained geometry to not match and subsequently a geometry change being sent synchronously. Introduce a new flag QWindowPrivate::resizeAutomatic similar to the existing QWindowPrivate::positionAutomatic to prevent assigning a default size and pass through the geometry as is where required. Fixes: QTBUG-74176 Change-Id: I70c66490838a2c4dfe200ec86094d28bd984dd03 Reviewed-by: Kati Kankaanpaa <kati.kankaanpaa@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | QDockWidget: Store tab position when undockingFriedemann Kleint2019-03-253-11/+53
| | | | | | | | | | | | | | | | | | Add a field remembering the tab position of the dock widget area to QDockWidgetPrivate and use that when grouping floating docks. Fixes: QTBUG-74242 Change-Id: I2a453080cb39dd4a5491976f1aeca70ae681682a Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | QDockWidgetPrivate: Use member initializationFriedemann Kleint2019-03-251-13/+6
| | | | | | | | | | | | Task-number: QTBUG-74242 Change-Id: I9f243bf37c7685e38a4a961c1173d45925b1b0e3 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | QDialog: be more specific on how to replace deprecated functionsChristian Ehrlicher2019-03-201-5/+5
| | | | | | | | | | | | | | | | | | | | | | QDialog::setOrientation/setExtension() was marked as deprecated without a suggestion on how to replace those functions. Therefore add a suggestion (taken from the documentation) now. Change-Id: I13b2af2264064ca1c7c034cf6b920caaadcee113 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-03-205-14/+22
|\| | | | | | | | | | | | | | | | | | | Conflicts: src/gui/kernel/qplatformintegration.cpp src/gui/kernel/qplatformintegration.h src/plugins/platforms/wasm/qwasmintegration.cpp src/plugins/platforms/xcb/qxcbconnection_screens.cpp Change-Id: I15063d42e9a1e226d9d2d2d372f75141b84c5c1b
| * Fix memory leak when unregistering a gesture recognizerAndy Shaw2019-03-192-5/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When a gesture was unrecognized, then it would add itself to the obsolete gestures hash. This was cleaned up only on application exit, but as the unregister call happens whenever a widget that had registered gestures was deleted then the hash could grow quite considerably. In order to ensure the original intention of the code here, we only call unregisterGestureRecognizer() when there is a QGestureManager in place to call it on. Otherwise it would create a memory leak in itself. Change-Id: I2342f3f737b28be4af7ed531d83f02197eb66c0e Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
| * Improve documentation for opaque resize in QSplitterJan Arve Sæther2019-03-182-6/+6
| | | | | | | | | | | | | | This also fixes the documentation for QStyle::SH_Splitter_OpaqueResize Change-Id: If8afb52ae300e9735a8bc6b065327f17d67f4323 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
| * Merge remote-tracking branch 'origin/5.12.2' into 5.12Qt Forward Merge Bot2019-03-151-3/+10
| |\ | | | | | | | | | Change-Id: I5f9d8090a07056411fb65d7de60eb679d00e99a3
| | * Merge 5.12 into 5.12.2Kari Oikarinen2019-02-201-0/+1
| | |\ | | | | | | | | | | | | Change-Id: I3a5721aebd3afd8fa08d3f3df6bf61502fa9c347
| | * | Fix QSplashscreen positioning on AndroidFriedemann Kleint2019-02-191-3/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Android does not use QPlatformWindow::initialGeometry(), so the underlying assumption of 56e92dfdf255231aff0034d2e197fd096da7f0c0 was wrong. Try to explicitly find a screen and default to primary. Fixes: QTBUG-73794 Change-Id: Iba3e70657a60babfcedf751335ca55cb971a4f99 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | | | Fix some qdoc warningsFriedemann Kleint2019-03-154-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | src/network/ssl/qsslsocket.cpp:1501: (qdoc) warning: Can't link to 'QSslConfiguration::defaultCaCertificates()' src/network/ssl/qsslsocket.cpp:1482: (qdoc) warning: Can't link to 'QSslConfiguration::defaultCaCertificates()' src/network/ssl/qsslsocket.cpp:1513: (qdoc) warning: Can't link to 'QSslConfiguration::defaultCaCertificates()' src/network/ssl/qsslsocket.cpp:1119: (qdoc) warning: Can't link to 'QSslConfiguration::setDefaultCiphers()' src/network/ssl/qsslsocket.cpp:1119: (qdoc) warning: Can't link to 'QSslConfiguration::defaultCiphers()' src/gui/opengl/qopengltexture.cpp:4137: (qdoc) warning: Can't link to 'setComparisonFunction()' src/widgets/dialogs/qfilesystemmodel.cpp:1215: (qdoc) warning: Undocumented return value (hint: use 'return' or 'returns' in the text src/widgets/graphicsview/qgraphicswidget.cpp:1229: (qdoc) warning: Undocumented return value (hint: use 'return' or 'returns' in the text src/widgets/graphicsview/qgraphicsscene.cpp:3313: (qdoc) warning: Undocumented return value (hint: use 'return' or 'returns' in the text src/gui/painting/qpaintengine_raster.cpp:3438: (qdoc) warning: Undocumented return value (hint: use 'return' or 'returns' in the text src/widgets/widgets/qtextedit.cpp:2544: (qdoc) warning: Overrides a previous doc src/widgets/widgets/qplaintextedit.cpp:2932: (qdoc) warning: (The previous doc is here) Change-Id: I0c68c59a87eb6a5d9e974f857af6aca0c6e0672d Reviewed-by: Paul Wicking <paul.wicking@qt.io>