FontFaceSet

EventTargetjs.html.FontFaceSet (extern class)

The FontFaceSet interface of the CSS Font Loading API manages the loading of font-faces and querying of their download status.

Documentation FontFaceSet by Mozilla Contributors, licensed under CC-BY-SA 2.5.

See:

Instance Members

size: Int

onloading: haxe.Function

An EventListener called whenever an event of type loading is fired, indicating a font-face set has started loading.


onloadingdone: haxe.Function

An EventListener called whenever an event of type loadingdone is fired, indicating that a font face set has finished loading.


onloadingerror: haxe.Function

An EventListener called whenever an event of type loadingerror is fired, indicating that an error occurred whilst loading a font-face set.



Indicates the font-face's loading status. It will be one of 'loading' or 'loaded'.


add(font: FontFace): Void
Name Type
font FontFace

has(font: FontFace): Bool
Name Type
font FontFace
Returns
Bool

delete(font: FontFace): Bool
Name Type
font FontFace
Returns
Bool

clear(): Void

Returns
FontFaceSetIterator

Returns
FontFaceSetIterator

forEach(cb: Function, ?thisArg: Dynamic): Void
Name Type Default
cb Function
thisArg Dynamic (optional)

load(font: String, ?text: String = " "): js.lib.Promise<Array<FontFace>>
Name Type Default
font String
text String " "
Returns
js.lib.Promise<Array<FontFace>>

check(font: String, ?text: String = " "): Bool
Name Type Default
font String
text String " "
Returns
Bool