Closed perlun closed 4 years ago
I can't reproduce this on my machine at home, unfortunately. All my layouts are cycled correctly with VSCode.
Could you provide a bit more info about your environment, i.e. OS version, customized winsplit settings, etc?
Hmm, interesting! I guess it could have something to do with my extensions or vscode settings or something. I tried running now with --disable-extensions
but it didn't change anything unfortunately. My vscode settings are roughly these: https://github.com/perlun/dotfiles/blob/master/vscode/settings.json
Machine is a pretty plain Windows 10 Professional setup, nothing really special there. nVidia graphics driver.
Haven't really customized the winsplit settings so much AFAICT. I tried doing an export of it but since it's a .zip
file it's not so easy to paste here, but maybe I can attach it:
Nothing jumps out at me in your setup as the source of the issue, but I do have a hunch. VSCode has a minimum window width. If the 33% layout width is smaller than the minimum width enforced by VSCode, this will break the sequencing.
For instance, winsplit tells the window to resize to 33% width but the smallest it can be is, say, 40% width. Then when winsplit checks the window size to determine the next layout size in the sequence, nothing matches and the sequence starts from the beginning.
Can you check if this is what is happening on your setup?
Hmm, interesting! I just tried on my current machine (a Debian GNU/Linux with Cinnamon, running Quicktile) - the sequencing currently works there (which is the same machine where I have the feeling I saw it fail with Quicktile as well). And, in the narrowest mode, I'd say it's about 33%.
I guess this could possibly be version-specific on the VSCode side as well. Do you happen to know where (in the vscode code base) that this minimum window width is set?
I'm not familiar with the code base of VSCode, but searching for "minimum width" finds some interesting issues.
https://github.com/microsoft/vscode/issues/89721 https://github.com/microsoft/vscode/issues/84164 https://github.com/microsoft/vscode/issues/84134
For what it's worth, I tested my theory with an application I have that I know can only shrink down to about 41% of my monitor width and I was able to reproduce the behaviour described in the original issue. It would cycle between 50% and the minimum size.
It's easy to miss that it's not actually hitting 33% when positioning on the right of the screen because the windows left edge ends up in the correct place. However, the window actually extends off screen to the right. It would be especially tricky to spot the problem if the window size was only off by a small amount like a pixel or two.
Hi,
Thanks for keeping this nice tool alive. 🙂 I got here because I've been using the Winsplit Revolution-inspired Quicktile for my Linux work desktop for about a year, and was looking for a Windows alternative.
However, running into a very weird road bump: when trying to use Ctrl-Alt-Right to switch between 33/50/66 percent for a window, it all works fine... with one exception: with VS Code, it only switches betwen 33 and 50 percent. (!)
Even more interesting, I've actually seen instances of something similar on one of my Linux desktops with quicktile, also with VS Code (in that case, it didn't even work at all, the window was showed as a very small window or something), so it could very well be that VS Code/Electron does something funky.
Any ideas?