emacs-lsp / lsp-ui

UI integrations for lsp-mode
https://emacs-lsp.github.io/lsp-ui
GNU General Public License v3.0
1.03k stars 141 forks source link

lsp-ui-doc--hide-frame: dont clear doc buffer on hide #644

Closed kiennq closed 2 years ago

kiennq commented 2 years ago

We've already clear the doc buffer on show so no need to clear the doc buffer on hide, the webkit version is also not doing that.

Don't clear the doc buffer on hide provides another advantage when triggers lsp-ui-doc--open-markdown-link with the keyboard. In that case, there's a race condition that (point) is calculated after the doc buffer has been cleared, thus there's no link to follow. Not clear the doc buffer on hide resolve that.

kiennq commented 2 years ago

@jcs090218 I don't have merge permission on this project so you will have to merge it for me though :D

ericdallo commented 2 years ago

Just invited you @kiennq