commit-hurd
[Top][All Lists]
Advanced

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

[hurd] 18/26: Make CUD more usual


From: Samuel Thibault
Subject: [hurd] 18/26: Make CUD more usual
Date: Sat, 02 Nov 2013 14:44:46 +0000

This is an automated email from the git hooks/post-receive script.

sthibault pushed a commit to branch upstream
in repository hurd.

commit e1dff04f50833437c47cf1b737e69d3a73de9d63
Author: Samuel Thibault <address@hidden>
Date:   Tue Oct 22 14:38:28 2013 +0200

    Make CUD more usual
    
    Whether CUD scrolls the screen or not is implementation-dependant.
    Applications are not supposed to assume one way or the other, but they
    sometimes do, and most implementations do scroll, so let's stick to common
    practice.
    
    * console/display.c (handle_esc_bracket): On CUD/VPR, scroll the screen
    instead of capping the cursor position.
---
 console/display.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/console/display.c b/console/display.c
index 97e1626..8d9e478 100644
--- a/console/display.c
+++ b/console/display.c
@@ -1186,8 +1186,9 @@ handle_esc_bracket (display_t display, char op)
     case 'B':          /* ECMA-48 <CUD>.  */
     case 'e':          /* ECMA-48 <VPR>.  */
       /* Cursor down: <cud1>, <cud>.  */
-      user->cursor.row += (parse->params[0] ?: 1);
-      limit_cursor (display);
+      /* Most implementations scroll the screen.  */
+      for (i = 0; i < (parse->params[0] ?: 1); i++)
+       linefeed (display);
       break;
     case 'C':          /* ECMA-48 <CUF>.  */
       /* Cursor right: <cuf1>, <cuf>.  */

-- 
Alioth's /usr/local/bin/git-commit-notice on 
/srv/git.debian.org/git/pkg-hurd/hurd.git



reply via email to

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