MCPcopy Create free account
hub / github.com/cinder/Cinder / ImFormatString

Function ImFormatString

src/imgui/imgui.cpp:2198–2214  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2196#endif
2197
2198int ImFormatString(char* buf, size_t buf_size, const char* fmt, ...)
2199{
2200 va_list args;
2201 va_start(args, fmt);
2202#ifdef IMGUI_USE_STB_SPRINTF
2203 int w = stbsp_vsnprintf(buf, (int)buf_size, fmt, args);
2204#else
2205 int w = vsnprintf(buf, buf_size, fmt, args);
2206#endif
2207 va_end(args);
2208 if (buf == NULL)
2209 return w;
2210 if (w == -1 || w >= (int)buf_size)
2211 w = (int)buf_size - 1;
2212 buf[w] = 0;
2213 return w;
2214}
2215
2216int ImFormatStringV(char* buf, size_t buf_size, const char* fmt, va_list args)
2217{

Callers 15

TableHeaderMethod · 0.85
DebugNodeTableMethod · 0.85
GetKeyChordNameMethod · 0.85
BeginTooltipExMethod · 0.85
BeginPopupExMethod · 0.85
BeginPopupMenuExMethod · 0.85
NavScoreItemMethod · 0.85
ShowMetricsWindowMethod · 0.85
DebugNodeDrawListMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected