diff options
Diffstat (limited to 'crawl-ref/source/libdos.cc')
-rw-r--r-- | crawl-ref/source/libdos.cc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/crawl-ref/source/libdos.cc b/crawl-ref/source/libdos.cc index 86c7aec1b6..b105896ba9 100644 --- a/crawl-ref/source/libdos.cc +++ b/crawl-ref/source/libdos.cc @@ -33,3 +33,12 @@ bool is_cursor_enabled() { return (cursor_is_enabled); } + +// This will force the cursor down to the next line. +void clear_to_end_of_line() +{ + const int pos = wherex(); + const int cols = get_number_of_cols(); + if (pos <= cols) + cprintf("%*s", cols - pos + 1, ""); +} |