[openbox] How can I add an arbitrary String with an associated Script/Command in the Right Click Drop Down Menu List in OpenBox WM? Also, autostart applications every session?

Mathias Dufresne mathias.dufresne at gmail.com
Mon May 22 02:45:40 EDT 2023


Hi Rajib,

Firsty, forget about the "Mr.", I have a first name ; )

I still don't understand what you want to achieve. As far as my
understanding goes, you were describing how you are doing to achieve
something but not really what you want to achieve.

Let's start from the beginning. Openbox menus can be hardcoded or
automagically generated.
Are you trying to have a piece of your Openbox menu (the one which opens
when right-clicking on the desktop background) auto-generated? You spoke
about scripts, perhaps you'd like to put all your scripts (or shortcuts to
these scripts) into some directory and you expect that each of these
scripts or shortcuts becomes a menu item in a separated sub-menu.

If you don't try to get an automated [sub]menu, scripts can be seen as
standard executable, if they are configured on your file systems with
executable bit (ie: chmod +x /path/to/your/script). Just use in that case
"<command>/path/to/your/script possible_arg1 possible_arg2</command>".

Cheers,

mathias

Le sam. 20 mai 2023 à 14:19, <u34 at net9.ga> a écrit :

> "Susmita/Rajib" <bkpsusmitaa at gmail.com> wrote:
>
> > My dear illustrious Team Leaders and Senior members of openbox ML,
> >
> > A simple query.
> >
> > I have a working debian-menu reflecting the stored menu file in
> > /var/lib/menu-xdg/menus/debian-menu.menu
> >
> > I read the page http://openbox.org/wiki/Help:Menus.
> >
> > Searching the internet, I tired to add a menu in extraScripts.xml in
> > ~/.config/openbox/. But failed to have it displayed upon right click
> > with $sudo update-menus.
> >
> > -------------------Begin Lines----------------------
> >    <menu id="extras" label="ExtraScripts">
> >       <menu id="my-scripts-menu" label="My Scripts">
> >          <item label="My Script">
> >             <action name="Execute">
> >                # <command>~/my_script.sh</command>
> > <command>true</command>
> >             </action>
> >          </item>
> >       </menu>
> >    </menu>
> > -------------------Begin Lines----------------------
> >
> > Right clicking on the desktop I find
> > /var/lib/menu-xdg/menus/debian-menu.menu being executed and the right
> > click drop down menu, sub-menu list appearing.
> >
>
> I have only superficial acquaintance with openbox.
>
> Where is that action binds to a mouse button? I would first try with a
> constant, meaningles, string. Just to see that part is working. It looks
> to me the simpler part of what you want.
> Basically, I guess that having open box do what you want is more
> complicated
> than what you imagine. You need openbox to read the output of your
> script.
> It could be you should look at openbox pipe capability.
> http://openbox.org/wiki/Help:Menus . I am not familair with that either.
>
> I hope that help. I am more guessing than writing out of knoweldge.
>
> --
> u34
>
> > I want to add my personal scripts in this list.
> >
> > I also want to autostart some applications upon every session.
> >
> > How to achieve these objectives?
> >
> > Best wishes,
> > Rajib B
> > _______________________________________________
> > openbox mailing list
> > openbox at icculus.org
> > http://icculus.org/mailman/listinfo/openbox
> _______________________________________________
> openbox mailing list
> openbox at icculus.org
> http://icculus.org/mailman/listinfo/openbox
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://icculus.org/pipermail/openbox/attachments/20230522/8c65eb90/attachment.htm>


More information about the openbox mailing list