The i3 FAQ has migrated to https://www.reddit.com/r/i3wm/. All content here is read-only.

# how to make the new window popout from the workspace where it is called

For example, What I wish to achieve is that, if i type gvim & enter in a terminal located in workspace 5 and immediately switched to workspace 6. gvim should pop out in workspace 5. Currently, without the desired function, gvim is created in workspace 6.

This is a general configureation for all windows. therefore, transfering the window with particular name or class to specific workspace does not work for me:

https://faq.i3wm.org/question/2135/op...

This method is quite useful to separate the projects I am working into different workspaces. Every time I finish project 1 input in workspace 1 and expect new windows comming in 10 minutes, I can switch to workspace 2 and work on project 2. Currnetly, without the desired function, all the new windows associated with project 1 will appear at workspace 2 (sincei am working on that during the 10 min waiting), mixing up windows associated with project 2, and vise versa.

Thanks

edit retag close merge delete

Sort by » oldest newest most voted

This is a very partial solution, but I've been doing this for some very slowly starting applications. If you want this to work only for a specific window type (gvim), you can create a json layout somewhere:

{
"name": "gvim will be here one day",
"swallows": [
{
"class": "????",
"instance": "????",
"window_role": "????"
}
],
"type": "con"
}


where you have to figure out yourself what to replace ???? with, using for instance xprop. You can also skip some of the properties. Then whenever you want to run gvim, you have to:

1. Call i3-msg "append_layout /full_path_to/your_layout_file" to load the layout.
2. Run gvim.

The hope is the when gvim eventually starts, its window is consumed by the loaded layout.

Downsides:

• The layout window is loaded on the top level of the current workspace, not where the focus currently is. I can imagine someone automatically moving the layout window to the scratchpad and then immediately back to where the focus is. This seems doable, but would require more work.

• If your application has an unpredictable number of windows, you should probably move them automatically to the scratchpad and then write a script that moves them back to the the proper workspace (once it gets focused, I don't think you can do this before). This would require way more scripting and in particular subscribing to i3 events!

more

This already works in i3, but only if the application supports the startup notification protocol. You should file a feature request against them to support it.

more

I have not noticed this behaviour anywhere, yet. Could you please give an example for applications supporting this feature for me to test this? Thank you.

( 2015-06-23 08:37:13 +0000 )edit

Eclipse, for example, does it.

( 2015-06-23 14:17:01 +0000 )edit
( 2015-06-23 14:17:29 +0000 )edit