console.h (471B)
1 // #include <libc.h> 2 // #include <uefi.h> 3 // #include <draw.h> 4 5 typedef struct AsciiFont { 6 int w, h; 7 uint8 glyph[128][16]; 8 } AsciiFont; 9 10 typedef struct Console { 11 Window *win; 12 AsciiFont *font; 13 int w, h; 14 Point pos; // cursor position in charactors. 15 } Console; 16 17 extern AsciiFont asciifont; 18 extern Console console; 19 20 void cons_putchar(Console *cons, char c); 21 int cons_print(Console *cons, char *s); 22 int cons_printf(Console *cons, char *fmt, ...);