Skip to content
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
39 changes: 27 additions & 12 deletions doc/builtin.jax
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
*builtin.txt* For Vim バージョン 9.1. Last change: 2024 Sep 23
*builtin.txt* For Vim バージョン 9.1. Last change: 2024 Oct 12


VIMリファレンスマニュアル by Bram Moolenaar
Expand Down Expand Up @@ -248,6 +248,8 @@ getcharmod() 数値 修飾キーの状態を表す数値を取得
getcharpos({expr}) リスト カーソル、マーク、その他のカーソル位置
getcharsearch() 辞書 最後の文字検索を取得
getcharstr([{expr}]) 文字列 ユーザーから1文字を取得する
getcmdcomplpat() 文字列 現在のコマンドライン補完の補完パターン
を返す
getcmdcompltype() 文字列 現在のコマンドライン補完のタイプを返す
getcmdline() 文字列 現在のコマンドライン入力を取得
getcmdpos() 数値 コマンドラインのカーソル位置を取得
Expand Down Expand Up @@ -2642,7 +2644,7 @@ exists({expr}) *exists()*
ば0となる。

Note: コンパイルされる |:def| 関数は実行時に評価が完了する。
`exists_compiled()` を使うことでコンパイル時に式が評価される。
`exists_compiled()` を使うことでコンパイル時に式が評価される。

ある機能がサポートされているか判定するには|has()|を使う。
ファイルが存在するかを判定するには|filereadable()|を使う。
Expand Down Expand Up @@ -3961,15 +3963,27 @@ getcharstr([{expr}]) *getcharstr()*

戻り値の型: |String|

getcmdcomplpat() *getcmdcomplpat()*
現在のコマンドラインの補完パターンを返す。
コマンドラインが編集されている場合にのみ機能するため、
|c_CTRL-\_e| または |c_CTRL-R_=| を使用する必要がある。
|getcmdtype()|, |setcmdpos()|, |getcmdline()|,
|getcmdprompt()|, |getcmdcompltype()| および |setcmdline()| も
参照。
補完が定義されていない場合は空の文字列を返す。

戻り値の型: |String|


getcmdcompltype() *getcmdcompltype()*
現在のコマンドライン補完のタイプを返す。
コマンドラインが編集時にのみ動作するので、|c_CTRL-e| または
|c_CTRL-R_=| を使用する必要がある。
返す文字列については |:command-completion| を参照のこと。
返す文字列については |:command-completion| を参照のこと。
|getcmdtype()|, |setcmdpos()|, |getcmdline()|,
|getcmdprompt()|, |setcmdline()| も参照。
補完が定義されていない場合は空文字列を返す。
|getcmdprompt()|, |getcmdcomplpat()| および |setcmdline()| も
参照。
補完が定義されていない場合は空文字列を返す。

戻り値の型: |String|

Expand Down Expand Up @@ -4013,7 +4027,7 @@ getcmdprompt() *getcmdprompt()*
getcmdscreenpos() *getcmdscreenpos()*
コマンドラインのカーソルのスクリーン位置をバイト単位で返す。最
初の桁は 1 である。
|getcmdpos()| の代わりにプロンプトの位置を加える。
|getcmdpos()| の代わりにプロンプトの位置を加える。
コマンドラインの編集時のみ動作するため、|c_CTRL-e| または
|c_CTRL-R_=| または式マッピングを使用する必要がある。それ以外
は 0 を返す。
Expand Down Expand Up @@ -4064,7 +4078,7 @@ getcompletion({pat}, {type} [, {filtered}]) *getcompletion()*
cscope |:cscope|のサブオプション
custom,{func} {func} で定義されたカスタム補完
customlist,{func} {func} で定義されたカスタム補完
diff_buffer |:diffget| と |:diffput| の補完
diff_buffer |:diffget| と |:diffput| の補完
dir ディレクトリ名
dir_in_path |'cdpath'| 内のディレクトリ名
environment 環境変数名
Expand All @@ -4088,6 +4102,7 @@ getcompletion({pat}, {type} [, {filtered}]) *getcompletion()*
runtime |:runtime| 補完
scriptnames 読み込まれているスクリプト名 |:scriptnames|
shellcmd シェルコマンド
shellcmdline ファイル名を引数とするシェルコマンドライン
sign |:sign|サブオプション
syntax 構文ファイル名 |'syntax'|
syntime |:syntime|サブオプション
Expand Down Expand Up @@ -7095,7 +7110,7 @@ matchlist({expr}, {pat} [, {start} [, {count}]]) *matchlist()*
< 結果は['acd', 'a', '', 'c', 'd', '', '', '', '', '']となる。
マッチしなかったときは空リストを返す。

リストを渡すことはできるが、あまり役に立たない。
リストを渡すことはできるが、あまり役に立たない。

|method| としても使用できる: >
GetText()->matchlist('word')
Expand Down Expand Up @@ -8366,10 +8381,10 @@ remote_expr({server}, {string} [, {idvar} [, {timeout}]])
{string} を {server} に送信する。引数 {server} は文字列。
|{server}| も参照。

{string} は式と見なされ、評価した結果が返ってくる。戻り値は文
字列かリスト |List| でなければならない。リストの場合は要素を連
結して文字列に変換される。要素間の区切りは改行文字となる
(join(expr, "\n")と同様)
{string} は式と見なされ、評価した結果が返ってくる。結果は文字
列または |List| でなければばらず、他の型は文字列に変換される。
|List| は、join(expr, "\n") のように、項目を改行で結合し (末尾
には付かない)、文字列に変換される

空でない {idvar} が渡された場合は変数名と見なされ、後で
|remote_read()| で使われる {serverid} がその変数に保存される。
Expand Down
27 changes: 20 additions & 7 deletions en/builtin.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
*builtin.txt* For Vim version 9.1. Last change: 2024 Sep 23
*builtin.txt* For Vim version 9.1. Last change: 2024 Oct 12


VIM REFERENCE MANUAL by Bram Moolenaar
Expand Down Expand Up @@ -230,6 +230,8 @@ getcharmod() Number modifiers for the last typed character
getcharpos({expr}) List position of cursor, mark, etc.
getcharsearch() Dict last character search
getcharstr([{expr}]) String get one character from the user
getcmdcomplpat() String return the completion pattern of the
current command-line completion
getcmdcompltype() String return the type of the current
command-line completion
getcmdline() String return the current command-line input
Expand Down Expand Up @@ -3973,14 +3975,24 @@ getcharstr([{expr}]) *getcharstr()*

Return type: |String|

getcmdcomplpat() *getcmdcomplpat()*
Return completion pattern of the current command-line.
Only works when the command line is being edited, thus
requires use of |c_CTRL-\_e| or |c_CTRL-R_=|.
Also see |getcmdtype()|, |setcmdpos()|, |getcmdline()|,
|getcmdprompt()|, |getcmdcompltype()| and |setcmdline()|.
Returns an empty string when completion is not defined.

Return type: |String|


getcmdcompltype() *getcmdcompltype()*
Return the type of the current command-line completion.
Only works when the command line is being edited, thus
requires use of |c_CTRL-\_e| or |c_CTRL-R_=|.
See |:command-completion| for the return string.
Also see |getcmdtype()|, |setcmdpos()|, |getcmdline()|,
|getcmdprompt()| and |setcmdline()|.
|getcmdprompt()|, |getcmdcomplpat()| and |setcmdline()|.
Returns an empty string when completion is not defined.

Return type: |String|
Expand Down Expand Up @@ -4079,7 +4091,7 @@ getcompletion({pat}, {type} [, {filtered}]) *getcompletion()*
cscope |:cscope| suboptions
custom,{func} custom completion, defined via {func}
customlist,{func} custom completion, defined via {func}
diff_buffer |:diffget| and |:diffput| completion
diff_buffer |:diffget| and |:diffput| completion
dir directory names
dir_in_path directory names in |'cdpath'|
environment environment variable names
Expand All @@ -4103,6 +4115,7 @@ getcompletion({pat}, {type} [, {filtered}]) *getcompletion()*
runtime |:runtime| completion
scriptnames sourced script names |:scriptnames|
shellcmd Shell command
shellcmdline Shell command line with filename arguments
sign |:sign| suboptions
syntax syntax file names |'syntax'|
syntime |:syntime| suboptions
Expand Down Expand Up @@ -8516,10 +8529,10 @@ remote_expr({server}, {string} [, {idvar} [, {timeout}]])
string, also see |{server}|.

The string is sent as an expression and the result is returned
after evaluation. The result must be a String or a |List|. A
|List| is turned into a String by joining the items with a
line break in between (not at the end), like with join(expr,
"\n").
after evaluation. The result must be a String or a |List|
other types will be converted to String. A |List| is turned
into a String by joining the items with a line break in
between (not at the end), like with join(expr, "\n").

If {idvar} is present and not empty, it is taken as the name
of a variable and a {serverid} for later use with
Expand Down