From ec791fda5fca2cf54a387e8fd2023c774164c521 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Thu, 15 Aug 2024 09:33:59 +0200 Subject: [PATCH] nvim: Move next/prev spell error to z Z keys From [s ]s [S ]S, we move all to [z ]z [Z ]Z. --- nvim/.config/nvim/lua/core/mappings.lua | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/nvim/.config/nvim/lua/core/mappings.lua b/nvim/.config/nvim/lua/core/mappings.lua index 23bbe2c..7f457e9 100644 --- a/nvim/.config/nvim/lua/core/mappings.lua +++ b/nvim/.config/nvim/lua/core/mappings.lua @@ -128,8 +128,16 @@ map("x", "q", "gq", { silent = true, desc = "Format {motion}" }) map("n", "Q", "vapJgqap", { silent = true, desc = "Unformat then format paragraph" }) -- SPELL CHECKING --- Move to the prev/next spelling error with [S ]S --- Move to the prev/next spelling error or suggestion with [s ]s +-- Move to the prev/next spelling error with [z|[Z ]Z|]z instead of ]s +map("n", "]z", "]s") +map("n", "[z", "[s") +map("n", "]s", "") +map("n", "[s", "") +map("n", "]Z", "]S") +map("n", "[Z", "[S") +map("n", "]S", "") +map("n", "[S", "") +-- Move to the prev/next spelling error or suggestion with [z ]z map("n", "ZZ", "SpellToggle en_us en_gb de_de", { desc = "Toggle spellcheck" }) map("n", "ZA", "SpellToggle! en_us en_gb de_de", { desc = "Enable spellcheck" }) map("n", "ZE", "SpellToggle en_us", { desc = "Toggle EN_US spellcheck" })