1 #ifndef LIBWTK_SDL2_FONT_MANAGER_HPP 2 #define LIBWTK_SDL2_FONT_MANAGER_HPP 7 #include <SDL2/SDL_render.h> 10 #include "font_word_cache.hpp" 11 #include "geometry.hpp" 15 font_manager(SDL_Renderer * renderer, std::vector<font> fonts);
21 std::size_t load_font(
font f);
25 std::tuple<vec, std::vector<copy_command>> text(std::string t,
int max_line_width = -1,
int font_idx = 0);
26 vec text_size(std::string t,
int max_line_width = -1,
int font_idx = 0);
27 int text_minimum_width(std::string t,
int font_idx = 0);
28 unsigned int font_height(
int font_idx = 0)
const;
29 int font_line_skip(
int font_idx = 0)
const;
33 SDL_Renderer * _renderer;
34 std::vector<font_word_cache> _font_word_caches;
Definition: geometry.hpp:12
Definition: font_manager.hpp:13