AudioRaiseVolume and AudioLowerVolume do not trigger anymore


#1

Hello, I have this weird issue that just popped out of nowhere. In the OpenBox Keybind settings, AudioRaiseVolume is connected to [pamixer -i 2] and respectively AudioLowerVolume to [pamixer -d 2]. This was the default setting and worked out fine. But suddenly it doesn’t work anymore (volume won’t change). Whats weird though is, that all other Fn Key combinations work (like Fn+F8 to mute, or resume/pause combination). What is even weirder though is, that trying to make a new keybind with the exact same keycombination works (I can add it and it detects the keycombination in the keybind menu, but still the audio won’t get raised). When I link pamixer -i 2 to another keybind (like Alt+K) it works and the volume increases. So it’s not my keys that are broken. Running pamixer -i 2 inside terminal also works and increases volume. This is weird and I am really unsure how to fix this.
Thanks in advance,


#2

There are two Keybind menues, one from OpenBox and another one from the settings menu. The 2nd is literally called “Keyboard” and when I try to add the keybind there (XFCE86AudioRaiseVolume or similar) it works so I guess it is something OpenBox related?


#4

Bump for the op here, can t help him concerning his issues. If someone here can be of any help it would be appreciated. Thx .

Wonder if it only happened after an update or that it has nothing to do with it. Sometimes weird things happen after some updates.


#5

I noticed before doing system update that it wasn’t working, however running pamixer -i 2 would give me some clear errors about missing boost libraries (I had updated boose beforehand seperately). Then I did the full system update and It still didn’t work with keybinds, but changing the volume with the command works (no boost library errors)…


#6

This is weird, maybe someone will chim in in order to give you a hand here.


#7

The actual keysyms are XF86AudioRaiseVolume

All the keybinds related to these type of ‘special’ keys will have the same XF86....

Please post the related section of your openbox rc.xml.


#8

Can you elaborate on this a bit more?


#9

The right one is the obkey-configurator. Notice that all the audio-related keybinds have XF86… keys, except for raise and lower volume. In fact, when I manually edit the rc.xml and write XF86AudioRaiseVolume instead of just AudioRaiseVolume, it seems to work. However this is really strange, because when I try to set the keybind with obkey, I will get asked to enter the keycombination (literally press it on my keyboard). Doing so will trigger “AudioRaiseVolume” instead of “XF86AudioRaiseVolume”.

Furthermore I tried changing other keybinds with special keys (like Audio Play and Stop). Trying those will yield AudioStop instead of XF86AudioStop. I suspect that after saving, I wouldn’t be able to Stop/Resume audio either, but I won’t try.

tl;dr: I solved this issue by changing AudioRaiseVolume to XF86AudioRaiseVolume in the rc.xml, however it still seems to be a bug.


#10

I see, ok well at least we got it sorted out.

This is likely a bug in obkey, I have fixed issues and made PRs to it before to I wouldn’t be surprised.

Seems like a simple override would do the trick, would you mind testing perhaps?

Go to /usr/lib/python2.7/site-packages/obkey_classes.py and change the replace_table_gtk2openbox dictionary at lines 82-95 to:

replace_table_gtk2openbox = {
  "Mod1" : "Mod1",
  "Mod2" : "Mod2",
  "Mod3" : "Mod3",
  "Mod4" : "Mod4",
  "Mod5" : "Mod5",
  "Control" : "C",
  "Primary" : "C",
  "Alt" : "A",
  "Meta" : "M",
  "Super" : "W",
  "Shift" : "S",
  "Hyper" : "H",
  "AudioRaiseVolume" : "XF86AudioRaiseVolume",
  "AudioLowerVolume" : "XF86AudioLowerVolume"
}

If it works and add’s the key correctly to the rc.xml then we can add other exceptions like AudioStop etc. Then I can make a pull request to have it fixed upstream.


#11

Adding the last two codelines, as well as trying to set the keybinds again (trough obkey-menu and pressing the audio keybinds) results in the same image I uploaded last time (AudioRaiseVolume instead of XF86). Saving disabled the functionality again.

The respective rc.xml entries are

<keybind key="AudioRaiseVolume">
  <action name="Execute">
    <command>pamixer -i 2</command>
  </action>
</keybind>
<keybind key="AudioLowerVolume">
  <action name="Execute">
    <command>pamixer -d 2</command>
  </action>
</keybind>
<keybind key="XF86AudioMute">
  <action name="Execute">
    <command>pamixer -t</command>
  </action>
</keybind>
<keybind key="XF86AudioStop">
  <action name="Execute">
    <command>playerctl stop</command>
  </action>
</keybind>
<keybind key="XF86AudioPlay">
  <action name="Execute">
    <command>playerctl play-pause</command>
  </action>

and so on ...

note that the XF86 ones like mute Audio were not changed, only raise and lower volume.


#12

Ok no worries, I had to install and figure it out.

The solution can be found in the PR I just opened