Commit | Line | Data |
---|---|---|
8f970554 KA |
1 | # include "curses.ext" |
2 | ||
3 | /* | |
4 | * This routine performs an insert-char on the line, leaving | |
5 | * (_cury,_curx) unchanged. | |
6 | * | |
4ed74706 | 7 | * @(#)delch.c 1.2 (Berkeley) %G% |
8f970554 KA |
8 | */ |
9 | wdelch(win) | |
10 | reg WINDOW *win; { | |
11 | ||
12 | reg char *temp1, *temp2; | |
13 | reg char *end; | |
14 | ||
15 | end = &win->_y[win->_cury][win->_maxx - 1]; | |
4ed74706 KA |
16 | temp1 = &win->_y[win->_cury][win->_curx]; |
17 | temp2 = temp1 + 1; | |
8f970554 KA |
18 | while (temp1 < end) |
19 | *temp1++ = *temp2++; | |
20 | *temp1 = ' '; | |
21 | win->_lastch[win->_cury] = win->_maxx - 1; | |
22 | if (win->_firstch[win->_cury] == _NOCHANGE || | |
23 | win->_firstch[win->_cury] > win->_curx) | |
24 | win->_firstch[win->_cury] = win->_curx; | |
25 | return OK; | |
26 | } |