Use Lua string length instead of relying on strlen (#1262)
This allows us to render `NULL` byte sequences and not truncate strings that contain them.
This commit is contained in:
+2
-2
@@ -28,8 +28,8 @@ int ren_font_group_get_height(RenFont **font);
|
||||
float ren_font_group_get_size(RenFont **font);
|
||||
void ren_font_group_set_size(RenFont **font, float size);
|
||||
void ren_font_group_set_tab_size(RenFont **font, int n);
|
||||
float ren_font_group_get_width(RenFont **font, const char *text);
|
||||
float ren_draw_text(RenFont **font, const char *text, float x, int y, RenColor color);
|
||||
float ren_font_group_get_width(RenFont **font, const char *text, size_t len);
|
||||
float ren_draw_text(RenFont **font, const char *text, size_t len, float x, int y, RenColor color);
|
||||
|
||||
void ren_draw_rect(RenRect rect, RenColor color);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user