Getting special keys to work

Andre Rodovalho andre.rodovalho at gmail.com
Tue Apr 29 19:13:13 UTC 2014


On lubuntu-rc.xml I do:

<keybind key="XF86Display">
      <action name="Execute">
        <command>lxrandr</command>
      </action>
    </keybind>

*lxrandr* deals with additional monitors, you just enable them an apply.

I'm not sure what commands you can execute to sleep and hibernate, but you
can control radio with *rfkill*. I'm not sure if those commands really
require root access, but on that case you can do a: *gksu command*

Hope that helps! To test the shortcuts without restarting all the system
you can restart only openbox: *openbox --restart*


2014-04-28 22:03 GMT-03:00 Israel <israeldahl at gmail.com>:

> On 04/28/2014 07:48 PM, John Hupp wrote:
> > I was trying to watch Netflix on a laptop (with Lubuntu) connected to
> > a TV by S-Video connection.  I found out that Fn-F7 was not working to
> > select the external VGA or S-Video displays.
> >
> > Subsequently I found that Fn-F4 does not put the laptop to sleep, and
> > Fn-F5 does not toggle the WiFi radio on/off.  (The other common
> > special keys work OK.)
> >
> > So I'm trying to get those keys working that way via entries in
> > lubuntu-rc.xml.
> >
> > With 'xev -event keyboard' I found out that Fn-F7 produces the keysym
> > 'XF86Display' but I still need to know what command to bind that to.
> > So that's my first question.
> >
> > Fn-F4 and Fn-F5 does not produce any keysym's, so I'm currently at a
> > loss for how to proceed next with those.
> >
> >
> Hi,
>
> you can use arandr to make a shell script to switch the display to a
> certain mode.  Plug in the monitor and use arandr to make a setup you
> want, and save that.  Then open your config file for openbox and set
> the keyboard shortcut for your display key (i.e. XF86Display)
> to execute the
> <command>
> /bin/bash /path/to/scriptname.sh
> </command>
> while scriptname.sh is whatever you saved the setup as with the correct
> path.
>
> arandr is a front-end for xrandr.  So the script is actually using
> xrandr to modify your display settings.
>
> I hope this helps.
>
> --
> Regards
>
>
> --
> Lubuntu-users mailing list
> Lubuntu-users at lists.ubuntu.com
> Modify settings or unsubscribe at:
> https://lists.ubuntu.com/mailman/listinfo/lubuntu-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/lubuntu-users/attachments/20140429/1d3788a8/attachment.html>


More information about the Lubuntu-users mailing list