lsp-ui icon indicating copy to clipboard operation
lsp-ui copied to clipboard

Wrong key bindings in LSP UI flycheck <M-return> <return>

Open farazshaikh opened this issue 4 months ago • 1 comments

RET and return are different keys in emacs. Binding such a M- don't work if emacs is in terminal mode.

For bindings to work both in terminal and UI. The correct binding is RET and M-RET

https://github.com/emacs-lsp/lsp-ui/blame/bc58c6664577d1d79060c6b32b7ad20e70ee19d0/lsp-ui-flycheck.el#L158 (let ((map (make-sparse-keymap))) (define-key map (kbd "q") 'lsp-ui-flycheck-list--quit)

  • (define-key map (kbd "") 'lsp-ui-flycheck-list--view) -(define-key map (kbd "<M-return>") 'lsp-ui-flycheck-list--visit)
  • (define-key map (kbd "<RET>") 'lsp-ui-flycheck-list--view) -(define-key map (kbd "<M-RET>") 'lsp-ui-flycheck-list--visit)

https://www.fromkk.com/posts/c-m-ret-and-return-key-in-emacs/

farazshaikh avatar Mar 02 '24 00:03 farazshaikh