# action\_new\_

```cpp
QAction		*action_new_;
```

所以说action\_new\_是一个QAction类型的指针

```cpp
action_new_ = new QAction(QIcon(":/MainWindow/Resources/images/new.jpg"), tr("&New"), this);
action_new_->setShortcut(QKeySequence::New);
action_new_->setStatusTip(tr("Create a new file"));
```

这里只是新建了一个QAction的按钮，并没有涉及到点击这个按钮后会发生什么

点击这个按钮后会发生什么需要我自己用connect函数来补充

接下来让我们看看其他优秀作品中，点击new会发生什么吧

笑死了，两份优秀作品都没有处理new，那我也不处理new了


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://tysun.gitbook.io/c++/action_new_.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
