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.

77 lines
1.7 KiB

  1. // Copyright 2022 Ulrich Spörlein (@uqs)
  2. // SPDX-License-Identifier: GPL-2.0-or-later
  3. // vi:et sw=4:
  4. #pragma once
  5. #include QMK_KEYBOARD_H
  6. enum layers {
  7. L_QWER = 0,
  8. L_WASD, // wasd gaming
  9. L_COLM, // Colemak DHm
  10. L_EXTD,
  11. L_NUM,
  12. L_FUNC,
  13. L_MOUSE,
  14. L_LAST, // unused
  15. };
  16. #ifdef VIA_ENABLE
  17. _Static_assert(DYNAMIC_KEYMAP_LAYER_COUNT >= L_LAST, "VIA enabled, but not enough DYNAMIC_KEYMAP_LAYER_COUNT for all layers");
  18. #endif
  19. #define KC_CTAB LCTL(KC_TAB)
  20. #define KC_SCTAB LCTL(LSFT(KC_TAB))
  21. // Custom single-key codes, see uqs.c for the combos.
  22. enum custom_keycodes {
  23. SHIFT_INS = SAFE_RANGE,
  24. ALT_SHIFT_INS,
  25. INS_HARD,
  26. KC_A_AE,
  27. KC_O_OE,
  28. KC_U_UE,
  29. MINS_UNDSCR, // obsoleted by combos, remove this!
  30. TM_NEXT,
  31. TM_PREV,
  32. VIM_NEXT,
  33. VIM_PREV,
  34. WIN_LEFT,
  35. WIN_RGHT,
  36. WIN_UP,
  37. WIN_DN,
  38. LT_EXTD_ESC,
  39. LT_NUM_BSPC,
  40. LT_MOUSE_ALT_SHIFT_INS,
  41. LT_FUNC_SHIFT_INS,
  42. OSM_GUI,
  43. OSM_SFT,
  44. OSM_CTL,
  45. OSM_ALT,
  46. ALT_TAB,
  47. };
  48. #ifndef LEADER_ENABLE
  49. #define KC_LEAD KC_NO
  50. #endif
  51. // Shorter names
  52. #define MS_WHDN KC_MS_WH_DOWN
  53. #define MS_WHUP KC_MS_WH_UP
  54. #define MS_WHLEFT KC_MS_WH_LEFT
  55. #define MS_WHRGHT KC_MS_WH_RIGHT
  56. // GASC/◆⎇⇧⎈ home row mod, read all about it here:
  57. // https://precondition.github.io/home-row-mods
  58. // Left-hand home row mods
  59. #define KC_G_A LGUI_T(KC_A)
  60. #define KC_A_R LALT_T(KC_R)
  61. #define KC_S_S LSFT_T(KC_S)
  62. #define KC_C_T LCTL_T(KC_T)
  63. // Right-hand home row mods
  64. #define KC_C_N RCTL_T(KC_N)
  65. #define KC_S_E RSFT_T(KC_E)
  66. #define KC_A_I LALT_T(KC_I) // RALT is special, it's AltGr and my compose key under Win (layout UScmpse) and *nix (setxkbmap -option compose:ralt)
  67. #define KC_G_O RGUI_T(KC_O)