mirror of
https://github.com/qmk/qmk_userspace.git
synced 2025-05-05 15:14:17 -04:00
Reshuffle Number Layer and Cleanup
- remove mods on number layer - function keys on top, numbers now on middle - added media keys to number layer - updated documentation
This commit is contained in:
parent
2d3c6f2f4e
commit
20cdbdd1a5
4 changed files with 36 additions and 19 deletions
|
@ -33,9 +33,9 @@ layers:
|
|||
- NAV
|
||||
- {t: Mute, type: ghost}
|
||||
NAV:
|
||||
- [null, Home, ▲, End, Page Up, Caps Lock, Tab, null, Print Screen, CONFIG ]
|
||||
- [null, ◄, ▼, ►, Page Down, Back Space, Shift, Ctrl, Alt, Gui ]
|
||||
- [Undo, Cut, Copy, Paste, Redo, Delete, App, Sniper Toggle, Sniper DPI, Pointer DPI ]
|
||||
- [null, Home, ▲, End, Page Up, null, null, Caps Lock, Print Screen, CONFIG ]
|
||||
- [null, ◄, ▼, ►, Page Down, null, Shift, Ctrl, Alt, Gui ]
|
||||
- [Undo, Cut, Copy, Paste, Redo, null, App, Sniper Toggle, Sniper DPI, Pointer DPI ]
|
||||
- {t: Zoom Reset, type: ghost}
|
||||
- NUM
|
||||
- Space
|
||||
|
@ -53,9 +53,9 @@ layers:
|
|||
- NAV
|
||||
- {type: ghost}
|
||||
NUM:
|
||||
- [F7, F5, F3, F1, F9, F8, F10, F2, F4, F6]
|
||||
- ['7', '5', '3', '1', '9', '8', '0', '2' , '4', '6' ]
|
||||
- [Gui, Alt, Ctrl, Shift, F11, F12, null, Vol- , Vol+, Mute]
|
||||
- [F7, F5, F3, F1, F9, F8, F10, F2 , F4, F6]
|
||||
- [Mute, Vol-, Vol+, Next, Play Pause, F11, F12, {h: '(', t: ','} , {h: ')', t: '.'}, {h: '_', t: '-'}]
|
||||
- {type: ghost}
|
||||
- {type: held}
|
||||
- null
|
||||
|
@ -82,6 +82,5 @@ combos:
|
|||
- { p: [6, 7], k: Tab, l: [base_QWERTY] }
|
||||
- { p: [22, 23], k: Enter, l: [base_QWERTY] }
|
||||
- { p: [26, 27], k: Bksp, l: [base_QWERTY] }
|
||||
- { p: [27, 28], k: Del, l: [base_QWERTY] }
|
||||
draw_config:
|
||||
small_pad: 6
|
BIN
my_keymap.png
BIN
my_keymap.png
Binary file not shown.
Before Width: | Height: | Size: 134 KiB After Width: | Height: | Size: 133 KiB |
|
@ -43,33 +43,51 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||
|
||||
case KC_BSPC: {
|
||||
//https://docs.qmk.fm/#/feature_advanced_keycodes?id=shift-backspace-for-delete
|
||||
|
||||
// Initialize a boolean variable that keeps track
|
||||
// of the delete key status: registered or not?
|
||||
static bool delkey_registered = false;
|
||||
|
||||
if (record->event.pressed) {
|
||||
// Detect the activation of either shift keys
|
||||
|
||||
uint8_t current_mod = get_mods();
|
||||
uint8_t current_osm = get_oneshot_mods();
|
||||
|
||||
// Detect the activation of either shift keys
|
||||
if ((current_mod | current_osm) & MOD_MASK_SHIFT) {
|
||||
|
||||
// First temporarily canceling both shifts so that
|
||||
// shift isn't applied to the KC_DEL keycode
|
||||
del_mods(MOD_MASK_SHIFT);
|
||||
del_oneshot_mods(MOD_MASK_SHIFT);
|
||||
|
||||
// Press delete and keep track that key press
|
||||
register_code(KC_DEL);
|
||||
delkey_registered = true;
|
||||
|
||||
// Reapplying modifier state so that the held shift key(s)
|
||||
// still work even after having tapped the Backspace/Delete key
|
||||
set_mods(current_mod);
|
||||
set_oneshot_mods(current_osm);
|
||||
|
||||
return false;
|
||||
|
||||
}
|
||||
|
||||
} else {
|
||||
|
||||
} else { // on release of KC_BSPC
|
||||
|
||||
if(delkey_registered) {
|
||||
|
||||
unregister_code(KC_DEL);
|
||||
delkey_registered = false;
|
||||
return false;
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
// QMK will process Backspace instead
|
||||
// if the shift modifier is not detected
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
@ -184,9 +184,9 @@ enum keycodes {
|
|||
|
||||
|
||||
#define LAYER_NAVIGATION \
|
||||
___x___, KC_HOME, KC_UP, KC_END, KC_PGUP, KC_CAPS, KC_TAB, ___x___, KC_PSCR, CONFIG, \
|
||||
___x___, KC_LEFT, KC_DOWN, KC_RGHT, KC_PGDN, KC_BSPC, _SCAG_MODS________________________, \
|
||||
_UCCPR_L___________________________________, KC_DEL, KC_APP, TR_SNIP, TR_SDPI, TR_PDPI, \
|
||||
___x___, KC_HOME, KC_UP, KC_END, KC_PGUP, ___x___, ___x___, KC_CAPS, KC_PSCR, CONFIG, \
|
||||
___x___, KC_LEFT, KC_DOWN, KC_RGHT, KC_PGDN, ___x___, _SCAG_MODS________________________, \
|
||||
_UCCPR_L___________________________________, ___x___, KC_APP, TR_SNIP, TR_SDPI, TR_PDPI, \
|
||||
ZOOMRST, SYM, KC_ENT, _LAYER_TRANS_____________
|
||||
|
||||
|
||||
|
@ -198,16 +198,16 @@ enum keycodes {
|
|||
|
||||
|
||||
#define LAYER_NUMBER \
|
||||
KC_F7, KC_F5, KC_F3, KC_F1, KC_F9, KC_F8, KC_F10, KC_F2, KC_F4, KC_F6, \
|
||||
KC_7, KC_5, KC_3, KC_1, KC_9, KC_8, KC_0, KC_2, KC_4, KC_6, \
|
||||
_GACS_MODS________________________, KC_F11, KC_F12, ___x___, KC_F2, KC_F4, KC_F6, \
|
||||
KC_F7, KC_F5, KC_F3, KC_F1, KC_F9, KC_F8, KC_F10, TR_COMM, TR_DOT, TR_MINS, \
|
||||
KC_MUTE, KC_VOLD, KC_VOLU, KC_MNXT, KC_MPLY, KC_F11, KC_F12, TR_COMM, TR_DOT, TR_MINS, \
|
||||
_LAYER_TRANS_____________, _LAYER_TRANS_____________
|
||||
|
||||
|
||||
#define LAYER_CONFIG \
|
||||
___x___, ___x___, ___x___, ___x___, KC_MUTE, ___x___, ___x___, EE_CLR, QK_BOOT, _______, \
|
||||
___x___, ___x___, ___x___, ___x___, KC_VOLU, ___x___, TR_LSFT, ___x___, ___x___, TR_RMOD, \
|
||||
___x___, ___x___, ___x___, ___x___, KC_VOLD, TR_RTOG, TR_RHUI, TR_RSAI, TR_RVAI, TR_RSPI, \
|
||||
_NONE_5____________________________________, ___x___, ___x___, EE_CLR, QK_BOOT, _______, \
|
||||
_NONE_5____________________________________, ___x___, TR_LSFT, ___x___, ___x___, TR_RMOD, \
|
||||
_NONE_5____________________________________, TR_RTOG, TR_RHUI, TR_RSAI, TR_RVAI, TR_RSPI, \
|
||||
BASELYR, ___x___, ___x___, TR_DMP1, TR_DMR1, TR_RTOG
|
||||
|
||||
/*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue