UI: Fix bug where color property shows transparency
Technically, setting the transparency value via a color property isn't currently supported. However, some sources/filters will set their alpha portion of their color value to 0, which would cause the color property to have a transparent background. Set the alpha value to 255 for now, at least until we properly implement support for setting transparency via the color property (if we ever do).
This commit is contained in:
parent
085af8bb72
commit
78d566916b
@ -638,6 +638,8 @@ void OBSPropertiesView::AddColor(obs_property_t *prop, QFormLayout *layout,
|
||||
button->setText(QTStr("Basic.PropertiesWindow.SelectColor"));
|
||||
button->setToolTip(QT_UTF8(obs_property_long_description(prop)));
|
||||
|
||||
color.setAlpha(255);
|
||||
|
||||
QPalette palette = QPalette(color);
|
||||
colorLabel->setFrameStyle(QFrame::Sunken | QFrame::Panel);
|
||||
colorLabel->setText(color.name(QColor::HexArgb));
|
||||
@ -1635,6 +1637,7 @@ bool WidgetInfo::ColorChanged(const char *setting)
|
||||
#endif
|
||||
|
||||
color = QColorDialog::getColor(color, view, QT_UTF8(desc), options);
|
||||
color.setAlpha(255);
|
||||
|
||||
if (!color.isValid())
|
||||
return false;
|
||||
|
Loading…
x
Reference in New Issue
Block a user