From 51c754b62e795c49cfcf9df3ab492bdd53c61482 Mon Sep 17 00:00:00 2001 From: bfredl Date: Wed, 2 Aug 2023 13:15:30 +0200 Subject: [PATCH] feat(lua): use keyset type information --- runtime/lua/vim/_meta/api_keysets.lua | 302 +++++++++++++------------- 1 file changed, 151 insertions(+), 151 deletions(-) diff --git a/runtime/lua/vim/_meta/api_keysets.lua b/runtime/lua/vim/_meta/api_keysets.lua index 184eb7a060..5f8cb93144 100644 --- a/runtime/lua/vim/_meta/api_keysets.lua +++ b/runtime/lua/vim/_meta/api_keysets.lua @@ -4,112 +4,112 @@ error('Cannot require a meta file') --- @class vim.api.keyset.clear_autocmds ---- @field buffer any +--- @field buffer integer --- @field event any --- @field group any --- @field pattern any --- @class vim.api.keyset.cmd ---- @field cmd any ---- @field range any ---- @field count any ---- @field reg any ---- @field bang any ---- @field args any ---- @field magic any ---- @field mods any +--- @field cmd string +--- @field range any[] +--- @field count integer +--- @field reg string +--- @field bang boolean +--- @field args any[] +--- @field magic table +--- @field mods table --- @field nargs any --- @field addr any --- @field nextcmd any --- @class vim.api.keyset.cmd_magic ---- @field file any ---- @field bar any +--- @field file boolean +--- @field bar boolean --- @class vim.api.keyset.cmd_mods ---- @field silent any ---- @field emsg_silent any ---- @field unsilent any ---- @field filter any ---- @field sandbox any ---- @field noautocmd any ---- @field browse any ---- @field confirm any ---- @field hide any ---- @field horizontal any ---- @field keepalt any ---- @field keepjumps any ---- @field keepmarks any ---- @field keeppatterns any ---- @field lockmarks any ---- @field noswapfile any ---- @field tab any ---- @field verbose any ---- @field vertical any ---- @field split any +--- @field silent boolean +--- @field emsg_silent boolean +--- @field unsilent boolean +--- @field filter table +--- @field sandbox boolean +--- @field noautocmd boolean +--- @field browse boolean +--- @field confirm boolean +--- @field hide boolean +--- @field horizontal boolean +--- @field keepalt boolean +--- @field keepjumps boolean +--- @field keepmarks boolean +--- @field keeppatterns boolean +--- @field lockmarks boolean +--- @field noswapfile boolean +--- @field tab integer +--- @field verbose integer +--- @field vertical boolean +--- @field split string --- @class vim.api.keyset.cmd_mods_filter ---- @field pattern any ---- @field force any +--- @field pattern string +--- @field force boolean --- @class vim.api.keyset.cmd_opts ---- @field output any +--- @field output boolean --- @class vim.api.keyset.context ---- @field types any +--- @field types any[] --- @class vim.api.keyset.create_augroup --- @field clear any --- @class vim.api.keyset.create_autocmd ---- @field buffer any +--- @field buffer integer --- @field callback any ---- @field command any ---- @field desc any +--- @field command string +--- @field desc string --- @field group any ---- @field nested any ---- @field once any +--- @field nested boolean +--- @field once boolean --- @field pattern any --- @class vim.api.keyset.echo_opts ---- @field verbose any +--- @field verbose boolean --- @class vim.api.keyset.eval_statusline ---- @field winid any ---- @field maxwidth any ---- @field fillchar any ---- @field highlights any ---- @field use_winbar any ---- @field use_tabline any ---- @field use_statuscol_lnum any +--- @field winid integer +--- @field maxwidth integer +--- @field fillchar string +--- @field highlights boolean +--- @field use_winbar boolean +--- @field use_tabline boolean +--- @field use_statuscol_lnum integer --- @class vim.api.keyset.exec_autocmds ---- @field buffer any +--- @field buffer integer --- @field group any ---- @field modeline any +--- @field modeline boolean --- @field pattern any --- @field data any --- @class vim.api.keyset.exec_opts ---- @field output any +--- @field output boolean --- @class vim.api.keyset.float_config ---- @field row any ---- @field col any ---- @field width any ---- @field height any ---- @field anchor any ---- @field relative any ---- @field win any ---- @field bufpos any ---- @field external any ---- @field focusable any ---- @field zindex any +--- @field row number +--- @field col number +--- @field width integer +--- @field height integer +--- @field anchor string +--- @field relative string +--- @field win integer +--- @field bufpos any[] +--- @field external boolean +--- @field focusable boolean +--- @field zindex integer --- @field border any --- @field title any ---- @field title_pos any ---- @field style any ---- @field noautocmd any +--- @field title_pos string +--- @field style string +--- @field noautocmd boolean --- @class vim.api.keyset.get_autocmds --- @field event any @@ -118,27 +118,27 @@ error('Cannot require a meta file') --- @field buffer any --- @class vim.api.keyset.get_commands ---- @field builtin any +--- @field builtin boolean --- @class vim.api.keyset.get_highlight ---- @field id any ---- @field name any ---- @field link any +--- @field id integer +--- @field name string +--- @field link boolean --- @class vim.api.keyset.highlight ---- @field bold any ---- @field standout any ---- @field strikethrough any ---- @field underline any ---- @field undercurl any ---- @field underdouble any ---- @field underdotted any ---- @field underdashed any ---- @field italic any ---- @field reverse any ---- @field altfont any ---- @field nocombine any ---- @field default_ any +--- @field bold boolean +--- @field standout boolean +--- @field strikethrough boolean +--- @field underline boolean +--- @field undercurl boolean +--- @field underdouble boolean +--- @field underdotted boolean +--- @field underdashed boolean +--- @field italic boolean +--- @field reverse boolean +--- @field altfont boolean +--- @field nocombine boolean +--- @field default boolean --- @field cterm any --- @field foreground any --- @field fg any @@ -150,100 +150,100 @@ error('Cannot require a meta file') --- @field sp any --- @field link any --- @field global_link any ---- @field fallback any ---- @field blend any ---- @field fg_indexed any ---- @field bg_indexed any +--- @field fallback boolean +--- @field blend integer +--- @field fg_indexed boolean +--- @field bg_indexed boolean --- @class vim.api.keyset.highlight_cterm ---- @field bold any ---- @field standout any ---- @field strikethrough any ---- @field underline any ---- @field undercurl any ---- @field underdouble any ---- @field underdotted any ---- @field underdashed any ---- @field italic any ---- @field reverse any ---- @field altfont any ---- @field nocombine any +--- @field bold boolean +--- @field standout boolean +--- @field strikethrough boolean +--- @field underline boolean +--- @field undercurl boolean +--- @field underdouble boolean +--- @field underdotted boolean +--- @field underdashed boolean +--- @field italic boolean +--- @field reverse boolean +--- @field altfont boolean +--- @field nocombine boolean --- @class vim.api.keyset.keymap ---- @field noremap any ---- @field nowait any ---- @field silent any ---- @field script any ---- @field expr any ---- @field unique any ---- @field callback any ---- @field desc any ---- @field replace_keycodes any +--- @field noremap boolean +--- @field nowait boolean +--- @field silent boolean +--- @field script boolean +--- @field expr boolean +--- @field unique boolean +--- @field callback function +--- @field desc string +--- @field replace_keycodes boolean --- @class vim.api.keyset.option ---- @field scope any ---- @field win any ---- @field buf any ---- @field filetype any +--- @field scope string +--- @field win integer +--- @field buf integer +--- @field filetype string --- @class vim.api.keyset.runtime ---- @field is_lua any ---- @field do_source any +--- @field is_lua boolean +--- @field do_source boolean --- @class vim.api.keyset.set_decoration_provider ---- @field on_start any ---- @field on_buf any ---- @field on_win any ---- @field on_line any ---- @field on_end any ---- @field _on_hl_def any ---- @field _on_spell_nav any +--- @field on_start function +--- @field on_buf function +--- @field on_win function +--- @field on_line function +--- @field on_end function +--- @field _on_hl_def function +--- @field _on_spell_nav function --- @class vim.api.keyset.set_extmark ---- @field id any ---- @field end_line any ---- @field end_row any ---- @field end_col any +--- @field id integer +--- @field end_line integer +--- @field end_row integer +--- @field end_col integer --- @field hl_group any ---- @field virt_text any ---- @field virt_text_pos any ---- @field virt_text_win_col any ---- @field virt_text_hide any ---- @field hl_eol any ---- @field hl_mode any ---- @field ephemeral any ---- @field priority any ---- @field right_gravity any ---- @field end_right_gravity any ---- @field virt_lines any ---- @field virt_lines_above any ---- @field virt_lines_leftcol any ---- @field strict any ---- @field sign_text any +--- @field virt_text any[] +--- @field virt_text_pos string +--- @field virt_text_win_col integer +--- @field virt_text_hide boolean +--- @field hl_eol boolean +--- @field hl_mode string +--- @field ephemeral boolean +--- @field priority integer +--- @field right_gravity boolean +--- @field end_right_gravity boolean +--- @field virt_lines any[] +--- @field virt_lines_above boolean +--- @field virt_lines_leftcol boolean +--- @field strict boolean +--- @field sign_text string --- @field sign_hl_group any --- @field number_hl_group any --- @field line_hl_group any --- @field cursorline_hl_group any ---- @field conceal any ---- @field spell any ---- @field ui_watched any +--- @field conceal string +--- @field spell boolean +--- @field ui_watched boolean --- @class vim.api.keyset.user_command --- @field addr any ---- @field bang any ---- @field bar any +--- @field bang boolean +--- @field bar boolean --- @field complete any --- @field count any --- @field desc any ---- @field force any ---- @field keepscript any +--- @field force boolean +--- @field keepscript boolean --- @field nargs any --- @field preview any --- @field range any ---- @field register_ any +--- @field register boolean --- @class vim.api.keyset.win_text_height ---- @field start_row any ---- @field end_row any ---- @field start_vcol any ---- @field end_vcol any +--- @field start_row integer +--- @field end_row integer +--- @field start_vcol integer +--- @field end_vcol integer