- for (i = 0; i < cnt; i++)
- if (XV)
- vputp(tgoto(DL, 0, p), WECHO - p);
- else
+ if (DL_PARM && (cnt>1 || *DL==0)) {
+ vputp(tgoto(DL_PARM, p, cnt), WECHO-p);
+ }
+ else if (CS && *DL==0) {
+ /* vt100: fake DL by changing scrolling region */
+ vputp(SC, 1); /* Save since CS homes stupid cursor */
+ vputp(tgoto(CS, LINES-1, p), 1);
+ vputp(tgoto(CM, 0, LINES-1), 1);/* Go to lower left corner */
+ for (i=0; i<cnt; i++) /* .. and scroll cnt times */
+ putch('\n'); /* should check NL too */
+ vputp(tgoto(CS, LINES-1, 0), 1);/* restore scrolling region */
+ vputp(RC, 1); /* put cursor back */
+ }
+ else {
+ for (i = 0; i < cnt; i++)