4#ifndef QQUICKTEXTEDIT_P_H
5#define QQUICKTEXTEDIT_P_H
21#include <QtGui/qtextoption.h>
36 Q_PROPERTY(
QColor selectionColor READ selectionColor WRITE setSelectionColor NOTIFY selectionColorChanged FINAL)
37 Q_PROPERTY(
QColor selectedTextColor READ selectedTextColor WRITE setSelectedTextColor NOTIFY selectedTextColorChanged FINAL)
39 Q_PROPERTY(
HAlignment horizontalAlignment READ hAlign WRITE setHAlign RESET resetHAlign NOTIFY horizontalAlignmentChanged FINAL)
40 Q_PROPERTY(
HAlignment effectiveHorizontalAlignment READ effectiveHAlign NOTIFY effectiveHorizontalAlignmentChanged FINAL)
41 Q_PROPERTY(
VAlignment verticalAlignment READ vAlign WRITE setVAlign NOTIFY verticalAlignmentChanged FINAL)
42 Q_PROPERTY(
WrapMode wrapMode READ wrapMode WRITE setWrapMode NOTIFY wrapModeChanged FINAL)
43 Q_PROPERTY(
int lineCount READ lineCount NOTIFY lineCountChanged FINAL)
45 Q_PROPERTY(
qreal contentWidth READ contentWidth NOTIFY contentSizeChanged FINAL)
46 Q_PROPERTY(
qreal contentHeight READ contentHeight NOTIFY contentSizeChanged FINAL)
47 Q_PROPERTY(
qreal paintedWidth READ contentWidth NOTIFY contentSizeChanged FINAL)
48 Q_PROPERTY(
qreal paintedHeight READ contentHeight NOTIFY contentSizeChanged FINAL)
49 Q_PROPERTY(
TextFormat textFormat READ textFormat WRITE setTextFormat NOTIFY textFormatChanged FINAL)
50 Q_PROPERTY(
bool readOnly READ isReadOnly WRITE setReadOnly NOTIFY readOnlyChanged FINAL)
51 Q_PROPERTY(
bool cursorVisible READ isCursorVisible WRITE setCursorVisible NOTIFY cursorVisibleChanged FINAL)
52 Q_PROPERTY(
int cursorPosition READ cursorPosition WRITE setCursorPosition NOTIFY cursorPositionChanged FINAL)
53 Q_PROPERTY(
QRectF cursorRectangle READ cursorRectangle NOTIFY cursorRectangleChanged FINAL)
54 Q_PROPERTY(
QQmlComponent* cursorDelegate READ cursorDelegate WRITE setCursorDelegate NOTIFY cursorDelegateChanged FINAL)
55 Q_PROPERTY(
bool overwriteMode READ overwriteMode WRITE setOverwriteMode NOTIFY overwriteModeChanged FINAL)
56 Q_PROPERTY(
int selectionStart READ selectionStart NOTIFY selectionStartChanged FINAL)
57 Q_PROPERTY(
int selectionEnd READ selectionEnd NOTIFY selectionEndChanged FINAL)
58 Q_PROPERTY(
QString selectedText READ selectedText NOTIFY selectedTextChanged FINAL)
59 Q_PROPERTY(
bool activeFocusOnPress READ focusOnPress WRITE setFocusOnPress NOTIFY activeFocusOnPressChanged FINAL)
60 Q_PROPERTY(
bool persistentSelection READ persistentSelection WRITE setPersistentSelection NOTIFY persistentSelectionChanged FINAL)
61 Q_PROPERTY(
qreal textMargin READ textMargin WRITE setTextMargin NOTIFY textMarginChanged FINAL)
62 Q_PROPERTY(Qt::InputMethodHints inputMethodHints READ inputMethodHints WRITE setInputMethodHints NOTIFY inputMethodHintsChanged FINAL)
63 Q_PROPERTY(
bool selectByKeyboard READ selectByKeyboard WRITE setSelectByKeyboard NOTIFY selectByKeyboardChanged REVISION(2, 1) FINAL)
64 Q_PROPERTY(
bool selectByMouse READ selectByMouse WRITE setSelectByMouse NOTIFY selectByMouseChanged FINAL)
65 Q_PROPERTY(
SelectionMode mouseSelectionMode READ mouseSelectionMode WRITE setMouseSelectionMode NOTIFY mouseSelectionModeChanged FINAL)
66 Q_PROPERTY(
bool canPaste READ canPaste NOTIFY canPasteChanged FINAL)
67 Q_PROPERTY(
bool canUndo READ canUndo NOTIFY canUndoChanged FINAL)
68 Q_PROPERTY(
bool canRedo READ canRedo NOTIFY canRedoChanged FINAL)
69 Q_PROPERTY(
bool inputMethodComposing READ isInputMethodComposing NOTIFY inputMethodComposingChanged FINAL)
71 Q_PROPERTY(
RenderType renderType READ renderType WRITE setRenderType NOTIFY renderTypeChanged FINAL)
74 Q_PROPERTY(
qreal padding READ padding WRITE setPadding RESET resetPadding NOTIFY paddingChanged REVISION(2, 6) FINAL)
75 Q_PROPERTY(
qreal topPadding READ topPadding WRITE setTopPadding RESET resetTopPadding NOTIFY topPaddingChanged REVISION(2, 6) FINAL)
76 Q_PROPERTY(
qreal leftPadding READ leftPadding WRITE setLeftPadding RESET resetLeftPadding NOTIFY leftPaddingChanged REVISION(2, 6) FINAL)
77 Q_PROPERTY(
qreal rightPadding READ rightPadding WRITE setRightPadding RESET resetRightPadding NOTIFY rightPaddingChanged REVISION(2, 6) FINAL)
78 Q_PROPERTY(
qreal bottomPadding READ bottomPadding WRITE setBottomPadding RESET resetBottomPadding NOTIFY bottomPaddingChanged REVISION(2, 6) FINAL)
79 Q_PROPERTY(
QString preeditText READ preeditText NOTIFY preeditTextChanged REVISION(2, 7) FINAL)
80 Q_PROPERTY(
qreal tabStopDistance READ tabStopDistance WRITE setTabStopDistance NOTIFY tabStopDistanceChanged REVISION(2, 10) FINAL)
82#if QT_VERSION < QT_VERSION_CHECK(7, 0, 0)
145 QColor selectionColor() const;
146 void setSelectionColor(const
QColor &
c);
148 QColor selectedTextColor() const;
149 void setSelectedTextColor(const
QColor &
c);
162 int lineCount() const;
166 bool isCursorVisible() const;
167 void setCursorVisible(
bool on);
169 int cursorPosition() const;
170 void setCursorPosition(
int pos);
175 bool overwriteMode() const;
176 void setOverwriteMode(
bool overwrite);
178 int selectionStart() const;
179 int selectionEnd() const;
183 bool focusOnPress() const;
184 void setFocusOnPress(
bool on);
186 bool persistentSelection() const;
187 void setPersistentSelection(
bool on);
189 qreal textMargin() const;
190 void setTextMargin(
qreal margin);
192 Qt::InputMethodHints inputMethodHints() const;
193 void setInputMethodHints(
Qt::InputMethodHints hints);
195 bool selectByKeyboard() const;
196 void setSelectByKeyboard(
bool);
198 bool selectByMouse() const;
199 void setSelectByMouse(
bool);
204 bool canPaste() const;
206 bool canUndo() const;
207 bool canRedo() const;
209 void componentComplete() override;
212 void setReadOnly(
bool);
213 bool isReadOnly() const;
215 QRectF cursorRectangle() const;
222 qreal contentWidth()
const;
223 qreal contentHeight()
const;
226 void setBaseUrl(
const QUrl &
url);
237 bool isInputMethodComposing()
const;
251 qreal padding() const;
252 void setPadding(
qreal padding);
255 qreal topPadding() const;
256 void setTopPadding(
qreal padding);
257 void resetTopPadding();
259 qreal leftPadding() const;
260 void setLeftPadding(
qreal padding);
261 void resetLeftPadding();
263 qreal rightPadding() const;
264 void setRightPadding(
qreal padding);
265 void resetRightPadding();
267 qreal bottomPadding() const;
268 void setBottomPadding(
qreal padding);
269 void resetBottomPadding();
271 int tabStopDistance() const;
274 void invalidate() override;
279 void contentSizeChanged();
280 void cursorPositionChanged();
281 void cursorRectangleChanged();
282 void selectionStartChanged();
283 void selectionEndChanged();
284 void selectedTextChanged();
291 void wrapModeChanged();
292 void lineCountChanged();
294 void readOnlyChanged(
bool isReadOnly);
295 void cursorVisibleChanged(
bool isCursorVisible);
296 void cursorDelegateChanged();
297 void overwriteModeChanged(
bool overwriteMode);
298 void activeFocusOnPressChanged(
bool activeFocusOnPressed);
299 void persistentSelectionChanged(
bool isPersistentSelection);
300 void textMarginChanged(
qreal textMargin);
301 Q_REVISION(2, 1)
void selectByKeyboardChanged(
bool selectByKeyboard);
302 void selectByMouseChanged(
bool selectByMouse);
306 void canPasteChanged();
307 void canUndoChanged();
308 void canRedoChanged();
309 void inputMethodComposingChanged();
310 void effectiveHorizontalAlignmentChanged();
311 void baseUrlChanged();
312 void inputMethodHintsChanged();
313 void renderTypeChanged();
327 bool isRightToLeft(
int start,
int end);
328#if QT_CONFIG(clipboard)
342 void q_textChanged();
343 void q_contentsChange(
int,
int,
int);
344 void updateSelection();
345 void moveCursorDelegate();
347 void q_canPasteChanged();
348 void updateWholeDocument();
349 void invalidateBlock(const
QTextBlock &block);
351 void q_linkHovered(const
QString &link);
352 void q_markerHovered(
bool hovered);
353 void q_updateAlignment();
355 void triggerPreprocess();
358 void markDirtyNodesForRange(
int start,
int end,
int charDelta);
359 void updateTotalLines();
360 void invalidateFontCaches();
364#if QT_VERSION < QT_VERSION_CHECK(7, 0, 0)
365 void setOldSelectionDefault();
399#if QT_VERSION < QT_VERSION_CHECK(7, 0, 0)
The QColor class provides colors based on RGB, HSV or CMYK values.
The QFocusEvent class contains event parameters for widget focus events.
The QKeyEvent class describes a key event.
The QQmlComponent class encapsulates a QML component definition.
The QQuickItem class provides the most basic of all visual items in \l {Qt Quick}.
virtual void focusOutEvent(QFocusEvent *)
This event handler can be reimplemented in a subclass to receive focus-out events for an item.
virtual void mouseReleaseEvent(QMouseEvent *event)
This event handler can be reimplemented in a subclass to receive mouse release events for an item.
virtual QSGNode * updatePaintNode(QSGNode *, UpdatePaintNodeData *)
Called on the render thread when it is time to sync the state of the item with the scene graph.
virtual void hoverEnterEvent(QHoverEvent *event)
This event handler can be reimplemented in a subclass to receive hover-enter events for an item.
virtual void mouseDoubleClickEvent(QMouseEvent *event)
This event handler can be reimplemented in a subclass to receive mouse double-click events for an ite...
virtual void geometryChange(const QRectF &newGeometry, const QRectF &oldGeometry)
virtual void keyPressEvent(QKeyEvent *event)
This event handler can be reimplemented in a subclass to receive key press events for an item.
virtual void hoverMoveEvent(QHoverEvent *event)
This event handler can be reimplemented in a subclass to receive hover-move events for an item.
virtual QRectF boundingRect() const
Returns the extents of the item in its own coordinate system: a rectangle from {0,...
virtual void mousePressEvent(QMouseEvent *event)
This event handler can be reimplemented in a subclass to receive mouse press events for an item.
Q_REVISION(2, 1) void activeFocusOnTabChanged(bool)
virtual void updatePolish()
This function should perform any layout as required for this item.
virtual void keyReleaseEvent(QKeyEvent *event)
This event handler can be reimplemented in a subclass to receive key release events for an item.
virtual QRectF clipRect() const
Returns the rectangular area within this item that is currently visible in \l viewportItem(),...
virtual void focusInEvent(QFocusEvent *)
This event handler can be reimplemented in a subclass to receive focus-in events for an item.
virtual void hoverLeaveEvent(QHoverEvent *event)
This event handler can be reimplemented in a subclass to receive hover-leave events for an item.
virtual void mouseMoveEvent(QMouseEvent *event)
This event handler can be reimplemented in a subclass to receive mouse move events for an item.
The QQuickTextDocument class provides access to the QTextDocument of QQuickTextEdit....
Q_REVISION(2, 2) void append(const QString &text)
Q_REVISION(2, 7) QString preeditText() const
QQuickTextDocument * textDocument()
\inmodule QtCore\reentrant
\group qtquick-scenegraph-nodes \title Qt Quick Scene Graph Node classes
\macro QT_RESTRICTED_CAST_FROM_ASCII
@ WrapAtWordBoundaryOrAnywhere
void textChanged(const QString &newText)
list append(new Employee("Blackpool", "Stephen"))
cache insert(employee->id(), employee)
Combined button and popup list for selecting options.
static jboolean cut(JNIEnv *, jobject)
static jboolean copy(JNIEnv *, jobject)
static jboolean paste(JNIEnv *, jobject)
static jboolean selectAll(JNIEnv *, jobject)
DBusConnection const char DBusError DBusBusType DBusError return DBusConnection DBusHandleMessageFunction void DBusFreeFunction return DBusConnection return DBusConnection return const char DBusError return DBusConnection DBusMessage dbus_uint32_t return DBusConnection dbus_bool_t DBusConnection DBusAddWatchFunction DBusRemoveWatchFunction DBusWatchToggledFunction void DBusFreeFunction return DBusConnection DBusDispatchStatusFunction void DBusFreeFunction DBusTimeout return DBusTimeout return DBusWatch return DBusWatch unsigned int return DBusError const DBusError return const DBusMessage return DBusMessage return DBusMessage return DBusMessage return DBusMessage return DBusMessage return DBusMessageIter int const void return DBusMessageIter DBusMessageIter return DBusMessageIter void DBusMessageIter void int return DBusMessage DBusMessageIter return DBusMessageIter return DBusMessageIter DBusMessageIter const char const char const char const char return DBusMessage return DBusMessage const char return DBusMessage dbus_bool_t return DBusMessage dbus_uint32_t return DBusMessage void
#define Q_DECLARE_MIXED_ENUM_OPERATORS_SYMMETRIC(Ret, Flags, Enum)
GLint GLint GLint GLint GLint x
[0]
GLfloat GLfloat GLfloat w
[0]
GLenum GLuint GLenum GLsizei length
GLsizei GLsizei GLfloat distance
GLint GLsizei GLsizei GLenum format
#define QML_DECLARE_TYPE(TYPE)
#define QML_NAMED_ELEMENT(NAME)
#define QML_REMOVED_IN_VERSION(MAJOR, MINOR)
#define QML_ADDED_IN_VERSION(MAJOR, MINOR)
static qreal position(const QQuickItem *item, QQuickAnchors::Anchor anchorLine)
static qreal positionAt(const QQuickRangeSlider *slider, QQuickItem *handle, const QPointF &point)
static void getText(QString &text, QTextDocumentPrivate *priv, const QString &docText, int pos, int end)
settings remove("monkey")
QUrl url("example.com")
[constructor-url-reference]
myFilter setColor(QColor(128, 0, 0))
selection select(topLeft, bottomRight)
insertRed setText("insert red text")
IUIAutomationTreeWalker __RPC__deref_out_opt IUIAutomationElement ** parent