WSL/SLF GitLab Repository

Commit f3dd4c72 authored by Michael Reisecker's avatar Michael Reisecker
Browse files

Document and allow to customize working directory.

parent 9869ccac
......@@ -443,6 +443,12 @@ This is INIshell's user guide.
<section name="Example Workflow"/>
<help>This is a walkthrough of the different steps of the provided example simulation. If you don't see the experiment &quot;Weißfluhjoch&quot; in the &lt;font color=&quot;#268bd2&quot;&gt;Simulations&lt;/font&gt; workflow tab, please check the &lt;font color=&quot;#dc322f&quot;&gt;Troubleshooting&lt;/font&gt; part of this help.&lt;br&gt;</help>
<frame caption="Working directory" key="help-workingdir">
<section name="Example Workflow"/>
<parameter type="helptext" wrap="true">
<help>At the bottom of workflows you will often find a dropdown menu to select the "working directory". In order for your computer to find the necessary programs and files, the &lt;a href=&quot;;&gt;working directory&lt;/a&gt; must be set accordingly. This is different on different systems, but usually one of the options provided should work. Only change this to a custom path if you know this is necessary.</help>
<frame caption="Step 1: Open the simulation">
<section name="Example Workflow"/>
<parameter type="helptext" wrap="true">
......@@ -183,6 +183,11 @@ their own simulation software. It showcases all panels and lists their options.
<help>&lt;code&gt;&amp;lt;element type=&quot;label&quot; caption=&quot;Weißfluhjoch 1996&quot;/&amp;gt;&lt;/code&gt;</help>
<frame caption="Working directory" color="#000096">
<parameter type="helptext" wrap="true">
<help>If the workflow incorporates actions such as running programs, a dropdown menu to set the current working directory will be generated automatically.</help>
<!-- SECTIONS -->
......@@ -36,6 +36,7 @@
#include <QListWidget>
#include <QRegularExpression>
#include <QString>
#include <QToolButton>
#include <QVBoxLayout>
#ifdef DEBUG
......@@ -181,7 +182,19 @@ void WorkflowPanel::buildWorkflowSection(QDomElement &section)
panel_working_directory->addItem( "{inifile}/../" );
panel_working_directory->addItem( QDir::currentPath() );
panel_working_directory->setSizeAdjustPolicy( QComboBox::AdjustToMinimumContentsLength );
workflow_layout->addWidget(panel_working_directory, 0, Qt::AlignBottom);
auto help_button = new QToolButton;
connect(help_button, &QToolButton::clicked, this,
[=]{ getMainWindow()->loadHelp("Example Workflow", "help-workingdir"); });
auto help_layout = new QHBoxLayout;
//remember the selection for next one that is loaded:
panel_working_directory->setCurrentIndex(getSetting("user::working_dir", "value").toInt());
connect(panel_working_directory, QOverload<const int>::of(&QComboBox::currentIndexChanged),
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment