mirror of
https://github.com/OPM/ResInsight.git
synced 2026-11-04 13:16:56 -06:00
Depth Track Plots: Optionally show a line in all tracks
* #9378 Depth Track Plots: Optionally show a line in all tracks * Use RiaDefines::Orientation
This commit is contained in:
1 parent
286855cce0
commit
a33f651bcc
25 files changed
+341
-111
No files matched your search
@@ -18,6 +18,7 @@
|
||||
|
||||
#include "RiuPlotAnnotationTool.h"
|
||||
|
||||
#include "RimPlotAxisAnnotation.h"
|
||||
#include "RiuGuiTheme.h"
|
||||
|
||||
#include "cafCategoryMapper.h"
|
||||
@@ -191,6 +192,7 @@ void RiuPlotAnnotationTool::attachWellPicks( QwtPlot* plot,
|
||||
void RiuPlotAnnotationTool::attachAnnotationLine( QwtPlot* plot,
|
||||
const QColor& color,
|
||||
const QString& annotationText,
|
||||
Qt::PenStyle penStyle,
|
||||
const double position,
|
||||
RiaDefines::Orientation orientation )
|
||||
{
|
||||
@@ -204,11 +206,29 @@ void RiuPlotAnnotationTool::attachAnnotationLine( QwtPlot* plot,
|
||||
textColor = RiuGuiTheme::getColorByVariableName( "textColor" );
|
||||
}
|
||||
|
||||
RiuPlotAnnotationTool::setLineProperties( line, annotationText, orientation, position, Qt::SolidLine, color, textColor );
|
||||
RiuPlotAnnotationTool::setLineProperties( line, annotationText, orientation, position, penStyle, color, textColor );
|
||||
m_plotItems.push_back( line );
|
||||
line->attach( m_plot );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RiuPlotAnnotationTool::attachAnnotation( QwtPlot* plot,
|
||||
RimPlotAxisAnnotation* annotation,
|
||||
RiaDefines::Orientation orientation )
|
||||
{
|
||||
if ( annotation->annotationType() == RimPlotAxisAnnotation::AnnotationType::LINE )
|
||||
{
|
||||
attachAnnotationLine( plot,
|
||||
annotation->color(),
|
||||
annotation->name(),
|
||||
annotation->penStyle(),
|
||||
annotation->value(),
|
||||
orientation );
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
Reference in new issue
Block a user