16 return QColor(rgbColor.red(), rgbColor.green(), rgbColor.blue(),
27 const auto rgbA =
a.
toRgb();
28 const auto rgbB =
b.
toRgb();
30 color.
setRedF(rgbA.redF() * (1.0 - factor) + rgbB.redF() * factor);
31 color.setGreenF(rgbA.greenF() * (1.0 - factor) + rgbB.greenF() * factor);
32 color.setBlueF(rgbA.blueF() * (1.0 - factor) + rgbB.blueF() * factor);
38#include "moc_qquickcolor_p.cpp"
The QColor class provides colors based on RGB, HSV or CMYK values.
void setRedF(float red)
Sets the red color component of this color to red.
QColor toRgb() const noexcept
Create and returns an RGB QColor based on this color.
Q_INVOKABLE QColor transparent(const QColor &color, qreal opacity) const
Q_INVOKABLE QColor blend(const QColor &a, const QColor &b, qreal factor) const
QQuickColor(QObject *parent=nullptr)
Combined button and popup list for selecting options.
constexpr const T & qBound(const T &min, const T &val, const T &max)
GLboolean GLboolean GLboolean b
GLboolean GLboolean GLboolean GLboolean a
[7]