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

floating mode bash script

asked 2015-02-17 15:57:58 +0000

mrneilypops gravatar image

updated 2015-02-17 15:58:38 +0000

Hi, Loving i3! I have a bash logout script located @ ~/logout.sh

So far, I have been unable to start it in floating mode. I have tried fiddling with this setting; for_window [class="???"] floating enable, border normal

???what do I put here?

At the moment the logout script starts fine with my 'Alt+z' keybinding but in full screen mode.

All ideas welcome. Thanks Neil

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted
0

answered 2015-02-17 21:41:24 +0000

mrneilypops gravatar image

COOL!

That works for me!

Thank you so much - i3 ROCKS!

for_window [class="Yad"] floating enable border pixel 0

Kind Regards, Neil

edit flag offensive delete link more

Comments

Welcome to the i3 FAQ. Please do not post comments or thank you notes as answers. To show your appreciation you might want to accept or upvote cee's answer.

Adaephon gravatar imageAdaephon ( 2015-02-18 07:24:57 +0000 )edit
0

answered 2015-02-17 21:04:17 +0000

cee gravatar image

Hi Neil and welcome to the forum.

What you have to put in [class="???"] depends on the window you want to match. Therefore you will need to have to find a unique feature that distinguishes your window from every other window.
You can use a little linux/unix tool called xprop to get the X properties of any window. It is probably already installed on your distro. Just type xprop in a terminal to test it.

Now you will get some information on your window such as:

...
WM_CLASS(STRING) = "urxvt", "URxvt"
...

When clicked on a simple urxvt terminal for example. (Your output includes much more information and of course the class name of the window you clicked on).

Now the interesting part:
In my example "urxvt" is the instance name and "URxvt" is the class name that you can use to match any window.
Attention the names are both case sensitive.

Most of the time a class and maybe an instance should suffice to tell your window apart from any other. But sometimes you will need more sophisticated queries. The best source for all possibilities is the i3 documentation or some real life samples from my config.

edit flag offensive delete link more

Question Tools

Stats

Asked: 2015-02-17 15:57:58 +0000

Seen: 183 times

Last updated: Feb 17