Small rectification, the offsets are private so the previous code won't work. But pseudo-code are not meant to work, are they? :-)

class LQColor: public QColor
{
     LQColor(ColorEntry const ce): QColor(ce.get_rbg()) {
         int ho, so, vo;
         ce.get_hsv_offset(ho,so,vo);
         if (ho != 0 || so != 0 || vo != 0) {
             convertTo(QColor::Hsv);
             int h, s, v;
             getHsv(&h,&s,&v);
             setHsv(&(h += ho), &(s += so), &(v += so));
    }
}

Reply via email to