Bubble Plot : Use soft contrast color, set read only if not used

This commit is contained in:
Magne Sjaastad 2020-02-05 07:37:03 +01:00
parent 8a3a1edafc
commit 2b1b1bf286
2 changed files with 22 additions and 11 deletions

View File

@ -429,7 +429,7 @@ void RivWellDiskPartMgr::buildWellDiskParts( size_t frameIndex, const caf::Displ
auto textColor = simWellInViewCollection()->wellLabelColor();
drawableText->setTextColor( textColor );
auto bgColor = RiaColorTools::contrastColor( textColor );
auto bgColor = RiaColorTools::contrastColor( textColor, true );
drawableText->setBackgroundColor( bgColor );
cvf::String cvfString = cvfqt::Utils::toString( labelText );

View File

@ -738,18 +738,29 @@ void RimSimWellInViewCollection::defineUiOrdering( QString uiConfigName, caf::Pd
advancedGroup->add( &wellHeadPosition );
}
caf::PdmUiGroup* wellDiskGroup = uiOrdering.addNewGroup( "Well Disk" );
wellDiskGroup->add( &m_wellDiskPropertyType );
if ( m_wellDiskPropertyType() == PROPERTY_TYPE_PREDEFINED )
{
wellDiskGroup->add( &m_wellDiskPropertyConfigType );
caf::PdmUiGroup* wellDiskGroup = uiOrdering.addNewGroup( "Disks" );
wellDiskGroup->add( &m_wellDiskPropertyType );
if ( m_wellDiskPropertyType() == PROPERTY_TYPE_PREDEFINED )
{
wellDiskGroup->add( &m_wellDiskPropertyConfigType );
}
else
{
wellDiskGroup->add( &m_wellDiskQuantity );
}
wellDiskGroup->add( &m_wellDiskShowQuantityLabels );
wellDiskGroup->add( &m_wellDiskshowLabelsBackground );
bool isReadOnly = m_showWellDisks().isFalse();
m_wellDiskPropertyType.uiCapability()->setUiReadOnly( isReadOnly );
m_wellDiskPropertyConfigType.uiCapability()->setUiReadOnly( isReadOnly );
m_wellDiskQuantity.uiCapability()->setUiReadOnly( isReadOnly );
m_wellDiskShowQuantityLabels.uiCapability()->setUiReadOnly( isReadOnly );
m_wellDiskshowLabelsBackground.uiCapability()->setUiReadOnly( isReadOnly );
}
else
{
wellDiskGroup->add( &m_wellDiskQuantity );
}
wellDiskGroup->add( &m_wellDiskShowQuantityLabels );
wellDiskGroup->add( &m_wellDiskshowLabelsBackground );
RimEclipseResultCase* ownerCase = nullptr;
firstAncestorOrThisOfType( ownerCase );