Muteki
EABI code execution on Besta® RTOS devices.
Loading...
Searching...
No Matches
font.h File Reference

Font-related API. More...

#include "types/font.h"

Go to the source code of this file.

Functions

unsigned short GetCharWidth (UTF16 c, unsigned short font_type)
 Get the width of the character c used in font_type.
unsigned short GetFontHeight (unsigned short font_type)
 Get the height of the font font_type.
unsigned short GetFontWidth (unsigned int c, font_info_t *font, unsigned short *out_glyph_extent)
 Calculate the width of a glyph.

Detailed Description

Font-related API.

Function Documentation

◆ GetCharWidth()

unsigned short GetCharWidth ( UTF16 c,
unsigned short font_type )
extern

Get the width of the character c used in font_type.

Syscall Number
0x1004d
Parameters
cUTF-16 codepoint of the character.
font_typeThe font type.
Returns
The width in pixels of that character.
See also
font_type_e List of known font types.

◆ GetFontHeight()

unsigned short GetFontHeight ( unsigned short font_type)
extern

Get the height of the font font_type.

Syscall Number
0x1004e
Parameters
font_typeThe font type.
Returns
The height in pixels of that font.
See also
font_type_e List of known font types.

◆ GetFontWidth()

unsigned short GetFontWidth ( unsigned int c,
font_info_t * font,
unsigned short * out_glyph_extent )
extern

Calculate the width of a glyph.

Syscall Number
0x102bf
Parameters
cUnicode codepoint of the character. Going above U+FFFF is possible.
[in,out]fontThe font info record.
[out]out_glyph_extentActual horizontal extent of the glyph in pixels.
Returns
Simple width of the glyph in pixels, without accounting for features such as italic overhangs.