QTextInlineObject Class▲
-
Header: QTextInlineObject
-
CMake:
find_package(Qt6 REQUIRED COMPONENTS Gui)
target_link_libraries(mytarget PRIVATE Qt6::Gui)
-
qmake: QT += gui
-
Group: QTextInlineObject is part of Rich Text Processing APIs
Detailed Description▲
Normally, you do not need to create a QTextInlineObject. It is used by QAbstractTextDocumentLayout to handle inline objects when implementing a custom layout.
The inline object has various attributes that can be set, for example using, setWidth(), setAscent(), and setDescent(). The rectangle it occupies is given by rect(), and its direction by textDirection(). Its position in the text layout is given by textPosition(), and its format is given by format().
Member Function Documentation▲
qreal QTextInlineObject::ascent() const▲
qreal QTextInlineObject::descent() const▲
QTextFormat QTextInlineObject::format() const▲
Returns format of the inline object within the text layout.
int QTextInlineObject::formatIndex() const▲
Returns an integer describing the format of the inline object within the text layout.
qreal QTextInlineObject::height() const▲
bool QTextInlineObject::isValid() const▲
Returns true if this inline object is valid; otherwise returns false.
QRectF QTextInlineObject::rect() const▲
void QTextInlineObject::setAscent(qreal a)▲
void QTextInlineObject::setDescent(qreal d)▲
void QTextInlineObject::setWidth(qreal w)▲
Qt::LayoutDirection QTextInlineObject::textDirection() const▲
Returns if the object should be laid out right-to-left or left-to-right.
int QTextInlineObject::textPosition() const▲
The position of the inline object within the text layout.