-
Amazing project! I created a layer with arrow keys that I activate with F, so I have:
Is there a way to let these mappings work orthogonally with modifiers such as Shift or Option? Would I even be able to remap such modifiers to D, S etc? Would be awesome to be able to hold down S+D+F then hit J to select words backwards just with the homerow keys. |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 11 replies
-
You can try (optional 'any' modifiers): layer('f', 'f-arrow-mode').manipulators([
map('i', undefined, 'any').to('↑'),
map('j', undefined, 'any').to('←'),
map('l', undefined, 'any').to('→'),
map('k', undefined, 'any').to('↓'),
]), or layer('f', 'f-arrow-mode').manipulators([
withMapper<FromKeyParam, ToKeyParam>({
i: '↑',
j: '←',
l: '→',
k: '↓',
})((k, v) => map(k, undefined, 'any').to(v)),
]), |
Beta Was this translation helpful? Give feedback.
-
For S an D key you can try rule('Letter to Modifiers').manipulators([
map('d').to('left_shift').toIfAlone('d'),
map('s').to('left_option').toIfAlone('s'),
]), |
Beta Was this translation helpful? Give feedback.
-
Thanks for all these tips! I found one unexpected issue with the idea of using F as a layer however – I discovered that when I type, I would accidentally trigger the new layer for words such as 'find'. I think it's because the F key up doesn't occur before the I key down when I type fast. I discovered https://ke-complex-modifications.pqrs.org/json/mouse_keys_mode_v4.json which is conceptually identical to a configuration I'm after, and a cursory read through makes me think that if the layer() method could generate from.simultaneous and simultaneous_options for all the layer key + mapped key combinations, it could resolve the issue. I'll try to test it out when I have some spare time. |
Beta Was this translation helpful? Give feedback.
-
I do not know a way to allow modifiers in the middle of simlayer, but there are 3 alternative ways, hope one of them works for you: Option 1Use different keys on the layer for adding modifiers. (I do it this way) simlayer('f', 'arrow-layer').manipulators({
j: toKey('←'),
i: toKey('↑'),
k: toKey('↓'),
l: toKey('→'),
u: toKey('←', '⌃'),
o: toKey('→', '⌃'),
}) Option 2Add the modifier to the layer key, then press the modifier + f to activate the 'control-f' layer. Note: Need to give a different variable name for each modifierLayer, like modifierLayer('⌃', 'f', 'control-f').manipulators({
u: toKey('←', '⌃'),
o: toKey('→', '⌃'),
}) Option 3Press another key close to 'f' key as the modifier key. Then press the key together with 'f' to activate the layer. duoLayer('f', 'd').manipulators({
u: toKey('←', '⌃'),
o: toKey('→', '⌃'),
}) |
Beta Was this translation helpful? Give feedback.
-
Hi @sohocoke, in case you still need it, there seems to be a new option now with #89 in |
Beta Was this translation helpful? Give feedback.
I think you are looking for
simlayer()