in file ~/.config/sway/config, reloaded the configuration, but it doesn’t seem to have any effect or might just be the wrong configuration.
Can someone with a fully working keyboard please share his output of localectl status with me? If you are using Sway as window manager, did it require any input configuration for the keyboard? Thanks.
This. Right now I am running the i3 not Sway. I run i3 or sway in the case. Why do you want to know it? Do you still have a problem on your environment?
$ localectl status
System Locale: LANG=en_US.UTF-8
VC Keymap: us
X11 Layout: us
~/.config/sway/config keyboard part.
input "1:1:AT_Translated_Set_2_keyboard" {
xkb_layout us
# The following files manage the symbols.
# /usr/share/X11/xkb/rules/evdev
# /usr/share/X11/xkb/rules/evdev.xml
# /usr/share/X11/xkb/symbols/*
#
# You can set the own custom symbol loading the following files.
# ~/.xkb/rules/evdev
# ~/.xkb/symbols/*
# https://github.com/swaywm/sway/wiki#keyboard-layout
#
# The caps:escape_shifted_compose is available on xkeyboard-config >= 2.35.
# https://gitlab.freedesktop.org/xkeyboard-config/xkeyboard-config/-/commit/8018e2982d1067fc79195e518546fee191b63b6d
xkb_options "caps:escape_shifted_compose,custom:compose_shifted_escape"
# Set Shift + Esc as Compose key.
# https://gitlab.freedesktop.org/xkeyboard-config/xkeyboard-config/-/merge_requests/418
# xkb_options "caps:escape_shifted_compose,compose:shifted_escape"
}
No, no problems really, I just wanted to avoid to have to configure each individual function+key to work in console mode and in Sway. I was hoping there is an existing X11 Model one could define that already has those key mappings defined.
I see. Thanks for sharing the intent. I don’t know what the X11 Model is. Below is the result by setxkbmap -query on “i3” (not “sway”). I am setting a custom layout to use my custom key binding that is not defined in the xkeyboard-config application. But I didn’t touch “model”. If you configure something to work in the console mode, I am curious to see the outcome.
OK, my setup is still work in progress, I have few applications installed so far, but here is what I got, I think you get the idea.
Any X11 configuration done via localectl will only update /etc/X11/xorg.conf.d/00-keyboard.conf which won’t have any impact on the Wayland compositor, therefore limiting it to its minimum:
$ localectl status
System Locale: LANG=en_US.UTF-8
VC Keymap: us
X11 Layout: us
Not doing any key mappings in .config/sway.config for the time being:
### Basic key bindings
bindsym --to-code {
# Fn+F01: KEY_MUTE (113) > /etc/acpi/events/FnF01-mute
# Fn+F02: KEY_VOLUMEDOWN (114) > /etc/acpi/events/FnF02-voldn
# Fn+F03: KEY_VOLUMEUP (115) > /etc/acpi/events/FnF03-volup
# Fn+F04: KEY_PREVIOUSSONG (165) - TODO
# Fn+F05: KEY_PLAYPAUSE (164) - TODO
# Fn+F06: KEY_NEXTSONG (163) - TODO
# Fn+F07: KEY_BRIGHTNESSDOWN (224) > /etc/acpi/events/FnF07-brtdn
# Fn+F08: KEY_BRIGHTNESSUP (225) > /etc/acpi/events/FnF08-brtup
# Fn+F09: Super_L + p
# Fn+F10: KEY_RFKILL (247) - works as is
# Fn+F11: KEY_SYSRQ (99) - TODO
# Fn+F12: KEY_MEDIA (226) - TODO
# Fn+Del: KEY_INSERT (110) - TODO
# Fn+Space: Controls the keyboard backlight - works as is
# Fn+Left: KEY_HOME (102) - works as is
# Fn+Right: KEY_END (107) - works as is
# Fn+Up: KEY_PAGEUP (104) - works as is
# Fn+Down: KEY_PAGEDOWN (109) - works as is
}
Instead delegating mappings for Fn+F[1-3,7,8] to the acpid so that they work on the console as well:
The only concern I’m having right now is Fn+Del, libinput debug-events lists the mapping as KEY_INSERT (110), but it doesn’t behave like an old fashioned insert key.