engelbart icon indicating copy to clipboard operation
engelbart copied to clipboard

Add sticky to chorded modifiers

Open bhodorog opened this issue 7 years ago • 1 comments

I was thinking if it's possible to add sticky as an option to newly defined modifiers. I've already tried activating sticky modifiers from OSX System Preferences panel and from within Karabiner ("Sticky modifiers keys). Both are only affecting the default modifiers key (triggered by physical ctrl, opt keys). I've already tried fiddling around with some settings, but my Karabiner voodoo is quite poor, so I was wondering if you know how to add something like that.

One way they could apear in the UI is to have the current items + duplicated items with "sticky enabled". Obviously having "Show sticky modifiers state" checked in Karabiner/Preferences/Status Message should be respected.

bhodorog avatar Feb 02 '17 06:02 bhodorog

I don't know if it's possible, you need to be able to merge the __SimultaneousKeyPresses__ with __KeyOverlaidModifier__ see how sticky is implemented

I would try with something like this

    <item>
      <name>CONTROL</name>
      <appendix>Simultaneous home keys presses to CONTROL</appendix>
      <appendix>(D+F to CONTROL_L)</appendix>
      <appendix>(J+K to CONTROL_R)</appendix>
      <identifier>remap.engelbart_control</identifier>
      <autogen>
        __SimultaneousKeyPresses__ 
        KeyCode::D, KeyCode::F, 
        KeyCode::CONTROL_L,
        KeyCode::VK_STICKY_ACTIVE_MODIFIERS_FORCE_ON,
        KeyCode::VK_STICKY_CONTROL_L,
      </autogen>
      <autogen>
        __SimultaneousKeyPresses__ 
        KeyCode::J, KeyCode::K, 
        KeyCode::CONTROL_R,
        KeyCode::VK_STICKY_ACTIVE_MODIFIERS_FORCE_ON,
        KeyCode::VK_STICKY_CONTROL_R,
      </autogen>
    </item>

gabrielelana avatar Feb 02 '17 15:02 gabrielelana