Font

interface Font : Disposable

An interface for describing and creating fonts in order to render their glyphs.

Author

Colton Daily

Functions

Link copied to clipboard
open override fun dispose()
Link copied to clipboard
open operator fun get(char: Char): GlyphMetrics?
open operator fun get(code: Int): GlyphMetrics?
Link copied to clipboard
open fun getKerning(first: Char, second: Char): Kerning?

Fetches the Kerning between two characters.

abstract fun getKerning(first: Int, second: Int): Kerning?

Fetches the Kerning between two codepoints.

Link copied to clipboard
open fun getKerningAmount(scale: Float, first: Char, second: Char): Float

Fetches the Kerning.amount between two characters.

open fun getKerningAmount(scale: Float, first: Int, second: Int): Float

Fetches the Kerning.amount between two codepoint.

Link copied to clipboard
open fun isWhitespace(char: Char): Boolean

Determines if the character is considered whitespace.

Link copied to clipboard
open fun isWrapChar(char: Char): Boolean

Determines if the character is considered a "wrap" character.

Properties

Link copied to clipboard

The glyph metrics supported by this Font.

Link copied to clipboard
abstract val metrics: FontMetrics

The font metrics of this Font

Link copied to clipboard
abstract var wrapChars: CharSequence

Additional characters besides whitespace where text is wrapped. Eg: a hyphen (-).

Inheritors

Link copied to clipboard
Link copied to clipboard