diff options
| -rw-r--r-- | src/controls/TextArea.qml | 27 | ||||
| -rw-r--r-- | tests/manual/testbench/main.qml | 3 |
2 files changed, 30 insertions, 0 deletions
diff --git a/src/controls/TextArea.qml b/src/controls/TextArea.qml index 85c0e056..47401147 100644 --- a/src/controls/TextArea.qml +++ b/src/controls/TextArea.qml @@ -346,6 +346,33 @@ ScrollView { property alias wrapMode: edit.wrapMode /*! + \qmlproperty bool TextArea::selectByMouse + + This property determines if the user can select the text with the + mouse. + + The default value is \c true. + */ + property alias selectByMouse: edit.selectByMouse + + /*! + \qmlproperty bool TextArea::selectByKeyboard + + This property determines if the user can select the text with the + keyboard. + + If set to \c true, the user can use the keyboard to select the text + even if the editor is read-only. If set to \c false, the user cannot + use the keyboard to select the text even if the editor is editable. + + The default value is \c true when the editor is editable, + and \c false when read-only. + + \sa readOnly + */ + property alias selectByKeyboard: edit.selectByKeyboard + + /*! \qmlsignal TextArea::linkActivated(string link) This signal is emitted when the user clicks on a link embedded in the text. diff --git a/tests/manual/testbench/main.qml b/tests/manual/testbench/main.qml index 0efe00b0..7454a121 100644 --- a/tests/manual/testbench/main.qml +++ b/tests/manual/testbench/main.qml @@ -191,6 +191,9 @@ ApplicationWindow { case "FrameVisible": case "AdjustToContentSize": case "Flat": + case "SelectByMouse": + case "SelectByKeyboard": + case "ReadOnly": layout = layouts.boolLayout typeName = "Boolean"; break |
