This patch

  a) fixes off-by-one error in the END key handling (an empty line was
     shown at the end);

  b) Makes END key always show a full last page of the document.  In
     other words, even if the last line is already shown, it is moved to
     become the last line of the screen: so that as much as possible
     of the document is on the screen.

Enjoy,
Ilya

--- ./src/LYMainLoop.c~ Thu Aug 24 21:30:11 2000
+++ ./src/LYMainLoop.c  Mon Jan 29 17:09:06 2001
@@ -6948,9 +6948,10 @@ new_cmd:  /*
            break;
 
        case LYK_END:
-           if (more) {
-              Newline = HText_getNumOfLines() - display_lines + 3;  /* go to end of 
file */
-              arrowup = TRUE;   /* position on last link */
+           i = HText_getNumOfLines() - display_lines + 2;
+           if (i >= 1 && Newline != i) {
+              Newline = i;             /* go to end of file */
+              arrowup = TRUE;          /* position on last link */
            } else {
                cmd = LYK_NEXT_PAGE;
                goto new_cmd;

; To UNSUBSCRIBE: Send "unsubscribe lynx-dev" to [EMAIL PROTECTED]

Reply via email to