Open ilan-schemoul opened 2 days ago
Also is there a way to restore closed windows after leaving NoNeckPain mode
I think the problem is the code vim.cmd("only") is called in main.disable instead of main.enable.
However once I do that fix I have another problem: the layout is not saved. To save the window layout the very simple solution is to open a new tab and close a new tab.
However this plugin seems to not take this approach of using tabnew/tabclose.
So I just added my own solution to my code. It is actually much simpler to roll out my own solution than trying to make this plugin or any other plugin fit my workflow.
Hey @ilan-schemoul thanks for using the plugin :D
I'm not totally sure to understand what is the issue here, I tried locally and disabling the plugin with killAllBuffersOnDisable
properly kills every focused windows.
Looking at your issue description, it seems like you'd expect that enabling the plugin only keeps the focused window, right?
Oh gosh I'm so stupid. killAllBuffersOnDisable obviously kills buffer when I disable. I expected it to kill other windows on enable. I do not know how I missed that, it's embarassing haha.
What I wanted is I have two windows window A | window B
When I NoNeckPain on Window A it first kills window B. Then center window A. When I disable NoNeckPain it stops center window A and then it shows again window A | window B
As I said I created my own solutions https://github.com/ilan-schemoul/nvim-config/commit/642ebf1f587ee003ed446b75b9bc8aaa935a638e when I use tabnew and tabclose without this plugin because it does what I want.
Description
killAllBuffersOnDisable = true I have two windows. I doz one time nothing happens. Second time right pane is closed. Third time I enter finally in NoNeckPain mode (window centered).
https://asciinema.org/a/PjILOtkDcZofOs1rp4RxLdG9g
Neovim version
0.9.x
Steps to reproduce
Lazy config
My repo
Relevant log output
Self-service