diff options
author | Ryan <fauxpark@gmail.com> | 2020-12-11 13:45:24 +1100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-11 13:45:24 +1100 |
commit | 501f2fdef115314713e94428d409e5c3b5bfc1c2 (patch) | |
tree | e454192658ed0000d1d814e2eab492410febe98f /docs | |
parent | 5b5d74a2677c281d12cd69825d2e252842786667 (diff) | |
download | qmk_firmware-501f2fdef115314713e94428d409e5c3b5bfc1c2.tar.gz qmk_firmware-501f2fdef115314713e94428d409e5c3b5bfc1c2.zip |
Normalise include statements in core code (#11153)
* Normalise include statements in core code
* Missed one
Diffstat (limited to 'docs')
-rw-r--r-- | docs/config_options.md | 4 | ||||
-rw-r--r-- | docs/de/newbs_testing_debugging.md | 4 | ||||
-rw-r--r-- | docs/es/newbs_testing_debugging.md | 4 | ||||
-rw-r--r-- | docs/feature_macros.md | 4 | ||||
-rw-r--r-- | docs/feature_userspace.md | 2 | ||||
-rw-r--r-- | docs/fr-fr/newbs_testing_debugging.md | 4 | ||||
-rw-r--r-- | docs/ja/config_options.md | 4 | ||||
-rw-r--r-- | docs/ja/feature_macros.md | 4 | ||||
-rw-r--r-- | docs/ja/feature_userspace.md | 2 | ||||
-rw-r--r-- | docs/ja/newbs_testing_debugging.md | 4 | ||||
-rw-r--r-- | docs/newbs_testing_debugging.md | 4 | ||||
-rw-r--r-- | docs/zh-cn/newbs_testing_debugging.md | 4 |
12 files changed, 32 insertions, 12 deletions
diff --git a/docs/config_options.md b/docs/config_options.md index 3a4d7c87c..a3262b418 100644 --- a/docs/config_options.md +++ b/docs/config_options.md | |||
@@ -29,7 +29,9 @@ This level contains all of the options for that particular keymap. If you wish t | |||
29 | 29 | ||
30 | This is a C header file that is one of the first things included, and will persist over the whole project (if included). Lots of variables can be set here and accessed elsewhere. The `config.h` file shouldn't be including other `config.h` files, or anything besides this: | 30 | This is a C header file that is one of the first things included, and will persist over the whole project (if included). Lots of variables can be set here and accessed elsewhere. The `config.h` file shouldn't be including other `config.h` files, or anything besides this: |
31 | 31 | ||
32 | #include "config_common.h" | 32 | ```c |
33 | #include "config_common.h" | ||
34 | ``` | ||
33 | 35 | ||
34 | 36 | ||
35 | ## Hardware Options | 37 | ## Hardware Options |
diff --git a/docs/de/newbs_testing_debugging.md b/docs/de/newbs_testing_debugging.md index acc067e10..b39072777 100644 --- a/docs/de/newbs_testing_debugging.md +++ b/docs/de/newbs_testing_debugging.md | |||
@@ -41,7 +41,9 @@ Bevorzugst Du es lieber auf der Befehlszeile zu debuggen? Dafür eignet sich das | |||
41 | 41 | ||
42 | Manchmal ist es hilfreich Debug-Nachrichten innerhalb deines eigenen [Custom Codes](de/custom_quantum_functions.md) zu drucken. Das ist ziemlich einfach. Beginne damit `print.h` am Anfang deiner Datei zu inkludieren: | 42 | Manchmal ist es hilfreich Debug-Nachrichten innerhalb deines eigenen [Custom Codes](de/custom_quantum_functions.md) zu drucken. Das ist ziemlich einfach. Beginne damit `print.h` am Anfang deiner Datei zu inkludieren: |
43 | 43 | ||
44 | #include <print.h> | 44 | ```c |
45 | #include "print.h" | ||
46 | ``` | ||
45 | 47 | ||
46 | Danach stehen dir verschiedene Druck-Funktionen zur Verfügung: | 48 | Danach stehen dir verschiedene Druck-Funktionen zur Verfügung: |
47 | 49 | ||
diff --git a/docs/es/newbs_testing_debugging.md b/docs/es/newbs_testing_debugging.md index ef7412f15..cb65b174f 100644 --- a/docs/es/newbs_testing_debugging.md +++ b/docs/es/newbs_testing_debugging.md | |||
@@ -41,7 +41,9 @@ Para plataformas compatibles, [QMK Toolbox](https://github.com/qmk/qmk_toolbox) | |||
41 | 41 | ||
42 | A veces, es útil imprimir mensajes de depuración desde tu [código personalizado](custom_quantum_functions.md). Hacerlo es bastante simple. Comienza incluyendo `print.h` al principio de tu fichero: | 42 | A veces, es útil imprimir mensajes de depuración desde tu [código personalizado](custom_quantum_functions.md). Hacerlo es bastante simple. Comienza incluyendo `print.h` al principio de tu fichero: |
43 | 43 | ||
44 | #include <print.h> | 44 | ```c |
45 | #include "print.h" | ||
46 | ``` | ||
45 | 47 | ||
46 | Después de eso puedes utilzar algunas funciones print diferentes: | 48 | Después de eso puedes utilzar algunas funciones print diferentes: |
47 | 49 | ||
diff --git a/docs/feature_macros.md b/docs/feature_macros.md index acd40d1bf..3752b3249 100644 --- a/docs/feature_macros.md +++ b/docs/feature_macros.md | |||
@@ -182,7 +182,9 @@ Which would send Left Control+`a` (Left Control down, `a`, Left Control up) - no | |||
182 | 182 | ||
183 | By default, it assumes a US keymap with a QWERTY layout; if you want to change that (e.g. if your OS uses software Colemak), include this somewhere in your keymap: | 183 | By default, it assumes a US keymap with a QWERTY layout; if you want to change that (e.g. if your OS uses software Colemak), include this somewhere in your keymap: |
184 | 184 | ||
185 | #include <sendstring_colemak.h> | 185 | ```c |
186 | #include "sendstring_colemak.h" | ||
187 | ``` | ||
186 | 188 | ||
187 | ### Strings in Memory | 189 | ### Strings in Memory |
188 | 190 | ||
diff --git a/docs/feature_userspace.md b/docs/feature_userspace.md index 77a6c8d76..8b001e3ce 100644 --- a/docs/feature_userspace.md +++ b/docs/feature_userspace.md | |||
@@ -184,7 +184,7 @@ If you wanted to consolidate macros and other functions into your userspace for | |||
184 | 184 | ||
185 | First, you'd want to go through all of your `keymap.c` files and replace `process_record_user` with `process_record_keymap` instead. This way, you can still use keyboard specific codes on those boards, and use your custom "global" keycodes as well. You'll also want to replace `SAFE_RANGE` with `NEW_SAFE_RANGE` so that you wont have any overlapping keycodes | 185 | First, you'd want to go through all of your `keymap.c` files and replace `process_record_user` with `process_record_keymap` instead. This way, you can still use keyboard specific codes on those boards, and use your custom "global" keycodes as well. You'll also want to replace `SAFE_RANGE` with `NEW_SAFE_RANGE` so that you wont have any overlapping keycodes |
186 | 186 | ||
187 | Then add `#include <name.h>` to all of your keymap.c files. This allows you to use these new keycodes without having to redefine them in each keymap. | 187 | Then add `#include "<name>.h"` to all of your keymap.c files. This allows you to use these new keycodes without having to redefine them in each keymap. |
188 | 188 | ||
189 | Once you've done that, you'll want to set the keycode definitions that you need to the `<name>.h` file. For instance: | 189 | Once you've done that, you'll want to set the keycode definitions that you need to the `<name>.h` file. For instance: |
190 | ```c | 190 | ```c |
diff --git a/docs/fr-fr/newbs_testing_debugging.md b/docs/fr-fr/newbs_testing_debugging.md index 680d7644e..0307429ec 100644 --- a/docs/fr-fr/newbs_testing_debugging.md +++ b/docs/fr-fr/newbs_testing_debugging.md | |||
@@ -42,7 +42,9 @@ Vous préférez une solution basée sur le terminal? [hid_listen](https://www.pj | |||
42 | 42 | ||
43 | Parfois, il est utile d'afficher des messages de débugage depuis votre [code custom](custom_quantum_functions.md). Le faire est assez simple. Commencez par ajouter `print.h` au début de votre fichier: | 43 | Parfois, il est utile d'afficher des messages de débugage depuis votre [code custom](custom_quantum_functions.md). Le faire est assez simple. Commencez par ajouter `print.h` au début de votre fichier: |
44 | 44 | ||
45 | #include <print.h> | 45 | ```c |
46 | #include "print.h" | ||
47 | ``` | ||
46 | 48 | ||
47 | Une fois fait, vous pouvez utiliser les fonctions print suivantes: | 49 | Une fois fait, vous pouvez utiliser les fonctions print suivantes: |
48 | 50 | ||
diff --git a/docs/ja/config_options.md b/docs/ja/config_options.md index 67e973030..170beadef 100644 --- a/docs/ja/config_options.md +++ b/docs/ja/config_options.md | |||
@@ -34,7 +34,9 @@ QMK での全ての利用可能な設定にはデフォルトがあります。 | |||
34 | 34 | ||
35 | これは最初に include されるものの 1 つである C ヘッダファイルで、プロジェクト全体(もし含まれる場合)にわたって持続します。多くの変数をここで設定し、他の場所からアクセスすることができます。`config.h` ファイルでは、以下のもの以外の、他の `config.h` ファイルやその他のファイルの include をしないでください: | 35 | これは最初に include されるものの 1 つである C ヘッダファイルで、プロジェクト全体(もし含まれる場合)にわたって持続します。多くの変数をここで設定し、他の場所からアクセスすることができます。`config.h` ファイルでは、以下のもの以外の、他の `config.h` ファイルやその他のファイルの include をしないでください: |
36 | 36 | ||
37 | #include "config_common.h" | 37 | ```c |
38 | #include "config_common.h" | ||
39 | ``` | ||
38 | 40 | ||
39 | 41 | ||
40 | ## ハードウェアオプション | 42 | ## ハードウェアオプション |
diff --git a/docs/ja/feature_macros.md b/docs/ja/feature_macros.md index 5fbe36726..14a58ad24 100644 --- a/docs/ja/feature_macros.md +++ b/docs/ja/feature_macros.md | |||
@@ -187,7 +187,9 @@ void post_process_record_user(uint16_t keycode, keyrecord_t *record) { | |||
187 | 187 | ||
188 | デフォルトでは、QWERTY レイアウトの US キーマップを想定しています; それを変更したい場合(例えば OS がソフトウェア Colemak を使う場合)、キーマップのどこかに以下を含めます: | 188 | デフォルトでは、QWERTY レイアウトの US キーマップを想定しています; それを変更したい場合(例えば OS がソフトウェア Colemak を使う場合)、キーマップのどこかに以下を含めます: |
189 | 189 | ||
190 | #include <sendstring_colemak.h> | 190 | ```c |
191 | #include "sendstring_colemak.h" | ||
192 | ``` | ||
191 | 193 | ||
192 | ### メモリ内の文字列 | 194 | ### メモリ内の文字列 |
193 | 195 | ||
diff --git a/docs/ja/feature_userspace.md b/docs/ja/feature_userspace.md index d0d46f63f..b0c113d1c 100644 --- a/docs/ja/feature_userspace.md +++ b/docs/ja/feature_userspace.md | |||
@@ -189,7 +189,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { | |||
189 | 189 | ||
190 | 最初に、全ての `keymap.c` ファイルを調べ、代わりに `process_record_user` を `process_record_keymap` に置き換えます。この方法では、これらのキーボードでキーボード固有のコードを使用でき、カスタムの "global" キーコードも使うことができます。また、`SAFE_RANGE` を `NEW_SAFE_RANGE` に置き換えて、キーコードが重複しないようにすることもできます。 | 190 | 最初に、全ての `keymap.c` ファイルを調べ、代わりに `process_record_user` を `process_record_keymap` に置き換えます。この方法では、これらのキーボードでキーボード固有のコードを使用でき、カスタムの "global" キーコードも使うことができます。また、`SAFE_RANGE` を `NEW_SAFE_RANGE` に置き換えて、キーコードが重複しないようにすることもできます。 |
191 | 191 | ||
192 | 次に、全ての keymap.c ファイルに `#include <name.h>` を追加します。これにより、各キーマップでそれらを再定義することなく新しいキーコードを使うことができます。 | 192 | 次に、全ての keymap.c ファイルに `#include "<name>.h"` を追加します。これにより、各キーマップでそれらを再定義することなく新しいキーコードを使うことができます。 |
193 | 193 | ||
194 | それが完了したら、必要なキーコードの定義を `<name>.h` ファイルに設定します。例えば: | 194 | それが完了したら、必要なキーコードの定義を `<name>.h` ファイルに設定します。例えば: |
195 | ```c | 195 | ```c |
diff --git a/docs/ja/newbs_testing_debugging.md b/docs/ja/newbs_testing_debugging.md index b80e09fc7..41103bae9 100644 --- a/docs/ja/newbs_testing_debugging.md +++ b/docs/ja/newbs_testing_debugging.md | |||
@@ -45,7 +45,9 @@ void keyboard_post_init_user(void) { | |||
45 | 45 | ||
46 | [custom code](ja/custom_quantum_functions.md)内からデバッグメッセージを出力すると便利な場合があります。それはとても簡単です。ファイルの先頭に`print.h`のインクルードを追加します: | 46 | [custom code](ja/custom_quantum_functions.md)内からデバッグメッセージを出力すると便利な場合があります。それはとても簡単です。ファイルの先頭に`print.h`のインクルードを追加します: |
47 | 47 | ||
48 | #include <print.h> | 48 | ```c |
49 | #include "print.h" | ||
50 | ``` | ||
49 | 51 | ||
50 | そのあとは、いくつかの異なった print 関数を使用することが出来ます。 | 52 | そのあとは、いくつかの異なった print 関数を使用することが出来ます。 |
51 | 53 | ||
diff --git a/docs/newbs_testing_debugging.md b/docs/newbs_testing_debugging.md index 181238902..834fed716 100644 --- a/docs/newbs_testing_debugging.md +++ b/docs/newbs_testing_debugging.md | |||
@@ -36,7 +36,9 @@ Prefer a terminal based solution? [hid_listen](https://www.pjrc.com/teensy/hid_l | |||
36 | 36 | ||
37 | Sometimes it's useful to print debug messages from within your [custom code](custom_quantum_functions.md). Doing so is pretty simple. Start by including `print.h` at the top of your file: | 37 | Sometimes it's useful to print debug messages from within your [custom code](custom_quantum_functions.md). Doing so is pretty simple. Start by including `print.h` at the top of your file: |
38 | 38 | ||
39 | #include <print.h> | 39 | ```c |
40 | #include "print.h" | ||
41 | ``` | ||
40 | 42 | ||
41 | After that you can use a few different print functions: | 43 | After that you can use a few different print functions: |
42 | 44 | ||
diff --git a/docs/zh-cn/newbs_testing_debugging.md b/docs/zh-cn/newbs_testing_debugging.md index 4edceee41..38e6346c4 100644 --- a/docs/zh-cn/newbs_testing_debugging.md +++ b/docs/zh-cn/newbs_testing_debugging.md | |||
@@ -34,7 +34,9 @@ void keyboard_post_init_user(void) { | |||
34 | 34 | ||
35 | 有时用[custom code](custom_quantum_functions.md)发送自定义调试信息很有用. 这么做很简单. 首先在你文件头部包含`print.h`: | 35 | 有时用[custom code](custom_quantum_functions.md)发送自定义调试信息很有用. 这么做很简单. 首先在你文件头部包含`print.h`: |
36 | 36 | ||
37 | #include <print.h> | 37 | ```c |
38 | #include "print.h" | ||
39 | ``` | ||
38 | 40 | ||
39 | 之后,您可以使用一些不同的打印功能: | 41 | 之后,您可以使用一些不同的打印功能: |
40 | 42 | ||