Core: add functions setPackedARGB and fromPackedRGBA

This commit is contained in:
wmayer
2023-02-25 22:21:02 +01:00
committed by wwmayer
parent 337991cbc7
commit 9604f94fdc
9 changed files with 55 additions and 41 deletions

View File

@@ -763,19 +763,19 @@ void ReportOutput::OnChange(Base::Subject<const char*> &rCaller, const char * sR
}
else if (strcmp(sReason, "colorText") == 0) {
unsigned long col = rclGrp.GetUnsigned( sReason );
reportHl->setTextColor( QColor( (col >> 24) & 0xff,(col >> 16) & 0xff,(col >> 8) & 0xff) );
reportHl->setTextColor(App::Color::fromPackedRGB<QColor>(col));
}
else if (strcmp(sReason, "colorLogging") == 0) {
unsigned long col = rclGrp.GetUnsigned( sReason );
reportHl->setLogColor( QColor( (col >> 24) & 0xff,(col >> 16) & 0xff,(col >> 8) & 0xff) );
reportHl->setLogColor(App::Color::fromPackedRGB<QColor>(col));
}
else if (strcmp(sReason, "colorWarning") == 0) {
unsigned long col = rclGrp.GetUnsigned( sReason );
reportHl->setWarningColor( QColor( (col >> 24) & 0xff,(col >> 16) & 0xff,(col >> 8) & 0xff) );
reportHl->setWarningColor(App::Color::fromPackedRGB<QColor>(col));
}
else if (strcmp(sReason, "colorError") == 0) {
unsigned long col = rclGrp.GetUnsigned( sReason );
reportHl->setErrorColor( QColor( (col >> 24) & 0xff,(col >> 16) & 0xff,(col >> 8) & 0xff) );
reportHl->setErrorColor(App::Color::fromPackedRGB<QColor>(col));
}
else if (strcmp(sReason, "checkGoToEnd") == 0) {
gotoEnd = rclGrp.GetBool(sReason, gotoEnd);