#8463 Plotting : Add command line parameter to show 2D main window

This commit is contained in:
Magne Sjaastad 2022-01-20 20:32:59 +01:00
parent 40d59b7bdc
commit b0470d38ee
2 changed files with 7 additions and 0 deletions

View File

@ -562,6 +562,12 @@ RiaApplication::ApplicationStatus RiaGuiApplication::handleArguments( gsl::not_n
RicSummaryPlotFeatureImpl::createSummaryPlotsFromArgumentLine( cvfqt::Utils::toQStringList( o.values() ) );
}
if ( cvf::Option o = progOpt->option( "openplotwindow" ) )
{
m_mainWindow->hide();
getOrCreateAndShowMainPlotWindow();
}
QString projectFileName;
if ( progOpt->hasOption( "last" ) )

View File

@ -143,6 +143,7 @@ bool RiaArgumentParser::parseArguments( cvf::ProgramOptions* progOpt )
progOpt->registerOption( "generate", "[<outputFile>]", "Generate code or documentation", cvf::ProgramOptions::SINGLE_VALUE );
progOpt->registerOption( "ignoreArgs", "", "System command. Ignore all arguments. Mostly for testing purposes" );
progOpt->registerOption( "version", "", "Display the application version string" );
progOpt->registerOption( "openplotwindow", "", "Open the 2D plot window. By default, the 3D window is displayed." );
progOpt->setOptionPrefix( cvf::ProgramOptions::DOUBLE_DASH );