Skip to content

Commit

Permalink
REVIEWED: Added SetTextLineSpacing() to multiline examples
Browse files Browse the repository at this point in the history
  • Loading branch information
raysan5 committed Sep 2, 2023
1 parent 0f39051 commit d41e314
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions examples/text/text_codepoints_loading.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ int main(void)
// Set bilinear scale filter for better font scaling
SetTextureFilter(font.texture, TEXTURE_FILTER_BILINEAR);

SetTextLineSpacing(54); // Set line spacing for multiline text (when line breaks are included '\n')

// Free codepoints, atlas has already been generated
free(codepointsNoDups);

Expand Down
2 changes: 2 additions & 0 deletions examples/text/text_font_loading.c
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ int main(void)
// NOTE: We define a font base size of 32 pixels tall and up-to 250 characters
Font fontTtf = LoadFontEx("resources/pixantiqua.ttf", 32, 0, 250);

SetTextLineSpacing(48); // Set line spacing for multiline text (when line breaks are included '\n')

bool useTtf = false;

SetTargetFPS(60); // Set our game to run at 60 frames-per-second
Expand Down

0 comments on commit d41e314

Please sign in to comment.