Skip to content

Commit c0a1222

Browse files
committed
👍 deno task gen
1 parent 7a9a58d commit c0a1222

File tree

8 files changed

+872
-229
lines changed

8 files changed

+872
-229
lines changed

denops_std/function/_generated.ts

Lines changed: 115 additions & 92 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

denops_std/function/buffer.ts

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,9 @@ export interface GetBufInfoDictArg {
7070
*
7171
* :let failed = appendbufline(13, 0, "# THE START")
7272
*
73+
* However, when **{text}** is an empty list then no error is given
74+
* for an invalid **{lnum}**, since **{lnum}** isn't actually used.
75+
*
7376
* Can also be used as a `method` after a List, the base is
7477
* passed as the second argument:
7578
*
@@ -295,7 +298,8 @@ export async function bufnr(
295298
*
296299
* echo "A window containing buffer 1 is " .. (bufwinid(1))
297300
*
298-
* Only deals with the current tab page.
301+
* Only deals with the current tab page. See `win_findbuf()` for
302+
* finding more.
299303
*
300304
* Can also be used as a `method`:
301305
*
@@ -460,7 +464,8 @@ export async function getbufinfo(
460464
/**
461465
* Return a `List` with the lines starting from **{lnum}** to **{end}**
462466
* (inclusive) in the buffer **{buf}**. If **{end}** is omitted, a
463-
* `List` with only the line **{lnum}** is returned.
467+
* `List` with only the line **{lnum}** is returned. See
468+
* `getbufoneline()` for only getting the line.
464469
*
465470
* For the use of **{buf}**, see `bufname()` above.
466471
*
@@ -607,9 +612,10 @@ export async function getmarklist(
607612
* To insert lines use `appendbufline()`.
608613
* Any text properties in **{lnum}** are cleared.
609614
*
610-
* **{text}** can be a string to set one line, or a list of strings
611-
* to set multiple lines. If the list extends below the last
612-
* line then those lines are added.
615+
* **{text}** can be a string to set one line, or a List of strings
616+
* to set multiple lines. If the List extends below the last
617+
* line then those lines are added. If the List is empty then
618+
* nothing is changed and zero is returned.
613619
*
614620
* For the use of **{buf}**, see `bufname()` above.
615621
*

denops_std/function/common.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,8 @@ export async function has(
228228
*
229229
* ComputeLnum()->getline()
230230
*
231-
* To get lines from another buffer see `getbufline()`
231+
* To get lines from another buffer see `getbufline()` and
232+
* `getbufoneline()`
232233
*/
233234
export async function getline(
234235
denops: Denops,
@@ -256,7 +257,8 @@ export async function getline(
256257
* When **{lnum}** is just below the last line the **{text}** will be
257258
* added below the last line.
258259
* **{text}** can be any type or a List of any type, each item is
259-
* converted to a String.
260+
* converted to a String. When **{text}** is an empty List then
261+
* nothing is changed and FALSE is returned.
260262
*
261263
* If this succeeds, FALSE is returned. If this fails (most likely
262264
* because **{lnum}** is invalid) TRUE is returned.

denops_std/function/cursor.ts

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ import type { Position, ScreenPos } from "./types.ts";
1717
* and column number. Most useful when the column is "$", to get
1818
* the last column of a specific line. When "lnum" or "col" is
1919
* out of range then col() returns zero.
20+
* With the optional **{winid}** argument the values are obtained for
21+
* that window instead of the current window.
2022
* To get the line number use `line()`. To get both use
2123
* `getpos()`.
2224
* For the screen column position use `virtcol()`. For the
@@ -29,17 +31,16 @@ import type { Position, ScreenPos } from "./types.ts";
2931
* col("'t") column of mark t
3032
* col("'" .. markname) column of mark markname
3133
*
32-
* The first column is 1. Returns 0 if **{expr}** is invalid.
34+
* The first column is 1. Returns 0 if **{expr}** is invalid or when
35+
* the window with ID **{winid}** is not found.
3336
* For an uppercase mark the column may actually be in another
3437
* buffer.
3538
* For the cursor position, when 'virtualedit' is active, the
3639
* column is one higher if the cursor is after the end of the
37-
* line. This can be used to obtain the column in Insert mode:
40+
* line. Also, when using a `<Cmd>` mapping the cursor isn't
41+
* moved, this can be used to obtain the column in Insert mode:
3842
*
39-
* :imap <F2> <C-O>:let save_ve = &ve<CR>
40-
* \<C-O>:set ve=all<CR>
41-
* \<C-O>:echo col(".") .. "\n" <Bar>
42-
* \let &ve = save_ve<CR>
43+
* :imap <F2> <Cmd>echowin col(".")<CR>
4344
*
4445
* Can also be used as a `method`:
4546
*
@@ -207,10 +208,10 @@ export async function winline(denops: Denops): Promise<number> {
207208
* `setcursorcharpos()`.
208209
*
209210
* Does not change the jumplist.
210-
* **{lnum}** is used like with `getline()`.
211+
* **{lnum}** is used like with `getline()`, except that if **{lnum}** is
212+
* zero, the cursor will stay in the current line.
211213
* If **{lnum}** is greater than the number of lines in the buffer,
212214
* the cursor will be positioned at the last line in the buffer.
213-
* If **{lnum}** is zero, the cursor will stay in the current line.
214215
* If **{col}** is greater than the number of bytes in the line,
215216
* the cursor will be positioned at the last character in the
216217
* line.

0 commit comments

Comments
 (0)