Skip to content

A generic font caching C++ library with loading and rendering support for SDL. C version by grimfang4.

License

Notifications You must be signed in to change notification settings

deltanedas/SDL_fontcache

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

67 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SDL_FontCache

A generic font caching C++ library with loading and rendering support for SDL.

SDL_FontCache loads, caches, and renders TrueType fonts using SDL_ttf.
It fully supports UTF-8 strings and includes some utility functions for manipulating them.

An example using SDL_Renderer:

FC_Font* font = FC_CreateFont();  
FC_LoadFont(font, renderer, "fonts/FreeSans.ttf", 20, FC_MakeColor(0,0,0,255), TTF_STYLE_NORMAL);  

...

FC_Draw(font, renderer, 0, 0, "This is %s.\n It works.", "example text"); 
 
...

FC_FreeFont(font);

Original version written in C by grimfang4

About

A generic font caching C++ library with loading and rendering support for SDL. C version by grimfang4.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 86.1%
  • C 12.2%
  • Makefile 1.7%