diff options
| author | William Boman <william@redwill.se> | 2022-12-02 19:16:05 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-12-02 18:16:05 +0000 |
| commit | 22129c714fcb0acd2cebba77980e6461a2c69d6b (patch) | |
| tree | dc90c973593f9008885c0356448575324f817a4b /lua/mason-core/ui/display.lua | |
| parent | feat(ui): change log line number formatting in tail output (#718) (diff) | |
| download | mason-22129c714fcb0acd2cebba77980e6461a2c69d6b.tar mason-22129c714fcb0acd2cebba77980e6461a2c69d6b.tar.gz mason-22129c714fcb0acd2cebba77980e6461a2c69d6b.tar.bz2 mason-22129c714fcb0acd2cebba77980e6461a2c69d6b.tar.lz mason-22129c714fcb0acd2cebba77980e6461a2c69d6b.tar.xz mason-22129c714fcb0acd2cebba77980e6461a2c69d6b.tar.zst mason-22129c714fcb0acd2cebba77980e6461a2c69d6b.zip | |
feat(ui): increase window height (#719)
Diffstat (limited to 'lua/mason-core/ui/display.lua')
| -rw-r--r-- | lua/mason-core/ui/display.lua | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/lua/mason-core/ui/display.lua b/lua/mason-core/ui/display.lua index f59d0952..b98b37ee 100644 --- a/lua/mason-core/ui/display.lua +++ b/lua/mason-core/ui/display.lua @@ -170,15 +170,15 @@ M._render_node = render_node ---@param opts WindowOpts ---@param sizes_only boolean Whether to only return properties that control the window size. local function create_popup_window_opts(opts, sizes_only) - local win_height = vim.o.lines - vim.o.cmdheight - 2 -- Add margin for status and buffer line - local win_width = vim.o.columns - local height = math.floor(win_height * 0.9) - local width = math.floor(win_width * 0.8) + local columns = vim.o.columns + local top_offset = 1 + local height = vim.o.lines - vim.o.cmdheight - top_offset + local width = math.floor(columns * 0.8) local popup_layout = { height = height, width = width, - row = math.floor((win_height - height) / 2), - col = math.floor((win_width - width) / 2), + row = top_offset, + col = math.floor((columns - width) / 2), relative = "editor", style = "minimal", zindex = 45, |
