LogoPixi’VN
pixi-jsClasses

Class: DynamicBitmapFont

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/DynamicBitmapFont.d.ts:23

Internal

A BitmapFont that generates its glyphs dynamically.

Extends

Constructors

Constructor

> new DynamicBitmapFont(options): DynamicBitmapFont

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/DynamicBitmapFont.d.ts:50

Parameters

options

DynamicBitmapFontOptions

The options for the dynamic bitmap font.

Returns

DynamicBitmapFont

Overrides

AbstractBitmapFont.constructor

Properties

applyFillAsTint

> applyFillAsTint: boolean

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:107

should the fill for this font be applied as a tint to the text.

Inherited from

AbstractBitmapFont.applyFillAsTint


baseLineOffset

> readonly baseLineOffset: number

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:99

The offset of the font face from the baseline.

Inherited from

AbstractBitmapFont.baseLineOffset


baseMeasurementFontSize

> readonly baseMeasurementFontSize: number

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:109

The size of the font face in pixels.

Inherited from

AbstractBitmapFont.baseMeasurementFontSize


baseRenderedFontSize

> protected baseRenderedFontSize: number

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:110

Inherited from

AbstractBitmapFont.baseRenderedFontSize


chars

> readonly chars: Record<string, CharData>

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:82

The map of characters by character string.

Inherited from

AbstractBitmapFont.chars


distanceField

> readonly distanceField: { range: number; type: "none" | "sdf" | "msdf"; } | undefined

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:101

The range and type of the distance field for this font.

Union Members

Type Literal

{ range: number; type: "none" | "sdf" | "msdf"; }

range

> range: number

Range of the distance field in pixels

type

> type: "none" | "sdf" | "msdf"

Type of distance field


undefined

Inherited from

AbstractBitmapFont.distanceField


fontFamily

> readonly fontFamily: string

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:92

The name of the font face

Inherited from

AbstractBitmapFont.fontFamily


fontMetrics

> readonly fontMetrics: FontMetrics

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:94

The metrics of the font face.

Inherited from

AbstractBitmapFont.fontMetrics


lineHeight

> readonly lineHeight: number

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:87

The line-height of the font face in pixels.

Inherited from

AbstractBitmapFont.lineHeight


pages

> readonly pages: object[]

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/DynamicBitmapFont.d.ts:31

The pages of the font.

canvasAndContext?

> optional canvasAndContext?: CanvasAndContext

texture

> texture: Texture

Overrides

AbstractBitmapFont.pages


resolution

> resolution: number

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/DynamicBitmapFont.d.ts:29

this is a resolution modifier for the font size.. texture resolution will also be used to scale texture according to its font size also


defaultOptions

> static defaultOptions: DynamicBitmapFontOptions

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/DynamicBitmapFont.d.ts:24


prefixed

> static prefixed: string | boolean

Defined in: node_modules/eventemitter3/index.d.ts:9

Inherited from

AbstractBitmapFont.prefixed

Accessors

distanceFieldRange

Get Signature

> get distanceFieldRange(): number

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:130

The kind of distance field for this font or "none".

Deprecated

since 8.0.0 Use distanceField.type instead.

Returns

number

Inherited from

AbstractBitmapFont.distanceFieldRange


distanceFieldType

Get Signature

> get distanceFieldType(): "none" | "sdf" | "msdf"

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:135

The range of the distance field in pixels.

Deprecated

since 8.0.0 Use distanceField.range instead.

Returns

"none" | "sdf" | "msdf"

Inherited from

AbstractBitmapFont.distanceFieldType


font

Get Signature

> get font(): string

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:115

The name of the font face.

Deprecated

since 8.0.0 Use fontFamily instead.

Returns

string

Inherited from

AbstractBitmapFont.font


pageTextures

Get Signature

> get pageTextures(): object[]

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/DynamicBitmapFont.d.ts:56

Deprecated

since 8.0.0 The map of base page textures (i.e., sheets of glyphs).

Returns

object[]

Overrides

AbstractBitmapFont.pageTextures


size

Get Signature

> get size(): number

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/AbstractBitmapFont.d.ts:125

The size of the font face in pixels.

Deprecated

since 8.0.0 Use fontMetrics.fontSize instead.

Returns

number

Inherited from

AbstractBitmapFont.size

Methods

addListener()

> addListener<T>(event, fn, context?): this

Defined in: node_modules/eventemitter3/index.d.ts:45

Type Parameters

T

T extends "destroy"

Parameters

event

T

fn

(...args) => void

context?

any

Returns

this

Inherited from

AbstractBitmapFont.addListener


destroy()

> destroy(): void

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/DynamicBitmapFont.d.ts:61

Returns

void

Overrides

AbstractBitmapFont.destroy


emit()

> emit<T>(event, ...args): boolean

Defined in: node_modules/eventemitter3/index.d.ts:32

Calls each of the listeners registered for a given event.

Type Parameters

T

T extends "destroy"

Parameters

event

T

args

...ArgumentMap<BitmapFontEvents<DynamicBitmapFont>>[Extract<T, "destroy">]

Returns

boolean

Inherited from

AbstractBitmapFont.emit


ensureCharacters()

> ensureCharacters(chars): void

Defined in: node_modules/pixi.js/lib/scene/text-bitmap/DynamicBitmapFont.d.ts:51

Parameters

chars

string

Returns

void


eventNames()

> eventNames(): "destroy"[]

Defined in: node_modules/eventemitter3/index.d.ts:15

Return an array listing the events for which the emitter has registered listeners.

Returns

"destroy"[]

Inherited from

AbstractBitmapFont.eventNames


listenerCount()

> listenerCount(event): number

Defined in: node_modules/eventemitter3/index.d.ts:27

Return the number of listeners listening to a given event.

Parameters

event

"destroy"

Returns

number

Inherited from

AbstractBitmapFont.listenerCount


listeners()

> listeners<T>(event): (...args) => void[]

Defined in: node_modules/eventemitter3/index.d.ts:20

Return the listeners registered for a given event.

Type Parameters

T

T extends "destroy"

Parameters

event

T

Returns

(...args) => void[]

Inherited from

AbstractBitmapFont.listeners


off()

> off<T>(event, fn?, context?, once?): this

Defined in: node_modules/eventemitter3/index.d.ts:69

Type Parameters

T

T extends "destroy"

Parameters

event

T

fn?

(...args) => void

context?

any

once?

boolean

Returns

this

Inherited from

AbstractBitmapFont.off


on()

> on<T>(event, fn, context?): this

Defined in: node_modules/eventemitter3/index.d.ts:40

Add a listener for a given event.

Type Parameters

T

T extends "destroy"

Parameters

event

T

fn

(...args) => void

context?

any

Returns

this

Inherited from

AbstractBitmapFont.on


once()

> once<T>(event, fn, context?): this

Defined in: node_modules/eventemitter3/index.d.ts:54

Add a one-time listener for a given event.

Type Parameters

T

T extends "destroy"

Parameters

event

T

fn

(...args) => void

context?

any

Returns

this

Inherited from

AbstractBitmapFont.once


removeAllListeners()

> removeAllListeners(event?): this

Defined in: node_modules/eventemitter3/index.d.ts:79

Remove all listeners, or those of the specified event.

Parameters

event?

"destroy"

Returns

this

Inherited from

AbstractBitmapFont.removeAllListeners


removeListener()

> removeListener<T>(event, fn?, context?, once?): this

Defined in: node_modules/eventemitter3/index.d.ts:63

Remove the listeners of a given event.

Type Parameters

T

T extends "destroy"

Parameters

event

T

fn?

(...args) => void

context?

any

once?

boolean

Returns

this

Inherited from

AbstractBitmapFont.removeListener