[Interface] Give every hover panel action a semantic color

The quick actions are the panel's whole point, so a neutral glyph made the
most-used buttons the hardest to scan. Every action now names a game fact with
its hue: gain, loss, information, hidden information, a mark on the card or a
move. The line glyph stays identical, so the colour is the only difference
between neighbours.

The grid is also ordered by family so a row reads as one idea: the two state
toggles, the two gains, the two marks, the two hidden-information actions and
the two losses each share a row. Conditional actions (Peek, Unattach) sit at the
end of their pair, so a missing one leaves a hole at the section edge instead of
splitting a row. In a zone, Play and Play Face Down stay adjacent on purpose:
the same action, one of them hiding information. The move tab leads with the
three library placements (Movement), then the destinations.

actionGridIcon is removed; semanticActionIcon is now the only grid ink. The
preview renders the real pages so the whole map can be judged at once.
This commit is contained in:
Lukas Brübach 2026-11-08 21:03:06 +01:00
parent 2567672556
commit 44fbbb6906
2 changed files with 71 additions and 66 deletions

View file

@ -323,8 +323,8 @@ TEST(IconTreatmentPreview, HoverPanelGridWritesPngsWhenRequested)
constexpr int GLYPH = 22;
constexpr qreal DPR = 2.0;
// The two pages a selected card shows, with every conditional action
// present so the whole map is visible at once.
// The pages a selected card shows, with every conditional action present
// so the whole map is visible at once.
const QList<PreviewPage> pages = {
PreviewPage{.title = QStringLiteral("Main — on the battlefield"),
.sections =
@ -334,31 +334,31 @@ TEST(IconTreatmentPreview, HoverPanelGridWritesPngsWhenRequested)
{
PreviewAction{.label = QStringLiteral("Tap / Untap"),
.glyph = "sync",
.role = AppColor::IconStrong},
.role = AppColor::InformationalStrong},
PreviewAction{.label = QStringLiteral("Skip untapping"),
.glyph = "lock",
.role = AppColor::IconStrong},
PreviewAction{.label = QStringLiteral("Turn Over"),
.glyph = "swap",
.role = AppColor::IconStrong},
PreviewAction{.label = QStringLiteral("Peek at card face"),
.glyph = "view",
.role = AppColor::HiddenStrong},
.role = AppColor::InformationalStrong},
PreviewAction{.label = QStringLiteral("Clone"),
.glyph = "increment",
.role = AppColor::PositiveStrong},
PreviewAction{.label = QStringLiteral("Attach to card..."),
.glyph = "pin",
.role = AppColor::IconStrong},
PreviewAction{.label = QStringLiteral("Unattach"),
.glyph = "arrow_undo",
.role = AppColor::NegativeStrong},
.role = AppColor::PositiveStrong},
PreviewAction{.label = QStringLiteral("Draw arrow..."),
.glyph = "share",
.role = AppColor::MarkedStrong},
PreviewAction{.label = QStringLiteral("Set annotation..."),
.glyph = "pencil",
.role = AppColor::MarkedStrong},
PreviewAction{.label = QStringLiteral("Turn Over"),
.glyph = "swap",
.role = AppColor::HiddenStrong},
PreviewAction{.label = QStringLiteral("Peek at card face"),
.glyph = "view",
.role = AppColor::HiddenStrong},
PreviewAction{.label = QStringLiteral("Unattach"),
.glyph = "arrow_undo",
.role = AppColor::NegativeStrong},
PreviewAction{.label = QStringLiteral("Reduce life"),
.glyph = "arrow_down",
.role = AppColor::NegativeStrong},
@ -368,10 +368,10 @@ TEST(IconTreatmentPreview, HoverPanelGridWritesPngsWhenRequested)
{
PreviewAction{.label = QStringLiteral("Select All"),
.glyph = "search",
.role = AppColor::IconStrong},
.role = AppColor::InformationalStrong},
PreviewAction{.label = QStringLiteral("Select Row"),
.glyph = "filter",
.role = AppColor::IconStrong},
.role = AppColor::InformationalStrong},
}},
}},
PreviewPage{.title = QStringLiteral("Main — in a zone"),
@ -391,7 +391,7 @@ TEST(IconTreatmentPreview, HoverPanelGridWritesPngsWhenRequested)
.role = AppColor::PositiveStrong},
PreviewAction{.label = QStringLiteral("Attach to card..."),
.glyph = "pin",
.role = AppColor::IconStrong},
.role = AppColor::PositiveStrong},
PreviewAction{.label = QStringLiteral("Draw arrow..."),
.glyph = "share",
.role = AppColor::MarkedStrong},
@ -401,10 +401,10 @@ TEST(IconTreatmentPreview, HoverPanelGridWritesPngsWhenRequested)
{
PreviewAction{.label = QStringLiteral("Select All"),
.glyph = "search",
.role = AppColor::IconStrong},
.role = AppColor::InformationalStrong},
PreviewAction{.label = QStringLiteral("Select Column"),
.glyph = "filter",
.role = AppColor::IconStrong},
.role = AppColor::InformationalStrong},
}},
}},
PreviewPage{.title = QStringLiteral("Move — card in a zone"),
@ -415,16 +415,16 @@ TEST(IconTreatmentPreview, HoverPanelGridWritesPngsWhenRequested)
{
PreviewAction{.label = QStringLiteral("Top of library"),
.glyph = "arrow_to_top",
.role = AppColor::IconStrong},
.role = AppColor::MovementStrong},
PreviewAction{.label = QStringLiteral("X from top..."),
.glyph = "search",
.role = AppColor::IconStrong},
.role = AppColor::MovementStrong},
PreviewAction{.label = QStringLiteral("Bottom of library"),
.glyph = "arrow_to_bottom",
.role = AppColor::IconStrong},
.role = AppColor::MovementStrong},
PreviewAction{.label = QStringLiteral("Table"),
.glyph = "player",
.role = AppColor::IconStrong},
.role = AppColor::PositiveStrong},
PreviewAction{.label = QStringLiteral("Hand"),
.glyph = "arrow_left",
.role = AppColor::PositiveStrong},