InsertLine (screen, n) register TScreen *screen; register int n;
InsertLine (register TScreen *screen, register int n)
InsertLine (screen, n)register TScreen *screen;register int n;{	register int i;	register int shift;	register int bot;	register int refreshtop;	register int refreshheight;	register int scrolltop;	register int scrollheight;	if (screen->cur_row < screen->top_marg ||	 screen->cur_row > screen->bot_marg)		return;	if(screen->cursor_state)		HideCursor();	screen->do_wrap = 0;	if (n > (i = screen->bot_marg - screen->cur_row + 1))		n = i;    if(screen->jumpscroll) {	if(screen->scroll_amt <= 0 &&	 screen->cur_row <= -screen->refresh_amt) {		if(-screen->refresh_amt + n > screen->max_row + 1)			FlushScroll(screen);		screen->scroll_amt -= n;		screen->refresh_amt -= n;	} else if(screen->scroll_amt)		FlushScroll(screen);    }    if(!screen->scroll_amt) {	shift = -screen->topline;	bot = screen->max_row - shift;	refreshheight = n;	scrollheight = screen->bot_marg - screen->cur_row - refreshheight + 1;	refreshtop = screen->cur_row + shift;	scrolltop = refreshtop + refreshheight;	if((i = screen->bot_marg - bot) > 0)		scrollheight -= i;	if((i = screen->cur_row + refreshheight - 1 - bot) > 0)		refreshheight -= i;	vertical_copy_area(screen, scrolltop-n, scrollheight, -n);	if(refreshheight > 0) {		ClearCurBackground(screen,		    (int) refreshtop * FontHeight(screen) + screen->border,		    (int) OriginX(screen),		    (unsigned) refreshheight * FontHeight(screen),		    (unsigned) Width(screen));	}    }    ScrnInsertLine(screen, screen->visbuf, screen->bot_marg, screen->cur_row, n,		   screen->max_col + 1);}