diff options
Diffstat (limited to 'framebuffer.h')
| -rw-r--r-- | framebuffer.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/framebuffer.h b/framebuffer.h index 7571294..6191f2c 100644 --- a/framebuffer.h +++ b/framebuffer.h @@ -65,6 +65,13 @@ void fb_put(Framebuffer fb, size_t row, size_t col, Pixel pixel); /* Draws a vertical line to fb on col x, from y1 to y2 */ void fb_vert_line(Framebuffer fb, size_t x, size_t y1, size_t y2, Pixel pixel); +/* Puts s onto fb in position (x, y) with given colour. s has to be null-terminated. + * x is of type long to handle text 'origin' being lefter than the left edge when x < 0 */ +void fb_text(Framebuffer fb, long x, size_t y, char *s, Colour fg, Colour bg); + +/* Same as above, but the background is 'transparent' */ +void fb_text_no_bg(Framebuffer fb, long x, size_t y, char *s, Colour fg); + /* Initializes the terminal and sets TERM_WIDTH and TERM_HEIGHT */ void term_init(void); |
