listwindow.h

来自「圣剑英雄传源码适合初学C语言者如细心阅读完定有收获!」· C头文件 代码 · 共 52 行

H
52
字号
//********************************************
//	图形列表框 相关函数
//  创建于2000年7月07日
//********************************************

#ifndef _LISTBOX_H_
#define _LISTBOX_H_

#include "window.h"
#include "scroll.h"

class CScroll;
class CGpFont;

//列表框类
class CListWindow : public CWindow
{
public:
	//标题结构
	struct stColumn{
		int x;			//显示位置
		int Align;		//对齐方式 0=left 1=right 2=center
		int Width;		//宽度
		char *Name;		//名字
	};

	int Id;
	int x, y, Width, Height;
	int LineHeight;					//行高

	int ColumnHeight;				//标题高度
	WORD ColumnColor;				//颜色
	CGpFont ColumnFont;				//标题字体

	int ColumnNum;					//标题数量
	stColumn *Column;				//标题

	CScroll ScrollBar;				//滚动条

	int Select;						//当前选择
	WORD SelectColor;				//被选单元的底色

public:
	CListWindow();
	~CListWindow();

	bool LoadListWindowIni(char *, char *);	//读入列表窗口
	void ShowListWindow(LPDIRECTDRAWSURFACE, bool bShowWindow=true, int left=-1, int top=-1);	//显示对话框
};

#endif

⌨️ 快捷键说明

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