mouseless
mouseless copied to clipboard
ESC going to layer initian, even when I removed the key-combo from config file
Hi. I would like to make the escape key work as usual, while not exiting the mouse layer, but ESC is always going back to the initial layer whenever I press it. This is my config file:
# the keyboard devices it reads from, if no devices are specified, it reads from all
devices:
- "/dev/input/by-id/usb-LITEON_Technology_USB_Keyboard-event-kbd"
# - "/dev/input/by-id/SOME_KEYBOARD_REPLACE_ME-event-kbd"
# this is executed when mouseless starts, e.g. useful for setting the keyboard layout
# startCommand: "setxkbmap de"
# the default speed for mouse movement and scrolling
baseMouseSpeed: 750.0
baseScrollSpeed: 20.0
# the time it takes to accelerate to baseMouseSpeed (in ms), 0 to reach top speed immediately
mouseAccelerationTime: 200.0
# the shape of the acceleration curve, 1.0 is linear, higher values have more time at low speeds
mouseAccelerationCurve: 2.0
# speed of the mouse when it starts moving
startMouseSpeed: 0.0
# same for deceleration
mouseDecelerationTime: 300.0
mouseDecelerationCurve: 3.0
# the rest of the config defines the layers with their bindings
layers:
# the first layer is active at start
- name: initial
bindings:
# when tab is held and another key pressed, activate mouse layer
# tab: tap-hold-next tab ; toggle-layer mouse ; 500
numlock: tap-hold-next numlock ; toggle-layer mouse ; 500
# when a is held for 300ms, activate mouse layer
#a: tap-hold a ; toggle-layer mouse ; 300
## right alt key toggles arrows layer
# rightalt: toggle-layer arrows
## switch escape with capslock
# esc: capslock
# capslock: esc
# a layer for mouse movement
- name: mouse
# when true, keys that are not mapped keep their original meaning
passThrough: true
bindings:
# quit mouse layer
# q: layer initial
z: layer initial
# keep the mouse layer active
space: layer mouse
r: reload-config
# l: move 1 0
# j: move -1 0
# k: move 0 1
# i: move 0 -1
d: move 1 0
a: move -1 0
s: move 0 1
w: move 0 -1
# p: scroll up
# n: scroll down
leftbrace: scroll up
apostrophe: scroll down
rightshift: speed 4.0
# leftalt: speed 4.0
# e: speed 0.3
# w: speed 0.1
rightctrl: speed 0.3
compose: speed 0.1
# capslock: speed 0.1
# f: button left
# d: button middle
# s: button right
semicolon: button left
p: button middle
rightbrace: button right
# move to the top left corner
k0: "exec xdotool mousemove 0 0"
# # another layer for arrows and some other keys
# - name: arrows
# passThrough: false
# bindings:
# e: up
# s: left
# d: down
# f: right
# q: esc
# w: backspace
# r: delete
# v: enter
# # _ is the wildcard key, which matches any key that is not mapped
# _: rightalt+_
Yes you're right, I did this so that one can always go to the initial layer and not get stuck somewhere else, but would be good if one could disable this.
I think what I will do is disable this when one explicitly maps the esc
key, so in your case one could add a binding esc: esc
to the mouse layer.
It's really nice that you thought about avoiding the user getting stuck. Makes a lot of sense.
The option to explicitly disable the ESC
default behavior or to disable when the key was mapped is perfect in my opinion.
i would highly appreciate this too to solve the inconsistency i have between mouseless and karabiner as i have space when held as a meta key and when i do hold space (navigation layer) + escape i get tmuxes copy vi modemm