# WinEdt建立快速巨集

## 介紹

**主要重點**

* 為了讓BibTex可以編譯需要先執行一次XeLaTex
* 要執行兩次 XeLaTex目錄才會正確

所以執行步驟為

> &#x20;XeLaTex -> BibTex ->  XeLaTex->  XeLaTex

下面介建立快速巨集的方法

## 設定步驟

1. 主頁面上打開Options->Options Interface
2. 打開按鈕設定檔Menu and Toolbar -> Main Menu
3. 搜&#x5C0B;**`MENU="TeX_Menu"`**
4. 新增以下按鈕，貼在
5.

```
<pre data-title="MainMenu.ini"><code>MENU="TeX_Menu"
```

```
  CAPTION="Te&#x26;X"
  CONFIG_FILTER="Default;MiKTeX;TeX Live"
  // ===========以下為新增內容===========
  ITEM="ButtonByAustin"
    CAPTION="MacroByAustin"
    IMAGE="MacroRun"
    SAVE_INPUT=1
    MACRO="Exe('%b\Exec\TeX\XeLaTeX.edt');Exe('%b\Exec\TeX\BibTeX.edt');Exe('%b\Exec\TeX\XeLaTeX.edt');Exe('%b\Exec\TeX\XeLaTeX.edt');Exe('%b\Exec\PDF\PDF Preview.edt');"
    REQ_FILTER=:"%!M=TeX"|"%!M=TeX:STY"|"%!M=TeX:AUX"    
</code></pre>
```

6\. 新增好後，先儲存(Ctrl + S)，在使用(Ctrl + Shift + F9)更新介面
7\. 以後可以使用`MacroByAustin`按鈕進行所有編譯動作&#x20;

{% hint style="info" %}
記得要開啟tex檔案才能按鈕才能使用
{% endhint %}

![](https://1278227785-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LC9uZM7RrYvbBnp3tOx%2F-LD5f1eTIWd20ryPvi2H%2F-LD5gPy4zy-HRTmRBy0a%2Fimage.png?alt=media\&token=1bdb2dae-65d2-43a6-a9af-b1b430708158)

設定好後以後不用再分四次按，只要按一次就可以了


---

# 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://austinsuyoyo.gitbook.io/latex-tutorial/winedt-jian-li-kuai-su-ju-ji.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.
