summaryrefslogtreecommitdiffstatshomepage
path: root/runtime/lua/vim/shared.lua
diff options
context:
space:
mode:
authorluukvbaal <luukvbaal@gmail.com>2025-05-02 11:02:02 +0200
committerGitHub <noreply@github.com>2025-05-02 02:02:02 -0700
commit2c1c0b7af50b9732a78799bca4cba0c6059b5415 (patch)
tree0f944aee4d798074349b3102b9cac8c32325f4d0 /runtime/lua/vim/shared.lua
parentda401ca25b4dbef121da627fdcdc1dbaf8b7e092 (diff)
feat(ui): ext_cmdline/messages for the TUI #27855
Problem: We have an unmaintained Vimscript parser and cmdline highlighting mechanism, with which it is hard to leverage the treesitter highlighter. Long messages result in a hit-enter-prompt. Solution: Implement a vim.ui_attach() UI, that replaces the message grid (orphaning some 3000+ LOC core C code). Introduce an experimental vim._extui module, because removing the message grid at the same time is too risky. The new UI leverages the bundled treesitter highlighter and parser for Vimscript, as well as the matchparen plugin, to highlight the cmdline. Messages are truncated in the cmdline area, or placed in a floating message box in the bottom right corner. Special ("list_cmd") messages and the message history are shown in a, "more prompt" (now a fully interactive regular window). Various default UI elements ('showcmd', 'ruler') are also placed in the cmdline area, as virtual text. `require('vim._extui').enable({})` enables the experimental UI. `{ msg.pos = 'box' }` or `:set cmdheight=0` enables the message box variant. Followup: - Come to a consensus for how best to represent messages (by default). - Start removing message grid when this is deemed a successful replacement. When that is finished, make this new UI the default and update a lot of tests.
Diffstat (limited to 'runtime/lua/vim/shared.lua')
0 files changed, 0 insertions, 0 deletions