From 4984097d9be00230de5d34ed069bc277d9899721 Mon Sep 17 00:00:00 2001 From: tzarc Date: Fri, 11 Dec 2020 02:47:28 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20master=20@?= =?UTF-8?q?=20501f2fdef115314713e94428d409e5c3b5bfc1c2=20=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config_options.md | 4 +++- de/newbs_testing_debugging.md | 4 +++- es/newbs_testing_debugging.md | 4 +++- feature_macros.md | 4 +++- feature_userspace.md | 2 +- fr-fr/newbs_testing_debugging.md | 4 +++- ja/config_options.md | 4 +++- ja/feature_macros.md | 4 +++- ja/feature_userspace.md | 2 +- ja/newbs_testing_debugging.md | 4 +++- newbs_testing_debugging.md | 4 +++- zh-cn/newbs_testing_debugging.md | 4 +++- 12 files changed, 32 insertions(+), 12 deletions(-) diff --git a/config_options.md b/config_options.md index 3a4d7c87c52..a3262b418b0 100644 --- a/config_options.md +++ b/config_options.md @@ -29,7 +29,9 @@ This level contains all of the options for that particular keymap. If you wish t 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: - #include "config_common.h" +```c +#include "config_common.h" +``` ## Hardware Options diff --git a/de/newbs_testing_debugging.md b/de/newbs_testing_debugging.md index acc067e10f9..b390727775b 100644 --- a/de/newbs_testing_debugging.md +++ b/de/newbs_testing_debugging.md @@ -41,7 +41,9 @@ Bevorzugst Du es lieber auf der Befehlszeile zu debuggen? Dafür eignet sich das 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: - #include +```c +#include "print.h" +``` Danach stehen dir verschiedene Druck-Funktionen zur Verfügung: diff --git a/es/newbs_testing_debugging.md b/es/newbs_testing_debugging.md index ef7412f15c3..cb65b174fe8 100644 --- a/es/newbs_testing_debugging.md +++ b/es/newbs_testing_debugging.md @@ -41,7 +41,9 @@ Para plataformas compatibles, [QMK Toolbox](https://github.com/qmk/qmk_toolbox) 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: - #include +```c +#include "print.h" +``` Después de eso puedes utilzar algunas funciones print diferentes: diff --git a/feature_macros.md b/feature_macros.md index acd40d1bf34..3752b324969 100644 --- a/feature_macros.md +++ b/feature_macros.md @@ -182,7 +182,9 @@ Which would send Left Control+`a` (Left Control down, `a`, Left Control up) - no 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: - #include +```c +#include "sendstring_colemak.h" +``` ### Strings in Memory diff --git a/feature_userspace.md b/feature_userspace.md index 77a6c8d7621..8b001e3ce21 100644 --- a/feature_userspace.md +++ b/feature_userspace.md @@ -184,7 +184,7 @@ If you wanted to consolidate macros and other functions into your userspace for 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 -Then add `#include ` to all of your keymap.c files. This allows you to use these new keycodes without having to redefine them in each keymap. +Then add `#include ".h"` to all of your keymap.c files. This allows you to use these new keycodes without having to redefine them in each keymap. Once you've done that, you'll want to set the keycode definitions that you need to the `.h` file. For instance: ```c diff --git a/fr-fr/newbs_testing_debugging.md b/fr-fr/newbs_testing_debugging.md index 680d7644ed2..0307429ec23 100644 --- a/fr-fr/newbs_testing_debugging.md +++ b/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 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: - #include +```c +#include "print.h" +``` Une fois fait, vous pouvez utiliser les fonctions print suivantes: diff --git a/ja/config_options.md b/ja/config_options.md index 67e973030df..170beadef41 100644 --- a/ja/config_options.md +++ b/ja/config_options.md @@ -34,7 +34,9 @@ QMK での全ての利用可能な設定にはデフォルトがあります。 これは最初に include されるものの 1 つである C ヘッダファイルで、プロジェクト全体(もし含まれる場合)にわたって持続します。多くの変数をここで設定し、他の場所からアクセスすることができます。`config.h` ファイルでは、以下のもの以外の、他の `config.h` ファイルやその他のファイルの include をしないでください: - #include "config_common.h" +```c +#include "config_common.h" +``` ## ハードウェアオプション diff --git a/ja/feature_macros.md b/ja/feature_macros.md index 5fbe36726ad..14a58ad2442 100644 --- a/ja/feature_macros.md +++ b/ja/feature_macros.md @@ -187,7 +187,9 @@ void post_process_record_user(uint16_t keycode, keyrecord_t *record) { デフォルトでは、QWERTY レイアウトの US キーマップを想定しています; それを変更したい場合(例えば OS がソフトウェア Colemak を使う場合)、キーマップのどこかに以下を含めます: - #include +```c +#include "sendstring_colemak.h" +``` ### メモリ内の文字列 diff --git a/ja/feature_userspace.md b/ja/feature_userspace.md index d0d46f63f87..b0c113d1cf2 100644 --- a/ja/feature_userspace.md +++ b/ja/feature_userspace.md @@ -189,7 +189,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { 最初に、全ての `keymap.c` ファイルを調べ、代わりに `process_record_user` を `process_record_keymap` に置き換えます。この方法では、これらのキーボードでキーボード固有のコードを使用でき、カスタムの "global" キーコードも使うことができます。また、`SAFE_RANGE` を `NEW_SAFE_RANGE` に置き換えて、キーコードが重複しないようにすることもできます。 -次に、全ての keymap.c ファイルに `#include ` を追加します。これにより、各キーマップでそれらを再定義することなく新しいキーコードを使うことができます。 +次に、全ての keymap.c ファイルに `#include ".h"` を追加します。これにより、各キーマップでそれらを再定義することなく新しいキーコードを使うことができます。 それが完了したら、必要なキーコードの定義を `.h` ファイルに設定します。例えば: ```c diff --git a/ja/newbs_testing_debugging.md b/ja/newbs_testing_debugging.md index b80e09fc700..41103bae973 100644 --- a/ja/newbs_testing_debugging.md +++ b/ja/newbs_testing_debugging.md @@ -45,7 +45,9 @@ void keyboard_post_init_user(void) { [custom code](ja/custom_quantum_functions.md)内からデバッグメッセージを出力すると便利な場合があります。それはとても簡単です。ファイルの先頭に`print.h`のインクルードを追加します: - #include +```c +#include "print.h" +``` そのあとは、いくつかの異なった print 関数を使用することが出来ます。 diff --git a/newbs_testing_debugging.md b/newbs_testing_debugging.md index 1812389020f..834fed7163b 100644 --- a/newbs_testing_debugging.md +++ b/newbs_testing_debugging.md @@ -36,7 +36,9 @@ Prefer a terminal based solution? [hid_listen](https://www.pjrc.com/teensy/hid_l 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: - #include +```c +#include "print.h" +``` After that you can use a few different print functions: diff --git a/zh-cn/newbs_testing_debugging.md b/zh-cn/newbs_testing_debugging.md index 4edceee41a0..38e6346c4ba 100644 --- a/zh-cn/newbs_testing_debugging.md +++ b/zh-cn/newbs_testing_debugging.md @@ -34,7 +34,9 @@ void keyboard_post_init_user(void) { 有时用[custom code](custom_quantum_functions.md)发送自定义调试信息很有用. 这么做很简单. 首先在你文件头部包含`print.h`: - #include +```c +#include "print.h" +``` 之后,您可以使用一些不同的打印功能: