wrappers.h 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266
  1. // Copyright 2020 Christopher Courtney, aka Drashna Jael're (@drashna) <drashna@live.com>
  2. // Copyright 2020 @jola5
  3. // SPDX-License-Identifier: GPL-2.0-or-later
  4. #pragma once
  5. #include "drashna.h"
  6. /*
  7. Since our quirky block definitions are basically a list of comma separated
  8. arguments, we need a wrapper in order for these definitions to be
  9. expanded before being used as arguments to the LAYOUT_xxx macro.
  10. */
  11. /*
  12. Blocks for each of the four major keyboard layouts
  13. Organized so we can quickly adapt and modify all of them
  14. at once, rather than for each keyboard, one at a time.
  15. And this allows for much cleaner blocks in the keymaps.
  16. For instance Tap/Hold for Control on all of the layouts
  17. NOTE: These are all the same length. If you do a search/replace
  18. then you need to add/remove underscores to keep the
  19. lengths consistent.
  20. */
  21. // clang-format off
  22. #define _________________QWERTY_L1_________________ KC_Q, KC_W, KC_E, KC_R, KC_T
  23. #define _________________QWERTY_L2_________________ KC_A, KC_S, KC_D, KC_F, KC_G
  24. #define _________________QWERTY_L3_________________ KC_Z, KC_X, KC_C, KC_V, KC_B
  25. #define _________________QWERTY_R1_________________ KC_Y, KC_U, KC_I, KC_O, KC_P
  26. #define _________________QWERTY_R2_________________ KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT
  27. #define _________________QWERTY_R3_________________ KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH
  28. #define _________________COLEMAK_L1________________ KC_Q, KC_W, KC_F, KC_P, KC_G
  29. #define _________________COLEMAK_L2________________ KC_A, KC_R, KC_S, KC_T, KC_D
  30. #define _________________COLEMAK_L3________________ KC_Z, KC_X, KC_C, KC_V, KC_B
  31. #define _________________COLEMAK_R1________________ KC_J, KC_L, KC_U, KC_Y, KC_SCLN
  32. #define _________________COLEMAK_R2________________ KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT
  33. #define _________________COLEMAK_R3________________ KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH
  34. #define ______________COLEMAK_MOD_DH_L1____________ KC_Q, KC_W, KC_F, KC_P, KC_B
  35. #define ______________COLEMAK_MOD_DH_L2____________ KC_A, KC_R, KC_S, KC_T, KC_G
  36. #define ______________COLEMAK_MOD_DH_L3____________ KC_Z, KC_X, KC_C, KC_D, KC_V
  37. #define ______________COLEMAK_MOD_DH_R1____________ KC_J, KC_L, KC_U, KC_Y, KC_SCLN
  38. #define ______________COLEMAK_MOD_DH_R2____________ KC_M, KC_N, KC_E, KC_I, KC_O, KC_QUOT
  39. #define ______________COLEMAK_MOD_DH_R3____________ KC_K, KC_H, KC_COMM, KC_DOT, KC_SLASH
  40. #define _________________DVORAK_L1_________________ KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y
  41. #define _________________DVORAK_L2_________________ KC_A, KC_O, KC_E, KC_U, KC_I
  42. #define _________________DVORAK_L3_________________ KC_SCLN, KC_Q, KC_J, KC_K, KC_X
  43. #define _________________DVORAK_R1_________________ KC_F, KC_G, KC_C, KC_R, KC_L
  44. #define _________________DVORAK_R2_________________ KC_D, KC_H, KC_T, KC_N, KC_S, KC_SLSH
  45. #define _________________DVORAK_R3_________________ KC_B, KC_M, KC_W, KC_V, KC_Z
  46. #define ________________DVORAK_AU_L1_______________ KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y
  47. #define ________________DVORAK_AU_L2_______________ KC_O, KC_A, KC_E, KC_I, KC_U
  48. #define ________________DVORAK_AU_L3_______________ KC_SCLN, KC_Q, KC_J, KC_K, KC_X
  49. #define ________________DVORAK_AU_R1_______________ KC_F, KC_G, KC_C, KC_R, KC_L
  50. #define ________________DVORAK_AU_R2_______________ KC_D, KC_H, KC_T, KC_N, KC_S, KC_SLSH
  51. #define ________________DVORAK_AU_R3_______________ KC_B, KC_M, KC_W, KC_V, KC_Z
  52. #define _________________WORKMAN_L1________________ KC_Q, KC_D, KC_R, KC_W, KC_B
  53. #define _________________WORKMAN_L2________________ KC_A, KC_S, KC_H, KC_T, KC_G
  54. #define _________________WORKMAN_L3________________ KC_Z, KC_X, KC_M, KC_C, KC_V
  55. #define _________________WORKMAN_R1________________ KC_J, KC_F, KC_U, KC_P, KC_SCLN
  56. #define _________________WORKMAN_R2________________ KC_Y, KC_N, KC_E, KC_O, KC_I, KC_QUOT
  57. #define _________________WORKMAN_R3________________ KC_K, KC_L, KC_COMM, KC_DOT, KC_SLSH
  58. #define _________________NORMAN_L1_________________ KC_Q, KC_W, KC_D, KC_F, KC_K
  59. #define _________________NORMAN_L2_________________ KC_A, KC_S, KC_E, KC_T, KC_G
  60. #define _________________NORMAN_L3_________________ KC_Z, KC_X, KC_C, KC_V, KC_B
  61. #define _________________NORMAN_R1_________________ KC_J, KC_U, KC_R, KC_L, KC_SCLN
  62. #define _________________NORMAN_R2_________________ KC_Y, KC_N, KC_I, KC_O, KC_U, KC_QUOT
  63. #define _________________NORMAN_R3_________________ KC_P, KC_M, KC_COMM, KC_DOT, KC_SLSH
  64. #define _________________MALTRON_L1________________ KC_Q, KC_P, KC_Y, KC_C, KC_B
  65. #define _________________MALTRON_L2________________ KC_A, KC_N, KC_I, KC_S, KC_F
  66. #define _________________MALTRON_L3________________ KC_SCLN, KC_SLSH, KC_J, KC_G, KC_COMM
  67. #define _________________MALTRON_R1________________ KC_V, KC_M, KC_U, KC_Z, KC_L
  68. #define _________________MALTRON_R2________________ KC_D, KC_T, KC_D, KC_O, KC_R, KC_QUOT
  69. #define _________________MALTRON_R3________________ KC_DOT, KC_W, KC_K, KC_MINS, KC_X
  70. #define _________________EUCALYN_L1________________ KC_Q, KC_W, KC_COMM, KC_DOT, KC_SCLN
  71. #define _________________EUCALYN_L2________________ KC_A, KC_O, KC_E, KC_I, KC_U
  72. #define _________________EUCALYN_L3________________ KC_Z, KC_X, KC_C, KC_V, KC_F
  73. #define _________________EUCALYN_R1________________ KC_M, KC_R, KC_D, KC_Y, KC_P
  74. #define _________________EUCALYN_R2________________ KC_G, KC_T, KC_K, KC_S, KC_N, KC_QUOT
  75. #define _________________EUCALYN_R3________________ KC_B, KC_H, KC_J, KC_L, KC_SLSH
  76. // Qwerty-like
  77. #define _____________CARPLAX_QFMLWY_L1_____________ KC_Q, KC_F, KC_M, KC_L, KC_W
  78. #define _____________CARPLAX_QFMLWY_L2_____________ KC_D, KC_S, KC_T, KC_N, KC_R
  79. #define _____________CARPLAX_QFMLWY_L3_____________ KC_Z, KC_V, KC_G, KC_C, KC_X
  80. #define _____________CARPLAX_QFMLWY_R1_____________ KC_Y, KC_U, KC_O, KC_B, KC_J
  81. #define _____________CARPLAX_QFMLWY_R2_____________ KC_I, KC_A, KC_E, KC_H, KC_SCLN, KC_QUOT
  82. #define _____________CARPLAX_QFMLWY_R3_____________ KC_P, KC_K, KC_COMM, KC_DOT, KC_SLSH
  83. // Colemak like
  84. #define _____________CARPLAX_QGMLWB_L1_____________ KC_Q, KC_G, KC_M, KC_L, KC_W
  85. #define _____________CARPLAX_QGMLWB_L2_____________ KC_D, KC_S, KC_T, KC_N, KC_R
  86. #define _____________CARPLAX_QGMLWB_L3_____________ KC_Z, KC_X, KC_C, KC_F, KC_J
  87. #define _____________CARPLAX_QGMLWB_R1_____________ KC_B, KC_Y, KC_U, KC_V, KC_SCLN
  88. #define _____________CARPLAX_QGMLWB_R2_____________ KC_I, KC_A, KC_E, KC_O, KC_H, KC_QUOT
  89. #define _____________CARPLAX_QGMLWB_R3_____________ KC_K, KC_P, KC_COMM, KC_DOT, KC_SLSH
  90. // colemak like, zxcv fixed
  91. #define _____________CARPLAX_QGMLWY_L1_____________ KC_Q, KC_G, KC_M, KC_L, KC_W
  92. #define _____________CARPLAX_QGMLWY_L2_____________ KC_D, KC_S, KC_T, KC_N, KC_R
  93. #define _____________CARPLAX_QGMLWY_L3_____________ KC_Z, KC_X, KC_C, KC_V, KC_J
  94. #define _____________CARPLAX_QGMLWY_R1_____________ KC_Y, KC_F, KC_U, KC_B, KC_SCLN
  95. #define _____________CARPLAX_QGMLWY_R2_____________ KC_I, KC_A, KC_E, KC_O, KC_H, KC_QUOT
  96. #define _____________CARPLAX_QGMLWY_R3_____________ KC_K, KC_P, KC_COMM, KC_DOT, KC_SLSH
  97. // teeheehee
  98. #define _____________CARPLAX_TNWCLR_L1_____________ KC_T, KC_N, KC_W, KC_C, KC_L
  99. #define _____________CARPLAX_TNWCLR_L2_____________ KC_S, KC_K, KC_J, KC_X, KC_G
  100. #define _____________CARPLAX_TNWCLR_L3_____________ KC_E, KC_O, KC_D, KC_I, KC_A
  101. #define _____________CARPLAX_TNWCLR_R1_____________ KC_R, KC_B, KC_F, KC_M, KC_H
  102. #define _____________CARPLAX_TNWCLR_R2_____________ KC_P, KC_Q, KC_Z, KC_V, KC_SCLN, KC_QUOT
  103. #define _____________CARPLAX_TNWCLR_R3_____________ KC_U, KC_Y, KC_COMM, KC_DOT, KC_SLSH
  104. #define _________________WHITE_R1__________________ KC_V, KC_Y, KC_D, KC_COMM, KC_QUOT
  105. #define _________________WHITE_R2__________________ KC_A, KC_T, KC_H, KC_E, KC_B
  106. #define _________________WHITE_R3__________________ KC_P, KC_K, KC_G, KC_W, KC_Q
  107. #define _________________WHITE_L1__________________ KC_INT1, KC_J, KC_M, KC_L, KC_U
  108. #define _________________WHITE_L2__________________ KC_MINS, KC_C, KC_S, KC_N, KC_O, KC_I
  109. #define _________________WHITE_L3__________________ KC_X, KC_R, KC_F, KC_DOT, KC_Z
  110. #define _________________HALMAK_L1_________________ KC_W, KC_L, KC_R, KC_B, KC_Z
  111. #define _________________HALMAK_L2_________________ KC_S, KC_H, KC_N, KC_T, KC_COMM
  112. #define _________________HALMAK_L3_________________ KC_F, KC_M, KC_V, KC_V, KC_SLASH
  113. #define _________________HALMAK_R1_________________ KC_SCLN, KC_Q, KC_U, KC_D, KC_J
  114. #define _________________HALMAK_R2_________________ KC_DOT, KC_A, KC_E, KC_O, KC_I, KC_QUOTE
  115. #define _________________HALMAK_R3_________________ KC_G, KC_P, KC_X, KC_K, KC_Y
  116. #define __________________ISRT_L1__________________ KC_W, KC_C, KC_L, KC_M, KC_K
  117. #define __________________ISRT_L2__________________ KC_I, KC_S, KC_R, KC_T, KC_G
  118. #define __________________ISRT_L3__________________ KC_Q, KC_V, KC_W, KC_D, KC_J
  119. #define __________________ISRT_R1__________________ KC_Z, KC_F, KC_U, KC_COMM, KC_QUOTE
  120. #define __________________ISRT_R2__________________ KC_P, KC_N, KC_E, KC_A, KC_O, KC_SCLN
  121. #define __________________ISRT_R3__________________ KC_B, KC_H, KC_SLSH, KC_DOT, KC_X
  122. #define __________________SOUL_L1__________________ KC_Q, KC_W, KC_L, KC_D, KC_P
  123. #define __________________SOUL_L2__________________ KC_A, KC_S, KC_R, KC_T, KC_G
  124. #define __________________SOUL_L3__________________ KC_Z, KC_X, KC_C, KC_V, KC_J
  125. #define __________________SOUL_R1__________________ KC_K, KC_M, KC_U, KC_Y, KC_SCLN
  126. #define __________________SOUL_R2__________________ KC_F, KC_N, KC_E, KC_I, KC_O, KC_QUOTE
  127. #define __________________SOUL_R3__________________ KC_B, KC_H, KC_COMM, KC_DOT, KC_SLSH
  128. #define __________________NIRO_L1__________________ KC_Q, KC_W, KC_U, KC_D, KC_P
  129. #define __________________NIRO_L2__________________ KC_A, KC_S, KC_E, KC_T, KC_G
  130. #define __________________NIRO_L3__________________ KC_Z, KC_X, KC_C, KC_V, KC_B
  131. #define __________________NIRO_R1__________________ KC_J, KC_F, KC_Y, KC_L, KC_SCLN
  132. #define __________________NIRO_R2__________________ KC_H, KC_N, KC_I, KC_R, KC_O, KC_QUOTE
  133. #define __________________NIRO_R3__________________ KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH
  134. #define _________________ASSET_L1__________________ KC_Q, KC_W, KC_J, KC_F, KC_G
  135. #define _________________ASSET_L2__________________ KC_A, KC_S, KC_E, KC_T, KC_D
  136. #define _________________ASSET_L3__________________ KC_Z, KC_X, KC_C, KC_V, KC_B
  137. #define _________________ASSET_R1__________________ KC_Y, KC_P, KC_U, KC_L, KC_SCLN
  138. #define _________________ASSET_R2__________________ KC_H, KC_N, KC_I, KC_O, KC_R, KC_QUOTE
  139. #define _________________ASSET_R3__________________ KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH
  140. #define _________________MTGAP_L1__________________ KC_Y, KC_P, KC_O, KC_U, KC_J
  141. #define _________________MTGAP_L2__________________ KC_I, KC_N, KC_E, KC_A, KC_COMM
  142. #define _________________MTGAP_L3__________________ KC_Q, KC_Z, KC_SLSH, KC_DOT, KC_SCLN
  143. #define _________________MTGAP_R1__________________ KC_K, KC_D, KC_L, KC_C, KC_W
  144. #define _________________MTGAP_R2__________________ KC_M, KC_H, KC_T, KC_S, KC_R, KC_QUOTE
  145. #define _________________MTGAP_R3__________________ KC_B, KC_F, KC_G, KC_V, KC_X
  146. #define _________________MINIMAK_L1________________ KC_Q, KC_W, KC_D, KC_R, KC_K
  147. #define _________________MINIMAK_L2________________ KC_A, KC_S, KC_T, KC_F, KC_G
  148. #define _________________MINIMAK_L3________________ KC_Z, KC_X, KC_C, KC_V, KC_B
  149. #define _________________MINIMAK_R1________________ KC_Y, KC_U, KC_I, KC_O, KC_P
  150. #define _________________MINIMAK_R2________________ KC_H, KC_J, KC_E, KC_L, KC_SCLN, KC_QUOT
  151. #define _________________MINIMAK_R3________________ KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH
  152. #define ________________MINIMAK_8_L1_______________ KC_Q, KC_W, KC_D, KC_R, KC_K
  153. #define ________________MINIMAK_8_L2_______________ KC_A, KC_S, KC_T, KC_F, KC_G
  154. #define ________________MINIMAK_8_L3_______________ KC_Z, KC_X, KC_C, KC_V, KC_B
  155. #define ________________MINIMAK_8_R1_______________ KC_Y, KC_U, KC_I, KC_L, KC_P
  156. #define ________________MINIMAK_8_R2_______________ KC_H, KC_N, KC_E, KC_O, KC_SCLN, KC_QUOT
  157. #define ________________MINIMAK_8_R3_______________ KC_J, KC_M, KC_COMM, KC_DOT, KC_SLSH
  158. #define _______________MINIMAK_12_L1_______________ KC_Q, KC_W, KC_D, KC_F, KC_K
  159. #define _______________MINIMAK_12_L2_______________ KC_A, KC_S, KC_T, KC_R, KC_G
  160. #define _______________MINIMAK_12_L3_______________ KC_Z, KC_X, KC_C, KC_V, KC_B
  161. #define _______________MINIMAK_12_R1_______________ KC_Y, KC_U, KC_I, KC_L, KC_SCLN
  162. #define _______________MINIMAK_12_R2_______________ KC_H, KC_N, KC_E, KC_O, KC_P, KC_QUOT
  163. #define _______________MINIMAK_12_R3_______________ KC_J, KC_M, KC_COMM, KC_DOT, KC_SLSH
  164. #define ________________NUMBER_LEFT________________ KC_1, KC_2, KC_3, KC_4, KC_5
  165. #define ________________NUMBER_RIGHT_______________ KC_6, KC_7, KC_8, KC_9, KC_0
  166. #define _________________FUNC_LEFT_________________ KC_F1, KC_F2, KC_F3, KC_F4, KC_F5
  167. #define _________________FUNC_RIGHT________________ KC_F6, KC_F7, KC_F8, KC_F9, KC_F10
  168. #define ___________________BLANK___________________ _______, _______, _______, _______, _______
  169. #define _________________LOWER_L1__________________ KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC
  170. #define _________________LOWER_L2__________________ _________________FUNC_LEFT_________________
  171. #define _________________LOWER_L3__________________ _________________FUNC_RIGHT________________
  172. #define _________________LOWER_R1__________________ KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN
  173. #define _________________LOWER_R2__________________ _______, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR
  174. #define _________________LOWER_R3__________________ _______, KC_HOME, KC_PGDN, KC_PGUP, KC_END
  175. #define _________________RAISE_L1__________________ ________________NUMBER_LEFT________________
  176. #define _________________RAISE_L2__________________ ___________________BLANK___________________
  177. #define _________________RAISE_L3__________________ ___________________BLANK___________________
  178. #define _________________RAISE_R1__________________ ________________NUMBER_RIGHT_______________
  179. #define _________________RAISE_R2__________________ _______, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC
  180. #define _________________RAISE_R3__________________ _______, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
  181. #define _________________ADJUST_L1_________________ RGB_MOD, RGB_HUI, RGB_SAI, RGB_VAI, RGB_TOG
  182. #define _________________ADJUST_L2_________________ MU_TOG , CK_TOGG, AU_ON, AU_OFF, CG_NORM
  183. #define _________________ADJUST_L3_________________ RGB_RMOD,RGB_HUD,RGB_SAD, RGB_VAD, KC_RGB_T
  184. #define _________________ADJUST_R1_________________ KC_SEC1, KC_SEC2, KC_SEC3, KC_SEC4, KC_SEC5
  185. #define _________________ADJUST_R2_________________ CG_SWAP, DEFLYR1, DEFLYR2, DEFLYR3, DEFLYR4
  186. #define _________________ADJUST_R3_________________ MG_NKRO, KC_MUTE, KC_VOLD, KC_VOLU, KC_MNXT
  187. // clang-format on