Update configuration manual for rawstr4c

This commit is contained in:
Aoran Zeng 2025-07-13 01:47:39 +08:00
parent efb802b0c8
commit 7642898eab
No known key found for this signature in database
GPG Key ID: 8F8BA8488E10ED98

View File

@ -7,12 +7,12 @@
! Contributors : Nul None <nul@none.org> ! Contributors : Nul None <nul@none.org>
! | ! |
! Created On : <2025-07-12> ! Created On : <2025-07-12>
! Last Modified : <2025-07-12> ! Last Modified : <2025-07-13>
! ---------------------------------------------------------- --> ! ---------------------------------------------------------- -->
# rawstr4c # rawstr4c
在你需要写一个复杂的C语言字符串的时候请想起我... \" / \n ' \\ ` 当你需要写一个复杂的C语言字符串的时候可使用该工具
<br> <br>
@ -36,39 +36,42 @@
## 配置项 ## 配置项
注意,如非特殊说明,第一项为默认值
- output = - output =
- `:terminal` = 在终端输出 - `:terminal` = 在终端输出
- `:global-variable` = 输出为一个 `.h` 文件,定义为全局变量
- `:macro` = 输出为一个 `.h` 文件,定义为宏 - `:macro` = 输出为一个 `.h` 文件,定义为宏
- `:global-variable` = 输出一个 `.h` 文件和对应的 `.c` 文件,定义为全局变量
- `:global-variable-only-header` = 仅输出为一个 `.h` 文件,定义为全局变量
- output-file = - output-file =
自定义生成的头文件名 自定义生成的头文件名,默认值为 `rawstr4c.h`
- translate = - translate =
- `:escape` = 仅转义
- `:oct` = 八进制 - `:oct` = 八进制
- `:hex` = 十六进制 - `:hex` = 十六进制
- `:escape` = 仅转义
- postfix = - postfix =
- `:use-language`: 使用 code block 的语言 - `:use-language` = 使用 code block 的语言
- `scratch string`: 使用某一自定义字符串为后缀 - `scratch string` = 使用某一自定义字符串为后缀
- name = - name =
生成的变量名,默认将会包含前缀和后缀 生成的变量名,默认将会包含前缀和后缀
- name-literally = `true` | `false` - name-literally = `false` | `true`
无视其他配置项,直接使用 `name` 作为变量名 无视其他配置项,直接使用 `name` 作为变量名
- keep-prefix = - keep-prefix = `true` | `false`
变量名是否使用前缀 变量名是否使用前缀
- keep-postfix = - keep-postfix = `true` | `false`
变量名是否使用后缀 变量名是否使用后缀