float the selection panel over the game world instead of a side column

This commit is contained in:
2026-08-06 22:06:42 +02:00
parent 3b37b0ecf8
commit 603f8063e9
14 changed files with 320 additions and 129 deletions

View File

@@ -192,7 +192,7 @@ BuildButtonBar::BuildButtonBar(Simulation* sim, const GameConfig* config,
// The bar floats over the rendered world rather than sitting in a panel, so it
// brings its own opaque background to stay legible over any world content
// (REQ-UI-BUILD-BAR). Palette colors keep it consistent with the buttons it holds
// and with the side panels; this is widget chrome, not world rendering, so it is
// and with the selection panel; this is widget chrome, not world rendering, so it is
// deliberately not a visuals.toml color.
setAttribute(Qt::WA_StyledBackground, true);
setStyleSheet(QStringLiteral(
@@ -310,6 +310,11 @@ void BuildButtonBar::anchorTo(const QRect& worldViewRect)
recenter();
}
int BuildButtonBar::getStripHeightPx() const
{
return height() + kBottomMarginPx;
}
void BuildButtonBar::clearActiveButton()
{
if (m_activeIndex)