MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / LoadFont

Function LoadFont

Descent3/gamefont.cpp:147–155  ·  view source on GitHub ↗

Loads the font and returns the handle. Exits with an error if the font can't be found.

Source from the content-addressed store, hash-verified

145
146// Loads the font and returns the handle. Exits with an error if the font can't be found.
147int LoadFont(const char *font_name) {
148 int handle = grfont_Load(font_name);
149 if (handle == -1)
150 Error(TXT_ERRNOFONT, font_name);
151
152 mprintf(0, "Font <%s> height = %d\n", font_name, grfont_GetHeight(handle));
153
154 return handle;
155}
156
157// loads all game fonts.
158void LoadAllFonts() {

Callers 2

LoadAllFontsFunction · 0.85
SelectHUDFontFunction · 0.85

Calls 3

grfont_LoadFunction · 0.85
ErrorFunction · 0.85
grfont_GetHeightFunction · 0.85

Tested by

no test coverage detected