QTextCursor Class Reference
#include <qtextcursor.h>
Definition at line 70 of file qtextcursor.h.
|
enum | MoveMode { MoveAnchor,
KeepAnchor
} |
|
enum | MoveOperation {
NoMove,
Start,
Up,
StartOfLine,
StartOfBlock,
StartOfWord,
PreviousBlock,
PreviousCharacter,
PreviousWord,
Left,
WordLeft,
End,
Down,
EndOfLine,
EndOfWord,
EndOfBlock,
NextBlock,
NextCharacter,
NextWord,
Right,
WordRight,
NextCell,
PreviousCell,
NextRow,
PreviousRow
} |
|
enum | SelectionType { WordUnderCursor,
LineUnderCursor,
BlockUnderCursor,
Document
} |
|
|
| QTextCursor () |
|
| QTextCursor (QTextDocument *document) |
|
| QTextCursor (QTextDocumentPrivate *p, int pos) |
|
| QTextCursor (QTextFrame *frame) |
|
| QTextCursor (const QTextBlock &block) |
|
| QTextCursor (QTextCursorPrivate *d) |
|
| QTextCursor (const QTextCursor &cursor) |
|
QTextCursor & | operator= (const QTextCursor &other) |
|
| ~QTextCursor () |
|
bool | isNull () const |
|
void | setPosition (int pos, MoveMode mode=MoveAnchor) |
|
int | position () const |
|
int | positionInBlock () const |
|
int | anchor () const |
|
void | insertText (const QString &text) |
|
void | insertText (const QString &text, const QTextCharFormat &format) |
|
bool | movePosition (MoveOperation op, MoveMode=MoveAnchor, int n=1) |
|
bool | visualNavigation () const |
|
void | setVisualNavigation (bool b) |
|
void | setVerticalMovementX (int x) |
|
int | verticalMovementX () const |
|
void | setKeepPositionOnInsert (bool b) |
|
bool | keepPositionOnInsert () const |
|
void | deleteChar () |
|
void | deletePreviousChar () |
|
void | select (SelectionType selection) |
|
bool | hasSelection () const |
|
bool | hasComplexSelection () const |
|
void | removeSelectedText () |
|
void | clearSelection () |
|
int | selectionStart () const |
|
int | selectionEnd () const |
|
QString | selectedText () const |
|
QTextDocumentFragment | selection () const |
|
void | selectedTableCells (int *firstRow, int *numRows, int *firstColumn, int *numColumns) const |
|
QTextBlock | block () const |
|
QTextCharFormat | charFormat () const |
|
void | setCharFormat (const QTextCharFormat &format) |
|
void | mergeCharFormat (const QTextCharFormat &modifier) |
|
QTextBlockFormat | blockFormat () const |
|
void | setBlockFormat (const QTextBlockFormat &format) |
|
void | mergeBlockFormat (const QTextBlockFormat &modifier) |
|
QTextCharFormat | blockCharFormat () const |
|
void | setBlockCharFormat (const QTextCharFormat &format) |
|
void | mergeBlockCharFormat (const QTextCharFormat &modifier) |
|
bool | atBlockStart () const |
|
bool | atBlockEnd () const |
|
bool | atStart () const |
|
bool | atEnd () const |
|
void | insertBlock () |
|
void | insertBlock (const QTextBlockFormat &format) |
|
void | insertBlock (const QTextBlockFormat &format, const QTextCharFormat &charFormat) |
|
QTextList * | insertList (const QTextListFormat &format) |
|
QTextList * | insertList (QTextListFormat::Style style) |
|
QTextList * | createList (const QTextListFormat &format) |
|
QTextList * | createList (QTextListFormat::Style style) |
|
QTextList * | currentList () const |
|
QTextTable * | insertTable (int rows, int cols, const QTextTableFormat &format) |
|
QTextTable * | insertTable (int rows, int cols) |
|
QTextTable * | currentTable () const |
|
QTextFrame * | insertFrame (const QTextFrameFormat &format) |
|
QTextFrame * | currentFrame () const |
|
void | insertFragment (const QTextDocumentFragment &fragment) |
|
void | insertHtml (const QString &html) |
|
void | insertImage (const QTextImageFormat &format, QTextFrameFormat::Position alignment) |
|
void | insertImage (const QTextImageFormat &format) |
|
void | insertImage (const QString &name) |
|
void | insertImage (const QImage &image, const QString &name=QString()) |
|
void | beginEditBlock () |
|
void | joinPreviousEditBlock () |
|
void | endEditBlock () |
|
bool | operator!= (const QTextCursor &rhs) const |
|
bool | operator< (const QTextCursor &rhs) const |
|
bool | operator<= (const QTextCursor &rhs) const |
|
bool | operator== (const QTextCursor &rhs) const |
|
bool | operator>= (const QTextCursor &rhs) const |
|
bool | operator> (const QTextCursor &rhs) const |
|
bool | isCopyOf (const QTextCursor &other) const |
|
int | blockNumber () const |
|
int | columnNumber () const |
|
QTextDocument * | document () const |
|
Enumerator |
---|
MoveAnchor |
|
KeepAnchor |
|
Definition at line 85 of file qtextcursor.h.
Enumerator |
---|
NoMove |
|
Start |
|
Up |
|
StartOfLine |
|
StartOfBlock |
|
StartOfWord |
|
PreviousBlock |
|
PreviousCharacter |
|
PreviousWord |
|
Left |
|
WordLeft |
|
End |
|
Down |
|
EndOfLine |
|
EndOfWord |
|
EndOfBlock |
|
NextBlock |
|
NextCharacter |
|
NextWord |
|
Right |
|
WordRight |
|
NextCell |
|
PreviousCell |
|
NextRow |
|
PreviousRow |
|
Definition at line 99 of file qtextcursor.h.
Enumerator |
---|
WordUnderCursor |
|
LineUnderCursor |
|
BlockUnderCursor |
|
Document |
|
Definition at line 144 of file qtextcursor.h.
int positionInBlock |
( |
| ) |
const |
bool visualNavigation |
( |
| ) |
const |
void setVisualNavigation |
( |
bool |
b | ) |
|
int verticalMovementX |
( |
| ) |
const |
void setKeepPositionOnInsert |
( |
bool |
b | ) |
|
bool keepPositionOnInsert |
( |
| ) |
const |
void deletePreviousChar |
( |
| ) |
|
bool hasSelection |
( |
| ) |
const |
bool hasComplexSelection |
( |
| ) |
const |
void removeSelectedText |
( |
| ) |
|
int selectionStart |
( |
| ) |
const |
int selectionEnd |
( |
| ) |
const |
void selectedTableCells |
( |
int * |
firstRow, |
|
|
int * |
numRows, |
|
|
int * |
firstColumn, |
|
|
int * |
numColumns |
|
) |
| const |
bool atBlockStart |
( |
| ) |
const |
bool atBlockEnd |
( |
| ) |
const |
void joinPreviousEditBlock |
( |
| ) |
|
int blockNumber |
( |
| ) |
const |
int columnNumber |
( |
| ) |
const |
friend class QTextDocumentFragmentPrivate |
|
friend |
friend class QTextCopyHelper |
|
friend |
friend class QTextControlPrivate |
|
friend |
The documentation for this class was generated from the following file: