#2094 Update well name color in 3d view (not sim well)

This commit is contained in:
Rebecca Cox
2017-11-07 16:42:52 +01:00
parent c19bc103c2
commit 93a83cd756
6 changed files with 47 additions and 2 deletions

View File

@@ -59,6 +59,9 @@
#include <QLabel>
#include <QMouseEvent>
#include <QProgressBar>
#include "RimWellPathCollection.h"
#include "RimWellPath.h"
#include "RivWellPathPartMgr.h"
using cvf::ManipulatorTrackball;
@@ -765,6 +768,8 @@ void RiuViewer::updateGridBoxData()
m_gridBoxGenerator->createGridBoxParts();
updateTextAndTickMarkColorForOverlayItems();
updateWellPathTextColor();
}
}
@@ -776,6 +781,27 @@ cvf::Model* RiuViewer::gridBoxModel() const
return m_gridBoxGenerator->model();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
void RiuViewer::updateWellPathTextColor()
{
RimView* rimView = ownerReservoirView();
if (!rimView) return;
RimWellPathCollection* wellPathCollection = rimView->wellPathsPartManager();
if (wellPathCollection)
{
cvf::Color3f color = computeContrastColor();
for (RimWellPath* path : wellPathCollection->wellPaths())
{
path->partMgr()->updateWellNameTextColor(color);
}
}
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------