qmk

Unnamed repository; edit this file 'description' to name the repository.
git clone git://git.z3bra.org/qmk.git
Log | Files | Refs | Submodules | LICENSE

stanrc85.h (1424B)


      1 #pragma once
      2 
      3 #include "quantum.h"
      4 #include "version.h"
      5 
      6 enum my_layers {
      7   _NUMPAD = 0,  //Macropad numpad
      8   _NAVKEY,      //Macropad nav keys
      9   _MEDIA,       //Macropad media controls
     10   _RGB,         //Macropad RGB controls
     11   _FN1PAD,      //Macropad reset and make commands
     12   _QWERTY = 0,  //Qwerty with custom shortcuts and functions
     13   _DEFAULT,     //Default ANSI for gaming, enable with FN2+RCtl
     14   _FN1_60,      //Function keys, arrows, custom shortcuts, volume control
     15   _FN2_60       //RGB Underglow controls and RESET
     16 };
     17 
     18 //Aliases for longer keycodes
     19 #define KC_CAD	LALT(LCTL(KC_DEL))
     20 #define KC_LOCK	LGUI(KC_L)
     21 #define CA_QUOT LCA(KC_QUOT)
     22 #define CA_SCLN LCA(KC_SCLN)
     23 #define KC_CTLE LCTL_T(KC_ESC)
     24 #define LT_SPCF LT(_FN1_60, KC_SPC)
     25 #define TD_TESC TD(TD_ESC)
     26 #define TD_TWIN TD(TD_WIN)
     27 #define TD_TCTL TD(TD_RCTL)
     28 #define CA_COPY LCTL(KC_C)
     29 #define CA_PSTE LCTL(KC_V)
     30 
     31 enum cust_keys {
     32   KC_MAKE = SAFE_RANGE,
     33   KC_RDP
     34 };
     35 
     36 enum tap_dance {
     37   TD_WIN,
     38   TD_ESC,
     39   TD_RCTL
     40 };
     41 
     42 // define a type containing as many tapdance states as you need
     43 typedef enum {
     44   SINGLE_TAP,
     45   SINGLE_HOLD,
     46   DOUBLE_TAP
     47 } td_state_t;
     48 
     49 // function to determine the current tapdance state
     50 int cur_dance (qk_tap_dance_state_t *state);
     51 
     52 // `finished` and `reset` functions for each tapdance keycode
     53 void ctl_copy_finished (qk_tap_dance_state_t *state, void *user_data);
     54 void ctl_copy_reset (qk_tap_dance_state_t *state, void *user_data);