##### jk's macOS/generic converter 2022-10-10 ###### #### Global definitions #### ## ## Toggle macOS mode with extra hardware button AUX1 ## or Shift + Ctrl + Alt + Numpad minus ## ## Toggle Special translations mode with Scroll Lock ## (later overridden to use Num Lock in macOS mode) ## ## CapsLock is ESC, with Shift for CapsLock ## remapblock ## Toggle macOS mode with extra hardware button AUX1 AUX1 SELECT_7 ## Toggle Special translations mode with Scroll Lock SCROLL_LOCK SELECT_1 endblock macroblock ## Shift + Caps Lock is normal Caps Lock, ## delay (100 ms) required for reliable lock operation macro CAPS_LOCK SHIFT -ALT -GUI -CTRL make CAPS_LOCK onbreak norestoremeta delay 100 break CAPS_LOCK endmacro ## Caps Lock is ESC (a real meta key would be nice; too bad) macro CAPS_LOCK make ESC onbreak norestoremeta break ESC endmacro ## Toggle macOS mode with Shift + Ctrl + Alt + Numpad minus macro PAD_MINUS CTRL ALT SHIFT -GUI press SELECT_7 endmacro endblock #### Special translations mode (1) #### ## ## Toggle with Scroll Lock (Num Lock in macOS mode) ## ## Home and End: remap to Ctrl + A, Ctrl + E ## Numpad period to real period, with Shift to comma ifselect 1 macroblock ## Home: remap to Ctrl + A, pass modifiers macro HOME push_meta set_meta LCTRL press A pop_all_meta endmacro ## End: remap Ctrl + E, pass modifiers macro END push_meta set_meta LCTRL press E pop_all_meta endmacro ## Numpad period (with no modifiers) to real period macro PAD_PERIOD SHIFT -CTRL -ALT -GUI push_meta clear_meta all press COMMA pop_all_meta endmacro ## Shift + Numpad period (no other modifiers) to comma macro PAD_PERIOD -SHIFT -CTRL -ALT -GUI push_meta clear_meta all press PERIOD pop_all_meta endmacro endblock #### macOS mode #### ## ## Toggle with extra harware button (AUX1) ## or Shift + Ctrl + Alt + Numpad minus ## ## Num Lock to toggle extra translations ## Swap Win and Alt keys, so locations match standard Apple keyboards ## Fix backtick issue (swap BACK_QUOTE and EUROPE_2) ## Sleep with Pause ## Lock screen with Scroll Lock ## Tap Menu (APP) to cycle through current application's windows ## New screen capture shortcuts for Print Screen key: ## PrtSc = select area, to clipboard ## + Shift = select area, to file ## + Ctrl = show screen capture options ## + Shift + Ctrl = whole screen to file ## ifselect 7 remapblock ## Num Lock to toggle Special translations mode NUM_LOCK SELECT_1 ## Scroll Lock remap override, pass through as-is SCROLL_LOCK SCROLL_LOCK ## Fix backtick issue EUROPE_2 BACK_QUOTE BACK_QUOTE EUROPE_2 ## Fix option/command key placement LALT LGUI LGUI LALT RALT RGUI RGUI RALT endblock macroblock ## Sleep with Pause macro PAUSE -SHIFT -CTRL -ALT -GUI push_meta set_meta LGUI LALT make SYSTEM_POWER onbreak break SYSTEM_POWER pop_all_meta endmacro ## Lock screen with Scroll Lock macro SCROLL_LOCK -SHIFT -CTRL -ALT -GUI push_meta set_meta LGUI LCTRL press q pop_all_meta endmacro ## Tap Menu (APP) to cycle through current application's windows macro APP push_meta set_meta LGUI press EUROPE_2 pop_all_meta endmacro ## Capture whole screen to file macro PRINTSCREEN SHIFT CTRL push_meta set_meta LGUI press 3 pop_all_meta endmacro ## Capture select area of screen to file macro PRINTSCREEN SHIFT push_meta set_meta LGUI press 4 pop_all_meta endmacro ## Show Ssreen capture options macro PRINTSCREEN CTRL push_meta clear_meta CTRL set_meta LSHIFT LGUI press 5 pop_all_meta endmacro ## Capture select area of screen to buffer macro PRINTSCREEN push_meta set_meta LSHIFT LCTRL LGUI press 4 pop_all_meta endmacro endblock ## EOF