Skip to content
This repository has been archived by the owner on Jan 26, 2024. It is now read-only.

Keybinds that contain XF86* keys don't work when combined with a modifier #510

Open
Kerberoge opened this issue Nov 10, 2023 · 6 comments
Open
Labels
A: bug Something isn't working

Comments

@Kerberoge
Copy link

Info

dwl version: v0.4-69-gfc8e4a4
wlroots version: 0.16.2-2

Description

When I create a keybind that contains only a XF86* key (like XF86MonBrightnessUp) and no modifier key, the keybind works. But if I add a modifier like WLR_MODIFIER_SHIFT to the keybind containing the XF86* key, the keybind no longer works.

@Kerberoge Kerberoge added the A: bug Something isn't working label Nov 10, 2023
@djpohly
Copy link
Owner

djpohly commented Nov 10, 2023

Hi Kerberoge,

The Shift modifier tends to modify what you have to put in the keycode field as well. Try using the command xkbcli interactive-wayland to see exactly what is being sent when you press your desired key combination.

@Hiqqup
Copy link

Hiqqup commented Nov 19, 2023

Ive also wondered about this, running xkbcli interactive-wayland doesnt say anything is modified. Ive also tried doing with other Modifiers, like ctrl or logo or modkey but they all dont seem to work, let me know if should provide any further detail.

@sevz17
Copy link
Collaborator

sevz17 commented Nov 20, 2023

Hm, I get this while pressing shift+XF86MonBrightnessDown:

seat0: keycode [ LFSH ] keysyms [ Shift_L          ] unicode [   ] layout [ Spanish (Latin American) (0) ] level [ 0 ] mods [ Mod2 ] leds [ Num Lock ] 
seat0: keycode [ FK02 ] keysyms [ F2               ] unicode [   ] layout [ Spanish (Latin American) (0) ] level [ 1 ] mods [ Shift Mod2 ] leds [ Num Lock ] 

@Hiqqup, can you paste the output you get from it?

@Kerberoge
Copy link
Author

@sevz17 It seems that you have fn-lock disabled. Could you please try enabling fn-lock and running xkbcli interactive-wayland again?

@Kerberoge
Copy link
Author

Kerberoge commented Nov 20, 2023

Here's the output of xkbcli interactive-wayland:

seat0: keycode [ LFSH ] keysyms [ Shift_L          ] unicode [   ] layout [ English (US) (0) ] level [ 0 ] mods [ ] leds [ ] 
seat0: keycode [ I233 ] keysyms [ XF86MonBrightne  ] unicode [   ] layout [ English (US) (0) ] level [ 0 ] mods [ ] leds [ ] 
seat0: keycode [ I232 ] keysyms [ XF86MonBrightne  ] unicode [   ] layout [ English (US) (0) ] level [ 0 ] mods [ ] leds [ ]

@Hiqqup
Copy link

Hiqqup commented Dec 2, 2023

sorry for the inactivity, so i get the same xkbcli interactive-wayland output as you:

[main !]~/projects/wayland/dwl xkbcli interactive-wayland
seat0: keycode [ LFSH ] keysyms [ Shift_L          ] unicode [   ] layout [ English (US) (0) ] level [ 0 ] mods [ ] leds [ ]
seat0: keycode [ I232 ] keysyms [ XF86MonBrightne  ] unicode [   ] layout [ English (US) (0) ] level [ 0 ] mods [ ] leds [ ]

but only when i comment out my configuration for those keys in my config.h:

 static const Key keys[] = {
    { 0, XKB_KEY_XF86MonBrightnessDown, spawn, { .v = darker } },
    { WLR_MODIFIER_SHIFT, XKB_KEY_XF86MonBrightnessDown, spawn, { .v = darkest } }
}

otherwise i get no output from xkbcli interactive-wayland because its intercepted by dwl. Idk maybe there is something i am not getting right about the config but the second keybinde for darkest doesnt apply.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants