chromebook-linux/cros-keyboard-map/keyd/examples/nav-layer.conf
2025-06-08 19:32:41 -05:00

53 lines
1 KiB
Text

# Goal:
#
# To create a vi like navigation layer accessible by holding capslock while holding capslock
# otherwise behave like the control key (when held) and escape when tapped.
#
# In essence we want:
#
# - capslock+h = left
# - capslock+j = down
# - capslock+k = up
# - capslock+l = right
#
# - capslock+shift+h = C-left
# - capslock+shift+l = C-right
# - capslock+shift+j = C-down
# - capslock+shift+k = C-up
#
# - capslock = escape (when tapped)
#
# In all other instances capslock should behave as normal control:
#
# - capslock+a = C-a
# - capslock+b = C-b
# - capslock+c = C-c
# ...
# - capslock+shift+i = C-S-i
# - capslock+shift+k = C-S-k
# ....
# This is achieved by creating a composite layer called [capslock+shift]
# which is activated whenever capslock and shift are simultaneously
# held.
[ids]
*
[main]
capslock = overload(capslock, esc)
[capslock:C]
h = left
j = down
k = up
l = right
# Activates when both capslock and shift is pressed
[capslock+shift]
h = C-left
j = C-down
k = C-up
l = C-right