mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Improve user interface for axis linking
Several adjustments to UI as discussed with Håkon and Alireza. * add link/unlink command to right-click menu of axis * select curve in project tree when clicking on legend item * make sure internal legend is always visible when toggling plot * fix issue when using sub plot as data source for axis range
This commit is contained in:
@@ -104,6 +104,7 @@ RimSummaryPlot::RimSummaryPlot( bool isCrossPlot )
|
||||
, m_isCrossPlot( isCrossPlot )
|
||||
, curvesChanged( this )
|
||||
, axisChanged( this )
|
||||
, plotZoomedByUser( this )
|
||||
, m_isValid( true )
|
||||
{
|
||||
CAF_PDM_InitScriptableObject( "Summary Plot", ":/SummaryPlotLight16x16.png", "", "A Summary Plot" );
|
||||
@@ -1744,6 +1745,8 @@ void RimSummaryPlot::updateZoomFromParentPlot()
|
||||
{
|
||||
propertyAxis->setAutoValueVisibleRangeMax( axisMax );
|
||||
propertyAxis->setAutoValueVisibleRangeMin( axisMin );
|
||||
axisProperties->setVisibleRangeMax( axisMax );
|
||||
axisProperties->setVisibleRangeMin( axisMin );
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -2372,8 +2375,18 @@ RimEnsembleCurveSet* RimSummaryPlot::addNewEnsembleCurveY( const RifEclipseSumma
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimSummaryPlot::onPlotZoomed()
|
||||
{
|
||||
// Disable auto scale in plot engine
|
||||
setAutoScaleXEnabled( false );
|
||||
setAutoScaleYEnabled( false );
|
||||
|
||||
// Disable auto value for min/max fields
|
||||
for ( auto p : plotYAxes() )
|
||||
{
|
||||
p->enableAutoValueMinMax( false );
|
||||
}
|
||||
|
||||
plotZoomedByUser.send();
|
||||
|
||||
updateZoomFromParentPlot();
|
||||
|
||||
axisChanged.send( this );
|
||||
|
||||
Reference in New Issue
Block a user