Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The Peek Definition window is not aligned to left side when opened in a left side window of a split. #1396

Open
madcdevelop opened this issue Feb 24, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@madcdevelop
Copy link

madcdevelop commented Feb 24, 2024

Describe the bug

Repro Steps:

  1. Split the neovim window vertically.
  2. Call Peek Definition command on any symbol on the left split window.
  3. The Peek Definition window is not aligned to left side when opened in a left side window of a split.
  • When opening with no split or opening on the right side of a split the preview definition window aligns to the full size of the screen or the split.

These are my settings:

lspsaga.setup({
  ui = {
    border = "single",
    devicon = true,
    title = true,
  },
  lightbulb = {
    enable = false,
    enable_in_insert = true,
    sign = true,
    sign_priority = 40,
    virtual_text = true,
  },
  symbol_in_winbar = {
    enable = false,
    separator = " ",
    ignore_patterns={},
    hide_keyword = true,
    show_file = true,
    folder_level = 2,
    respect_root = false,
    color_mode = true,
  },
  definition = {
    width = 0.99,
    height = 0.4,
  },
})

LeftSideSplitIncorrectLocation
LeftSide2_PreviewDefinition
LeftSide_PreviewDefinition
FullScreen_PreviewDefinition
RightSide_PreviewDefinition

Steps to reproduce

use min.lua https://github.com/nvimdev/lspsaga.nvim/blob/main/test/minimal_test.lua for test
nvim --clean -u min.lua example.lua

Repro Steps:

  1. Split the neovim window vertically.
  2. Call Peek Definition command on any symbol on the left split window.
  3. The Peek Definition window is not aligned to left side when opened in a left side window of a split.

I've reproduced this in a lua file and a c and cpp file types.

Expected behavior

The Preview Definition window should open up and align to the left side of the screen on a vertical split.

Neovim version (nvim -v)

0.9.5

lspsaga commit

b1b140a

Terminal name/version

Neovide, Windows Terminal

@madcdevelop madcdevelop added the bug Something isn't working label Feb 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant