-
Notifications
You must be signed in to change notification settings - Fork 62
Expand file tree
/
Copy pathoutline.lua
More file actions
65 lines (61 loc) · 2.26 KB
/
outline.lua
File metadata and controls
65 lines (61 loc) · 2.26 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
local M = {}
M.config = function()
local kind = require("user.lsp_kind").cmp_kind
local status_ok, symout = pcall(require, "outline")
if not status_ok then
return
end
local opts = {
outline_window = {
position = "right",
width = 20,
relative_width = true,
auto_close = false,
auto_jump = false,
jump_highlight_duration = 300,
center_on_jump = true,
show_numbers = false,
show_relative_numbers = false,
wrap = false,
show_cursorline = true,
hide_cursor = false,
focus_on_open = true,
},
outline_items = {
show_symbol_details = false,
show_symbol_lineno = false,
},
symbols = {
icons = {
File = { icon = kind.File, hl = "@text.uri" },
Module = { icon = kind.Module, hl = "@namespace" },
Namespace = { icon = kind.Namespace, hl = "@namespace" },
Package = { icon = kind.Package, hl = "@namespace" },
Class = { icon = kind.Class, hl = "@type" },
Method = { icon = kind.Method, hl = "@method" },
Property = { icon = kind.Property, hl = "@method" },
Field = { icon = kind.Field, hl = "@field" },
Constructor = { icon = kind.Constructor, hl = "@constructor" },
Enum = { icon = kind.Enum, hl = "@type" },
Interface = { icon = kind.Interface, hl = "@type" },
Function = { icon = kind.Function, hl = "@function" },
Variable = { icon = kind.Variable, hl = "@constant" },
Constant = { icon = kind.Constant, hl = "@constant" },
String = { icon = kind.String, hl = "@string" },
Number = { icon = kind.Number, hl = "@number" },
Boolean = { icon = kind.Boolean, hl = "@boolean" },
Array = { icon = kind.Array, hl = "@constant" },
Object = { icon = kind.Object, hl = "@type" },
Key = { icon = kind.Key, hl = "@type" },
Null = { icon = kind.Null, hl = "@type" },
EnumMember = { icon = kind.EnumMember, hl = "@field" },
Struct = { icon = kind.Struct, hl = "@type" },
Event = { icon = kind.Event, hl = "@type" },
Operator = { icon = kind.Operator, hl = "@operator" },
TypeParameter = { icon = kind.TypeParameter, hl = "@parameter" },
},
},
}
symout.setup(opts)
end
return M