extract getOverlayColor() to AbstractCounter for shared fill+hover styling and Use server-provided color and radius for tax counters

This commit is contained in:
DawnFire42 2026-08-10 15:08:27 -04:00
parent eeae205f51
commit c8ed9835bd
No known key found for this signature in database
GPG key ID: 24BB855EE2911B33
5 changed files with 27 additions and 18 deletions

View file

@ -36,6 +36,14 @@ protected:
bool hovered = false;
bool useNameForShortcut;
/**
* @brief Returns the counter's color adjusted for overlay rendering.
*
* Applies semi-transparency and lightens the color when hovered.
* Use this for fill-based counters; SVG-based counters (GeneralCounter) bypass this.
*/
[[nodiscard]] QColor getOverlayColor() const;
void mousePressEvent(QGraphicsSceneMouseEvent *event) override;
void hoverEnterEvent(QGraphicsSceneHoverEvent *event) override;
void hoverLeaveEvent(QGraphicsSceneHoverEvent *event) override;