From b3b3dd579278b6c322056509142fa701d5c2b700 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <bensberg@justemail.net>
Date: Tue, 18 Apr 2017 21:07:17 +0200
Subject: [PATCH] help: remove the final blank line, so <End> does the same as
 all <Down>

Since the help text is searchable, an <End> would go to the end of the
text but would leave a blank line above the statusbar -- a blank line
that wasn't there before, and that is not reached when simply holding
down <Down> all the way from the top.
---
 src/help.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/help.c b/src/help.c
index 8f1ddb89..1b2be872 100644
--- a/src/help.c
+++ b/src/help.c
@@ -77,6 +77,7 @@ void display_the_help_text(bool redisplaying)
 	close_buffer();
 
     open_buffer(tempfilename, FALSE);
+    remove_magicline();
 
     display_buffer();
 
@@ -189,7 +190,7 @@ void do_help(void)
 	} else if (func == do_up_void) {
 	    do_up(TRUE);
 	} else if (func == do_down_void) {
-	    if (openfile->edittop->lineno + editwinrows <
+	    if (openfile->edittop->lineno + editwinrows - 1 <
 				openfile->filebot->lineno)
 		do_down(TRUE);
 	} else if (func == do_page_up) {
-- 
GitLab