Skip to content

Commit

Permalink
Renamed LAYOUT macros that contained the keyboard name
Browse files Browse the repository at this point in the history
  • Loading branch information
0xcharly committed Jan 22, 2023
1 parent 300a0de commit e0686e6
Show file tree
Hide file tree
Showing 18 changed files with 54 additions and 50 deletions.
2 changes: 1 addition & 1 deletion keyboards/bastardkb/charybdis/3x5/3x5.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include "charybdis.h"

// clang-format off
#define LAYOUT_charybdis_3x5( \
#define LAYOUT( \
k00, k01, k02, k03, k04, k44, k43, k42, k41, k40, \
k10, k11, k12, k13, k14, k54, k53, k52, k51, k50, \
k20, k21, k22, k23, k24, k64, k63, k62, k61, k60, \
Expand Down
2 changes: 1 addition & 1 deletion keyboards/bastardkb/charybdis/3x5/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"vid": "0xA8F8"
},
"layouts": {
"LAYOUT_charybdis_3x5": {
"LAYOUT": {
"layout": [
{ "label": "L00", "x": 0, "y": 0 },
{ "label": "L01", "x": 1, "y": 0 },
Expand Down
4 changes: 4 additions & 0 deletions keyboards/bastardkb/charybdis/3x5/keymaps/bstiq/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -156,10 +156,14 @@
# define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_LEFT_RIGHT

// Slow swirl at startup.
# undef RGB_MATRIX_DEFAULT_SPD
# define RGB_MATRIX_DEFAULT_SPD 32

// Startup values.
# undef RGB_MATRIX_DEFAULT_HUE
# define RGB_MATRIX_DEFAULT_HUE 0
# undef RGB_MATRIX_DEFAULT_SAT
# define RGB_MATRIX_DEFAULT_SAT 255
# undef RGB_MATRIX_DEFAULT_VAL
# define RGB_MATRIX_DEFAULT_VAL RGB_MATRIX_MAXIMUM_BRIGHTNESS
#endif // RGB_MATRIX_ENABLE
2 changes: 1 addition & 1 deletion keyboards/bastardkb/charybdis/3x5/keymaps/bstiq/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ enum charybdis_keymap_bstiq_layers {
__VA_ARGS__
#define MOUSE_MOD(...) _MOUSE_MOD(__VA_ARGS__)

#define LAYOUT_wrapper(...) LAYOUT_charybdis_3x5(__VA_ARGS__)
#define LAYOUT_wrapper(...) LAYOUT(__VA_ARGS__)

const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[LAYER_BASE] = LAYOUT_wrapper(
Expand Down
6 changes: 3 additions & 3 deletions keyboards/bastardkb/charybdis/3x5/keymaps/default/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ enum charybdis_keymap_layers {

// clang-format off
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[LAYER_BASE] = LAYOUT_charybdis_3x5(
[LAYER_BASE] = LAYOUT(
// ╭─────────────────────────────────────────────╮ ╭─────────────────────────────────────────────╮
KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P,
// ├─────────────────────────────────────────────┤ ├─────────────────────────────────────────────┤
Expand All @@ -44,7 +44,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// ╰───────────────────────────╯ ╰──────────────────╯
),

[LAYER_LOWER] = LAYOUT_charybdis_3x5(
[LAYER_LOWER] = LAYOUT(
// ╭─────────────────────────────────────────────╮ ╭─────────────────────────────────────────────╮
RGB_TOG, KC_MNXT, KC_MPLY, KC_MPRV, XXXXXXX, KC_LBRC, KC_7, KC_8, KC_9, KC_RBRC,
// ├─────────────────────────────────────────────┤ ├─────────────────────────────────────────────┤
Expand All @@ -56,7 +56,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// ╰───────────────────────────╯ ╰──────────────────╯
),

[LAYER_RAISE] = LAYOUT_charybdis_3x5(
[LAYER_RAISE] = LAYOUT(
// ╭─────────────────────────────────────────────╮ ╭─────────────────────────────────────────────╮
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLU, KC_MUTE, KC_VOLD, XXXXXXX,
// ├─────────────────────────────────────────────┤ ├─────────────────────────────────────────────┤
Expand Down
24 changes: 12 additions & 12 deletions keyboards/bastardkb/charybdis/3x5/keymaps/drashna/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,64 +18,64 @@

#include "drashna.h"

#define LAYOUT_charybdis_3x5_wrapper(...) LAYOUT_charybdis_3x5(__VA_ARGS__)
#define LAYOUT_charybdis_3x5_base( \
#define LAYOUT_wrapper(...) LAYOUT(__VA_ARGS__)
#define LAYOUT_base( \
K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, \
K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, \
K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A \
) \
LAYOUT_charybdis_3x5 ( \
LAYOUT ( \
K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, \
ALT_T(K11), K12, K13, K14, GUI_T(K15), LGUI_T(K16), K17, K18, K19, LALT_T(K1A), \
CTL_T(K21), K22, K23, K24, K25, K26, K27, K28, K29, RCTL_T(K2A), \
LSFT_T(KC_GRV), KC_SPC, BK_LWER, DL_RAIS, RSFT_T(KC_ENT) \
)
#define LAYOUT_charybdis_3x5_base_wrapper(...) LAYOUT_charybdis_3x5_base(__VA_ARGS__)
#define LAYOUT_base_wrapper(...) LAYOUT_base(__VA_ARGS__)

const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {

[_DEFAULT_LAYER_1] = LAYOUT_charybdis_3x5_base_wrapper(
[_DEFAULT_LAYER_1] = LAYOUT_base_wrapper(
_________________QWERTY_L1_________________, _________________QWERTY_R1_________________,
_________________QWERTY_L2_________________, _________________QWERTY_R2_________________,
_________________QWERTY_L3_________________, _________________QWERTY_R3_________________
),

[_DEFAULT_LAYER_2] = LAYOUT_charybdis_3x5_base_wrapper(
[_DEFAULT_LAYER_2] = LAYOUT_base_wrapper(
______________COLEMAK_MOD_DH_L1____________, ______________COLEMAK_MOD_DH_R1____________,
______________COLEMAK_MOD_DH_L2____________, ______________COLEMAK_MOD_DH_R2____________,
______________COLEMAK_MOD_DH_L3____________, ______________COLEMAK_MOD_DH_R3____________
),
[_DEFAULT_LAYER_3] = LAYOUT_charybdis_3x5_base_wrapper(
[_DEFAULT_LAYER_3] = LAYOUT_base_wrapper(
_________________COLEMAK_L1________________, _________________COLEMAK_R1________________,
_________________COLEMAK_L2________________, _________________COLEMAK_R2________________,
_________________COLEMAK_L3________________, _________________COLEMAK_R3________________
),

[_DEFAULT_LAYER_4] = LAYOUT_charybdis_3x5_base_wrapper(
[_DEFAULT_LAYER_4] = LAYOUT_base_wrapper(
_________________DVORAK_L1_________________, _________________DVORAK_R1_________________,
_________________DVORAK_L2_________________, _________________DVORAK_R2_________________,
_________________DVORAK_L3_________________, _________________DVORAK_R3_________________
),

[_MOUSE] = LAYOUT_charybdis_3x5(
[_MOUSE] = LAYOUT(
_______, _______, _______, _______, _______, KC_WH_U, DPI_RMOD,DPI_MOD, S_D_RMOD,S_D_MOD,
_______, _______, _______, _______, _______, KC_WH_D, KC_BTN1, KC_BTN3, KC_BTN2, KC_BTN6,
_______, _______, _______, _______, _______, KC_BTN7, KC_BTN4, KC_BTN5, KC_BTN8, _______,
_______, SNIPING, _______, _______, _______
),
[_LOWER] = LAYOUT_charybdis_3x5_wrapper(
[_LOWER] = LAYOUT_wrapper(
_________________LOWER_L1__________________, _________________LOWER_R1__________________,
_________________LOWER_L2__________________, _________________LOWER_R2__________________,
_________________LOWER_L3__________________, _________________LOWER_R3__________________,
_______, _______, _______, _______, AUTO_CTN
),
[_RAISE] = LAYOUT_charybdis_3x5_wrapper(
[_RAISE] = LAYOUT_wrapper(
_________________RAISE_L1__________________, _________________RAISE_R1__________________,
_________________RAISE_L2__________________, _________________RAISE_R2__________________,
_________________RAISE_L3__________________, _________________RAISE_R3__________________,
QK_RBT, _______, _______, _______, _______
),
[_ADJUST] = LAYOUT_charybdis_3x5_wrapper(
[_ADJUST] = LAYOUT_wrapper(
_________________ADJUST_L1_________________, _________________ADJUST_R1_________________,
_________________ADJUST_L2_________________, _________________ADJUST_R2_________________,
_________________ADJUST_L3_________________, _________________ADJUST_R3_________________,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, \
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, \
N30, N31, K32, K33, K34, K35, K36, K37, N38, N39 \
) \
LAYOUT_charybdis_3x5( \
LAYOUT( \
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, \
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, \
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, \
Expand Down
2 changes: 1 addition & 1 deletion keyboards/bastardkb/charybdis/3x5/keymaps/via/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ static uint16_t auto_pointer_layer_timer = 0;
__VA_ARGS__
#define POINTER_MOD(...) _POINTER_MOD(__VA_ARGS__)

#define LAYOUT_wrapper(...) LAYOUT_charybdis_3x5(__VA_ARGS__)
#define LAYOUT_wrapper(...) LAYOUT(__VA_ARGS__)

const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[LAYER_BASE] = LAYOUT_wrapper(
Expand Down
2 changes: 1 addition & 1 deletion keyboards/bastardkb/charybdis/3x6/3x6.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include "charybdis.h"

// clang-format off
#define LAYOUT_charybdis_3x6( \
#define LAYOUT( \
k00, k01, k02, k03, k04, k05, k45, k44, k43, k42, k41, k40, \
k10, k11, k12, k13, k14, k15, k55, k54, k53, k52, k51, k50, \
k20, k21, k22, k23, k24, k25, k65, k64, k63, k62, k61, k60, \
Expand Down
2 changes: 1 addition & 1 deletion keyboards/bastardkb/charybdis/3x6/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"pid": "0x1834"
},
"layouts": {
"LAYOUT_charybdis_3x6": {
"LAYOUT": {
"layout": [
{ "label": "L00", "x": 0, "y": 0 },
{ "label": "L01", "x": 1, "y": 0 },
Expand Down
6 changes: 3 additions & 3 deletions keyboards/bastardkb/charybdis/3x6/keymaps/default/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ enum charybdis_keymap_layers {

// clang-format off
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[LAYER_BASE] = LAYOUT_charybdis_3x6(
[LAYER_BASE] = LAYOUT(
// ╭──────────────────────────────────────────────────────╮ ╭──────────────────────────────────────────────────────╮
KC_LGUI, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_RGUI,
// ├──────────────────────────────────────────────────────┤ ├──────────────────────────────────────────────────────┤
Expand All @@ -39,7 +39,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// ╰───────────────────────────╯ ╰──────────────────╯
),

[LAYER_LOWER] = LAYOUT_charybdis_3x6(
[LAYER_LOWER] = LAYOUT(
// ╭──────────────────────────────────────────────────────╮ ╭──────────────────────────────────────────────────────╮
XXXXXXX, RGB_TOG, KC_MNXT, KC_MPLY, KC_MPRV, XXXXXXX, KC_LBRC, KC_7, KC_8, KC_9, KC_RBRC, XXXXXXX,
// ├──────────────────────────────────────────────────────┤ ├──────────────────────────────────────────────────────┤
Expand All @@ -51,7 +51,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// ╰───────────────────────────╯ ╰──────────────────╯
),

[LAYER_RAISE] = LAYOUT_charybdis_3x6(
[LAYER_RAISE] = LAYOUT(
// ╭──────────────────────────────────────────────────────╮ ╭──────────────────────────────────────────────────────╮
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLU, KC_MUTE, KC_VOLD, XXXXXXX, XXXXXXX,
// ├──────────────────────────────────────────────────────┤ ├──────────────────────────────────────────────────────┤
Expand Down
8 changes: 4 additions & 4 deletions keyboards/bastardkb/charybdis/3x6/keymaps/via/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ static uint16_t auto_pointer_layer_timer = 0;

// clang-format off
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[LAYER_BASE] = LAYOUT_charybdis_3x6(
[LAYER_BASE] = LAYOUT(
// ╭──────────────────────────────────────────────────────╮ ╭──────────────────────────────────────────────────────╮
KC_LGUI, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_RGUI,
// ├──────────────────────────────────────────────────────┤ ├──────────────────────────────────────────────────────┤
Expand All @@ -57,7 +57,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// ╰───────────────────────────╯ ╰──────────────────╯
),

[LAYER_LOWER] = LAYOUT_charybdis_3x6(
[LAYER_LOWER] = LAYOUT(
// ╭──────────────────────────────────────────────────────╮ ╭──────────────────────────────────────────────────────╮
XXXXXXX, RGB_TOG, KC_MNXT, KC_MPLY, KC_MPRV, XXXXXXX, KC_LBRC, KC_7, KC_8, KC_9, KC_RBRC, XXXXXXX,
// ├──────────────────────────────────────────────────────┤ ├──────────────────────────────────────────────────────┤
Expand All @@ -69,7 +69,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// ╰───────────────────────────╯ ╰──────────────────╯
),

[LAYER_RAISE] = LAYOUT_charybdis_3x6(
[LAYER_RAISE] = LAYOUT(
// ╭──────────────────────────────────────────────────────╮ ╭──────────────────────────────────────────────────────╮
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLU, KC_MUTE, KC_VOLD, XXXXXXX, XXXXXXX,
// ├──────────────────────────────────────────────────────┤ ├──────────────────────────────────────────────────────┤
Expand All @@ -81,7 +81,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// ╰───────────────────────────╯ ╰──────────────────╯
),

[LAYER_POINTER] = LAYOUT_charybdis_3x6(
[LAYER_POINTER] = LAYOUT(
// ╭──────────────────────────────────────────────────────╮ ╭──────────────────────────────────────────────────────╮
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, DPI_MOD, S_D_MOD, S_D_MOD, DPI_MOD, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
// ├──────────────────────────────────────────────────────┤ ├──────────────────────────────────────────────────────┤
Expand Down
2 changes: 1 addition & 1 deletion keyboards/bastardkb/charybdis/4x6/4x6.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include "charybdis.h"

// clang-format off
#define LAYOUT_charybdis_4x6( \
#define LAYOUT( \
k00, k01, k02, k03, k04, k05, k55, k54, k53, k52, k51, k50, \
k10, k11, k12, k13, k14, k15, k65, k64, k63, k62, k61, k60, \
k20, k21, k22, k23, k24, k25, k75, k74, k73, k72, k71, k70, \
Expand Down
2 changes: 1 addition & 1 deletion keyboards/bastardkb/charybdis/4x6/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"vid": "0xA8F8"
},
"layouts": {
"LAYOUT_charybdis_4x6": {
"LAYOUT": {
"layout": [
{ "label": "L00", "x": 0, "y": 0 },
{ "label": "L01", "x": 1, "y": 0 },
Expand Down
Loading

0 comments on commit e0686e6

Please sign in to comment.