WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Openbox piped menus for apps and ondemand  (Read 3777 times)

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Openbox piped menus for apps and ondemand
« on: June 23, 2016, 08:03:49 AM »
Hi there!
I see benefit in using piped menus in Openbox for generating menus for Applications and On-Demand items.
I was thinking about submitting an  openbox_mod.tcz  extension containing these changes (plus menu icons), but I figured I should first see if I get some feedback.

The main reason for this mod is that Openbox doesn't need to be restarted (this can be quite annoying since the menu disappears if opened) after every extension (containing a .desktop file) that gets loaded.

The proper way would be to modify the openbox.tcz extension, delete /usr/local/bin/openbox_* scripts, add the files attached to this post, and edit default menu.xml.

Otherwise:

Code: [Select]
cp ~/.config/openbox/menu.xml ~/.config/openbox/menu_custom.xml
~/.config/openbox/rc.xml
change
Code: [Select]
<file>menu.xml</file>
to
Code: [Select]
<file>menu_custom.xml</file>
(only needed to survive reboots)

Assuming attached scripts were downloaded to  /tmp .
Code: [Select]
sudo rm /usr/local/bin/openbox_*
sudo cp /tmp/openbox_* /usr/local/bin
cp /tmp/pipe_*.sh ~/.config/openbox

Add to ~/.config/openbox/menu_custom.xml
Code: [Select]
<menu id="apps-pipe-menu" label="Applications" execute="~/.config/openbox/pipe_apps.sh" />
<menu id="ondemand-pipe-menu" label="On Demand" execute="~/.config/openbox/pipe_ondemand.sh" />

Code: [Select]
openbox --reconfigure

Cheers!
Download a copy and keep it handy: Core book ;)