Cockatrice 2025-11-30-Development-2.11.0-beta.38
A cross-platform virtual tabletop for multiplayer card games
Loading...
Searching...
No Matches
GeneralCounter Class Reference

#include <counter_general.h>

Inheritance diagram for GeneralCounter:
[legend]
Collaboration diagram for GeneralCounter:
[legend]

Public Member Functions

 GeneralCounter (Player *_player, int _id, const QString &_name, const QColor &_color, int _radius, int _value, bool useNameForShortcut=false, QGraphicsItem *parent=nullptr)
QRectF boundingRect () const override
void paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) override
Public Member Functions inherited from AbstractCounter
 AbstractCounter (Player *_player, int _id, const QString &_name, bool _shownInCounterArea, int _value, bool _useNameForShortcut=false, QGraphicsItem *parent=nullptr)
 ~AbstractCounter () override
void retranslateUi ()
void setValue (int _value)
void setShortcutsActive ()
void setShortcutsInactive ()
void delCounter ()
QMenu * getMenu () const
int getId () const
QString getName () const
bool getShownInCounterArea () const
int getValue () const

Private Attributes

QColor color
int radius

Additional Inherited Members

Protected Member Functions inherited from AbstractCounter
void mousePressEvent (QGraphicsSceneMouseEvent *event) override
void hoverEnterEvent (QGraphicsSceneHoverEvent *event) override
void hoverLeaveEvent (QGraphicsSceneHoverEvent *event) override
Protected Attributes inherited from AbstractCounter
Playerplayer
int id
QString name
int value
bool useNameForShortcut
bool hovered

Constructor & Destructor Documentation

◆ GeneralCounter()

GeneralCounter::GeneralCounter ( Player * _player,
int _id,
const QString & _name,
const QColor & _color,
int _radius,
int _value,
bool useNameForShortcut = false,
QGraphicsItem * parent = nullptr )
Here is the call graph for this function:

Member Function Documentation

◆ boundingRect()

QRectF GeneralCounter::boundingRect ( ) const
override
Here is the caller graph for this function:

◆ paint()

void GeneralCounter::paint ( QPainter * painter,
const QStyleOptionGraphicsItem * option,
QWidget * widget )
override
Here is the call graph for this function:

Member Data Documentation

◆ color

QColor GeneralCounter::color
private

◆ radius

int GeneralCounter::radius
private

The documentation for this class was generated from the following files: