A reference to a color. Used for skinning. More...

Detailed Description

A reference to a color. Used for skinning.

This allows easy skinning : by using these classes instead of directly QColor, we can change a color in a whole graphics scene instantly on the next redraw.

Public Member Functions

constexpr ColorRef (const ColorRef &other) noexcept=default
 
constexpr ColorRef (ColorRef &&other) noexcept=default
 
constexpr ColorRefoperator= (const ColorRef &other) noexcept=default
 
constexpr ColorRefoperator= (ColorRef &&other) noexcept=default
 
 ColorRef (Brush Skin::*s)
 
constexpr ColorRef (const Brush *col) noexcept
 
void setColor (Brush Skin::*s) noexcept
 
const BrushgetBrush () const
 
QString name () const noexcept
 

Static Public Member Functions

static std::optional< ColorRefColorFromString (const QString &) noexcept
 
static std::optional< ColorRefSimilarColor (QColor other) noexcept
 

Friends

bool operator== (ColorRef lhs, ColorRef rhs)
 
bool operator!= (ColorRef lhs, ColorRef rhs)
 

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