It makes sense to store the provider each sidebar is using with own
self.provider fields, no way that did not occur to me before this.
The old `_G._outline_current_provider` ironically, can now be replaced
by `require('outline').current.provider`.
Primarily:
- Utils
- Sidebar (removed the need of writer.lua)
- Resolve keymaps shortcut in config eraly
- Put highlight functions into highlight.lua
- Put functions that do stuff on outline window into view.lua
Was passing self fields a lot, decided to just do all that in Sidebar
in the first place.
Also resolved guides.enabled=false early to setting markers to ' '.
Everything should work the same.
Currently the implementation is very limited.
Ref: #24
- Outline must be open and have been loaded for it to work (requires
lazy loading or headless loading of Sidebar)
- Empty string returned if cursor is not in any symbol ('closest' symbol
not yet supported)
- Line column not used
- Returning concatenated symbol names rather than a list of tables with
node info (requires a refactor of outline.SymbolNode type)
- Subject to config.symbols.filter and folds (requires finding hover
list somewhere outside of writer.make_outline)
Closes#37
Almost completely refactored the UI parts outline.nvim to use a Sidebar
object that implements an outline window. In init.lua, we can then store
a table of the outline for each tabpage ID.
When tabs are closed the outline is closed and sidebar reset
responsibly.
This simplifies `init.lua` quite a lot, making it the highest level
control center for the outline elements.
All lua APIs and commands should work as before.