MCPcopy Create free account
hub / github.com/bambulab/BambuStudio / ImFormatString

Function ImFormatString

src/imgui/imgui.cpp:1435–1451  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1433#endif
1434
1435int ImFormatString(char* buf, size_t buf_size, const char* fmt, ...)
1436{
1437 va_list args;
1438 va_start(args, fmt);
1439#ifdef IMGUI_USE_STB_SPRINTF
1440 int w = stbsp_vsnprintf(buf, (int)buf_size, fmt, args);
1441#else
1442 int w = vsnprintf(buf, buf_size, fmt, args);
1443#endif
1444 va_end(args);
1445 if (buf == NULL)
1446 return w;
1447 if (w == -1 || w >= (int)buf_size)
1448 w = (int)buf_size - 1;
1449 buf[w] = 0;
1450 return w;
1451}
1452
1453int ImFormatStringV(char* buf, size_t buf_size, const char* fmt, va_list args)
1454{

Callers 15

TableHeaderMethod · 0.85
DebugNodeTableMethod · 0.85
BeginChildExMethod · 0.85
BeginTooltipExMethod · 0.85
BeginPopupExMethod · 0.85
NavScoreItemMethod · 0.85
NavUpdateMethod · 0.85
ShowMetricsWindowMethod · 0.85
DebugNodeDrawListMethod · 0.85
DebugNodeTabBarMethod · 0.85
AddFontDefaultMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected