Font

class Font(val id: ResourcePath, providers: List<FontProvider> = emptyList())

Constructors

Link copied to clipboard
constructor(id: ResourcePath, providers: List<FontProvider> = emptyList())

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
fun add(provider: FontProvider)

Adds the given provider to the end of the list.

Link copied to clipboard
fun addAll(other: Font)

Adds all providers of the given font to the end of the list.

Link copied to clipboard
fun addFirst(provider: FontProvider)

Adds the given provider to the start of the list.

Link copied to clipboard
fun getCodePoints(fonts: Iterable<Font>): IntSet

Gets all occupied code points by resolving reference providers using the given fonts.

Link copied to clipboard

Maps every reference provider of this font to the corresponding font from fonts.

Link copied to clipboard
operator fun plusAssign(providers: Iterable<FontProvider>)

Adds the given providers to the end of the list.

operator fun plusAssign(font: Font)

Adds all providers of the given font to the end of the list.

operator fun plusAssign(provider: FontProvider)

Adds the given provider to the end of the list.

Link copied to clipboard
fun remove(provider: FontProvider)

Removes the given provider from the list.

Link copied to clipboard
open override fun toString(): String
Link copied to clipboard
fun write(assetsDir: Path)

Writes this Font to its corresponding file in the given assetsDir.