feat: improve wrapped-line editing and completion cancellation

Use word-boundary wrapping and count-aware displayed-line movement in ordinary buffers. Escape cancels Blink completion before falling back. Preserve the existing ergonomics check; it was not rerun during Git cleanup.
This commit is contained in:
kiri committed 2026-09-09 17:31:25 +02:00
1 parent 35ce6be8f9
commit 8f5d690d75
4 files changed
+26

No files matched your search

@@ -7,6 +7,12 @@ end
vim.keymap.del("x", "gra")
vim.keymap.del({ "i", "s" }, "<C-S>")
for _, key in ipairs({ "j", "k" }) do
vim.keymap.set({ "n", "x" }, key, function()
return vim.bo.buftype == "" and vim.v.count == 0 and "g" .. key or key
end, { expr = true, desc = "Move by displayed line, or logical line with a count" })
end
vim.keymap.set("n", "<C-h>", "<C-w><C-h>", { desc = "Focus left window" })
vim.keymap.set("n", "<C-j>", "<C-w><C-j>", { desc = "Focus lower window" })
vim.keymap.set("n", "<C-k>", "<C-w><C-k>", { desc = "Focus upper window" })
@@ -17,6 +17,7 @@ vim.o.timeoutlen = 300
vim.o.updatetime = 250
vim.o.breakindent = true
vim.o.linebreak = true
vim.o.undofile = true
vim.o.ignorecase = true
vim.o.smartcase = true
@@ -15,6 +15,7 @@ require("lz.n").load({
after = function()
require("blink.cmp").setup({
keymap = {
["<Esc>"] = { "cancel", "fallback" },
["<C-j>"] = { "select_next", "fallback" },
["<C-k>"] = { "select_prev", "fallback" },
["<Tab>"] = { "select_and_accept", "fallback" },