add scrolling text to popup list, handling clipping inside scrolling text, game menu changes

- added delete entity in game menu
- added list meta records to game menu
This commit is contained in:
ITotalJustice
2025-05-01 15:14:50 +01:00
parent 8dfb9b9ba6
commit 3545f557fc
10 changed files with 157 additions and 49 deletions

View File

@@ -610,14 +610,9 @@ void Menu::Draw(NVGcontext* vg, Theme* theme) {
const auto text_x = x + xoff;
const auto text_clip_w = w - 30.f - xoff;
nvgSave(vg);
nvgIntersectScissor(vg, text_x, y, text_clip_w, h); // clip
{
const float font_size = 18;
m_scroll_name.Draw(vg, selected, text_x, y + 180 + 20, text_clip_w, font_size, NVG_ALIGN_LEFT, theme->GetColour(text_id), e.details.name.c_str());
m_scroll_author.Draw(vg, selected, text_x, y + 180 + 55, text_clip_w, font_size, NVG_ALIGN_LEFT, theme->GetColour(text_id), e.creator.display_name.c_str());
}
nvgRestore(vg);
const float font_size = 18;
m_scroll_name.Draw(vg, selected, text_x, y + 180 + 20, text_clip_w, font_size, NVG_ALIGN_LEFT, theme->GetColour(text_id), e.details.name.c_str());
m_scroll_author.Draw(vg, selected, text_x, y + 180 + 55, text_clip_w, font_size, NVG_ALIGN_LEFT, theme->GetColour(text_id), e.creator.display_name.c_str());
});
}