Skip to content

Commit eec8a28

Browse files
authored
Merge pull request #2608 from h-east/update-channel
Update channel.{txt,jax}
2 parents fdda2f7 + 9dcf23b commit eec8a28

2 files changed

Lines changed: 15 additions & 9 deletions

File tree

doc/channel.jax

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*channel.txt* For Vim バージョン 9.2. Last change: 2026 Apr 15
1+
*channel.txt* For Vim バージョン 9.2. Last change: 2026 Apr 29
22

33

44
VIM リファレンスマニュアル by Bram Moolenaar
@@ -169,6 +169,7 @@ Vimを起動し、リスニングチャネルを作成する: >
169169
"js" - JS (JavaScript) エンコーディングを使用し、JSON よりも効率的。
170170
"nl" - NL 文字で終わるメッセージを使う
171171
"raw" - raw メッセージを使う
172+
"blob" - raw メッセージを使い、コールバックデータを |Blob| として渡す。
172173
"lsp" - language server protocol エンコーディングを使う
173174
"dap" - debug adapter protocol エンコーディングを使う
174175
*channel-callback* *E921*
@@ -183,18 +184,20 @@ Vimを起動し、リスニングチャネルを作成する: >
183184
"mode" が "json"、"js"、"lsp"、または "dap" のいずれかの場合、
184185
"msg" 引数は受信したメッセージの本文であり、Vim の型に変換され
185186
る。
186-
"mode" が "nl" の時には、"msg" 引数は NL を除く 1 つのメッセー
187-
ジである。
188-
"mode" が "raw" の時には、"msg" 引数はメッセージ全体を格納し
189-
た文字列である。
187+
"mode" が "nl" の場合、"msg" 引数は NL を除く 1 つのメッセージ
188+
である。
189+
"mode" が "raw" の場合、"msg" 引数はメッセージ全体を格納した文
190+
字列である。
191+
"mode" が "blob" の場合、"msg" 引数はメッセージ全体を格納した
192+
|Blob| である。
190193

191194
すべてのコールバック: |function()| を使用して、引数および/また
192-
は辞書にバインドします。または、"dict.function" という形式を使
193-
用して辞書をバインドします
195+
は辞書にバインドする。または、"dict.function" という形式を使用
196+
して辞書をバインドする
194197

195198
コールバックは、通常、Vim がユーザーが文字を入力するのを待って
196199
いるとき、「安全な」瞬間にのみ呼び出されます。Vim はマルチス
197-
レッドを使用しません
200+
レッドを使用しない
198201

199202
*close_cb*
200203
"close_cb" |ch_close()| を呼び出す以外に、チャネルが閉じられたときに呼び

en/channel.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*channel.txt* For Vim version 9.2. Last change: 2026 Apr 15
1+
*channel.txt* For Vim version 9.2. Last change: 2026 Apr 29
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -170,6 +170,7 @@ unreachable on the network.
170170
"js" - Use JS (JavaScript) encoding, more efficient than JSON.
171171
"nl" - Use messages that end in a NL character
172172
"raw" - Use raw messages
173+
"blob" - Use raw messages and pass callback data as a |Blob|
173174
"lsp" - Use language server protocol encoding
174175
"dap" - Use debug adapter protocol encoding
175176
*channel-callback* *E921*
@@ -189,6 +190,8 @@ unreachable on the network.
189190
excluding the NL.
190191
When "mode" is "raw" the "msg" argument is the whole message
191192
as a string.
193+
When "mode" is "blob" the "msg" argument is the whole message
194+
as a |Blob|.
192195

193196
For all callbacks: Use |function()| to bind it to arguments
194197
and/or a Dictionary. Or use the form "dict.function" to bind

0 commit comments

Comments
 (0)