src/global.cpp

Thu, 18 Aug 2022 20:34:15 +0200

author
Michiel Broek <mbroek@mbse.eu>
date
Thu, 18 Aug 2022 20:34:15 +0200
changeset 401
583148eb6e01
parent 380
8f5c03ed4321
child 411
c78f8cf11849
permissions
-rw-r--r--

Init est_carb field for new products.

131
0115b97e8c39 Added global variables, C++ lovers will hate that. Added global acid data. Fixed several load and save errors in the json arrays in the recipe record. Added first part of the miscs table. The first part of the water tab has values.
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
1
0115b97e8c39 Added global variables, C++ lovers will hate that. Added global acid data. Fixed several load and save errors in the json arrays in the recipe record. Added first part of the miscs table. The first part of the water tab has values.
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
2
0115b97e8c39 Added global variables, C++ lovers will hate that. Added global acid data. Fixed several load and save errors in the json arrays in the recipe record. Added first part of the miscs table. The first part of the water tab has values.
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
3 #include "global.h"
0115b97e8c39 Added global variables, C++ lovers will hate that. Added global acid data. Fixed several load and save errors in the json arrays in the recipe record. Added first part of the miscs table. The first part of the water tab has values.
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
4
323
d053ffbbf3e9 Started with change and signal functions. Implemented mode change for test. The MainWindow webSocket is now global so the Detail screens can send websocket messages.
Michiel Broek <mbroek@mbse.eu>
parents: 301
diff changeset
5 QWebSocket *webSocket;
d053ffbbf3e9 Started with change and signal functions. Implemented mode change for test. The MainWindow webSocket is now global so the Detail screens can send websocket messages.
Michiel Broek <mbroek@mbse.eu>
parents: 301
diff changeset
6 QList<Acid> my_acids;
131
0115b97e8c39 Added global variables, C++ lovers will hate that. Added global acid data. Fixed several load and save errors in the json arrays in the recipe record. Added first part of the miscs table. The first part of the water tab has values.
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
7
0115b97e8c39 Added global variables, C++ lovers will hate that. Added global acid data. Fixed several load and save errors in the json arrays in the recipe record. Added first part of the miscs table. The first part of the water tab has values.
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
8 QString my_brewery_name = "No-name";
133
08635b028dcf Load waters during recipe startup. Started calcWater() function. Load profile_setup record global. The print function uses the globals now too instead of loading from the database.
Michiel Broek <mbroek@mbse.eu>
parents: 131
diff changeset
9 QByteArray my_logoByteArray = 0;
08635b028dcf Load waters during recipe startup. Started calcWater() function. Load profile_setup record global. The print function uses the globals now too instead of loading from the database.
Michiel Broek <mbroek@mbse.eu>
parents: 131
diff changeset
10 int my_factor_mashhop = -30;
08635b028dcf Load waters during recipe startup. Started calcWater() function. Load profile_setup record global. The print function uses the globals now too instead of loading from the database.
Michiel Broek <mbroek@mbse.eu>
parents: 131
diff changeset
11 int my_factor_fwh = 10;
131
0115b97e8c39 Added global variables, C++ lovers will hate that. Added global acid data. Fixed several load and save errors in the json arrays in the recipe record. Added first part of the miscs table. The first part of the water tab has values.
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
12 int my_ibu_method = 0;
0115b97e8c39 Added global variables, C++ lovers will hate that. Added global acid data. Fixed several load and save errors in the json arrays in the recipe record. Added first part of the miscs table. The first part of the water tab has values.
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
13 int my_color_method = 0;
0115b97e8c39 Added global variables, C++ lovers will hate that. Added global acid data. Fixed several load and save errors in the json arrays in the recipe record. Added first part of the miscs table. The first part of the water tab has values.
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
14 double my_brix_correction = 1.04;
0115b97e8c39 Added global variables, C++ lovers will hate that. Added global acid data. Fixed several load and save errors in the json arrays in the recipe record. Added first part of the miscs table. The first part of the water tab has values.
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
15 double my_grain_absorbtion = 1.01;
133
08635b028dcf Load waters during recipe startup. Started calcWater() function. Load profile_setup record global. The print function uses the globals now too instead of loading from the database.
Michiel Broek <mbroek@mbse.eu>
parents: 131
diff changeset
16 int my_default_water = -1;
08635b028dcf Load waters during recipe startup. Started calcWater() function. Load profile_setup record global. The print function uses the globals now too instead of loading from the database.
Michiel Broek <mbroek@mbse.eu>
parents: 131
diff changeset
17 QString my_yeastlab = "";
337
8133cdb19aa1 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.
Michiel Broek <mbroek@mbse.eu>
parents: 336
diff changeset
18 int my_height = 0;
380
8f5c03ed4321 Global setup added hop utilisation defaults, these are used by the hops editor. In the hops editor, changing the hop form sets the new default utilisation. Hide and show the time edit entry instead of setting it read-only. The new defaults are loaded at program startup. Changed the global setup for the new utilisation fields and dropped the obsolete factor fields. The toIBU formula doesn't use my_factor_* variables anymore, hop differences now come from the utilisation field per hop. The global database is updated to the new defaults.
Michiel Broek <mbroek@mbse.eu>
parents: 373
diff changeset
19 double my_ut_pellet = 22.0;
8f5c03ed4321 Global setup added hop utilisation defaults, these are used by the hops editor. In the hops editor, changing the hop form sets the new default utilisation. Hide and show the time edit entry instead of setting it read-only. The new defaults are loaded at program startup. Changed the global setup for the new utilisation fields and dropped the obsolete factor fields. The toIBU formula doesn't use my_factor_* variables anymore, hop differences now come from the utilisation field per hop. The global database is updated to the new defaults.
Michiel Broek <mbroek@mbse.eu>
parents: 373
diff changeset
20 double my_ut_plug = 20.4;
8f5c03ed4321 Global setup added hop utilisation defaults, these are used by the hops editor. In the hops editor, changing the hop form sets the new default utilisation. Hide and show the time edit entry instead of setting it read-only. The new defaults are loaded at program startup. Changed the global setup for the new utilisation fields and dropped the obsolete factor fields. The toIBU formula doesn't use my_factor_* variables anymore, hop differences now come from the utilisation field per hop. The global database is updated to the new defaults.
Michiel Broek <mbroek@mbse.eu>
parents: 373
diff changeset
21 double my_ut_leaf = 20.0;
8f5c03ed4321 Global setup added hop utilisation defaults, these are used by the hops editor. In the hops editor, changing the hop form sets the new default utilisation. Hide and show the time edit entry instead of setting it read-only. The new defaults are loaded at program startup. Changed the global setup for the new utilisation fields and dropped the obsolete factor fields. The toIBU formula doesn't use my_factor_* variables anymore, hop differences now come from the utilisation field per hop. The global database is updated to the new defaults.
Michiel Broek <mbroek@mbse.eu>
parents: 373
diff changeset
22 double my_ut_wethop = 3.6;
8f5c03ed4321 Global setup added hop utilisation defaults, these are used by the hops editor. In the hops editor, changing the hop form sets the new default utilisation. Hide and show the time edit entry instead of setting it read-only. The new defaults are loaded at program startup. Changed the global setup for the new utilisation fields and dropped the obsolete factor fields. The toIBU formula doesn't use my_factor_* variables anymore, hop differences now come from the utilisation field per hop. The global database is updated to the new defaults.
Michiel Broek <mbroek@mbse.eu>
parents: 373
diff changeset
23 double my_ut_t45 = 50.0;
8f5c03ed4321 Global setup added hop utilisation defaults, these are used by the hops editor. In the hops editor, changing the hop form sets the new default utilisation. Hide and show the time edit entry instead of setting it read-only. The new defaults are loaded at program startup. Changed the global setup for the new utilisation fields and dropped the obsolete factor fields. The toIBU formula doesn't use my_factor_* variables anymore, hop differences now come from the utilisation field per hop. The global database is updated to the new defaults.
Michiel Broek <mbroek@mbse.eu>
parents: 373
diff changeset
24 double my_ut_co2extract = 35.0;
8f5c03ed4321 Global setup added hop utilisation defaults, these are used by the hops editor. In the hops editor, changing the hop form sets the new default utilisation. Hide and show the time edit entry instead of setting it read-only. The new defaults are loaded at program startup. Changed the global setup for the new utilisation fields and dropped the obsolete factor fields. The toIBU formula doesn't use my_factor_* variables anymore, hop differences now come from the utilisation field per hop. The global database is updated to the new defaults.
Michiel Broek <mbroek@mbse.eu>
parents: 373
diff changeset
25
131
0115b97e8c39 Added global variables, C++ lovers will hate that. Added global acid data. Fixed several load and save errors in the json arrays in the recipe record. Added first part of the miscs table. The first part of the water tab has values.
Michiel Broek <mbroek@mbse.eu>
parents:
diff changeset
26
158
24bc2de721d9 Activated print recipe button. The recipe record structure is now global. Added global product record structure.
Michiel Broek <mbroek@mbse.eu>
parents: 154
diff changeset
27 Recipe *recipe;
175
f1ed3a2a94e9 Initial import of EditProduct, the part from EditRecipe is ported.
Michiel Broek <mbroek@mbse.eu>
parents: 173
diff changeset
28 Product *product;
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
29
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
30 const char * const g_prod_stages[12] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
31 QT_TRANSLATE_NOOP("ProdStages", "Plan"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
32 QT_TRANSLATE_NOOP("ProdStages", "Wait"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
33 QT_TRANSLATE_NOOP("ProdStages", "Brew"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
34 QT_TRANSLATE_NOOP("ProdStages", "Primary"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
35 QT_TRANSLATE_NOOP("ProdStages", "Secondary"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
36 QT_TRANSLATE_NOOP("ProdStages", "Tertiary"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
37 QT_TRANSLATE_NOOP("ProdStages", "Package"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
38 QT_TRANSLATE_NOOP("ProdStages", "Carbonation"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
39 QT_TRANSLATE_NOOP("ProdStages", "Mature"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
40 QT_TRANSLATE_NOOP("ProdStages", "Taste"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
41 QT_TRANSLATE_NOOP("ProdStages", "Ready"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
42 QT_TRANSLATE_NOOP("ProdStages", "Closed")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
43 };
173
8514932b61aa Added menu entry products in production
Michiel Broek <mbroek@mbse.eu>
parents: 159
diff changeset
44
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
45 const char * const g_prod_split[7] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
46 QT_TRANSLATE_NOOP("Splitter", "Not divided"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
47 QT_TRANSLATE_NOOP("Splitter", "After mash"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
48 QT_TRANSLATE_NOOP("Splitter", "After boil"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
49 QT_TRANSLATE_NOOP("Splitter", "After cooling"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
50 QT_TRANSLATE_NOOP("Splitter", "After primary"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
51 QT_TRANSLATE_NOOP("Splitter", "After secondary"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
52 QT_TRANSLATE_NOOP("Splitter", "After tertiary")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
53 };
173
8514932b61aa Added menu entry products in production
Michiel Broek <mbroek@mbse.eu>
parents: 159
diff changeset
54
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
55 const char * const g_recipe_types[3] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
56 QT_TRANSLATE_NOOP("RecipeType", "Extract"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
57 QT_TRANSLATE_NOOP("RecipeType", "Partial Mash"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
58 QT_TRANSLATE_NOOP("RecipeType", "All Grain")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
59 };
159
231f5c8002e3 Added the largest part of print recipe.
Michiel Broek <mbroek@mbse.eu>
parents: 158
diff changeset
60
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
61 const char * const g_style_types[6] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
62 QT_TRANSLATE_NOOP("BeerType", "Lager"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
63 QT_TRANSLATE_NOOP("BeerType", "Ale"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
64 QT_TRANSLATE_NOOP("BeerType", "Mead"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
65 QT_TRANSLATE_NOOP("BeerType", "Wheat"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
66 QT_TRANSLATE_NOOP("BeerType", "Mixed"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
67 QT_TRANSLATE_NOOP("BeerType", "Cider")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
68 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
69
336
e97f9e87d94b IBU method names are now global.
Michiel Broek <mbroek@mbse.eu>
parents: 323
diff changeset
70 const char * g_ibu_method[3] = {
e97f9e87d94b IBU method names are now global.
Michiel Broek <mbroek@mbse.eu>
parents: 323
diff changeset
71 "Tinseth",
339
2f3cfb983fcc Removed Garetz and Rager IBU calculations, we will only use Tinseth
Michiel Broek <mbroek@mbse.eu>
parents: 337
diff changeset
72 "Tinseth++",
2f3cfb983fcc Removed Garetz and Rager IBU calculations, we will only use Tinseth
Michiel Broek <mbroek@mbse.eu>
parents: 337
diff changeset
73 "N/A"
336
e97f9e87d94b IBU method names are now global.
Michiel Broek <mbroek@mbse.eu>
parents: 323
diff changeset
74 };
e97f9e87d94b IBU method names are now global.
Michiel Broek <mbroek@mbse.eu>
parents: 323
diff changeset
75
341
1b1e2d4c1a3e Cooling method dropdown table loads from a global table. Updated the translations.
Michiel Broek <mbroek@mbse.eu>
parents: 339
diff changeset
76 const char * const g_chiller_types[5] = {
1b1e2d4c1a3e Cooling method dropdown table loads from a global table. Updated the translations.
Michiel Broek <mbroek@mbse.eu>
parents: 339
diff changeset
77 QT_TRANSLATE_NOOP("ChillerType", "-"),
1b1e2d4c1a3e Cooling method dropdown table loads from a global table. Updated the translations.
Michiel Broek <mbroek@mbse.eu>
parents: 339
diff changeset
78 QT_TRANSLATE_NOOP("ChillerType", "Emersion chiller"),
1b1e2d4c1a3e Cooling method dropdown table loads from a global table. Updated the translations.
Michiel Broek <mbroek@mbse.eu>
parents: 339
diff changeset
79 QT_TRANSLATE_NOOP("ChillerType", "Counterflow chiller"),
1b1e2d4c1a3e Cooling method dropdown table loads from a global table. Updated the translations.
Michiel Broek <mbroek@mbse.eu>
parents: 339
diff changeset
80 QT_TRANSLATE_NOOP("ChillerType", "Au bain marie"),
1b1e2d4c1a3e Cooling method dropdown table loads from a global table. Updated the translations.
Michiel Broek <mbroek@mbse.eu>
parents: 339
diff changeset
81 QT_TRANSLATE_NOOP("ChillerType", "Natural")
1b1e2d4c1a3e Cooling method dropdown table loads from a global table. Updated the translations.
Michiel Broek <mbroek@mbse.eu>
parents: 339
diff changeset
82 };
1b1e2d4c1a3e Cooling method dropdown table loads from a global table. Updated the translations.
Michiel Broek <mbroek@mbse.eu>
parents: 339
diff changeset
83
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
84 const char * const g_fermentable_types[5] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
85 QT_TRANSLATE_NOOP("FermentableType", "Grain"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
86 QT_TRANSLATE_NOOP("FermentableType", "Sugar"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
87 QT_TRANSLATE_NOOP("FermentableType", "Extract"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
88 QT_TRANSLATE_NOOP("FermentableType", "Dry extract"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
89 QT_TRANSLATE_NOOP("FermentableType", "Adjunct")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
90 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
91
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
92 const char * const g_fermentable_graintypes[7] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
93 QT_TRANSLATE_NOOP("FermentableGraintype", "Base"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
94 QT_TRANSLATE_NOOP("FermentableGraintype", "Roast"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
95 QT_TRANSLATE_NOOP("FermentableGraintype", "Crystal"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
96 QT_TRANSLATE_NOOP("FermentableGraintype", "Kilned"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
97 QT_TRANSLATE_NOOP("FermentableGraintype", "Sour Malt"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
98 QT_TRANSLATE_NOOP("FermentableGraintype", "Special"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
99 QT_TRANSLATE_NOOP("FermentableGraintype", "No malt")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
100 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
101
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
102 const char * const g_fermentable_added[6] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
103 QT_TRANSLATE_NOOP("FermentableAdded", "Mash"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
104 QT_TRANSLATE_NOOP("FermentableAdded", "Boil"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
105 QT_TRANSLATE_NOOP("FermentableAdded", "Fermentation"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
106 QT_TRANSLATE_NOOP("FermentableAdded", "Lagering"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
107 QT_TRANSLATE_NOOP("FermentableAdded", "Bottle"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
108 QT_TRANSLATE_NOOP("FermentableAdded", "Kegs")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
109 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
110
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
111 const char * const g_hop_types[3] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
112 QT_TRANSLATE_NOOP("HopTypes", "Bittering"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
113 QT_TRANSLATE_NOOP("HopTypes", "Aroma"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
114 QT_TRANSLATE_NOOP("HopTypes", "Both")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
115 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
116
373
b02aca4e926c First load of changes for hops. In EditHop load the dropdown buttons from the global table. Use named query fields. Added database utilisation and bu_factor fields for hop extracts. Added edit fields for these new fields. Added post boil SG, utilisation and bu_factor parameters to the toIBU function. Added hops form parameter to the hopFlavourContribution and hopAromaContribution display bars. In the hops inventory list dispay volumes instead of weight for hop extracts. Modified the TinsethIBU function to use utilisation and bu_factor parameters. Add calculations for co2 and iso hop extracts, this is work in progress. The toIBU function makes use of the preSG and postSG values to use the correct SG to caall the TinsethIBU function. This results in a bit lower IBU values mostly affecting the late additions. Added use hop at bottling for iso hop extracts like Tetra hops using the formula from BarthHaas.
Michiel Broek <mbroek@mbse.eu>
parents: 355
diff changeset
117 const char * const g_hop_forms[7] = {
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
118 QT_TRANSLATE_NOOP("HopForm", "Pellet"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
119 QT_TRANSLATE_NOOP("HopForm", "Plug"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
120 QT_TRANSLATE_NOOP("HopForm", "Leaf"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
121 QT_TRANSLATE_NOOP("HopForm", "Leaf wet"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
122 QT_TRANSLATE_NOOP("HopForm", "Cryo"),
373
b02aca4e926c First load of changes for hops. In EditHop load the dropdown buttons from the global table. Use named query fields. Added database utilisation and bu_factor fields for hop extracts. Added edit fields for these new fields. Added post boil SG, utilisation and bu_factor parameters to the toIBU function. Added hops form parameter to the hopFlavourContribution and hopAromaContribution display bars. In the hops inventory list dispay volumes instead of weight for hop extracts. Modified the TinsethIBU function to use utilisation and bu_factor parameters. Add calculations for co2 and iso hop extracts, this is work in progress. The toIBU function makes use of the preSG and postSG values to use the correct SG to caall the TinsethIBU function. This results in a bit lower IBU values mostly affecting the late additions. Added use hop at bottling for iso hop extracts like Tetra hops using the formula from BarthHaas.
Michiel Broek <mbroek@mbse.eu>
parents: 355
diff changeset
123 QT_TRANSLATE_NOOP("HopForm", "CO2 extract"),
b02aca4e926c First load of changes for hops. In EditHop load the dropdown buttons from the global table. Use named query fields. Added database utilisation and bu_factor fields for hop extracts. Added edit fields for these new fields. Added post boil SG, utilisation and bu_factor parameters to the toIBU function. Added hops form parameter to the hopFlavourContribution and hopAromaContribution display bars. In the hops inventory list dispay volumes instead of weight for hop extracts. Modified the TinsethIBU function to use utilisation and bu_factor parameters. Add calculations for co2 and iso hop extracts, this is work in progress. The toIBU function makes use of the preSG and postSG values to use the correct SG to caall the TinsethIBU function. This results in a bit lower IBU values mostly affecting the late additions. Added use hop at bottling for iso hop extracts like Tetra hops using the formula from BarthHaas.
Michiel Broek <mbroek@mbse.eu>
parents: 355
diff changeset
124 QT_TRANSLATE_NOOP("HopForm", "Iso extract")
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
125 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
126
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
127 const char * const g_hop_useat[7] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
128 QT_TRANSLATE_NOOP("HopUse", "Mash"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
129 QT_TRANSLATE_NOOP("HopUse", "First wort"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
130 QT_TRANSLATE_NOOP("HopUse", "Boil"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
131 QT_TRANSLATE_NOOP("HopUse", "Aroma"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
132 QT_TRANSLATE_NOOP("HopUse", "Whirlpool"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
133 QT_TRANSLATE_NOOP("HopUse", "Dry hop"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
134 QT_TRANSLATE_NOOP("HopUse", "Bottling")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
135 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
136
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
137 const char * const g_misc_types[7] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
138 QT_TRANSLATE_NOOP("MiscType", "Spice"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
139 QT_TRANSLATE_NOOP("MiscType", "Herb"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
140 QT_TRANSLATE_NOOP("MiscType", "Flavor"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
141 QT_TRANSLATE_NOOP("MiscType", "Fining"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
142 QT_TRANSLATE_NOOP("MiscType", "Water agent"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
143 QT_TRANSLATE_NOOP("MiscType", "Yeast nutrient"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
144 QT_TRANSLATE_NOOP("MiscType", "Other")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
145 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
146
355
f3318d9d6668 Added misc_uses spage step. Corrected some defines mol values.
Michiel Broek <mbroek@mbse.eu>
parents: 341
diff changeset
147 const char * const g_misc_uses[7] = {
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
148 QT_TRANSLATE_NOOP("MiscUse", "Starter"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
149 QT_TRANSLATE_NOOP("MiscUse", "Mash"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
150 QT_TRANSLATE_NOOP("MiscUse", "Boil"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
151 QT_TRANSLATE_NOOP("MiscUse", "Primary"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
152 QT_TRANSLATE_NOOP("MiscUse", "Secondary"),
355
f3318d9d6668 Added misc_uses spage step. Corrected some defines mol values.
Michiel Broek <mbroek@mbse.eu>
parents: 341
diff changeset
153 QT_TRANSLATE_NOOP("MiscUse", "Bottling"),
f3318d9d6668 Added misc_uses spage step. Corrected some defines mol values.
Michiel Broek <mbroek@mbse.eu>
parents: 341
diff changeset
154 QT_TRANSLATE_NOOP("MiscUse", "Sparge")
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
155 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
156
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
157 const char * const g_yeast_types[8] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
158 QT_TRANSLATE_NOOP("YeastType", "Lager"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
159 QT_TRANSLATE_NOOP("YeastType", "Ale"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
160 QT_TRANSLATE_NOOP("YeastType", "Wheat"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
161 QT_TRANSLATE_NOOP("YeastType", "Wine"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
162 QT_TRANSLATE_NOOP("YeastType", "Champagne"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
163 QT_TRANSLATE_NOOP("YeastType", "Brett"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
164 QT_TRANSLATE_NOOP("YeastType", "Kveik"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
165 QT_TRANSLATE_NOOP("YeastType", "Hybrid")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
166 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
167
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
168 const char * const g_yeast_forms[7] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
169 QT_TRANSLATE_NOOP("YeastForm", "Liquid"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
170 QT_TRANSLATE_NOOP("YeastForm", "Dry"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
171 QT_TRANSLATE_NOOP("YeastForm", "Slant"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
172 QT_TRANSLATE_NOOP("YeastForm", "Culture"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
173 QT_TRANSLATE_NOOP("YeastForm", "Frozen"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
174 QT_TRANSLATE_NOOP("YeastForm", "Bottle"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
175 QT_TRANSLATE_NOOP("YeastForm", "Dried")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
176 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
177
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
178 const char * const g_yeast_use[4] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
179 QT_TRANSLATE_NOOP("YeastUse", "Primary"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
180 QT_TRANSLATE_NOOP("YeastUse", "Secondary"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
181 QT_TRANSLATE_NOOP("YeastUse", "Tertiary"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
182 QT_TRANSLATE_NOOP("YeastUse", "Bottle")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
183 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
184
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
185 const char * const g_yeast_starter[3] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
186 QT_TRANSLATE_NOOP("YeastStarter", "Stirred"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
187 QT_TRANSLATE_NOOP("YeastStarter", "Shaken"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
188 QT_TRANSLATE_NOOP("YeastStarter", "Simple")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
189 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
190
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
191 const char * const g_step_types[3] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
192 QT_TRANSLATE_NOOP("StepType", "Infusion"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
193 QT_TRANSLATE_NOOP("StepType", "Temperature"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
194 QT_TRANSLATE_NOOP("StepType", "Decoction")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
195 };
154
1af9f7b7f317 Moved QStringList arrays to global.
Michiel Broek <mbroek@mbse.eu>
parents: 133
diff changeset
196
301
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
197 const char * const g_tun_materials[4] = {
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
198 QT_TRANSLATE_NOOP("TunMaterial", "Stainless Steel"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
199 QT_TRANSLATE_NOOP("TunMaterial", "Aluminium"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
200 QT_TRANSLATE_NOOP("TunMaterial", "Plastics"),
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
201 QT_TRANSLATE_NOOP("TunMaterial", "Copper")
fe6346211b5b Finally the translation of string arrays is working.
Michiel Broek <mbroek@mbse.eu>
parents: 300
diff changeset
202 };
176
69a033e099a2 Tab 2 equipent, all editfields placed.
Michiel Broek <mbroek@mbse.eu>
parents: 175
diff changeset
203

mercurial