diff options
Diffstat (limited to 'src/text.h')
-rw-r--r-- | src/text.h | 18 |
1 files changed, 7 insertions, 11 deletions
@@ -250,17 +250,13 @@ txt_init_hybrid(TextMode mode, Font font, u32 *buf) { | |||
250 | } | 250 | } |
251 | 251 | ||
252 | // Print text to the screen with formatting. | 252 | // Print text to the screen with formatting. |
253 | void | 253 | |
254 | txt_printf(char *msg, ...) { | 254 | #define txt_printf(msg, ...) \ |
255 | va_list arg_list; | 255 | { \ |
256 | va_start(arg_list, msg); | 256 | char buf[256] = {0}; \ |
257 | char buf[512] = {0}; | 257 | posprintf(buf, msg, ##__VA_ARGS__); \ |
258 | // TODO: This call pulls in malloc() and a bunch of other things. | 258 | txt_puts(buf); \ |
259 | // To reduce memory usage and filesize, it would be advisable | 259 | } |
260 | // to replace it with something simpler. | ||
261 | vsiprintf(buf, msg, arg_list); | ||
262 | txt_puts(buf); | ||
263 | } | ||
264 | 260 | ||
265 | void | 261 | void |
266 | txt_clear_line_tiled(void) { | 262 | txt_clear_line_tiled(void) { |