playing a bit with cursor keys

example_keyboards
Stephan Bösebeck 9 years ago
parent 240db0c7d8
commit 4beb0115ff

@ -6,13 +6,23 @@
#define BASE 0 // default layer #define BASE 0 // default layer
#define SYMB 1 // symbols #define SYMB 1 // symbols
#define MDIA 2 // media keys #define MDIA 2 // media keys
#define CRSR 3 // media keys #define SMLY 3 // media keys
#define NUMB 4 // number keys #define NUMB 4 // number keys
#define M_CTRL_CMDV 1 #define M_CTRL_CMDV 1
#define M_CTRL_CMDC 2 #define M_CTRL_CMDC 2
#define M_MEH_SH_ACUT 3 #define M_MEH_SH_ACUT 3
#define SM_SMILE 4
#define SM_SMIRK 5
#define SM_FROWN 6
#define SM_CRY 7
#define SM_KISS 8
#define SM_HEART 9
#define SM_LAUGH 10
#define SM_SAD 11
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Keymap 0: Basic layer /* Keymap 0: Basic layer
* *
@ -43,16 +53,16 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TAB, DE_Q, DE_W, DE_E, DE_R, DE_T, KC_LGUI, KC_TAB, DE_Q, DE_W, DE_E, DE_R, DE_T, KC_LGUI,
KC_LALT, DE_A, DE_S, DE_D, DE_F, DE_G, KC_LALT, DE_A, DE_S, DE_D, DE_F, DE_G,
KC_LSFT, CTL_T(DE_Y), DE_X, DE_C, DE_V, DE_B, KC_LALT, KC_LSFT, CTL_T(DE_Y), DE_X, DE_C, DE_V, DE_B, KC_LALT,
LT(SYMB,DE_LESS), DE_CIRC, LALT(KC_LSFT), KC_LEFT,KC_RGHT, LT(SYMB,DE_LESS), DE_CIRC, DE_PLUS, LALT(KC_LSFT), LGUI(KC_LSFT),
M(M_MEH_SH_ACUT), TG(2), M(M_MEH_SH_ACUT), TG(2),
KC_HOME, KC_HOME,
KC_BSPC,KC_DEL, KC_END, KC_BSPC,KC_DEL, LT(SMLY,KC_END),
// right hand // right hand
M(M_CTRL_CMDC), DE_6, DE_7, DE_8, DE_9, DE_0, DE_SS, M(M_CTRL_CMDC), DE_6, DE_7, DE_8, DE_9, DE_0, DE_SS,
KC_RGUI, DE_Z, DE_U, DE_I, DE_O, DE_P, DE_UE, KC_RGUI, DE_Z, DE_U, DE_I, DE_O, DE_P, DE_UE,
DE_H, DE_J, DE_K, DE_L, DE_OE, ALT_T(DE_AE), DE_H, DE_J, DE_K, DE_L, DE_OE, ALT_T(DE_AE),
KC_RALT, DE_N, DE_M, DE_COMM,DE_DOT, CTL_T(DE_MINS), KC_RSFT, KC_RALT, DE_N, DE_M, DE_COMM,DE_DOT, CTL_T(DE_MINS), KC_RSFT,
KC_UP, KC_DOWN,LGUI(KC_LSFT),DE_PLUS, LT(SYMB,DE_HASH), KC_LEFT, KC_DOWN,KC_UP,KC_RIGHT, LT(SYMB,DE_HASH),
TG(4), ALL_T(DE_ACUT), TG(4), ALL_T(DE_ACUT),
KC_PGUP, KC_PGUP,
KC_PGDN,KC_ENT, KC_SPC KC_PGDN,KC_ENT, KC_SPC
@ -140,20 +150,20 @@ KEYMAP(
KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_WBAK KC_TRNS, KC_TRNS, KC_WBAK
), ),
// ADNW-KOY layer /* Keymap 3: Smiley layer
/* Keymap 3: ADNW-Koy layer * making it easier to type smileys... tipp: on osx you can easily replace those smileys with the UTF-8 character using
* ADNW-Koy is a special layout designed to be ergonomic. Was created using software to determine the most ergonomic way to type German and English texts. * keyboard short commands...
* *
* ,--------------------------------------------------. ,--------------------------------------------------. * ,--------------------------------------------------. ,--------------------------------------------------.
* | | | | | | | | | | | | | | | - | * | | | | | | | | | :-) | ;-) | :-D | | | | |
* |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------| * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
* | | K | . | O | , | Y | | | | V | G | C | L | ß | Z | * | | | | | | | | | | :-{ | :-( | | | | |
* |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
* | | H | A | E | I | U |------| |------| D | T | R | N | S | F/L2 | * | | | | | | |------| |------| <3 | :-* | | | | |
* |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
* | |X/Ctrl| Q | Ä | Ü | Ö | | | | B | P | W | M |J/Ctrl| RShift | * | | | | | | | | | | | | | | | |
* `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------' * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
* |</L1| ^ |AltShf| Left | Right| | Up | Down | CMD-SHIFT | ´ | //L1 | * | | | | | | | | | | | r|
* `----------------------------------' `----------------------------------' * `----------------------------------' `----------------------------------'
* ,-------------. ,-------------. * ,-------------. ,-------------.
* | | | | | | * | | | | | |
@ -165,18 +175,18 @@ KEYMAP(
*/ */
KEYMAP( KEYMAP(
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_K, KC_DOT, KC_O, KC_COMM, KC_Z, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_H, KC_A, KC_E, KC_I, KC_U, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, CTL_T(KC_X),KC_Q, DE_AE, DE_UE, DE_OE, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
// right hand // right hand
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_SLSH, M(SM_SMILE), M(SM_SMIRK), M(SM_LAUGH), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_V, KC_G, KC_C, KC_L, KC_MINS, KC_Y, KC_TRNS, M(SM_FROWN), M(SM_SAD), M(SM_CRY), KC_TRNS, KC_TRNS, KC_TRNS,
KC_D, KC_T, KC_R, KC_N, KC_S, LT(MDIA,KC_F), M(SM_HEART), M(SM_KISS), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_B, KC_P, KC_W, KC_M, CTL_T(KC_J), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS,
@ -195,9 +205,9 @@ KEYMAP(
// right hand // right hand
KC_TRNS, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_TRNS, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
KC_TRNS, KC_UP, KC_7, KC_8, KC_9, LSFT(KC_RBRC), KC_F12, KC_TRNS, KC_UP, KC_7, KC_8, KC_9, LSFT(KC_RBRC), KC_F12,
KC_DOWN, KC_4, KC_5, KC_6, KC_RBRC, KC_TRNS, KC_DOWN, KC_4, KC_5, KC_6, KC_RBRC, DE_MINS,
KC_TRNS, LSFT(KC_6), KC_1, KC_2, KC_3, LSFT(KC_7), KC_TRNS, KC_TRNS, LSFT(KC_6), KC_1, KC_2, KC_3, LSFT(KC_7), KC_TRNS,
KC_0,KC_DOT, KC_0, KC_EQL, KC_TRNS, KC_0,KC_DOT, KC_0, DE_EQL, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS KC_TRNS, KC_TRNS, KC_TRNS
@ -206,7 +216,7 @@ KEYMAP(
const uint16_t PROGMEM fn_actions[] = { const uint16_t PROGMEM fn_actions[] = {
[1] = ACTION_LAYER_TAP_TOGGLE(SYMB), // FN1 - Momentary Layer 1 (Symbols) [1] = ACTION_LAYER_TAP_TOGGLE(SYMB), // FN1 - Momentary Layer 1 (Symbols)
[2] = ACTION_LAYER_TAP_TOGGLE(CRSR) // FN2 - Momentary Layer 2 (Cursors) [2] = ACTION_LAYER_TAP_TOGGLE(SMLY) // FN2 - Momentary Layer 2 (Smiley)
}; };
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
@ -257,6 +267,49 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
} }
} }
break; break;
case SM_SMILE:
if (record->event.pressed) {
return MACRO(D(LSFT),T(DOT),U(LSFT),T(SLSH),D(LSFT),T(9),U(LSFT),END);
}
break;
case SM_SMIRK:
if (record->event.pressed) {
return MACRO(D(LSFT),T(COMM),U(LSFT),T(SLSH),D(LSFT),T(9),U(LSFT),END);
}
break;
case SM_CRY:
if (record->event.pressed) {
return MACRO(D(LSFT),T(COMM),U(LSFT),T(SLSH),D(LSFT),T(8),U(LSFT),END);
}
break;
case SM_SAD:
if (record->event.pressed) {
return MACRO(D(LSFT),T(DOT),U(LSFT),T(SLSH),D(LSFT),T(8),U(LSFT),END);
}
break;
case SM_HEART:
if (record->event.pressed) {
return MACRO(T(GRV),T(3),END);
}
break;
case SM_LAUGH:
if (record->event.pressed) {
return MACRO(D(LSFT),T(DOT),U(LSFT),T(SLSH),D(LSFT),T(D),U(LSFT),END);
}
break;
case SM_KISS:
if (record->event.pressed) {
return MACRO(D(LSFT),T(DOT),U(LSFT),T(SLSH),D(LSFT),T(RBRC),U(LSFT),END);
}
break;
case SM_FROWN:
if (record->event.pressed) {
return MACRO(D(LSFT),T(DOT),U(LSFT),T(SLSH),D(LALT),T(8),U(LALT),END);
}
break;
} }
return MACRO_NONE; return MACRO_NONE;
}; };

Loading…
Cancel
Save