Reputation:
I am not even sure this is possible, but I am curious because it would be useful.
I have the default i3 binding mod+enter
which opens my terminal.
What I would like to do is create a binding that will open a terminal that is floating.
In other words, I need to execute terminator 2 different ways, standard and floating. I have been through the docs and have looked at many different configs, but I can't find anyone doing this (and I can't quite figure it out myself).
Any suggestions?
Upvotes: 1
Views: 3619
Reputation: 18399
Add something like this to your ~/.i3/config
(or ~/.config/i3/config
):
bindsym Mod+Shift+Enter exec terminator --role=floating
for_window [window_role="^floating$"] floating enable
The first line binds the key combination Mod+Shift+Enter to start termite
with the WM_WINDOW_ROLE
property set to "floating". By default WM_WINDOW_ROLE
is not set by terminator
, so this can be used as criterion to differentiate between normal and floating windows.
The second line will tell i3 to enable floating mode on any window that has WM_WINDOW_ROLE
set to (exactly) "floating".
This works also the same for some (all?) other vte3 based terminals, like gnome-terminal
or termite
. Other tools might provide similar command line options to change the role.
Sometimes the WM_CLASS can also be changed. In that case class
would have to be used instead of window_role
in the i3 configuration.
Upvotes: 2