FL.objects.KerningPair.KerningPair

class FL.objects.KerningPair.KerningPair(kerningpair_or_index: KerningPair | int | None = None, value: int = 0)

Bases: Copyable

Class to represent kerning pair. This class is Multiple Master-compatible.

__init__(kerningpair_or_index: KerningPair | int | None = None, value: int = 0) None
KerningPair()

generic constructor, creates an empty KerningPair

KerningPair(KerningPair)

copy constructor

KerningPair(index)

creates a KerningPair to glyph referenced by index but zero value

KerningPair(index, value)

creates a KerningPair to glyph referenced by index and assigns value

Parameters:
  • kerningpair_or_index (KerningPair | int | None, optional) – _description_. Defaults to None.

  • value (int, optional) – _description_. Defaults to 0.

Methods

__init__([kerningpair_or_index, value])

KerningPair()

Attributes

fake_parent

key

index of right glyph of the pair

parent

KerningPair's parent object, Glyph.

value

value of the pair

values

list of values for each master

property key: int

index of right glyph of the pair

property parent: Glyph | None

KerningPair’s parent object, Glyph.

property value: int

value of the pair

property values: list[int]

list of values for each master