summaryrefslogtreecommitdiffstats
path: root/src/widgets/widgets
Commit message (Collapse)AuthorAgeFilesLines
* Fix build without features.completerTasuku Suzuki2020-06-051-0/+2
| | | | | Change-Id: Icaed1963d6306e36653d01ad9d05b68cb50717e5 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* QLabel: create the text control when getting polished, if necessaryVolker Hilsheimer2020-06-041-0/+3
| | | | | | | | | | | | This amends 7bee4e9cb3750be4573e1872f52023081b014500, and makes sure that the text control is created even if the attributes that define whether it's needed are changed after a call to setText or setTextInteractionFlags, where it is otherwise created. Task-number: QTBUG-84080 Pick-to: 5.15 Change-Id: I3be27f35bc83944948027345535d1202a7b97163 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* Fix build without features.menuTasuku Suzuki2020-06-041-3/+2
| | | | | | | qaction_widgets.cpp needs qwidget_p.h for qWidgetShortcutContextMatcher. Change-Id: I9144a4158af2f25f20b6f13badd0ddcd50075b67 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Fix QTabBar crash with offscreen platform pluginFilipe Azevedo2020-05-261-0/+2
| | | | | | | | | The offscreen implementation does not have a QPlatformNativeInterface implementation. Pick-to: 5.15 Change-Id: Ife4f296f52c307a2fab90de2cdc1ef0cc7796385 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Reduce QDesktopWidget API to bare minimumVolker Hilsheimer2020-05-155-10/+10
| | | | | | | | | | | | | | | | | The class is documented as obsolete, and the majority of APIs is marked as deprecated. In this first phase, remove all explicitly deprecated APIs and trivial implementations. The test case is complete removed; what's left when code that uses any of those deprecated methods is removed is not testing anything meaningful. For some methods, there is no practical replacement using QScreen yet, and QDesktopWidget is still used in QWidget internals. Those require refactoring to only use QScreen before the rest can be removed. Change-Id: I8f7c968ec566820077221d37b817843758d51d49 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Use correct order of arguments when calling QCalendar::daysInMonth()Andy Shaw2020-05-151-5/+5
| | | | | | | Change-Id: Ic4e30d8ffea80c1dc1dc8da1f97f4bb0d21b63e3 Pick-to: 5.15 Fixes: QTBUG-83870 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Add an option to set the alignment of the text in QComboBoxAndy Shaw2020-05-151-1/+5
| | | | | | Change-Id: Ic9dca8864643302b2b3ff7dbd86260efdb0ab1d5 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* QLabel: lay out text using a text control when label can get focusVolker Hilsheimer2020-05-151-1/+3
| | | | | | | | | | | | | | | | QLabel ensures a text control in its focusInEvent, and from that point on lays the text out using the control. A label with text control will place the text so that there is space for a cursor and text selection, resulting in text shifting when a label receives focus without having had a text control before. Instead of creating the control only on focusIn, ensure that it's created for any QLabel that can receive focus. Change-Id: I26c9df3affa08f2360ad4b94de43bd85e2e2e164 Fixes: QTBUG-84080 Pick-to: 5.15 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* Remove QTextCodec dependency from QTextBrowserLars Knoll2020-05-141-11/+8
| | | | | | | | | | | Use QStringConverter instead to convert HTML to a QString. This limits the amount of supported encodings to UTF based encodings and Latin1. This is ok, as anything but utf8 is strongly discouraged by the HTML spec anyway, and the support we have with this change does cover ~98% of all real world HTML. Change-Id: Ia610d327624b083c23d3c604aee70517a4a5eb6a Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Make qtbase compile without QT_CONFIG(timezone)Andrei Golubev2020-05-111-1/+4
| | | | | | | | Fixes: QTBUG-83795 Pick-to: 5.15 Change-Id: I05eaaf57d87a9111d3609ebab81bc707f8af98f0 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Remove dead code from src/widgetsVolker Hilsheimer2020-05-1110-59/+6
| | | | | | | | Code that's removed via QT_VERSION(6, 0, 0) check is already no longer compiled. Change-Id: I70865f330a6260ac2e9cf2770d599a5b6f7bb7d4 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* QMenuPrivate::hideMenu - avoid deleting 'q' too earlyTimur Pocheptsov2020-05-081-0/+30
| | | | | | | | | | | | | | | | This function among other things enters a nested event loop twice. With enough luck processing events may end with posting deferred delete event for 'q' and then ... executing this event leaving the whole call tree with a dangling pointer. This is not very convenient, and we filter out such events to re-post them a bit later. Pick-to: 5.15 Fixes: QTBUG-82349 Change-Id: Ic620273b529b89f2bd57e25df1f91c2754940670 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Merge QStyleOptionTabV4 into QStyleOptionTabGiuseppe D'Angelo2020-05-081-9/+8
| | | | | | | | | We don't need the subclass any more now that we can break ABI. Merge it back into the "main" style option class, like already happened during Qt 4->5. Change-Id: Iba6d3df5f87b0c96f01746260f0a93951dad0e27 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* QComboBox: Remove deprecated auto-completion propertiesVolker Hilsheimer2020-05-063-147/+26
| | | | | | | | | | | | The replacement is to set, and configure, a QCompleter directly via setCompleter. With the removal of the separate properties in QComboBox, the configuration of the completer is not maintained if the line edit is replaced. A QCompleter is created and set implicitly when the line edit is set, unless the line edit came with a completer. This is what the auto test verifies as well. Change-Id: I9a4c73db5e39a2558aad346c0904be6deb4f1cd2 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Fix Clang 10 warning about misleading indentationThiago Macieira2020-05-051-2/+2
| | | | | | | | qcombobox.cpp:3282:13: error: misleading indentation; statement is not part of the previous 'if' [-Werror,-Wmisleading-indentation] Pick-To: 5.15 Change-Id: I99ab0f318b1c43b89888fffd160b5a7310c0a0d0 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* Explicitly prevent out-of-bounds access to tabPositions arrayVolker Hilsheimer2020-05-052-2/+6
| | | | | | | | | | | Use DockCount enum value for the size of the array, and explicitly handle when toDockPos returns DockCount (which it might). Change-Id: Id52399607fb1ae74a24a050de7a8481264c03e47 Fixes: QTBUG-83983 Coverity-Id: 218539 Pick-to: 5.15 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Long live QHVContainer!Marc Mutz2020-05-051-1/+2
| | | | | | | | | | | | | | | | | | Various places in Qt use arrays indexed by some function of Qt::Orientation input. None document their dependence on the numerical values of the Qt::Orientation enum, some waste space, none is type-safe. QHVContainer is a private container of two values, one for Qt::Horizontal and one for Qt::Vertical. Its salient API is the indexing operator, taking Qt::Orientation, thus making the class type-safe. Use it to port QGridLayoutItem and QAbstractScrollAreaPrivate. Change-Id: I0d9f17431a5eb141bfb0763c83155710bb82a537 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* QAbstractScollArea: Cast an enumerator to int before doing math on itGiuseppe D'Angelo2020-05-051-1/+1
| | | | | Change-Id: I78288c7d104a33936b6f1f3f7bff9a076845cfc8 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Merge remote-tracking branch 'origin/5.15' into devQt Forward Merge Bot2020-05-041-2/+11
|\ | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/text/qlocale.cpp src/network/access/qnetworkaccessmanager.cpp Regenerated tests/auto/testlib/selftests/float/CMakeLists.txt Change-Id: I5a8ae42511380ca49a38b13c6fa8a3c5df8bed01
| * Always open a submenu on the same screen where the parent menu isShawn Rutledge2020-04-271-2/+11
| | | | | | | | | | | | | | | | | | | | | | We've seen submenus opening on different screens in different scenarios, but probably there's never a sensible reason to do that. QWidgetPrivate::setScreenForPoint() can often give incorrect results in multi-screen desktop configurations; this is a way of avoiding that. Task-number: QTBUG-76162 Change-Id: I895696c6858ad953258c84b21117beea4c4fc01d Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* | QWidgetLineControl: replace raw memory handling with std::unique_ptrMarc Mutz2020-04-302-7/+4
| | | | | | | | | | | | Change-Id: I131175a9f7147783c4f4c0a1c4929e28677c159a Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | QtWidgets: fix a few more int/char -> QChar conversionsMarc Mutz2020-04-304-12/+10
| | | | | | | | | | | | | | | | | | | | They were masked by all QChar ctors being made explicit, except the char16_t one, which was left as the only viable choice. Change-Id: I210d50dc243391ad2c7dd353ba9ae40147585d04 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* | Enable Qt 5 connection syntax for QAbstractButton::animateClick()Friedemann Kleint2020-04-292-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Slot QAbstractButton::animateClick() is commonly connected to signal QLineEdit::returnPressed() in dialogs. The function had a parameter with a default for specifying the delay which requires a lambda when using Qt 5 connection syntax. Since the default value is used practically everywhere, remove the parameter. [ChangeLog][QtWidgets][QAbstractButton] The interval parameter has been removed from QAbstractButton::animateClick(). Task-number: QTBUG-81845 Change-Id: I4e399138b6aa3a9f0b31c1f10de97ffcbab6a337 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | Always open a text control's context menu on the same screenShawn Rutledge2020-04-291-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's very disorienting when a context menu pops up on a different screen from where the right mouse button was clicked. QWidgetPrivate::setScreenForPoint() can give incorrect results in multi-screen desktop configurations; but we can give the menu a hint by setting initialScreenIndex, which was originally used only when QDesktopScreen or QDesktopScreenWidget is the parent (see b3fc5e1ea3eb4fe838ac716aaca4efaa5de5a814 ). Task-number: QTBUG-76162 Pick-to: 5.15 Pick-to: 5.12 Change-Id: Icd4abdc32564430147e6c63a8ea70d483d25cddd Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | Remove deprecated QComboBox::SizeAdjustPolicy enum valueVolker Hilsheimer2020-04-272-23/+4
| | | | | | | | | | Change-Id: Ia8ae2eb11b86bc615e1297d7fabd1afcb821557c Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | QMainWindow: don't grow memory when modifying tabbed docks while hiddenVolker Hilsheimer2020-04-241-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QMainWindow tries to avoid memory allocations by caching tab bars that are no longer used. That cache is populated when the layout is activated. The layout might never be activated when the main window is never shown, in which case adding and removing dock widgets at runtime will continuously allocate more memory for tab bars that are created. A workaround is to call QMainWindow::layout()->activate() explicitly in application code, once all dock widgets have been removed. This change avoids that applications have to do that. Change-Id: I70eb585d2120f0b7b73f59c3ee65d7242c12ec59 Fixes: QTBUG-83135 Pick-to: 5.15 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | Merge remote-tracking branch 'origin/5.15' into devQt Forward Merge Bot2020-04-233-0/+15
|\| | | | | | | Change-Id: Iaa439ba7dff19a17e3716b3d30f49f60fa6e38f8
| * Merge "Merge remote-tracking branch 'origin/5.14' into 5.15"Liang Qi2020-04-221-0/+2
| |\
| | * Merge remote-tracking branch 'origin/5.14' into 5.15Liang Qi2020-04-221-0/+2
| | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 3a6d8df5219653b043bd642668cee193f563ec84. That change is only for 5.14. Conflicts: src/plugins/platforms/wasm/qwasmeventtranslator.cpp src/plugins/platforms/wasm/qwasmintegration.cpp src/plugins/platforms/wasm/qwasmopenglcontext.cpp src/plugins/platforms/wasm/qwasmscreen.cpp Change-Id: Ib9151e199291fe6eb4151027b515393c05303d65
| | | * widgets: Re-calculate focus frame style option after setting new geometryTor Arne Vestbø2020-03-241-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: QTBUG-83019 Change-Id: I75d3d93732cb0c5a5b7350f19f0227998bda4791 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| * | | Handle specified time-spec in date-time parsingAndrei Golubev2020-04-222-0/+13
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a date-time was parsed from a string, the result was equal (as a date-time) to the correct value, but had (at least in some cases) the wrong spec, where it should have had a spec reflecting the zone specifier parsed. The time-spec imposed for the benefit of QDateTimeEdit is now moved from QDateTimeParser to QDateTimeEditPrivate, which takes over responsibility for imposing it. QDateTimeParser assumes Qt::LocalTime in member functions (where applicable) and uses the time-spec parsed from the string when constructing the date-time. QDateTime::fromString() and QLocale::toDateTime() are updated to use the full QDateTime returned by QDateTimeParser. Fixes: QTBUG-83075 Done-With: Edward Welbourne <edward.welbourne@qt.io> Change-Id: I8b79add2c7fc13a200e1252d48dbfa70b36757bf Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | | Merge remote-tracking branch 'origin/5.15' into devQt Forward Merge Bot2020-04-229-17/+78
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/widgets/widgets/qabstractbutton.cpp src/widgets/widgets/qbuttongroup.cpp src/widgets/widgets/qbuttongroup.h src/widgets/widgets/qsplashscreen.cpp tests/auto/widgets/widgets/qbuttongroup/tst_qbuttongroup.cpp tests/benchmarks/opengl/main.cpp Needed update: src/plugins/platforms/cocoa/CMakeLists.txt Change-Id: I7be4baebb63844ec2b3e0de859ca9de1bc730bb5
| * | doc: Recommend the QSplashScreen constructor taking a QScreen*Shawn Rutledge2020-04-151-1/+1
| | | | | | | | | | | | | | | | | | | | | Amends 49362d064fffe350600f5324fb510b381578d04a Change-Id: If217af44cf6ebe8ebed37bbd927ac311b23d8c0e Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| * | Add QButtonGroup::idClicked/Pressed/Released/Toggled signalsVolker Hilsheimer2020-04-153-8/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Following the deprecation of the signal overloads, the remaining signals did not provide equivalent functionality for connecting a slot expecting an integer. The mapping from QAbstractButton* to the ID is comparatively cumbersome to do in the connected slot. Add uniquely named signals that emit the ID of the button directly. [ChangeLog][QtWidgets][QButtonGroup] Added signals idClicked/Pressed/Released/Toggled that replace the deprecated signal overloads. Change-Id: I77215e4f815c4fb7dd6326e1f431230e6601e8f8 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| * | Deprecate QMacNativeWidget and QMacCocoaViewContainerTor Arne Vestbø2020-04-145-5/+11
| | | | | | | | | | | | | | | Change-Id: I489870f97dcf7b54a4427ead3a9e627dd938f4ca Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* | | Port QT_NO_TOOLTIP to QT_CONFIG(tooltip)Joerg Bornemann2020-04-2113-33/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We remove the QT_NO_TOOLTIP check from qstandarditemmodel.h, because as the 'tooltip' feature is in QtWidgets, we cannot use it properly in QtGui. Also this affects just two non-virtual inline methods, i.e. it has no effect on library size. Task-number: QTBUG-82785 Change-Id: Ic166f14fb1cf3e9dd789573a6b9db6a87fb50e10 Reviewed-by: Tasuku Suzuki <tasuku.suzuki@kdab.com> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* | | Always encode HTML as utf-8Lars Knoll2020-04-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | When converting a text document to HTML, always convert it to utf-8, as required by the HTML standard. This also means that we remove the optional encoding parameter. Change-Id: I0bd2fc9df2d06734e1c5b8053b964fbfbb6881e1 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Don't fall back to QGuiApplication for line control's layoutDirectionEdward Welbourne2020-04-211-5/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the widget whose line control we are has its own locale setting, then we should use that rather than the default UI layout direction. Instead, the client of the QWidgetLineControl needs to handle the case where auto-detection of the text direction can't be done based on the content of the line control. Fortunately, QWidget's handling of text direction handles setting to auto gracefully as unsetting, on which it consults the parent widget to set a sensible default. Change-Id: Id0d247f1e6e7219b6d0ece5856ca93ee87778c74 Pick-to: 5.15 Fixes: QTBUG-53110 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* | | Fix QLabel with no "picture" featureNodir Temirkhodjaev2020-04-191-0/+2
| | | | | | | | | | | | | | | Change-Id: I97bc58438791402168bcc58326f199b5675e75ff Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | | Remove deprecated members from QtWidgets/widgets classesVolker Hilsheimer2020-04-1715-248/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Cleaning up those that are trivial to remove because they have direct replacements. The QLabel changes to the pixmap/picture getters provide the following migration path: QPixmap *ppix = l->pixmap(); // up to 5.15, warns in 5.15 QPixmap pval = l->pixmap(Qt::ReturnByValue); // new in 5.15, works in 6 QPixmap pixmap = l->pixmap(); // from Qt 6 on The overload with argument can be deprecated after the first LTS or so. Change-Id: I8494ceeea55b2aeda0bd340640ad95cb7c91f7d6 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | | Merge remote-tracking branch 'origin/5.15' into devQt Forward Merge Bot2020-04-111-3/+14
|\| | | | | | | | | | | | | | | | | | | | Conflicts: tests/auto/network/socket/platformsocketengine/platformsocketengine.pri Change-Id: I22daf269a8f28f80630b5f521b91637531156404
| * | Fix warning about deprecated QComboBox::AdjustToMinimumContentsLengthThiago Macieira2020-04-091-3/+14
| | | | | | | | | | | | | | | Change-Id: Ibdc95e9af7bd456a94ecfffd1603f5c25dabf78e Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | | QApplication: remove obsolete globalStrut functionalityVolker Hilsheimer2020-04-1020-52/+30
| | | | | | | | | | | | | | | | | | Change-Id: If56873f86f5291264cac720f8db7dbd4db756f49 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | | Merge "Merge remote-tracking branch 'origin/5.15' into dev"Qt Forward Merge Bot2020-04-0815-50/+71
|\ \ \
| * | | Merge remote-tracking branch 'origin/5.15' into devQt Forward Merge Bot2020-04-0815-50/+71
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: examples/opengl/doc/src/cube.qdoc src/corelib/global/qlibraryinfo.cpp src/corelib/text/qbytearray_p.h src/corelib/text/qlocale_data_p.h src/corelib/time/qhijricalendar_data_p.h src/corelib/time/qjalalicalendar_data_p.h src/corelib/time/qromancalendar_data_p.h src/network/ssl/qsslcertificate.h src/widgets/doc/src/graphicsview.qdoc src/widgets/widgets/qcombobox.cpp src/widgets/widgets/qcombobox.h tests/auto/corelib/tools/qscopeguard/tst_qscopeguard.cpp tests/auto/widgets/widgets/qcombobox/tst_qcombobox.cpp tests/benchmarks/corelib/io/qdiriterator/qdiriterator.pro tests/manual/diaglib/debugproxystyle.cpp tests/manual/diaglib/qwidgetdump.cpp tests/manual/diaglib/qwindowdump.cpp tests/manual/diaglib/textdump.cpp util/locale_database/cldr2qlocalexml.py util/locale_database/qlocalexml.py util/locale_database/qlocalexml2cpp.py Resolution of util/locale_database/ are based on: https://codereview.qt-project.org/c/qt/qtbase/+/294250 and src/corelib/{text,time}/*_data_p.h were then regenerated by running those scripts. Updated CMakeLists.txt in each of tests/auto/corelib/serialization/qcborstreamreader/ tests/auto/corelib/serialization/qcborvalue/ tests/auto/gui/kernel/ and generated new ones in each of tests/auto/gui/kernel/qaddpostroutine/ tests/auto/gui/kernel/qhighdpiscaling/ tests/libfuzzer/corelib/text/qregularexpression/optimize/ tests/libfuzzer/gui/painting/qcolorspace/fromiccprofile/ tests/libfuzzer/gui/text/qtextdocument/sethtml/ tests/libfuzzer/gui/text/qtextdocument/setmarkdown/ tests/libfuzzer/gui/text/qtextlayout/beginlayout/ by running util/cmake/pro2cmake.py on their changed .pro files. Changed target name in tests/auto/gui/kernel/qaction/qaction.pro tests/auto/gui/kernel/qaction/qactiongroup.pro tests/auto/gui/kernel/qshortcut/qshortcut.pro to ensure unique target names for CMake Changed tst_QComboBox::currentIndex to not test the currentIndexChanged(QString), as that one does not exist in Qt 6 anymore. Change-Id: I9a85705484855ae1dc874a81f49d27a50b0dcff7
| | * | macOS: Remove all use of deprecated Q_OS_OSX defineTor Arne Vestbø2020-04-0310-26/+26
| | | | | | | | | | | | | | | | | | | | Change-Id: I49c285604694c93d37c9d1c7cd6d3b1509858319 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
| | * | QLineEdit: clarify the impact of using validatorsVolker Hilsheimer2020-04-011-4/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Values that are validated as Intermediate are possible to enter, but returnPressed and editingFinished signals are not emitted. Fixes: QTBUG-82915 Change-Id: I3e194cd6ee93b3402090117b67044cf3663a232e Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
| | * | QTextEdit: remove the cursor when a read-only textedit looses focusVolker Hilsheimer2020-03-271-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A read-only text edit with Qt::TextSelectableByKeyboard shows a steady cursor to indicate to users that they can select the text, but not edit it. When the control receives focus, it doesn't turn on blinking, but explicitly sets cursorOn to true. When focus is lost, then cursorOn needs to be reset to false to make the cursor disappear, even if the blinking (as indicated by the poorly named cursorVisible variable) is not on. Change-Id: I78408b5c50c6ede3f9a7128be7a31b9c6795cf9c Fixes: QTBUG-83029 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
| | * | QLineEdit: Include the horizontal margin in minimumSizeHintVolker Hilsheimer2020-03-261-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The margin is respected in the sizeHint, but not in the minimumSizeHint. Since the latter should be the former for a single character (as per the documentation promising enough space for one character), the margin calculation needs to be identical. Adjusting the documentation nevertheless, as there are characters that won't fit either way. As reported, the permyriad character doesn't fit even with this fix on macOS, as the core graphics API we are using doesn't report a glyph-index for U+2031 (so our existing assumption that 'W' is the widest character is still the best we can do). Change-Id: I30573960c316cc7b8c9bbe3c3f4c6351792bed36 Fixes: QTBUG-82970 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
| | * | Fix deprecation of QComboBox:::currentIndexChanged(const QString&)Lars Knoll2020-03-252-27/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Don't introduce another overload with two parameters. Users want a simple signal to connect to, not another overload. Deprecate the currentIndexChanged(QString) overload, usage of that can/should get replaced by currentTextChanged(). This partially reverts commit 11dc7b35c8c3957bd19087a5e3ae7cfc4f1a3343. Change-Id: I5e7d16413f3d62b1a5a7a197f510af2c45cdfa55 Reviewed-by: Vitaly Fanaskov <vitaly.fanaskov@qt.io>