OpenMS
SwathTabWidget.h
Go to the documentation of this file.
1 // Copyright (c) 2002-present, OpenMS Inc. -- EKU Tuebingen, ETH Zurich, and FU Berlin
2 // SPDX-License-Identifier: BSD-3-Clause
3 //
4 // --------------------------------------------------------------------------
5 // $Maintainer: Chris Bielow $
6 // $Authors: Chris Bielow $
7 // --------------------------------------------------------------------------
8 
9 #pragma once
10 
11 // OpenMS_GUI config
12 #include <OpenMS/VISUAL/OpenMS_GUIConfig.h>
13 
20 
21 #include <QTabWidget> // our base class
22 
23 #include <vector>
24 #include <utility> // for std::pair
25 
26 namespace Ui
27 {
28  class SwathTabWidget;
29 }
30 
31 namespace OpenMS
32 {
33  class InputFile;
34  class OutputDirectory;
35  class ParamEditor;
36 
37 
38  namespace Internal
39  {
40  class SwathTabWidget;
41 
43  class OPENMS_GUI_DLLAPI SwathTabWidget : public QTabWidget
44  {
45  Q_OBJECT
46 
47  public:
48  template <typename> friend class WizardGUILock;
49 
50  explicit SwathTabWidget(QWidget *parent = nullptr);
52 
54 
55  QStringList getPyProphetOutputFileNames() const;
56 
57  private slots:
61  void broadcastNewCWD_(const QString& new_cwd);
62 
63 
65 
67 
69 
70  private:
73  bool findPythonScript_(const String& path_to_python_exe, String& script_name);
74 
77 
80 
82  QString getCurrentOutDir_() const;
83 
86  std::vector<std::pair<String, bool>> getPyProphetInputFiles() const;
87 
90 
92 
93 
98  void writeLog_(const QString& text, const QColor& color = "#000000", bool new_section = false);
100  void writeLog_(const String& text, const QColor& color = "#000000", bool new_section = false);
101 
105 
106  Ui::SwathTabWidget *ui;
109 
112  };
113 
114  }
115 } // ns OpenMS
116 
117 // this is required to allow Ui_SwathTabWidget (auto UIC'd from .ui) to have a InputFile member
OpenMS::TableView TableView
Definition: SwathTabWidget.h:121
OpenMS::InputFile InputFile
Definition: SwathTabWidget.h:118
OpenMS::OutputDirectory OutputDirectory
Definition: SwathTabWidget.h:119
OpenMS::ParamEditor ParamEditor
Definition: SwathTabWidget.h:120
A wrapper around ExternalProcess to conveniently show a MessageBox when an error occurs.
Definition: ExternalProcessMBox.h:29
A simple widget with a line-edit and a browse button to choose filenames.
Definition: gui/include/OpenMS/VISUAL/InputFile.h:31
A multi-tabbed widget for the SwathWizard offering setting of parameters, input-file specification an...
Definition: SwathTabWidget.h:44
QStringList getPyProphetOutputFileNames() const
std::vector< std::pair< String, bool > > getPyProphetInputFiles() const
ExternalProcessMBox ep_
to run external programs and pipe their output into our log
Definition: SwathTabWidget.h:111
void writeLog_(const QString &text, const QColor &color="#000000", bool new_section=false)
fill osw_result_files_ according to the the currently specified input mzMLs
bool findPythonScript_(const String &path_to_python_exe, String &script_name)
void checkPyProphetInput_()
check if input to pyProphet is already present in the output directory of OSW
void updateWidgetsfromSwathParam_()
update Widgets given a param object
Param swath_param_wizard_
small selection of important parameters which the user can directly change in the Wizard
Definition: SwathTabWidget.h:108
void updateSwathParamFromWidgets_()
collect all parameters throughout the Wizard's controls and update 'swath_param_'
StringList getMzMLInputFiles() const
SwathTabWidget(QWidget *parent=nullptr)
StringList osw_result_files_
list of .osw files produced by OSW which are currently available
Definition: SwathTabWidget.h:110
QString getCurrentOutDir_() const
where to write OSW output and pyProphet output
Param swath_param_
the global Swath parameters which will be passed to OpenSwathWorkflow.exe, once updated with paramete...
Definition: SwathTabWidget.h:107
void writeLog_(const String &text, const QColor &color="#000000", bool new_section=false)
convenient overload for String
void broadcastNewCWD_(const QString &new_cwd)
update the current working directory for all file input fields
Ui::SwathTabWidget * ui
Definition: SwathTabWidget.h:106
RAII class to switch to certain TabWidget, disable the GUI and go back to the orignal Tab when this c...
Definition: WizardHelper.h:24
A simple widget with a line-edit and a browse button to choose filenames.
Definition: OutputDirectory.h:31
A GUI for editing or viewing a Param object.
Definition: ParamEditor.h:156
Management and storage of parameters / INI files.
Definition: Param.h:44
A more convenient string class.
Definition: String.h:34
A better QTable for TOPPView, which supports exporting to TSV and conveniently adding data to cells a...
Definition: TableView.h:22
std::vector< String > StringList
Vector of String.
Definition: ListUtils.h:44
Main OpenMS namespace.
Definition: openswathalgo/include/OpenMS/OPENSWATHALGO/DATAACCESS/ISpectrumAccess.h:19
Definition: FLASHDeconvWizardBase.h:37