API Reference / @gtkx/cairo / ToyFontFace
Class: ToyFontFace
Defined in: packages/cairo/src/font-face.ts:100
A toy font face, created with FontFace.create or a context's selectFontFace.
Extends
Constructors
Constructor
new ToyFontFace():
ToyFontFace
Returns
ToyFontFace
Inherited from
Properties
__type__
__type__:
bigint
Defined in: packages/cairo/src/font-face.ts:81
GType of CairoFontFace, the boxed type this class is registered under.
Inherited from
Methods
getFamily()
getFamily():
string
Defined in: packages/cairo/src/font-face.ts:102
Returns the family name the font face was created with.
Returns
string
getReferenceCount()
getReferenceCount():
number
Defined in: packages/cairo/src/font-face.ts:94
Returns the reference count of the font face.
Returns
number
Inherited from
getSlant()
getSlant():
FontSlant
Defined in: packages/cairo/src/font-face.ts:107
Returns the slant the font face was created with.
Returns
getType()
getType():
FontType
Defined in: packages/cairo/src/font-face.ts:89
Returns the backend the font face belongs to.
Returns
Inherited from
getWeight()
getWeight():
FontWeight
Defined in: packages/cairo/src/font-face.ts:112
Returns the weight the font face was created with.
Returns
status()
status():
Status
Defined in: packages/cairo/src/font-face.ts:84
Returns the error status of the font face, Status.SUCCESS when it is usable.
Returns
Inherited from
create()
staticcreate(family,slant,weight):ToyFontFace
Defined in: packages/cairo/src/font-face.ts:76
Creates a toy font face from a family name, slant and weight.
Parameters
family
string
slant
weight
Returns
ToyFontFace