Fildo7525/pretty_hover

[Bug] No border visible

lars-vc opened this issue · 8 comments

I use the default options, but I don't see a border:
image

How I installed:
image

Can you try branch i#3-no-border branch to check if it helped? I created a dummy file and after this change, it started working. If not could you post here a function and its comment?

It didn't show a border, here is a javascript function and its popup

 /**
 *  Send current state and update using backend, for popup
 *  @param {function} sendResponse the function that sends the response to the requester
 */
export async function requestSmallState(sendResponse) {
    // TODO: This should also request the backend to get all the infosrcs of this user and see if the list is outdated
    // NOTE: could maybe form this into 1 storage request
    const information_sources = (
        await chrome.storage.session.get(["information_sources"])
    ).information_sources;
    const state_changed = (
        await chrome.storage.session.get(["small_state_changed"])
    ).small_state_changed;
    const folders = (await chrome.storage.session.get(["folders"])).folders;

    sendResponse({
        infosrcs: information_sources,
        changed: state_changed,
        folders: folders,
    });
    // Only update the store if a changed state is sent, to avoid race conditions + it would be a pointless operation
    if (state_changed) {
        await chrome.storage.session.set({
            small_state_changed: false,
        });
    }
}

image

Screenshot from 2023-04-10 16-55-07
I have just tried it and something must be wrong besides the plugin. Did you set up the 'textDocument/hover' in lspconfig?

vim.lsp.handlers["textDocument/hover"] = vim.lsp.with(vim.lsp.handlers.hover, {
 	border = "rounded",
})

Did you try adding this to your config? If yes and it helps I will include it in the setup function. I think that I can include it there because if you use this plugin the chance of using native hover or another hover plugin at the same time is not so big.

Very strange, even with this the border is not being rounded, gotta be something in my config that prevents it.

	use({
		"Fildo7525/pretty_hover",
		opt = true,
		module = "pretty_hover",
		config = function()
			vim.lsp.handlers["textDocument/hover"] = vim.lsp.with(vim.lsp.handlers.hover, {
				border = "rounded",
			})
		end,
	})

Try putting the hover setup to lspconfig setup function.
EDIT: You do not call the setup function.

image
I moved it into my on_attach function (I presume you meant that) and still no difference?

I have figured out the issue, I was not calling the setup function, but without it, it still works to a degree, showing with window as seen above.