summaryrefslogtreecommitdiff
path: root/text.h
diff options
context:
space:
mode:
authorLeo Tenenbaum <pommicket@gmail.com>2020-11-25 22:02:43 -0500
committerLeo Tenenbaum <pommicket@gmail.com>2020-11-25 22:02:43 -0500
commit346acd202547c3ecb315ff7980f505643bacc77e (patch)
tree4884f16e6528bbf3576878944f49989ecc0979c9 /text.h
parent8461f5dec71f5d63d8ffba2ae1bb73ce2e74a000 (diff)
more scrolling
Diffstat (limited to 'text.h')
-rw-r--r--text.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/text.h b/text.h
index 9f0d351..25c5e49 100644
--- a/text.h
+++ b/text.h
@@ -25,6 +25,9 @@ extern void text_clear_err(void);
extern Font *text_font_load(char const *ttf_filename, float font_size);
// Height of a character of this font in pixels.
extern float text_font_char_height(Font *font);
+// Width of the character 'a' of this font in pixels.
+// This is meant to be only used for monospace fonts.
+extern float text_font_char_width(Font *font);
// Render some UTF-8 text to the screen (simple interface).
extern void text_render(Font *font, char const *text, float x, float y);
// Get the dimensions of some text.