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

📄 report.h

📁 这是一个银行系统的管理软件
💻 H
字号:
/**********************************************************************************
*                                                                                 *
*  Henry Banking System ATM Module                                                *
*  Copyright (c) 2004 by Henry. All rights reserved.                              *
*                                                                                 *
*  Permission to use, copy, modify, and distribute this software for any purpose  *
*  is hereby granted without fee, provided that this copyright and permissions    *
*  notice appear in all copies and derivatives, and that no charge may be made    *
*  for the software and its documentation except to cover cost of distribution.   *
*                                                                                 *
*  This software is provided "as is" without express or implied warranty.         *
*                                                                                 *
**********************************************************************************/

/*
*  Description:
*
*    Generate a report form in a CUI way.
*
*  Notes:
*
*    This code has been written to conform to standard C++ and STL. It has been
*    compiled successfully using Visual C++ 7.0.
*/

#ifndef GUARD_report_h
#define GUARD_report_h

#include <string>
using namespace std;

namespace report
{
class ReportForm
{
public:
	struct ReportItem
	{
		string caption;
		string text;
	};

	string header, footer;
	vector<ReportItem> body;
	size_t captionSize, textSize;

public:
	ReportForm::ReportForm()
	{
		captionSize= 30;
		textSize = 35;
		body.clear();
	}
	size_t size();
	void show();
	void appendItem(string caption, string text);
	void appendItem(string caption);
	void appendItem();

private:
	void showHeader();
	void showBody();
	void showFooter();
	void showItem(ReportItem item);
	void showLine();
};
}

#endif

⌨️ 快捷键说明

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