AttrType#

class AttrType#

The PangoAttrType distinguishes between different types of attributes.

Along with the predefined values, it is possible to allocate additional values for custom attributes using register. The predefined values are given below. The type of structure used to store the attribute is listed in parentheses after the description.

Methods#

class AttrType
get_name() str | None#

Fetches the attribute type name.

The attribute type name is the string passed in when registering the type using register.

The returned value is an interned string (see intern_string() for what that means) that should not be modified or freed.

Added in version 1.22.

register() AttrType#

Allocate a new attribute type ID.

The attribute type name can be accessed later by using get_name.

Fields#

class AttrType
ABSOLUTE_LINE_HEIGHT#

The type of the None singleton.

ABSOLUTE_SIZE#

The type of the None singleton.

ALLOW_BREAKS#

The type of the None singleton.

BACKGROUND#

The type of the None singleton.

BACKGROUND_ALPHA#

The type of the None singleton.

BASELINE_SHIFT#

The type of the None singleton.

FALLBACK#

The type of the None singleton.

FAMILY#

The type of the None singleton.

FONT_DESC#

The type of the None singleton.

FONT_FEATURES#

The type of the None singleton.

FONT_SCALE#

The type of the None singleton.

FOREGROUND#

The type of the None singleton.

FOREGROUND_ALPHA#

The type of the None singleton.

GRAVITY#

The type of the None singleton.

GRAVITY_HINT#

The type of the None singleton.

INSERT_HYPHENS#

The type of the None singleton.

INVALID#

The type of the None singleton.

LANGUAGE#

The type of the None singleton.

LETTER_SPACING#

The type of the None singleton.

LINE_HEIGHT#

The type of the None singleton.

OVERLINE#

The type of the None singleton.

OVERLINE_COLOR#

The type of the None singleton.

RISE#

The type of the None singleton.

SCALE#

The type of the None singleton.

SENTENCE#

The type of the None singleton.

SHAPE#

The type of the None singleton.

SHOW#

The type of the None singleton.

SIZE#

The type of the None singleton.

STRETCH#

The type of the None singleton.

STRIKETHROUGH#

The type of the None singleton.

STRIKETHROUGH_COLOR#

The type of the None singleton.

STYLE#

The type of the None singleton.

TEXT_TRANSFORM#

The type of the None singleton.

UNDERLINE#

The type of the None singleton.

UNDERLINE_COLOR#

The type of the None singleton.

VARIANT#

The type of the None singleton.

WEIGHT#

The type of the None singleton.

WORD#

The type of the None singleton.