commit cf75da9888a1b3b4b1c7b6052961a1920a29385e
parent 14c62dbf11f539c1f98349bfb3f97622d7157ac7
Author: Benno Schulenberg <bensberg@justemail.net>
Date: Mon, 9 Jan 2017 15:00:29 +0100
softwrap: when pasting an overlong line, ensure it is fully visible
This fixes https://savannah.gnu.org/bugs/?50009.
Diffstat:
1 file changed, 5 insertions(+), 0 deletions(-)
diff --git a/src/cut.c b/src/cut.c
@@ -287,6 +287,11 @@ void do_uncut_text(void)
/* Update the cursor position to account for the inserted lines. */
reset_cursor();
+#ifndef NANO_TINY
+ if (ISSET(SOFTWRAP))
+ ensure_line_is_visible();
+#endif
+
refresh_needed = TRUE;
#ifndef DISABLE_COLOR