Getting better scrolling from curses?

Paul Chamberlain tif at doorstop.austin.ibm.com
Thu Jun 13 00:15:58 AEST 1991


Not really an answer but some information that might lead you in the
right direction.

In article <1991Jun11.211657.17798 at jwt.UUCP> john at jwt.UUCP (John Temples) writes:
>The second problem occurs when scrolling the upper window in one of
>these applications.  With idlok() enabled, the lower window jumps up
>and down a line for every line the upper window scrolls.

This is being done by deleting a line at the top of the top window
and inserting a blank line at the bottom of the top window.

>If I turn off
>idlok(), the unpleasant artifacts disappear, but scrolling speed falls
>dramatically, while CPU consumption rises.  Is there any way to get
>clean, fast scrolling in two windows like this?

This is done by redrawing each line I think.

What you really want is something that uses scroll regions.  Now,
it'd be convenient if I knew whether curses knows how to use
scroll regions or not but I don't.  If it does though, all you
have to do (I'm guessing now) is make sure that the terminfo
entry for your terminal has the right thing for "csr".

Also, yeah it'd be nice if curses knew that when scrolling a full
screen window all you have to do is new-line from the bottom line.

Paul Chamberlain | I do NOT speak for IBM.          IBM VNET: PAULCC AT AUSTIN
512/838-9748     | ...!cs.utexas.edu!ibmchs!auschs!doorstop.austin.ibm.com!tif



More information about the Comp.unix.programmer mailing list