mirror of
https://github.com/raysan5/raylib.git
synced 2025-11-26 20:20:39 +00:00
Refactor SpriteFont struct
Now it uses CharInfo data, this way, it's better aligned with the future RRES file format data layout for sprite font characters.
This commit is contained in:
@@ -45,10 +45,10 @@ int main()
|
||||
ClearBackground(RAYWHITE);
|
||||
|
||||
DrawText("Font name: PixAntiqua", 40, 50, 20, GRAY);
|
||||
DrawText(FormatText("Font base size: %i", font.size), 40, 80, 20, GRAY);
|
||||
DrawText(FormatText("Font chars number: %i", font.numChars), 40, 110, 20, GRAY);
|
||||
DrawText(FormatText("Font base size: %i", font.baseSize), 40, 80, 20, GRAY);
|
||||
DrawText(FormatText("Font chars number: %i", font.charsCount), 40, 110, 20, GRAY);
|
||||
|
||||
DrawTextEx(font, msg, (Vector2){ 40, 180 }, font.size, 0, MAROON);
|
||||
DrawTextEx(font, msg, (Vector2){ 40, 180 }, font.baseSize, 0, MAROON);
|
||||
|
||||
EndDrawing();
|
||||
//----------------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user