alt_mods.h 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129
  1. #pragma once
  2. /*
  3. Copyright 2018-2022 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. //
  16. // non Home row mods, mod layer.
  17. // MOD_ROW variants.
  18. // input 5 get six, left and right language specific outer edge keys.
  19. // no edge keys.
  20. // input 5 get 5 with mods applied.
  21. // input 6 get 6 with mods applied.
  22. // base cols in out. 5, 5_6, 6.
  23. // input column count, output column count, if different.
  24. // L_5 Left R_5 Right.
  25. // K01, K02, K03, K04, K05 - K01, K02, K03, K04, K05
  26. // pky, rng, mdl, idx, idx - idx, idx, mdl, rng, pnky
  27. // ROW0 - Number row.
  28. // LEFT.
  29. #define ROW0L_5_alt(K01, K02, K03, K04, K05) \
  30. K01, K02, K03, K04, K05
  31. // take and put an extra column in front. Mod K01 how you want it.
  32. #define ROW0L_6_alt(K01, K02, K03, K04, K05, K06) K01, \
  33. ROW0L_5_alt(K02, K03, K04, K05, K06)
  34. // 5 into 6, derivitive of the first two.
  35. #define ROW0L_5_6_alt(K01, K02, K03, K04, K05) \
  36. ROW0L_6_alt(LEFT_0, K01, K02, K03, K04, K05)
  37. // RIGHT.
  38. #define ROW0R_5_alt(K01, K02, K03, K04, K05) \
  39. K01, K02, K03, K04, K05
  40. // take and put an extra column in front. Mod K01 how you want it.
  41. #define ROW0R_6_alt(K01, K02, K03, K04, K05, K06) \
  42. ROW0R_5_alt(K01, K02, K03, K04, K05), K06
  43. // 5 into 6, derivitive of the first two.
  44. #define ROW0R_5_6_alt(K01, K02, K03, K04, K05) \
  45. ROW0R_6_alt(K01, K02, K03, K04, K05, RIGHT_0)
  46. // ROW1
  47. // LEFT.
  48. #define ROW1L_5_alt(K01, K02, K03, K04, K05) \
  49. K01, K02, K03, K04, K05
  50. // take and put an extra column in front. Mod K01 how you want it.
  51. #define ROW1L_6_alt(K01, K02, K03, K04, K05, K06) K01, \
  52. ROW1L_5_alt(K02, K03, K04, K05, K06)
  53. // 5 into 6, derivitive of the first two.
  54. #define ROW1L_5_6_alt(K01, K02, K03, K04, K05) \
  55. ROW1L_6_alt(LEFT_1, K01, K02, K03, K04, K05)
  56. // RIGHT.
  57. #define ROW1R_5_alt(K01, K02, K03, K04, K05) \
  58. K01, K02, K03, K04, K05 \
  59. // take and put an extra column in front. Mod K01 how you want it.
  60. #define ROW1R_6_alt(K01, K02, K03, K04, K05, K06) \
  61. ROW1R_5_alt(K01, K02, K03, K04, K05), K06
  62. // 5 into 6, derivitive of the first two.
  63. #define ROW1R_5_6_alt(K01, K02, K03, K04, K05) \
  64. ROW1R_6_alt(K01, K02, K03, K04, K05, RIGHT_1)
  65. // HOME ROW - ROW2
  66. // LEFT.
  67. #define ROW2L_5_alt(K01, K02, K03, K04, K05) \
  68. K01, K02, LT(_NAV, K03), MT(MOD_LSFT, K04), K05
  69. // take and put an extra column in front. Mod K01 how you want it.
  70. #define ROW2L_6_alt(K01, K02, K03, K04, K05, K06) K01, \
  71. ROW2L_5_alt(K02, K03, K04, K05, K06)
  72. // 5 into 6, derivitive of the first two.
  73. #define ROW2L_5_6_alt(K01, K02, K03, K04, K05) \
  74. ROW2L_6_alt(LEFT_2, K01, K02, K03, K04, K05)
  75. // RIGHT.
  76. #define ROW2R_5_alt(K01, K02, K03, K04, K05) \
  77. K01, MT(MOD_LSFT, K02), LT(_NAV, K03), K04, K05 \
  78. // take and put an extra column in front. Mod K01 how you want it.
  79. #define ROW2R_6_alt(K01, K02, K03, K04, K05, K06) \
  80. ROW2R_5_alt(K01, K02, K03, K04, K05), K06
  81. // 5 into 6, derivitive of the first two.
  82. #define ROW2R_5_6_alt(K01, K02, K03, K04, K05) \
  83. ROW2R_6_alt(K01, K02, K03, K04, K05, RIGHT_2)
  84. // ROW 3
  85. // LEFT.
  86. #define ROW3L_5_alt(K01, K02, K03, K04, K05) \
  87. K01, K02, LT(_NAV, K03), K04, MT(MOD_LSFT, K05)
  88. // take and put an extra column in front. Mod K01 how you want it.
  89. #define ROW3L_6_alt(K01, K02, K03, K04, K05, K06) K01, \
  90. ROW3L_5_alt(K02, K03, K04, K05, K06)
  91. // 5 into 6, derivitive of the first two.
  92. #define ROW3L_5_6_alt(K01, K02, K03, K04, K05) \
  93. ROW3L_6_alt(LEFT_3, K01, K02, K03, K04, K05)
  94. // RIGHT.
  95. #define ROW3R_5_alt(K01, K02, K03, K04, K05) \
  96. K01, K02, K03, K04, K05
  97. // take and put an extra column in front. Mod K01 how you want it.
  98. #define ROW3R_6_alt(K01, K02, K03, K04, K05, K06) K01, \
  99. ROW3R_5_alt(K02, K03, K04, K05, K06)
  100. // 5 into 6, derivitive of the first two.
  101. #define ROW3R_5_6_alt(K01, K02, K03, K04, K05) \
  102. ROW3R_6_alt(K01, K02, K03, K04, K05, RIGHT_3)