You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

720 lines
45 KiB

  1. #pragma once
  2. /*
  3. Copyright 2018 Eric Gebhart <e.a.gebhart@gmail.com>
  4. This program is free software: you can redistribute it and/or modify
  5. it under the terms of the GNU General Public License as published by
  6. the Free Software Foundation, either version 2 of the License, or
  7. (at your option) any later version.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. GNU General Public License for more details.
  12. You should have received a copy of the GNU General Public License
  13. along with this program. If not, see <http://www.gnu.org/licenses/>.
  14. */
  15. #include "core_keysets.h"
  16. #include "mod_layer.h"
  17. #include "edge_keys.h"
  18. /******************************************************************/
  19. /* This is where I put my Keyboard layouts. */
  20. /* The mod layer can be modified in mod_layer.h */
  21. /* can be applied here. The physical shape of the keyboard is */
  22. /* also accounted for here. This makes it very simple to add a */
  23. /* new keyboard and reuse all of my layouts and layers */
  24. /* */
  25. /* With all of that in hand, we then create a LAYOUT wrapper */
  26. /* macro that takes a list of keys, to create a keyboard matrix */
  27. /* that fits the keyboard. Simple. */
  28. /* */
  29. /* The thumb keys, the bottom rows, etc. */
  30. /* */
  31. /* An attempt has been made to adapt the kinesis and ergodox */
  32. /* Thumb keys to the rectangular shapes of the xd75, viterbi, */
  33. /* and rebound. */
  34. /******************************************************************/
  35. /******************************************************************/
  36. /* * The XD75 is a 5x15 Ortholinear matrix which means it has 3 */
  37. /* keys inbetween the usual left and right hand keys */
  38. /* * The Viterbi is a split 5x14 Ortholinear with 2 middle keys. */
  39. /* * The Ergodox is a split 5x14 Ortholinear with 2 middle keys, */
  40. /* thumbkeys. It is missing middle keys on (home) row 3. */
  41. /* * The Corne is a split 3x12 with 6 thumb keys. It has no */
  42. /* extra middle keys */
  43. /* */
  44. /******************************************************************/
  45. /******************************************************************/
  46. /* In all cases these keyboards are defined in a matrix which is */
  47. /* a set of rows. Maybe like so, or not. */
  48. /* */
  49. /* -------------------------|------------------------ */
  50. /* | Left0 | Numbers L | mid|dle0 | numbers R | Right0 | */
  51. /* | Left1 | keys0-5 | mid|dle1 | Keys6-10 | Right1 | */
  52. /* | Left2 | keys11-15 | mid|dle2 | Keys16-20 | Right2 | */
  53. /* | Left3 | keys20-25 | mid|dle3 | Keys25-30 | Right3 | */
  54. /* | Row5L | Row5R | */
  55. /* | ThumbsL | ThumbsR | */
  56. /* -------------------------|------------------------ */
  57. /* Generally speaking, the keys on the right and left don't change. */
  58. /* Neither does the bottom row or the thumbs. Frequently the numbers */
  59. /* row is identical across layers. Mostly, we want our Base layers to */
  60. /* be predctable. */
  61. // Since our quirky block definitions are basically a list of comma separated
  62. // arguments, we need a wrapper in order for these definitions to be
  63. // expanded before being used as arguments to the LAYOUT_xxx macro.
  64. #if (!defined(LAYOUT) && defined(KEYMAP))
  65. #define LAYOUT KEYMAP
  66. #endif
  67. // every keyboard has it's Layout. We start there and make a var args
  68. // out of it.
  69. #define LVARG_ergodox(...) LAYOUT_ergodox(__VA_ARGS__)
  70. #define LVARG_edox(...) LAYOUT_ergodox_pretty(__VA_ARGS__)
  71. #define LAYOUT_VARG(...) LAYOUT(__VA_ARGS__)
  72. #define LAYOUT_PVARG(...) LAYOUT_pretty(__VA_ARGS__)
  73. #define LVARG_4x12(...) LAYOUT_ortho_4x12(__VA_ARGS__)
  74. #define LVARG_5x12(...) LAYOUT_ortho_5x12(__VA_ARGS__)
  75. #define LVARG_5x14(...) LAYOUT_ortho_5x14(__VA_ARGS__)
  76. #define LVARG_5x15(...) LAYOUT_ortho_5x15(__VA_ARGS__)
  77. /*
  78. | Left | Numbers L | middle | numbers R | Right |
  79. | Left | keys0-5 | middle | Keys6-10 | Right |
  80. | Left | keys11-15 | middle | Keys16-20 | Right |
  81. | Left | keys20-25 | middle | Keys25-30 | Right |
  82. |Row5L Row5R |
  83. |ThumbsL ThumbsR |
  84. */
  85. /* Assuming that left, midddle, right, row5, and thumbs stay the same, */
  86. /* numbers, no numbers, numbers never change, whatever. */
  87. /* we can have a layout macro that takes a nice rectangle of keys. */
  88. /* Actually, because of Bepo, each keyboard currently requires four of */
  89. /* these macros. One for Qwerty, One for foreign layouts on bepo like */
  90. /* dvorak and beakl on bepo instead of on Qwerty. Then another for the Bepo */
  91. /* layout because unlike the rest of the layouts Bepo doesn't fit in */
  92. /* 3x10. It wants 3x12. So there are potentially 4 macros per keyboard here. */
  93. /* XXXX_base, XXXX_base_bepo, XXXX_base_bepo6, The 4th macro */
  94. /* is XXXXX_transient and generally works for all other */
  95. /* non base layers. */
  96. /* The base and transient versions are all that is necessary, if bepo is */
  97. /* not needed. */
  98. /* All layouts are relatively simple to make. */
  99. /* The ROW macros add a universal mod layer so that mods can be defined once */
  100. /* and used everywhere. No matter the keymap or layer. this allows actual maps */
  101. /* like dvorak, qwerty, colemak, beakl, etc., to be defined simply. */
  102. /* Additional, more complicated layouts can be found here.*/
  103. /* examples can be found in crkbd/keymaps/ericgebhart */
  104. /* examples can be found in kinesis/keymaps/ericgebhart */
  105. /* examples can be found in ergodox/keymaps/ericgebhart */
  106. /* examples can be found in montsinger/rebound/rev4/keymaps/ericgebhart */
  107. /********************************************************************/
  108. /* xiudi/xd75 - Ortholinear 5x15 */
  109. /********************************************************************/
  110. /// These first two base layout templates take sets of 5 keys, left and right.
  111. // Using 4 sets allows for changing the number row if you have one.
  112. // if you never change the number row, then use 3 sets of left and right.
  113. // and define the number row here.
  114. #define LAYOUT_5x15_base( \
  115. K01, K02, K03, K04, K05, \
  116. K06, K07, K08, K09, K0A, \
  117. K11, K12, K13, K14, K15, \
  118. K16, K17, K18, K19, K1A, \
  119. K21, K22, K23, K24, K25, \
  120. K26, K27, K28, K29, K2A, \
  121. K31, K32, K33, K34, K35, \
  122. K36, K37, K38, K39, K3A) \
  123. LVARG_5x15( \
  124. ROW0_LEFT(K01, K02, K03, K04, K05), \
  125. ___3_MIDDLE_T___, \
  126. ROW0_RIGHT(K06, K07, K08, K09, K0A), \
  127. \
  128. ROW1_LEFT(K11, K12, K13, K14, K15), \
  129. ___3_MIDDLE_1___, \
  130. ROW1_RIGHT(K16, K17, K18, K19, K1A), \
  131. \
  132. ROW2_LEFT(K21, K22, K23, K24, K25), \
  133. ___3_MIDDLE_2___, \
  134. ROW2_RIGHT(K26, K27, K28, K29, K2A), \
  135. \
  136. ROW3_LEFT(K31, K32, K33, K34, K35), \
  137. ___3_MIDDLE_3___, \
  138. ROW3_RIGHT(K36, K37, K38, K39, K3A), \
  139. ___15_BOTTOM___ \
  140. )
  141. #define LAYOUT_5x15_base_bepo( \
  142. K01, K02, K03, K04, K05, \
  143. K06, K07, K08, K09, K0A, \
  144. K11, K12, K13, K14, K15, \
  145. K16, K17, K18, K19, K1A, \
  146. K21, K22, K23, K24, K25, \
  147. K26, K27, K28, K29, K2A, \
  148. K31, K32, K33, K34, K35, \
  149. K36, K37, K38, K39, K3A) \
  150. LVARG_5x15( \
  151. ROW0_LEFT_BP(K01, K02, K03, K04, K05), \
  152. ___3_MIDDLE_T___, \
  153. ROW0_RIGHT_BP(K06, K07, K08, K09, K0A), \
  154. \
  155. ROW1_LEFT_BP(K11, K12, K13, K14, K15), \
  156. ___3_MIDDLE_1_BP___, \
  157. ROW1_RIGHT_BP(K16, K17, K18, K19, K1A), \
  158. \
  159. ROW2_LEFT_BP(K21, K22, K23, K24, K25), \
  160. ___3_MIDDLE_2_BP___, \
  161. ROW2_RIGHT_BP(K26, K27, K28, K29, K2A), \
  162. \
  163. ROW3_LEFT_BP(K31, K32, K33, K34, K35), \
  164. ___3_MIDDLE_3_BP___, \
  165. ROW3_RIGHT_BP(K36, K37, K38, K39, K3A), \
  166. ___15_BOTTOM_BP___ \
  167. )
  168. // Just for bepo because it's a 3x6 matrix on each side.
  169. // So 3 pairs of 6 keys, left and right.
  170. #define Layout_5x15_base_bepo6( \
  171. K01, K02, K03, K04, K05, K06, \
  172. K07, K08, K09, K0A, K0B, K0C, \
  173. K11, K12, K13, K14, K15, K16, \
  174. K17, K18, K19, K1A, K1B, K1C, \
  175. K21, K22, K23, K24, K25, K26, \
  176. K27, K28, K29, K2A, K2B, K2C \
  177. ) \
  178. LVARG_5x15( \
  179. ___15_B_SYMB___, \
  180. ROW1_LEFT_BP6(K01, K02, K03, K04, K05, K06), \
  181. ___3_MIDDLE_1_BP___, \
  182. ROW1_RIGHT_BP6(K07, K08, K09, K0A, K0B, K0C), \
  183. \
  184. ROW2_LEFT_BP6(K11, K12, K13, K14, K15, K16), \
  185. ___3_MIDDLE_2___, \
  186. ROW2_RIGHT_BP6(K17, K18, K19, K1A, K1B, K1C), \
  187. \
  188. ROW3_LEFT_BP6(K21, K22, K23, K24, K25, K26), \
  189. ___3_MIDDLE_3___, \
  190. ROW3_RIGHT_BP6(K27, K28, K29, K2A, K2B, K2C), \
  191. ___15_BOTTOM_BP___ \
  192. )
  193. // 4 rows of 12. 3 columns transparent in the middle.
  194. #define LAYOUT_5x15_transient( \
  195. K01, K02, K03, K04, K05, K06, \
  196. K07, K08, K09, K0A, K0B, K0C, \
  197. K11, K12, K13, K14, K15, K16, \
  198. K17, K18, K19, K1A, K1B, K1C, \
  199. K21, K22, K23, K24, K25, K26, \
  200. K27, K28, K29, K2A, K2B, K2C, \
  201. K31, K32, K33, K34, K35, K36, \
  202. K37, K38, K39, K3A, K3B, K3C \
  203. ) \
  204. LVARG_5x15( \
  205. K01, K02, K03, K04, K05, K06, \
  206. ___3___, \
  207. K07, K08, K09, K0A, K0B, K0C, \
  208. K11, K12, K13, K14, K15, K16, \
  209. ___3___, \
  210. K17, K18, K19, K1A, K1B, K1C, \
  211. K21, K22, K23, K24, K25, K26, \
  212. ___3___, \
  213. K27, K28, K29, K2A, K2B, K2C, \
  214. K31, K32, K33, K34, K35, K36, \
  215. ___3___, \
  216. K37, K38, K39, K3A, K3B, K3C, \
  217. ___15___) \
  218. #define BASE_5x15(...) LAYOUT_5x15_base(__VA_ARGS__)
  219. #define BASE_5x15_bepo(...) LAYOUT_5x15_base_bepo(__VA_ARGS__)
  220. #define BASE_5x15_bepo6(...) LAYOUT_5x15_base_bepo6(__VA_ARGS__)
  221. #define TRANSIENT_5x15(...) LAYOUT_5x15_transient(__VA_ARGS__)
  222. /********************************************************************/
  223. /********************************************************************/
  224. /* viterbi - Ortholinear 5x14 */
  225. /********************************************************************/
  226. #define LAYOUT_5x14_base( \
  227. K01, K02, K03, K04, K05, \
  228. K06, K07, K08, K09, K0A, \
  229. K11, K12, K13, K14, K15, \
  230. K16, K17, K18, K19, K1A, \
  231. K21, K22, K23, K24, K25, \
  232. K26, K27, K28, K29, K2A, \
  233. K31, K32, K33, K34, K35, \
  234. K36, K37, K38, K39, K3A) \
  235. LVARG_5x14( \
  236. ROW0_LEFT(K01, K02, K03, K04, K05), \
  237. ___2_MIDDLE_T___, \
  238. ROW0_RIGHT(K06, K07, K08, K09, K0A), \
  239. \
  240. ROW1_LEFT(K11, K12, K13, K14, K15), \
  241. ___2_MIDDLE_1___, \
  242. ROW1_RIGHT(K16, K17, K18, K19, K1A), \
  243. \
  244. ROW2_LEFT(K21, K22, K23, K24, K25), \
  245. ___2_MIDDLE_2___, \
  246. ROW2_RIGHT(K26, K27, K28, K29, K2A), \
  247. \
  248. ROW3_LEFT(K31, K32, K33, K34, K35), \
  249. ___2_MIDDLE_3___, \
  250. ROW3_RIGHT(K36, K37, K38, K39, K3A), \
  251. ___14_BOTTOM___ \
  252. )
  253. #define LAYOUT_5x14_base_bepo( \
  254. K01, K02, K03, K04, K05, \
  255. K06, K07, K08, K09, K0A, \
  256. K11, K12, K13, K14, K15, \
  257. K16, K17, K18, K19, K1A, \
  258. K21, K22, K23, K24, K25, \
  259. K26, K27, K28, K29, K2A, \
  260. K31, K32, K33, K34, K35, \
  261. K36, K37, K38, K39, K3A) \
  262. LVARG_5x14( \
  263. ROW0_LEFT_BP(K01, K02, K03, K04, K05), \
  264. ___2_MIDDLE_T___, \
  265. ROW0_RIGHT_BP(K06, K07, K08, K09, K0A), \
  266. \
  267. ROW1_LEFT_BP(K11, K12, K13, K14, K15), \
  268. ___2_MIDDLE_1_BP___, \
  269. ROW1_RIGHT_BP(K16, K17, K18, K19, K1A), \
  270. \
  271. ROW2_LEFT_BP(K21, K22, K23, K24, K25), \
  272. ___2_MIDDLE_2_BP___, \
  273. ROW2_RIGHT_BP(K26, K27, K28, K29, K2A), \
  274. \
  275. ROW3_LEFT_BP(K31, K32, K33, K34, K35), \
  276. ___2_MIDDLE_3_BP___, \
  277. ROW3_RIGHT_BP(K36, K37, K38, K39, K3A), \
  278. ___14_BOTTOM_BP___ \
  279. )
  280. // Just for bepo because it's a 3x6 matrix on each side.
  281. // So 3 pairs of 6 keys, left and right.
  282. #define LAYOUT_5x14_base_bepo6( \
  283. K01, K02, K03, K04, K05, K06, \
  284. K07, K08, K09, K0A, K0B, K0C, \
  285. K11, K12, K13, K14, K15, K16, \
  286. K17, K18, K19, K1A, K1B, K1C, \
  287. K21, K22, K23, K24, K25, K26, \
  288. K27, K28, K29, K2A, K2B, K2C \
  289. ) \
  290. LVARG_5x14( \
  291. ___14_B_SYMB___, \
  292. ROW1_LEFT_BP6(K01, K02, K03, K04, K05, K06), \
  293. ___2_MIDDLE_1_BP___, \
  294. ROW1_RIGHT_BP6(K07, K08, K09, K0A, K0B, K0C), \
  295. \
  296. ROW2_LEFT_BP6(K11, K12, K13, K14, K15, K16), \
  297. ___2_MIDDLE_2___, \
  298. ROW2_RIGHT_BP6(K17, K18, K19, K1A, K1B, K1C), \
  299. \
  300. ROW3_LEFT_BP6(K21, K22, K23, K24, K25, K26), \
  301. ___2_MIDDLE_3___, \
  302. ROW3_RIGHT_BP6(K27, K28, K29, K2A, K2B, K2C), \
  303. ___14_BOTTOM_BP___ \
  304. )
  305. // 4 rows of 12. 2 columns transparent in the middle.
  306. #define LAYOUT_5x14_transient( \
  307. K01, K02, K03, K04, K05, K06, \
  308. K07, K08, K09, K0A, K0B, K0C, \
  309. K11, K12, K13, K14, K15, K16, \
  310. K17, K18, K19, K1A, K1B, K1C, \
  311. K21, K22, K23, K24, K25, K26, \
  312. K27, K28, K29, K2A, K2B, K2C, \
  313. K31, K32, K33, K34, K35, K36, \
  314. K37, K38, K39, K3A, K3B, K3C \
  315. ) \
  316. LVARG_5x14( \
  317. K01, K02, K03, K04, K05, K06, \
  318. ___2___, \
  319. K07, K08, K09, K0A, K0B, K0C, \
  320. K11, K12, K13, K14, K15, K16, \
  321. ___2___, \
  322. K17, K18, K19, K1A, K1B, K1C, \
  323. K21, K22, K23, K24, K25, K26, \
  324. ___2___, \
  325. K27, K28, K29, K2A, K2B, K2C, \
  326. K31, K32, K33, K34, K35, K36, \
  327. ___2___, \
  328. K37, K38, K39, K3A, K3B, K3C, \
  329. ___14___ \
  330. ) \
  331. #define BASE_5x14(...) LAYOUT_5x14_base(__VA_ARGS__)
  332. #define BASE_5x14_bepo(...) LAYOUT_5x14_base_bepo(__VA_ARGS__)
  333. #define BASE_5x14_bepo6(...) LAYOUT_5x14_base_bepo6(__VA_ARGS__)
  334. #define TRANSIENT_5x14(...) LAYOUT_5x14_transient(__VA_ARGS__)
  335. /********************************************************************/
  336. /* Ortholinear 4x12 */
  337. /********************************************************************/
  338. #define LAYOUT_4x12_base( \
  339. K01, K02, K03, K04, K05, \
  340. K06, K07, K08, K09, K0A, \
  341. K11, K12, K13, K14, K15, \
  342. K16, K17, K18, K19, K1A, \
  343. K21, K22, K23, K24, K25, \
  344. K26, K27, K28, K29, K2A \
  345. ) \
  346. LVARG_4x12( \
  347. ROW1_LEFT(K01, K02, K03, K04, K05), \
  348. ROW1_RIGHT(K06, K07, K08, K09, K0A), \
  349. \
  350. ROW2_LEFT(K11, K12, K13, K14, K15), \
  351. ROW2_RIGHT(K16, K17, K18, K19, K1A), \
  352. \
  353. ROW3_LEFT(K21, K22, K23, K24, K25), \
  354. ROW3_RIGHT(K26, K27, K28, K29, K2A), \
  355. \
  356. ___12_BOTTOM___ \
  357. )
  358. #define LAYOUT_4x12_base_bepo( \
  359. K01, K02, K03, K04, K05, \
  360. K06, K07, K08, K09, K0A, \
  361. K11, K12, K13, K14, K15, \
  362. K16, K17, K18, K19, K1A, \
  363. K21, K22, K23, K24, K25, \
  364. K26, K27, K28, K29, K2A \
  365. ) \
  366. LVARG_4x12( \
  367. ROW1_LEFT_BP(K01, K02, K03, K04, K05), \
  368. ROW1_RIGHT_BP(K06, K07, K08, K09, K0A), \
  369. \
  370. ROW2_LEFT_BP(K11, K12, K13, K14, K15), \
  371. ROW2_RIGHT_BP(K16, K17, K18, K19, K1A), \
  372. \
  373. ROW3_LEFT_BP(K21, K22, K23, K24, K25), \
  374. ROW3_RIGHT_BP(K26, K27, K28, K29, K2A), \
  375. \
  376. ___12_BOTTOM_BP___ \
  377. )
  378. // Just for bepo because it's a 3x6 matrix on each side.
  379. // So 3 pairs of 6 keys, left and right.
  380. #define Layout_4x12_base_bepo6( \
  381. K01, K02, K03, K04, K05, K06, \
  382. K07, K08, K09, K0A, K0B, K0C, \
  383. K11, K12, K13, K14, K15, K16, \
  384. K17, K18, K19, K1A, K1B, K1C, \
  385. K21, K22, K23, K24, K25, K26, \
  386. K27, K28, K29, K2A, K2B, K2C \
  387. ) \
  388. LVARG_4x12( \
  389. ROW1_LEFT_BP6(K01, K02, K03, K04, K05, K06), \
  390. ROW1_RIGHT_BP6(K07, K08, K09, K0A, K0B, K0C), \
  391. \
  392. ROW2_LEFT_BP6(K11, K12, K13, K14, K15, K16), \
  393. ROW2_RIGHT_BP6(K17, K18, K19, K1A, K1B, K1C), \
  394. \
  395. ROW3_LEFT_BP6(K21, K22, K23, K24, K25, K26), \
  396. ROW3_RIGHT_BP6(K27, K28, K29, K2A, K2B, K2C), \
  397. ___12_BOTTOM_BP___ \
  398. )
  399. // takes 3 makes 4 rows of 12.
  400. #define LAYOUT_4x12_transient( \
  401. K01, K02, K03, K04, K05, K06, \
  402. K07, K08, K09, K0A, K0B, K0C, \
  403. K11, K12, K13, K14, K15, K16, \
  404. K17, K18, K19, K1A, K1B, K1C, \
  405. K21, K22, K23, K24, K25, K26, \
  406. K27, K28, K29, K2A, K2B, K2C \
  407. ) \
  408. LVARG_4x12( \
  409. K01, K02, K03, K04, K05, K06, \
  410. K07, K08, K09, K0A, K0B, K0C, \
  411. K11, K12, K13, K14, K15, K16, \
  412. K17, K18, K19, K1A, K1B, K1C, \
  413. K21, K22, K23, K24, K25, K26, \
  414. K27, K28, K29, K2A, K2B, K2C, \
  415. ___12___) \
  416. #define BASE_4x12(...) LAYOUT_4x12_base(__VA_ARGS__)
  417. #define BASE_4x12_bepo(...) LAYOUT_4x12_base_bepo(__VA_ARGS__)
  418. #define BASE_4x12_bepo6(...) LAYOUT_4x12_base_bepo6(__VA_ARGS__)
  419. #define TRANSIENT_4x12(...) LAYOUT_4x12_transient(__VA_ARGS__)
  420. /********************************************************************/
  421. /* CRKBD Corne */
  422. /* The Corne has 3x6 matrix on both sides with 6 thumbs total */
  423. /* This Macro takes 2x3x5 and gives it pinkies, and thumbs. */
  424. /* Arg chunks are in the middle with the passthrough modifiers as */
  425. /* needed. Sama Sama apres cette fois. */
  426. /********************************************************************/
  427. #define Base_3x6_3( \
  428. K01, K02, K03, K04, K05, \
  429. K06, K07, K08, K09, K0A, \
  430. K11, K12, K13, K14, K15, \
  431. K16, K17, K18, K19, K1A, \
  432. K21, K22, K23, K24, K25, \
  433. K26, K27, K28, K29, K2A) \
  434. LAYOUT_VARG( \
  435. ROW1_LEFT(K01, K02, K03, K04, K05), \
  436. ROW1_RIGHT(K06, K07, K08, K09, K0A), \
  437. \
  438. ROW2_LEFT(K11, K12, K13, K14, K15), \
  439. ROW2_RIGHT(K16, K17, K18, K19, K1A), \
  440. \
  441. ROW3_LEFT(K21, K22, K23, K24, K25), \
  442. ROW3_RIGHT(K26, K27, K28, K29, K2A), \
  443. ___6_ERGO_THUMBS___ \
  444. )
  445. // So we can have different transient layers for symbols and numbers on bepo.
  446. // for layouts like dvorak on bepo.
  447. #define Base_bepo_3x6_3( \
  448. K01, K02, K03, K04, K05, \
  449. K06, K07, K08, K09, K0A, \
  450. K11, K12, K13, K14, K15, \
  451. K16, K17, K18, K19, K1A, \
  452. K21, K22, K23, K24, K25, \
  453. K26, K27, K28, K29, K2A \
  454. ) \
  455. LAYOUT_VARG( \
  456. ROW1_LEFT_BP(K01, K02, K03, K04, K05), \
  457. ROW1_RIGHT_BP(K06, K07, K08, K09, K0A), \
  458. \
  459. ROW2_LEFT_BP(K11, K12, K13, K14, K15), \
  460. ROW2_RIGHT_BP(K16, K17, K18, K19, K1A), \
  461. \
  462. ROW3_LEFT_BP(K21, K22, K23, K24, K25), \
  463. ROW3_RIGHT_BP(K26, K27, K28, K29, K2A), \
  464. ___6_ERGO_THUMBS_BP___ \
  465. )
  466. // No room for pinkies.
  467. // Just for bepo because it's a 3x6 matrix on each side.
  468. // So 3 pairs of 6 keys, And we lose our left and right.
  469. // Except it keeps the layer toggles along with the keycode
  470. // on the bottom.
  471. #define Base_bepo6_3x6_3( \
  472. K01, K02, K03, K04, K05, K06, \
  473. K07, K08, K09, K0A, K0B, K0C, \
  474. K11, K12, K13, K14, K15, K16, \
  475. K17, K18, K19, K1A, K1B, K1C, \
  476. K21, K22, K23, K24, K25, K26, \
  477. K27, K28, K29, K2A, K2B, K2C \
  478. ) \
  479. LAYOUT_VARG( \
  480. ROW1_LEFT_BP6(K01, K02, K03, K04, K05, K06), \
  481. ROW1_RIGHT_BP6(K07, K08, K09, K0A, K0B, K0C), \
  482. \
  483. ROW2_LEFT_BP6(K11, K12, K13, K14, K15, K16), \
  484. ROW2_RIGHT_BP6(K17, K18, K19, K1A, K1B, K1C), \
  485. \
  486. ROW3_LEFT_BP6(K21, K22, K23, K24, K25, K26), \
  487. ROW3_RIGHT_BP6(K27, K28, K29, K2A, K2B, K2C), \
  488. ___6_ERGO_THUMBS_BP___ \
  489. )
  490. // All we really need is to add the see through thumbs to the end.
  491. #define Transient6_3x6_3( \
  492. K01, K02, K03, K04, K05, K06, \
  493. K07, K08, K09, K0A, K0B, K0C, \
  494. K11, K12, K13, K14, K15, K16, \
  495. K17, K18, K19, K1A, K1B, K1C, \
  496. K21, K22, K23, K24, K25, K26, \
  497. K27, K28, K29, K2A, K2B, K2C \
  498. ) \
  499. LAYOUT_VARG( \
  500. K01, K02, K03, K04, K05, K06, \
  501. K07, K08, K09, K0A, K0B, K0C, \
  502. K11, K12, K13, K14, K15, K16, \
  503. K17, K18, K19, K1A, K1B, K1C, \
  504. K21, K22, K23, K24, K25, K26, \
  505. K27, K28, K29, K2A, K2B, K2C, \
  506. ___6___)
  507. //---------------------------------------------------------
  508. // 3x5
  509. #define Base_3x5_3( \
  510. K01, K02, K03, K04, K05, \
  511. K06, K07, K08, K09, K0A, \
  512. K11, K12, K13, K14, K15, \
  513. K16, K17, K18, K19, K1A, \
  514. K21, K22, K23, K24, K25, \
  515. K26, K27, K28, K29, K2A) \
  516. LAYOUT_VARG( \
  517. ROW1_LEFT5(K01, K02, K03, K04, K05), \
  518. ROW1_RIGHT5(K06, K07, K08, K09, K0A), \
  519. \
  520. ROW2_LEFT5(K11, K12, K13, K14, K15), \
  521. ROW2_RIGHT5(K16, K17, K18, K19, K1A), \
  522. \
  523. ROW3_LEFT5(K21, K22, K23, K24, K25), \
  524. ROW3_RIGHT5(K26, K27, K28, K29, K2A), \
  525. ___6_ERGO_THUMBS___ \
  526. )
  527. // So we can have different transient layers for symbols and numbers on bepo.
  528. // for layouts like dvorak on bepo.
  529. #define Base_bepo_3x5_3( \
  530. K01, K02, K03, K04, K05, \
  531. K06, K07, K08, K09, K0A, \
  532. K11, K12, K13, K14, K15, \
  533. K16, K17, K18, K19, K1A, \
  534. K21, K22, K23, K24, K25, \
  535. K26, K27, K28, K29, K2A \
  536. ) \
  537. LAYOUT_VARG( \
  538. ROW1_LEFT5_BP(K01, K02, K03, K04, K05), \
  539. ROW1_RIGHT5_BP(K06, K07, K08, K09, K0A), \
  540. \
  541. ROW2_LEFT5_BP(K11, K12, K13, K14, K15), \
  542. ROW2_RIGHT5_BP(K16, K17, K18, K19, K1A), \
  543. \
  544. ROW3_LEFT5_BP(K21, K22, K23, K24, K25), \
  545. ROW3_RIGHT5_BP(K26, K27, K28, K29, K2A), \
  546. ___6_ERGO_THUMBS_BP___ \
  547. )
  548. // All we really need is to add the see through thumbs to the end.
  549. #define Transient5_3x5_3( \
  550. K01, K02, K03, K04, K05, \
  551. K07, K08, K09, K0A, K0B, \
  552. K11, K12, K13, K14, K15, \
  553. K17, K18, K19, K1A, K1B, \
  554. K21, K22, K23, K24, K25, \
  555. K27, K28, K29, K2A, K2B \
  556. ) \
  557. LAYOUT_VARG( \
  558. K01, K02, K03, K04, K05, \
  559. K07, K08, K09, K0A, K0B, \
  560. K11, K12, K13, K14, K15, \
  561. K17, K18, K19, K1A, K1B, \
  562. K21, K22, K23, K24, K25, \
  563. K27, K28, K29, K2A, K2B, \
  564. ___6___)
  565. /********************************************************************/
  566. /* Kinesis*/
  567. /********************************************************************/
  568. // Basically an ergodox ez without the 3 pairs of middle keys.
  569. // Left, right, bottom, and thumbs all stay the same.
  570. #define Base_4x6_4_6( \
  571. K01, K02, K03, K04, K05, \
  572. K06, K07, K08, K09, K0A, \
  573. K11, K12, K13, K14, K15, \
  574. K16, K17, K18, K19, K1A, \
  575. K21, K22, K23, K24, K25, \
  576. K26, K27, K28, K29, K2A, \
  577. K31, K32, K33, K34, K35, \
  578. K36, K37, K38, K39, K3A \
  579. ) \
  580. LAYOUT_PVARG( \
  581. ___KINTFUNC_L___, ___KINTFUNC_R___, \
  582. ROW0_LEFT(K01, K02, K03, K04, K05), \
  583. ROW0_RIGHT(K06, K07, K08, K09, K0A), \
  584. \
  585. ROW1_LEFT(K11, K12, K13, K14, K15), \
  586. ROW1_RIGHT(K16, K17, K18, K19, K1A), \
  587. \
  588. ROW2_LEFT(K21, K22, K23, K24, K25), \
  589. ROW2_RIGHT(K26, K27, K28, K29, K2A), \
  590. \
  591. ROW3_LEFT(K31, K32, K33, K34, K35), \
  592. ROW3_RIGHT(K36, K37, K38, K39, K3A), \
  593. ___4_BOTTOM_LEFT___, ___4_BOTTOM_RIGHT___, \
  594. ___12_DOX_ALL_THUMBS___ \
  595. )
  596. #define Base_bepo_4x6_4_6( \
  597. K01, K02, K03, K04, K05, \
  598. K06, K07, K08, K09, K0A, \
  599. K11, K12, K13, K14, K15, \
  600. K16, K17, K18, K19, K1A, \
  601. K21, K22, K23, K24, K25, \
  602. K26, K27, K28, K29, K2A, \
  603. K31, K32, K33, K34, K35, \
  604. K36, K37, K38, K39, K3A \
  605. ) \
  606. LAYOUT_PVARG( \
  607. ___KINTFUNC_L___, ___KINTFUNC_R___, \
  608. ROW0_LEFT(K01, K02, K03, K04, K05), \
  609. ROW0_RIGHT(K06, K07, K08, K09, K0A), \
  610. \
  611. ROW1_LEFT(K11, K12, K13, K14, K15), \
  612. ROW1_RIGHT(K16, K17, K18, K19, K1A), \
  613. \
  614. ROW2_LEFT(K21, K22, K23, K24, K25), \
  615. ROW2_RIGHT(K26, K27, K28, K29, K2A), \
  616. \
  617. ROW3_LEFT(K31, K32, K33, K34, K35), \
  618. ROW3_RIGHT(K36, K37, K38, K39, K3A), \
  619. ___4_BOTTOM_LEFT___, ___4_BOTTOM_RIGHT___, \
  620. ___12_DOX_ALL_THUMBS_BP___ \
  621. )
  622. // So 3 pairs of 6 keys, left and right.
  623. #define Base_bepo6_4x6_4_6( \
  624. K01, K02, K03, K04, K05, K06, \
  625. K07, K08, K09, K0A, K0B, K0C, \
  626. K11, K12, K13, K14, K15, K16, \
  627. K17, K18, K19, K1A, K1B, K1C, \
  628. K21, K22, K23, K24, K25, K26, \
  629. K27, K28, K29, K2A, K2B, K2C \
  630. ) \
  631. LAYOUT_PVARG( \
  632. ___KINTFUNC_L___, ___KINTFUNC_R___, \
  633. ___6SYMBOL_BEPO_L___, \
  634. ___6SYMBOL_BEPO_R___, \
  635. ROW1_LEFT_BP6(K01, K02, K03, K04, K05, K06), \
  636. ROW1_RIGHT_BP6(K07, K08, K09, K0A, K0B, K0C), \
  637. \
  638. ROW2_LEFT_BP6(K11, K12, K13, K14, K15, K16), \
  639. ROW2_RIGHT_BP6(K17, K18, K19, K1A, K1B, K1C), \
  640. \
  641. ROW3_LEFT_BP6(K21, K22, K23, K24, K25, K26), \
  642. ROW3_RIGHT_BP6(K27, K28, K29, K2A, K2B, K2C), \
  643. ___4_BOTTOM_LEFT_BP___, ___4_BOTTOM_RIGHT_BP___, \
  644. ___12_DOX_ALL_THUMBS_BP___ \
  645. )
  646. #define Transient6_4x6_4_6( \
  647. K01, K02, K03, K04, K05, K06, \
  648. K07, K08, K09, K0A, K0B, K0C, \
  649. K11, K12, K13, K14, K15, K16, \
  650. K17, K18, K19, K1A, K1B, K1C, \
  651. K21, K22, K23, K24, K25, K26, \
  652. K27, K28, K29, K2A, K2B, K2C, \
  653. K31, K32, K33, K34, K35, K36, \
  654. K37, K38, K39, K3A, K3B, K3C \
  655. ) \
  656. LAYOUT_PVARG( \
  657. ___KINTFUNC_L___, ___KINTFUNC_R___, \
  658. K01, K02, K03, K04, K05, K06, \
  659. K07, K08, K09, K0A, K0B, K0C, \
  660. K11, K12, K13, K14, K15, K16, \
  661. K17, K18, K19, K1A, K1B, K1C, \
  662. K21, K22, K23, K24, K25, K26, \
  663. K27, K28, K29, K2A, K2B, K2C, \
  664. K31, K32, K33, K34, K35, K36, \
  665. K37, K38, K39, K3A, K3B, K3C, \
  666. ___4___, ___4___, \
  667. ___12___ \
  668. )