The i3 FAQ has migrated to https://github.com/i3/i3/discussions. All content here is read-only.
Ask Your Question
0

Opening program in scratchpad without focus

asked 2015-11-05 10:36:07 +0000

cancarne gravatar image

I wish to open vlc as floating in scratchpad, but not focusing it :

for_window  [class="vlc"] floating enable;  [class="vlc"] move position 300px 200px; [class="vlc"] move scratchpad; [class="vlc"] scratchpad show; focus tiling;

focus tiling should focus back to tiling windows. Instad vlc remains focused when opened. Effect is the same with or without "focus tiling". Any ideas ?

edit retag flag offensive close merge delete

Comments

for_window [class="(?i)^vlc$"] floating enable, move position 300px 200px, move scratchpad, scratchpad show, exec sleep 1 && i3-msg focus tiling

Anon1234 gravatar imageAnon1234 ( 2015-11-05 15:05:58 +0000 )edit

Works great, thanks ! So some pause is needed for vlc to "fully open", i guess ... Solved !

cancarne gravatar imagecancarne ( 2015-11-05 20:42:44 +0000 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2015-11-05 19:51:11 +0000

Airblader gravatar image

As Anon1234 pointed out in the comment, you should just put all commands together:

for_window [class=(?i)vlc] floating enable, move position 300 200, move scratchpad, scratchpad show

As for not focussing the window, you can use

no_focus [class=(?i)vlc]

in your config.

edit flag offensive delete link more

Comments

For some strange reason no_focus gives me an error. That is the first thing i tried : no_focus [class="vlc"] , which i saw in i3 guide.

cancarne gravatar imagecancarne ( 2015-11-05 20:55:15 +0000 )edit

What error? Do you have a current version of i3?

Airblader gravatar imageAirblader ( 2015-11-05 21:30:11 +0000 )edit

Oh, sorry, i have version 4.8. Will check 4.11. Cheers ! :)

cancarne gravatar imagecancarne ( 2015-11-08 03:02:01 +0000 )edit

Question Tools

1 follower

Stats

Asked: 2015-11-05 10:36:07 +0000

Seen: 70 times

Last updated: Nov 05