Auto generate docs
This commit is contained in:
committed by
github-actions[bot]
parent
06bdbc8f6e
commit
e459f3262c
@@ -1,293 +1,178 @@
|
|||||||
*symbols-outline.txt* Tree view of LSP symbols
|
*symbols-outline.txt* For NVIM v0.5.0 Last change: 2022 August 18
|
||||||
|
|
||||||
================================================================================
|
==============================================================================
|
||||||
CONTENTS *symbols-outline-contents*
|
Table of Contents *symbols-outline-table-of-contents*
|
||||||
|
|
||||||
1. Introduction...........................|symbols-outline-introduction|
|
1. symbols-outline.nvim |symbols-outline-symbols-outline.nvim|
|
||||||
2. Prerequisites.........................|symbols-outline-prerequisites|
|
- Prerequisites |symbols-outline-prerequisites|
|
||||||
3. Installation...........................|symbols-outline-installation|
|
- Installation |symbols-outline-installation|
|
||||||
4. Configuration.........................|symbols-outline-configuration|
|
- Setup |symbols-outline-setup|
|
||||||
5. Commands...................................|symbols-outline-commands|
|
- Configuration |symbols-outline-configuration|
|
||||||
6. Default keymaps.....................|symbols-outline-default_keymaps|
|
- Commands |symbols-outline-commands|
|
||||||
7. Highlights...............................|symbols-outline-highlights|
|
- Default keymaps |symbols-outline-default-keymaps|
|
||||||
|
- Highlights |symbols-outline-highlights|
|
||||||
|
|
||||||
|
==============================================================================
|
||||||
|
1. symbols-outline.nvim *symbols-outline-symbols-outline.nvim*
|
||||||
|
|
||||||
|
**A tree like view for symbols in Neovim using the Language Server Protocol.
|
||||||
|
Supports all your favourite languages.**
|
||||||
|
|
||||||
|
<div class="figure">
|
||||||
|
<img src="https://github.com/simrat39/rust-tools-demos/raw/master/symbols-demo.gif" title="fig:"/>
|
||||||
|
<p class="caption">demo</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
PREREQUISITES *symbols-outline-prerequisites*
|
||||||
|
|
||||||
|
|
||||||
================================================================================
|
- `neovim 0.7+`
|
||||||
1. INTRODUCTION *symbols-outline-introduction*
|
- Properly configured Neovim LSP client
|
||||||
|
|
||||||
A tree like view for symbols in Neovim using the Language Server Protocol.
|
|
||||||
Supports all your favourite languages.
|
|
||||||
|
|
||||||
================================================================================
|
|
||||||
2. PREREQUISITES *symbols-outline-prerequisites*
|
|
||||||
|
|
||||||
* `neovim 0.5+`
|
|
||||||
* Properly configured Neovim LSP client
|
|
||||||
|
|
||||||
|
|
||||||
================================================================================
|
INSTALLATION *symbols-outline-installation*
|
||||||
3. INSTALLATION *symbols-outline-installation*
|
|
||||||
|
Using `packer.nvim`
|
||||||
|
|
||||||
Using `vim-plug`
|
|
||||||
>
|
>
|
||||||
Plug 'simrat39/symbols-outline.nvim'
|
use 'simrat39/symbols-outline.nvim'
|
||||||
<
|
<
|
||||||
|
|
||||||
|
|
||||||
================================================================================
|
SETUP *symbols-outline-setup*
|
||||||
4. CONFIGURATION *symbols-outline-configuration*
|
|
||||||
|
|
||||||
Define a global variable `symbols_outline` as follows:
|
Put the setup call in your init.lua or any lua file that is sourced.
|
||||||
|
|
||||||
Only add stuff that you want to override (even in nested tables),
|
|
||||||
or skip this section entirely if you want to roll with the defaults.
|
|
||||||
>
|
>
|
||||||
-- init.lua
|
require("symbols-outline").setup()
|
||||||
vim.g.symbols_outline = {
|
<
|
||||||
highlight_hovered_item = true,
|
|
||||||
show_guides = true,
|
|
||||||
auto_preview = true,
|
CONFIGURATION *symbols-outline-configuration*
|
||||||
position = 'right',
|
|
||||||
width = 25,
|
Pass a table to the setup call above with your configuration options.
|
||||||
auto_close = false,
|
|
||||||
show_numbers = false,
|
>
|
||||||
show_relative_numbers = false,
|
local opts = {
|
||||||
show_symbol_details = true,
|
highlight_hovered_item = true,
|
||||||
preview_bg_highlight = 'Pmenu',
|
show_guides = true,
|
||||||
-- These keymaps can be a string or a table for multiple keys
|
auto_preview = false,
|
||||||
keymaps = {
|
position = 'right',
|
||||||
close = {"<Esc>", "q"},
|
relative_width = true,
|
||||||
goto_location = "<Cr>",
|
width = 25,
|
||||||
focus_location = "o",
|
auto_close = false,
|
||||||
hover_symbol = "<C-space>",
|
show_numbers = false,
|
||||||
toggle_preview = "K",
|
show_relative_numbers = false,
|
||||||
rename_symbol = "r",
|
show_symbol_details = true,
|
||||||
code_actions = "a",
|
preview_bg_highlight = 'Pmenu',
|
||||||
},
|
autofold_depth = nil,
|
||||||
lsp_blacklist = {},
|
auto_unfold_hover = true,
|
||||||
symbol_blacklist = {},
|
fold_markers = { '', '' },
|
||||||
symbols = {
|
keymaps = { -- These keymaps can be a string or a table for multiple keys
|
||||||
File = {icon = "", hl = "TSURI"},
|
close = {"<Esc>", "q"},
|
||||||
Module = {icon = "", hl = "TSNamespace"},
|
goto_location = "<Cr>",
|
||||||
Namespace = {icon = "", hl = "TSNamespace"},
|
focus_location = "o",
|
||||||
Package = {icon = "", hl = "TSNamespace"},
|
hover_symbol = "<C-space>",
|
||||||
Class = {icon = "𝓒", hl = "TSType"},
|
toggle_preview = "K",
|
||||||
Method = {icon = "ƒ", hl = "TSMethod"},
|
rename_symbol = "r",
|
||||||
Property = {icon = "", hl = "TSMethod"},
|
code_actions = "a",
|
||||||
Field = {icon = "", hl = "TSField"},
|
fold = "h",
|
||||||
Constructor = {icon = "", hl = "TSConstructor"},
|
unfold = "l",
|
||||||
Enum = {icon = "ℰ", hl = "TSType"},
|
fold_all = "W",
|
||||||
Interface = {icon = "ﰮ", hl = "TSType"},
|
unfold_all = "E",
|
||||||
Function = {icon = "", hl = "TSFunction"},
|
fold_reset = "R",
|
||||||
Variable = {icon = "", hl = "TSConstant"},
|
},
|
||||||
Constant = {icon = "", hl = "TSConstant"},
|
lsp_blacklist = {},
|
||||||
String = {icon = "𝓐", hl = "TSString"},
|
symbol_blacklist = {},
|
||||||
Number = {icon = "#", hl = "TSNumber"},
|
symbols = {
|
||||||
Boolean = {icon = "⊨", hl = "TSBoolean"},
|
File = {icon = "", hl = "TSURI"},
|
||||||
Array = {icon = "", hl = "TSConstant"},
|
Module = {icon = "", hl = "TSNamespace"},
|
||||||
Object = {icon = "⦿", hl = "TSType"},
|
Namespace = {icon = "", hl = "TSNamespace"},
|
||||||
Key = {icon = "🔐", hl = "TSType"},
|
Package = {icon = "", hl = "TSNamespace"},
|
||||||
Null = {icon = "NULL", hl = "TSType"},
|
Class = {icon = "𝓒", hl = "TSType"},
|
||||||
EnumMember = {icon = "", hl = "TSField"},
|
Method = {icon = "ƒ", hl = "TSMethod"},
|
||||||
Struct = {icon = "𝓢", hl = "TSType"},
|
Property = {icon = "", hl = "TSMethod"},
|
||||||
Event = {icon = "🗲", hl = "TSType"},
|
Field = {icon = "", hl = "TSField"},
|
||||||
Operator = {icon = "+", hl = "TSOperator"},
|
Constructor = {icon = "", hl = "TSConstructor"},
|
||||||
TypeParameter = {icon = "𝙏", hl = "TSParameter"}
|
Enum = {icon = "ℰ", hl = "TSType"},
|
||||||
}
|
Interface = {icon = "ﰮ", hl = "TSType"},
|
||||||
|
Function = {icon = "", hl = "TSFunction"},
|
||||||
|
Variable = {icon = "", hl = "TSConstant"},
|
||||||
|
Constant = {icon = "", hl = "TSConstant"},
|
||||||
|
String = {icon = "𝓐", hl = "TSString"},
|
||||||
|
Number = {icon = "#", hl = "TSNumber"},
|
||||||
|
Boolean = {icon = "⊨", hl = "TSBoolean"},
|
||||||
|
Array = {icon = "", hl = "TSConstant"},
|
||||||
|
Object = {icon = "⦿", hl = "TSType"},
|
||||||
|
Key = {icon = "🔐", hl = "TSType"},
|
||||||
|
Null = {icon = "NULL", hl = "TSType"},
|
||||||
|
EnumMember = {icon = "", hl = "TSField"},
|
||||||
|
Struct = {icon = "𝓢", hl = "TSType"},
|
||||||
|
Event = {icon = "🗲", hl = "TSType"},
|
||||||
|
Operator = {icon = "+", hl = "TSOperator"},
|
||||||
|
TypeParameter = {icon = "𝙏", hl = "TSParameter"}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
<
|
<
|
||||||
|
|
||||||
-----------------------------------------------------------------------------
|
|
||||||
highlight_hovered_item
|
|
||||||
|
|
||||||
Whether to highlight the currently hovered symbol (high cpu usage)
|
│ Property │ Description │ Type │ Default │
|
||||||
|
│highlight_hovered_item│Whether to highlight the currently hovered symbol (high cpu usage) │boolean │true │
|
||||||
Default: true ~
|
│show_guides │Whether to show outline guides │boolean │true │
|
||||||
|
│position │Where to open the split window │'right' or 'left' │'right' │
|
||||||
Type: boolean
|
│relative_width │Whether width of window is set relative to existing windows │boolean │true │
|
||||||
|
│width │Width of window (as a % or columns based on relative_width) │int │25 │
|
||||||
-----------------------------------------------------------------------------
|
│auto_close │Whether to automatically close the window after selection │boolean │false │
|
||||||
show_guides
|
│auto_preview │Show a preview of the code on hover │boolean │false │
|
||||||
|
│show_numbers │Shows numbers with the outline │boolean │false │
|
||||||
Whether to show outline guides
|
│show_relative_numbers │Shows relative numbers with the outline │boolean │false │
|
||||||
|
│show_symbol_details │Shows extra details with the symbols (lsp dependent) │boolean │true │
|
||||||
Default: true ~
|
│preview_bg_highlight │Background color of the preview window │string │Pmenu │
|
||||||
|
│winblend │Pseudo-transparency of the preview window │int │0 │
|
||||||
Type: boolean
|
│keymaps │Which keys do what │table (dictionary)│|symbols-outline-here|│
|
||||||
|
│symbols │Icon and highlight config for symbol icons │table (dictionary)│scroll up │
|
||||||
-----------------------------------------------------------------------------
|
│lsp_blacklist │Which lsp clients to ignore │table (array) │{} │
|
||||||
position
|
│symbol_blacklist │Which symbols to ignore (possible values <./lua/symbols-outline/symbols.lua>)│table (array) │{} │
|
||||||
|
│autofold_depth │Depth past which nodes will be folded by default │int │nil │
|
||||||
Where to open the split window
|
│auto_unfold_hover │Automatically unfold hovered symbol │boolean │true │
|
||||||
|
│fold_markers │Markers to denote foldable symbol’s status │table (array) │{ '', '' } │
|
||||||
Default: 'right' ~
|
|
||||||
|
|
||||||
Type: 'right' or 'left'
|
COMMANDS *symbols-outline-commands*
|
||||||
|
|
||||||
-----------------------------------------------------------------------------
|
│ Command │ Description │
|
||||||
relative_width
|
│:SymbolsOutline │Toggle symbols outline│
|
||||||
|
│:SymbolsOutlineOpen │Open symbols outline │
|
||||||
Whether the width of the window is relative to the current split or an
|
│:SymbolsOutlineClose │Close symbols outline │
|
||||||
absolute width
|
|
||||||
|
|
||||||
Default: true ~
|
DEFAULT KEYMAPS *symbols-outline-default-keymaps*
|
||||||
|
|
||||||
Type: boolean
|
│ Key │ Action │
|
||||||
|
│Escape │Close outline │
|
||||||
-----------------------------------------------------------------------------
|
│Enter │Go to symbol location in code │
|
||||||
width
|
│o │Go to symbol location in code without losing focus│
|
||||||
|
│Ctrl+Space│Hover current symbol │
|
||||||
Width of the window as a percentage of the current split
|
│K │Toggles the current symbol preview │
|
||||||
(`relative_width `= true) or as number of columns (`relative_width `= false)
|
│r │Rename symbol │
|
||||||
|
│a │Code actions │
|
||||||
Default: 25 ~
|
│h │Unfold symbol │
|
||||||
|
│l │Fold symbol │
|
||||||
Type: int
|
│W │Fold all symbols │
|
||||||
|
│E │Unfold all symbols │
|
||||||
-----------------------------------------------------------------------------
|
│R │Reset all folding │
|
||||||
auto_close
|
│? │Show help message │
|
||||||
|
|
||||||
Whether to automatically close the window after selection
|
|
||||||
|
HIGHLIGHTS *symbols-outline-highlights*
|
||||||
Default: false ~
|
|
||||||
|
│ Highlight │ Purpose │
|
||||||
Type: boolean
|
│FocusedSymbol │Highlight of the focused symbol │
|
||||||
|
│Pmenu │Highlight of the preview popup windows│
|
||||||
-----------------------------------------------------------------------------
|
│SymbolsOutlineConnector│Highlight of the table connectors │
|
||||||
auto_preview
|
│Comment │Highlight of the info virtual text │
|
||||||
|
|
||||||
Show a preview of the code on hover
|
|
||||||
|
Generated by panvimdoc <https://github.com/kdheepak/panvimdoc>
|
||||||
Default: true ~
|
|
||||||
|
vim:tw=78:ts=8:noet:ft=help:norl:
|
||||||
Type: boolean
|
|
||||||
|
|
||||||
-----------------------------------------------------------------------------
|
|
||||||
show_numbers
|
|
||||||
|
|
||||||
Shows numbers with the outline
|
|
||||||
|
|
||||||
Default: false ~
|
|
||||||
|
|
||||||
Type: boolean
|
|
||||||
|
|
||||||
-----------------------------------------------------------------------------
|
|
||||||
show_relative_numbers
|
|
||||||
|
|
||||||
Shows relative numbers with the outline
|
|
||||||
|
|
||||||
Default: false ~
|
|
||||||
|
|
||||||
Type: boolean
|
|
||||||
|
|
||||||
-----------------------------------------------------------------------------
|
|
||||||
show_symbol_details
|
|
||||||
|
|
||||||
Shows extra details with the symbols (lsp dependent)
|
|
||||||
|
|
||||||
Default: true ~
|
|
||||||
|
|
||||||
Type: boolean
|
|
||||||
|
|
||||||
-----------------------------------------------------------------------------
|
|
||||||
preview_bg_highlight
|
|
||||||
|
|
||||||
Background color of the preview window
|
|
||||||
|
|
||||||
Default: Pmenu
|
|
||||||
|
|
||||||
Type: string
|
|
||||||
|
|
||||||
-----------------------------------------------------------------------------
|
|
||||||
winblend
|
|
||||||
|
|
||||||
Pseudo-transparency of the preview window (value between `0` and `100`)
|
|
||||||
See `:h winblend`
|
|
||||||
|
|
||||||
Default: 0
|
|
||||||
|
|
||||||
Type: int
|
|
||||||
|
|
||||||
-----------------------------------------------------------------------------
|
|
||||||
keymaps
|
|
||||||
|
|
||||||
Which keys do what
|
|
||||||
|
|
||||||
Default: See |symbols-outline-default_keymaps| ~
|
|
||||||
|
|
||||||
Type: table (dictionary)
|
|
||||||
|
|
||||||
|
|
||||||
-----------------------------------------------------------------------------
|
|
||||||
symbols
|
|
||||||
|
|
||||||
Icon and highlight config for symbol icons
|
|
||||||
|
|
||||||
Default: See default config ~
|
|
||||||
|
|
||||||
Type: table (dictionary)
|
|
||||||
|
|
||||||
|
|
||||||
-----------------------------------------------------------------------------
|
|
||||||
lsp_blacklist
|
|
||||||
|
|
||||||
Which lsp clients to ignore
|
|
||||||
|
|
||||||
Default: {} ~
|
|
||||||
|
|
||||||
Type: table (dictionary)
|
|
||||||
|
|
||||||
-----------------------------------------------------------------------------
|
|
||||||
symbol_blacklist
|
|
||||||
|
|
||||||
Which symbols to ignore
|
|
||||||
|
|
||||||
>
|
|
||||||
-- symbols-outline.nvim/lua/symbols-outline/symbols.lua
|
|
||||||
{
|
|
||||||
"File", "Module", "Namespace", "Package", "Class", "Method", "Property",
|
|
||||||
"Field", "Constructor", "Enum", "Interface", "Function", "Variable",
|
|
||||||
"Constant", "String", "Number", "Boolean", "Array", "Object", "Key",
|
|
||||||
"Null", "EnumMember", "Struct", "Event", "Operator", "TypeParameter"
|
|
||||||
}
|
|
||||||
<
|
|
||||||
|
|
||||||
Default: {} ~
|
|
||||||
|
|
||||||
Type: table (dictionary)
|
|
||||||
|
|
||||||
================================================================================
|
|
||||||
5. COMMANDS *symbols-outline-commands*
|
|
||||||
|
|
||||||
| Command | Description |
|
|
||||||
| ---------------------- | ---------------------- |
|
|
||||||
| `:SymbolsOutline` | Toggle symbols outline |
|
|
||||||
| `:SymbolsOutlineOpen` | Open symbols outline |
|
|
||||||
| `:SymbolsOutlineClose` | Close symbols outline |
|
|
||||||
|
|
||||||
================================================================================
|
|
||||||
6. DEFAULT KEYMAPS *symbols-outline-default_keymaps*
|
|
||||||
|
|
||||||
| Key | Action |
|
|
||||||
| ---------- | ------------------------------------------------------------------ |
|
|
||||||
| Escape | Close outline |
|
|
||||||
| Enter | Go to symbol location in code |
|
|
||||||
| o | Go to symbol location in code without losing focus |
|
|
||||||
| Ctrl+Space | Hover current symbol |
|
|
||||||
| K | Toggles the current symbol preview |
|
|
||||||
| r | Rename symbol |
|
|
||||||
| a | Code actions |
|
|
||||||
| ? | Show help message |
|
|
||||||
|
|
||||||
================================================================================
|
|
||||||
7. HIGHLIGHTS *symbols-outline-highlights*
|
|
||||||
|
|
||||||
| Highlight | Purpose |
|
|
||||||
| ----------------------- | ------------------------------------------------------- |
|
|
||||||
| FocusedSymbol | Highlight of the focused symbol |
|
|
||||||
| Pmenu | Highlight of the preview popup windows |
|
|
||||||
| SymbolsOutlineConnector | Highlight of the table connectors |
|
|
||||||
| Comment | Highlight of the table connectors and info virtual text |
|
|
||||||
|
|
||||||
================================================================================
|
|
||||||
vim:tw=79:ts=8:ft=help:norl
|
|
||||||
|
|||||||
Reference in New Issue
Block a user