[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: TTY display trouble
From: |
Devon Sean McCullough |
Subject: |
Re: TTY display trouble |
Date: |
Mon, 25 Jul 2005 14:51:21 -0400 (EDT) |
From: "Richard M. Stallman" <address@hidden>
CC: address@hidden
Date: Sun, 24 Jul 2005 21:43:01 -0400
The fix is to scroll the emacs command line off the top at initial
startup and suspend resume, before any mode line or text redisplay.
Newlines are best because clear screen fails to preserve scroll back
Would simply outputting a number of newlines equal to the screen height
do the job? If that would work, we can easily do it.
Yes, in place of the termcap:ti string emacs apparently outputs now,
which selects the "Alternate Screen Buffer" with the side effect of
excluding emacs screens from the terminal scroll back buffer.
Therefore this should be a user choice.
Peace
--Devon
PS: EMACS uses the alt screen when I enable it in GNU SCREEN
although TCONV reports no such capability, I'm baffled.
The alt screen feature is disabled by default in GNU SCREEN
and absent from the termcap/terminfo databases in FreeBSD and MacOS.
Unix manuals, however, assume "cup" (cursor-positioning) programs use it.
SCREEN(1) SCREEN(1)
altscreen on|off
TERMCAP(5) FreeBSD File Formats Manual TERMCAP(5)
enter_ca_mode ti string to start programs using
cursor_address
exit_ca_mode te strings to end programs using cup
non_rev_rmcup NR enter_ca_mode does not reverse exit_ca_mode
TERMINFO(5) File Formats TERMINFO(5)
enter_ca_mode smcup ti string to start programs using cup
exit_ca_mode rmcup te strings to end programs using cup
non_rev_rmcup nrrmc NR smcup does not reverse rmcup
;;; Video Terminal VT-100/XTERM escape codes
(defvar vt-screen-alternate-buffer-string "\e[?47h"
"Video Terminal command to use Alternate Screen Buffer.")
(defvar vt-screen-normal-buffer-string "\e[?47l"
"Video Terminal command to use Normal Screen Buffer.")
(defun vt-screen-snapshot ()
"Append an emacs screen snapshot to the terminal scrollback buffer."
(send-string-to-terminal vt-screen-alternate-buffer-string)
(send-string-to-terminal (make-string (screen-height) ?\n))
(redraw-frame (selected-frame))
(send-string-to-terminal vt-screen-normal-buffer-string)
(redraw-frame (selected-frame)))
(defun vt-screen-alternate-hook ()
(send-string-to-terminal vt-screen-alternate-buffer-string))
(defun vt-screen-normal-hook ()
(send-string-to-terminal vt-screen-normal-buffer-string))