aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/quick/qquicktextedit/tst_qquicktextedit.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-05-161-0/+56
|\ | | | | | | Change-Id: Ia93dc734ce25b3134b0f905f473a0c30777ceaf1
| * TextEdit: use I-beam cursor by default, pointing cursor for linksShawn Rutledge2019-05-151-0/+56
| | | | | | | | | | | | | | | | | | | | But do not interfere with any custom cursor that user code sets: remember and restore it when the mouse is no longer hovering a link. Task-number: QTBUG-14769 Fixes: QTBUG-50482 Change-Id: Ia4633c22d0ad42d07203d4dc3e330b90a5f94a7c Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | TextEdit: Fix persistentSelection for readonly controlsNils Jeisecke2019-02-151-0/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | TextEdit items with readOnly:true do not clear the selection on losing focus which is expected with persistentSelection:false. The reason is that a readonly TextEdit does never show a blinking cursor and thus the selection clearing within setCursorVisible never happens. This change adapts the implementation from TextInput. Fixes: QTBUG-50587 Change-Id: Ie66baaa0ccbc006359473862d8e9dbecd46a59f6 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Fix Keys.onShortcutOverride for TextEditJan Arve Sæther2018-12-131-0/+32
|/ | | | | | | | | | | | | | It was not possible to override a shortcut with Keys.onShortcutOverride for TextEdit. This was because the ShortcutOverride event sent to the TextEdit was not passed on to the default event() implementation (of the base class) in the case that the QQuickTextEdit did not handle the ShortcutOverride event. Fixes: QTBUG-68711 Change-Id: I981738d8f92c77eadb8dd98b4245290d430525d3 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io> Reviewed-by: Liang Qi <liang.qi@qt.io> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* use nullptr consistently (clang-tidy)Shawn Rutledge2018-02-261-107/+107
| | | | | | | | | | | | | From now on we prefer nullptr instead of 0 to clarify cases where we are assigning or testing a pointer rather than a numeric zero. Also, replaced cases where 0 was passed as Qt::KeyboardModifiers with Qt::NoModifier (clang-tidy replaced them with nullptr, which waas wrong, so it was just as well to make the tests more readable rather than to revert those lines). Change-Id: I4735d35e4d9f42db5216862ce091429eadc6e65d Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* tests: Wrap qWaitForWindow{Active,Exposed} in QVERIFYv5.11.0-beta1Kari Oikarinen2018-02-231-32/+32
| | | | | | | | | | | The functions are marked Q_REQUIRED_RESULT, so they give compilation warnings when not handling the bool return value. Failing the test early at an unexpected event is also better behavior anyway. Task-number: QTBUG-66559 Change-Id: I6c4db29379ec01528208c3e4ee54346b4230616c Reviewed-by: Sami Nurmenniemi <sami.nurmenniemi@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Merge remote-tracking branch 'origin/5.10' into devLiang Qi2017-11-061-1/+1
|\ | | | | | | Change-Id: I1ed923d72566af663555898c3ec708191eef8ae9
| * Update the cursor rectangle when select all is triggeredAndy Shaw2017-10-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When select all is triggered then the cursor rectangle should be updated to ensure that the selection handles are visible if they are displayed on a given platform. For instance, on iOS the loupe handles should appear in this case. This also has the added effect that when using Backspace on the iOS keyboard, it will delete the selected text as opposed to just a single character as it will handle that situation correctly. The tst_qquicktextedit::inputMethodUpdate() test is modified to account for the extra event sent now when selectAll() is called. Task-number: QTBUG-63835 Change-Id: I94fb0576b286c006dd12c65d0b322d712ed2a96f Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* | Merge remote-tracking branch 'origin/5.10' into devLiang Qi2017-09-221-0/+13
|\| | | | | | | Change-Id: I3878bbf2ac7b62651215938c98ead7171be49c74
| * QQuickTextEdit: call implicitWidth() even if requireImplicitWidth is trueTim Jenssen2017-09-141-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Before once requireImplicitWidth was set to true by requesting the implicit width, the implicit (and width) was never updated again, even if the text was updated/changed. Adding also a test Task-number: QTBUG-63153 Change-Id: Ie3bac4baeb14c2e69acc43d11a351ac91d5400da Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: J-P Nurmi <jpnurmi@qt.io> Reviewed-by: Alessandro Portale <alessandro.portale@qt.io> Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
* | Enable tests for boot2qtSami Nurmenniemi2017-09-211-0/+4
|/ | | | | | | | | | | | | | Some tests needed fixing - Disabled tests too heavy for qemu - Skipped tests requiring OpenGL without support from the platform - Skipped tests requiring functionality on broken offscreen platform - Skipped tests that take too long on qemu + software renderer - Blacklisted tests for created bugs QTBUG-63049, QTBUG-63053 QTBUG-63055 and QTBUG-63057 Task-number: QTBUG-60268 Change-Id: I0346b0e436cf286d7d9cbc140acf324a4087cfb9 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Merge remote-tracking branch 'origin/5.8' into devLiang Qi2016-12-141-7/+7
|\ | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/qmltooling/qmldbg_debugger/qv4debugjob.cpp src/plugins/qmltooling/qmldbg_inspector/globalinspector.cpp src/plugins/qmltooling/qmldbg_nativedebugger/qqmlnativedebugservice.cpp src/qml/qml/qqmlimport.cpp src/quick/items/context2d/qquickcontext2dtexture_p.h tools/qmleasing/splineeditor.h Change-Id: I8f6630fcac243824350986c8e9f4bd6483bf20b5
| * Get rid of most QT_NO_FOO usagesLars Knoll2016-11-291-7/+7
| | | | | | | | | | | | | | | | Instead use QT_CONFIG(foo). This change actually detected a few mis-spelled macros and invalid usages. Change-Id: I06ac327098dd1a458e6bc379d637b8e2dac52f85 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | tst_qquicktextedit: remove useless call to image.save()Mitch Curtis2016-11-281-1/+0
|/ | | | | Change-Id: I433ba9ef0dc403e7b15eeaee1fd682cf443870cf Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Merge remote-tracking branch 'origin/5.7' into 5.8Simon Hausmann2016-11-151-0/+38
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/jsruntime/qv4string.cpp The conflict resolution for qv4tsring.cpp is to essentially omit the change of commit 64714ea431f2fd355ed27edc69dba4e992511e75 as the code in 5.8 already uses the add/mul_overflow functions. This merge also reverts commit f4ac007f4a19bc095ff15d415a6629986de78e49 as we can deal with dead store elimination now. Change-Id: Iee08c87cbe1a2ff23a73ce621d56262b4e007c56
| * TextEdit: set cursor delegate's height to match the selected fontMitch Curtis2016-11-121-0/+38
| | | | | | | | | | | | | | | | | | | | RichText can have blocks of text with varying font sizes, so we must ensure that the cursor delegate's height is also set when it's moved to a different position in the text. Change-Id: I00691a94a2360c7d3272571fc4ba0da28b01006a Task-number: QTBUG-54934 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* | Merge remote-tracking branch 'origin/5.7' into 5.8v5.8.0-beta1Liang Qi2016-10-271-8/+8
|\| | | | | | | | | | | | | Conflicts: tests/auto/quick/qquicktextedit/BLACKLIST Change-Id: I0b9e5bea5da5d2666887c202e62d889b4aa56900
| * Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-10-271-8/+8
| |\ | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/quick/items/qquickwindow.cpp tests/auto/quick/qquicktext/BLACKLIST tests/auto/quick/qquicktextedit/BLACKLIST Change-Id: I8bd68b0b5e853b7908791d2cbddd18dd527c76ae
| | * Make tst_qquicktextedit::mouseSelection() passJ-P Nurmi2016-10-241-5/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since qtbase commit beef975, QTestLib avoids generating accidental double click events by adding 500ms timestamp delta on release events. The test requires a press-and-drag-and-release type of sequence with double and triple clicks. The triple-click case is handled fine with QTest::mouseDClick() + press + move + release, but the double-click case is using QTest::mouseClick() + press + move + release and relies on the accidental double-click event generation that QTestLib now deliberately prevents. I can't think of a nice way to inject the move event in the middle of a double-click sequence generated by QTest::mouseDClick(), so we just send the missing double-click event by hand. We can also remove the QStyleHints::mouseDoubleClickInterval waits, which were there to prevent the aforementioned accidental double click events that can no longer happen. This reduces the total execution time of mouseSelection() by roughly 90%. Task-number: QTBUG-50022 Change-Id: I252e87d6a49ea86a44cfa347a29eebee12fd36d1 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
| | * tst_qquicktextedit: remove mouseDoubleClickInterval waitJ-P Nurmi2016-10-231-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since qtbase commit beef975, QTestLib avoids generating accidental double click events by adding 500ms timestamp delta on release events. Thus, now we can remove the QStyleHints::mouseDoubleClickInterval wait, which were there to prevent the aforementioned accidental double click events that can no longer happen. The default inverval is 400ms, so this saves us nearly half a second on most platforms. Change-Id: I7a670b70c012ac027dc951ebafdf5e7d53b89ce9 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | Merge remote-tracking branch 'origin/5.7' into devAndy Nichols2016-04-051-0/+12
|\| | | | | | | | | | | Change-Id: I57b06e2e98beb010a56dd0593d93e078ecf76eea
| * | QQuickText{Edit,Input}: Reset selection when becoming readOnly.Robin Burchell2016-03-011-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When read only, controls may not be edited or altered, and indeed, a read-only control cannot acquire a selection (as it cannot be interacted with). Leaving an existing selection breaks that implication, so clear it when becoming read-only. [ChangeLog][QtQuick][TextEdit/TextInput] If a control has a selection, it is now cleared when becoming read-only. Task-number: QTBUG-51115 Change-Id: Ife43b97ee3d6b780f09a938868c3ccb2f1b6e6e7 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* | | Add overwriteMode to QML TextEdit and QML TextInputDan Cape2016-03-031-0/+69
|/ / | | | | | | | | | | | | | | | | | | Overwrite mode was added to QML TextEdit and QML TextInput to match the functionality provided by QTextEdit. Tests were updated as well to ensure the mode functions as expected. Task-number: QTBUG-26513 Change-Id: I1769159b298220107b09f9f13dc3af5f274715cc Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* | QTextEdit/QQuickTextEdit undo issue - Part #1Dan Cape2016-01-281-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change to the qquicktextedit testcase will match updated functionality for undo (made in qtbase) in the following scenario: If a user selected the text "foo" and typed "bar", upon pressing undo, the text would change to "b". This is incorrect and does not match the functionality of QTextEdit or the default behaviours of Windows/OSX/Ubuntu. When pressing undo on QTextEdit, the text would change back to "foo". The changes to the testcase is basically removing one step in the undo test data that does not happen anymore. Since the change to undo was made in qtbase, I need to disable the undo test cases using the BLACKLIST until the qtbase change is in. Then there will be another review to re-enable it. Task-number: QTBUG-38825 Change-Id: I60e799d546945aac89634b49b2e1dc60a2a68935 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* | Updated license headersJani Heikkinen2016-01-201-17/+12
| | | | | | | | | | | | | | | | | | | | | | | | From Qt 5.7 -> tools & applications are lisenced under GPL v3 with some exceptions, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new GPL-EXCEPT header instead of LGPL21 one (in those files which will be under GPL 3 with exceptions) Change-Id: I04760a0801837cfc516d1c7c02d4f503f6bb70b6 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | QQuickTextEdit: added clear() methodLiang Qi2016-01-191-0/+61
| | | | | | | | | | | | Task-number: QTBUG-50428 Change-Id: Id618616f8d8d50c2a2eba79a2bf6969662e727b8 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* | QQuickTextEdit: added preeditText propertyLiang Qi2016-01-131-0/+17
|/ | | | | | Task-number: QTBUG-49503 Change-Id: I3390e72893e4125e00e8e0835a8d2fae11ea276f Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* QQuickTextEdit: Fully qualify enumerations in changed() signals.Friedemann Kleint2015-12-151-2/+5
| | | | | | | | | Fix warnings when running tst_qquicktextedit: QWARN : tst_qquicktextedit::mouseSelectionMode_accessors() QSignalSpy: Unable to handle parameter 'mode' of type 'QQuickTextEdit::SelectionMode' of method 'mouseSelectionModeChanged', use qRegisterMetaType to register it. QWARN : tst_qquicktextedit::textFormat() QSignalSpy: Unable to handle parameter 'textFormat' of type 'QQuickTextEdit::TextFormat' of method 'textFormatChanged', use qRegisterMetaType to register it. Change-Id: I2d41f970777c9ee4d8999acceed9e1b9cf52b0f0 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* Fix autotests for change in QtNetworkDaniel Molkentin2015-11-291-2/+2
| | | | | | | See change 4efa50a5e37497bc3a3dd30f27db7d8100e3f6a5 in qtbase Change-Id: I00e5e529faed029bc3bc461a3b1807811d33c769 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* tst_qquicktextedit: Fix warning about uninitialized variable.Friedemann Kleint2015-11-271-2/+2
| | | | | | | | | tst_qquicktextedit.cpp: In member function 'void tst_qquicktextedit::positionAt()': tst_qquicktextedit.cpp:2428:68: warning: 'y1' may be used uninitialized in this function [-Wmaybe-uninitialized] tst_qquicktextedit.cpp:2425:64: warning: 'y0' may be used uninitialized in this function [-Wmaybe-uninitialized] Change-Id: I28d5a8c1c5421e20097b25ca18915763bac3200c Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
* Move QQuickTextDocumentWithImageResources out of qquicktext_p_p.hJ-P Nurmi2015-10-291-1/+2
| | | | | | | | | | | | | | QQuickTextDocumentWithImageResources was autotest-exported in b63185. The problem is that the QQuickLabel in qtquickcontrols2 inherits QQuickText, and therefore includes the private header. An autotest- exported class with Q_OBJECT macro leads to a linking error: qquickcontrol.obj : error LNK2019: unresolved external symbol "public: static struct TestNamespace::QMetaObject const TestNamespace::QQuickTextDocumentWithImageResources::staticMetaObject" (?staticMetaObject@QQuickTextDocumentWithImageResources@TestNamespace@@2UQMetaObject@2@B) referenced in function "public: static class TestNamespace::QString __cdecl TestNamespace::QQuickTextDocumentWithImageResources::tr(char const *,char const *,int)" (?tr@QQuickTextDocumentWithImageResources@TestNamespace@@SA?AVQString@2@PBD0H@Z) qquicklabel.obj : error LNK2001: unresolved external symbol "public: static struct TestNamespace::QMetaObject const TestNamespace::QQuickTextDocumentWithImageResources::staticMetaObject" (?staticMetaObject@QQuickTextDocumentWithImageResources@TestNamespace@@2UQMetaObject@2@B) ..\..\lib\Qt5LabsTemplatesTestInfix.dll : fatal error LNK1120: 1 unresolved externals Change-Id: I7e8731973c4ad67fca40f87bf009dc55336c3d6f Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Provide a threaded TestHTTPServerUlf Hermann2015-10-141-9/+8
| | | | | | | | | This allows us to do blocking operations that interact with the test server in the main thread. The threaded server is used in tests that don't explicitly require asynchronous operation. Change-Id: Ibcb28e79a1114cb9cfb812e86aae0a1af71c569e Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Tests: Fix single-character string literals.Friedemann Kleint2015-10-131-1/+1
| | | | | | | | Use character literals where applicable. Change-Id: Ib0e618752fbc762a73a0a91c43efab61ef2c9687 Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com> Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* TextEdit: selectedTextChanged not emitted when calling select 2nd timeDan Cape2015-09-211-14/+26
| | | | | | | | | | | | | | | | | | | | | | | qquicktextcontrol was only checking if the text was previous selected or not and if the current state matched the previous state it would not dispatch a selectedTextChanged event. This is wrong if you programmatically select text a second time with a different start or end of selection. You must notify that the selected text changed since visually you can see the highlight changed locations. When correcting this and creating a test case, it was seen that other tests had QEXPECT_FAIL set for this specific case. Upon further inspection, I could remove those calls and adjust the expected data that was set before the test (changing false to true). testing of tst_qquicktext: Totals: 182 passed, 0 failed, 0 skipped, 0 blacklisted testing of tst_qquicktextedit: Totals: 354 passed, 0 failed, 3 skipped, 0 blacklisted Task-number: QTBUG-38704 Change-Id: Ib5244dc264ab76951bb722a31dcb64717282725a Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* tests/quick: Replace Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b).Friedemann Kleint2015-07-271-29/+29
| | | | | | | | | | | | - Replace Q[TRY]_VERIFY(pointer == 0) by Q[TRY]_VERIFY(!pointer). - Replace Q[TRY]_VERIFY(smartPointer == 0) by Q[TRY]_VERIFY(smartPointer.isNull()). - Replace Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b) and add casts where necessary. The values will then be logged should a test fail. Change-Id: Ib9f4c2486af23c47990be4b9e004b965de226dcc Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Tests: Replace Q[TRY]_VERIFY(v == true|false) by QVERIFY(v)|QVERIFY(!v).Friedemann Kleint2015-07-271-17/+17
| | | | | | | | Preparing the replacement of Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b) for non-boolean types. Change-Id: I8a4e44a2b4e20a9c8b811799e3932c8ce1a2cbbb Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.5' into devSimon Hausmann2015-04-281-14/+23
|\ | | | | | | | | | | | | Conflicts: tests/auto/quick/qquicktext/tst_qquicktext.cpp Change-Id: I075e742da8396a268d97d3ab34bcd9e0c0cf001f
| * Merge remote-tracking branch 'origin/5.4' into 5.5Simon Hausmann2015-04-271-14/+23
| |\ | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf tests/auto/qml/qqmlxmlhttprequest/tst_qqmlxmlhttprequest.cpp Change-Id: I715b8a78b74cbe0dcaf599367fd6e08af4858e11
| | * Prospective fix for flakey "network" related QML testsv5.4.2Simon Hausmann2015-04-251-14/+23
| | | | | | | | | | | | | | | | | | | | | Replace hard-coded server ports with dynamically allocated ports. Change-Id: Iab8f9a88343a9f2c49af3cd700c954c13c3bf121 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
* | | TextEdit: add support for paddingJ-P Nurmi2015-03-051-0/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This makes it possible for TextArea to inherit TextEdit, reserve space for the decoration, and set the desired property defaults without having to create dozens of property aliases. [ChangeLog][QtQuick][TextEdit] Added padding, leftPadding, topPadding, rightPadding and bottomPadding properties. Task-number: QTBUG-41559 Change-Id: I4fa22f86e6151524a63b2b862f17bc9d6a713142 Reviewed-by: Alan Alpert <aalpert@blackberry.com>
* | | TextEdit: add editingFinished signalLiang Qi2015-03-031-0/+49
|/ / | | | | | | | | | | | | | | | | | | | | Autotest is included. [ChangeLog][TextEdit] add editingFinished signal Task-number: QTBUG-44734 Change-Id: Ib632e589419758bea09442e6efcf4d977b9a13e8 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* / Update copyright headersJani Heikkinen2015-02-121-7/+7
|/ | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Change-Id: I61120571787870c0ed17066afb31779b1e6e30e9 Reviewed-by: Iikka Eklund <iikka.eklund@theqtcompany.com>
* TextEdit: fix construction time text cacheJ-P Nurmi2015-01-081-0/+12
| | | | | | | | | | | QQuickTextEdit does not apply cached text to the underlying document until component construction is complete. However, if text() was called during the construction (eg. because of a binding), it would blindly overwrite the cached text with (still) empty document content. Task-number: QTBUG-41583 Change-Id: I6c5c1b6283d70d8a5ec2c8bd986095ee3c35a14c Reviewed-by: Pierre Rossi <pierre.rossi@theqtcompany.com>
* text input: always let cursor rect have a width == 1Richard Moe Gustavsen2014-10-301-0/+21
| | | | | | | | | | | | | | | | Instead of using a cursor width of null when a cursor delegate is set, we should to use a value of 1. Otherwise the rect we e.g return from cursorRect() will be invalid. An alternative would be to use the width of the delegate, but that was found to be controversial. On iOS we saw a bug with this when telling iOS to position text spelling popups underneath the cursor. Since the cursor rect we got was invalid (zero-width), no popup would show. Change-Id: Ice51b9a1bd33f331183e3acec61b7d9c0f5163cd Reviewed-by: Andrew den Exter <andrew.den.exter@qinetic.com.au>
* Update license headers and add new licensesJani Heikkinen2014-08-251-19/+11
| | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 & LICENSE.GPLv2 - Removed LICENSE.GPL Change-Id: I84a565e2e0caa3b76bf291a7d188a57a4b00e1b0 Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com>
* Merge remote-tracking branch 'origin/5.3' into 5.4Frederik Gladhorn2014-08-141-3/+2
|\ | | | | | | Change-Id: I2e06c2fcd8aa9d5d090f0568be75272ec82f7b20
| * Silence harmless compiler warning.Gunnar Sletta2014-08-121-3/+2
| | | | | | | | | | | | | | | | AlignJustify is not a tested value, but the compiler warning can throw you off, so best to keep it quiet. Change-Id: I0b3d717dfe2c11fc4367e7eceb5b83009c4e0a30 Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* | Merge remote-tracking branch 'origin/stable' into devSimon Hausmann2014-05-221-0/+28
|\| | | | | | | Change-Id: I0dd91626837276f5811e4830f4a4e9f89bf1e1bd
| * Fix tst_qquicktextedit::cursorRectangle_QTBUG_38947()J-P Nurmi2014-05-191-2/+2
| | | | | | | | | | | | | | | | | | Fix the uninitialize variable and make sure the test creates a window that has a sensible (200x200) size. Change-Id: I02616ab3c832276921e84ae98b7ed926d8fc5f5e Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Liang Qi <liang.qi@digia.com>
| * TextEdit: fix cursor rectangle positioningJ-P Nurmi2014-05-161-0/+28
| | | | | | | | | | | | | | | | | | | | | | QQuickTextControl::cursorRectangleChanged() wasn't emitted as appropriate when dragging mouse => The cursor delegate was stuck in wrong position under certain circumstances, especially when selecting multiple lines. Task-number: QTBUG-38947 Change-Id: Ib5b0d2f6ea2a1b3712fbaba4a7ad1865d2b0a74e Reviewed-by: Pierre Rossi <pierre.rossi@gmail.com>