nyngwang / NeoZoom.lua

A simple usecase of floating window to help you focus.
MIT License
184 stars 15 forks source link

Can't get window to center? #85

Closed Integralist closed 1 year ago

Integralist commented 1 year ago

This is my config...

{
    "nyngwang/NeoZoom.lua",
    config = function()
        require('neo-zoom').setup({})
        vim.keymap.set("", "<leader><leader>z", "<Cmd>NeoZoomToggle<CR>", {desc = "full screen active window"})
    end
}

But this is how the zoomed window is displayed?

Screenshot 2023-10-05 at 08 00 26

Any ideas what I might be doing wrong?

Thanks!

niderhoff commented 1 year ago

the default config sets an offset (compare readme). You might want to change that.

Integralist commented 1 year ago

Hi @niderhoff

Setting left = 0 did the trick...

require('neo-zoom').setup({
    winopts = {left = 0, width = 150, height = 0.80}
})