⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 werase.c

📁 minux的源代码,一个非常小的操作系统
💻 C
字号:
#include <curses.h>
#include "curspriv.h"

/****************************************************************/
/* Werase() fills all lines of window 'win' with blanks and po-	*/
/* Sitions the cursor at home in the scroll region.		*/
/****************************************************************/

void werase(win)
WINDOW *win;
{
  int *end, *start, y, blank;

  blank = ' ' | (win->_attrs & ATR_MSK);

  for (y = win->_regtop; y <= win->_regbottom; y++) {	/* clear all lines */
	start = win->_line[y];
	end = &start[win->_maxx];
	while (start <= end)	/* clear all line */
		*start++ = blank;
	win->_minchng[y] = 0;
	win->_maxchng[y] = win->_maxx;
  }
  win->_cury = win->_regtop;	/* cursor home */
  win->_curx = 0;
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -