tech-kern archive

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

Re: Add five new escape sequences to wscons



On Mon, Jan 16, 2023 at 15:10:06 -0300, Crystal Kolipe wrote:

> On Mon, Jan 16, 2023 at 08:20:35PM +0300, Valery Ushakov wrote:
> > On Mon, Jan 16, 2023 at 09:18:53 -0300, Crystal Kolipe wrote:
> > 
> > > It's useful, because these sequences correspond to the terminfo
> > > capabilities rin, indn, vpa, hpa, and cbt as defined in the xterm
> > > terminfo entry.  With these sequences implemented, it becomes
> > > slightly more practical to set TERM=xterm when connecting to remote
> > > systems that don't have a comprehensive terminfo database.
> > 
> > Why is is desirable to set specifically TERM=xterm instead of, say,
> > vt220, or whichever vt entry describes wscons the closest?
> 
> The xterm entry supports colour, which vt220 does not.

As someone who routinely runs xterm with TERM=vt220 I'm probably not
qualified to comment further.


> The multi-line scroll commands, as far as I understand, are supposed to
> scroll the entire screen, (or the scrolling region).

It's the "or the scrolling region" part that I'm not sure about.  The
terminfo documentation seems to indicate that the scrolling
capabilities like "ind" are to operate on the whole screen.

E.g. X/Open Curses, Issue 7 (p.353):

  To scroll text up, a program goes to the bottom left CORNER OF THE
  SCREEN and sends the ind (index) string.  To scroll text down, a
  program goes to the top left CORNER OF THE SCREEN and sends the ri
  (reverse index) string.  The strings ind and ri are undefined when
  not on their respective corners of the screen.

On the other hand a few pages later the same document says (p.356):

  To determine whether a terminal has destructive scrolling regions or
  non-destructive scrolling regions, create a scrolling region in the
  middle of the screen, place data on the bottom line of the scrolling
  region, move the cursor to the top LINE OF THE SCROLLING REGION, and
  do a reverse index (ri) followed by a delete line (dl1) or index
  (ind).  If the data that was originally on the bottom line of the
  scrolling region was restored into the scrolling region by dl1 or
  ind, then the terminal has non-destructive scrolling regions.
  Otherwise, it has destructive scrolling regions.

I cannot find any passages that would explicitly say how ind/ri and
csr interact.  (Note, I'm not talking about the observed behaviour of
specific xterm/vt commands, but about the semantic of terminfo
capabilities as abstractly defined in the ETI).

May be it's so obvious to everyone involved that "ind" and "ri" and to
operate on the scrolling region that no-one even realizes that the
current wording does actually say something different and you need to
do exegetics on an tangential remark elsewhere in the document to be
kinda able to infer that it's "screen (or the scrolling region)"

-uwe


Home | Main Index | Thread Index | Old Index