A component for displaying/editing multiple lines of text.
More...
Public Member Functions |
|
void | clear () |
| | Clears all text.
|
|
void | copy () |
| | Copies the selected text to the clipboard.
|
|
void | cut () |
| | Cuts the selected text to the clipboard.
|
|
void | forceActiveFocus () |
| | Forces the text area to become the current focus item.
|
|
void | paste () |
| | Pastes text from the clipboard into the text area.
|
| point | positionAt (int x, int y) |
| | Returns the cursor position at co-ordinates x, y.
|
| rect | positionToRectangle (point pos) |
| | Returns the position at point pos as a rectangle.
|
| void | select (int start, int end) |
| | Selects the text between start and end.
|
|
void | selectAll () |
| | Selects all text.
|
|
void | selectWord () |
| | Selects the current word.
|
Detailed Description
A component for displaying/editing multiple lines of text.
import QtQuick 1.0
import org.hildon.components 1.0
Window {
id: window
title: qsTr("TextArea Example")
visible: true
Column {
id: column
anchors.centerIn: parent
width: 300
width: parent.width
text: qsTr(
"Hildon TextArea")
}
width: parent.width
text: qsTr(
"Osso TextArea")
}
}
}
- See Also
- Label, OssoTextAreaStyle, TextAreaStyle, TextField
- Examples:
- directory.qml, file.qml, process.qml, and textarea.qml.
Member Function Documentation
| point TextArea::positionAt |
( |
int |
x, |
|
|
int |
y |
|
) |
| |
Returns the cursor position at co-ordinates x, y.
- Parameters
-
- Returns
| rect TextArea::positionToRectangle |
( |
point |
pos | ) |
|
Returns the position at point pos as a rectangle.
- Parameters
-
- Returns
| void TextArea::select |
( |
int |
start, |
|
|
int |
end |
|
) |
| |
Selects the text between start and end.
- Parameters
-
Property Documentation
Whether the text area is read only.
The default value is false.