Commit Graph

92 Commits

Author SHA1 Message Date
Simrat Grewal
66b2422455 feat: Bring back auto_preview keymap 2022-08-15 15:06:37 -07:00
Simrat Grewal
47cbb20f52 feat: Bring back auto_preview 2022-08-15 14:59:40 -07:00
Simrat Grewal
ab3c25c3d9 refactor: Switch to new autocmd apis 2022-08-15 14:53:29 -07:00
Simrat Grewal
776ddb3930 feat(parser): Flatten outline items while parsing
* Removes the need for flatten_outline_items
* Improves performance
2022-08-15 14:31:19 -07:00
Simrat Grewal
f33bdb4be9 misc: formatting 2022-08-15 14:08:28 -07:00
Simrat Grewal
7747a020a6 feat(parser): Fix guide highlight for multi-width characters 2022-08-10 20:47:31 -07:00
Simrat Grewal
094334c1a8 feat(ui): Rework how highlights are applied to outlines
* Previously we used vim's pattern matching which is not a great way to
  do this in neovim, as tree-sitter doesn't support it.

* Now we use the neovim apis which are range based
2022-08-10 17:42:50 -07:00
Simrat Grewal
d7542aab11 refresh: Use view.is_open 2022-08-10 15:40:38 -07:00
Simrat Grewal
1188ed7201 (breaking_change) feat: Make setup explicit
Don't setup on its own
2022-08-10 15:33:23 -07:00
Simrat Grewal
ed6c058eee chore: stylua 2022-08-10 15:29:39 -07:00
Simrat Grewal
d1065bc492 fix: Fix close mapping 2022-08-10 15:24:37 -07:00
Simrat Grewal
9ff33755cd cleanup: Disable auto_preview for now
Till we clean this stuff up
2022-08-10 15:22:47 -07:00
Simrat Grewal
374b80010a feat: Use vim.keymap.set for setting keymaps 2022-08-10 15:08:46 -07:00
Simrat Grewal
d12af70950 state: Remove unused winnr/bufnr 2022-08-10 14:48:55 -07:00
Simrat Grewal
62b59f4de5 toggle: Use View:is_open 2022-08-10 14:47:25 -07:00
Simrat Grewal
50dd2e9275 feat(view): Turn View into a class and refactor closing 2022-08-10 14:46:01 -07:00
FollieHiyuki
d980dbf947 Format with stylua 2022-02-22 22:32:53 +07:00
zeertzjq
d738b1defd fix: initialize code_win to 0 instead of nil
Ref <https://github.com/neovim/neovim/pull/16745>
2022-01-04 10:18:57 +08:00
Andrew
f98bc4de86 feat: added autoclose functionality 2021-11-23 05:09:08 +11:00
simrat39
042c8466a2 feat(providers): Inital COC support
Closes #68
Still needs support for code actions/hover/rename etc
2021-10-06 12:58:44 -07:00
simrat39
a0d563172d refactor: Add a generic provider module
In preperation for coc support
2021-10-05 22:46:53 -07:00
simrat39
6f376ef4ce refactor: Move should refresh logic to utils 2021-08-22 17:29:29 -07:00
simrat39
fae3393873 refactor: Move buffer/window creation to its own module
For now we have some stuff out of that module to prevent infinite
require loops (set_keymaps/clear_state), but once state goes into its
own module as well then we can work it all into view.lua
2021-08-22 17:22:16 -07:00
simrat39
c646d68fe8 refactor: Move nmap to utils 2021-08-22 17:00:24 -07:00
simrat39
ebf490a0e8 cleanup: Remove _prevent_buffer_override() function on BufLeave 2021-08-22 16:56:33 -07:00
simrat39
a4b701978f refactor: Move commands and autocommands to vimscript 2021-08-22 16:55:29 -07:00
simrat39
2932c11e92 refactor: Move debounce function to the utils 2021-08-22 16:38:26 -07:00
Omar Zeghouani
78b4f20b39 Simplify preview toggle 2021-08-21 10:17:12 +01:00
simrat39
079f39607a Update preview_toggle name 2021-08-20 19:11:24 -07:00
simrat39
a2e4a20308 Merge branch 'master' of https://github.com/ram02z/symbols-outline.nvim into ram02z-master 2021-08-20 19:06:46 -07:00
Omar Zeghouani
970d9932c5 Add help message for keybinds 2021-08-20 20:38:04 +01:00
Omar Zeghouani
23f1299869 Add toggle functionality
- Ensure that preview window always closes on symbol window exit
2021-08-20 20:25:22 +01:00
sim
2047f401e7 Merge pull request #50 from scheatkode/fix/refresh
fix: Handle window switching
2021-08-18 17:51:44 -07:00
scheatkode
bb8df852d2 fix: Handle window switching
The outline window is sometimes not refreshed when switching windows.
This is fixed by listening for `BufEnter` events.

A debouncing function is also added to prevent spamming the language
server.
2021-08-05 16:03:12 +01:00
scheatkode
b1d0fadac5 feat(config): Add preview keymap trigger 2021-08-05 13:52:25 +01:00
simrat39
1941d9edf9 Initial markdown support
Markdown doesnt have a language server, so do this manually
Closes #43
2021-08-01 12:22:01 -07:00
simrat39
63931775ce feat(config): Allow multiple keys for keymaps
Closes #45
2021-07-29 12:09:41 -07:00
simrat39
260227983a feat: Add width option
* This is relative to the size of the current split
2021-07-27 15:27:54 -07:00
simrat39
0868b5f463 fix: Fix the width of the outline window
So that it does not get offset by opening a file manager or other splits
Closes #33
2021-07-21 12:34:55 -07:00
simrat39
fea9ce74e2 Remove debug print 2021-07-13 21:46:44 -07:00
simrat39
8aa8cbad58 feat: Focus to the currently hovered symbol on the first open
We already do this whenever the user is going through the code file but
it doesnt happen on the first open of the outline, so do that.

Closes #24
2021-07-13 21:10:26 -07:00
simrat39
a100b51b23 feat: Allow setting line numbers / relative numbers
Closes #31
2021-06-22 19:59:49 -07:00
sim
e4172c803c Merge pull request #29 from ovikk13/feat-multiple-lsp-clients
feat: support multiple lsp clients
2021-06-13 11:10:06 -07:00
osmund
2caf9f6ff7 Fix(#22): unable to close last buffer if outline opened. 2021-06-13 11:59:17 +02:00
osmund
e7a2cfbee8 feat: support multiple lsp clients
Fixes issue #25
2021-06-13 11:23:46 +02:00
simrat39
23f253aa38 Make keybindings non recursive
Closes #18
2021-05-29 19:13:37 -07:00
Emiliano Ruiz Carletti
bb73de0e6a Silent mappings 2021-05-26 19:46:47 -03:00
simrat39
6cffe24f33 fix(_refresh): Only refresh if current buffer is attached to a lsp
client
2021-05-03 15:30:46 -07:00
simrat39
887db9aaaa refractor(parser): get_details: Use flattened_outline_items 2021-05-03 15:25:06 -07:00
simrat39
e9adda47f3 feat(auto_preview): Experimental auto preview and auto hover support
#10
2021-05-02 17:49:18 -07:00