Thu, 07 Jul 2022 08:51:57 +0200
Added my_height global variable and edit in profile setup. This sets the height of the brewery above or below sealevel. Added calculations for the air pressure, boilpoint and IBU_reduction that all depend on the height. Currently not yet in use. Split out the real IBU calculation from the generic toIBU function. This has no effect on the results.
94
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
1 | /* |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
2 | * RangedSliderPlugin.h is part of bmsapp. |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
3 | * |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
4 | * bmsapp is free software: you can redistribute it and/or modify |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
5 | * it under the terms of the GNU General Public License as published by |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
6 | * the Free Software Foundation, either version 3 of the License, or |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
7 | * (at your option) any later version. |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
8 | |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
9 | * bmsapp is distributed in the hope that it will be useful, |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
12 | * GNU General Public License for more details. |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
13 | |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
14 | * You should have received a copy of the GNU General Public License |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
15 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
16 | */ |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
17 | |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
18 | #ifndef _RANGEDSLIDERPLUGIN_H |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
19 | #define _RANGEDSLIDERPLUGIN_H |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
20 | |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
21 | #include <QObject> |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
22 | #include <QString> |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
23 | #include <QWidget> |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
24 | #include <QIcon> |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
25 | #include <QtUiPlugin/QDesignerCustomWidgetInterface> |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
26 | |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
27 | class RangedSliderPlugin; |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
28 | |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
29 | class RangedSliderPlugin : public QObject, public QDesignerCustomWidgetInterface |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
30 | { |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
31 | Q_OBJECT |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
32 | Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDesignerCustomWidgetCollectionInterface") |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
33 | Q_INTERFACES(QDesignerCustomWidgetInterface) |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
34 | |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
35 | public: |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
36 | RangedSliderPlugin(QObject* parent = nullptr); |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
37 | |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
38 | bool isContainer() const; |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
39 | bool isInitialized() const; |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
40 | QIcon icon() const; |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
41 | QString domXml() const; |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
42 | QString group() const; |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
43 | QString includeFile() const; |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
44 | QString name() const; |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
45 | QString toolTip() const; |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
46 | QString whatsThis() const; |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
47 | QWidget *createWidget(QWidget *parent); |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
48 | void initialize(QDesignerFormEditorInterface *core); |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
49 | |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
50 | private: |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
51 | bool initialized = false; |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
52 | }; |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
53 | |
380b1331ad2e
More progress in building designer plugins.
Michiel Broek <mbroek@mbse.eu>
parents:
diff
changeset
|
54 | #endif |