Repository navigation
fix(keymaps): remap <C-L> functionality into <C-c> - #2191
Open
nathanzeng wants to merge 1 commit into
Open
nathanzeng wants to merge 1 commit into
nathanzeng wants to merge 1 commit into
Conversation
nathanzeng
commented
Nov 30, 2026
|
|
||
| -- Clear highlights on search when pressing <Esc> in normal mode | ||
| -- See `:help hlsearch` | ||
| vim.keymap.set('n', '<Esc>', '<cmd>nohlsearch<CR>') |
Contributor
Author
There was a problem hiding this comment.
I'm could go either way on removing this, but I just didn't think it made sense to have two mappings cover the same thing
nathanzeng
commented
Nov 30, 2026
Comment on lines
+241
to
+249
| vim.keymap.set( | ||
| 'n', | ||
| '<C-c>', | ||
| '<Cmd>nohlsearch' | ||
| .. '<Bar>diffupdate' | ||
| .. '<Bar>call nvim_buf_clear_namespace(0, nvim_create_namespace("nvim.multicursor"), 0, -1)' | ||
| .. '<Bar>normal! <C-L><C-c><CR>', | ||
| { desc = 'Clear pending command and search highlighting, update diffs, remove multicursors' } | ||
| ) |
Contributor
Author
There was a problem hiding this comment.
If this is not friendly enough, I could see if we could get an upstream feature for a <Plug> mapping for CTRL-L behavior
Problem: We use `<C-L>` for window navigation, but it is also the only way to clear multicursors when in neovim 0.13. Solution: Create a mapping for `<C-c>` that performs `<C-c>` as well as `<C-L>` default behavior. NOTE: probably wait for 0.13 stable release to merge this.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem:
We use
<C-L>for window navigation, but it is also the only way to clear multicursors when in neovim 0.13.Solution:
Create a mapping for
<C-c>that performs<C-c>as well as<C-L>default behavior.NOTE: probably wait for 0.13 stable release to merge this.