summaryrefslogtreecommitdiff
path: root/kernel/src/tty/term.h
blob: ceda255187b97e68f105d4d4c6a542956870ae08 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#pragma once 

#include <stdint.h>
#include <stddef.h>

#include "color.h"

#define TERM_W 80
#define TERM_H 25

void term_init(void);

void term_reset(void);
void term_setfg(enum VGAColor color);
void term_setbg(enum VGAColor color);

void term_clear(void);
void term_scroll(int lines);
void term_setpos(uint8_t x, uint8_t y);

uint32_t term_save(void);
void term_load(uint32_t state);

uint16_t term_save_col(void);
void term_load_col(uint16_t color);

bool term_newline(void);

void term_flush(void);