Commit 2d1162e6 authored by ledig's avatar ledig
Browse files

[FIX] WColorWidgets now get correctly colored even in win

parent 33161abb
......@@ -51,7 +51,6 @@ WQtNavGLWidget::WQtNavGLWidget( QString title, QWidget* parent, std::string slid
m_layout = new QVBoxLayout();
m_glWidget = boost::shared_ptr<WQtGLWidget>( new WQtGLWidget( title.toStdString(), panel, WGECamera::ORTHOGRAPHIC ) );
//m_glWidget->setFixedSize( 150, 150 );
m_glWidget->initialize();
setMinimumSize( 160, 240 );
......
......@@ -66,7 +66,15 @@ WPropertyColorWidget::~WPropertyColorWidget()
void WPropertyColorWidget::update()
{
m_button.setPalette( QPalette( toQColor( m_colorProperty->get() ) ) );
std::stringstream buttonColorStr;
QColor bgColor = toQColor( m_colorProperty->get() );
buttonColorStr << "* { background-color: rgb("
<< bgColor.red() << ","
<< bgColor.green() << ","
<< bgColor.blue() << ") }";
m_button.setStyleSheet( QString().fromStdString( buttonColorStr.str() ) );
// if this is a info property -> set background of label and some text
m_asText.setText( QString::fromStdString( m_colorProperty->getAsString() ) );
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment