SetWindowTextUtf8
function · unassigned · host
- Address
0x435a50· 81 bytes, up to0x435aa0- Signature
void __fastcall (void *window, const char *text)- Meaning
- Sets a window's caption from UTF-8 through SetWindowTextW, in a buffer sized by 0x65b250
- Confidence
- verified, proof one
- Finding
- storm/unicode#counting-utf-16-units
Finding: Counting UTF-16 units in storm: UTF-8 to UTF-16
0x65b250(src, len, &read) counts, sequence by sequence and the NUL included, what the conversion
would store, with the same table, the same bounds and the same results for a source that runs out,
but folds each byte sign-extended. A lead from 0xc0 is then negative, so a sequence of two to four
bytes (lead 0xc0 to 0xf7) folds above 0x10ffff, whatever follows the lead, and counts 1, a four-byte
form included, which the conversion stores as two units; for valid UTF-8 the count is the code points
plus one. read takes the bytes
consumed, the NUL's included, and 0 for a null or empty source.
The derivation is in the doc.
Callers 2
- ConsoleCommandGxRestart console
- ConsoleSetCaption console
Callees 3
- __alloca_probe crt
- Utf8ToUtf16Length storm
- SUniConvertUTF8to16 storm
Calls and jumps by a bare address, from tables/calls.tsv.