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

Do not apply sidescrolloff to DressingInput #75

Closed
chrisgrieser opened this issue Dec 4, 2022 · 2 comments
Closed

Do not apply sidescrolloff to DressingInput #75

chrisgrieser opened this issue Dec 4, 2022 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@chrisgrieser
Copy link
Contributor

Describe the bug
when you have a higher sidescrolloff value, this leads DressingInput to not using the entire width of the input window.

for the DressingInput window, sidescrolloff should be disabled or set to 0.

To Reproduce
Steps to reproduce the behavior:

  1. set vim.opt.sidescrolloff = 30
  2. run LSP rename (or anything else triggering dressing input)
  3. fill a lot of characters

Additional context
this fixed it for me

augroup("dressing", {})
autocmd("FileType", {
	pattern = "DressingInput",
	group = "dressing",
	command = "setlocal sidescrolloff=0",
})
@stevearc
Copy link
Owner

stevearc commented Dec 5, 2022

I've refactored the config to allow passing in any window options you like. This should work for you now:

require("dressing").setup({
  input = {
    win_options = {
      sidescrolloff = 0,
    },
  },
})

@chrisgrieser
Copy link
Contributor Author

thanks for the quick fix, works fantastic. 🙂

fnichol added a commit to fnichol/dotneovim that referenced this issue Dec 6, 2022
References: stevearc/dressing.nvim#75

Signed-off-by: Fletcher Nichol <fnichol@nichol.ca>
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

2 participants