24#include "Utils/Pimpl.h"
53 Rating rating()
const;
74 void paint(QPainter* painter,
const QRect& rect);
102 void sigFinished(
bool save);
154 void paintEvent(QPaintEvent* e)
override;
156 void focusInEvent(QFocusEvent* e)
override;
157 void focusOutEvent(QFocusEvent* e)
override;
159 void mousePressEvent(QMouseEvent* e)
override;
160 void mouseMoveEvent(QMouseEvent* e)
override;
161 void mouseReleaseEvent(QMouseEvent* e)
override;
This class is used for the actual editing of a RatingLabel While the RatingLabel class is used in pai...
Definition: RatingLabel.h:97
void setVerticalOffset(int offset)
Set an offset where to begin drawing stars.
QSize minimumSizeHint() const override
Same as RatingLabel::minimumSizeHint.
QSize sizeHint() const override
Same as RatingLabel::sizeHint.
void setMouseTrackable(bool b)
Enable mouse move events. If disabled, there's no live update.
Rating rating() const
Returns the actual rating. This is not neccessarily the rating currently visible. Consider the case w...
void setRating(Rating rating)
Sets the actual rating.
A simple label, not suitable for editing. For editing, use the RatingEditor class....
Definition: RatingLabel.h:40
Rating ratingAt(QPoint pos) const
Returns the rating regarding the current mouse position.
QSize sizeHint() const override
about 20px in height and 5x20px in width
QSize minimumSizeHint() const override
Same as sizeHint.
void paint(QPainter *painter, const QRect &rect)
Called from outside. Mostly from delegates or from the RatingEditor class.
void setVerticalOffset(int offset)
The y-offset where the stars should be painted.
void setRating(Rating rating)
Set a rating from one to 5.