You are not logged in.

#1 2014-02-16 02:54:21

sheomualjy
Member
Registered: 2011-12-23
Posts: 37

Preventing backlight function keys from changing brightness

I would like to remap my backlight keys (fn + F5/F6) to use xbacklight, instead of the out-of-the-box implementation, to change the screen backlight level. This is because the default implementation does not save the backlight settings on reboot, whereas setting the backlight via xbacklight does.

If I do a simple keybinding via my window manager to run "xbacklight -inc 10" and "xbacklight -dec 10" when pressing the keys, the backlight changes twice per keypress (once from the default implementation, then again from the command). I would like to prevent the default implementation from changing the backlight so that only xbacklight changes it.

How should I go about doing this? My laptop is a Zenbook UX301LA which has acpi_video0 and intel_backlight inside /sys/class/backlight. I use the kernel parameter "acpi_osi=" in order to get the backlight keys functioning.

Offline

#2 2014-02-16 17:58:46

Rexilion
Member
Registered: 2013-12-23
Posts: 784

Re: Preventing backlight function keys from changing brightness

A file called: /usr/share/X11/xkb/symbols/inet defines these keys.

You could use something like:

xmodmap -e 'keycode 101=XF86MonBrightnessUp'

to remap those keys to other functions not affiliated with brightness and then attach those to xbacklight. But I'm not sure if it works though.


fs/super.c : "Self-destruct in 5 seconds.  Have a nice day...\n",

Offline

Board footer

Powered by FluxBB