Customise Window Layout with Ardour and Openbox

Post fully complete "how to" guides and tutorials here. This is a great place to get feedback on stuff you might put in the wiki.

Moderators: MattKingUSA, khz

Post Reply
merlyn
Established Member
Posts: 660
Joined: Thu Oct 11, 2018 4:13 pm

Customise Window Layout with Ardour and Openbox

Post by merlyn »

My goal is to have Catia on Desktop 8, the Ardour editor on Desktop 9, the Ardour mixer on Desktop 10 and plug-ins on Desktop 11.

To control window placement in Openbox edit ~/.config/openbox/rc.xml. Window layout is managed in the 'applications' section, the last section in the file.

Code: Select all

<applications>

    <application>

      YOUR CONFIG
    
    </application>
    
</applications>
Windows are identified by _OB_APP properties. To find the _OB_APP properties for a window type this into a terminal :

Code: Select all

$ obxprop | grep "^_OB_APP"
The mouse pointer turns into a cross.

Click on the window you want to identify. Using Catia as an example :

Code: Select all

$ obxprop|grep "^_OB_APP"
_OB_APP_TYPE(UTF8_STRING) = "normal"
_OB_APP_TITLE(UTF8_STRING) = "Catia"
_OB_APP_GROUP_CLASS(UTF8_STRING) = 
_OB_APP_GROUP_NAME(UTF8_STRING) = 
_OB_APP_CLASS(UTF8_STRING) = "Catia"
_OB_APP_NAME(UTF8_STRING) = "catia.py"
_OB_APP_ROLE(UTF8_STRING) = 
I want a unique identifier, so I chose title = "Catia". Now add this to rc.xml to put Catia on Desktop 8 maximised :

Code: Select all

	<application	title="Catia">
     
		<desktop>8</desktop>
		<maximized>yes</maximized>
      
	</application>
Now I find out the properties of the Ardour editor :

Code: Select all

$ obxprop|grep "^_OB_APP"
_OB_APP_TYPE(UTF8_STRING) = "normal"
_OB_APP_TITLE(UTF8_STRING) = "Ardour"
_OB_APP_GROUP_CLASS(UTF8_STRING) = "Ardour-5.12.0"
_OB_APP_GROUP_NAME(UTF8_STRING) = "ardour-5.12.0"
_OB_APP_CLASS(UTF8_STRING) = "Ardour"
_OB_APP_NAME(UTF8_STRING) = "ardour_ardour"
_OB_APP_ROLE(UTF8_STRING) = 
To make sure it's a unique identifier I chose name = "ardour_ardour" and title = "Ardour" adding this to rc.xml :

Code: Select all

    <application 	name="ardour_ardour"
		              title="Ardour">
     
		  <desktop>9</desktop>
		  <maximized>yes</maximized>
  
    </application>
The mixer produces this obxprop output :

Code: Select all

$ obxprop|grep "^_OB_APP"
_OB_APP_TYPE(UTF8_STRING) = "normal"
_OB_APP_TITLE(UTF8_STRING) = "Drivin' - Mixer - Ardour"
_OB_APP_GROUP_CLASS(UTF8_STRING) = "Ardour-5.12.0"
_OB_APP_GROUP_NAME(UTF8_STRING) = "ardour-5.12.0"
_OB_APP_CLASS(UTF8_STRING) = "Ardour"
_OB_APP_NAME(UTF8_STRING) = "ardour_ardour"
_OB_APP_ROLE(UTF8_STRING) = 
The unique identifier is title, and that includes the name of the project so I use a wildcard "*" to match all mixers :

Code: Select all

	<application 	name="ardour_ardour" 
			          title="* - Mixer - Ardour">
    
		<desktop>10</desktop>
		<maximized>yes</maximized>
      
   </application>
Now to have plug-ins on Desktop 11 I'll use DrumGizmo as an example :

Code: Select all

$ obxprop|grep "^_OB_APP"
_OB_APP_TYPE(UTF8_STRING) = "dialog"
_OB_APP_TITLE(UTF8_STRING) = "MIDI: DrumGizmo (by DrumGizmo Team)"
_OB_APP_GROUP_CLASS(UTF8_STRING) = "Ardour-5.12.0"
_OB_APP_GROUP_NAME(UTF8_STRING) = "ardour-5.12.0"
_OB_APP_CLASS(UTF8_STRING) = "Ardour-5.12.0"
_OB_APP_NAME(UTF8_STRING) = "ardour-5.12.0"
_OB_APP_ROLE(UTF8_STRING) = "plugin_ui"
To put all plug-ins on Desktop 11 add this to rc.xml :

Code: Select all

	<application 	name="ardour-5.12.0" 
			          role="plugin_ui">
     
		<desktop>11</desktop>
		<layer>normal</layer>

	</application>
A lot more could be done with plug-ins, putting specific plug-ins on specific desktops, or types of plug-ins (instruments, insert effects, send effects) on specific desktops.

Now here is the whole config. You can copy and paste this as a starting point for your own customisations :

Code: Select all

	<application	title="Catia">
     
		<desktop>8</desktop>
		<maximised>yes</maximised>
      
	</application>

	<application 	name="ardour_ardour"
			title="Ardour">
     
		<desktop>9</desktop>
		<maximized>yes</maximized>
      
    	</application>

	<application 	name="ardour_ardour" 
			title="* - Mixer - Ardour">
     
		<desktop>10</desktop>
		<maximized>yes</maximized>
      
    	</application>

	<application 	name="ardour-5.12.0" 
			role="plugin_ui">
     
		<desktop>11</desktop>
		<layer>normal</layer>

	</application>

User avatar
bluebell
Established Member
Posts: 1377
Joined: Sat Sep 15, 2012 11:44 am
Location: Saarland & Frankfurt, Germany

Re: Customise Window Layout with Ardour and Openbox

Post by bluebell »

I think you can get the same results with devilspie (and gDevilspie to create rules interactively) - working for all window managers.
Linux – MOTU UltraLite AVB – Qtractor – https://soundcloud.com/suedwestlicht

mtf8
Established Member
Posts: 3
Joined: Wed Sep 26, 2018 3:18 pm

Re: Customise Window Layout with Ardour and Openbox

Post by mtf8 »

Moving to i3wm would be the move here.

merlyn
Established Member
Posts: 660
Joined: Thu Oct 11, 2018 4:13 pm

Re: Customise Window Layout with Ardour and Openbox

Post by merlyn »

Thanks @mtf8. I gave i3wm a spin and I'm now using it. The developer appears to think the same way I do in terms of what a window manager should do, and be able to do.

Openbox was a useful step for me between using the mouse a lot with KDE, and using the keyboard more with i3wm.

Post Reply