Skip to content

Update autocmd.{txt,jax} #2028

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 18, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 15 additions & 6 deletions doc/autocmd.jax
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
*autocmd.txt* For Vim バージョン 9.1. Last change: 2025 Mar 12
*autocmd.txt* For Vim バージョン 9.1. Last change: 2025 Apr 04


VIMリファレンスマニュアル by Bram Moolenaar
Expand Down Expand Up @@ -596,9 +596,10 @@ BufWriteCmd バッファ全体をファイルに書き込む前。ファイル
の書き込みの役目を負い、成功したときはオプショ
ン 'modified' をオフにする。バッファの内容を変
更すべきではない。
'modified' をオフにすると、以前の undo 状態が
'modified' (変更あり) になるように undo 情報が
調整される (|:write| と同様)。
コマンドが 'modified' をリセットすると、
|:write| と同様に、古い undo 状態を'modified'
としてマークするように undo 情報が調整される。
行の範囲には |'[| と |']| マークを使用する。
|Cmd-event|
*BufWritePost*
BufWritePost バッファ全体をファイルに書き込んだ後 (イベント
Expand Down Expand Up @@ -882,13 +883,15 @@ FileType オプション 'filetype' が設定されたとき。
*FileWriteCmd*
FileWriteCmd バッファ全体を書き込まない場合の、ファイルに書
き込む前。ファイルへの書き込みの役目を負う。バッ
ファを変更すべきではない。 |Cmd-event|
ファを変更すべきではない。行の範囲には |'[| と
|']| マークを使用する。 |Cmd-event|
*FileWritePost*
FileWritePost バッファ全体を書き込まない場合の、ファイルに書
き込んだ後。
*FileWritePre*
FileWritePre バッファ全体を書き込まない場合の、ファイルに書
き込む前。
き込む前。行の範囲には |'[| と |']| マークを使
用する。
*FilterReadPost*
FilterReadPost フィルタコマンドからファイルを読み込んだ後。
Vimは FilterReadPre と同様に、現在のバッファの
Expand Down Expand Up @@ -1457,6 +1460,12 @@ WinScrolled カレントのタブページのウィンドウでテキストが
さが変更された後。|win-scrolled-resized| を参
照。

Note: これは、Vim がメインループに戻ったときに
通常のコマンドを処理した後でトリガーされるた
め、`:noautocmd` ではスキップできない。これを
無効にしたい場合は、代わりに 'eventignore' オ
プションを設定することを検討すること。

パターンは、スクロールかリサイズされた最初の
ウィンドウの |window-ID| に対してマッチングさ
れる。<amatch> と <afile> 両方が |window-ID|
Expand Down
16 changes: 12 additions & 4 deletions en/autocmd.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
*autocmd.txt* For Vim version 9.1. Last change: 2025 Mar 12
*autocmd.txt* For Vim version 9.1. Last change: 2025 Apr 04


VIM REFERENCE MANUAL by Bram Moolenaar
Expand Down Expand Up @@ -593,7 +593,8 @@ BufWriteCmd Before writing the whole buffer to a file.
The buffer contents should not be changed.
When the command resets 'modified' the undo
information is adjusted to mark older undo
states as 'modified', like |:write| does.
states as 'modified', like |:write| does. Use
the |'[| and |']| marks for the range of lines.
|Cmd-event|
*BufWritePost*
BufWritePost After writing the whole buffer to a file
Expand Down Expand Up @@ -886,14 +887,14 @@ FileType When the 'filetype' option has been set. The
FileWriteCmd Before writing to a file, when not writing the
whole buffer. Should do the writing to the
file. Should not change the buffer. Use the
'[ and '] marks for the range of lines.
|'[| and |']| marks for the range of lines.
|Cmd-event|
*FileWritePost*
FileWritePost After writing to a file, when not writing the
whole buffer.
*FileWritePre*
FileWritePre Before writing to a file, when not writing the
whole buffer. Use the '[ and '] marks for the
whole buffer. Use the |'[| and |']| marks for the
range of lines.
*FilterReadPost*
FilterReadPost After reading a file from a filter command.
Expand Down Expand Up @@ -1480,6 +1481,13 @@ WinScrolled After any window in the current tab page
or changed width or height. See
|win-scrolled-resized|.

Note: This can not be skipped with
`:noautocmd`, because it triggers after
processing normal commands when Vim is back in
the main loop. If you want to disable this,
consider setting the 'eventignore' option
instead.

The pattern is matched against the |window-ID|
of the first window that scrolled or resized.
Both <amatch> and <afile> are set to the
Expand Down