CycloBranch
cFormulaPredictor.h
Go to the documentation of this file.
1
7#ifndef _CFORMULAPREDICTOR_H
8#define _CFORMULAPREDICTOR_H
9
10#include <QWidget>
11#include <QDesktopServices>
12#include <QToolBar>
13#include <QMenuBar>
14#include <QMenu>
15#include <QUrl>
16#include <QFileInfo>
17#include <QMainWindow>
18#include <QTextDocument>
19#include <QTableView>
20#include <QStandardItemModel>
21#include <QStandardItem>
22#include <QHeaderView>
23#include <QProgressDialog>
24#include <QTextStream>
26#include "core/cPeaksList.h"
31#include "gui/cEventFilter.h"
34
35
36// forward declaration
37class QTextBrowser;
38class QHBoxLayout;
39class QVBoxLayout;
40class QFormLayout;
41class QCheckBox;
42class QPushButton;
43class QSplitter;
44class QComboBox;
45class QDoubleSpinBox;
46class QSpinBox;
47class QAction;
48class QLabel;
49class QLineEdit;
50
51
55class cFormulaPredictor : public QMainWindow
56{
57 Q_OBJECT
58
59public:
60
61
67 cFormulaPredictor(cGlobalPreferences* globalpreferences, QWidget *parent);
68
69
74
75
80 void closeEvent(QCloseEvent *event);
81
82
87
88
89protected:
90
91
96 void keyPressEvent(QKeyEvent *event);
97
98
99private:
100
101 cGlobalPreferences* globalpreferences;
102 QWidget* parent;
103
104 cFormulaPredictorThread* formulapredictorthread;
105 int chargevalue;
106 int maximumcombinedelements;
107 bool basicformulacheck;
108 bool advancedformulacheck;
109 bool noratiocheck;
110 double mzvalue;
111 double mzerror;
112 vector<cIonType> selectedions;
113 vector<string> selectedelements;
114 vector<cFormulaPredictorRowItem> ionitems;
115 bool success;
116 bool terminatecomputation;
117 string errmsg;
118
119 map<string, int> pchemdata;
120
121 QMenuBar* menuBar;
122 QMenu* menuFile;
123 QMenu* menuSearch;
124 QMenu* menuHelp;
125
126 QToolBar* toolbarFile;
127 QToolBar* toolbarSearch;
128 QToolBar* toolbarHelp;
129
130 QAction* actionExportTable;
131 QAction* actionCloseWindow;
132 QAction* actionSearchPubChem;
133 QAction* actionHTMLDocumentation;
134
135 QDoubleSpinBox* doublespinboxmz;
136 QSpinBox* spinboxcharge;
137 QDoubleSpinBox* doublespinboxmzerror;
138 cFragmentIonsListWidget* widgetiontypes;
139 cNeutralLossesListWidget* widgetelements;
140 QSpinBox* spinboxmaximumcombinedelements;
141 QCheckBox* checkboxbasicformula;
142 QCheckBox* checkboxadvancedformula;
143 QCheckBox* checkboxnoratio;
144 QPushButton* predictbutton;
145 QPushButton* cancelbutton;
146
147 QFormLayout* formlayout;
148 QWidget* formwidget;
149
150 QTableView* peakstable;
151 QStandardItemModel* peakstablemodel;
152 cSpectrumDetailProxyModel* proxymodel;
153
154 QSplitter* vsplitter1;
155 QSplitter* vsplitter2;
156 QSplitter* hsplitter;
157
158 void preparePeaksTable();
159
160 void deleteTable();
161
162
163private slots:
164
165
166 void predictButtonReleased();
167
168
169 void cancelButtonReleased();
170
171
172 void exportTableToCSV();
173
174
175 void showHTMLDocumentation();
176
177
178 void closeWindow();
179
180
181 void resetIonTypes();
182
183
184 void formulaPredictorThreadFinished();
185
186
187 void searchPubChem();
188
189};
190
191#endif
192
An event filter.
The thread which searches molecular formulas corresponding to m/z value.
The implementation of a widget where types of fragment ions generated in theoretical spectra are sele...
The representation of a set of peptide sequence candidates.
The implementation of a widget where types of neutral losses generated in theoretical spectra are sel...
The representation of a peak list.
The implementation of the dialog PubChem search widget.
A table proxy model.
A delegate to create a reference view button.
Predicts the molecular formula from the exact mass.
Definition: cFormulaPredictor.h:56
~cFormulaPredictor()
The destructor.
Definition: cFormulaPredictor.cpp:226
void applyGlobalPreferences()
Apply new global preferences.
Definition: cFormulaPredictor.cpp:272
void keyPressEvent(QKeyEvent *event)
Handle a key press event.
Definition: cFormulaPredictor.cpp:279
cFormulaPredictor(cGlobalPreferences *globalpreferences, QWidget *parent)
The constructor.
Definition: cFormulaPredictor.cpp:28
void closeEvent(QCloseEvent *event)
Handle the window close event.
Definition: cFormulaPredictor.cpp:266
The thread which searches molecular formulas corresponding to m/z value.
Definition: cFormulaPredictorThread.h:57
The widget for selection of fragment ion types.
Definition: cFragmentIonsListWidget.h:26
The class storing global preferences.
Definition: cGlobalPreferences.h:104
The widget for selection of types of neutral losses.
Definition: cNeutralLossesListWidget.h:26
A table proxy model.
Definition: cSpectrumDetailProxyModel.h:19