MCPcopy Create free account
hub / github.com/BernardoGiordano/Checkpoint / drawRow

Method drawRow

switch/source/ScriptRequestOverlays.cpp:245–252  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

243}
244
245void ScriptPickOneOverlay::drawRow(size_t k, int rowY, bool focused) const
246{
247 u32 th;
248 Gfx::GetTextDimensions(ScriptTile::NOTE_SIZE, "Ag", NULL, &th);
249 const int textX = INNER_X + 14;
250 const std::string fitted = trimToFit(mItems[k], INNER_X + INNER_W - 14 - textX, ScriptTile::NOTE_SIZE);
251 Gfx::DrawText(ScriptTile::NOTE_SIZE, textX, rowY + (ROW_H - (int)th) / 2, focused ? COLOR_TEXT : COLOR_TEXT2, fitted.c_str());
252}
253
254std::string ScriptPickOneOverlay::hints(void) const
255{

Callers

nothing calls this directly

Calls 1

trimToFitFunction · 0.85

Tested by

no test coverage detected