Skip to content

Commit 661f0df

Browse files
authored
Merge pull request #908 from tsuyoshicho/update/usr-20210429
Update usr_{02,04,12,41}.{txt,jax}
2 parents e6a7aec + fecff9a commit 661f0df

File tree

8 files changed

+56
-36
lines changed

8 files changed

+56
-36
lines changed

doc/usr_02.jax

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*usr_02.txt* For Vim バージョン 8.2. Last change: 2019 Nov 21
1+
*usr_02.txt* For Vim バージョン 8.2. Last change: 2021 Apr 24
22

33
VIM USER MANUAL - by Bram Moolenaar
44

@@ -42,7 +42,7 @@ Vim が起動して file.txt という名前のファイルの編集が開始さ
4242
|~ |
4343
|"file.txt" [New file] |
4444
+---------------------------------------+
45-
("#" はカーソルの位置です)
45+
('#' はカーソルの位置です)
4646

4747
チルダ (~) の行は、ファイルにその行がないことを示しています。ファイルの末尾よ
4848
り後ろを表示する場合にチルダが表示されます。画面の下の方に、編集中のファイル名
@@ -523,7 +523,7 @@ Vim にはオプションがたくさんあり、それを設定することで
523523
< は設定 'cpoptions' のフラグに対応します。<letter> は個別のフラグに置き換えて
524524
下さい。例: >
525525
:help cpo-;
526-
< さらに guioption のフラグであれば: >
526+
< さらに 'guioptions' のフラグであれば: >
527527
:help go-<letter>
528528
529529
4) ノーマルモードのコマンドにはプリフィックスはありません。"gt" コマンドのヘル

doc/usr_04.jax

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*usr_04.txt* For Vim バージョン 8.2. Last change: 2019 Nov 21
1+
*usr_04.txt* For Vim バージョン 8.2. Last change: 2021 Feb 22
22

33
VIM USER MANUAL - by Bram Moolenaar
44

doc/usr_12.jax

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*usr_12.txt* For Vim バージョン 8.2. Last change: 2017 Aug 11
1+
*usr_12.txt* For Vim バージョン 8.2. Last change: 2021 Apr 19
22

33
VIM USER MANUAL - by Bram Moolenaar
44

@@ -184,17 +184,17 @@ Makefile ではよく、ファイルのリストが使われます。例:
184184
することで、行を逆順に並べ替えたファイルを作ることができます。コマンドは次の通
185185
りです: >
186186
187-
:global/^/m 0
187+
:global/^/move 0
188188
189189
短縮して書くこともできます: >
190190
191191
:g/^/m 0
192192
193193
"^" という正規表現は行の先頭に (それが空行であっても) マッチします。|:move|
194-
マンドはマッチした行を 0 行目 (実際には存在しない仮想的な行) の下に移動します。
195-
つまり、マッチした行がファイルの先頭行になります|:global| コマンドは行番号が
196-
変更されても処理を継続できます。そして、マッチしたすべての行が、順番にファイル
197-
の先頭に移動していきます
194+
マンドはマッチした行を仮想的な 0 行目の下に移動します。つまり、マッチした行が
195+
ファイルの先頭行になります|:global| コマンドは行番号が変更されても処理を継続
196+
できます。そして、マッチしたすべての行が、順番にファイルの先頭に移動していきま
197+
198198

199199
ある一定の範囲だけ並べ替えることもできます。まず、並べ替えたい範囲の一行上に移
200200
動し、"mt" でマークします。そして、範囲の末尾に移動し、次のように入力します: >

doc/usr_41.jax

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*usr_41.txt* For Vim バージョン 8.2. Last change: 2021 Feb 01
1+
*usr_41.txt* For Vim バージョン 8.2. Last change: 2021 Apr 19
22

33
VIM USER MANUAL - by Bram Moolenaar
44

@@ -110,12 +110,20 @@ script の場合はちょっと違います。|usr_46.txt| を参照。
110110
4種類の数値
111111
------------
112112

113-
数値は10進数、16進数、8進数および2進数のいずれかで表記します。16進数は "0x" か
114-
"0X" で開始します。例えば "0x1f" は10進数の 31 です。8進数は "0" で開始します。
115-
例えば "017" は10進数の 15 です。2進数は "0b" か "0B" で開始します。例えば
116-
"0b101" は10進数の 5 です。注意: 10進数で書くときは先頭に "0" を付けないでく
117-
ださい。8進数として扱われてしまいます。
118-
":echo" コマンドは常に10進数で出力します。例: >
113+
数値は10進数、16進数、8進数および2進数のいずれかで表記します。
114+
115+
16進数は "0x" か "0X" で開始します。例えば "0x1f" は10進数の 31 です。
116+
117+
8進数は "0o" か "0O" あるいは "0" とつづく他の数値で開始します。例えば "0o17"
118+
は10進数の 15 です。Vim9 script では前置詞が "0" だけの利用はサポートされませ
119+
ん。
120+
121+
2進数は "0b" か "0B" で開始します。例えば "0b101" は10進数の 5 です。
122+
123+
10進数は数値そのままです。注意: 10進数で書くときは先頭に "0" を付けないでくだ
124+
さい。旧来のスクリプトでは8進数として扱われてしまいます!
125+
126+
":echo" コマンドは常に10進数で出力します。例: >
119127
120128
:echo 0x7f 0o36
121129
< 127 30 ~
@@ -586,7 +594,8 @@ substitute() の呼び出しの前後にいろいろな処理を入れたりす
586594
stridx() 文字列の中で部分文字列が見つかった最初の位置
587595
strridx() 文字列の中で部分文字列が見つかった最後の位置
588596
strlen() 文字列のバイト単位での長さ
589-
strchars() 文字列の文字単位での長さ
597+
strcharlen() 文字列の文字単位での長さ
598+
strchars() 文字列内の文字数
590599
strwidth() 表示された文字列のサイズ
591600
strdisplaywidth() 表示された文字列のサイズ、タブを扱う
592601
setcellwidths() 文字の幅の上書き設定
@@ -982,6 +991,7 @@ Vimサーバー: *server-functions*
982991
assert_true() 式がtrueかどうかテストする
983992
assert_exception() コマンドが例外を投げる事をテストする
984993
assert_beeps() コマンドがビープ音を鳴らすことをテストする
994+
assert_nobeep() コマンドがビープ音を鳴らさないことをテストする
985995
assert_fails() コマンドが失敗する事をテストする
986996
assert_report() テストの失敗をレポートする
987997
test_alloc_fail() メモリの確保を失敗させる

en/usr_02.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*usr_02.txt* For Vim version 8.2. Last change: 2019 Nov 21
1+
*usr_02.txt* For Vim version 8.2. Last change: 2021 Apr 24
22

33
VIM USER MANUAL - by Bram Moolenaar
44

@@ -43,7 +43,7 @@ like:
4343
|~ |
4444
|"file.txt" [New file] |
4545
+---------------------------------------+
46-
('#" is the cursor position.)
46+
('#' is the cursor position.)
4747

4848
The tilde (~) lines indicate lines not in the file. In other words, when Vim
4949
runs out of file to display, it displays tilde lines. At the bottom of the
@@ -532,7 +532,7 @@ Summary: *help-summary* >
532532
< for the corresponding flag of the 'cpoptions' settings, substitute <letter>
533533
by a specific flag, e.g.: >
534534
:help cpo-;
535-
< And for the guioption flags: >
535+
< And for the 'guioptions' flags: >
536536
:help go-<letter>
537537
538538
4) Normal mode commands do not have a prefix. To go to the help page for the

en/usr_04.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*usr_04.txt* For Vim version 8.2. Last change: 2019 Nov 21
1+
*usr_04.txt* For Vim version 8.2. Last change: 2021 Feb 22
22

33
VIM USER MANUAL - by Bram Moolenaar
44

@@ -464,9 +464,9 @@ of characters to replace. It will not continue on the next line.
464464

465465
You can switch between Insert mode and Replace mode with the <Insert> key.
466466

467-
When you use <BS> (backspace) to make correction, you will notice that the
468-
old text is put back. Thus it works like an undo command for the last typed
469-
character.
467+
When you use <BS> (backspace) to make a correction, you will notice that the
468+
old text is put back. Thus it works like an undo command for the previously
469+
typed character.
470470

471471
==============================================================================
472472
*04.10* Conclusion

en/usr_12.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*usr_12.txt* For Vim version 8.2. Last change: 2017 Aug 11
1+
*usr_12.txt* For Vim version 8.2. Last change: 2021 Apr 19
22

33
VIM USER MANUAL - by Bram Moolenaar
44

@@ -180,14 +180,14 @@ after it. That way you don't have this problem again.
180180
The |:global| command can be combined with the |:move| command to move all the
181181
lines before the first line, resulting in a reversed file. The command is: >
182182
183-
:global/^/m 0
183+
:global/^/move 0
184184
185185
Abbreviated: >
186186
187187
:g/^/m 0
188188
189189
The "^" regular expression matches the beginning of the line (even if the line
190-
is blank). The |:move| command moves the matching line to after the mythical
190+
is blank). The |:move| command moves the matching line to after the imaginary
191191
zeroth line, so the current matching line becomes the first line of the file.
192192
As the |:global| command is not confused by the changing line numbering,
193193
|:global| proceeds to match all remaining lines of the file and puts each as

en/usr_41.txt

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*usr_41.txt* For Vim version 8.2. Last change: 2021 Feb 01
1+
*usr_41.txt* For Vim version 8.2. Last change: 2021 Apr 19
22

33
VIM USER MANUAL - by Bram Moolenaar
44

@@ -115,12 +115,20 @@ if you are impatient.
115115

116116
FOUR KINDS OF NUMBERS
117117

118-
Numbers can be decimal, hexadecimal, octal or binary. A hexadecimal number
119-
starts with "0x" or "0X". For example "0x1f" is decimal 31. An octal number
120-
starts with a zero. "017" is decimal 15. A binary number starts with "0b" or
121-
"0B". For example "0b101" is decimal 5. Careful: don't put a zero before a
122-
decimal number, it will be interpreted as an octal number!
123-
The ":echo" command always prints decimal numbers. Example: >
118+
Numbers can be decimal, hexadecimal, octal or binary.
119+
120+
A hexadecimal number starts with "0x" or "0X". For example "0x1f" is decimal
121+
31.
122+
123+
An octal number starts with "0o", "0O" or a zero and another digit. "0o17" is
124+
decimal 15. Using just a zero prefix is not supported in Vim9 script.
125+
126+
A binary number starts with "0b" or "0B". For example "0b101" is decimal 5.
127+
128+
A decimal number is just digits. Careful: don't put a zero before a decimal
129+
number, it will be interpreted as an octal number in legacy script!
130+
131+
The ":echo" command always prints decimal numbers. Example: >
124132
125133
:echo 0x7f 0o36
126134
< 127 30 ~
@@ -611,7 +619,8 @@ String manipulation: *string-functions*
611619
stridx() first index of a short string in a long string
612620
strridx() last index of a short string in a long string
613621
strlen() length of a string in bytes
614-
strchars() length of a string in characters
622+
strcharlen() length of a string in characters
623+
strchars() number of characters in a string
615624
strwidth() size of string when displayed
616625
strdisplaywidth() size of string when displayed, deals with tabs
617626
setcellwidths() set character cell width overrides
@@ -1002,6 +1011,7 @@ Testing: *test-functions*
10021011
assert_true() assert that an expression is true
10031012
assert_exception() assert that a command throws an exception
10041013
assert_beeps() assert that a command beeps
1014+
assert_nobeep() assert that a command does not cause a beep
10051015
assert_fails() assert that a command fails
10061016
assert_report() report a test failure
10071017
test_alloc_fail() make memory allocation fail

0 commit comments

Comments
 (0)