summaryrefslogtreecommitdiffstats
path: root/docs/keymap.md
diff options
context:
space:
mode:
authorPablo Martínez <58857054+elpekenin@users.noreply.github.com>2023-02-10 11:39:35 +0100
committerGitHub <noreply@github.com>2023-02-10 02:39:35 -0800
commit95671148a4f451cd98b98e5d2b8d559ad12eb24d (patch)
tree8817ffe14c8b9d9be0b7b955505266a9d1930a91 /docs/keymap.md
parent50cd320616aa4850ebcd876b3462f449ec55c51b (diff)
[Docs] Change defines to enums in examples (#19793)
Diffstat (limited to 'docs/keymap.md')
-rw-r--r--docs/keymap.md8
1 files changed, 5 insertions, 3 deletions
diff --git a/docs/keymap.md b/docs/keymap.md
index 66e9db1a7f..f9d45b3267 100644
--- a/docs/keymap.md
+++ b/docs/keymap.md
@@ -117,9 +117,11 @@ At the top of the file you'll find this:
// Layer names don't all need to be of the same
// length, and you can also skip them entirely
// and just use numbers.
- #define _BL 0
- #define _FL 1
- #define _CL 2
+ enum layer_names {
+ _BL,
+ _FL,
+ _CL,
+ };
These are some handy definitions we can use when building our keymap and our custom function. The `GRAVE_MODS` definition will be used later in our custom function, and the following `_BL`, `_FL`, and `_CL` defines make it easier to refer to each of our layers.