Open verhovsky opened 3 years ago
Ctrl-l rebind in c/c++ mode after ccls load
How to disable ccls
, it rebinds "C-h", "C-k" in normal state, which is inconvenient.
I tried to rebind it back inside 'with-eval-after-load' but failed.
Finally I used this for my temporary local fix, might be a bad solution, but it works:
diff --git a/modules/lang/cc/config.el b/modules/lang/cc/config.el
index 788903f0..1cb0af57 100644
--- a/modules/lang/cc/config.el
+++ b/modules/lang/cc/config.el
@@ -247,7 +247,7 @@
:n "C-h" (cmd! (ccls-navigate "U"))
:n "C-j" (cmd! (ccls-navigate "R"))
:n "C-k" (cmd! (ccls-navigate "L"))
- :n "C-l" (cmd! (ccls-navigate "D"))
+ ;; :n "C-l" (cmd! (ccls-navigate "D"))
(:localleader
:desc "Preprocess file" "lp" #'ccls-preprocess-file
:desc "Reload cache & CCLS" "lf" #'ccls-reload)
What did you expect to happen?
When I press ctrl-l while editing a C file, it should move around the file so that the line my cursor is currently on is in the middle of the screen.
What actually happened?
I see this error:
Steps to reproduce
init.el
:myfile.c
and write some code in it (you can add a bunch of empty lines to make it longer)press Ctrl-l
System Information
https://pastebin.com/Pa0aFHCr