Ubuntu F7 & F8 brightness work only under Ubuntu, not Windowmaker or Xfce

When using “Ubuntu” or “Ubuntu on Xorg” as my window manager running on Ubuntu (duh), F7 & F8 work fine to control the screen’s brightness. They don’t work under WindowMaker or Xfce (haven’t installed others to try.)

Volume control (F1-F3) seem to work fine under xfce.

Searching the forums only got me some Windows issues. Is this a known problem with some Linux WMs?

The shortcuts probably aren’t bound by default. You’ll have to go into the settings and set the commands manually (look into brightnessctl, for example).

1 Like

Hey, another Window Maker user! :slightly_smiling_face:

For most people using the common desktop environments, the desktop environment reacts to the brightness keys to adjust the brightness. Same goes for volume controls. Window Maker doesn’t do any of this, it just makes windows and assumes you’ll use other software to handle that stuff.

On my own system I’ve configured acpid to handle volume and brightness. That way the controls work regardless of whether I’m in Window Maker, or on the console, or not even logged in yet, or whatever. But you could use any sort of hotkey daemon to do it instead if you’d rather configure it that way.

I don’t know why xfce is handling volume but not brightness for you.

I have a couple scripts that do this for me right now. I’m not sure which method Ubuntu’s default WM uses, its just bound inputs to those keys. I have found sometimes mine work and sometimes they dont (XFCE in Slackware-current). Here are two methods i’ve used, see if they manually work for you, and if so, you can rebind. Also, better would be, to boot into the WM that works as expected and check what it uses. I’d be curious. I have had the best luck sticking with one method. I found if I set with xrandr, xbackground stops working well. I had to install xbackground, there is also xbacklight that wasn’t working for me, but you can try it. Let me know if these work for ya.
Edit: (I realize this doesn’t answer your question about what they hotkey is doing, but you should be able to find that in the settings of the working WM, and replicate that in another. As the below command doesn’t increment, just sets the value.)

bash-5.1$ cat setBrightnessGood.sh
#!/usr/bin/env bash 
### xbrightness <backlight 0-65535> <gamma 0-10> 
## 30035 for low, 65000 for high, 65535 should be "max"
xbrightness 65000 1.5 
### xrandr | grep " connected" 
### anything over 1 increases gamma. 1 should be max brightness but you can ++
#xrandr --output eDP-1 --brightness 1
1 Like

note that brightness events are handled by the HID event driver for display brightness, but volume up,down,play,pause are standard key scan codes from the keyboard controller.

1 Like