make float auto close configurable#1551
Conversation
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
1 similar comment
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
|
Thank you for the PR. The idea of making CursorHold float close behavior configurable is useful, but I think there is a bug in the current implementation. The The fix should only affect let s:Dispose = lsp#callbag#pipe(
\ lsp#callbag#merge(
\ lsp#callbag#pipe(
\ lsp#callbag#fromEvent(['CursorMoved']),
\ lsp#callbag#tap({_->s:hide_float()}),
\ ),
\ lsp#callbag#pipe(
\ lsp#callbag#fromEvent(['CursorHold']),
\ lsp#callbag#filter({_->g:lsp_diagnostics_float_close_on_hold}),
\ lsp#callbag#tap({_->s:hide_float()}),
\ ),
\ lsp#callbag#pipe(
\ lsp#callbag#fromEvent(['InsertEnter']),
\ lsp#callbag#filter({_->!g:lsp_diagnostics_float_insert_mode_enabled}),
\ lsp#callbag#tap({_->s:hide_float()}),
\ )
\ ),
\ lsp#callbag#filter({_->g:lsp_diagnostics_float_cursor}),
\ lsp#callbag#debounceTime(g:lsp_diagnostics_float_delay),This way |
Some diag message may be long that close on CursorHold (updatetime) is not desirable.