Class "Font"
Constructors
Font () {: aria-label='Constructors' }
void Font ( void ) {: .copyable aria-label='Constructors' }
Constructor for the "Font" class.
???- example "Example Code" Example usage.
Functions
DrawString () {: aria-label='Functions' }
void DrawString ( string String, float PositionX, float PositionY, KColor RenderColor, u_int BoxWidth, boolean Center ) {: .copyable aria-label='Functions' }
Draws a string of text to the screen Converts UTF8 to UTF16, then draws the string. Notes: The BoxWidth and Center parameters can be used for aligning the text: If BoxWidth is zero, the text will be left aligned and the center parameter will be ignored If BoxWidth is NOT zero, and the Center parameter is FALSE, then the text will be right aligned inside the BoxWidth size If BoxWidth is NOT zero, and the center parameter is TRUE, then the text will be centered inside the BoxWidth size
???- example "Example Code" Example usage.
DrawStringScaled () {: aria-label='Functions' }
void DrawStringScaled ( string String, float PositionX, float PositionY, float ScaleX, float ScaleY, KColor RenderColor, u_int BoxWidth, boolean Center ) {: .copyable aria-label='Functions' }
Draws a scaled string of text on the screen. Converts UTF8 to UTF16, then draws the string.
???- example "Example Code" Example usage.
DrawStringScaledUTF8 () {: aria-label='Functions' }
void DrawStringScaledUTF8 ( string String, float PositionX, float PositionY, float ScaleX, float ScaleY, KColor RenderColor, u_int BoxWidth, boolean Center ) {: .copyable aria-label='Functions' }
Draws a scaled string of Unicode text on the screen.
???- example "Example Code" Example usage.
DrawStringUTF8 () {: aria-label='Functions' }
void DrawStringUTF8 ( string String, float PositionX, float PositionY, KColor RenderColor, u_int BoxWidth, boolean Center ) {: .copyable aria-label='Functions' }
Draws a string of Unicode text to the screen Notes: The BoxWidth and Center parameters can be used for aligning the text: If BoxWidth is zero, the text will be left aligned and the center parameter will be ignored If BoxWidth is NOT zero, and the Center parameter is FALSE, then the text will be right aligned inside the BoxWidth size If BoxWidth is NOT zero, and the center parameter is TRUE, then the text will be centered inside the BoxWidth size
???- example "Example Code" Example usage.
GetBaselineHeight () {: aria-label='Functions' }
u_int GetBaselineHeight ( ) {: .copyable aria-label='Functions' }
Get the number of pixels from the absolute top of the line to the base of the characters
GetCharacterWidth () {: aria-label='Functions' }
u_int GetCharacterWidth ( char Character ) {: .copyable aria-label='Functions' }
Returns the width of a specific character
GetLineHeight () {: aria-label='Functions' }
u_int GetLineHeight ( ) {: .copyable aria-label='Functions' }
Get the distance in pixels between each line of text
GetStringWidth () {: aria-label='Functions' }
u_int GetStringWidth ( string String ) {: .copyable aria-label='Functions' }
Converts UTF8 to UTF16 and returns string width
GetStringWidthUTF8 () {: aria-label='Functions' }
u_int GetStringWidthUTF8 ( string String ) {: .copyable aria-label='Functions' }
returns string width of a Unicode text.
IsLoaded () {: aria-label='Functions' }
boolean IsLoaded ( ) {: .copyable aria-label='Functions' }
Returns whether a font is loaded or not.
Load () {: aria-label='Functions' }
boolean Load ( string FilePath ) {: .copyable aria-label='Functions' }
Loads a font.
???- example "Example Code" Example usage.
SetMissingCharacter () {: aria-label='Functions' }
void SetMissingCharacter ( u16 MissingCharacter ) {: .copyable aria-label='Functions' }
Converts UTF8 to UTF16, then draws Sets the missing character to be used by the font (the character used when missing characters are encountered)
Unload () {: aria-label='Functions' }
void Unload ( ) {: .copyable aria-label='Functions' }
Unloads all our data from memory
Last updated