Compare commits

...
2 Commits
Author SHA1 Message Date
bonkmaykr 6e79035cc3 signing off. todo in commit description
todo:
fix 0-wide chars
  minimum of 1px, minimum of some other px for spaces. chars with no width cause the base allegro_font addon to fail.
new optional param in load call to specify ranges from within the game
2026-09-22 14:37:56 -05:00
bonkmaykr 5181f163e8 fix bullshit clangd error when operating on single bytes inside an unsigned int 2026-09-22 14:26:02 -05:00
+5 -5
View File
@@ -18,10 +18,10 @@
ALLEGRO_DEBUG_CHANNEL("font")
#define CANI_ALLEGRO_SCHRIFT_VER 1
#define delimit_red 0
#define delimit_green 0
#define delimit_blue 255
#define delimit_alpha 255
#define delimit_red (unsigned)0 // shut up i know what i'm doing
#define delimit_green (unsigned)0
#define delimit_blue (unsigned)255
#define delimit_alpha (unsigned)255
#define delimit_color al_map_rgba(delimit_red, delimit_green, delimit_blue, delimit_alpha)
/* globals */
@@ -65,7 +65,7 @@ ALLEGRO_FONT *al_load_ttf_font_f(ALLEGRO_FILE *file,
al_get_config_value(system_cfg, "ttf", "cache_text");
if (!cache_text_str) {
ALLEGRO_ERROR("No characters defined in cache_text! Using defaults\n");
cache_text_str = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789 ";
cache_text_str = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789.,!?/()@#$%^&*-_=+<>~`\u007F ";
}
// read font file