lynx-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

lynx-dev [PATCH 2.8.4dev.16] END key fixed


From: Ilya Zakharevich
Subject: lynx-dev [PATCH 2.8.4dev.16] END key fixed
Date: Mon, 29 Jan 2001 17:19:50 -0500
User-agent: Mutt/1.2.5i

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 address@hidden

reply via email to

[Prev in Thread] Current Thread [Next in Thread]