Closed QiangF closed 2 years ago
This is just how i3's window swallowing works. The only way to force it to swallow a previously existing window from another workspace is to unmap and remap the window on that workspace. i3-resurrect does this when you do a layout restore. So you could force a swallow by going to workspace 2 and restoring an empty layout profile. But why aren't you just restoring a layout on workspace 1 before opening the window? Or why are you moving the window to workspace 2 after restoring the layout? If you want it back on workspace 1, you could also just move it back to workspace 1 yourself then restore the layout there.. And if you don't want new copies of the program to be launched, just use --layout-only
as I said on your other issue (did you read the README?)
If you really want, you could also write a very simple script that restores an empty profile to every workspace, thus triggering all of their windows to be swalloved by a matching placeholder.
Isn't this supposed to help make things more automated. I have tried --layout-only. Thanks!
Yes, and it does, but it isn't magic. If you don't like how i3 window swallowing works you can feel free to open an issue on the i3 repo. Otherwise, feel free to use the workaround I suggested.
Steps to reproduce the behavior:
Result The Emacs window is not brought back from workspace 2, instead a new Emacs window is open, and a blank placeholder of the old Emacs window is left in workspace 1.
If this is the expected behavior, only layout on one workspace can be restored, it is not very useful.
Expected behavior The original Emacs window on workspace 2 is brought back from workspace 2.