WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Start graphical program on defined workspace  (Read 2076 times)

Offline mindmachine

  • Newbie
  • *
  • Posts: 45
Start graphical program on defined workspace
« on: July 30, 2013, 03:12:47 PM »
Hi!

Still using this fine os, meanwhile for two Thinclients, but will get more soon :-).

Is there a way to start a program on a defined workspace via an entry in .X.d.? Like start prog1 on workspace one and prog2 on workspace two at boot ? (It's two different rdesktops autostarting at boot up, so my wife won't get too confused...). I know, compiz can do this, but I couldn't find a solution by searching the forum, maybe I took the wrong keywords?

Thanks for your help!

mindmachine
------------------------------------------------------------
mindmachine

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11050
Re: Start graphical program on defined workspace
« Reply #1 on: July 30, 2013, 03:18:20 PM »
Completely depends on which WM you use.
The only barriers that can stop you are the ones you create yourself.

Offline mindmachine

  • Newbie
  • *
  • Posts: 45
Re: Start graphical program on defined workspace
« Reply #2 on: July 30, 2013, 03:24:32 PM »
Sorry, you're right. I'm using fluxbox and xorg
------------------------------------------------------------
mindmachine

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11050
Re: Start graphical program on defined workspace
« Reply #3 on: July 30, 2013, 05:30:52 PM »
Check out xdotool and wmctrl. Both should work with fluxbox.
The only barriers that can stop you are the ones you create yourself.

Offline mindmachine

  • Newbie
  • *
  • Posts: 45
Re: Start graphical program on defined workspace
« Reply #4 on: August 23, 2013, 04:07:10 PM »
Okay, I tried xdotool by using the following script in ~/.X.d:
Quote
rdesktop "parameters"
xdotool key Control_L+F2
sleep 3 #(just in case :-))
rdesktop "parameters II"
xdotool key Control_L+F1 # turn back to workspace one
Unfortunately both desktops open on workspace 2.
That one behaves the same:
Quote
rdesktop "parameters"
sleep 1
xdotool set_desktop 1 #get to desktop 2
rdesktop "parameters2"
sleep 1
xdotool set_desktop 0 '#get bacl to workspace 1
Seems like any command is send to the rdesktop window. How do I get back to my workspace?

Thanks
mindmachine
« Last Edit: August 23, 2013, 04:48:36 PM by mindmachine »
------------------------------------------------------------
mindmachine