Skip to content

PythonQt.QtGui.QGlyphRun · declarations 001

Back to PythonQt.QtGui.QGlyphRun

GlyphRunFlag instance-attribute

GlyphRunFlag: type

int([x]) -> integer int(x, base=10) -> integer

Convert a number or string to an integer, or return 0 if no arguments are given. If x is a number, return x.int(). For floating point numbers, this truncates towards zero.

If x is not a number or if base is given, then x must be a string, bytes, or bytearray instance representing an integer literal in the given base. The literal can be preceded by '+' or '-' and be surrounded by whitespace. The base defaults to 10. Valid bases are 0 and 2-36. Base 0 means to interpret the base from the string as an integer literal.

int('0b100', base=0) 4

GlyphRunFlags instance-attribute

GlyphRunFlags: type

int([x]) -> integer int(x, base=10) -> integer

Convert a number or string to an integer, or return 0 if no arguments are given. If x is a number, return x.int(). For floating point numbers, this truncates towards zero.

If x is not a number or if base is given, then x must be a string, bytes, or bytearray instance representing an integer literal in the given base. The literal can be preceded by '+' or '-' and be surrounded by whitespace. The base defaults to 10. Valid bases are 0 and 2-36. Base 0 means to interpret the base from the string as an integer literal.

int('0b100', base=0) 4

Overline instance-attribute

Overline: Any

SplitLigature instance-attribute

SplitLigature: Any

StrikeOut instance-attribute

StrikeOut: Any

Underline instance-attribute

Underline: Any

boundingRect

boundingRect() -> Any

X.boundingRect() -> PythonQt.QtCore.QRectF

Supplemental documentation: Qt 5 reference:

QRectF QGlyphRun::boundingRect() const

Returns the smallest rectangle that contains all glyphs in this QGlyphRun. If a bounding rect has been set using setBoundingRect(), then this will be returned. Otherwise the bounding rect will be calculated based on the font metrics of the glyphs in the glyph run.

This function was introduced in Qt 5.0.

See also setBoundingRect().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#boundingRect

clear

clear() -> Any

X.clear()

Supplemental documentation: Qt 5 reference:

void QGlyphRun::clear()

Clears all data in the QGlyphRun object.

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#clear

flags

flags() -> Any

X.flags()

Supplemental documentation: Qt 5 reference:

QGlyphRun::GlyphRunFlags QGlyphRun::flags() const

Returns the flags set for this QGlyphRun.

This function was introduced in Qt 5.0.

See also setFlags(), setFlag(), and setFlag().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#flags

glyphIndexes

glyphIndexes() -> tuple

X.glyphIndexes() -> tuple

Supplemental documentation: Qt 5 reference:

QVector\<quint32> QGlyphRun::glyphIndexes() const

Returns the glyph indexes for this QGlyphRun object.

See also setGlyphIndexes() and setPositions().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#glyphIndexes

isEmpty

isEmpty() -> bool

X.isEmpty() -> bool

Supplemental documentation: Qt 5 reference:

bool QGlyphRun::isEmpty() const

Returns true if the QGlyphRun does not contain any glyphs.

This function was introduced in Qt 5.0.

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#isEmpty

isRightToLeft

isRightToLeft() -> bool

X.isRightToLeft() -> bool

Supplemental documentation: Qt 5 reference:

bool QGlyphRun::isRightToLeft() const

Returns true if this QGlyphRun contains glyphs that are painted from the right to the left.

This function was introduced in Qt 5.0.

See also setRightToLeft() and flags().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#isRightToLeft

operator_assign

operator_assign(other: Any) -> Any

X.operator_assign(other) -> PythonQt.QtGui.QGlyphRun

overline

overline() -> bool

X.overline() -> bool

Supplemental documentation: Qt 5 reference:

bool QGlyphRun::overline() const

Returns true if this QGlyphRun should be painted with an overline decoration.

See also setOverline() and flags().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#overline

positions

positions() -> tuple

X.positions() -> tuple

Supplemental documentation: Qt 5 reference:

QVector\<QPointF> QGlyphRun::positions() const

Returns the position of the edge of the baseline for each glyph in this set of glyph indexes.

See also setPositions().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#positions

rawFont

rawFont() -> Any

X.rawFont() -> PythonQt.QtGui.QRawFont

Supplemental documentation: Qt 5 reference:

QRawFont QGlyphRun::rawFont() const

Returns the font selected for this QGlyphRun object.

See also setRawFont().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#rawFont

setBoundingRect

setBoundingRect(boundingRect: Any) -> Any

X.setBoundingRect(boundingRect)

Supplemental documentation: Qt 5 reference:

void QGlyphRun::setBoundingRect(const QRectF \&boundingRect)

Sets the bounding rect of the glyphs in this QGlyphRun to be boundingRect. This rectangle will be returned by boundingRect() unless it is empty, in which case the bounding rectangle of the glyphs in the glyph run will be returned instead.

Note: Unless you are implementing text shaping, you should not have to use this function. It is used specifically when the QGlyphRun should represent an area which is smaller than the area of the glyphs it contains. This could happen e.g. if the glyph run is retrieved by calling QTextLayout::glyphRuns() and the specified range only includes part of a ligature (where two or more characters are combined to a single glyph.) When this is the case, the bounding rect should only include the appropriate part of the ligature glyph, based on a calculation of the average width of the characters in the ligature.

In order to support such a case (an example is selections which should be drawn with a different color than the main text color), it is necessary to clip the painting mechanism to the rectangle returned from boundingRect() to avoid drawing the entire ligature glyph.

This function was introduced in Qt 5.0.

See also boundingRect().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#setBoundingRect

setFlag

setFlag(arg0: flag, enabled: Any) -> Any

X.setFlag(flag, enabled)

Supplemental documentation: Qt 5 reference:

void QGlyphRun::setFlag(QGlyphRun::GlyphRunFlag flag, bool enabled \= true)

If enabled is true, then flag is enabled; otherwise, it is disabled.

This function was introduced in Qt 5.0.

See also flags() and setFlags().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#setFlag

setFlags

setFlags(arg0: flags) -> Any

X.setFlags(flags)

Supplemental documentation: Qt 5 reference:

void QGlyphRun::setFlags(QGlyphRun::GlyphRunFlags flags)

Sets the flags of this QGlyphRun to flags.

This function was introduced in Qt 5.0.

See also setFlag() and flags().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#setFlags

setGlyphIndexes

setGlyphIndexes(glyphIndexes: Any) -> Any

X.setGlyphIndexes(glyphIndexes)

Supplemental documentation: Qt 5 reference:

void QGlyphRun::setGlyphIndexes(const QVector\<quint32> \&glyphIndexes)

Set the glyph indexes for this QGlyphRun object to glyphIndexes. The glyph indexes must be valid for the selected font.

See also glyphIndexes().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#setGlyphIndexes

setOverline

setOverline(overline: Any) -> Any

X.setOverline(overline)

Supplemental documentation: Qt 5 reference:

void QGlyphRun::setOverline(bool overline)

Indicates that this QGlyphRun should be painted with an overline decoration if overline is true. Otherwise the QGlyphRun should be painted with no overline decoration.

See also overline(), setFlag(), and setFlags().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#setOverline

setPositions

setPositions(positions: Any) -> Any

X.setPositions(positions)

Supplemental documentation: Qt 5 reference:

void QGlyphRun::setPositions(const QVector\<QPointF> \&positions)

Sets the positions of the edge of the baseline for each glyph in this set of glyph indexes to positions.

See also positions().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#setPositions

setRawData

setRawData(glyphIndexArray: Any, glyphPositionArray: Any, size: Any) -> Any

X.setRawData(glyphIndexArray, glyphPositionArray, size)

Supplemental documentation: Qt 5 reference:

void QGlyphRun::setRawData(const quint32 *glyphIndexArray, const QPointF *glyphPositionArray, int size)

Sets the glyph indexes and positions of this QGlyphRun to use the first size elements in the arrays glyphIndexArray and glyphPositionArray. The data is not copied. The caller must guarantee that the arrays are not deleted as long as this QGlyphRun and any copies of it exists.

See also setGlyphIndexes() and setPositions().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#setRawData

setRawFont

setRawFont(rawFont: Any) -> Any

X.setRawFont(rawFont)

Supplemental documentation: Qt 5 reference:

void QGlyphRun::setRawFont(const QRawFont \&rawFont)

Sets the font in which to look up the glyph indexes to the rawFont specified.

See also rawFont() and setGlyphIndexes().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#setRawFont

setRightToLeft

setRightToLeft(on: Any) -> Any

X.setRightToLeft(on)

Supplemental documentation: Qt 5 reference:

void QGlyphRun::setRightToLeft(bool rightToLeft)

Indicates that this QGlyphRun contains glyphs that should be ordered from the right to left if rightToLeft is true. Otherwise the order of the glyphs is assumed to be left to right.

This function was introduced in Qt 5.0.

See also isRightToLeft(), setFlag(), and setFlags().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#setRightToLeft

setStrikeOut

setStrikeOut(strikeOut: Any) -> Any

X.setStrikeOut(strikeOut)

Supplemental documentation: Qt 5 reference:

void QGlyphRun::setStrikeOut(bool strikeOut)

Indicates that this QGlyphRun should be painted with an strike out decoration if strikeOut is true. Otherwise the QGlyphRun should be painted with no strike out decoration.

See also strikeOut(), setFlag(), and setFlags().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#setStrikeOut

setUnderline

setUnderline(underline: Any) -> Any

X.setUnderline(underline)

Supplemental documentation: Qt 5 reference:

void QGlyphRun::setUnderline(bool underline)

Indicates that this QGlyphRun should be painted with an underline decoration if underline is true. Otherwise the QGlyphRun should be painted with no underline decoration.

See also underline(), setFlag(), and setFlags().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#setUnderline

strikeOut

strikeOut() -> bool

X.strikeOut() -> bool

Supplemental documentation: Qt 5 reference:

bool QGlyphRun::strikeOut() const

Returns true if this QGlyphRun should be painted with a strike out decoration.

See also setStrikeOut() and flags().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#strikeOut

swap

swap(other: Any) -> Any

X.swap(other)

Supplemental documentation: Qt 5 reference:

void QGlyphRun::swap(QGlyphRun \&other)

Swaps this glyph run instance with other. This function is very fast and never fails.

This function was introduced in Qt 5.0.

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#swap

underline

underline() -> bool

X.underline() -> bool

Supplemental documentation: Qt 5 reference:

bool QGlyphRun::underline() const

Returns true if this QGlyphRun should be painted with an underline decoration.

See also setUnderline() and flags().

Source: https://doc.qt.io/archives/qt-5.15/qglyphrun.html#underline