C++ -> C
This commit is contained in:
18
ui/base.c
Normal file
18
ui/base.c
Normal file
@@ -0,0 +1,18 @@
|
||||
#include "base.h"
|
||||
|
||||
#include <curses.h>
|
||||
#include <string.h>
|
||||
|
||||
|
||||
void draw_text(char *text, int *x, int *y) {
|
||||
if (!text || strnlen(text, 1) == 0) return;
|
||||
|
||||
mvaddch(*y, *x, *text);
|
||||
++text;
|
||||
|
||||
for (; *text != '\0'; ++text) {
|
||||
addch(*text);
|
||||
}
|
||||
|
||||
getyx(stdscr, *y, *x);
|
||||
}
|
||||
Reference in New Issue
Block a user