projects
/
visor
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
some progress with vi_redraw
[visor]
/
visor
/
src
/
term.c
diff --git
a/visor/src/term.c
b/visor/src/term.c
index
ee93e03
..
af7d278
100644
(file)
--- a/
visor/src/term.c
+++ b/
visor/src/term.c
@@
-91,6
+91,11
@@
void term_send(const char *s, int size)
}
}
}
}
+void term_putchar(char c)
+{
+ term_send(&c, 1);
+}
+
void term_puts(const char *s)
{
term_send(s, strlen(s));
void term_puts(const char *s)
{
term_send(s, strlen(s));
@@
-141,6
+146,16
@@
void term_clear(void)
term_puts("\033[2J");
}
term_puts("\033[2J");
}
+void term_cursor(int show)
+{
+ term_printf("\033[?25%c", show ? 'h' : 'l');
+}
+
+void term_setcursor(int row, int col)
+{
+ term_printf("\033[%d;%dH", row + 1, col + 1);
+}
+
int term_getchar(void)
{
int res;
int term_getchar(void)
{
int res;