C++ (Qt)//Цвета по умолчанию...QColor base = QColor::fromRgb(203, 203, 203);QColor color1 = QColor::fromRgb(153, 153, 153);//QColor color2 = ...//QColor color3 = ... double delta1 = color1.valueF() / base.valueF();double delta2 = color2.valueF() / base.valueF();double delta3 = color3.valueF() / base.valueF();//... QColor newBase = QColor::fromRgb(240, 240, 180); //Рассчитываем новые на основе newBaseQColor newColor1 = QColor::fromHsvF(newBase.hueF(), newBase.saturationF(), std::min(newBase.valueF() * delta1, 1.0));QColor newColor2 = QColor::fromHsvF(newBase.hueF(), newBase.saturationF(), std::min(newBase.valueF() * delta2, 1.0));QColor newColor3 = QColor::fromHsvF(newBase.hueF(), newBase.saturationF(), std::min(newBase.valueF() * delta3, 1.0));
C++ (Qt)QColor newColor1 = QColor::fromHsvF(newBase.hueF(), newBase.saturationF(), std::min(newBase.valueF() * delta1, 1.0));
QColor temp = old_Color + new_Back - default_Back;