MCPcopy Create free account
hub / github.com/Wemino/MarkerPatch / ImTextClassifierSetCharClassFromStr

Function ImTextClassifierSetCharClassFromStr

include/imgui/imgui_draw.cpp:5487–5496  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5485}
5486
5487void ImTextClassifierSetCharClassFromStr(ImU32* bits, unsigned int codepoint_min, unsigned int codepoint_end, ImWcharClass char_class, const char* s)
5488{
5489 const char* s_end = s + strlen(s);
5490 while (*s)
5491 {
5492 unsigned int c;
5493 s += ImTextCharFromUtf8(&c, s, s_end);
5494 ImTextClassifierSetCharClass(bits, codepoint_min, codepoint_end, char_class, c);
5495 }
5496}
5497
5498#define ImTextClassifierGet(_BITS, _CHAR_OFFSET) ((_BITS[(_CHAR_OFFSET) >> 4] >> (((_CHAR_OFFSET) & 15) << 1)) & 0x03)
5499

Callers 1

ImTextInitClassifiersFunction · 0.85

Calls 2

ImTextCharFromUtf8Function · 0.85

Tested by

no test coverage detected