From 13479fbc2a130d97caeb66f7f56fb89c6be8c489 Mon Sep 17 00:00:00 2001 From: David Adam Date: Fri, 16 Oct 2015 11:53:51 +0800 Subject: [PATCH] reader.cpp: send carriage return after printing the window title Terminals can get confused by all the non-printed characters about the line position. Closes #2453. --- src/reader.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/reader.cpp b/src/reader.cpp index 63b702835..9b90a70ff 100644 --- a/src/reader.cpp +++ b/src/reader.cpp @@ -952,6 +952,8 @@ void reader_write_title(const wcstring &cmd) } proc_pop_interactive(); set_color(rgb_color_t::reset(), rgb_color_t::reset()); + // Put the cursor back at the beginning of the line #2453 + writestr(L"\r"); } /**