You are not logged in.

#1 2012-10-01 15:22:24

moere
Member
Registered: 2010-02-14
Posts: 29

Openbox-highlight text, keybind command to search as location in firef

Hi there,

I use the keybinds in Openbox alot.

Is it possible to use highlighted / marked text as a variable in a keybin-command?

For example:

I want to highlight text eg: Holstenstraße, Kiel
then I want to hit a shortcut and this command to be executed:

<keybind key="W-q">
      <action name="Execute">
        <command>firefox http://maps.google.de/maps?q={the text I highligthed}</command>
      </action>
    </keybind>

Any hints or suggestions?


Greets,
moere

Offline

#2 2012-10-02 14:13:14

Stebalien
Member
Registered: 2010-04-27
Posts: 1,218
Website

Re: Openbox-highlight text, keybind command to search as location in firef

xclip

bash -c 'exec firefox http://maps.google.com/maps?q="$(xclip -o)"'

Steven [ web : git ]
GPG:  327B 20CE 21EA 68CF A7748675 7C92 3221 5899 410C
Do not email: honeypot@stebalien.com

Offline

#3 2012-10-02 14:51:23

moere
Member
Registered: 2010-02-14
Posts: 29

Re: Openbox-highlight text, keybind command to search as location in firef

Thanks!!

Offline

Board footer

Powered by FluxBB