Sorry if I missed this in the docs! I looked for a bit and didn't find it.
So, some background. I like having my cursorline centered, which I do through this super basic autocmd:
vim.api.nvim_create_autocmd({ "CursorMoved" }, {
desc = "Center cursor",
command = "normal! zz",
})
This works better than vim.o.scrolloff - it's a long story. Anyways, this works great, even with help commands. Running :h a puts my cursor in the right place in the center of the screen:
But when helpview renders, the cursor suddenly isn't centered anymore:
Is there a way to run an arbitrary command after helpview renders? This would let me recenter with the new rendered doc, which would fix the issue.
Thanks!
Sorry if I missed this in the docs! I looked for a bit and didn't find it.
So, some background. I like having my cursorline centered, which I do through this super basic autocmd:
This works better than
vim.o.scrolloff- it's a long story. Anyways, this works great, even with help commands. Running:h aputs my cursor in the right place in the center of the screen:But when helpview renders, the cursor suddenly isn't centered anymore:
Is there a way to run an arbitrary command after helpview renders? This would let me recenter with the new rendered doc, which would fix the issue.
Thanks!