diff options
Diffstat (limited to 'keyboards/planck/keymaps/luke/keymap.c')
-rw-r--r-- | keyboards/planck/keymaps/luke/keymap.c | 39 |
1 files changed, 20 insertions, 19 deletions
diff --git a/keyboards/planck/keymaps/luke/keymap.c b/keyboards/planck/keymaps/luke/keymap.c index 26dcb451b..5fc895803 100644 --- a/keyboards/planck/keymaps/luke/keymap.c +++ b/keyboards/planck/keymaps/luke/keymap.c | |||
@@ -1,18 +1,18 @@ | |||
1 | /* | 1 | /* |
2 | * A keyboard layout for the gridded planck. | 2 | * A keyboard layout for the gridded planck. |
3 | * | 3 | * |
4 | * Copyright (C) 2017 Luke Silva | 4 | * Copyright (C) 2017 Luke Silva |
5 | * | 5 | * |
6 | * This program is free software; you can redistribute it and/or | 6 | * This program is free software; you can redistribute it and/or |
7 | * modify it under the terms of the GNU General Public License | 7 | * modify it under the terms of the GNU General Public License |
8 | * as published by the Free Software Foundation; either version 2 | 8 | * as published by the Free Software Foundation; either version 2 |
9 | * of the License, or (at your option) any later version. | 9 | * of the License, or (at your option) any later version. |
10 | * | 10 | * |
11 | * This program is distributed in the hope that it will be useful, | 11 | * This program is distributed in the hope that it will be useful, |
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
14 | * GNU General Public License for more details. | 14 | * GNU General Public License for more details. |
15 | * | 15 | * |
16 | * You should have received a copy of the GNU General Public License | 16 | * You should have received a copy of the GNU General Public License |
17 | * along with this program; if not, write to the Free Software | 17 | * along with this program; if not, write to the Free Software |
18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | 18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
@@ -31,7 +31,7 @@ | |||
31 | * through either double purpose modifiers or colemak style rolling for commonly used symbol clusters | 31 | * through either double purpose modifiers or colemak style rolling for commonly used symbol clusters |
32 | * Eg: compare colemak 'this' to '(){\n}' on the symbol layer. | 32 | * Eg: compare colemak 'this' to '(){\n}' on the symbol layer. |
33 | * | 33 | * |
34 | * The layout also supports a range of multilingual characters, covering those | 34 | * The layout also supports a range of multilingual characters, covering those |
35 | * needed for French, German, Swedish and likely some other European Languages. | 35 | * needed for French, German, Swedish and likely some other European Languages. |
36 | * In the future full support for Colemak's multilingual deadkeys may be introduced. | 36 | * In the future full support for Colemak's multilingual deadkeys may be introduced. |
37 | * | 37 | * |
@@ -41,6 +41,7 @@ | |||
41 | */ | 41 | */ |
42 | 42 | ||
43 | 43 | ||
44 | #pragma message "You may need to add LAYOUT_planck_grid to your keymap layers - see default for an example" | ||
44 | #include "planck.h" | 45 | #include "planck.h" |
45 | 46 | ||
46 | #define _______ KC_TRNS | 47 | #define _______ KC_TRNS |
@@ -61,10 +62,10 @@ | |||
61 | // Macro ID numbers | 62 | // Macro ID numbers |
62 | #define M_ALT_HASH 1 | 63 | #define M_ALT_HASH 1 |
63 | #define M_GR_DASH 2 | 64 | #define M_GR_DASH 2 |
64 | #define M_SYM_LPRN 3 | 65 | #define M_SYM_LPRN 3 |
65 | #define M_NAV_UNDS 4 | 66 | #define M_NAV_UNDS 4 |
66 | #define M_NUM_RPRN 5 | 67 | #define M_NUM_RPRN 5 |
67 | #define M_CTRL_DLR 6 | 68 | #define M_CTRL_DLR 6 |
68 | #define M_LCBR_ENT 7 | 69 | #define M_LCBR_ENT 7 |
69 | #define M_PLOVER 8 | 70 | #define M_PLOVER 8 |
70 | #define M_EXT_PLV 9 | 71 | #define M_EXT_PLV 9 |
@@ -76,7 +77,7 @@ | |||
76 | #define M_CATCH 15 | 77 | #define M_CATCH 15 |
77 | 78 | ||
78 | // Macro keys | 79 | // Macro keys |
79 | #define ALT_HASH MACROTAP(M_ALT_HASH) // tap for #, hold for Alt | 80 | #define ALT_HASH MACROTAP(M_ALT_HASH) // tap for #, hold for Alt |
80 | #define GR_DASH MACROTAP(M_GR_DASH) // tap for -, hold for GR layer a-class-name | 81 | #define GR_DASH MACROTAP(M_GR_DASH) // tap for -, hold for GR layer a-class-name |
81 | #define SYM_LPRN MACROTAP(M_SYM_LPRN) // tap for (, hold for symbols layer if() | 82 | #define SYM_LPRN MACROTAP(M_SYM_LPRN) // tap for (, hold for symbols layer if() |
82 | #define NAV_UNDS MACROTAP(M_NAV_UNDS) // tap for _, hold for navigation layer snake_case_variable | 83 | #define NAV_UNDS MACROTAP(M_NAV_UNDS) // tap for _, hold for navigation layer snake_case_variable |
@@ -123,7 +124,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
123 | }, | 124 | }, |
124 | 125 | ||
125 | 126 | ||
126 | 127 | ||
127 | /* QWERTY | 128 | /* QWERTY |
128 | * ,-----------------------------------------------------------------------------------. | 129 | * ,-----------------------------------------------------------------------------------. |
129 | * | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp | | 130 | * | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp | |
@@ -155,7 +156,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
155 | * | | | | | Sym | _ |Space | NUM | X2 | | | | | 156 | * | | | | | Sym | _ |Space | NUM | X2 | | | | |
156 | * `-----------------------------------------------------------------------------------' | 157 | * `-----------------------------------------------------------------------------------' |
157 | */ | 158 | */ |
158 | 159 | ||
159 | [_SYM] = { | 160 | [_SYM] = { |
160 | {KC_TAB, KC_GRV, KC_AT, KC_SLSH, KC_ASTR, KC_CIRC, KC_PERC, KC_COLN, KC_PLUS, KC_MINS, KC_DEL, KC_BSPC}, | 161 | {KC_TAB, KC_GRV, KC_AT, KC_SLSH, KC_ASTR, KC_CIRC, KC_PERC, KC_COLN, KC_PLUS, KC_MINS, KC_DEL, KC_BSPC}, |
161 | {FUNCTION,KC_LBRC, KC_SCLN, KC_RCBR, KC_LPRN, KC_DQT, KC_QUOT, KC_RPRN, LCBR_ENT,KC_EXLM, KC_RBRC, KC_BSLS}, | 162 | {FUNCTION,KC_LBRC, KC_SCLN, KC_RCBR, KC_LPRN, KC_DQT, KC_QUOT, KC_RPRN, LCBR_ENT,KC_EXLM, KC_RBRC, KC_BSLS}, |
@@ -175,7 +176,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
175 | * | | | | GR | SYM | _ |Space | NUM | 0 | . | f | | | 176 | * | | | | GR | SYM | _ |Space | NUM | 0 | . | f | | |
176 | * `-----------------------------------------------------------------------------------' | 177 | * `-----------------------------------------------------------------------------------' |
177 | */ | 178 | */ |
178 | 179 | ||
179 | [_NUM] = { | 180 | [_NUM] = { |
180 | {KC_TAB, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC}, | 181 | {KC_TAB, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC}, |
181 | {KC_BSPC, KC_X, S(KC_D), S(KC_E), S(KC_F), KC_PLUS, KC_MINS, KC_4, KC_5, KC_6, KC_0, KC_ENT }, | 182 | {KC_BSPC, KC_X, S(KC_D), S(KC_E), S(KC_F), KC_PLUS, KC_MINS, KC_4, KC_5, KC_6, KC_0, KC_ENT }, |
@@ -195,7 +196,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
195 | * | | | | | | | | | | | | | | 196 | * | | | | | | | | | | | | | |
196 | * `-----------------------------------------------------------------------------------' | 197 | * `-----------------------------------------------------------------------------------' |
197 | */ | 198 | */ |
198 | 199 | ||
199 | [_GR] = { | 200 | [_GR] = { |
200 | {_______, UC(0xE4),UC(0xE5), _______,UC(0xA2), UC(0x20AC),_______,UC(0xEB),UC(0xEA),UC(0xFC),UC(0xF9), _______}, | 201 | {_______, UC(0xE4),UC(0xE5), _______,UC(0xA2), UC(0x20AC),_______,UC(0xEB),UC(0xEA),UC(0xFC),UC(0xF9), _______}, |
201 | {_______, UC(0xE2),UC(0xE0),UC(0xDF), _______, _______, _______,UC(0xE8),UC(0xE9),UC(0xEF),UC(0xF6), _______}, | 202 | {_______, UC(0xE2),UC(0xE0),UC(0xDF), _______, _______, _______,UC(0xE8),UC(0xE9),UC(0xEF),UC(0xF6), _______}, |
@@ -223,7 +224,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
223 | * | | | | | | | | | | | | | | 224 | * | | | | | | | | | | | | | |
224 | * `-----------------------------------------------------------------------------------' | 225 | * `-----------------------------------------------------------------------------------' |
225 | */ | 226 | */ |
226 | 227 | ||
227 | [_ADJ] = { | 228 | [_ADJ] = { |
228 | {KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12 }, | 229 | {KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12 }, |
229 | {XXXXXXX, XXXXXXX, KC_PSCR, KC_ESC, KC_VOLU, KC_MPLY, KC_MPRV, QWERTY, COLEMAK, PLOVER, XXXXXXX, XXXXXXX}, | 230 | {XXXXXXX, XXXXXXX, KC_PSCR, KC_ESC, KC_VOLU, KC_MPLY, KC_MPRV, QWERTY, COLEMAK, PLOVER, XXXXXXX, XXXXXXX}, |
@@ -243,7 +244,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
243 | * | | | | | | _ |Space | ACL0 | ACL1 | ACL2 | |TGLNAV| | 244 | * | | | | | | _ |Space | ACL0 | ACL1 | ACL2 | |TGLNAV| |
244 | * `-----------------------------------------------------------------------------------' | 245 | * `-----------------------------------------------------------------------------------' |
245 | */ | 246 | */ |
246 | 247 | ||
247 | [_NAV] = { | 248 | [_NAV] = { |
248 | {XXXXXXX, XXXXXXX, KC_BTN3, KC_BTN2, KC_BTN1, XXXXXXX, KC_ACL0, KC_HOME, KC_PGDN, KC_PGUP, KC_END, KC_BSPC}, | 249 | {XXXXXXX, XXXXXXX, KC_BTN3, KC_BTN2, KC_BTN1, XXXXXXX, KC_ACL0, KC_HOME, KC_PGDN, KC_PGUP, KC_END, KC_BSPC}, |
249 | {XXXXXXX, KC_MS_L, KC_MS_D, KC_MS_U, KC_MS_R, XXXXXXX, KC_ACL1, KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT,KC_ENT }, | 250 | {XXXXXXX, KC_MS_L, KC_MS_D, KC_MS_U, KC_MS_R, XXXXXXX, KC_ACL1, KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT,KC_ENT }, |
@@ -312,16 +313,16 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) | |||
312 | layer_and(0); | 313 | layer_and(0); |
313 | layer_on(_PLOVER); | 314 | layer_on(_PLOVER); |
314 | default_layer_set(_PLOVER); | 315 | default_layer_set(_PLOVER); |
315 | 316 | ||
316 | // Starts plover | 317 | // Starts plover |
317 | return MACRO(I(10), D(E), D(R), D(F), D(V), D(I), D(K), U(E), U(R), U(F), U(V), U(I), U(K), END); | 318 | return MACRO(I(10), D(E), D(R), D(F), D(V), D(I), D(K), U(E), U(R), U(F), U(V), U(I), U(K), END); |
318 | } | 319 | } |
319 | break; | 320 | break; |
320 | case M_EXT_PLV: | 321 | case M_EXT_PLV: |
321 | if (!record->event.pressed) { | 322 | if (!record->event.pressed) { |
322 | layer_off(_PLOVER); | 323 | layer_off(_PLOVER); |
323 | default_layer_set(_COLEMAK); | 324 | default_layer_set(_COLEMAK); |
324 | 325 | ||
325 | //Pauses plover | 326 | //Pauses plover |
326 | return MACRO(I(10), D(E), D(R), D(F), D(V), D(Y), D(U), U(E), U(R), U(F), U(V), U(Y), U(U), END); | 327 | return MACRO(I(10), D(E), D(R), D(F), D(V), D(Y), D(U), U(E), U(R), U(F), U(V), U(Y), U(U), END); |
327 | } | 328 | } |