3.2 <PangoAttrType>

Enumeration: <PangoAttrType>

The <PangoAttrType> distinguishes between different types of attributes.

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

Members

invalid

does not happen

language

language (<PangoAttrLanguage>)

family

font family name list (<PangoAttrString>)

style

font slant style (<PangoAttrInt>)

weight

font weight (<PangoAttrInt>)

variant

font variant (normal or small caps) (<PangoAttrInt>)

stretch

font stretch (<PangoAttrInt>)

size

font size in points scaled by PANGO_SCALE (<PangoAttrInt>)

font-desc

font description (<PangoAttrFontDesc>)

foreground

foreground color (<PangoAttrColor>)

background

background color (<PangoAttrColor>)

underline

whether the text has an underline (<PangoAttrInt>)

strikethrough

whether the text is struck-through (<PangoAttrInt>)

rise

baseline displacement (<PangoAttrInt>)

shape

shape (<PangoAttrShape>)

scale

font size scale factor (<PangoAttrFloat>)

fallback

whether fallback is enabled (<PangoAttrInt>)

letter-spacing

letter spacing (PangoAttrInt)

underline-color

underline color (<PangoAttrColor>)

strikethrough-color

strikethrough color (<PangoAttrColor>)

absolute-size

font size in pixels scaled by PANGO_SCALE (<PangoAttrInt>)

gravity

base text gravity (<PangoAttrInt>)

gravity-hint

gravity hint (<PangoAttrInt>)

font-features

OpenType font features (<PangoAttrFontFeatures>). Since 1.38

foreground-alpha

foreground alpha (<PangoAttrInt>). Since 1.38

background-alpha

background alpha (<PangoAttrInt>). Since 1.38

allow-breaks

whether breaks are allowed (<PangoAttrInt>). Since 1.44

show

how to render invisible characters (<PangoAttrInt>). Since 1.44

insert-hyphens

whether to insert hyphens at intra-word line breaks (<PangoAttrInt>). Since 1.44

overline

whether the text has an overline (<PangoAttrInt>). Since 1.46

overline-color

overline color (<PangoAttrColor>). Since 1.46

line-height

line height factor (<PangoAttrFloat>). Since: 1.50

absolute-line-height

line height (<PangoAttrInt>). Since: 1.50

text-transform
word

override segmentation to classify the range of the attribute as a single word (<PangoAttrInt>). Since 1.50

sentence

override segmentation to classify the range of the attribute as a single sentence (<PangoAttrInt>). Since 1.50

baseline-shift

baseline displacement (<PangoAttrInt>). Since 1.50

font-scale

font-relative size change (<PangoAttrInt>). Since 1.50

Procedures

Procedure: attr-type:get-name type ⇒ %return

Fetches the attribute type name.

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

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

type

Passed: a <PangoAttrType>, or one of its symbols.

an attribute type ID to fetch the name for

%return

Returned: a string, or #f.

the type ID name (which may be #f), or #f if type is a built-in Pango attribute type or invalid.

Procedure: attr-type:register name ⇒ %return

Allocate a new attribute type ID.

The attribute type name can be accessed later by using attr-type:get-name.

name

Passed: a string.

an identifier for the type

%return

Returned: a <PangoAttrType>.

the new type ID.