When I press Ctrl+F# (any of the F1 to F12 keys) the display switches to the coresponding virtual console, i.e. this renders Ctrl+F# keys used in many applications unusable. Using Alt+Ctrl+F# also works.
I cannot understand why Ctrl+F# switches to a virtual console.
I tried removing all Console bindings with something like:
sudo dumpkeys | grep -vE 'Console_5[^0-9]' | sudo loadkeys
but it does not have an effect in sway/wayland.
I also tried srvkeys:none
setxkbmap -layout us -variant dvorak-alt-intl -option srvkeys:none
but it has no effect either.
It doesn't matter if I start sway from gdm or from the shell. (however in a gnome session all is fine)
Please give me a hint, how to find out where the virtual console swithing keybinding is handled! Is it in sway, or is it something else?
Is there a workaround I can try?
Sway Version:
Debug Log:
Description:
asked also at https://unix.stackexchange.com/questions/623873
setxkbmap -layout us -variant dvorak-alt-intl -option srvkeys:none
This does not work within sway, since we are not running within an X server. You need to configure your keyboard layout using an input directive in the sway configuration file.
input "*" {
xkb_options 'srvkeys:none'
}
should be worth a try. man sway-input has more information on the input configuration.
@Emantor - thanks, this solves my problem. (I was absolutely sure, that I've already tried having a srvkeys:none in the sway config, but it seemed to have no effect; now that it's there, all works fine):
input "type:keyboard" {
xkb_layout us,de
xkb_variant dvorak-alt-intl,
xkb_options 'grp:shifts_toggle,srvkeys:none'
}
@Emantor - there seems to be a bug after all - using grp:alts_toggle together with srvkeys:none leads to the above annoying behaviour, I have to use grp:shifts_toggle,srvkeys:none to make things work as expected.
@Emantor - there seems to be a bug after all - using
grp:alts_toggletogether withsrvkeys:noneleads to the above annoying behaviour, I have to usegrp:shifts_toggle,srvkeys:noneto make things work as expected.
This indeed sounds like a bug, if it doesn't reproduce in X11.
Most helpful comment
This does not work within sway, since we are not running within an X server. You need to configure your keyboard layout using an input directive in the sway configuration file.
should be worth a try.
man sway-inputhas more information on the input configuration.