📄 main.cpp
字号:
#include "Application.h"
#include "OpenCommand.h"
#include "PasteCommand.h"
#include "Document.h"
//将一个请求封装为一个对象,从而使你可以用不同的请求对客户进行参数化;
//对请求排队或记录请求日志,以及支持可撤消的操作
int main()
{
Application* myApp = new Application;
Command* cmd = new OpenCommand(myApp);
cmd->Execute();
Document* myDoc = new Document("Oops");
cmd = new PasteCommand(myDoc);
cmd->Execute();
//...
delete myApp;
delete myDoc;
delete cmd;
return 0;
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -