Represents a document consisting of one or more QgsTextBlock objects.
More...
#include <qgstextdocument.h>
Represents a document consisting of one or more QgsTextBlock objects.
- Warning
- This API is not considered stable and may change in future QGIS versions.
- Since
- QGIS 3.14
Definition at line 40 of file qgstextdocument.h.
◆ QgsTextDocument() [1/3]
QgsTextDocument::QgsTextDocument |
( |
| ) |
|
|
default |
◆ ~QgsTextDocument()
QgsTextDocument::~QgsTextDocument |
( |
| ) |
|
|
default |
◆ QgsTextDocument() [2/3]
QgsTextDocument::QgsTextDocument |
( |
const QgsTextBlock & |
block | ) |
|
|
explicit |
◆ QgsTextDocument() [3/3]
◆ append() [1/2]
◆ append() [2/2]
◆ applyCapitalization()
Applies a capitalization style to the document's text.
- Since
- QGIS 3.16
Definition at line 192 of file qgstextdocument.cpp.
◆ at()
◆ fromHtml()
◆ fromPlainText()
QgsTextDocument QgsTextDocument::fromPlainText |
( |
const QStringList & |
lines | ) |
|
|
static |
◆ operator[]()
◆ reserve()
void QgsTextDocument::reserve |
( |
int |
count | ) |
|
Reserves the specified count of blocks for optimised block appending.
Definition at line 97 of file qgstextdocument.cpp.
◆ size()
int QgsTextDocument::size |
( |
| ) |
const |
◆ splitLines()
void QgsTextDocument::splitLines |
( |
const QString & |
wrapCharacter, |
|
|
int |
autoWrapLength = 0 , |
|
|
bool |
useMaxLineLengthWhenAutoWrapping = true |
|
) |
| |
Splits lines of text in the document to separate lines, using a specified wrap character (wrapCharacter) or newline characters.
The autoWrapLength argument can be used to specify an ideal length of line to automatically wrap text to (automatic wrapping is disabled if autoWrapLength is 0). This automatic wrapping is performed after processing wrapping using wrapCharacter. When auto wrapping is enabled, the useMaxLineLengthWhenAutoWrapping argument controls whether the lines should be wrapped to an ideal maximum of autoWrapLength characters, or if false
then the lines are wrapped to an ideal minimum length of autoWrapLength characters.
Definition at line 133 of file qgstextdocument.cpp.
◆ toPlainText()
QStringList QgsTextDocument::toPlainText |
( |
| ) |
const |
Returns a list of plain text lines of text representing the document.
Definition at line 117 of file qgstextdocument.cpp.
The documentation for this class was generated from the following files: