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

Different layout an a specified workspace

asked 2013-09-24 16:01:07 +0000

uzsolt gravatar image

I'm using workspace_layout tabbed and it's good in most cases. But on workspace dox I would need splith (I'm run a specified urxvt with vim and edit LaTeX documents and I need zathura on right to view my document).

I thought I can do with the following code:

mode "terminal" {
    bindsym d exec urxvt-config dox; workspace dox;layout splith; mode default
    ... other specified terminals ... 
}
bindsym $winkey+x mode terminal

I thought it runs urxvt with correct config (it's OK, urxvt-config is an own script, works well), change current workspace to dox (it's OK), set its layout to splith (it's NOT OK).

Is there any workaround or what do I wrong?

edit retag flag offensive close merge delete

1 answer

Sort by » oldest newest most voted
0

answered 2013-09-25 16:18:52 +0000

Michael gravatar image

updated 2013-09-25 16:19:14 +0000

You don’t do anything wrong, but unfortunately you are hitting an implementation detail here: workspace_layout triggers whenever a new window gets opened at workspace level. That means, after your layout splith, the new window is opened and afterwards, the workspace_layout kicks in.

As a workaround, you could use i3-exec-wait (search the FAQ) and send your layout command(s) after the window was opened.

edit flag offensive delete link more

Comments

Oh, understand. But I've a simplier workaround: a small script with a 1-2 seconds delay, call i3-msg and that's all. And in my config `bindsym d exec urxvt-config dox; workspace dox;layout splith; mode default` will `bindsym d exec urxvt-config dox; workspace dox;i3-wait layout splith; mode default`

uzsolt gravatar imageuzsolt ( 2013-09-26 08:49:34 +0000 )edit

Sorry, `exec i3-wait layout splith` (I can't edit my comment).

uzsolt gravatar imageuzsolt ( 2013-09-26 08:52:38 +0000 )edit

Question Tools

Stats

Asked: 2013-09-24 16:01:07 +0000

Seen: 1,005 times

Last updated: Sep 25 '13