Document the QTextBlockFormat::headingLevel property
Followup to 310daae539
Change-Id: Ib0b4330e2201991fa28b297e26edb3a8dd493577
Reviewed-by: Martin Smith <martin.smith@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
This commit is contained in:
parent
9976a1c76d
commit
db7c644cd6
@ -556,6 +556,8 @@ Q_GUI_EXPORT QDataStream &operator>>(QDataStream &stream, QTextFormat &fmt)
|
||||
\value LineHeightType
|
||||
\value BlockNonBreakableLines
|
||||
\value BlockTrailingHorizontalRulerWidth The width of a horizontal ruler element.
|
||||
\value HeadingLevel The level of a heading, for example 1 corresponds to an HTML H1 tag; otherwise 0.
|
||||
This enum value has been added in Qt 5.12.
|
||||
|
||||
Character properties
|
||||
|
||||
@ -2245,6 +2247,34 @@ QList<QTextOption::Tab> QTextBlockFormat::tabPositions() const
|
||||
*/
|
||||
|
||||
|
||||
/*!
|
||||
\fn void QTextBlockFormat::setHeadingLevel(int level)
|
||||
\since 5.12
|
||||
|
||||
Sets the paragraph's heading level, where 1 is the highest-level heading
|
||||
type (usually with the largest possible heading font size), and increasing
|
||||
values are progressively deeper into the document (and usually with smaller
|
||||
font sizes). For example when reading an HTML H1 tag, the heading level is
|
||||
set to 1. Setting the heading level does not automatically change the font
|
||||
size; however QTextDocumentFragment::fromHtml() sets both the heading level
|
||||
and the font size simultaneously.
|
||||
|
||||
If the paragraph is not a heading, the level should be set to 0 (the default).
|
||||
|
||||
\sa headingLevel()
|
||||
*/
|
||||
|
||||
|
||||
/*!
|
||||
\fn int QTextBlockFormat::headingLevel() const
|
||||
\since 5.12
|
||||
|
||||
Returns the paragraph's heading level if it is a heading, or 0 if not.
|
||||
|
||||
\sa setHeadingLevel()
|
||||
*/
|
||||
|
||||
|
||||
/*!
|
||||
\fn void QTextBlockFormat::setLineHeight(qreal height, int heightType)
|
||||
\since 4.8
|
||||
|
Loading…
Reference in New Issue
Block a user