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

📄 qwindowx.hpp

📁 fgjhkcghkcghmbmcmcmxgfnhgxgnhynxntxrtnt
💻 HPP
字号:
/*****************************************************************************
	程序名称 : QWindowX.cpp
	程序功能 : 自建 WINDOW 类,重新设计了 box 功能
	开发时间 : 2004年 3月 4日
	开发者  : 邱洋
	最后修改 : NULL
	修改内容 : NULL
*****************************************************************************/

class  QWindow
{
	public:
		WINDOW     *QWin;        //窗口指针
		WINDOW     *MainWin;
		int        Color;        //颜色

	//构造函数
	QWindow(WINDOW  *QMainWin,int  Higth,int  Width,int  HBegin,int  WBegin,bool   cYoNbox,int  ColorNumb)
	{
		MainWin = QMainWin;
		QWin = derwin(QMainWin,Higth,Width,HBegin,WBegin);		//构造函数,建立窗口
		Color = ColorNumb;
		if (ColorNumb>0)               //如果这个变量大于0,则就给颜色
			SetWinColor(ColorNumb);
		if (cYoNbox)                   //如果这个变量大于零则给予边框
		{
			YoNbox = true;
			Box(QWin);
		}
		else
			YoNbox = false;
		wrefresh(QWin);//完成设定,刷新窗口
	}
	~QWindow()
	{
		delwin(QWin);
		wrefresh(MainWin);
	}

	//属性设置函数
	void    SetWinColor(int   ColorNumb);   //设定颜色
	void    Box(WINDOW   *Twin);            //外框(必须是双数)
	void    SetCaption(char *CAP);          //设定窗口名称

	protected:
		bool           YoNbox;     //是否画框

	//内容提取函数
};

⌨️ 快捷键说明

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