kerep/src/kprint/kprint_format.md
2022-10-30 18:51:49 +06:00

3.1 KiB

kerep_format

          00000000 00000000 00000000 00000000
fgColorSet┘│││└┼┴┘ └┼┴┘└┴┴┤       ktId
bgColorSet─┘││ │  bgColor └data format
 prefix┬────┘│ └fgColor
 postfix     └uppercase

Console colors

Foreground

kprint_fg hex bin
Black 0x80000000 10000000 00000000...
DarkRed 0x81000000 10000001 00000000...
DarkGreen 0x82000000 10000010 00000000...
DarkYellow 0x83000000 10000011 00000000...
DarkBlue 0x84000000 10000100 00000000...
DarkMagenta 0x85000000 10000101 00000000...
DarkCyan 0x86000000 10000110 00000000...
Gray 0x87000000 10000111 00000000...
DarkGray 0x88000000 10001000 00000000...
Red 0x89000000 10001001 00000000...
Green 0x8a000000 10001010 00000000...
Yellow 0x8b000000 10001011 00000000...
Blue 0x8c000000 10001100 00000000...
Magenta 0x8d000000 10001101 00000000...
Cyan 0x8e000000 10001110 00000000...
White 0x8f000000 10001111 00000000...

Background

kprint_bg hex bin
Black 0x40000000 01000000 00000000...
DarkRed 0x40100000 01000000 00010000...
DarkGreen 0x40200000 01000000 00100000...
DarkYellow 0x40300000 01000000 00110000...
DarkBlue 0x40400000 01000000 01000000...
DarkMagenta 0x40500000 01000000 01010000...
DarkCyan 0x40600000 01000000 01100000...
Gray 0x40700000 01000000 01110000...
DarkGray 0x40800000 01000000 10000000...
Red 0x40900000 01000000 10010000...
Green 0x40a00000 01000000 10100000...
Yellow 0x40b00000 01000000 10110000...
Blue 0x40c00000 01000000 11000000...
Magenta 0x40d00000 01000000 11010000...
Cyan 0x40e00000 01000000 11100000...
White 0x40f00000 01000000 11110000...

Data format

kprint_fmt possible flags data types hex value bin value
Int int8... int64 0x00000000 00000000 00000000...
UInt WithPostfix, Uppercase uint8... uint64 0x00010000 00000000 00000001...
Hex WithPrefix, Uppercase any 0x00020000 00000000 00000010...
Bin WithPrefix, any 0x00030000 00000000 00000011...
Float WithPostfix, Uppercase float32, float64 0x00040000 00000000 00000100...
Char char 0x00050000 00000000 00000101...
String char* 0x00060000 00000000 00000110...

Flags

kprint_fmt hex value bin value
withPrefix 0x20000000 00100000 00000000...
withPostfix 0x20000000 00100000 00000000...
upperase 0x10000000 00010000 00000000...