DeleteLine(screen, n) register TScreen *screen; register int n;
DeleteLine(register TScreen *screen, register int n)
DeleteLine(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->top_marg) {		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;	scrollheight = i - n;	refreshheight = n;	if((refreshtop = screen->bot_marg - refreshheight + 1 + shift) >	 (i = screen->max_row - refreshheight + 1))		refreshtop = i;	if(screen->scrollWidget && !screen->alternate && screen->cur_row == 0) {		scrolltop = 0;		if((scrollheight += shift) > i)			scrollheight = i;		if((i = screen->savedlines) < screen->savelines) {			if((i += n) > screen->savelines)				i = screen->savelines;			screen->savedlines = i;			ScrollBarDrawThumb(screen->scrollWidget);		}	} else {		scrolltop = screen->cur_row + shift;		if((i = screen->bot_marg - bot) > 0) {			scrollheight -= i;			if((i = screen->cur_row + n - 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));	}    }	/* adjust screen->buf */	if(screen->scrollWidget && !screen->alternate && screen->cur_row == 0)		ScrnDeleteLine(screen, screen->allbuf,			screen->bot_marg + screen->savelines, 0,			n, screen->max_col + 1);	else		ScrnDeleteLine(screen, screen->visbuf,			screen->bot_marg, screen->cur_row,			n, screen->max_col + 1);}