11 Text::Text(uint32_t x/*= 0*/, uint32_t y/*= 0*/, uint32_t w/*= 0*/, uint32_t h/*= 0*/, Element * parent/*= NULL*/):
12 Element(x, y, w, h, parent)
14 fgColor = 0xFF8484FF, bgColor = 0xFF84FF4D;
17 Text::Text(uint32_t x, uint32_t y, std::string s, uint32_t fg/*= 0xFF8484FF*/, uint32_t bg/*= 0xFF84FF4D*/, Element * parent/*= NULL*/):
18 Element(x, y, 0, 0, parent), text(s)
20 fgColor = fg, bgColor = bg;
25 if (text.length() > 0)
27 // DrawString(screenBuffer, extents.x + offsetX, extents.y + offsetY, false, "%s", text.c_str());
28 SDL_Rect r = GetScreenCoords();
29 DrawStringOpaque(screen, r.x, r.y, fgColor, bgColor, "%s", text.c_str());
33 void Text::SetText(std::string s)