0

I'm on Lunarvim and I can check the line diagnostic with gl. But I don't know how to go there with the cursor and copy the text, the mouse doesn't work either.

Axeltherabbit
  • 680
  • 3
  • 20
  • 1
    I haven't used lunarvim, but maybe the diagnostic popup window is set to be non-focusable. So do you can not move your cursor to popup window and copy text. However, you can try command `lua vim.diagnostic.setqflist()`, which should populate your quickfix list with diagnostic and you can copy from there. – jdhao Oct 18 '22 at 02:23
  • Yes, thanks it works, you can add it to the answers if you want – Axeltherabbit Oct 19 '22 at 08:51

2 Answers2

4

It is likely that the diagnostic popup window is set to be non-focusable. So you can not move your cursor to the popup window and copy text. However, you can try command lua vim.diagnostic.setqflist(), which should populate your quickfix list with diagnostic and you can copy from there.

jdhao
  • 24,001
  • 18
  • 134
  • 273
0

You can change the diagnostic popup window to focusable by passing { focusable = true } to lua vim.diagnostic.open_float()

Docs for vim.diagnostic.open_float

The options for vim.diagnostic.open_float is the same as vim.diagnostic.open_floating_preview

Docs for vim.diagnostic.open_floating_preview