KWidgetsAddons
kratingwidget.cpp
191 d->hoverRating = adjustedHoverRating(halfStepsEnabled(), d->ratingPainter.ratingFromPosition(contentsRect(), e->pos()), d->rating);
204 d->hoverRating = adjustedHoverRating(halfStepsEnabled(), d->ratingPainter.ratingFromPosition(contentsRect(), e->pos()), d->rating);
233 pixSize = d->ratingPainter.customPixmap().size() / d->ratingPainter.customPixmap().devicePixelRatio();
236 return QSize(pixSize.width() * numPix + spacing() * (numPix - 1) + frameWidth() * 2, pixSize.height() + frameWidth() * 2);
QPoint pos() const const
typedef Alignment
Utility class that draws a row of stars for a rating value.
Definition: kratingpainter.h:37
frameWidth
Q_EMITQ_EMIT
Qt::MouseButton button() const const
void update()
virtual void resizeEvent(QResizeEvent *event)
LeftButton
void setOnlyPaintFullSteps(bool)
Definition: kratingwidget.cpp:157
void setAlignment(Qt::Alignment align)
The alignment of the stars in the drawing rect.
Definition: kratingwidget.cpp:81
void setPixmap(const QPixmap &)
Set the pixap to be used to display a rating step.
Definition: kratingwidget.cpp:36
void setHalfStepsEnabled(bool enabled)
If half steps are enabled (the default) then one rating step corresponds to half a star.
Definition: kratingwidget.cpp:150
enabled
void setMouseTracking(bool enable)
void updateGeometry()
void ratingChanged(unsigned int rating)
virtual void paintEvent(QPaintEvent *) override
LayoutDirection
void setPixmapSize(int size)
Set the recommended size of the pixmaps.
Definition: kratingwidget.cpp:54
size
QRect contentsRect() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Mon Dec 11 2023 04:01:37 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2023 The KDE developers.
Generated on Mon Dec 11 2023 04:01:37 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.