aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/items/qquicktextedit.cpp
diff options
context:
space:
mode:
authorJaishree Vyas <Jaishree.Vyas@qt.io>2022-03-28 15:24:55 +0200
committerJaishree Vyas <Jaishree.Vyas@qt.io>2022-03-29 13:21:40 +0200
commit79807f37b5e9e9744fdaf7af380fd7bfb7ed85f4 (patch)
treeb0a71cd24081566f83b165e4c349864f46551e62 /src/quick/items/qquicktextedit.cpp
parent864dade139242f8ef8bb208d899fa8264cfb91f3 (diff)
Doc: Improve cursorPosition description in TextInput and TextEdit docs
Fixes: QTBUG-97169 Pick-to: 5.15 6.2 6.3 6.3.0 Change-Id: I060be767dd980c489d8e5426d67f2e8b6d21e96c Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Ivan Tkachenko <me@ratijas.tk> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
Diffstat (limited to 'src/quick/items/qquicktextedit.cpp')
-rw-r--r--src/quick/items/qquicktextedit.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/quick/items/qquicktextedit.cpp b/src/quick/items/qquicktextedit.cpp
index 0f956e627a..f739474908 100644
--- a/src/quick/items/qquicktextedit.cpp
+++ b/src/quick/items/qquicktextedit.cpp
@@ -1237,7 +1237,15 @@ void QQuickTextEdit::setCursorVisible(bool on)
/*!
\qmlproperty int QtQuick::TextEdit::cursorPosition
- The position of the cursor in the TextEdit.
+ The position of the cursor in the TextEdit. The cursor is positioned between
+ characters.
+
+ \note The \e characters in this case refer to the string of \l QChar objects,
+ therefore 16-bit Unicode characters, and the position is considered an index
+ into this string. This does not necessarily correspond to individual graphemes
+ in the writing system, as a single grapheme may be represented by multiple
+ Unicode characters, such as in the case of surrogate pairs, linguistic
+ ligatures or diacritics.
*/
int QQuickTextEdit::cursorPosition() const
{