<div dir="ltr">This is a symptom of "factory windows". spawnOn can't work for them, you need to find out the application-specific way to attach distinct identifiers to windows, because _NET_WM_PID will never match for any but the first window opened (and sometimes not then). And no, neither spawnOn nor any similar mechanism will be able to find a "fix",, because "application specific" — and even then not every application bothers to provide a mechanism to label specific windows.</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, Nov 2, 2019 at 5:39 AM Adam Sjøgren <<a href="mailto:asjo@koldfront.dk">asjo@koldfront.dk</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"> Hi,<br>
<br>
I'm using spawnOn in my startupHook to open various programs on various<br>
virtual desktops when logging in - it's quite nice to have that happen<br>
automatically.<br>
<br>
I start two instances of the Nautilus (file manager) fork Nemo:<br>
<br>
spawnOn "7" "nemo ~/video/"<br>
spawnOn "7" "nemo ~/video/tablet/"<br>
<br>
But only one of them ends up on desktop 7. The one other is placed on<br>
the current desktop.<br>
<br>
I have tried adding a "sleep 2;" to one of them, to see if it was some<br>
timing thing, but the same thing happens.<br>
<br>
I have also tried to combine them, and have one line starting "nemo<br>
~/video/" nemo ~/video/tablet/", same thing.<br>
<br>
Oh, and as I am typing this, I realize that the second invocation<br>
probably doesn't start a lasting separate process, but messages the<br>
first to open a new window, and that original process then opens it,<br>
might be why spawnOn seems to "not work".<br>
<br>
Maybe I should just use manageSpawn to have all Nemo windows end up on<br>
desktop 7.<br>
<br>
I guess I have rubber ducked myself into the answer, but any comments<br>
are welcome regardless.<br>
<br>
Best wishes,<br>
<br>
Adam<br>
<br>
-- <br>
"Please don't "meh" the panopticon. You are Adam Sjøgren<br>
not making things better by doing that." <a href="mailto:asjo@koldfront.dk" target="_blank">asjo@koldfront.dk</a><br>
<br>
_______________________________________________<br>
xmonad mailing list<br>
<a href="mailto:xmonad@haskell.org" target="_blank">xmonad@haskell.org</a><br>
<a href="http://mail.haskell.org/cgi-bin/mailman/listinfo/xmonad" rel="noreferrer" target="_blank">http://mail.haskell.org/cgi-bin/mailman/listinfo/xmonad</a><br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>brandon s allbery kf8nh</div><div><a href="mailto:allbery.b@gmail.com" target="_blank">allbery.b@gmail.com</a></div></div></div></div></div>