Pango.AttrSize

Fields

Name

Type

Access

Description

absolute

int

r/w

whether the font size is in device units or points. This field is only present for compatibility with Pango-1.8.0 (Pango.AttrType.ABSOLUTE_SIZE was added in 1.8.1); and always will be False for Pango.AttrType.SIZE and True for Pango.AttrType.ABSOLUTE_SIZE.

attr

Pango.Attribute

r/w

the common portion of the attribute

size

int

r/w

size of font, in units of 1/Pango.SCALE of a point (for Pango.AttrType.SIZE) or of a device unit (for Pango.AttrType.ABSOLUTE_SIZE)

Methods

class

new (size)

class

new_absolute (size)

Details

class Pango.AttrSize

The PangoAttrSize structure is used to represent attributes which set font size.

classmethod new(size)[source]
Parameters:

size (int) – the font size, in Pango.SCALE-ths of a point

Returns:

the newly allocated PangoAttribute, which should be freed with [method`Pango`.Attribute.destroy]

Return type:

Pango.Attribute

Create a new font-size attribute in fractional points.

classmethod new_absolute(size)[source]
Parameters:

size (int) – the font size, in Pango.SCALE-ths of a device unit

Returns:

the newly allocated PangoAttribute, which should be freed with [method`Pango`.Attribute.destroy]

Return type:

Pango.Attribute

Create a new font-size attribute in device units.

New in version 1.8.