MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / OnDraw

Method OnDraw

Descent3/newui_core.cpp:1018–1032  ·  view source on GitHub ↗

overridable draws the window background before gadgets

Source from the content-addressed store, hash-verified

1016
1017// overridable draws the window background before gadgets
1018void newuiMenu::OnDraw() {
1019 // draw background
1020 m_bkg->draw(0, 0);
1021
1022 // draw title
1023 if (m_cursheetidx != -1 && m_hassheet[m_cursheetidx]) {
1024 UITextItem *title = m_sheetbtn[m_cursheetidx].GetTitle();
1025 UITextItem m_texttitle(MONITOR15_NEWUI_FONT, title->GetBuffer(), NEWUI_MONITORFONT_COLOR);
1026
1027 m_texttitle.draw(m_titlex - 8 + (NEWUI_MEDWIN_TITLE_W - m_texttitle.width()) / 2, m_titley);
1028 }
1029
1030 // draws gadgets.
1031 UIWindow::OnDraw();
1032}
1033
1034// overridable: called in Destroy
1035void newuiMenu::OnDestroy() {

Callers

nothing calls this directly

Calls 15

ui_DrawLineFunction · 0.85
ui_SetTextClipFunction · 0.85
SetCurrentIndexFunction · 0.85
ui_DrawRectFunction · 0.85
ui_ResetTextClipFunction · 0.85
ui_DrawBoxFunction · 0.85
textaux_WordWrapFunction · 0.85
GetBufferMethod · 0.80
WMethod · 0.80
set_flagsMethod · 0.80
GR_RGBFunction · 0.50
drawMethod · 0.45

Tested by

no test coverage detected