|
|
|
@ -794,6 +794,7 @@ int cursor_yx_get(int ttyfd, const char* u7, int* y, int* x){
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
int locate_cursor_early(struct notcurses* nc, int* cursor_y, int* cursor_x){
|
|
|
|
|
if(nc->ttyfd >= 0){
|
|
|
|
|
const char* u7 = get_escape(&nc->tcache, ESCAPE_DSRCPR);
|
|
|
|
|
// FIXME ought check for cursor inversion!
|
|
|
|
|
int ret = cursor_yx_get(nc->ttyfd, u7, cursor_y, cursor_x);
|
|
|
|
@ -807,5 +808,6 @@ int locate_cursor_early(struct notcurses* nc, int* cursor_y, int* cursor_x){
|
|
|
|
|
--*cursor_y;
|
|
|
|
|
--*cursor_x;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
return ret;
|
|
|
|
|
}
|
|
|
|
|