Karabiner-elements: regular key as modifier key

Created on 17 Dec 2016  Â·  15Comments  Â·  Source: pqrs-org/Karabiner-Elements

I'm using the NEO Keyboard layout, and just tried using Karabiner Elements instead of Karabiner.
In the NEO Keyboard Layout the Keycode 0x2a is used as an option key. Is it somehow possible to change this with Karabiner Elements?

stale

Most helpful comment

Hey, I'm using a Layout with similar features to Neo2 (virtual layers). My plan is to create a dedicated keyboard 'driver' programm (without the general purpose UI from Karabiner) using Karabiner grabber and Karabiner virtual HID. Anyone interested? :)

All 15 comments

Neo 2? I have basically the same problem. At the moment, modifier keys are handled separately from "normal" keys in the grabber, in that there is only state (pressed, not pressed) for modifier keys. This would require state for all keys, so keys can be combined.

Hey, I'm using a Layout with similar features to Neo2 (virtual layers). My plan is to create a dedicated keyboard 'driver' programm (without the general purpose UI from Karabiner) using Karabiner grabber and Karabiner virtual HID. Anyone interested? :)

I've been patching the grabber to achieve this, so far without luck. Maybe writing a keyboard driver is the better option, but probably much harder unless you find a nice base. Will publish as soon as I find something, but don't hold your breath.

Hm, just tried, and have no difficulties mapping 0x2a ('#' on German Keyboard) to 'option'. Did you really mean 'option' or did you mean to use it as 'virtual modifier key'?

@dirkz I went the grabber patching route myself now: https://github.com/epegzz/Karabiner-Elements/compare/master...epegzz:coder-layout It's not feature complete yet but works pretty well.
And actually patching the grabber provides way more flexibility than the previous Karabiner config :)

@epegzz Will take a look at it.

@epegzz Is that a custom Version to use German Neo 2 with Karabiner Elements? How good does it work? I'am using Neo and running still at El Capitain with the old Karabiner...

@PaulePan The alphabetic mapping is done via a normal keylayout file after all, so my fork only takes care of the other layers (Just like the Neo2 Karabiner config does). The coding characters layer is pretty much taken 1:1 from NEO2, just the numbers/navigation layer differs a bit plus there are some other mappings not existent in NEO2.

Overall it works very well; Even better than with the previous Karabiner version, as writing C++ code gives you more control than an xml config file does.

On the downside it requires to write some C++ code in order to tailor it to your needs. However, nothing too complex, and by looking at my changes you should be able to implement your own features by simply copying and modifying some lines, even if you're not too familiar with C++. That's what I did as well.

For now I'm happy with this approach. I'll rebase my fork to this one on a regular base so that it won't become outdated.

I'd also contribute development of some generic features instead of going my own way, but it looks like tekezo doesn't want others to participate in feature development. Maybe that'll change as soon as his code base became more stable. Until than, I'll happily just go with my fork. If you want to adapt it for NEO2 let me know and I'll give you some guidance. Maybe we'll have a talk on the IRC channel then :)

@epegzz Hi Daniel, that would be great. I installed the Coder Layout Version via DMG File. But it doesn't work for me. Maybe because i am still running on OSX El Capitan... Some Guidance would be very helpful. I am no Developer, just a user :-) Maybe you can contact me on Facebook: https://www.facebook.com/weickert.anselmpaul Thank you very much.

@PaulePan my DMG will only work when using the coder layout mappings.

I currently don't have enough time to create a complete Neo2 version, but I'll pitch my fork to the Neo community :)

Hey @epegzz I tried to install your version, but i don't make it. The Left Command and the Tab Key did nothing. No Key Event was visible in the Event Viewer. I don't know what to do with the coder Layout Mappings. Maybe i should wait for an "official" Solution. But typing without Layer 4 is so annoying :-(

@PaulePan Left Command in CoderLayout triggers kind of a Layer 4, called Navigation Layer :)

CMD_L + J = Left
CMD_L + K = Down
CMD_L + L = Right
…

CMD_L + Spacebar + J = Word Left
CMD_L + Spacebar + K = Page Down
CMD_L + Spacebar + L = Word Right
…

The Tab Key is a modifier as well for the so called Edit Layer:
Tab + W = Copy
Tab + E = Cut
Tab + F = Paste
Tab + R = Select All
…

To type a real Tab you have to use the NavigationLayer:
CMD_L + W = Tab (focus next input / indent)
CMD_L + Q = Shift + Tab (focus previous input / un-indent)

I'll try make a graphical overview of all CoderLayout mappings as soon as possible.
Because without, it's impossible to even test the layout.

Also, it would be easy for me to create a version of CoderLayout using Layer1 from the Neo2 layout, so that you wouldn't have to re-learn the alphabetical layer. But let me create a graphical overview off all CoderLayout first.

Ok, thats explains why it doesn't work. Thank you.

I haven't followed this discussion, but you might want to take a look at #40 and jgosmann/Karabiner-Elements-Neo.

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

Was this page helpful?
0 / 5 - 0 ratings