summaryrefslogtreecommitdiffstats
path: root/src/widgets
Commit message (Collapse)AuthorAgeFilesLines
* Merge "Merge remote-tracking branch 'origin/5.5' into dev" into refs/staging/devFrederik Gladhorn2015-04-228-41/+128
|\
| * Merge remote-tracking branch 'origin/5.5' into devLiang Qi2015-04-228-41/+128
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/statemachine/qstatemachine.cpp src/corelib/statemachine/qstatemachine_p.h src/gui/painting/qdrawhelper.cpp src/plugins/platforms/xcb/qxcbnativeinterface.cpp src/plugins/platforms/xcb/qxcbwindow.cpp src/plugins/platforms/xcb/qxcbwindow.h src/testlib/qtestblacklist.cpp src/tools/qdoc/node.cpp src/tools/qdoc/node.h tests/auto/gui/painting/qcolor/tst_qcolor.cpp Change-Id: I6c78b7b162001712d5774293f501b06b4ff32684
| | * QFileDialog: save settings to FileDialog group instead of serializedShawn Rutledge2015-04-202-35/+120
| | | | | | | | | | | | | | | | | | | | | | | | | | | The byte array serialization needed versioning, whereas a collection of separate settings is more robust and accessible. Task-number: QTBUG-36888 Change-Id: I790b1d7574707261923a7a33ccd8bcc596a69de5 Reviewed-by: David Faure <david.faure@kdab.com>
| | * Enable checking for whether the system palette was explicitly setHarald Hvaal2015-04-201-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In order to obey a palette set globally on QApplication, an application attribute for checking if it's set at all is added. Task-number: QTBUG-39800 Change-Id: I26b965e6e18e0e1ca4df03cf343b3527df3636b2 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
| | * Avoid warnings with clang 6Laszlo Agocs2015-04-161-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | warning: 'this' pointer cannot be null in well-defined C++ code The code tries to be smart but compilers warn about this unfortunately. Change-Id: Ifb8deafe8834d580beef829a3079ae9222acfa8f Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
| | * Fix compilation error (OS X 10.8, warnings as errors)Timur Pocheptsov2015-04-161-1/+1
| | | | | | | | | | | | | | | | | | | | | Failed to compile on my OS X 10.8 (unused variable warning treated as error) Change-Id: I7ee881d4b905539361a10e93cff76b44ec08afbf Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
| | * QToolButton: Fix popup menu geometry in case of QGraphicsProxyWidget.Friedemann Kleint2015-04-091-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QDesktopWidget::availableGeometry(const QWidget *) returns the scene geometry when the widget is embedded into a QGraphicsProxyWidget. Work around by using the overload taking a point. Task-number: QTBUG-38559 Change-Id: Ie630bda57e14648255015587a04e29b0de96bab7 Reviewed-by: Arnaud Bienner <arnaud.bienner@gmail.com> Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
| | * Guard QWidget::setStyleSheet() against invocation from destructor.Friedemann Kleint2015-04-091-0/+2
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-45178 Change-Id: I3670d9cd9645155318b595d1324a3b3caf2352f6 Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
| | * Avoid leaking the QPlatformTextureListLaszlo Agocs2015-04-081-0/+1
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-45395 Change-Id: I8fbdc5136d7d15b9c131d6b91186a1bf2645e4d4 Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
* | | QWindowsStyle: Do not rely on the widget to draw the dock titleOlivier Goffart2015-04-221-1/+1
|/ / | | | | | | | | | | | | | | | | There is no need to query widget->isWindow when this information is present in the QStyleOption state (it is even set using isWindow in QStyleOption::init) Change-Id: I4f3bbdd9c70d6253e9301bc168d61c7ecdbfdc06 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* | Remove <qhash.h> where it's not usedMarc Mutz2015-04-207-6/+2
| | | | | | | | | | | | | | | | To avoid source-incompatibilites, wrap in QT_DEPRECATED_SINCE(5, 5) in public headers. Change-Id: I6117e8a6b11200d2f1a0a94a0e87d5c27538218e Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* | Allow for rearranging tabified QDockWidgetsOlivier Goffart2015-04-114-0/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Allow to drag and drop tabs [ChangeLog][QtWidgets][Important Behavior Changes] The tabs for the tabified docks can be moved by the user. Task-number: QTBUG-1049 Task-number: QTBUG-2295 Task-number: QTBUG-4532 Task-number: QTBUG-18883 Task-number: QTBUG-35148 Change-Id: I7ef9d4987db081654bd5d648e14370b3d381a720 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com> Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.5' into devLiang Qi2015-04-081-0/+2
|\| | | | | | | Change-Id: I04f9f2749f68c0cb5a427b8d84e43b44bb143e4d
| * Add Q_UNUSED for parameter (OS X)Timur Pocheptsov2015-04-071-0/+2
| | | | | | | | | | | | | | | | Ifdefs exclude the code on OS X, but there is still unused parameter and annoying compiler (either warning or error, depending on ...). Change-Id: I913c25b4f96ebe275a6b1d15873bccf4aebe9e7a Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
* | Merge "Merge remote-tracking branch 'origin/5.5' into dev" into refs/staging/devLiang Qi2015-04-0810-49/+97
|\ \
| * | Merge remote-tracking branch 'origin/5.5' into devLiang Qi2015-04-0610-49/+97
| |\| | | | | | | | | | Change-Id: If9fd98525b6b4ca07e5e006fc98bf372a73b8a21
| | * QComboBox: also adjust size on model reset, with AdjustToContentsDavid Faure2015-04-041-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the size adjust policy is QComboBox::AdjustToContents, the combobox sizeHint was recalculated on dataChanged, rowsInserted, rowsRemoved, and setModel, but not when the model was reset. This led to truncated items in the combobox when models are filled asynchronously. Task-number: QTBUG-5413 Change-Id: I3456c327d680dfffa58d6dcb26c79456c67b2a32 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
| | * QComboBox: open popup on touch release if QStyleHints has ↵Richard Moe Gustavsen2015-04-042-16/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | setFocusOnTouchRelease() If we give focus to the combobox on touch release, we need to await opening the popup until touch release as well. Otherwise we might end up showing a popup for an unfocused combobox. Especially on iOS, there is a strong coupling between focus object and popup menus, which means that we effectively require the combobox to gain focus before it can show the popup. Change-Id: Ifb7ba091bb39b77f325cdbf61e00ab3e8ff2e522 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
| | * Fix debug stream operators.Friedemann Kleint2015-04-011-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Use QDebugStateSaver to restore space setting in stream operators instead of returning dbg.space() which breaks formatting on streams that already have nospace() set. - Fix some single character string constants. Change-Id: I0fe86bb1adbdd4a76ab6d2f8c19e063b45ddcf3b Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
| | * Improve debug operator for QGraphicsItem/QGraphicsObject.Friedemann Kleint2015-04-011-13/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Introduce QDebugStateSaver, use new formatting helpers and output parent, flags and z only when necessary. Output the widget contained in QGraphicsProxyWidget. For example, QGraphicsProxyWidget (this = 0x1877550 , parent = 0x0 , pos = QPointF(870,491) , z = 1e+30 , flags = ( ItemIsFocusable | ItemUsesExtendedStyleOpton | ItemSendsGeometryChanges | ItemIsPanel ) ) becomes: QGraphicsProxyWidget(0x1877550, widget=ItemDialog(0x1e29dc0), pos=870,491, z=1e+30, flags=(ItemIsFocusable|ItemUsesExtendedStyleOption|ItemSendsGeometryChanges|ItemIsPanel)) Change-Id: Ia554dc3e2eb6f16d9d9220d1067194a4424b7cf5 Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
| | * Merge "Merge remote-tracking branch 'origin/5.4' into 5.5" into refs/staging/5.5Liang Qi2015-04-017-19/+22
| | |\
| | | * Merge remote-tracking branch 'origin/5.4' into 5.5Liang Qi2015-03-317-19/+22
| | | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: mkspecs/android-g++/qmake.conf qmake/generators/unix/unixmake2.cpp src/gui/image/qimage_conversions.cpp Change-Id: Ib76264b8c2d29a0228438ec02bd97d4b97545be0
| | | | * Fix use of the window geometry specificationAlexander Volkov2015-03-271-16/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Until now we applied the geometry in QWidget::setVisible() by calling QWidget::move() and QWidget::resize(). But these methods are unreliable when the window is created but not visible yet. For example, specifying the window position by "-geometry +0+0" will take no effect. Apply the geometry directly to QWindow in QWindow::setVisible(). QWidget will update its geometry after the response of the window system. Besides it allows to specify the geometry for QML applications. Task-number: QTBUG-44713 Change-Id: I9a0e110e81e569c81da802729707fec104fef887 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
| | | | * Doc: warn about resize event bugPaul Olav Tvete2015-03-211-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The resize event for QMdiSubWindow may occasionally have an invalid oldSize(). This has been the case since 2007. Fixing this looks like a high risk, low reward endeavour. Task-number: QTBUG-32446 Change-Id: I80ce43987c7b6e346cd44f7ac4cef01b01e5472b Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
| | | | * QComboBox: Update completer on setCurrentIndex()Andre Hartmann2015-03-181-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the ComboBox currentText() was changed by key LineUp or LineDown or mouse click, the completer still contained the last inserted characters. If now all text was selected (by Ctrl+A or selectAll()), the old item and index was restored on next Enter press. Task-number: QTBUG-41288 Change-Id: I6916fd31c8b8fbacfb12e1a62c3e46823cf918b4 Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
| | | | * Do not colorizing images to invalid premultiplied colorsAllan Sandfeld Jensen2015-03-161-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In some combinations the fusion style colorizeImage method would generate invalid colors causing odd colors in the end result. Task-number: QTBUG-41515 Change-Id: Ib16049be1f3e93ae4976524df2827076eac7d94f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com> Reviewed-by: Jens Bache-Wiig <jensbw@gmail.com>
| | | | * Workaround for programs depending on previous layout bugPaul Olav Tvete2015-03-111-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change 2bfee10f made QDockAreaLayout respect the maximum size of the central widget. This broke some existing programs which would set sizePolicy to Fixed on a central widget without a sizeHint. This patch restores the old behaviour for the special case where there are no dock areas. It is highly unlikely that the intention in this case is to have a very small central widget with huge blank areas on either side. Task-number: QTBUG-43797 Change-Id: I1e1fb17204f72166da3b0b054a7777e8183604a7 Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
| | | | * [Android]: Ensure clicking on the arrow shows the popupAndy Shaw2015-03-111-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was a problem with editable comboboxes specifically as there is an edit field area which is separate to the arrow. Giving a valid rectangle for the arrow allows QComboBox to know that it was clicked on. Task-number: QTBUG-44931 Change-Id: Ie1d06a6631d6c7f5e813419a5e76f67ec9dcd7e8 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
| | | | * Adjust wiki links to the new redirectSergio Ahumada2015-03-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | it looks nicer this way Change-Id: I872976bdef5f581187a758aa92b02e2f5f32b130 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* | | | | QErrorMessage: sort statements in ctorMarc Mutz2015-04-071-13/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This has no influence on text size, but by executing similar functions temporally close to each other, we should make better use of the i-cache. It's also more readable. Change-Id: Ia211e562d798d4f16f3fd17f87f1e2cad2e0359d Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* | | | | QErrorMessage: streamline conditionals in done()Marc Mutz2015-04-071-5/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ...to avoid checking the same conditions a second time. Saves 32B in text size on my machine, too. Change-Id: I0368408b9f5feb02e811dc15ade79d9796031896 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* | | | | QErrorMessage: avoid some code duplicationMarc Mutz2015-04-071-9/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ...by using the predicate from nextPending() in the two showMessage() functions, too, which thus become identical, when substituting type -> QString(). Also saves around 250B in text size. Change-Id: Ibf5d081dbec3438b7b1be4e240879e26d0455d6b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* | | | | QErrorMessage: add some strategic qMove()sMarc Mutz2015-04-071-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Saves 56 bytes in text size on my machine. Change-Id: Ic92943356e0e27620346854e02c129cdfa00f894 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* | | | | QErrorMessage: replace inefficient QQueue with std::queueMarc Mutz2015-04-071-6/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QQueue is-a QList, so it inherits the trait that types larger than a void* cause a heap-allocation when inserted, which is horribly inefficient. Use a std::queue instead, which, by default, is backed by std::deque. Requires rewriting the API calls, since QQueue uses non-standard function names. Text and data size increase negligibly (23 and 8 bytes, respectively), even though we're instantiating a completely new type (std::deque) instead of QList<QPair<QString, QString>>, which is probably still used, despite the inefficiency. Change-Id: I9bb04a2ec32bb1b9fa2eb83780f0aaa26e872d49 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* | | | | QErrorMessage: put local types into the unnamed namespaceMarc Mutz2015-04-071-0/+2
|/ / / / | | | | | | | | | | | | | | | | | | | | Change-Id: I20f8ea7dc95fdecc4bb1190fb8acda19d99cc234 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* | | | QStyleSheetStyle: do not style the moving tab of a QTabBarOlivier Goffart2015-04-021-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QTabBar uses a palette brush on a child QWidget. But if that widget get styled, it sets the palette on it overwriting the existing palette. Make sure that no stylesheet is applied to it. [ChangeLog][QtWidgets][QTabBar] Fixed moving tab when a stylesheet is applied. Task-number: QTBUG-45173 Task-number: QTBUG-15128 Change-Id: I07aee0f369fa715d852556620c8e74bcffd836da Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* | | | Merge remote-tracking branch 'origin/5.5' into devLiang Qi2015-04-0110-65/+135
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/testlib/qtestblacklist.cpp src/widgets/accessible/qaccessiblewidgets.cpp Change-Id: If032adb9296428f62384ed835dbf41ee7a0b886c
| * | | doc: Correct error in QProxyStyle() doc.Martin Smith2015-03-311-2/+2
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | Constructing the QProxyStle object with a null QStyle pointer causes the QProxyStyle to use the default native style. Change-Id: If624ed7a805aef839ca8a51242d12b2f6d777e83 Task-number: QTBUG-42231 Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
| * | Fix incorrect FBO bindings with QOpenGLWidgetLaszlo Agocs2015-03-301-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QOpenGLContext::defaultFramebufferObject() knows nothing about QOpenGLWidget and QQuickWidget. The problem is that this function (and others that rely on it) is expected to give the widget's backing FBO in paintGL() and friends. To overcome this, we have to provide a way for such widgets that indicate what is the expected "default fbo". Task-number: QTBUG-43269 Change-Id: I43f439f8609382b9f7004707ab0ef9f091952b4f Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
| * | QTabBar: Disable wheel events on MacGabriel de Dietrich2015-03-301-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Many people complain about this unexpected behavior. We may consider introducing a style hint later for those few people that may want it. Change-Id: Ifab663b4b5c3a78a3544ab4408cf34f672df8c05 Task-number: QTBUG-8428 Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
| * | Remove compression of posted input method events.Friedemann Kleint2015-03-301-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | Input method events contain attributes, etc. and cannot be compressed. Change-Id: Ib9a2a80f1efec53f9d843684f8227e1f2e245853 Reviewed-by: Andy Shaw <andy.shaw@digia.com>
| * | Windows: Support virtual folders as initial directory for file dialog.Friedemann Kleint2015-03-271-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use the scheme "clsid" to be able to pass them as "clsid:<GUID>" (with '{', '}' stripped). Task-number: QTBUG-33962 Change-Id: Ib045fe81518bca6e91588007ce8a245a48479b1f Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com> Reviewed-by: Patrick Spendrin <patrick.spendrin@kdab.com> Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com> Reviewed-by: Björn Breitmeyer <bjoern.breitmeyer@kdab.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
| * | Do not emit textEdited on inputMask changeJoni Poikelin2015-03-271-2/+2
| | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-1266 Change-Id: Ib2f1db15be876c1d6713bd7c28c2b91006b3b2d4 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Andy Shaw <andy.shaw@digia.com>
| * | Add a section about QOpenGLWidget alternativesLaszlo Agocs2015-03-251-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | QOpenGLWindow with createWindowContainer() can be an option for desktop-only apps in some special cases. Document this. Task-number: QTBUG-45192 Change-Id: I7c59b7d04d6c0fe58ffe93ac72b204103bef2f4c Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
| * | Don't replay mouse press event which closes a popup on X11Alexander Volkov2015-03-251-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a new style hint to QPlatformIntegration: ReplayMousePressOutsidePopup. Return false for it in the xcb plugin. This commit restores the behavior which was in Qt 4. Task-number: QTBUG-34814 Change-Id: I19fee762395a51475cc67b52b368c70679ca736b Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
| * | iOS: support SH_ComboBox_UseNativePopup in fusion styleRichard Moe Gustavsen2015-03-251-0/+5
| | | | | | | | | | | | | | | Change-Id: I24ef41249042cd658ecba01b0024d08965673b41 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
| * | QComboBox: use native popup on iOSRichard Moe Gustavsen2015-03-252-7/+7
| | | | | | | | | | | | | | | | | | | | | Enable native popup on iOS as well as OS X Change-Id: If99180a017768d9c94241adf2282ee9b3f69cbc1 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
| * | QComboBox: change showNativePopup to be non-blockingRichard Moe Gustavsen2015-03-252-51/+81
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QPlatformMenu::showPopup() is supposed to be non-blocking. So ensure that we don't start cleaning up the menu items directly after the call in showNativePopup, but wait until we need to reload the items, or the combobox is destroyed. Change-Id: Ie4c9b6425cec44861af38e517fc5ef226e0903c7 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
| * | Fix QAccessibleTextWidget::characterRect for off-cursor positionsBoris Dušek2015-03-251-1/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Current code retrieved the character format at position where the cursor currently was, irrespective of the position actually passed to the characterRect function. This is now fixed and we retrieve the character format for the QTextFragment containing the specified offset. This fixes display of visual bounds around text by screen reader in some cases. E.g. on OS X, when searching text using VoiceOver, VoiceOver first queries the visual bounds of the found text (and thus also characterRect), and only then it moves cursor position to the found text. If before the change of position the cursor was on some text with different metrics (i.e. a bigger font), the visual bounds for the found text reflected those metrics, not the metrics of the actual found text for which the bounds were drawn. This resulted in smaller/bigger rectangles around the found text than was actually correct. Change-Id: Ie2a4dfc714504b7923cdaf8ff875c438aeccddee Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
| * | Fix QAccessibleTextWidget::characterRect for complex linesBoris Dušek2015-03-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Current implementation of QAccessibleTextWidget::characterRect returned rect with correct vertical position only when the font point size did not vary inside the line. This commit makes it work for lines where point size changes by taking text ascent and descent into account. Change-Id: I4ee43701a30ce9bff1db2f2d0422227496c3df4c Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>