diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2022-09-29 13:46:44 +0200 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2022-10-04 16:49:17 +0200 |
commit | 088abbeb6e6aecfc34b42db9b8d1396f493a2466 (patch) | |
tree | 39b0ddd7de032afad6088330191f0345dae9a2fa /runtime | |
parent | 28fbdd338586e066aa3e540333513b04c54361bc (diff) | |
download | rneovim-088abbeb6e6aecfc34b42db9b8d1396f493a2466.tar.gz rneovim-088abbeb6e6aecfc34b42db9b8d1396f493a2466.tar.bz2 rneovim-088abbeb6e6aecfc34b42db9b8d1396f493a2466.zip |
feat(docs): nested lists in HTML, update :help parser
- Docs HTML: improvements in https://github.com/neovim/tree-sitter-vimdoc
allow us to many hacks in `gen_help_html.lua`.
- Docs HTML: support nested lists.
- Docs HTML: avoid extra newlines (too much whitespace) in old
(preformatted) layout.
- Docs HTML: disable golden-grid for narrow viewport.
- Workaround for https://github.com/neovim/neovim/issues/20404
closes https://github.com/neovim/neovim/issues/20404
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/doc/api.txt | 12 | ||||
-rw-r--r-- | runtime/doc/builtin.txt | 2 | ||||
-rw-r--r-- | runtime/doc/index.txt | 11 | ||||
-rw-r--r-- | runtime/doc/luaref.txt | 2 | ||||
-rw-r--r-- | runtime/doc/pi_netrw.txt | 2 | ||||
-rw-r--r-- | runtime/doc/repeat.txt | 4 | ||||
-rw-r--r-- | runtime/doc/starting.txt | 2 |
7 files changed, 23 insertions, 12 deletions
diff --git a/runtime/doc/api.txt b/runtime/doc/api.txt index d53ca01df0..6f7f0bf416 100644 --- a/runtime/doc/api.txt +++ b/runtime/doc/api.txt @@ -434,7 +434,7 @@ its config is non-empty: > if vim.api.nvim_win_get_config(window_id).relative ~= '' then -- window with this window_id is floating end -> +< Buffer text can be highlighted by typical mechanisms (syntax highlighting, |api-highlights|). The |hl-NormalFloat| group highlights normal text; @@ -456,7 +456,7 @@ Example: create a float with scratch buffer: > let win = nvim_open_win(buf, 0, opts) " optional: change highlight, otherwise Pmenu is used call nvim_win_set_option(win, 'winhl', 'Normal:MyHighlight') -> +< ============================================================================== Extended marks *api-extended-marks* *extmarks* @@ -500,8 +500,8 @@ Let's set an extmark at the first row (row=0) and third column (column=2). 01 2345678 0 ex|ample.. -< ^ extmark position -> + ^ extmark position + let g:mark_ns = nvim_create_namespace('myplugin') let g:mark_id = nvim_buf_set_extmark(0, g:mark_ns, 0, 2, {}) < @@ -520,8 +520,8 @@ use |nvim_buf_del_extmark()|. Deleting "x" in our example: > 0 12345678 0 e|ample.. -< ^ extmark position -> + ^ extmark position + echo nvim_buf_get_extmark_by_id(0, g:mark_ns, g:mark_id, {}) => [0, 1] < diff --git a/runtime/doc/builtin.txt b/runtime/doc/builtin.txt index 2f44a41699..9de8db1f43 100644 --- a/runtime/doc/builtin.txt +++ b/runtime/doc/builtin.txt @@ -7716,7 +7716,7 @@ sqrt({expr}) *sqrt()* :echo sqrt(100) < 10.0 > :echo sqrt(-4.01) -< str2float('nan') +< str2float("nan") NaN may be different, it depends on system libraries. Can also be used as a |method|: > diff --git a/runtime/doc/index.txt b/runtime/doc/index.txt index f9ef99f819..8dd3d708a3 100644 --- a/runtime/doc/index.txt +++ b/runtime/doc/index.txt @@ -21,6 +21,7 @@ For a list of Vim variables see |vim-variable|. tag char action in Insert mode ~ ----------------------------------------------------------------------- + |i_CTRL-@| CTRL-@ insert previously inserted text and stop insert |i_CTRL-A| CTRL-A insert previously inserted text @@ -184,6 +185,7 @@ note: 1 = cursor movement command; 2 = can be undone/redone tag char note action in Normal mode ~ ------------------------------------------------------------------------------ + CTRL-@ not used |CTRL-A| CTRL-A 2 add N to number at/after cursor |CTRL-B| CTRL-B 1 scroll N screens Backwards @@ -469,6 +471,7 @@ These can be used after an operator or in Visual mode to select an object. tag command action in op-pending and Visual mode ~ ------------------------------------------------------------------------------ + |v_aquote| a" double quoted string |v_a'| a' single quoted string |v_a(| a( same as ab @@ -511,6 +514,7 @@ tag command action in op-pending and Visual mode ~ tag command action in Normal mode ~ ------------------------------------------------------------------------------ + |CTRL-W_CTRL-B| CTRL-W CTRL-B same as "CTRL-W b" |CTRL-W_CTRL-C| CTRL-W CTRL-C same as "CTRL-W c" |CTRL-W_CTRL-D| CTRL-W CTRL-D same as "CTRL-W d" @@ -609,6 +613,7 @@ tag command action in Normal mode ~ tag char note action in Normal mode ~ ------------------------------------------------------------------------------ + |[_CTRL-D| [ CTRL-D jump to first #define found in current and included files matching the word under the cursor, start searching at beginning of @@ -699,6 +704,7 @@ tag char note action in Normal mode ~ tag char note action in Normal mode ~ ------------------------------------------------------------------------------ + g_CTRL-A g CTRL-A dump a memory profile |g_CTRL-G| g CTRL-G show information about current cursor position @@ -802,6 +808,7 @@ g_CTRL-A g CTRL-A dump a memory profile tag char note action in Normal mode ~ ------------------------------------------------------------------------------ + |z<CR>| z<CR> redraw, cursor line to top of window, cursor on first non-blank |zN<CR>| z{height}<CR> redraw, make window {height} lines high @@ -876,6 +883,7 @@ These can be used after an operator, but before a {motion} has been entered. tag char action in Operator-pending mode ~ ----------------------------------------------------------------------- + |o_v| v force operator to work charwise |o_V| V force operator to work linewise |o_CTRL-V| CTRL-V force operator to work blockwise @@ -888,6 +896,7 @@ here are those that are different. tag command note action in Visual mode ~ ------------------------------------------------------------------------------ + |v_CTRL-\_CTRL-N| CTRL-\ CTRL-N stop Visual mode |v_CTRL-\_CTRL-G| CTRL-\ CTRL-G go to Normal mode |v_CTRL-A| CTRL-A 2 add N to number in highlighted text @@ -1008,6 +1017,7 @@ file names, tags, commands etc. as appropriate. tag command action in Command-line editing mode ~ ------------------------------------------------------------------------------ + CTRL-@ not used |c_CTRL-A| CTRL-A do completion on the pattern in front of the cursor and insert all matches @@ -1118,6 +1128,7 @@ The commands are sorted on the non-optional part of their name. tag command action ~ ------------------------------------------------------------------------------ + |:| : nothing |:range| :{range} go to last line in {range} |:!| :! filter lines or execute an external command diff --git a/runtime/doc/luaref.txt b/runtime/doc/luaref.txt index 0b04005e1a..9ce3637563 100644 --- a/runtime/doc/luaref.txt +++ b/runtime/doc/luaref.txt @@ -61,7 +61,7 @@ other words, this section describes which tokens are valid, how they can be combined, and what their combinations mean. The language constructs will be explained using the usual extended BNF -notation, in which { `a` } means 0 or more `a`'s, and [ `a` ] means an optional `a`. +notation, in which `{ a }` means 0 or more `a`'s, and `[ a ]` means an optional `a`. ============================================================================== 2.1 Lexical Conventions *luaref-langLexConv* diff --git a/runtime/doc/pi_netrw.txt b/runtime/doc/pi_netrw.txt index 63d4496dc4..972c42107c 100644 --- a/runtime/doc/pi_netrw.txt +++ b/runtime/doc/pi_netrw.txt @@ -2782,7 +2782,7 @@ your browsing preferences. (see also: |netrw-settings|) history are saved (as .netrwbook and .netrwhist). Netrw uses |expand()| on the string. - default: stdpath('data') (see |stdpath()|) + default: stdpath("data") (see |stdpath()|) *g:netrw_keepdir* =1 (default) keep current directory immune from the browsing directory. diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt index b0332269d7..b84274cc9e 100644 --- a/runtime/doc/repeat.txt +++ b/runtime/doc/repeat.txt @@ -471,7 +471,7 @@ flag when defining the function, it is not relevant when executing it. > :set cpo-=C < *line-continuation-comment* -To add a comment in between the lines start with '"\ '. Notice the space +To add a comment in between the lines start with `'"\ '`. Notice the space after the backslash. Example: > let array = [ "\ first entry comment @@ -491,7 +491,7 @@ Rationale: continuation lines to be part of the comment. Since it was like this for a long time, when making it possible to add a comment halfway a sequence of continuation lines, it was not possible to use \", since - that was a valid continuation line. Using '"\ ' comes closest, even + that was a valid continuation line. Using `'"\ '` comes closest, even though it may look a bit weird. Requiring the space after the backslash is to make it very unlikely this is a normal comment line. diff --git a/runtime/doc/starting.txt b/runtime/doc/starting.txt index 351fe868d9..4ac076027c 100644 --- a/runtime/doc/starting.txt +++ b/runtime/doc/starting.txt @@ -1357,7 +1357,7 @@ LOG FILE *$NVIM_LOG_FILE* *E5430* Besides 'debug' and 'verbose', Nvim keeps a general log file for internal debugging, plugins and RPC clients. > :echo $NVIM_LOG_FILE -By default, the file is located at stdpath('log')/log unless that path +By default, the file is located at stdpath("log")/log unless that path is inaccessible or if $NVIM_LOG_FILE was set before |startup|. |