Skip to content

Commit 00e4a28

Browse files
authored
Merge pull request #1891 from h-east/update-helphelp
Update helphelp.{txt,jax}
2 parents f2d87f0 + 472699e commit 00e4a28

File tree

2 files changed

+51
-24
lines changed

2 files changed

+51
-24
lines changed

doc/helphelp.jax

Lines changed: 23 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*helphelp.txt* For Vim バージョン 9.1. Last change: 2024 Dec 15
1+
*helphelp.txt* For Vim バージョン 9.1. Last change: 2024 Dec 26
22

33

44
VIMリファレンスマニュアル by Bram Moolenaar
@@ -426,17 +426,30 @@ Ex コマンドのブロックを例示するときは、大なり記号 (>) を
426426
末に書き、小なり記号 (<) をその後ろのブロックの前の最初の非空白文字として書き
427427
ます。テキストが 1 列目から始まっている行があると、Ex コマンドのブロックはその
428428
直前で暗黙的に終了となります。例: >
429-
function Example_Func()
430-
echo "Example"
431-
endfunction
429+
function Example_Func()
430+
echo "Example"
431+
endfunction
432432
<
433-
コード例に Vim 構文ハイライトサポートを追加することができます。これは、大なり
434-
記号 (>) の後に "vim" を追加することで可能です (">vim")。
435-
例: >vim
436-
function Example_Func()
437-
echo "Example"
438-
endfunction
433+
コードブロックの構文ハイライトを有効にするには、大なり記号 (>) の後に言語名の
434+
注釈 (例: "vim") を配置します。例: >vim
435+
function Example_Func()
436+
echo "Example"
437+
endfunction
439438
<
439+
*g:help_example_languages*
440+
デフォルトでは、ヘルプファイルは Vim script のハイライトのみをサポートします。
441+
他の言語の構文ハイライトが必要な場合は、|vimrc| に以下を追加してください: >
442+
:let g:help_example_languages = { "vim": "vim", "sh": "bash" }
443+
キーは注釈マーカー名を表し、値は 'syntax' 名です。
444+
445+
Note: "g:help_example_languages" に "vim" を含めない場合、"vim" の構文ハイライ
446+
トは有効になりません。"g:help_example_languages" を空の値に設定すると、埋め込
447+
み言語の構文ハイライトは無効になります。
448+
449+
さらに note: 含まれている 'syntax' スクリプトがそのような趣旨を考慮していない
450+
場合、ヘルプファイルに任意の構文言語を含めることは必ずしも完璧に機能するとは限
451+
りません。
452+
*help-notation*
440453
Vim ヘルプファイルでは以下のものがそれぞれハイライトされます:
441454
- 特殊キーの名前。<PageDown> のような <> 表記で書かれたものと、CTRL-X のよう
442455
に書かれた制御文字。

en/helphelp.txt

Lines changed: 28 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*helphelp.txt* For Vim version 9.1. Last change: 2024 Dec 15
1+
*helphelp.txt* For Vim version 9.1. Last change: 2024 Dec 26
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -433,17 +433,31 @@ To quote a block of ex-commands verbatim, place a greater than (>) character
433433
at the end of the line before the block and a less than (<) character as the
434434
first non-blank on a line following the block. Any line starting in column 1
435435
also implicitly stops the block of ex-commands before it. E.g. >
436-
function Example_Func()
437-
echo "Example"
438-
endfunction
436+
function Example_Func()
437+
echo "Example"
438+
endfunction
439439
<
440-
It's possible to add Vim syntax highlighting support to code examples. This
441-
can be done by adding "vim" after the greater than (>) character (">vim").
442-
E.g: >vim
443-
function Example_Func()
444-
echo "Example"
445-
endfunction
440+
To enable syntax highlighting for a block of code, place a language name
441+
annotation (e.g. "vim") after a greater than (>) character. E.g. >vim
442+
function Example_Func()
443+
echo "Example"
444+
endfunction
446445
<
446+
*g:help_example_languages*
447+
By default, help files only support Vim script highlighting. If you need
448+
syntax highlighting for other languages, add to your |vimrc|: >
449+
:let g:help_example_languages = { "vim": "vim", "sh": "bash" }
450+
The key represents the annotation marker name, and the value is the 'syntax'
451+
name.
452+
453+
Note: If you do not include "vim" in "g:help_example_languages", its syntax
454+
highlighting will not be enabled. If you set "g:help_example_languages" to an
455+
empty value, syntax highlighting for embedded languages will be disabled.
456+
457+
Further note: Including arbitrary syntax languages into help files may not
458+
always work perfectly, if the included 'syntax' script does not account for
459+
such an import.
460+
*help-notation*
447461
The following are highlighted differently in a Vim help file:
448462
- a special key name expressed either in <> notation as in <PageDown>, or
449463
as a Ctrl character as in CTRL-X
@@ -460,15 +474,15 @@ You can find the details in $VIMRUNTIME/syntax/help.vim
460474
GENDER NEUTRAL LANGUAGE
461475

462476
*gender-neutral* *inclusion*
463-
Vim is for everybody, no matter race, gender or anything. For new or updated
464-
help text, gender neutral language is recommended. Some of the help text is
465-
many years old and there is no need to change it. We do not make any
477+
Vim is for everybody, no matter race, gender or anything. For new or updated
478+
help text, gender neutral language is recommended. Some of the help text is
479+
many years old and there is no need to change it. We do not make any
466480
assumptions about the gender of the user, no matter how the text is phrased.
467481
The goal is that the reader understands how Vim works, the exact wording is
468482
secondary.
469483

470484
Many online technical style guides include sections about gender neutral
471-
language. Here are a few: >
485+
language. Here are a few: >
472486
473487
https://developers.google.com/style/pronouns
474488
https://techwhirl.com/gender-neutral-technical-writing/

0 commit comments

Comments
 (0)