1

I frequently switch my windows to/from floating when using i3, either by float toggle or when I'm using scratchpad.

However, when I do this I want the borders of the windows to become larger - mainly since I want to be able to easily click the border to resize the window. I also want the border to fall back to the default size when they return to tiling mode.

So far, I have only found a way to define the border size for windows that automatically float, and if I toggle them the borders do not go back to the default size.

Is there any way to do this in i3?

Lucas
  • 121

1 Answers1

2

You can use for_window with tiling_from and floating_from criteria in order to create separate rules for floating and tiling windows (see for_window and command criteria for more details). Usually I don't use this configuration, but it seems like putting this in the i3 config file works fine:

for_window [tiling_from="user"] border pixel 1
for_window [tiling_from="auto"] border pixel 1
for_window [floating_from="user"] border pixel 5

By doing so you'll get 1px border for tiling windows and 5px border for windows you make floating.

Note, that for some reason, using for_window [tiling] is not working in this case.