Skip to content

Commit cd24c8a

Browse files
authored
Update PRINT_HELP_FORMATTED.md
1 parent 5928d5c commit cd24c8a

File tree

1 file changed

+14
-11
lines changed

1 file changed

+14
-11
lines changed
Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,16 @@
1-
This command displays a black rectangular text box similar to PRINT_HELP. The message is constructed out of the given string and any extra arguments, using common C++ format specifiers starting from `%`, e.g.:
2-
3-
* `%d` prints an integer number
4-
* `%f` prints a floating-point number
5-
* `%s` prints a string.
6-
* `%p` prints a number as an 8-digit hex number
7-
* `%%` prints a single %
8-
9-
For more supported specifiers see: https://cplusplus.com/reference/cstdio/printf/
10-
11-
The string may contain zero or more format specifiers and their count must match the number of arguments.
1+
This command displays a black rectangular text box similar to PRINT_HELP. The message is constructed out of the given string and any extra arguments.
122

3+
Common [C++ format specifiers](https://cplusplus.com/reference/cstdio/printf/) starting from `%` are used to define argument type, e.g.:
4+
* `%d` integer number in decimal form
5+
* `%x` integer number in hex form (lower case letters)
6+
* `%X` integer number in hex form (upper case letters)
7+
* `%f` floating-point number
8+
* `%s` string
9+
* `%p` 8-digit hex number
10+
* `%%` single `%` character
11+
* `%c` single ASCII character specified by number
12+
* `%4d` at least 4 digits wide integer number (padded with spaces)
13+
* `%04d` at least 4 digits wide integer number (padded with zeros)
14+
* `%.2f` floating-point number rounded to 2 digits after decimal point
1315

16+
The format string may contain zero or more specifiers and their count must match the number of arguments.

0 commit comments

Comments
 (0)