Introduce TextInput::ensureVisible(int position)
authorJ-P Nurmi <jpnurmi@digia.com>
Fri, 16 May 2014 12:35:23 +0000 (14:35 +0200)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Wed, 21 May 2014 11:11:18 +0000 (13:11 +0200)
commitdc5f86c8ffc2d6d13d00f2bb68373f66c91525c0
tree9f3e869f8b1e10b27b85ba7f3f3c4be957ca4abc
parenta7122f3b2832ad65cfd0ab0ce0315a7042ee9f92
Introduce TextInput::ensureVisible(int position)

This is required for TextField to be able to implement text selection
handles. TextField needs to be able to ensure that the appropriate
character position becomes visible when the handles are moved around.

[ChangeLog][QtQuick][TextInput] Added TextInput::ensureVisible(int pos)
method to be able to control the scrolling position of a TextInput that
has automatic scrolling enabled.

Task-number: QTBUG-38934
Change-Id: Id77eafcda6324d10868e0798519e5b712a0d33ed
Reviewed-by: Alan Alpert <aalpert@blackberry.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
src/quick/items/qquicktextinput.cpp
src/quick/items/qquicktextinput_p.h
src/quick/items/qquicktextinput_p_p.h
tests/auto/quick/qquicktextinput/tst_qquicktextinput.cpp