Invoke Openbox's Menu with xdotool
Something I wanted to do with my Openbox install was to call the main Openbox menu from my instance of tablaunch. I wanted to do this as it's not always easy/possible to find and area of the desktop to right-click on, especially when operating on a small screen with maximised windows.
As luck would have it, somebody had already found a solution for this and published details about it on the Arch Linux wiki. The solution involves installing a small utility called xdotool. There's no package for xdotool in the Ubuntu repositories, so I've created one and placed it in the CrunchBang Linux repository.
For future reference; follow the steps below to install xdotool and configure Openbox so that you can summon the main menu from a command:
1. Install xdotool, either from source, via the .deb file, or via the repository with the following command:
sudo apt-get install xdotool
2. Edit Openbox's rc.xml file and add the following code to the "keyboard" section:
<keybind key="A-C-q">
<action name="ShowMenu">
<menu>root-menu</menu>
</action>
</keybind>
3. Reconfigure Openbox to apply the changes, enter the following command:
openbox --reconfigure
4. Call the Openbox menu with the following command:
xdotool key ctrl+alt+q
It should now be possible to bind the menu to your favourite application launcher, such as tablaunch or wbar.

Add Your Comment
Use the form below to add your comment. Markdown syntax is available. Note, comments are moderated by me for spam filtering. Alternatively, feel free to contact me privately.