重新安排目前行的換行
gqq
範例
一般模式 0 / 2等待指定範圍 1 / 2一般模式 2 / 2one two three four five six seven eight nine ten游標位於第 1 行,第 1 欄one two three four five six seven eight nine ten游標位於第 1 行,第 1 欄one two three four five
six seven eight nine ten游標位於第 2 行,第 1 欄用格式運算子重新排列目前行的文字。
接著按 q,指定要重新編排的範圍。
指令已執行
操作前後
one two three four five six seven eight nine ten游標位於第 1 行,第 1 欄one two three four five
six seven eight nine ten游標位於第 2 行,第 1 欄從一般模式開始。游標在第 1 行第 1 欄,行和欄都從 1 起算。設定 textwidth=24 與 formatoptions=tcq。q 會重複行格式化運算子。按 gqq。
詳細說明與 Vim 文件
範例已在 Vim 重播驗證
用格式運算子重新排列目前行的文字。
第二個 q 指定整行。本例設定 textwidth=24 和 formatoptions=tcq,過長的行會依規則折行。