Commit 61918618 authored by rswindell's avatar rswindell

Create sbbs_t::cursor_getxy() which gets the current x/y coordinates even for...

Create sbbs_t::cursor_getxy() which gets the current x/y coordinates even for non-ANSI terminals (using the locally-tracked cursor position).
parent 14257de1
......@@ -969,6 +969,15 @@ bool sbbs_t::cursor_xy(int x, int y)
return false;
}
bool sbbs_t::cursor_getxy(int* x, int* y)
{
if(term_supports(ANSI))
return ansi_getxy(x, y);
*x = column + 1;
*y = row + 1;
return true;
}
void sbbs_t::cleartoeol(void)
{
int i,j;
......
......@@ -765,6 +765,7 @@ public:
void cursor_left(int count=1);
void cursor_right(int count=1);
bool cursor_xy(int x, int y);
bool cursor_getxy(int* x, int* y);
void carriage_return(int count=1);
void line_feed(int count=1);
void newline(int count=1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment