Redesign of the water tabs in product and recipe editors. Prepare for sparge water salt additions. Acid additions are now automatic or manual for mash and sparge. Fixed error in acid calculation strength. Fixed phophoric SG value.

Mon, 18 Jul 2022 17:04:02 +0200

author
Michiel Broek <mbroek@mbse.eu>
date
Mon, 18 Jul 2022 17:04:02 +0200
changeset 359
dfbb012c631c
parent 358
d89bc21e2f07
child 360
b70cfa20ac46

Redesign of the water tabs in product and recipe editors. Prepare for sparge water salt additions. Acid additions are now automatic or manual for mash and sparge. Fixed error in acid calculation strength. Fixed phophoric SG value.

src/EditProduct.cpp file | annotate | diff | comparison | revisions
src/EditProduct.h file | annotate | diff | comparison | revisions
src/EditProductTab1.cpp file | annotate | diff | comparison | revisions
src/EditProductTab5.cpp file | annotate | diff | comparison | revisions
src/EditProductTab8.cpp file | annotate | diff | comparison | revisions
src/EditRecipe.cpp file | annotate | diff | comparison | revisions
src/EditRecipe.h file | annotate | diff | comparison | revisions
src/EditRecipeTab1.cpp file | annotate | diff | comparison | revisions
src/EditRecipeTab4.cpp file | annotate | diff | comparison | revisions
src/EditRecipeTab7.cpp file | annotate | diff | comparison | revisions
ui/EditProduct.ui file | annotate | diff | comparison | revisions
ui/EditRecipe.ui file | annotate | diff | comparison | revisions
--- a/src/EditProduct.cpp	Sun Jul 17 22:18:48 2022 +0200
+++ b/src/EditProduct.cpp	Mon Jul 18 17:04:02 2022 +0200
@@ -59,10 +59,6 @@
 	ui->sp_acidtypeEdit->addItem(my_acids.at(i).name_en);
     }
 
-    ui->sp_sourceEdit->addItem(tr("Source 1"));
-    ui->sp_sourceEdit->addItem(tr("Source 2"));
-    ui->sp_sourceEdit->addItem(tr("Mixed"));
-
     query.prepare("SELECT name FROM inventory_waters ORDER BY record");
     query.exec();
     ui->w1_nameEdit->addItem("");
@@ -109,6 +105,10 @@
 	ui->keg_sugarEdit->addItem(query.value(0).toString());
     }
 
+    ui->spargeGroup->setId(ui->w1_spButton, 0);
+    ui->spargeGroup->setId(ui->w2_spButton, 1);
+    ui->spargeGroup->setId(ui->wg_spButton, 2);
+
     if (id >= 0) {
 	if (! DB_product::load(product, this, id))
 	    return;
@@ -405,7 +405,7 @@
     ui->w1_volEdit->setValue(product->w1_amount);
     ui->w1_caEdit->setValue(product->w1_calcium);
     ui->w1_mgEdit->setValue(product->w1_magnesium);
-    ui->w1_hco3Edit->setValue(product->w1_total_alkalinity * 1.22);
+    ui->w1_hco3Edit->setValue(Utils::Bicarbonate(product->w1_total_alkalinity, product->w1_ph));
     ui->w1_caco3Edit->setValue(product->w1_total_alkalinity);
     ui->w1_naEdit->setValue(product->w1_sodium);
     ui->w1_clEdit->setValue(product->w1_chloride);
@@ -441,7 +441,7 @@
     ui->w2_volEdit->setValue(product->w2_amount);
     ui->w2_caEdit->setValue(product->w2_calcium);
     ui->w2_mgEdit->setValue(product->w2_magnesium);
-    ui->w2_hco3Edit->setValue(product->w2_total_alkalinity * 1.22);
+    ui->w2_hco3Edit->setValue(Utils::Bicarbonate(product->w2_total_alkalinity, product->w2_ph));
     ui->w2_caco3Edit->setValue(product->w2_total_alkalinity);
     ui->w2_naEdit->setValue(product->w2_sodium);
     ui->w2_clEdit->setValue(product->w2_chloride);
@@ -452,11 +452,12 @@
     ui->mw_phEdit->setButtonSymbols(product->calc_acid ? QAbstractSpinBox::UpDownArrows : QAbstractSpinBox::NoButtons);
     ui->mw_acidvolEdit->setReadOnly(product->calc_acid);
     ui->mw_acidvolEdit->setButtonSymbols(product->calc_acid ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
-
+    ui->sp_phEdit->setReadOnly(! product->calc_acid);
+    ui->sp_phEdit->setButtonSymbols(product->calc_acid ? QAbstractSpinBox::UpDownArrows : QAbstractSpinBox::NoButtons);
+    ui->sp_acidvolEdit->setReadOnly(product->calc_acid);
+    ui->sp_acidvolEdit->setButtonSymbols(product->calc_acid ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     ui->sp_volEdit->setValue(product->sparge_volume);
-    ui->sp_tempEdit->setValue(product->sparge_temp);
     ui->sp_phEdit->setValue(product->sparge_ph);
-    ui->sp_sourceEdit->setCurrentIndex(product->sparge_source);
     ui->sp_acidtypeEdit->setCurrentIndex(product->sparge_acid_type);
     ui->sp_acidpercEdit->setValue(product->sparge_acid_perc);
     ui->sp_acidvolEdit->setValue(product->sparge_acid_amount);
@@ -469,7 +470,7 @@
     ui->brew_mashsgEdit->setValue(product->brew_mash_sg);
     ui->brew_mashsgShow->setValue(0);
     ui->brew_masheffShow->setValue(product->brew_mash_efficiency);
-    ui->brew_spargetempShow->setValue(product->sparge_temp);
+    ui->brew_spargetempEdit->setValue(product->sparge_temp);
     ui->brew_spargevolShow->setValue(product->sparge_volume);
     ui->brew_spargeestShow->setValue(product->brew_sparge_est);
     ui->brew_spargephEdit->setValue(product->brew_sparge_ph);
@@ -618,6 +619,11 @@
     connect(ui->bs_mgcl2Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::wb_mgcl2_changed);
     connect(ui->bs_nahco3Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::wb_nahco3_changed);
     connect(ui->bs_caco3Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::wb_caco3_changed);
+    connect(ui->ss_cacl2Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::sp_cacl2_changed);
+    connect(ui->ss_caso4Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::sp_caso4_changed);
+    connect(ui->ss_mgso4Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::sp_mgso4_changed);
+    connect(ui->ss_naclEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::sp_nacl_changed);
+    connect(ui->ss_mgcl2Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::sp_mgcl2_changed);
     connect(ui->mw_autoEdit, &QCheckBox::stateChanged, this, &EditProduct::mw_calc_acid_clicked);
     connect(ui->mw_phEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::mw_ph_changed);
     connect(ui->mw_acidvolEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::mw_acid_changed);
@@ -627,10 +633,10 @@
     connect(ui->w2_nameEdit, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &EditProduct::w2_name_changed);
     connect(ui->w2_volEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::w2_volume_changed);
     connect(ui->sp_volEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::sp_volume_changed);
-    connect(ui->sp_tempEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::sp_temp_changed);
-    connect(ui->sp_sourceEdit, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &EditProduct::sp_source_changed);
+    connect(ui->spargeGroup, SIGNAL(buttonClicked(int)), this, SLOT(sp_group_changed(int)));
     connect(ui->sp_acidtypeEdit, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &EditProduct::sp_type_changed);
     connect(ui->sp_phEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::sp_ph_changed);
+    connect(ui->sp_acidvolEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::sp_acid_changed);
 
     /* All signals from tab Brewday */
     calcEfficiencyBeforeBoil();
@@ -646,6 +652,7 @@
     connect(ui->brew_mashphEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::brew_mashph_changed);
     connect(ui->brew_mashsgEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::brew_mashsg_changed);
     connect(ui->brew_spargephEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::brew_spargeph_changed);
+    connect(ui->brew_spargetempEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::sp_temp_changed);
     connect(ui->brew_preboilphEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::brew_preboilph_changed);
     connect(ui->brew_preboilsgEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::brew_preboilsg_changed);
     connect(ui->brew_preboilvolEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditProduct::brew_preboilvol_changed);
--- a/src/EditProduct.h	Sun Jul 17 22:18:48 2022 +0200
+++ b/src/EditProduct.h	Mon Jul 18 17:04:02 2022 +0200
@@ -128,6 +128,11 @@
     void wb_mgcl2_changed(double val);
     void wb_nahco3_changed(double val);
     void wb_caco3_changed(double val);
+    void sp_cacl2_changed(double val);
+    void sp_caso4_changed(double val);
+    void sp_mgso4_changed(double val);
+    void sp_nacl_changed(double val);
+    void sp_mgcl2_changed(double val);
     void mw_calc_acid_clicked();
     void wt_target_changed(int val);
     void mw_ph_changed(double val);
@@ -135,9 +140,10 @@
     void mw_type_changed(int val);
     void sp_volume_changed(double val);
     void sp_temp_changed(double val);
-    void sp_source_changed(int val);
+    void sp_group_changed(int val);
     void sp_type_changed(int val);
     void sp_ph_changed(double val);
+    void sp_acid_changed(double val);
     void step_name_changed(QString val);
     void step_type_changed(int val);
     void step_temp_changed(double val);
@@ -278,8 +284,8 @@
     void showEquipment();
     void initEquipment();
     void setStage();
-    void brewing_salt_sub(QString salt, double val);
-    void set_brewing_salt(QString salt, double val);
+    void brewing_salt_sub(QString salt, double val, int use);
+    void set_brewing_salt(QString salt, double val, int use);
     void calcMiscs();
     void calcFermentables();
     void calcFermentablesFromOG(double og);
--- a/src/EditProductTab1.cpp	Sun Jul 17 22:18:48 2022 +0200
+++ b/src/EditProductTab1.cpp	Mon Jul 18 17:04:02 2022 +0200
@@ -290,7 +290,6 @@
     ui->mash_pickEdit->setDisabled(stage > PROD_STAGE_BREW);
 
     /* Tab 8, water */
-    ui->sp_sourceEdit->setDisabled(stage > PROD_STAGE_BREW);
     ui->wt_sourceEdit->setDisabled(stage > PROD_STAGE_BREW);
     ui->w1_nameEdit->setDisabled(stage > PROD_STAGE_BREW);
     ui->w2_nameEdit->setDisabled(stage > PROD_STAGE_BREW);
@@ -298,10 +297,8 @@
     ui->sp_acidtypeEdit->setDisabled(stage > PROD_STAGE_BREW);
     ui->w2_volEdit->setReadOnly(stage > PROD_STAGE_BREW);
     ui->w2_volEdit->setButtonSymbols((stage > PROD_STAGE_BREW) ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
-    ui->sp_phEdit->setReadOnly(stage > PROD_STAGE_BREW);
-    ui->sp_phEdit->setButtonSymbols((stage > PROD_STAGE_BREW) ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
-    ui->sp_tempEdit->setReadOnly(stage > PROD_STAGE_BREW);
-    ui->sp_tempEdit->setButtonSymbols((stage > PROD_STAGE_BREW) ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
+    //ui->sp_tempEdit->setReadOnly(stage > PROD_STAGE_BREW);
+    //ui->sp_tempEdit->setButtonSymbols((stage > PROD_STAGE_BREW) ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     ui->sp_volEdit->setReadOnly(stage > PROD_STAGE_BREW);
     ui->sp_volEdit->setButtonSymbols((stage > PROD_STAGE_BREW) ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     ui->bs_cacl2Edit->setReadOnly(stage > PROD_STAGE_BREW);
@@ -323,11 +320,22 @@
 	ui->mw_phEdit->setButtonSymbols(QAbstractSpinBox::NoButtons);
 	ui->mw_acidvolEdit->setReadOnly(true);
 	ui->mw_acidvolEdit->setButtonSymbols(QAbstractSpinBox::NoButtons);
+	ui->sp_phEdit->setReadOnly(true);
+    	ui->sp_phEdit->setButtonSymbols(QAbstractSpinBox::NoButtons);
+	ui->sp_acidvolEdit->setReadOnly(true);
+        ui->sp_acidvolEdit->setButtonSymbols(QAbstractSpinBox::NoButtons);
+	ui->w1_spButton->setDisabled(true);
+    	ui->w2_spButton->setDisabled(true);
+    	ui->wg_spButton->setDisabled(true);
     } else {
     	ui->mw_phEdit->setReadOnly(! product->calc_acid);
     	ui->mw_phEdit->setButtonSymbols(product->calc_acid ? QAbstractSpinBox::UpDownArrows : QAbstractSpinBox::NoButtons);
     	ui->mw_acidvolEdit->setReadOnly(product->calc_acid);
     	ui->mw_acidvolEdit->setButtonSymbols(product->calc_acid ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
+	ui->sp_phEdit->setReadOnly(! product->calc_acid);
+    	ui->sp_phEdit->setButtonSymbols(product->calc_acid ? QAbstractSpinBox::UpDownArrows : QAbstractSpinBox::NoButtons);
+	ui->sp_acidvolEdit->setReadOnly(product->calc_acid);
+        ui->sp_acidvolEdit->setButtonSymbols(product->calc_acid ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     }
     ui->mw_autoEdit->setDisabled(stage > PROD_STAGE_BREW);
 
@@ -418,6 +426,8 @@
     ui->brew_mashsgEdit->setButtonSymbols( (stage > PROD_STAGE_BREW) ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     ui->brew_spargephEdit->setReadOnly(stage > PROD_STAGE_BREW);
     ui->brew_spargephEdit->setButtonSymbols( (stage > PROD_STAGE_BREW) ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
+    ui->brew_spargetempEdit->setReadOnly(stage > PROD_STAGE_BREW);
+    ui->brew_spargetempEdit->setButtonSymbols((stage > PROD_STAGE_BREW) ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     ui->brew_preboilphEdit->setReadOnly(stage > PROD_STAGE_BREW);
     ui->brew_preboilphEdit->setButtonSymbols( (stage > PROD_STAGE_BREW) ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     ui->brew_preboilsgEdit->setReadOnly(stage > PROD_STAGE_BREW);
--- a/src/EditProductTab5.cpp	Sun Jul 17 22:18:48 2022 +0200
+++ b/src/EditProductTab5.cpp	Mon Jul 18 17:04:02 2022 +0200
@@ -65,6 +65,13 @@
     const QSignalBlocker blocker7(ui->bs_caco3Edit);
     const QSignalBlocker blocker8(ui->mw_acidPick);
     const QSignalBlocker blocker9(ui->mw_acidvolEdit);
+    const QSignalBlocker blocker10(ui->ss_cacl2Edit);
+    const QSignalBlocker blocker11(ui->ss_caso4Edit);
+    const QSignalBlocker blocker12(ui->ss_mgso4Edit);
+    const QSignalBlocker blocker13(ui->ss_naclEdit);
+    const QSignalBlocker blocker14(ui->ss_mgcl2Edit);
+    const QSignalBlocker blocker15(ui->sp_acidtypeEdit);
+    const QSignalBlocker blocker16(ui->sp_acidvolEdit);
 
     const QStringList labels({tr("Ingredient"), tr("Type"), tr("Use at"), tr("Time"), tr("Amount"), tr("Stock"), tr("Delete"), tr("Edit") });
 
@@ -179,7 +186,7 @@
 	/*
 	 * Update the water agents.
 	 */
-	if (product->miscs.at(i).type == MISC_TYPES_WATER_AGENT) {
+	if (product->miscs.at(i).type == MISC_TYPES_WATER_AGENT && product->miscs.at(i).use_use == MISC_USES_MASH) {
 	    if (product->miscs.at(i).name == "CaCl2") {
 		ui->bs_cacl2Edit->setValue(product->miscs.at(i).amount * 1000.0);
 	    } else if (product->miscs.at(i).name == "CaSO4") {
@@ -219,7 +226,43 @@
                 ui->mw_acidpercEdit->setValue(my_acids.at(3).AcidPrc);
                 ui->mw_acidvolEdit->setValue(product->miscs.at(i).amount * 1000.0);
 	    }
-	}
+	} else if (product->miscs.at(i).type == MISC_TYPES_WATER_AGENT && product->miscs.at(i).use_use == MISC_USES_SPARGE) {
+            if (product->miscs.at(i).name == "CaCl2") {
+                ui->ss_cacl2Edit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "CaSO4") {
+                ui->ss_caso4Edit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "MgSO4") {
+                ui->ss_mgso4Edit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "NaCl") {
+                ui->ss_naclEdit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "MgCl2") {
+                ui->ss_mgcl2Edit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "Melkzuur" || product->miscs.at(i).name == "Lactic") {
+                product->sparge_acid_type = 0;
+                product->sparge_acid_perc = my_acids.at(0).AcidPrc;
+                ui->sp_acidtypeEdit->setCurrentIndex(0);
+                ui->sp_acidpercEdit->setValue(my_acids.at(0).AcidPrc);
+                ui->sp_acidvolEdit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "Zoutzuur" || product->miscs.at(i).name == "Hydrochloric") {
+                product->sparge_acid_type = 1;
+                product->sparge_acid_perc = my_acids.at(1).AcidPrc;
+                ui->sp_acidtypeEdit->setCurrentIndex(1);
+                ui->sp_acidpercEdit->setValue(my_acids.at(1).AcidPrc);
+                ui->sp_acidvolEdit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "Fosforzuur" || product->miscs.at(i).name == "Phosphoric") {
+                product->sparge_acid_type = 2;
+                product->sparge_acid_perc = my_acids.at(2).AcidPrc;
+                ui->sp_acidtypeEdit->setCurrentIndex(2);
+                ui->sp_acidpercEdit->setValue(my_acids.at(2).AcidPrc);
+                ui->sp_acidvolEdit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "Zwavelzuur" || product->miscs.at(i).name == "Sulfuric") {
+                product->sparge_acid_type = 3;
+                product->sparge_acid_perc = my_acids.at(3).AcidPrc;
+                ui->sp_acidtypeEdit->setCurrentIndex(3);
+                ui->sp_acidpercEdit->setValue(my_acids.at(3).AcidPrc);
+                ui->sp_acidvolEdit->setValue(product->miscs.at(i).amount * 1000.0);
+            }
+        }
     }
 }
 
@@ -229,6 +272,7 @@
     product->miscs_ok = true;
     for (int i = 0; i < product->miscs.size(); i++) {
 	if ((((product->inventory_reduced <= PROD_STAGE_BREW)     && (product->miscs.at(i).use_use <= MISC_USES_BOIL)) ||  // Starter, Mash, Boil
+	     ((product->inventory_reduced <= PROD_STAGE_BREW)     && (product->miscs.at(i).use_use == MISC_USES_SPARGE)) ||
              ((product->inventory_reduced <= PROD_STAGE_PRIMARY)  && (product->miscs.at(i).use_use == MISC_USES_PRIMARY)) ||
              ((product->inventory_reduced <= PROD_STAGE_TERTIARY) && (product->miscs.at(i).use_use == MISC_USES_SECONDARY)) ||
              ((product->inventory_reduced <= PROD_STAGE_PACKAGE)  && (product->miscs.at(i).use_use == MISC_USES_BOTTLING))) &&
@@ -242,7 +286,7 @@
 /*
  * Manipulate the memory array and update the miscs table.
  */
-void EditProduct::brewing_salt_sub(QString salt, double val)
+void EditProduct::brewing_salt_sub(QString salt, double val, int use)
 {
     QTableWidgetItem *item;
 
@@ -252,8 +296,8 @@
 	 * Remove this salt if it is in the table.
 	 */
 	for (int i = 0; i < product->miscs.size(); i++) {
-	    if (salt.contains(product->miscs.at(i).name)) {
-		qDebug() << "  brewing_salt_sub delete" << salt;
+	    if (salt.contains(product->miscs.at(i).name) && product->miscs.at(i).use_use == use) {
+		qDebug() << "  brewing_salt_sub delete" << salt << use;
 		product->miscs.removeAt(i);
 		refreshMiscs();
 		return;
@@ -268,7 +312,7 @@
      * If it is, update the amount.
      */
     for (int i = 0; i < product->miscs.size(); i++) {
-	if (salt.contains(product->miscs.at(i).name)) {
+	if (salt.contains(product->miscs.at(i).name) && product->miscs.at(i).use_use == use) {
 	    product->miscs[i].amount = val / 1000.0;
 	    if (product->miscs.at(i).amount_is_weight)
             	item = new QTableWidgetItem(QString("%1 gr").arg(val, 3, 'f', 2, '0'));
@@ -294,7 +338,7 @@
 	    m.name = query.value(1).toString();
             m.amount = val / 1000.0;
             m.type = query.value(2).toInt();
-            m.use_use = query.value(3).toInt();
+            m.use_use = use;
             m.time = query.value(4).toDouble();
             m.amount_is_weight = query.value(5).toInt() ? true:false;
             m.cost = query.value(10).toDouble();
@@ -305,18 +349,18 @@
 	}
     }
 
-    qDebug() << "brewing_salt_sub, nothing done." << salt << val;
+    qDebug() << "brewing_salt_sub, nothing done." << salt << val << use;
 }
 
 
 /*
  * Edit brewing salt and recalculate.
  */
-void EditProduct::set_brewing_salt(QString salt, double val)
+void EditProduct::set_brewing_salt(QString salt, double val, int use)
 {
     val = round(val * 100.0) / 100.0;
-    qDebug() << "set_brewing_salt" << salt << val;
-    brewing_salt_sub(salt, val);
+    qDebug() << "set_brewing_salt" << salt << val << use;
+    brewing_salt_sub(salt, val, use);
     calcWater();
     is_changed();
 }
@@ -677,6 +721,7 @@
     useatEdit->addItem(tr("Primary"));
     useatEdit->addItem(tr("Secondary"));
     useatEdit->addItem(tr("Bottling"));
+    useatEdit->addItem(tr("Sparge"));
     useatEdit->setCurrentIndex(product->miscs.at(product->miscs_row).use_use);
 
     minstockEdit = new QCheckBox(dialog);
@@ -737,6 +782,11 @@
     const QSignalBlocker blocker6(ui->bs_nahco3Edit);
     const QSignalBlocker blocker7(ui->bs_caco3Edit);
     const QSignalBlocker blocker9(ui->mw_acidvolEdit);
+    const QSignalBlocker blocker10(ui->ss_cacl2Edit);
+    const QSignalBlocker blocker11(ui->ss_caso4Edit);
+    const QSignalBlocker blocker12(ui->ss_mgso4Edit);
+    const QSignalBlocker blocker13(ui->ss_naclEdit);
+    const QSignalBlocker blocker14(ui->ss_mgcl2Edit);
 
     for (int i = 0; i < product->miscs.size(); i++) {
 	amount = product->miscs.at(i).amount * factor;
@@ -745,7 +795,7 @@
 	/*
          * Update the water agents.
          */
-        if (product->miscs.at(i).type == MISC_TYPES_WATER_AGENT) {
+        if (product->miscs.at(i).type == MISC_TYPES_WATER_AGENT && product->miscs.at(i).use_use == MISC_USES_MASH) {
             if (product->miscs.at(i).name == "CaCl2") {
                 ui->bs_cacl2Edit->setValue(product->miscs.at(i).amount * 1000.0);
             } else if (product->miscs.at(i).name == "CaSO4") {
@@ -769,6 +819,26 @@
             } else if (product->miscs.at(i).name == "Zwavelzuur" || product->miscs.at(i).name == "Sulfuric") {
                 ui->mw_acidvolEdit->setValue(product->miscs.at(i).amount * 1000.0);
             }
+        } else if (product->miscs.at(i).type == MISC_TYPES_WATER_AGENT && product->miscs.at(i).use_use == MISC_USES_SPARGE) {
+            if (product->miscs.at(i).name == "CaCl2") {
+                ui->ss_cacl2Edit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "CaSO4") {
+                ui->ss_caso4Edit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "MgSO4") {
+                ui->ss_mgso4Edit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "NaCl") {
+                ui->ss_naclEdit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "MgCl2") {
+                ui->ss_mgcl2Edit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "Melkzuur" || product->miscs.at(i).name == "Lactic") {
+                ui->sp_acidvolEdit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "Zoutzuur" || product->miscs.at(i).name == "Hydrochloric") {
+                ui->sp_acidvolEdit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "Fosforzuur" || product->miscs.at(i).name == "Phosphoric") {
+                ui->sp_acidvolEdit->setValue(product->miscs.at(i).amount * 1000.0);
+            } else if (product->miscs.at(i).name == "Zwavelzuur" || product->miscs.at(i).name == "Sulfuric") {
+                ui->sp_acidvolEdit->setValue(product->miscs.at(i).amount * 1000.0);
+            }
         }
     }
 }
--- a/src/EditProductTab8.cpp	Sun Jul 17 22:18:48 2022 +0200
+++ b/src/EditProductTab8.cpp	Mon Jul 18 17:04:02 2022 +0200
@@ -161,7 +161,7 @@
     qDebug() << "calcWater()";
 
     ui->w1_hardnessEdit->setValue(Utils::Hardness(product->w1_calcium, product->w1_magnesium));
-    ui->w1_raEdit->setValue(Utils::RA_ppm(product->w1_total_alkalinity, product->w1_calcium, product->w1_magnesium));
+    ui->w1_raEdit->setValue(Utils::ResidualAlkalinity(product->w1_total_alkalinity, product->w1_calcium, product->w1_magnesium));
 
     /*
      * If there is a dilute water source, mix the waters.
@@ -176,7 +176,7 @@
 	total_alkalinity = Utils::mix(product->w1_amount, product->w2_amount, product->w1_total_alkalinity, product->w2_total_alkalinity);
 	ph = -log10(((pow(10, -product->w1_ph) * product->w1_amount) + (pow(10, -product->w2_ph) * product->w2_amount)) / liters);
 	ui->w2_hardnessEdit->setValue(Utils::Hardness(product->w2_calcium, product->w2_magnesium));
-    	ui->w2_raEdit->setValue(Utils::RA_ppm(product->w2_total_alkalinity, product->w2_calcium, product->w2_magnesium));
+    	ui->w2_raEdit->setValue(Utils::ResidualAlkalinity(product->w2_total_alkalinity, product->w2_calcium, product->w2_magnesium));
     } else {
 	liters = product->w1_amount;
 	calcium = product->w1_calcium;
@@ -197,18 +197,18 @@
     product->wg_total_alkalinity = round(total_alkalinity * 10.0) / 10.0;
     product->wg_ph = ph;
 
+    bicarbonate = Utils::Bicarbonate(total_alkalinity, ph);
     ui->wg_volEdit->setValue(liters);
     ui->wg_caEdit->setValue(calcium);
     ui->wg_mgEdit->setValue(magnesium);
-    ui->wg_hco3Edit->setValue(total_alkalinity * 1.22);
+    ui->wg_hco3Edit->setValue(bicarbonate);
     ui->wg_caco3Edit->setValue(total_alkalinity);
     ui->wg_naEdit->setValue(sodium);
     ui->wg_clEdit->setValue(chloride);
     ui->wg_so4Edit->setValue(sulfate);
     ui->wg_phEdit->setValue(ph);
     ui->wg_hardnessEdit->setValue(Utils::Hardness(calcium, magnesium));
-    ui->wg_raEdit->setValue(Utils::RA_ppm(total_alkalinity, calcium, magnesium));
-    bicarbonate = total_alkalinity * 1.22;
+    ui->wg_raEdit->setValue(Utils::ResidualAlkalinity(total_alkalinity, calcium, magnesium));
 
     /* Save mixed water ions for later */
     double wg_calcium = calcium;
@@ -265,10 +265,17 @@
 	    Acidmg = Acid;
 	    Acid = Acid / my_acids[AT].AcidSG;
 	    Acid = round((Acid / (product->wa_acid_perc / 100.0)) * 100.0) / 100.0;
+	    qDebug() << "  Mash auto Acid final old ml:" << Acid;
+	    Acid = Acidmg;
+
+	    double RealSG = round(((my_acids[AT].AcidSG - 1000) * (product->wa_acid_perc / 100)) + 1000);
+	    Acid /= RealSG;
+	    Acid /= my_acids[AT].AcidPrc / 100;
+	    Acid = round(Acid * 100.0) / 100.0;
 	    qDebug() << "  Mash auto Acid final ml:" << Acid;
 
 	    QString w = my_acids[AT].name_en + ' ' + my_acids[AT].name_nl;
-	    brewing_salt_sub(w, Acid);
+	    brewing_salt_sub(w, Acid, MISC_USES_MASH);
 	    ui->mw_acidvolEdit->setValue(Acid);
 
 	    bicarbonate = bicarbonate - protonDeficit * frac / liters;
@@ -282,17 +289,19 @@
 	 * Manual adjust acid, calculate resulting pH.
 	 */
 	double pHa = ph;	// Mixed water pH.
+	double RealSG = round(((my_acids[AT].AcidSG - 1000) * (product->wa_acid_perc / 100)) + 1000);
 	// Then calculate the new pH with added acids and malts
 	qDebug() << "  Mash pH:" << pHa;
-	Acid = my_acids[AT].AcidSG * (product->wa_acid_perc / 100.0);	// ml
+	Acid = RealSG;
 	Acid *= ui->mw_acidvolEdit->value();
+	Acid *= my_acids[AT].AcidPrc / 100;
 	Acid /= my_acids[AT].MolWt;	// mg;
 	Acidmg = Acid;
 
 	//find the pH where the protondeficit = protondeficit by the acid
 	frac = Utils::CalcFrac(pHa, my_acids[AT].pK1, my_acids[AT].pK2, my_acids[AT].pK3);
 	protonDeficit = Acid * frac;
-	//qDebug() << "  protonDeficit Acid:" << protonDeficit << "frac:" << frac << "pH:" << pHa;
+	qDebug() << "  Acid:" << Acid << "protonDeficit:" << protonDeficit << "frac:" << frac << "pH:" << pHa;
 
 	double deltapH = 0.001;
    	double deltapd = 0.1;
@@ -308,7 +317,7 @@
 	    protonDeficit = Acid * frac;
 	    pd = ProtonDeficit(pHa);
 	}
-	//qDebug() << "  n:" << n << "pd:" << pd << "protonDeficit:" << protonDeficit << "frac:" << frac << "pHa:" << pHa;
+	qDebug() << "  n:" << n << "pd:" << pd << "protonDeficit:" << protonDeficit << "frac:" << frac << "pHa:" << pHa;
 
 	bicarbonate = wg_bicarbonate - protonDeficit * frac / liters;
 	total_alkalinity = bicarbonate * 50 / 61;
@@ -383,7 +392,7 @@
     ui->wb_clEdit->setValue(chloride);
     ui->wb_so4Edit->setValue(sulfate);
     ui->wb_hardnessEdit->setValue(Utils::Hardness(calcium, magnesium));
-    ui->wb_raEdit->setValue(Utils::RA_ppm(total_alkalinity, calcium, magnesium));
+    ui->wb_raEdit->setValue(Utils::ResidualAlkalinity(total_alkalinity, calcium, magnesium));
 
     ui->wb_caEdit->setStyleSheet((calcium < 40 || calcium > 150) ? "background-color: red":"background-color: green");
     ui->wb_mgEdit->setStyleSheet((magnesium < 5 || magnesium > 40) ? "background-color: red":"background-color: green");
@@ -420,80 +429,130 @@
 
     qDebug() << "calcSparge()";
 
-    const QSignalBlocker blocker1(ui->sp_sourceEdit);
+    const QSignalBlocker blocker2(ui->w1_spButton);
+    const QSignalBlocker blocker3(ui->w2_spButton);
+    const QSignalBlocker blocker4(ui->wg_spButton);
 
     // Select watersource or fallback to the first source.
     if (product->sparge_source == 1) { // Source 2
 	if (product->w2_ph > 0.0 && product->w2_amount > 0) {
 	    Source_pH = product->w2_ph;
 	    Source_alkalinity = product->w2_total_alkalinity;
+	    ui->sp_caEdit->setValue(product->w2_calcium);
+            ui->sp_mgEdit->setValue(product->w2_magnesium);
+            ui->sp_hco3Edit->setValue(Utils::Bicarbonate(product->w2_total_alkalinity, product->w2_ph));
+            ui->sp_caco3Edit->setValue(product->w2_total_alkalinity);
+            ui->sp_naEdit->setValue(product->w2_sodium);
+            ui->sp_clEdit->setValue(product->w2_chloride);
+            ui->sp_so4Edit->setValue(product->w2_sulfate);
+            ui->sp_phShow->setValue(product->w2_ph);
+            ui->sp_hardnessEdit->setValue(Utils::Hardness(product->w2_calcium, product->w2_magnesium));
+            ui->sp_raEdit->setValue(Utils::ResidualAlkalinity(product->w2_total_alkalinity, product->w2_calcium, product->w2_magnesium));
+	    ui->w2_spButton->setChecked(true);
 	} else {
-	    product->sparge_source = 0; // Source 1
-	    ui->sp_sourceEdit->setCurrentIndex(0);
+	    product->sparge_source = 0; // Fallback to source 1
+	    ui->w1_spButton->setChecked(true);
 	}
     } else if (product->sparge_source == 2) { // Mixed
 	if (product->w2_ph > 0.0 && product->w2_amount > 0) {
 	    Source_pH = product->wg_ph;
 	    Source_alkalinity = product->wg_total_alkalinity;
+	    ui->sp_caEdit->setValue(product->wg_calcium);
+	    ui->sp_mgEdit->setValue(product->wg_magnesium);
+	    ui->sp_hco3Edit->setValue(Utils::Bicarbonate(product->wg_total_alkalinity, product->wg_ph));
+	    ui->sp_caco3Edit->setValue(product->wg_total_alkalinity);
+	    ui->sp_naEdit->setValue(product->wg_sodium);
+	    ui->sp_clEdit->setValue(product->wg_chloride);
+	    ui->sp_so4Edit->setValue(product->wg_sulfate);
+	    ui->sp_phShow->setValue(product->wg_ph);
+	    ui->sp_hardnessEdit->setValue(Utils::Hardness(product->wg_calcium, product->wg_magnesium));
+	    ui->sp_raEdit->setValue(Utils::ResidualAlkalinity(product->wg_total_alkalinity, product->wg_calcium, product->wg_magnesium));
+	    ui->wg_spButton->setChecked(true);
 	} else {
-	    product->sparge_source = 0; // Source 1
-            ui->sp_sourceEdit->setCurrentIndex(0);
+	    product->sparge_source = 0; // Fallback to source 1
+	    ui->w1_spButton->setChecked(true);
 	}
     }
+    if (product->sparge_source == 0) {
+	ui->sp_caEdit->setValue(product->w1_calcium);
+	ui->sp_mgEdit->setValue(product->w1_magnesium);
+	ui->sp_hco3Edit->setValue(Utils::Bicarbonate(product->w1_total_alkalinity, product->w1_ph));
+	ui->sp_caco3Edit->setValue(product->w1_total_alkalinity);
+	ui->sp_naEdit->setValue(product->w1_sodium);
+	ui->sp_clEdit->setValue(product->w1_chloride);
+	ui->sp_so4Edit->setValue(product->w1_sulfate);
+	ui->sp_phShow->setValue(product->w1_ph);
+	ui->sp_hardnessEdit->setValue(Utils::Hardness(product->w1_calcium, product->w1_magnesium));
+	ui->sp_raEdit->setValue(Utils::ResidualAlkalinity(product->w1_total_alkalinity, product->w1_calcium, product->w1_magnesium));
+	ui->w1_spButton->setChecked(true);
+    }
+    // The spargewater is set.
+
+    int AT = product->sparge_acid_type;
+    if (AT < 0 || AT >= my_acids.size()) {
+        AT = 0;
+        product->sparge_acid_type = 0;
+        ui->sp_acidtypeEdit->setCurrentIndex(0);
+        product->sparge_acid_perc = my_acids[0].AcidPrc;
+        ui->sp_acidpercEdit->setValue(product->sparge_acid_perc);
+    }
 
-    // Step 1: Compute the mole fractions of carbonic (f1o), bicarbonate (f2o) and carbonate(f3o) at the water pH
-    double r1 = pow(10, Source_pH - 6.35);
-    double r2 = pow(10, Source_pH - 10.33);
-    double d = 1 + r1 + r1 * r2;
-    double f1 = 1 / d;
-    double f3 = r1 * r2 / d;
+    /*
+     * Auto calculate the required acid
+     */
+    if (product->calc_acid) {
+    	// Step 1: Compute the mole fractions of carbonic (f1o), bicarbonate (f2o) and carbonate(f3o) at the water pH
+    	double r1 = pow(10, Source_pH - 6.35);
+    	double r2 = pow(10, Source_pH - 10.33);
+    	double d = 1 + r1 + r1 * r2;
+    	double f1 = 1 / d;
+    	double f3 = r1 * r2 / d;
 
-    // Step 2. Compute the mole fractions at pH = 4.3 (the pH which defines alkalinity)
-    double r143 = pow(10, 4.3 - 6.35);
-    double r243 = pow(10, 4.3 - 10.33);
-    double d43 = 1 + r143 + r143 * r243;
-    double f143 = 1 / d43;
-    double f343 = r143 * r243 / d43;
+    	// Step 2. Compute the mole fractions at pH = 4.3 (the pH which defines alkalinity)
+    	double r143 = pow(10, 4.3 - 6.35);
+    	double r243 = pow(10, 4.3 - 10.33);
+    	double d43 = 1 + r143 + r143 * r243;
+    	double f143 = 1 / d43;
+    	double f343 = r143 * r243 / d43;
 
-    // Step 4. Solve
-    //double Ct = (Source_alkalinity - 1000 * (pow(10, -4.3) - pow(10, -Source_pH))) / ((f143 - f1) + (f3 - f343));
-    double Ct = Source_alkalinity / 50 / ((f143 - f1) + (f3 - f343));
+    	// Step 4. Solve
+    	double Ct = Source_alkalinity / 50 / ((f143 - f1) + (f3 - f343));
 
-    // Step 5. Compute mole fractions at desired pH
-    double r1g = pow(10, TargetpH - 6.35);
-    double r2g = pow(10, TargetpH - 10.33);
-    double dg = 1 + r1g + r1g * r2g;
-    double f1g = 1 / dg;
-    double f3g = r1g * r2g / dg;
+    	// Step 5. Compute mole fractions at desired pH
+    	double r1g = pow(10, TargetpH - 6.35);
+    	double r2g = pow(10, TargetpH - 10.33);
+    	double dg = 1 + r1g + r1g * r2g;
+    	double f1g = 1 / dg;
+    	double f3g = r1g * r2g / dg;
 
-    // Step 6. Use these to compute the milliequivalents acid required per liter (mEq/L)
-    double Acid = Ct * ((f1g - f1) + (f3 - f3g)) + pow(10, -TargetpH) - pow(10, -Source_pH);  //mEq/l
-    Acid += 0.01;   // Add acid that would be required for distilled water.
+    	// Step 6. Use these to compute the milliequivalents acid required per liter (mEq/L)
+    	double Acid = Ct * ((f1g - f1) + (f3 - f3g)) + pow(10, -TargetpH) - pow(10, -Source_pH);  //mEq/l
+    	Acid += 0.01;   // Add acid that would be required for distilled water.
+
+    	// Step 7. There is no step 7.
+
+    	// Step 8. Get the acid data.
+    	double fract = Utils::CalcFrac(TargetpH, my_acids[AT].pK1, my_acids[AT].pK2, my_acids[AT].pK3);
+
+    	// Step 9. Now divide the mEq required by the "fraction". This is the required number of moles of acid.
+    	Acid /= fract;
 
-    //Step 8. Get the acid data.
-    int AT = product->sparge_acid_type;
-    if (AT < 0 || AT >= my_acids.size()) {
-	AT = 0;
-	product->sparge_acid_type = 0;
-	ui->sp_acidtypeEdit->setCurrentIndex(0);
-	product->sparge_acid_perc = my_acids[0].AcidPrc;
-	ui->sp_acidpercEdit->setValue(product->sparge_acid_perc);
+    	// Step 10. Multiply by molecular weight of the acid
+    	Acid *= my_acids[AT].MolWt; //mg
+
+    	// Step 11. Divide by Specific Gravity and Percentage to get the final ml.
+    	double RealSG = round(((my_acids[AT].AcidSG - 1000) * (product->sparge_acid_perc / 100)) + 1000);
+    	Acid = Acid / RealSG;		//ml
+    	Acid *= product->sparge_volume;	//ml acid total at 100%
+    	Acid /= my_acids[AT].AcidPrc / 100;	//ml acid at supplied strength
+    	Acid = round(Acid * 100.0) / 100.0;
+    	product->sparge_acid_amount = Acid / 1000;
+    	QString w = my_acids[AT].name_en + ' ' + my_acids[AT].name_nl;
+    	brewing_salt_sub(w, Acid, MISC_USES_SPARGE);	// Put it in the miscs table.
+    	ui->sp_acidvolEdit->setValue(Acid);
     }
-    double fract = Utils::CalcFrac(TargetpH, my_acids[AT].pK1, my_acids[AT].pK2, my_acids[AT].pK3);
 
-    // Step 9. Now divide the mEq required by the "fraction". This is the required number of moles of acid.
-    Acid /= fract;
-
-    // Step 10. Multiply by molecular weight of the acid
-    Acid *= my_acids[AT].MolWt; //mg
-
-    // Step 11. Divide by Specific Gravity and Percentage to get the final ml.
-    Acid = Acid / my_acids[AT].AcidSG / (product->sparge_acid_perc / 100); //ml
-    Acid *= product->sparge_volume; //ml acid total
-    Acid = round(Acid * 100.0) / 100.0;
-    product->sparge_acid_amount = Acid / 1000;
-    ui->sp_acidvolEdit->setValue(Acid);
-
+    ui->sp_phShow->setValue(product->sparge_ph);
     // Finally calculate the estimate preboil pH
     product->est_preboil_ph = -log10(((pow(10, -product->mash_ph) * product->wg_amount) + (pow(10, -product->sparge_ph) * product->brew_sparge_est)) /
 		     	      (product->wg_amount + product->brew_sparge_est));
@@ -502,11 +561,13 @@
 }
 
 
-void EditProduct::sp_source_changed(int val)
+void EditProduct::sp_group_changed(int val)
 {
-    product->sparge_source = val;
-    calcSparge();
-    is_changed();
+    if (val != product->sparge_source) {
+	product->sparge_source = val;
+    	calcSparge();
+    	is_changed();
+    }
 }
 
 
@@ -522,7 +583,6 @@
 void EditProduct::sp_temp_changed(double val)
 {
     product->sparge_temp = val;
-    ui->brew_spargetempShow->setValue(val);
     calcSparge();
     is_changed();
 }
@@ -530,9 +590,23 @@
 
 void EditProduct::sp_type_changed(int val)
 {
+    if (val == product->sparge_acid_type)
+        return;
+
+    qDebug() << "sp_type_changed" << val << "old" << product->sparge_acid_type;
+    /*
+     * First remove current acid.
+     */
+    QString w = my_acids[product->sparge_acid_type].name_en + ' ' + my_acids[product->sparge_acid_type].name_nl;
+    brewing_salt_sub(w, 0, MISC_USES_SPARGE);
+
     product->sparge_acid_type = val;
+    w = my_acids[product->sparge_acid_type].name_en + ' ' + my_acids[product->sparge_acid_type].name_nl;
+
     product->sparge_acid_perc = my_acids[val].AcidPrc;
     ui->sp_acidpercEdit->setValue(product->sparge_acid_perc);
+    brewing_salt_sub(w, ui->sp_acidvolEdit->value(), MISC_USES_SPARGE);	// For now, set old amount.
+
     calcSparge();
     is_changed();
 }
@@ -547,6 +621,116 @@
 }
 
 
+void EditProduct::sp_acid_changed(double val)
+{
+    if (product->calc_acid)
+        return;
+
+    qDebug() << "sp_acid_changed" << val << product->sparge_acid_amount * 1000.0;
+
+    double TargetpH = product->sparge_ph;
+    double Source_pH = product->w1_ph;
+    double Source_alkalinity = product->w1_total_alkalinity;
+
+    if (product->sparge_source == 1) { // Source 2
+	if (product->w2_ph > 0.0 && product->w2_amount > 0) {
+	    Source_pH = product->w2_ph;
+            Source_alkalinity = product->w2_total_alkalinity;
+	}
+    } else if (product->sparge_source == 2) { // Mixed
+	if (product->w2_ph > 0.0 && product->w2_amount > 0) {
+	    Source_pH = product->wg_ph;
+            Source_alkalinity = product->wg_total_alkalinity;
+	}
+    }
+
+    int AT = product->sparge_acid_type;
+    if (AT < 0 || AT >= my_acids.size()) {
+        AT = 0;
+        product->sparge_acid_type = 0;
+        ui->sp_acidtypeEdit->setCurrentIndex(0);
+        product->sparge_acid_perc = my_acids[0].AcidPrc;
+        ui->sp_acidpercEdit->setValue(product->sparge_acid_perc);
+    }
+
+    bool go_up = (val < (product->sparge_acid_amount * 1000.0));
+    bool loop = true;
+
+    while (loop) {
+
+	if (go_up)
+	    TargetpH += 0.001;
+	else
+	    TargetpH -= 0.001;
+	//qDebug() << "  TargetpH" << TargetpH << "up" << go_up;
+
+        // Step 1: Compute the mole fractions of carbonic (f1o), bicarbonate (f2o) and carbonate(f3o) at the water pH
+        double r1 = pow(10, Source_pH - 6.35);
+        double r2 = pow(10, Source_pH - 10.33);
+        double d = 1 + r1 + r1 * r2;
+        double f1 = 1 / d;
+        double f3 = r1 * r2 / d;
+
+        // Step 2. Compute the mole fractions at pH = 4.3 (the pH which defines alkalinity)
+        double r143 = pow(10, 4.3 - 6.35);
+        double r243 = pow(10, 4.3 - 10.33);
+        double d43 = 1 + r143 + r143 * r243;
+        double f143 = 1 / d43;
+        double f343 = r143 * r243 / d43;
+
+        // Step 4. Solve
+        double Ct = Source_alkalinity / 50 / ((f143 - f1) + (f3 - f343));
+
+        // Step 5. Compute mole fractions at desired pH
+        double r1g = pow(10, TargetpH - 6.35);
+        double r2g = pow(10, TargetpH - 10.33);
+        double dg = 1 + r1g + r1g * r2g;
+        double f1g = 1 / dg;
+        double f3g = r1g * r2g / dg;
+
+        // Step 6. Use these to compute the milliequivalents acid required per liter (mEq/L)
+        double Acid = Ct * ((f1g - f1) + (f3 - f3g)) + pow(10, -TargetpH) - pow(10, -Source_pH);  //mEq/l
+        Acid += 0.01;   // Add acid that would be required for distilled water.
+
+        // Step 7. There is no step 7.
+
+        // Step 8. Get the acid data.
+        double fract = Utils::CalcFrac(TargetpH, my_acids[AT].pK1, my_acids[AT].pK2, my_acids[AT].pK3);
+
+        // Step 9. Now divide the mEq required by the "fraction". This is the required number of moles of acid.
+        Acid /= fract;
+
+        // Step 10. Multiply by molecular weight of the acid
+        Acid *= my_acids[AT].MolWt; //mg
+
+        // Step 11. Divide by Specific Gravity and Percentage to get the final ml.
+        double RealSG = round(((my_acids[AT].AcidSG - 1000) * (product->sparge_acid_perc / 100)) + 1000);
+        Acid = Acid / RealSG;           //ml
+        Acid *= product->sparge_volume; //ml acid total at 100%
+        Acid /= my_acids[AT].AcidPrc / 100;     //ml acid at supplied strength
+        Acid = round(Acid * 100.0) / 100.0;
+        product->sparge_acid_amount = Acid / 1000;
+	//qDebug() << "  acid" << product->sparge_acid_amount;
+
+	if (go_up && (val > (product->sparge_acid_amount * 1000.0)))
+	    loop = false;
+	else if (! go_up && (val < (product->sparge_acid_amount * 1000.0)))
+	    loop = false;
+
+	//qDebug() << "  test" << loop << go_up << val << product->sparge_acid_amount * 1000.0;
+    }
+
+    const QSignalBlocker blocker1(ui->sp_phEdit);
+    product->sparge_ph = round(TargetpH * 100) / 100;
+    ui->sp_phEdit->setValue(product->sparge_ph);
+    ui->sp_phShow->setValue(product->sparge_ph);
+
+    QString w = my_acids[AT].name_en + ' ' + my_acids[AT].name_nl;
+    set_brewing_salt(w, val, MISC_USES_SPARGE);
+    //qDebug() << "  new" << product->sparge_ph << val;
+}
+
+
 double EditProduct::GetBUGU()
 {
     double gu = (product->est_og - 1) * 1000;
@@ -575,6 +759,10 @@
     ui->mw_phEdit->setButtonSymbols(product->calc_acid ? QAbstractSpinBox::UpDownArrows : QAbstractSpinBox::NoButtons);
     ui->mw_acidvolEdit->setReadOnly(product->calc_acid);
     ui->mw_acidvolEdit->setButtonSymbols(product->calc_acid ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
+    ui->sp_phEdit->setReadOnly(! product->calc_acid);
+    ui->sp_phEdit->setButtonSymbols(product->calc_acid ? QAbstractSpinBox::UpDownArrows : QAbstractSpinBox::NoButtons);
+    ui->sp_acidvolEdit->setReadOnly(product->calc_acid);
+    ui->sp_acidvolEdit->setButtonSymbols(product->calc_acid ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     is_changed();
     calcWater();
 }
@@ -601,7 +789,7 @@
 
     qDebug() << "on_mw_acid_changed" << val;
     QString w = my_acids[product->wa_acid_name].name_en + ' ' + my_acids[product->wa_acid_name].name_nl;
-    set_brewing_salt(w, val);
+    set_brewing_salt(w, val, MISC_USES_MASH);
 }
 
 
@@ -615,14 +803,14 @@
      * First remove current acid.
      */
     QString w = my_acids[product->wa_acid_name].name_en + ' ' + my_acids[product->wa_acid_name].name_nl;
-    brewing_salt_sub(w, 0);
+    brewing_salt_sub(w, 0, MISC_USES_MASH);
 
     product->wa_acid_name = val;
     w = my_acids[product->wa_acid_name].name_en + ' ' + my_acids[product->wa_acid_name].name_nl;
 
     product->wa_acid_perc = my_acids.at(val).AcidPrc;
     ui->mw_acidpercEdit->setValue(my_acids.at(val).AcidPrc);
-    brewing_salt_sub(w, ui->mw_acidvolEdit->value());   // For now, set old amount.
+    brewing_salt_sub(w, ui->mw_acidvolEdit->value(), MISC_USES_MASH);   // For now, set old amount.
 
     is_changed();
     calcWater();
@@ -684,7 +872,16 @@
                 product->waters_ok = false;
                 qDebug() << "w2_amount too low";
             }
+	    ui->w2_spButton->setEnabled(true);
+            ui->wg_spButton->setEnabled(true);
         }
+    } else {
+	/*
+	 * Block selecting sparge water 2 and mixed water.
+	 */
+	ui->w2_spButton->setEnabled(false);
+	ui->wg_spButton->setEnabled(false);
+	product->sparge_source = 0;      // Only water source 1
     }
 }
 
@@ -722,14 +919,14 @@
 
     ui->w1_caEdit->setValue(product->w1_calcium);
     ui->w1_mgEdit->setValue(product->w1_magnesium);
-    ui->w1_hco3Edit->setValue(product->w1_total_alkalinity * 1.22);
+    ui->w1_hco3Edit->setValue(Utils::Bicarbonate(product->w1_total_alkalinity, product->w1_ph));
     ui->w1_caco3Edit->setValue(product->w1_total_alkalinity);
     ui->w1_naEdit->setValue(product->w1_sodium);
     ui->w1_clEdit->setValue(product->w1_chloride);
     ui->w1_so4Edit->setValue(product->w1_sulfate);
     ui->w1_phEdit->setValue(product->w1_ph);
     ui->w1_hardnessEdit->setValue(Utils::Hardness(product->w1_calcium, product->w1_magnesium));
-    ui->w1_raEdit->setValue(Utils::RA_ppm(product->w1_total_alkalinity, product->w1_calcium, product->w1_magnesium));
+    ui->w1_raEdit->setValue(Utils::ResidualAlkalinity(product->w1_total_alkalinity, product->w1_calcium, product->w1_magnesium));
 
     check_waters();
     is_changed();
@@ -774,13 +971,13 @@
         product->w2_sulfate = query.value(5).toDouble();
         product->w2_ph = query.value(9).toDouble();
 	hardness = Utils::Hardness(product->w2_calcium, product->w2_magnesium);
-	ra_ppm = Utils::RA_ppm(product->w2_total_alkalinity, product->w2_calcium, product->w2_magnesium);
+	ra_ppm = Utils::ResidualAlkalinity(product->w2_total_alkalinity, product->w2_calcium, product->w2_magnesium);
     }
     ui->w1_volEdit->setValue(product->w1_amount);
     ui->w2_volEdit->setValue(product->w2_amount);
     ui->w2_caEdit->setValue(product->w2_calcium);
     ui->w2_mgEdit->setValue(product->w2_magnesium);
-    ui->w2_hco3Edit->setValue(product->w2_total_alkalinity * 1.22);
+    ui->w2_hco3Edit->setValue(Utils::Bicarbonate(product->w2_total_alkalinity, product->w2_ph));
     ui->w2_caco3Edit->setValue(product->w2_total_alkalinity);
     ui->w2_naEdit->setValue(product->w2_sodium);
     ui->w2_clEdit->setValue(product->w2_chloride);
@@ -825,7 +1022,7 @@
         ui->wt_clEdit->setValue(query.value("chloride").toDouble());
         ui->wt_so4Edit->setValue(query.value("sulfate").toDouble());
 	ui->wt_hardnessEdit->setValue(Utils::Hardness(query.value("calcium").toDouble(), query.value("magnesium").toDouble()));
-    	ui->wt_raEdit->setValue(Utils::RA_ppm(query.value("total_alkalinity").toDouble(), query.value("calcium").toDouble(), query.value("magnesium").toDouble()));
+    	ui->wt_raEdit->setValue(Utils::ResidualAlkalinity(query.value("total_alkalinity").toDouble(), query.value("calcium").toDouble(), query.value("magnesium").toDouble()));
     }
     calcWater();
 }
@@ -868,12 +1065,16 @@
 }
 
 
-void EditProduct::wb_cacl2_changed(double val)  { set_brewing_salt("CaCl2", val);  }
-void EditProduct::wb_caso4_changed(double val)  { set_brewing_salt("CaSO4", val);  }
-void EditProduct::wb_mgso4_changed(double val)  { set_brewing_salt("MgSO4", val);  }
-void EditProduct::wb_nacl_changed(double val)   { set_brewing_salt("NaCl", val);   }
-void EditProduct::wb_mgcl2_changed(double val)  { set_brewing_salt("MgCl2", val);  }
-void EditProduct::wb_nahco3_changed(double val) { set_brewing_salt("NaHCO3", val); }
-void EditProduct::wb_caco3_changed(double val)  { set_brewing_salt("CaCO3", val);  }
+void EditProduct::wb_cacl2_changed(double val)  { set_brewing_salt("CaCl2", val, MISC_USES_MASH);   }
+void EditProduct::wb_caso4_changed(double val)  { set_brewing_salt("CaSO4", val, MISC_USES_MASH);   }
+void EditProduct::wb_mgso4_changed(double val)  { set_brewing_salt("MgSO4", val, MISC_USES_MASH);   }
+void EditProduct::wb_nacl_changed(double val)   { set_brewing_salt("NaCl", val, MISC_USES_MASH);    }
+void EditProduct::wb_mgcl2_changed(double val)  { set_brewing_salt("MgCl2", val, MISC_USES_MASH);   }
+void EditProduct::wb_nahco3_changed(double val) { set_brewing_salt("NaHCO3", val, MISC_USES_MASH);  }
+void EditProduct::wb_caco3_changed(double val)  { set_brewing_salt("CaCO3", val, MISC_USES_MASH);   }
+void EditProduct::sp_cacl2_changed(double val)  { set_brewing_salt("CaCl2", val, MISC_USES_SPARGE); }
+void EditProduct::sp_caso4_changed(double val)  { set_brewing_salt("CaSO4", val, MISC_USES_SPARGE); }
+void EditProduct::sp_mgso4_changed(double val)  { set_brewing_salt("MgSO4", val, MISC_USES_SPARGE); }
+void EditProduct::sp_nacl_changed(double val)   { set_brewing_salt("NaCl", val, MISC_USES_SPARGE);  }
+void EditProduct::sp_mgcl2_changed(double val)  { set_brewing_salt("MgCl2", val, MISC_USES_SPARGE); }
 
-
--- a/src/EditRecipe.cpp	Sun Jul 17 22:18:48 2022 +0200
+++ b/src/EditRecipe.cpp	Mon Jul 18 17:04:02 2022 +0200
@@ -56,10 +56,6 @@
 	ui->sp_acidtypeEdit->addItem(my_acids.at(i).name_en);
     }
 
-    ui->sp_sourceEdit->addItem(tr("Source 1"));
-    ui->sp_sourceEdit->addItem(tr("Source 2"));
-    ui->sp_sourceEdit->addItem(tr("Mixed"));
-
     query.prepare("SELECT name FROM inventory_waters ORDER BY record");
     query.exec();
     query.first();
@@ -94,6 +90,10 @@
 	query.next();
     }
 
+    ui->spargeGroup->setId(ui->w1_spButton, 0);
+    ui->spargeGroup->setId(ui->w2_spButton, 1);
+    ui->spargeGroup->setId(ui->wg_spButton, 2);
+
     if (id >= 0) {
 	if (! DB_recipe::load(recipe, this, id))
             return;
@@ -333,10 +333,12 @@
     ui->mw_acidvolEdit->setReadOnly(recipe->calc_acid);
     ui->mw_acidvolEdit->setButtonSymbols(recipe->calc_acid ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
 
+    ui->sp_phEdit->setReadOnly(! recipe->calc_acid);
+    ui->sp_phEdit->setButtonSymbols(recipe->calc_acid ? QAbstractSpinBox::UpDownArrows : QAbstractSpinBox::NoButtons);
+    ui->sp_acidvolEdit->setReadOnly(recipe->calc_acid);
+    ui->sp_acidvolEdit->setButtonSymbols(recipe->calc_acid ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     ui->sp_volEdit->setValue(recipe->sparge_volume);
-    ui->sp_tempEdit->setValue(recipe->sparge_temp);
     ui->sp_phEdit->setValue(recipe->sparge_ph);
-    ui->sp_sourceEdit->setCurrentIndex(recipe->sparge_source);
     ui->sp_acidtypeEdit->setCurrentIndex(recipe->sparge_acid_type);
     ui->sp_acidpercEdit->setValue(recipe->sparge_acid_perc);
     ui->sp_acidvolEdit->setValue(recipe->sparge_acid_amount);
@@ -392,6 +394,11 @@
     connect(ui->bs_mgcl2Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::wb_mgcl2_changed);
     connect(ui->bs_nahco3Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::wb_nahco3_changed);
     connect(ui->bs_caco3Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::wb_caco3_changed);
+    connect(ui->ss_cacl2Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::sp_cacl2_changed);
+    connect(ui->ss_caso4Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::sp_caso4_changed);
+    connect(ui->ss_mgso4Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::sp_mgso4_changed);
+    connect(ui->ss_naclEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::sp_nacl_changed);
+    connect(ui->ss_mgcl2Edit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::sp_mgcl2_changed);
     connect(ui->mw_autoEdit, &QCheckBox::stateChanged, this, &EditRecipe::mw_calc_acid_clicked);
     connect(ui->mw_phEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::mw_ph_changed);
     connect(ui->mw_acidvolEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::mw_acid_changed);
@@ -400,10 +407,10 @@
     connect(ui->w1_nameEdit, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &EditRecipe::w1_name_changed);
     connect(ui->w2_nameEdit, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &EditRecipe::w2_name_changed);
     connect(ui->w2_volEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::w2_volume_changed);
-    connect(ui->sp_sourceEdit, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &EditRecipe::sp_source_changed);
+    connect(ui->spargeGroup, SIGNAL(buttonClicked(int)), this, SLOT(sp_group_changed(int)));
     connect(ui->sp_acidtypeEdit, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &EditRecipe::sp_type_changed);
     connect(ui->sp_phEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::sp_ph_changed);
-
+    connect(ui->sp_acidvolEdit, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &EditRecipe::sp_acid_changed);
     setLocked(recipe->locked);
 
     ui->saveButton->setEnabled(false);
--- a/src/EditRecipe.h	Sun Jul 17 22:18:48 2022 +0200
+++ b/src/EditRecipe.h	Mon Jul 18 17:04:02 2022 +0200
@@ -107,14 +107,20 @@
     void wb_mgcl2_changed(double val);
     void wb_nahco3_changed(double val);
     void wb_caco3_changed(double val);
+    void sp_cacl2_changed(double val);
+    void sp_caso4_changed(double val);
+    void sp_mgso4_changed(double val);
+    void sp_nacl_changed(double val);
+    void sp_mgcl2_changed(double val);
     void mw_calc_acid_clicked();
     void wt_target_changed(int val);
     void mw_ph_changed(double val);
     void mw_acid_changed(double val);
     void mw_type_changed(int val);
-    void sp_source_changed(int val);
+    void sp_group_changed(int val);
     void sp_type_changed(int val);
     void sp_ph_changed(double val);
+    void sp_acid_changed(double val);
     void step_name_changed(QString val);
     void step_type_changed(int val);
     void step_temp_changed(double val);
@@ -158,8 +164,8 @@
     static bool yeast_sort_test(const Yeasts &D1, const Yeasts &D2);
     void WindowTitle();
     void setLocked(bool val);
-    void brewing_salt_sub(QString salt, double val);
-    void set_brewing_salt(QString salt, double val);
+    void brewing_salt_sub(QString salt, double val, int use);
+    void set_brewing_salt(QString salt, double val, int use);
     void calcFermentables();
     void calcFermentablesFromOG(double og);
     void calcIBUs();
--- a/src/EditRecipeTab1.cpp	Sun Jul 17 22:18:48 2022 +0200
+++ b/src/EditRecipeTab1.cpp	Mon Jul 18 17:04:02 2022 +0200
@@ -222,7 +222,6 @@
     ui->mash_pickEdit->setDisabled(val);
 
     /* Tab 7, water */
-    ui->sp_sourceEdit->setDisabled(val);
     ui->wt_sourceEdit->setDisabled(val);
     ui->w1_nameEdit->setDisabled(val);
     ui->w2_nameEdit->setDisabled(val);
@@ -230,10 +229,6 @@
     ui->sp_acidtypeEdit->setDisabled(val);
     ui->w2_volEdit->setReadOnly(val);
     ui->w2_volEdit->setButtonSymbols(val ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
-    ui->sp_phEdit->setReadOnly(val);
-    ui->sp_phEdit->setButtonSymbols(val ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
-    ui->sp_tempEdit->setReadOnly(val);
-    ui->sp_tempEdit->setButtonSymbols(val ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     ui->sp_volEdit->setReadOnly(val);
     ui->sp_volEdit->setButtonSymbols(val ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     ui->bs_cacl2Edit->setReadOnly(val);
@@ -255,11 +250,22 @@
 	ui->mw_phEdit->setButtonSymbols(QAbstractSpinBox::NoButtons);
 	ui->mw_acidvolEdit->setReadOnly(true);
 	ui->mw_acidvolEdit->setButtonSymbols(QAbstractSpinBox::NoButtons);
+	ui->sp_phEdit->setReadOnly(true);
+	ui->sp_phEdit->setButtonSymbols(QAbstractSpinBox::NoButtons);
+	ui->sp_acidvolEdit->setReadOnly(true);
+	ui->sp_acidvolEdit->setButtonSymbols(QAbstractSpinBox::NoButtons);
+	ui->w1_spButton->setDisabled(true);
+	ui->w2_spButton->setDisabled(true);
+	ui->wg_spButton->setDisabled(true);
     } else {
     	ui->mw_phEdit->setReadOnly(! recipe->calc_acid);
     	ui->mw_phEdit->setButtonSymbols(recipe->calc_acid ? QAbstractSpinBox::UpDownArrows : QAbstractSpinBox::NoButtons);
     	ui->mw_acidvolEdit->setReadOnly(recipe->calc_acid);
     	ui->mw_acidvolEdit->setButtonSymbols(recipe->calc_acid ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
+	ui->sp_phEdit->setReadOnly(! recipe->calc_acid);
+	ui->sp_phEdit->setButtonSymbols(recipe->calc_acid ? QAbstractSpinBox::UpDownArrows : QAbstractSpinBox::NoButtons);
+	ui->sp_acidvolEdit->setReadOnly(recipe->calc_acid);
+	ui->sp_acidvolEdit->setButtonSymbols(recipe->calc_acid ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     }
     ui->mw_autoEdit->setDisabled(val);
 }
--- a/src/EditRecipeTab4.cpp	Sun Jul 17 22:18:48 2022 +0200
+++ b/src/EditRecipeTab4.cpp	Mon Jul 18 17:04:02 2022 +0200
@@ -51,6 +51,13 @@
     const QSignalBlocker blocker7(ui->bs_caco3Edit);
     const QSignalBlocker blocker8(ui->mw_acidPick);
     const QSignalBlocker blocker9(ui->mw_acidvolEdit);
+    const QSignalBlocker blocker10(ui->ss_cacl2Edit);
+    const QSignalBlocker blocker11(ui->ss_caso4Edit);
+    const QSignalBlocker blocker12(ui->ss_mgso4Edit);
+    const QSignalBlocker blocker13(ui->ss_naclEdit);
+    const QSignalBlocker blocker14(ui->ss_mgcl2Edit);
+    const QSignalBlocker blocker15(ui->sp_acidtypeEdit);
+    const QSignalBlocker blocker16(ui->sp_acidvolEdit);
 
     const QStringList labels({tr("Ingredient"), tr("Type"), tr("Use at"), tr("Time"), tr("Amount"), tr("Delete"), tr("Edit") });
 
@@ -141,7 +148,7 @@
 	/*
 	 * Update the water agents.
 	 */
-	if (recipe->miscs.at(i).type == MISC_TYPES_WATER_AGENT) {
+	if (recipe->miscs.at(i).type == MISC_TYPES_WATER_AGENT && recipe->miscs.at(i).use_use == MISC_USES_MASH) {
 	    if (recipe->miscs.at(i).name == "CaCl2") {
 		ui->bs_cacl2Edit->setValue(recipe->miscs.at(i).amount * 1000.0);
 	    } else if (recipe->miscs.at(i).name == "CaSO4") {
@@ -181,6 +188,42 @@
                 ui->mw_acidpercEdit->setValue(my_acids.at(3).AcidPrc);
                 ui->mw_acidvolEdit->setValue(recipe->miscs.at(i).amount * 1000.0);
 	    }
+	} else if (recipe->miscs.at(i).type == MISC_TYPES_WATER_AGENT && recipe->miscs.at(i).use_use == MISC_USES_SPARGE) {
+            if (recipe->miscs.at(i).name == "CaCl2") {
+                ui->ss_cacl2Edit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "CaSO4") {
+                ui->ss_caso4Edit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "MgSO4") {
+                ui->ss_mgso4Edit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "NaCl") {
+                ui->ss_naclEdit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "MgCl2") {
+                ui->ss_mgcl2Edit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "Melkzuur" || recipe->miscs.at(i).name == "Lactic") {
+                recipe->sparge_acid_type = 0;
+                recipe->sparge_acid_perc = my_acids.at(0).AcidPrc;
+                ui->sp_acidtypeEdit->setCurrentIndex(0);
+                ui->sp_acidpercEdit->setValue(my_acids.at(0).AcidPrc);
+                ui->sp_acidvolEdit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "Zoutzuur" || recipe->miscs.at(i).name == "Hydrochloric") {
+                recipe->sparge_acid_type = 1;
+                recipe->sparge_acid_perc = my_acids.at(1).AcidPrc;
+                ui->sp_acidtypeEdit->setCurrentIndex(1);
+                ui->sp_acidpercEdit->setValue(my_acids.at(1).AcidPrc);
+                ui->sp_acidvolEdit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "Fosforzuur" || recipe->miscs.at(i).name == "Phosphoric") {
+                recipe->sparge_acid_type = 2;
+                recipe->sparge_acid_perc = my_acids.at(2).AcidPrc;
+                ui->sp_acidtypeEdit->setCurrentIndex(2);
+                ui->sp_acidpercEdit->setValue(my_acids.at(2).AcidPrc);
+                ui->sp_acidvolEdit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "Zwavelzuur" || recipe->miscs.at(i).name == "Sulfuric") {
+                recipe->sparge_acid_type = 3;
+                recipe->sparge_acid_perc = my_acids.at(3).AcidPrc;
+                ui->sp_acidtypeEdit->setCurrentIndex(3);
+                ui->sp_acidpercEdit->setValue(my_acids.at(3).AcidPrc);
+                ui->sp_acidvolEdit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            }
 	}
     }
 }
@@ -189,7 +232,7 @@
 /*
  * Manipulate the memory array and update the miscs table.
  */
-void EditRecipe::brewing_salt_sub(QString salt, double val)
+void EditRecipe::brewing_salt_sub(QString salt, double val, int use)
 {
     QTableWidgetItem *item;
 
@@ -199,8 +242,8 @@
 	 * Remove this salt if it is in the table.
 	 */
 	for (int i = 0; i < recipe->miscs.size(); i++) {
-	    if (salt.contains(recipe->miscs.at(i).name)) {
-		qDebug() << "  brewing_salt_sub delete" << salt;
+	    if (salt.contains(recipe->miscs.at(i).name) && recipe->miscs.at(i).use_use == use) {
+		qDebug() << "  brewing_salt_sub delete" << salt << use;
 		recipe->miscs.removeAt(i);
 		refreshMiscs();
 		return;
@@ -214,7 +257,7 @@
      * If it is, update the amount.
      */
     for (int i = 0; i < recipe->miscs.size(); i++) {
-	if (salt.contains(recipe->miscs.at(i).name)) {
+	if (salt.contains(recipe->miscs.at(i).name) && recipe->miscs.at(i).use_use == use) {
 	    recipe->miscs[i].amount = val / 1000.0;
 	    if (recipe->miscs.at(i).amount_is_weight)
             	item = new QTableWidgetItem(QString("%1 gr").arg(val, 3, 'f', 2, '0'));
@@ -240,7 +283,7 @@
 	    m.name = query.value(1).toString();
             m.amount = val / 1000.0;
             m.type = query.value(2).toInt();
-            m.use_use = query.value(3).toInt();
+            m.use_use = use;
             m.time = query.value(4).toDouble();
             m.amount_is_weight = query.value(5).toInt() ? true:false;
             m.cost = query.value(10).toDouble();
@@ -250,18 +293,18 @@
 	}
     }
 
-    qDebug() << "brewing_salt_sub, nothing done." << salt << val;
+    qDebug() << "brewing_salt_sub, nothing done." << salt << val << use;
 }
 
 
 /*
  * Edit brewing salt and recalculate.
  */
-void EditRecipe::set_brewing_salt(QString salt, double val)
+void EditRecipe::set_brewing_salt(QString salt, double val, int use)
 {
     val = round(val * 100.0) / 100.0;
-    qDebug() << "set_brewing_salt" << salt << val;
-    brewing_salt_sub(salt, val);
+    qDebug() << "set_brewing_salt" << salt << val << use;
+    brewing_salt_sub(salt, val, use);
     calcWater();
     is_changed();
 }
@@ -612,6 +655,7 @@
     useatEdit->addItem(tr("Primary"));
     useatEdit->addItem(tr("Secondary"));
     useatEdit->addItem(tr("Bottling"));
+    useatEdit->addItem(tr("Sparge"));
     useatEdit->setCurrentIndex(recipe->miscs.at(recipe->miscs_row).use_use);
 
     minstockEdit = new QCheckBox(dialog);
@@ -672,6 +716,11 @@
     const QSignalBlocker blocker6(ui->bs_nahco3Edit);
     const QSignalBlocker blocker7(ui->bs_caco3Edit);
     const QSignalBlocker blocker9(ui->mw_acidvolEdit);
+    const QSignalBlocker blocker10(ui->ss_cacl2Edit);
+    const QSignalBlocker blocker11(ui->ss_caso4Edit);
+    const QSignalBlocker blocker12(ui->ss_mgso4Edit);
+    const QSignalBlocker blocker13(ui->ss_naclEdit);
+    const QSignalBlocker blocker14(ui->ss_mgcl2Edit);
 
     for (int i = 0; i < recipe->miscs.size(); i++) {
 	amount = recipe->miscs.at(i).amount * factor;
@@ -680,7 +729,7 @@
 	/*
          * Update the water agents.
          */
-        if (recipe->miscs.at(i).type == MISC_TYPES_WATER_AGENT) {
+        if (recipe->miscs.at(i).type == MISC_TYPES_WATER_AGENT && recipe->miscs.at(i).use_use == MISC_USES_MASH) {
             if (recipe->miscs.at(i).name == "CaCl2") {
                 ui->bs_cacl2Edit->setValue(recipe->miscs.at(i).amount * 1000.0);
             } else if (recipe->miscs.at(i).name == "CaSO4") {
@@ -704,6 +753,26 @@
             } else if (recipe->miscs.at(i).name == "Zwavelzuur" || recipe->miscs.at(i).name == "Sulfuric") {
                 ui->mw_acidvolEdit->setValue(recipe->miscs.at(i).amount * 1000.0);
             }
+	} else if (recipe->miscs.at(i).type == MISC_TYPES_WATER_AGENT && recipe->miscs.at(i).use_use == MISC_USES_SPARGE) {
+            if (recipe->miscs.at(i).name == "CaCl2") {
+                ui->ss_cacl2Edit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "CaSO4") {
+                ui->ss_caso4Edit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "MgSO4") {
+                ui->ss_mgso4Edit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "NaCl") {
+                ui->ss_naclEdit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "MgCl2") {
+                ui->ss_mgcl2Edit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "Melkzuur" || recipe->miscs.at(i).name == "Lactic") {
+                ui->sp_acidvolEdit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "Zoutzuur" || recipe->miscs.at(i).name == "Hydrochloric") {
+                ui->sp_acidvolEdit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "Fosforzuur" || recipe->miscs.at(i).name == "Phosphoric") {
+                ui->sp_acidvolEdit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            } else if (recipe->miscs.at(i).name == "Zwavelzuur" || recipe->miscs.at(i).name == "Sulfuric") {
+                ui->sp_acidvolEdit->setValue(recipe->miscs.at(i).amount * 1000.0);
+            }
         }
     }
 }
--- a/src/EditRecipeTab7.cpp	Sun Jul 17 22:18:48 2022 +0200
+++ b/src/EditRecipeTab7.cpp	Mon Jul 18 17:04:02 2022 +0200
@@ -265,10 +265,17 @@
 	    Acidmg = Acid;
 	    Acid = Acid / my_acids[AT].AcidSG;
 	    Acid = round((Acid / (recipe->wa_acid_perc / 100.0)) * 100.0) / 100.0;
+	    qDebug() << "  Mash auto Acid final old ml:" << Acid;
+	    Acid = Acidmg;
+
+	    double RealSG = round(((my_acids[AT].AcidSG - 1000) * (recipe->wa_acid_perc / 100)) + 1000);
+	    Acid /= RealSG;
+	    Acid /= my_acids[AT].AcidPrc / 100;
+	    Acid = round(Acid * 100.0) / 100.0;
 	    qDebug() << "  Mash auto Acid final ml:" << Acid;
 
 	    QString w = my_acids[AT].name_en + ' ' + my_acids[AT].name_nl;
-	    brewing_salt_sub(w, Acid);
+	    brewing_salt_sub(w, Acid, MISC_USES_MASH);
 	    ui->mw_acidvolEdit->setValue(Acid);
 
 	    bicarbonate = bicarbonate - protonDeficit * frac / liters;
@@ -282,10 +289,12 @@
 	 * Manual adjust acid, calculate resulting pH.
 	 */
 	double pHa = ph;	// Mixed water pH.
+	double RealSG = round(((my_acids[AT].AcidSG - 1000) * (recipe->wa_acid_perc / 100)) + 1000);
 	// Then calculate the new pH with added acids and malts
 	qDebug() << "  Mash pH:" << pHa;
-	Acid = my_acids[AT].AcidSG * (recipe->wa_acid_perc / 100.0);	// ml
+	Acid = RealSG;
 	Acid *= ui->mw_acidvolEdit->value();
+	Acid *= my_acids[AT].AcidPrc / 100;
 	Acid /= my_acids[AT].MolWt;	// mg;
 	Acidmg = Acid;
 
@@ -420,80 +429,128 @@
 
     qDebug() << "calcSparge()";
 
-    const QSignalBlocker blocker1(ui->sp_sourceEdit);
+    const QSignalBlocker blocker2(ui->w1_spButton);
+    const QSignalBlocker blocker3(ui->w2_spButton);
+    const QSignalBlocker blocker4(ui->wg_spButton);
 
     // Select watersource or fallback to the first source.
     if (recipe->sparge_source == 1) { // Source 2
 	if (recipe->w2_ph > 0.0 && recipe->w2_amount > 0) {
 	    Source_pH = recipe->w2_ph;
 	    Source_alkalinity = recipe->w2_total_alkalinity;
+	    ui->sp_caEdit->setValue(recipe->w2_calcium);
+            ui->sp_mgEdit->setValue(recipe->w2_magnesium);
+            ui->sp_hco3Edit->setValue(Utils::Bicarbonate(recipe->w2_total_alkalinity, recipe->w2_ph));
+            ui->sp_caco3Edit->setValue(recipe->w2_total_alkalinity);
+            ui->sp_naEdit->setValue(recipe->w2_sodium);
+            ui->sp_clEdit->setValue(recipe->w2_chloride);
+            ui->sp_so4Edit->setValue(recipe->w2_sulfate);
+            ui->sp_phShow->setValue(recipe->w2_ph);
+            ui->sp_hardnessEdit->setValue(Utils::Hardness(recipe->w2_calcium, recipe->w2_magnesium));
+            ui->sp_raEdit->setValue(Utils::ResidualAlkalinity(recipe->w2_total_alkalinity, recipe->w2_calcium, recipe->w2_magnesium));
+            ui->w2_spButton->setChecked(true);
 	} else {
-	    recipe->sparge_source = 0; // Source 1
-	    ui->sp_sourceEdit->setCurrentIndex(0);
+	    recipe->sparge_source = 0; // Fallback to source 1
+	    ui->w1_spButton->setChecked(true);
 	}
     } else if (recipe->sparge_source == 2) { // Mixed
 	if (recipe->w2_ph > 0.0 && recipe->w2_amount > 0) {
 	    Source_pH = recipe->wg_ph;
 	    Source_alkalinity = recipe->wg_total_alkalinity;
+	    ui->sp_caEdit->setValue(recipe->wg_calcium);
+	    ui->sp_mgEdit->setValue(recipe->wg_magnesium);
+	    ui->sp_hco3Edit->setValue(Utils::Bicarbonate(recipe->wg_total_alkalinity, recipe->wg_ph));
+	    ui->sp_caco3Edit->setValue(recipe->wg_total_alkalinity);
+	    ui->sp_naEdit->setValue(recipe->wg_sodium);
+	    ui->sp_clEdit->setValue(recipe->wg_chloride);
+	    ui->sp_so4Edit->setValue(recipe->wg_sulfate);
+	    ui->sp_phShow->setValue(recipe->wg_ph);
+	    ui->sp_hardnessEdit->setValue(Utils::Hardness(recipe->wg_calcium, recipe->wg_magnesium));
+	    ui->sp_raEdit->setValue(Utils::ResidualAlkalinity(recipe->wg_total_alkalinity, recipe->wg_calcium, recipe->wg_magnesium));
+	    ui->wg_spButton->setChecked(true);
 	} else {
-	    recipe->sparge_source = 0; // Source 1
-            ui->sp_sourceEdit->setCurrentIndex(0);
+	    recipe->sparge_source = 0; // Fallback to source 1
+	    ui->w1_spButton->setChecked(true);
 	}
     }
+    if (recipe->sparge_source == 0) {
+       ui->sp_caEdit->setValue(recipe->w1_calcium);
+       ui->sp_mgEdit->setValue(recipe->w1_magnesium);
+       ui->sp_hco3Edit->setValue(Utils::Bicarbonate(recipe->w1_total_alkalinity, recipe->w1_ph));
+       ui->sp_caco3Edit->setValue(recipe->w1_total_alkalinity);
+       ui->sp_naEdit->setValue(recipe->w1_sodium);
+       ui->sp_clEdit->setValue(recipe->w1_chloride);
+       ui->sp_so4Edit->setValue(recipe->w1_sulfate);
+       ui->sp_phShow->setValue(recipe->w1_ph);
+       ui->sp_hardnessEdit->setValue(Utils::Hardness(recipe->w1_calcium, recipe->w1_magnesium));
+       ui->sp_raEdit->setValue(Utils::ResidualAlkalinity(recipe->w1_total_alkalinity, recipe->w1_calcium, recipe->w1_magnesium));
+       ui->w1_spButton->setChecked(true);
+    }
+    // The spargewater is set.
+
+    int AT = recipe->sparge_acid_type;
+    if (AT < 0 || AT >= my_acids.size()) {
+        AT = 0;
+        recipe->sparge_acid_type = 0;
+        ui->sp_acidtypeEdit->setCurrentIndex(0);
+        recipe->sparge_acid_perc = my_acids[0].AcidPrc;
+        ui->sp_acidpercEdit->setValue(recipe->sparge_acid_perc);
+    }
 
-    // Step 1: Compute the mole fractions of carbonic (f1o), bicarbonate (f2o) and carbonate(f3o) at the water pH
-    double r1 = pow(10, Source_pH - 6.35);
-    double r2 = pow(10, Source_pH - 10.33);
-    double d = 1 + r1 + r1 * r2;
-    double f1 = 1 / d;
-    double f3 = r1 * r2 / d;
+    /*
+     * Auto calculate the required acid
+     */
+    if (recipe->calc_acid) {
+    	// Step 1: Compute the mole fractions of carbonic (f1o), bicarbonate (f2o) and carbonate(f3o) at the water pH
+    	double r1 = pow(10, Source_pH - 6.35);
+    	double r2 = pow(10, Source_pH - 10.33);
+    	double d = 1 + r1 + r1 * r2;
+    	double f1 = 1 / d;
+    	double f3 = r1 * r2 / d;
 
-    // Step 2. Compute the mole fractions at pH = 4.3 (the pH which defines alkalinity)
-    double r143 = pow(10, 4.3 - 6.35);
-    double r243 = pow(10, 4.3 - 10.33);
-    double d43 = 1 + r143 + r143 * r243;
-    double f143 = 1 / d43;
-    double f343 = r143 * r243 / d43;
+    	// Step 2. Compute the mole fractions at pH = 4.3 (the pH which defines alkalinity)
+    	double r143 = pow(10, 4.3 - 6.35);
+    	double r243 = pow(10, 4.3 - 10.33);
+    	double d43 = 1 + r143 + r143 * r243;
+    	double f143 = 1 / d43;
+    	double f343 = r143 * r243 / d43;
 
-    // Step 4. Solve
-    //double Ct = (Source_alkalinity - 1000 * (pow(10, -4.3) - pow(10, -Source_pH))) / ((f143 - f1) + (f3 - f343));
-    double Ct = Source_alkalinity / 50 / ((f143 - f1) + (f3 - f343));
-
-    // Step 5. Compute mole fractions at desired pH
-    double r1g = pow(10, TargetpH - 6.35);
-    double r2g = pow(10, TargetpH - 10.33);
-    double dg = 1 + r1g + r1g * r2g;
-    double f1g = 1 / dg;
-    double f3g = r1g * r2g / dg;
+    	// Step 4. Solve
+    	double Ct = Source_alkalinity / 50 / ((f143 - f1) + (f3 - f343));
 
-    // Step 6. Use these to compute the milliequivalents acid required per liter (mEq/L)
-    double Acid = Ct * ((f1g - f1) + (f3 - f3g)) + pow(10, -TargetpH) - pow(10, -Source_pH);  //mEq/l
-    Acid += 0.01;   // Add acid that would be required for distilled water.
+    	// Step 5. Compute mole fractions at desired pH
+    	double r1g = pow(10, TargetpH - 6.35);
+    	double r2g = pow(10, TargetpH - 10.33);
+    	double dg = 1 + r1g + r1g * r2g;
+    	double f1g = 1 / dg;
+    	double f3g = r1g * r2g / dg;
+
+    	// Step 6. Use these to compute the milliequivalents acid required per liter (mEq/L)
+    	double Acid = Ct * ((f1g - f1) + (f3 - f3g)) + pow(10, -TargetpH) - pow(10, -Source_pH);  //mEq/l
+    	Acid += 0.01;   // Add acid that would be required for distilled water.
+
+    	// Step 8. Get the acid data.
+    	double fract = Utils::CalcFrac(TargetpH, my_acids[AT].pK1, my_acids[AT].pK2, my_acids[AT].pK3);
 
-    //Step 8. Get the acid data.
-    int AT = recipe->sparge_acid_type;
-    if (AT < 0 || AT >= my_acids.size()) {
-	AT = 0;
-	recipe->sparge_acid_type = 0;
-	ui->sp_acidtypeEdit->setCurrentIndex(0);
-	recipe->sparge_acid_perc = my_acids[0].AcidPrc;
-	ui->sp_acidpercEdit->setValue(recipe->sparge_acid_perc);
+    	// Step 9. Now divide the mEq required by the "fraction". This is the required number of moles of acid.
+    	Acid /= fract;
+
+    	// Step 10. Multiply by molecular weight of the acid
+    	Acid *= my_acids[AT].MolWt; //mg
+
+    	// Step 11. Divide by Specific Gravity and Percentage to get the final ml.
+	double RealSG = round(((my_acids[AT].AcidSG - 1000) * (recipe->sparge_acid_perc / 100)) + 1000);
+	Acid = Acid / RealSG;           //ml
+	Acid *= recipe->sparge_volume; //ml acid total at 100%
+	Acid /= my_acids[AT].AcidPrc / 100;     //ml acid at supplied strength
+	Acid = round(Acid * 100.0) / 100.0;
+	recipe->sparge_acid_amount = Acid / 1000;
+	QString w = my_acids[AT].name_en + ' ' + my_acids[AT].name_nl;
+	brewing_salt_sub(w, Acid, MISC_USES_SPARGE);	// Put it in the miscs table.
+    	ui->sp_acidvolEdit->setValue(Acid);
     }
-    double fract = Utils::CalcFrac(TargetpH, my_acids[AT].pK1, my_acids[AT].pK2, my_acids[AT].pK3);
 
-    // Step 9. Now divide the mEq required by the "fraction". This is the required number of moles of acid.
-    Acid /= fract;
-
-    // Step 10. Multiply by molecular weight of the acid
-    Acid *= my_acids[AT].MolWt; //mg
-
-    // Step 11. Divide by Specific Gravity and Percentage to get the final ml.
-    Acid = Acid / my_acids[AT].AcidSG / (recipe->sparge_acid_perc / 100); //ml
-    Acid *= recipe->sparge_volume; //ml acid total
-    Acid = round(Acid * 100.0) / 100.0;
-    recipe->sparge_acid_amount = Acid / 1000;
-    ui->sp_acidvolEdit->setValue(Acid);
-
+    ui->sp_phShow->setValue(recipe->sparge_ph);
     // Finally calculate the estimate preboil pH
     recipe->preboil_ph = -log10(((pow(10, -recipe->mash_ph) * recipe->wg_amount) + (pow(10, -recipe->sparge_ph) * recipe->sparge_volume)) /
                              (recipe->wg_amount + recipe->sparge_volume));
@@ -501,19 +558,36 @@
 }
 
 
-void EditRecipe::sp_source_changed(int val)
+void EditRecipe::sp_group_changed(int val)
 {
-    recipe->sparge_source = val;
-    calcSparge();
-    is_changed();
+    if (val != recipe->sparge_source) {
+           qDebug() << "sp_group_changed" << val;
+       recipe->sparge_source = val;
+       calcSparge();
+       is_changed();
+    }
 }
 
 
 void EditRecipe::sp_type_changed(int val)
 {
+    if (val == recipe->sparge_acid_type)
+        return;
+
+    qDebug() << "sp_type_changed" << val << "old" << recipe->sparge_acid_type;
+    /*
+     * First remove current acid.
+     */
+    QString w = my_acids[recipe->sparge_acid_type].name_en + ' ' + my_acids[recipe->sparge_acid_type].name_nl;
+    brewing_salt_sub(w, 0, MISC_USES_SPARGE);
+
     recipe->sparge_acid_type = val;
+    w = my_acids[recipe->sparge_acid_type].name_en + ' ' + my_acids[recipe->sparge_acid_type].name_nl;
+
     recipe->sparge_acid_perc = my_acids[val].AcidPrc;
     ui->sp_acidpercEdit->setValue(recipe->sparge_acid_perc);
+    brewing_salt_sub(w, ui->sp_acidvolEdit->value(), MISC_USES_SPARGE);        // For now, set old amount.
+
     calcSparge();
     is_changed();
 }
@@ -527,6 +601,116 @@
 }
 
 
+void EditRecipe::sp_acid_changed(double val)
+{
+    if (recipe->calc_acid)
+        return;
+
+    qDebug() << "sp_acid_changed" << val << recipe->sparge_acid_amount * 1000.0;
+
+    double TargetpH = recipe->sparge_ph;
+    double Source_pH = recipe->w1_ph;
+    double Source_alkalinity = recipe->w1_total_alkalinity;
+
+    if (recipe->sparge_source == 1) { // Source 2
+       if (recipe->w2_ph > 0.0 && recipe->w2_amount > 0) {
+           Source_pH = recipe->w2_ph;
+            Source_alkalinity = recipe->w2_total_alkalinity;
+       }
+    } else if (recipe->sparge_source == 2) { // Mixed
+       if (recipe->w2_ph > 0.0 && recipe->w2_amount > 0) {
+           Source_pH = recipe->wg_ph;
+            Source_alkalinity = recipe->wg_total_alkalinity;
+       }
+    }
+
+    int AT = recipe->sparge_acid_type;
+    if (AT < 0 || AT >= my_acids.size()) {
+        AT = 0;
+        recipe->sparge_acid_type = 0;
+        ui->sp_acidtypeEdit->setCurrentIndex(0);
+        recipe->sparge_acid_perc = my_acids[0].AcidPrc;
+        ui->sp_acidpercEdit->setValue(recipe->sparge_acid_perc);
+    }
+
+    bool go_up = (val < (recipe->sparge_acid_amount * 1000.0));
+    bool loop = true;
+
+    while (loop) {
+
+       if (go_up)
+           TargetpH += 0.001;
+       else
+           TargetpH -= 0.001;
+       //qDebug() << "  TargetpH" << TargetpH << "up" << go_up;
+
+        // Step 1: Compute the mole fractions of carbonic (f1o), bicarbonate (f2o) and carbonate(f3o) at the water pH
+        double r1 = pow(10, Source_pH - 6.35);
+        double r2 = pow(10, Source_pH - 10.33);
+        double d = 1 + r1 + r1 * r2;
+        double f1 = 1 / d;
+        double f3 = r1 * r2 / d;
+
+        // Step 2. Compute the mole fractions at pH = 4.3 (the pH which defines alkalinity)
+        double r143 = pow(10, 4.3 - 6.35);
+        double r243 = pow(10, 4.3 - 10.33);
+        double d43 = 1 + r143 + r143 * r243;
+        double f143 = 1 / d43;
+        double f343 = r143 * r243 / d43;
+
+        // Step 4. Solve
+        double Ct = Source_alkalinity / 50 / ((f143 - f1) + (f3 - f343));
+
+        // Step 5. Compute mole fractions at desired pH
+        double r1g = pow(10, TargetpH - 6.35);
+        double r2g = pow(10, TargetpH - 10.33);
+        double dg = 1 + r1g + r1g * r2g;
+        double f1g = 1 / dg;
+        double f3g = r1g * r2g / dg;
+
+        // Step 6. Use these to compute the milliequivalents acid required per liter (mEq/L)
+        double Acid = Ct * ((f1g - f1) + (f3 - f3g)) + pow(10, -TargetpH) - pow(10, -Source_pH);  //mEq/l
+        Acid += 0.01;   // Add acid that would be required for distilled water.
+
+        // Step 7. There is no step 7.
+
+        // Step 8. Get the acid data.
+        double fract = Utils::CalcFrac(TargetpH, my_acids[AT].pK1, my_acids[AT].pK2, my_acids[AT].pK3);
+
+        // Step 9. Now divide the mEq required by the "fraction". This is the required number of moles of acid.
+        Acid /= fract;
+
+        // Step 10. Multiply by molecular weight of the acid
+        Acid *= my_acids[AT].MolWt; //mg
+
+        // Step 11. Divide by Specific Gravity and Percentage to get the final ml.
+        double RealSG = round(((my_acids[AT].AcidSG - 1000) * (recipe->sparge_acid_perc / 100)) + 1000);
+        Acid = Acid / RealSG;           //ml
+        Acid *= recipe->sparge_volume; //ml acid total at 100%
+        Acid /= my_acids[AT].AcidPrc / 100;     //ml acid at supplied strength
+        Acid = round(Acid * 100.0) / 100.0;
+        recipe->sparge_acid_amount = Acid / 1000;
+       //qDebug() << "  acid" << recipe->sparge_acid_amount;
+
+       if (go_up && (val > (recipe->sparge_acid_amount * 1000.0)))
+           loop = false;
+       else if (! go_up && (val < (recipe->sparge_acid_amount * 1000.0)))
+           loop = false;
+
+       //qDebug() << "  test" << loop << go_up << val << recipe->sparge_acid_amount * 1000.0;
+    }
+
+    const QSignalBlocker blocker1(ui->sp_phEdit);
+    recipe->sparge_ph = round(TargetpH * 100) / 100;
+    ui->sp_phEdit->setValue(recipe->sparge_ph);
+    ui->sp_phShow->setValue(recipe->sparge_ph);
+
+    QString w = my_acids[AT].name_en + ' ' + my_acids[AT].name_nl;
+    set_brewing_salt(w, val, MISC_USES_SPARGE);
+    //qDebug() << "  new" << recipe->sparge_ph << val;
+}
+
+
 double EditRecipe::GetBUGU()
 {
     double gu = (recipe->est_og - 1) * 1000;
@@ -555,6 +739,10 @@
     ui->mw_phEdit->setButtonSymbols(recipe->calc_acid ? QAbstractSpinBox::UpDownArrows : QAbstractSpinBox::NoButtons);
     ui->mw_acidvolEdit->setReadOnly(recipe->calc_acid);
     ui->mw_acidvolEdit->setButtonSymbols(recipe->calc_acid ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
+    ui->sp_phEdit->setReadOnly(! recipe->calc_acid);
+    ui->sp_phEdit->setButtonSymbols(recipe->calc_acid ? QAbstractSpinBox::UpDownArrows : QAbstractSpinBox::NoButtons);
+    ui->sp_acidvolEdit->setReadOnly(recipe->calc_acid);
+    ui->sp_acidvolEdit->setButtonSymbols(recipe->calc_acid ? QAbstractSpinBox::NoButtons : QAbstractSpinBox::UpDownArrows);
     is_changed();
     calcWater();
 }
@@ -581,7 +769,7 @@
 
     qDebug() << "on_mw_acid_changed" << val;
     QString w = my_acids[recipe->wa_acid_name].name_en + ' ' + my_acids[recipe->wa_acid_name].name_nl;
-    set_brewing_salt(w, val);
+    set_brewing_salt(w, val, MISC_USES_MASH);
 }
 
 
@@ -595,14 +783,14 @@
      * First remove current acid.
      */
     QString w = my_acids[recipe->wa_acid_name].name_en + ' ' + my_acids[recipe->wa_acid_name].name_nl;
-    brewing_salt_sub(w, 0);
+    brewing_salt_sub(w, 0, MISC_USES_MASH);
 
     recipe->wa_acid_name = val;
     w = my_acids[recipe->wa_acid_name].name_en + ' ' + my_acids[recipe->wa_acid_name].name_nl;
 
     recipe->wa_acid_perc = my_acids.at(val).AcidPrc;
     ui->mw_acidpercEdit->setValue(my_acids.at(val).AcidPrc);
-    brewing_salt_sub(w, ui->mw_acidvolEdit->value());   // For now, set old amount.
+    brewing_salt_sub(w, ui->mw_acidvolEdit->value(), MISC_USES_MASH);   // For now, set old amount.
 
     is_changed();
     calcWater();
@@ -812,12 +1000,17 @@
 }
 
 
-void EditRecipe::wb_cacl2_changed(double val)  { set_brewing_salt("CaCl2", val);  }
-void EditRecipe::wb_caso4_changed(double val)  { set_brewing_salt("CaSO4", val);  }
-void EditRecipe::wb_mgso4_changed(double val)  { set_brewing_salt("MgSO4", val);  }
-void EditRecipe::wb_nacl_changed(double val)   { set_brewing_salt("NaCl", val);   }
-void EditRecipe::wb_mgcl2_changed(double val)  { set_brewing_salt("MgCl2", val);  }
-void EditRecipe::wb_nahco3_changed(double val) { set_brewing_salt("NaHCO3", val); }
-void EditRecipe::wb_caco3_changed(double val)  { set_brewing_salt("CaCO3", val);  }
+void EditRecipe::wb_cacl2_changed(double val)  { set_brewing_salt("CaCl2", val, MISC_USES_MASH);   }
+void EditRecipe::wb_caso4_changed(double val)  { set_brewing_salt("CaSO4", val, MISC_USES_MASH);   }
+void EditRecipe::wb_mgso4_changed(double val)  { set_brewing_salt("MgSO4", val, MISC_USES_MASH);   }
+void EditRecipe::wb_nacl_changed(double val)   { set_brewing_salt("NaCl", val, MISC_USES_MASH);    }
+void EditRecipe::wb_mgcl2_changed(double val)  { set_brewing_salt("MgCl2", val, MISC_USES_MASH);   }
+void EditRecipe::wb_nahco3_changed(double val) { set_brewing_salt("NaHCO3", val, MISC_USES_MASH);  }
+void EditRecipe::wb_caco3_changed(double val)  { set_brewing_salt("CaCO3", val, MISC_USES_MASH);   }
+void EditRecipe::sp_cacl2_changed(double val)  { set_brewing_salt("CaCl2", val, MISC_USES_SPARGE); }
+void EditRecipe::sp_caso4_changed(double val)  { set_brewing_salt("CaSO4", val, MISC_USES_SPARGE); }
+void EditRecipe::sp_mgso4_changed(double val)  { set_brewing_salt("MgSO4", val, MISC_USES_SPARGE); }
+void EditRecipe::sp_nacl_changed(double val)   { set_brewing_salt("NaCl", val, MISC_USES_SPARGE);  }
+void EditRecipe::sp_mgcl2_changed(double val)  { set_brewing_salt("MgCl2", val, MISC_USES_SPARGE); }
 
 
--- a/ui/EditProduct.ui	Sun Jul 17 22:18:48 2022 +0200
+++ b/ui/EditProduct.ui	Mon Jul 18 17:04:02 2022 +0200
@@ -95,7 +95,7 @@
        <enum>QTabWidget::Rounded</enum>
       </property>
       <property name="currentIndex">
-       <number>0</number>
+       <number>7</number>
       </property>
       <property name="elideMode">
        <enum>Qt::ElideNone</enum>
@@ -3794,1662 +3794,12 @@
        <attribute name="title">
         <string>Water</string>
        </attribute>
-       <widget class="QGroupBox" name="waterviewBox">
-        <property name="geometry">
-         <rect>
-          <x>10</x>
-          <y>0</y>
-          <width>1101</width>
-          <height>221</height>
-         </rect>
-        </property>
-        <property name="autoFillBackground">
-         <bool>false</bool>
-        </property>
-        <property name="title">
-         <string>Water overview</string>
-        </property>
-        <property name="flat">
-         <bool>false</bool>
-        </property>
-        <property name="checkable">
-         <bool>false</bool>
-        </property>
-        <property name="checked">
-         <bool>false</bool>
-        </property>
-        <widget class="QDoubleSpinBox" name="w1_caEdit">
-         <property name="geometry">
-          <rect>
-           <x>300</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_phEdit">
-         <property name="geometry">
-          <rect>
-           <x>860</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_so4Edit">
-         <property name="geometry">
-          <rect>
-           <x>780</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_clEdit">
-         <property name="geometry">
-          <rect>
-           <x>700</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_naEdit">
-         <property name="geometry">
-          <rect>
-           <x>620</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_caco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>540</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_hco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>460</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_mgEdit">
-         <property name="geometry">
-          <rect>
-           <x>380</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QLabel" name="caLabel">
-         <property name="geometry">
-          <rect>
-           <x>300</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Ca</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="mgLabel">
-         <property name="geometry">
-          <rect>
-           <x>380</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Mg</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="hco3Label">
-         <property name="geometry">
-          <rect>
-           <x>460</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>HCO3</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="caco3Label">
-         <property name="geometry">
-          <rect>
-           <x>540</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>CaCO3</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="naLabel">
-         <property name="geometry">
-          <rect>
-           <x>620</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Na</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="clLabel">
-         <property name="geometry">
-          <rect>
-           <x>700</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Cl</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="so4Label">
-         <property name="geometry">
-          <rect>
-           <x>780</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>SO4</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="phLabel">
-         <property name="geometry">
-          <rect>
-           <x>860</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>pH</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_volEdit">
-         <property name="geometry">
-          <rect>
-           <x>200</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="accelerated">
-          <bool>false</bool>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>100000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QLabel" name="volLabel">
-         <property name="geometry">
-          <rect>
-           <x>200</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Volume</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_hco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>460</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_phEdit">
-         <property name="geometry">
-          <rect>
-           <x>860</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_caco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>540</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_naEdit">
-         <property name="geometry">
-          <rect>
-           <x>620</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_so4Edit">
-         <property name="geometry">
-          <rect>
-           <x>780</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_caEdit">
-         <property name="geometry">
-          <rect>
-           <x>300</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_clEdit">
-         <property name="geometry">
-          <rect>
-           <x>700</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_volEdit">
-         <property name="geometry">
-          <rect>
-           <x>200</x>
-           <y>80</y>
-           <width>85</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The division between the main and dilution water. The total volume does not change.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>false</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::UpDownArrows</enum>
-         </property>
-         <property name="accelerated">
-          <bool>true</bool>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>100000.000000000000000</double>
-         </property>
-         <property name="singleStep">
-          <double>0.500000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_mgEdit">
-         <property name="geometry">
-          <rect>
-           <x>380</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_hco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>460</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_phEdit">
-         <property name="geometry">
-          <rect>
-           <x>860</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_caco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>540</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_naEdit">
-         <property name="geometry">
-          <rect>
-           <x>620</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_so4Edit">
-         <property name="geometry">
-          <rect>
-           <x>780</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_caEdit">
-         <property name="geometry">
-          <rect>
-           <x>300</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_clEdit">
-         <property name="geometry">
-          <rect>
-           <x>700</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_volEdit">
-         <property name="geometry">
-          <rect>
-           <x>200</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>100000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_mgEdit">
-         <property name="geometry">
-          <rect>
-           <x>380</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_hco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>460</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_phEdit">
-         <property name="geometry">
-          <rect>
-           <x>860</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>Mash pH should be between 5.2 and 5.6. Use 5.2 for light and 5.5 for dark beers.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_caco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>540</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_naEdit">
-         <property name="geometry">
-          <rect>
-           <x>620</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_so4Edit">
-         <property name="geometry">
-          <rect>
-           <x>780</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_caEdit">
-         <property name="geometry">
-          <rect>
-           <x>300</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_clEdit">
-         <property name="geometry">
-          <rect>
-           <x>700</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_mgEdit">
-         <property name="geometry">
-          <rect>
-           <x>380</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_mgEdit">
-         <property name="geometry">
-          <rect>
-           <x>380</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The ideal amount of Magnesium is between 5 and 40.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_hco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>460</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>0 to 50 for light beers, 50 to 150 for amber beers, 150 to 250 for dark beers.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_so4Edit">
-         <property name="geometry">
-          <rect>
-           <x>780</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The ideal Sulfate amount should be between 50 and 400.
-Together with Chloride it must be below 500.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_caEdit">
-         <property name="geometry">
-          <rect>
-           <x>300</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The ideal amount of Calcium is between 40 and 150.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_clEdit">
-         <property name="geometry">
-          <rect>
-           <x>700</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The ideal Chloride amount is between 50 and 150.
-Together with Sulfate it must be below 500.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_caco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>540</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_naEdit">
-         <property name="geometry">
-          <rect>
-           <x>620</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The ideal amount of Natrium should be below 150.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QLabel" name="profileLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>20</y>
-           <width>171</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Water profile</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QComboBox" name="w1_nameEdit">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>50</y>
-           <width>181</width>
-           <height>23</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The main brewing water</string>
-         </property>
-         <property name="currentText">
-          <string/>
-         </property>
-         <property name="placeholderText">
-          <string>Choose water</string>
-         </property>
-        </widget>
-        <widget class="QComboBox" name="w2_nameEdit">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>80</y>
-           <width>181</width>
-           <height>23</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>Optional dilution water</string>
-         </property>
-         <property name="placeholderText">
-          <string>Choose dilution</string>
-         </property>
-        </widget>
-        <widget class="QComboBox" name="wt_sourceEdit">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>180</y>
-           <width>181</width>
-           <height>23</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>If needed, choose a target water profile.</string>
-         </property>
-         <property name="placeholderText">
-          <string>Choose example water</string>
-         </property>
-        </widget>
-        <widget class="QLabel" name="mixedLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>110</y>
-           <width>171</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Mixed water</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="treatedLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>140</y>
-           <width>171</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Treated water</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_raEdit">
-         <property name="geometry">
-          <rect>
-           <x>1020</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="minimum">
-          <double>-1000.000000000000000</double>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QLabel" name="raLabel">
-         <property name="geometry">
-          <rect>
-           <x>1020</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>RA</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_raEdit">
-         <property name="geometry">
-          <rect>
-           <x>1020</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="minimum">
-          <double>-1000.000000000000000</double>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_raEdit">
-         <property name="geometry">
-          <rect>
-           <x>1020</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="minimum">
-          <double>-1000.000000000000000</double>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_raEdit">
-         <property name="geometry">
-          <rect>
-           <x>1020</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="minimum">
-          <double>-1000.000000000000000</double>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_hardnessEdit">
-         <property name="geometry">
-          <rect>
-           <x>940</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_hardnessEdit">
-         <property name="geometry">
-          <rect>
-           <x>940</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_hardnessEdit">
-         <property name="geometry">
-          <rect>
-           <x>940</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QLabel" name="hardnessLabel">
-         <property name="geometry">
-          <rect>
-           <x>940</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Hardness</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_hardnessEdit">
-         <property name="geometry">
-          <rect>
-           <x>940</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_raEdit">
-         <property name="geometry">
-          <rect>
-           <x>1020</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="minimum">
-          <double>-1000.000000000000000</double>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_hardnessEdit">
-         <property name="geometry">
-          <rect>
-           <x>940</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-       </widget>
        <widget class="QGroupBox" name="brewsaltsBox">
         <property name="geometry">
          <rect>
           <x>10</x>
-          <y>230</y>
-          <width>271</width>
+          <y>220</y>
+          <width>291</width>
           <height>241</height>
          </rect>
         </property>
@@ -5461,7 +3811,7 @@
           <rect>
            <x>10</x>
            <y>20</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -5480,7 +3830,7 @@
           <rect>
            <x>10</x>
            <y>50</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -5499,7 +3849,7 @@
           <rect>
            <x>10</x>
            <y>80</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -5518,7 +3868,7 @@
           <rect>
            <x>10</x>
            <y>110</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -5537,7 +3887,7 @@
           <rect>
            <x>10</x>
            <y>140</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -5556,7 +3906,7 @@
           <rect>
            <x>10</x>
            <y>170</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -5575,7 +3925,7 @@
           <rect>
            <x>10</x>
            <y>200</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -5592,7 +3942,7 @@
         <widget class="QDoubleSpinBox" name="bs_cacl2Edit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>20</y>
            <width>91</width>
            <height>24</height>
@@ -5624,7 +3974,7 @@
         <widget class="QDoubleSpinBox" name="bs_caso4Edit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>50</y>
            <width>91</width>
            <height>24</height>
@@ -5656,7 +4006,7 @@
         <widget class="QDoubleSpinBox" name="bs_mgso4Edit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>80</y>
            <width>91</width>
            <height>24</height>
@@ -5687,7 +4037,7 @@
         <widget class="QDoubleSpinBox" name="bs_naclEdit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>110</y>
            <width>91</width>
            <height>24</height>
@@ -5719,7 +4069,7 @@
         <widget class="QDoubleSpinBox" name="bs_mgcl2Edit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>140</y>
            <width>91</width>
            <height>24</height>
@@ -5750,7 +4100,7 @@
         <widget class="QDoubleSpinBox" name="bs_nahco3Edit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>170</y>
            <width>91</width>
            <height>24</height>
@@ -5781,7 +4131,7 @@
         <widget class="QDoubleSpinBox" name="bs_caco3Edit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>200</y>
            <width>91</width>
            <height>24</height>
@@ -5809,30 +4159,188 @@
           <double>0.100000000000000</double>
          </property>
         </widget>
+        <widget class="QDoubleSpinBox" name="ss_caso4Edit">
+         <property name="geometry">
+          <rect>
+           <x>190</x>
+           <y>50</y>
+           <width>91</width>
+           <height>24</height>
+          </rect>
+         </property>
+         <property name="toolTip">
+          <string>Gypsum to change the water profile. This adds Calcium and Sulfate.
+To improve bitter beers.</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+         <property name="accelerated">
+          <bool>true</bool>
+         </property>
+         <property name="suffix">
+          <string> gr</string>
+         </property>
+         <property name="decimals">
+          <number>2</number>
+         </property>
+         <property name="maximum">
+          <double>1000.000000000000000</double>
+         </property>
+         <property name="singleStep">
+          <double>0.100000000000000</double>
+         </property>
+        </widget>
+        <widget class="QDoubleSpinBox" name="ss_mgso4Edit">
+         <property name="geometry">
+          <rect>
+           <x>190</x>
+           <y>80</y>
+           <width>91</width>
+           <height>24</height>
+          </rect>
+         </property>
+         <property name="toolTip">
+          <string>Epsom salt to change the water profile. Use with caution!</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+         <property name="accelerated">
+          <bool>true</bool>
+         </property>
+         <property name="suffix">
+          <string> gr</string>
+         </property>
+         <property name="decimals">
+          <number>2</number>
+         </property>
+         <property name="maximum">
+          <double>1000.000000000000000</double>
+         </property>
+         <property name="singleStep">
+          <double>0.100000000000000</double>
+         </property>
+        </widget>
+        <widget class="QDoubleSpinBox" name="ss_naclEdit">
+         <property name="geometry">
+          <rect>
+           <x>190</x>
+           <y>110</y>
+           <width>91</width>
+           <height>24</height>
+          </rect>
+         </property>
+         <property name="toolTip">
+          <string>Table salt to change the water profile. This adds Sodium and Chloride.
+Improves the sweetness of the beer. The beer will become salty at high doses.</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+         <property name="accelerated">
+          <bool>true</bool>
+         </property>
+         <property name="suffix">
+          <string> gr</string>
+         </property>
+         <property name="decimals">
+          <number>2</number>
+         </property>
+         <property name="maximum">
+          <double>1000.000000000000000</double>
+         </property>
+         <property name="singleStep">
+          <double>0.100000000000000</double>
+         </property>
+        </widget>
+        <widget class="QDoubleSpinBox" name="ss_cacl2Edit">
+         <property name="geometry">
+          <rect>
+           <x>190</x>
+           <y>20</y>
+           <width>91</width>
+           <height>24</height>
+          </rect>
+         </property>
+         <property name="toolTip">
+          <string>To change the water profile. This adds Calcium and Chloride.
+To improve sweet style beers.</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+         <property name="accelerated">
+          <bool>true</bool>
+         </property>
+         <property name="suffix">
+          <string> gr</string>
+         </property>
+         <property name="decimals">
+          <number>2</number>
+         </property>
+         <property name="maximum">
+          <double>1000.000000000000000</double>
+         </property>
+         <property name="singleStep">
+          <double>0.100000000000000</double>
+         </property>
+        </widget>
+        <widget class="QDoubleSpinBox" name="ss_mgcl2Edit">
+         <property name="geometry">
+          <rect>
+           <x>190</x>
+           <y>140</y>
+           <width>91</width>
+           <height>24</height>
+          </rect>
+         </property>
+         <property name="toolTip">
+          <string>Magnesium Chloride</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+         <property name="accelerated">
+          <bool>true</bool>
+         </property>
+         <property name="suffix">
+          <string> gr</string>
+         </property>
+         <property name="decimals">
+          <number>2</number>
+         </property>
+         <property name="maximum">
+          <double>1000.000000000000000</double>
+         </property>
+         <property name="singleStep">
+          <double>0.100000000000000</double>
+         </property>
+        </widget>
        </widget>
        <widget class="QGroupBox" name="mashBox">
         <property name="geometry">
          <rect>
-          <x>350</x>
-          <y>230</y>
-          <width>421</width>
-          <height>91</height>
+          <x>780</x>
+          <y>220</y>
+          <width>331</width>
+          <height>241</height>
          </rect>
         </property>
         <property name="title">
-         <string>Mash water</string>
+         <string>Acid Additions</string>
         </property>
         <widget class="QLabel" name="mw_phLabel">
          <property name="geometry">
           <rect>
            <x>10</x>
-           <y>20</y>
-           <width>111</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Desired pH:</string>
+           <y>50</y>
+           <width>131</width>
+           <height>20</height>
+          </rect>
+         </property>
+         <property name="text">
+          <string>Desired mash pH:</string>
          </property>
          <property name="alignment">
           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
@@ -5841,9 +4349,9 @@
         <widget class="QLabel" name="mw_autoLabel">
          <property name="geometry">
           <rect>
-           <x>235</x>
+           <x>10</x>
            <y>20</y>
-           <width>141</width>
+           <width>131</width>
            <height>20</height>
           </rect>
          </property>
@@ -5858,8 +4366,8 @@
          <property name="geometry">
           <rect>
            <x>10</x>
-           <y>50</y>
-           <width>111</width>
+           <y>80</y>
+           <width>131</width>
            <height>20</height>
           </rect>
          </property>
@@ -5873,8 +4381,8 @@
         <widget class="QComboBox" name="mw_acidPick">
          <property name="geometry">
           <rect>
-           <x>130</x>
-           <y>50</y>
+           <x>150</x>
+           <y>80</y>
            <width>101</width>
            <height>23</height>
           </rect>
@@ -5883,8 +4391,8 @@
         <widget class="QDoubleSpinBox" name="mw_phEdit">
          <property name="geometry">
           <rect>
-           <x>130</x>
-           <y>20</y>
+           <x>150</x>
+           <y>50</y>
            <width>101</width>
            <height>24</height>
           </rect>
@@ -5911,8 +4419,8 @@
         <widget class="QDoubleSpinBox" name="mw_acidpercEdit">
          <property name="geometry">
           <rect>
-           <x>240</x>
-           <y>50</y>
+           <x>260</x>
+           <y>80</y>
            <width>61</width>
            <height>24</height>
           </rect>
@@ -5945,8 +4453,8 @@
         <widget class="QDoubleSpinBox" name="mw_acidvolEdit">
          <property name="geometry">
           <rect>
-           <x>310</x>
-           <y>50</y>
+           <x>150</x>
+           <y>110</y>
            <width>89</width>
            <height>24</height>
           </rect>
@@ -5973,200 +4481,35 @@
         <widget class="QCheckBox" name="mw_autoEdit">
          <property name="geometry">
           <rect>
-           <x>385</x>
+           <x>150</x>
            <y>20</y>
            <width>16</width>
            <height>21</height>
           </rect>
          </property>
         </widget>
-       </widget>
-       <widget class="QGroupBox" name="spargeBox">
-        <property name="geometry">
-         <rect>
-          <x>840</x>
-          <y>230</y>
-          <width>271</width>
-          <height>241</height>
-         </rect>
-        </property>
-        <property name="title">
-         <string>Sparge water</string>
-        </property>
-        <widget class="QLabel" name="sp_volLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>20</y>
-           <width>151</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Sparge water supply:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="sp_tempLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>50</y>
-           <width>151</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Sparge temperature:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="sp_sourceLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>80</y>
-           <width>151</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Water source:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
         <widget class="QLabel" name="sp_phLabel">
          <property name="geometry">
           <rect>
            <x>10</x>
-           <y>110</y>
-           <width>151</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Desired pH:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="sp_acidtypeLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
            <y>140</y>
-           <width>151</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Acid type:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="sp_acidpercLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>170</y>
-           <width>151</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Acid strength:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="sp_acidvolLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>200</y>
-           <width>151</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Acid needed:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="sp_volEdit">
-         <property name="geometry">
-          <rect>
-           <x>170</x>
-           <y>20</y>
-           <width>91</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="accelerated">
-          <bool>true</bool>
-         </property>
-         <property name="suffix">
-          <string> L</string>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>100000.000000000000000</double>
-         </property>
-         <property name="singleStep">
-          <double>0.500000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="sp_tempEdit">
-         <property name="geometry">
-          <rect>
-           <x>170</x>
-           <y>50</y>
-           <width>91</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="accelerated">
-          <bool>true</bool>
-         </property>
-         <property name="suffix">
-          <string> °C</string>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>100.000000000000000</double>
-         </property>
-         <property name="singleStep">
-          <double>0.500000000000000</double>
+           <width>131</width>
+           <height>20</height>
+          </rect>
+         </property>
+         <property name="text">
+          <string>Desired sparge pH:</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
          </property>
         </widget>
         <widget class="QDoubleSpinBox" name="sp_phEdit">
          <property name="geometry">
           <rect>
-           <x>170</x>
-           <y>110</y>
-           <width>91</width>
+           <x>150</x>
+           <y>140</y>
+           <width>101</width>
            <height>24</height>
           </rect>
          </property>
@@ -6186,12 +4529,38 @@
           <double>0.100000000000000</double>
          </property>
         </widget>
+        <widget class="QLabel" name="sp_acidtypeLabel">
+         <property name="geometry">
+          <rect>
+           <x>10</x>
+           <y>170</y>
+           <width>131</width>
+           <height>20</height>
+          </rect>
+         </property>
+         <property name="text">
+          <string>Acid type:</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+        </widget>
+        <widget class="QComboBox" name="sp_acidtypeEdit">
+         <property name="geometry">
+          <rect>
+           <x>150</x>
+           <y>170</y>
+           <width>101</width>
+           <height>23</height>
+          </rect>
+         </property>
+        </widget>
         <widget class="QDoubleSpinBox" name="sp_acidpercEdit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>260</x>
            <y>170</y>
-           <width>91</width>
+           <width>61</width>
            <height>24</height>
           </rect>
          </property>
@@ -6223,9 +4592,9 @@
         <widget class="QDoubleSpinBox" name="sp_acidvolEdit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>150</x>
            <y>200</y>
-           <width>91</width>
+           <width>89</width>
            <height>24</height>
           </rect>
          </property>
@@ -6233,13 +4602,13 @@
           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
          </property>
          <property name="readOnly">
-          <bool>true</bool>
+          <bool>false</bool>
          </property>
          <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
+          <enum>QAbstractSpinBox::UpDownArrows</enum>
          </property>
          <property name="accelerated">
-          <bool>false</bool>
+          <bool>true</bool>
          </property>
          <property name="suffix">
           <string> ml</string>
@@ -6251,35 +4620,47 @@
           <double>10000.000000000000000</double>
          </property>
          <property name="singleStep">
-          <double>0.100000000000000</double>
-         </property>
-        </widget>
-        <widget class="QComboBox" name="sp_sourceEdit">
-         <property name="geometry">
-          <rect>
-           <x>170</x>
-           <y>80</y>
-           <width>91</width>
-           <height>23</height>
-          </rect>
-         </property>
-        </widget>
-        <widget class="QComboBox" name="sp_acidtypeEdit">
-         <property name="geometry">
-          <rect>
-           <x>170</x>
-           <y>140</y>
-           <width>91</width>
-           <height>23</height>
-          </rect>
+          <double>0.010000000000000</double>
+         </property>
+        </widget>
+        <widget class="QLabel" name="mw_acidvolLabel">
+         <property name="geometry">
+          <rect>
+           <x>10</x>
+           <y>110</y>
+           <width>131</width>
+           <height>20</height>
+          </rect>
+         </property>
+         <property name="text">
+          <string>Acid amount:</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+        </widget>
+        <widget class="QLabel" name="sp_acidvolLabel">
+         <property name="geometry">
+          <rect>
+           <x>10</x>
+           <y>200</y>
+           <width>131</width>
+           <height>20</height>
+          </rect>
+         </property>
+         <property name="text">
+          <string>Acid amount:</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
          </property>
         </widget>
        </widget>
        <widget class="QLabel" name="buguLabel">
         <property name="geometry">
          <rect>
-          <x>290</x>
-          <y>340</y>
+          <x>310</x>
+          <y>240</y>
           <width>181</width>
           <height>20</height>
          </rect>
@@ -6294,8 +4675,8 @@
        <widget class="QDoubleSpinBox" name="buguEdit">
         <property name="geometry">
          <rect>
-          <x>480</x>
-          <y>340</y>
+          <x>500</x>
+          <y>240</y>
           <width>71</width>
           <height>24</height>
          </rect>
@@ -6325,9 +4706,9 @@
        <widget class="QLabel" name="buguResult">
         <property name="geometry">
          <rect>
-          <x>560</x>
-          <y>340</y>
-          <width>211</width>
+          <x>580</x>
+          <y>240</y>
+          <width>191</width>
           <height>20</height>
          </rect>
         </property>
@@ -6346,8 +4727,8 @@
        <widget class="QLabel" name="so4clLabel">
         <property name="geometry">
          <rect>
-          <x>290</x>
-          <y>370</y>
+          <x>310</x>
+          <y>270</y>
           <width>181</width>
           <height>20</height>
          </rect>
@@ -6362,8 +4743,8 @@
        <widget class="QDoubleSpinBox" name="so4clEdit">
         <property name="geometry">
          <rect>
-          <x>480</x>
-          <y>370</y>
+          <x>500</x>
+          <y>270</y>
           <width>71</width>
           <height>24</height>
          </rect>
@@ -6393,9 +4774,9 @@
        <widget class="QLabel" name="so4clResult">
         <property name="geometry">
          <rect>
-          <x>560</x>
-          <y>370</y>
-          <width>211</width>
+          <x>580</x>
+          <y>270</y>
+          <width>191</width>
           <height>20</height>
          </rect>
         </property>
@@ -6414,8 +4795,8 @@
        <widget class="QLabel" name="cur_so4clLabel">
         <property name="geometry">
          <rect>
-          <x>290</x>
-          <y>400</y>
+          <x>311</x>
+          <y>300</y>
           <width>181</width>
           <height>20</height>
          </rect>
@@ -6430,8 +4811,8 @@
        <widget class="QDoubleSpinBox" name="cur_so4clEdit">
         <property name="geometry">
          <rect>
-          <x>480</x>
-          <y>400</y>
+          <x>501</x>
+          <y>300</y>
           <width>71</width>
           <height>24</height>
          </rect>
@@ -6461,9 +4842,9 @@
        <widget class="RangedSlider" name="cur_so4clResult">
         <property name="geometry">
          <rect>
-          <x>559</x>
-          <y>400</y>
-          <width>211</width>
+          <x>580</x>
+          <y>300</y>
+          <width>191</width>
           <height>20</height>
          </rect>
         </property>
@@ -6471,8 +4852,8 @@
        <widget class="QLabel" name="preboil_phLabel">
         <property name="geometry">
          <rect>
-          <x>290</x>
-          <y>430</y>
+          <x>311</x>
+          <y>330</y>
           <width>181</width>
           <height>20</height>
          </rect>
@@ -6487,8 +4868,136 @@
        <widget class="QDoubleSpinBox" name="preboil_phEdit">
         <property name="geometry">
          <rect>
-          <x>480</x>
-          <y>430</y>
+          <x>501</x>
+          <y>330</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_clEdit">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_naEdit">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_caco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_raEdit">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="minimum">
+         <double>-1000.000000000000000</double>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_phShow">
+        <property name="geometry">
+         <rect>
+          <x>880</x>
+          <y>180</y>
           <width>71</width>
           <height>24</height>
          </rect>
@@ -6509,6 +5018,1897 @@
          <double>1000.000000000000000</double>
         </property>
        </widget>
+       <widget class="QDoubleSpinBox" name="sp_so4Edit">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_mgEdit">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_hco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_volEdit">
+        <property name="geometry">
+         <rect>
+          <x>230</x>
+          <y>180</y>
+          <width>81</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The total prepared amount of sparge water</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="accelerated">
+         <bool>true</bool>
+        </property>
+        <property name="suffix">
+         <string> L</string>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>100000.000000000000000</double>
+        </property>
+        <property name="singleStep">
+         <double>0.500000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_hardnessEdit">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_caEdit">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QComboBox" name="wt_sourceEdit">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>150</y>
+          <width>181</width>
+          <height>23</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>If needed, choose a target water profile.</string>
+        </property>
+        <property name="placeholderText">
+         <string>Choose example water</string>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_hardnessEdit">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_so4Edit">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_naEdit">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_raEdit">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="minimum">
+         <double>-1000.000000000000000</double>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_caco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_caEdit">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_clEdit">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_mgEdit">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_hco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_hco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>0 to 50 for light beers, 50 to 150 for amber beers, 150 to 250 for dark beers.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_hardnessEdit">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="treatedLabel">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>120</y>
+          <width>171</width>
+          <height>21</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Treated mash water</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_phEdit">
+        <property name="geometry">
+         <rect>
+          <x>880</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>Mash pH should be between 5.2 and 5.6. Use 5.2 for light and 5.5 for dark beers.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_naEdit">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The ideal amount of Natrium should be below 150.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_caco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_clEdit">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The ideal Chloride amount is between 50 and 150.
+Together with Sulfate it must be below 500.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_caEdit">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The ideal amount of Calcium is between 40 and 150.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_raEdit">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="minimum">
+         <double>-1000.000000000000000</double>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_mgEdit">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The ideal amount of Magnesium is between 5 and 40.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_so4Edit">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The ideal Sulfate amount should be between 50 and 400.
+Together with Chloride it must be below 500.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_hco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_raEdit">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="minimum">
+         <double>-1000.000000000000000</double>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="mixedLabel">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>90</y>
+          <width>171</width>
+          <height>21</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Mixed water</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_caEdit">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_hardnessEdit">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_volEdit">
+        <property name="geometry">
+         <rect>
+          <x>230</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="suffix">
+         <string> L</string>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>100000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_naEdit">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_clEdit">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_mgEdit">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_so4Edit">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_caco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_phEdit">
+        <property name="geometry">
+         <rect>
+          <x>880</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_raEdit">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="minimum">
+         <double>-1000.000000000000000</double>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_caEdit">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_so4Edit">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_mgEdit">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_phEdit">
+        <property name="geometry">
+         <rect>
+          <x>880</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_hardnessEdit">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_volEdit">
+        <property name="geometry">
+         <rect>
+          <x>230</x>
+          <y>60</y>
+          <width>85</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The division between the main and dilution water. The total volume does not change.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>false</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::UpDownArrows</enum>
+        </property>
+        <property name="accelerated">
+         <bool>true</bool>
+        </property>
+        <property name="suffix">
+         <string> L</string>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>100000.000000000000000</double>
+        </property>
+        <property name="singleStep">
+         <double>0.500000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_naEdit">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_clEdit">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QComboBox" name="w2_nameEdit">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>60</y>
+          <width>181</width>
+          <height>23</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>Optional dilution water</string>
+        </property>
+        <property name="placeholderText">
+         <string>Choose dilution</string>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_caco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_hco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_mgEdit">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_hco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="hardnessLabel">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Hardness</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_phEdit">
+        <property name="geometry">
+         <rect>
+          <x>880</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="mgLabel">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Mg</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="phLabel">
+        <property name="geometry">
+         <rect>
+          <x>880</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>pH</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="raLabel">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="font">
+         <font>
+          <weight>50</weight>
+          <italic>false</italic>
+          <bold>false</bold>
+          <underline>false</underline>
+          <strikeout>false</strikeout>
+         </font>
+        </property>
+        <property name="frameShape">
+         <enum>QFrame::NoFrame</enum>
+        </property>
+        <property name="text">
+         <string>RA</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_hardnessEdit">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_volEdit">
+        <property name="geometry">
+         <rect>
+          <x>230</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="accelerated">
+         <bool>false</bool>
+        </property>
+        <property name="suffix">
+         <string> L</string>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>100000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_so4Edit">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="caco3Label">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>CaCO3</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_caco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_raEdit">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="minimum">
+         <double>-1000.000000000000000</double>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QComboBox" name="w1_nameEdit">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>30</y>
+          <width>181</width>
+          <height>23</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The main brewing water</string>
+        </property>
+        <property name="currentText">
+         <string/>
+        </property>
+        <property name="placeholderText">
+         <string>Choose water</string>
+        </property>
+       </widget>
+       <widget class="QLabel" name="clLabel">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Cl</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="naLabel">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Na</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="caLabel">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Ca</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="so4Label">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>SO4</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="volLabel">
+        <property name="geometry">
+         <rect>
+          <x>240</x>
+          <y>10</y>
+          <width>61</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Volume</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="hco3Label">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>HCO3</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="profileLabel">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>10</y>
+          <width>171</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Water profile</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_clEdit">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_caEdit">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_naEdit">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QRadioButton" name="w1_spButton">
+        <property name="geometry">
+         <rect>
+          <x>200</x>
+          <y>30</y>
+          <width>21</width>
+          <height>21</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>Sparge water source 1</string>
+        </property>
+        <property name="checked">
+         <bool>true</bool>
+        </property>
+        <attribute name="buttonGroup">
+         <string notr="true">spargeGroup</string>
+        </attribute>
+       </widget>
+       <widget class="QRadioButton" name="w2_spButton">
+        <property name="enabled">
+         <bool>false</bool>
+        </property>
+        <property name="geometry">
+         <rect>
+          <x>200</x>
+          <y>60</y>
+          <width>21</width>
+          <height>21</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>Sparge water source 2</string>
+        </property>
+        <attribute name="buttonGroup">
+         <string notr="true">spargeGroup</string>
+        </attribute>
+       </widget>
+       <widget class="QRadioButton" name="wg_spButton">
+        <property name="enabled">
+         <bool>false</bool>
+        </property>
+        <property name="geometry">
+         <rect>
+          <x>200</x>
+          <y>90</y>
+          <width>21</width>
+          <height>21</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>Sparge water mixed</string>
+        </property>
+        <attribute name="buttonGroup">
+         <string notr="true">spargeGroup</string>
+        </attribute>
+       </widget>
+       <widget class="QLabel" name="wspLabel">
+        <property name="geometry">
+         <rect>
+          <x>180</x>
+          <y>10</y>
+          <width>61</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Sparge</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="sp_treatedLabel">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>180</y>
+          <width>171</width>
+          <height>21</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Treated sparge water</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
+        </property>
+       </widget>
       </widget>
       <widget class="QWidget" name="brewday">
        <attribute name="title">
@@ -6861,7 +7261,7 @@
           <double>200000.000000000000000</double>
          </property>
         </widget>
-        <widget class="QDoubleSpinBox" name="brew_spargetempShow">
+        <widget class="QDoubleSpinBox" name="brew_spargetempEdit">
          <property name="geometry">
           <rect>
            <x>160</x>
@@ -6874,10 +7274,13 @@
           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
          </property>
          <property name="readOnly">
-          <bool>true</bool>
+          <bool>false</bool>
          </property>
          <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
+          <enum>QAbstractSpinBox::UpDownArrows</enum>
+         </property>
+         <property name="accelerated">
+          <bool>true</bool>
          </property>
          <property name="suffix">
           <string> °C</string>
@@ -6888,6 +7291,9 @@
          <property name="maximum">
           <double>200.000000000000000</double>
          </property>
+         <property name="singleStep">
+          <double>0.500000000000000</double>
+         </property>
         </widget>
         <widget class="QDoubleSpinBox" name="brew_spargephShow">
          <property name="geometry">
@@ -11117,51 +11523,6 @@
   <tabstop>mash_timeEdit</tabstop>
   <tabstop>addMash</tabstop>
   <tabstop>mashsTable</tabstop>
-  <tabstop>w1_nameEdit</tabstop>
-  <tabstop>w1_volEdit</tabstop>
-  <tabstop>w1_caEdit</tabstop>
-  <tabstop>w1_mgEdit</tabstop>
-  <tabstop>w1_hco3Edit</tabstop>
-  <tabstop>w1_caco3Edit</tabstop>
-  <tabstop>w1_naEdit</tabstop>
-  <tabstop>w1_clEdit</tabstop>
-  <tabstop>w1_so4Edit</tabstop>
-  <tabstop>w1_phEdit</tabstop>
-  <tabstop>w2_nameEdit</tabstop>
-  <tabstop>w2_volEdit</tabstop>
-  <tabstop>w2_caEdit</tabstop>
-  <tabstop>w2_mgEdit</tabstop>
-  <tabstop>w2_hco3Edit</tabstop>
-  <tabstop>w2_caco3Edit</tabstop>
-  <tabstop>w2_naEdit</tabstop>
-  <tabstop>w2_clEdit</tabstop>
-  <tabstop>w2_so4Edit</tabstop>
-  <tabstop>w2_phEdit</tabstop>
-  <tabstop>wg_volEdit</tabstop>
-  <tabstop>wg_caEdit</tabstop>
-  <tabstop>wg_mgEdit</tabstop>
-  <tabstop>wg_hco3Edit</tabstop>
-  <tabstop>wg_caco3Edit</tabstop>
-  <tabstop>wg_naEdit</tabstop>
-  <tabstop>wg_clEdit</tabstop>
-  <tabstop>wg_so4Edit</tabstop>
-  <tabstop>wg_phEdit</tabstop>
-  <tabstop>wb_caEdit</tabstop>
-  <tabstop>wb_mgEdit</tabstop>
-  <tabstop>wb_hco3Edit</tabstop>
-  <tabstop>wb_caco3Edit</tabstop>
-  <tabstop>wb_naEdit</tabstop>
-  <tabstop>wb_clEdit</tabstop>
-  <tabstop>wb_so4Edit</tabstop>
-  <tabstop>wb_phEdit</tabstop>
-  <tabstop>wt_sourceEdit</tabstop>
-  <tabstop>wt_caEdit</tabstop>
-  <tabstop>wt_mgEdit</tabstop>
-  <tabstop>wt_hco3Edit</tabstop>
-  <tabstop>wt_caco3Edit</tabstop>
-  <tabstop>wt_naEdit</tabstop>
-  <tabstop>wt_clEdit</tabstop>
-  <tabstop>wt_so4Edit</tabstop>
   <tabstop>bs_cacl2Edit</tabstop>
   <tabstop>bs_caso4Edit</tabstop>
   <tabstop>bs_mgso4Edit</tabstop>
@@ -11174,13 +11535,6 @@
   <tabstop>mw_acidPick</tabstop>
   <tabstop>mw_acidpercEdit</tabstop>
   <tabstop>mw_acidvolEdit</tabstop>
-  <tabstop>sp_volEdit</tabstop>
-  <tabstop>sp_tempEdit</tabstop>
-  <tabstop>sp_sourceEdit</tabstop>
-  <tabstop>sp_phEdit</tabstop>
-  <tabstop>sp_acidtypeEdit</tabstop>
-  <tabstop>sp_acidpercEdit</tabstop>
-  <tabstop>sp_acidvolEdit</tabstop>
   <tabstop>buguEdit</tabstop>
   <tabstop>so4clEdit</tabstop>
   <tabstop>cur_so4clEdit</tabstop>
@@ -11198,7 +11552,7 @@
   <tabstop>brew_mashsgEdit</tabstop>
   <tabstop>brew_mashsgShow</tabstop>
   <tabstop>brew_masheffShow</tabstop>
-  <tabstop>brew_spargetempShow</tabstop>
+  <tabstop>brew_spargetempEdit</tabstop>
   <tabstop>brew_spargevolShow</tabstop>
   <tabstop>brew_spargeestShow</tabstop>
   <tabstop>brew_spargephEdit</tabstop>
@@ -11306,4 +11660,7 @@
   <include location="../../../../../../home/mbroek/MyProjects/bmsapp/resources/icons.qrc"/>
  </resources>
  <connections/>
+ <buttongroups>
+  <buttongroup name="spargeGroup"/>
+ </buttongroups>
 </ui>
--- a/ui/EditRecipe.ui	Sun Jul 17 22:18:48 2022 +0200
+++ b/ui/EditRecipe.ui	Mon Jul 18 17:04:02 2022 +0200
@@ -95,7 +95,7 @@
        <enum>QTabWidget::Rounded</enum>
       </property>
       <property name="currentIndex">
-       <number>0</number>
+       <number>6</number>
       </property>
       <property name="elideMode">
        <enum>Qt::ElideNone</enum>
@@ -2425,1662 +2425,12 @@
        <attribute name="title">
         <string>Water</string>
        </attribute>
-       <widget class="QGroupBox" name="waterviewBox">
-        <property name="geometry">
-         <rect>
-          <x>10</x>
-          <y>0</y>
-          <width>1101</width>
-          <height>221</height>
-         </rect>
-        </property>
-        <property name="autoFillBackground">
-         <bool>false</bool>
-        </property>
-        <property name="title">
-         <string>Water overview</string>
-        </property>
-        <property name="flat">
-         <bool>false</bool>
-        </property>
-        <property name="checkable">
-         <bool>false</bool>
-        </property>
-        <property name="checked">
-         <bool>false</bool>
-        </property>
-        <widget class="QDoubleSpinBox" name="w1_caEdit">
-         <property name="geometry">
-          <rect>
-           <x>300</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_phEdit">
-         <property name="geometry">
-          <rect>
-           <x>860</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_so4Edit">
-         <property name="geometry">
-          <rect>
-           <x>780</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_clEdit">
-         <property name="geometry">
-          <rect>
-           <x>700</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_naEdit">
-         <property name="geometry">
-          <rect>
-           <x>620</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_caco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>540</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_hco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>460</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_mgEdit">
-         <property name="geometry">
-          <rect>
-           <x>380</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QLabel" name="caLabel">
-         <property name="geometry">
-          <rect>
-           <x>300</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Ca</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="mgLabel">
-         <property name="geometry">
-          <rect>
-           <x>380</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Mg</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="hco3Label">
-         <property name="geometry">
-          <rect>
-           <x>460</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>HCO3</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="caco3Label">
-         <property name="geometry">
-          <rect>
-           <x>540</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>CaCO3</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="naLabel">
-         <property name="geometry">
-          <rect>
-           <x>620</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Na</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="clLabel">
-         <property name="geometry">
-          <rect>
-           <x>700</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Cl</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="so4Label">
-         <property name="geometry">
-          <rect>
-           <x>780</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>SO4</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="phLabel">
-         <property name="geometry">
-          <rect>
-           <x>860</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>pH</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_volEdit">
-         <property name="geometry">
-          <rect>
-           <x>200</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="accelerated">
-          <bool>false</bool>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>100000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QLabel" name="volLabel">
-         <property name="geometry">
-          <rect>
-           <x>200</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Volume</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_hco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>460</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_phEdit">
-         <property name="geometry">
-          <rect>
-           <x>860</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_caco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>540</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_naEdit">
-         <property name="geometry">
-          <rect>
-           <x>620</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_so4Edit">
-         <property name="geometry">
-          <rect>
-           <x>780</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_caEdit">
-         <property name="geometry">
-          <rect>
-           <x>300</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_clEdit">
-         <property name="geometry">
-          <rect>
-           <x>700</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_volEdit">
-         <property name="geometry">
-          <rect>
-           <x>200</x>
-           <y>80</y>
-           <width>85</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The division between the main and dilution water. The total volume does not change.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>false</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::UpDownArrows</enum>
-         </property>
-         <property name="accelerated">
-          <bool>true</bool>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>100000.000000000000000</double>
-         </property>
-         <property name="singleStep">
-          <double>0.500000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_mgEdit">
-         <property name="geometry">
-          <rect>
-           <x>380</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_hco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>460</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_phEdit">
-         <property name="geometry">
-          <rect>
-           <x>860</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_caco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>540</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_naEdit">
-         <property name="geometry">
-          <rect>
-           <x>620</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_so4Edit">
-         <property name="geometry">
-          <rect>
-           <x>780</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_caEdit">
-         <property name="geometry">
-          <rect>
-           <x>300</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_clEdit">
-         <property name="geometry">
-          <rect>
-           <x>700</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_volEdit">
-         <property name="geometry">
-          <rect>
-           <x>200</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>100000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_mgEdit">
-         <property name="geometry">
-          <rect>
-           <x>380</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_hco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>460</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_phEdit">
-         <property name="geometry">
-          <rect>
-           <x>860</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>Mash pH should be between 5.2 and 5.6. Use 5.2 for light and 5.5 for dark beers.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>2</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_caco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>540</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_naEdit">
-         <property name="geometry">
-          <rect>
-           <x>620</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_so4Edit">
-         <property name="geometry">
-          <rect>
-           <x>780</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_caEdit">
-         <property name="geometry">
-          <rect>
-           <x>300</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_clEdit">
-         <property name="geometry">
-          <rect>
-           <x>700</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_mgEdit">
-         <property name="geometry">
-          <rect>
-           <x>380</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_mgEdit">
-         <property name="geometry">
-          <rect>
-           <x>380</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The ideal amount of Magnesium is between 5 and 40.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_hco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>460</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>0 to 50 for light beers, 50 to 150 for amber beers, 150 to 250 for dark beers.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_so4Edit">
-         <property name="geometry">
-          <rect>
-           <x>780</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The ideal Sulfate amount should be between 50 and 400.
-Together with Chloride it must be below 500.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_caEdit">
-         <property name="geometry">
-          <rect>
-           <x>300</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The ideal amount of Calcium is between 40 and 150.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_clEdit">
-         <property name="geometry">
-          <rect>
-           <x>700</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The ideal Chloride amount is between 50 and 150.
-Together with Sulfate it must be below 500.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_caco3Edit">
-         <property name="geometry">
-          <rect>
-           <x>540</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_naEdit">
-         <property name="geometry">
-          <rect>
-           <x>620</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The ideal amount of Natrium should be below 150.</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QLabel" name="profileLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>20</y>
-           <width>171</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Water profile</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QComboBox" name="w1_nameEdit">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>50</y>
-           <width>181</width>
-           <height>23</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>The main brewing water</string>
-         </property>
-         <property name="currentText">
-          <string/>
-         </property>
-         <property name="placeholderText">
-          <string>Choose water</string>
-         </property>
-        </widget>
-        <widget class="QComboBox" name="w2_nameEdit">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>80</y>
-           <width>181</width>
-           <height>23</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>Optional dilution water</string>
-         </property>
-         <property name="placeholderText">
-          <string>Choose dilution</string>
-         </property>
-        </widget>
-        <widget class="QComboBox" name="wt_sourceEdit">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>180</y>
-           <width>181</width>
-           <height>23</height>
-          </rect>
-         </property>
-         <property name="toolTip">
-          <string>If needed, choose a target water profile.</string>
-         </property>
-         <property name="placeholderText">
-          <string>Choose example water</string>
-         </property>
-        </widget>
-        <widget class="QLabel" name="mixedLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>110</y>
-           <width>171</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Mixed water</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="treatedLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>140</y>
-           <width>171</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Treated water</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_raEdit">
-         <property name="geometry">
-          <rect>
-           <x>1020</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="minimum">
-          <double>-1000.000000000000000</double>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_hardnessEdit">
-         <property name="geometry">
-          <rect>
-           <x>940</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_raEdit">
-         <property name="geometry">
-          <rect>
-           <x>1020</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="minimum">
-          <double>-1000.000000000000000</double>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wt_hardnessEdit">
-         <property name="geometry">
-          <rect>
-           <x>940</x>
-           <y>180</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w2_hardnessEdit">
-         <property name="geometry">
-          <rect>
-           <x>940</x>
-           <y>80</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wg_raEdit">
-         <property name="geometry">
-          <rect>
-           <x>1020</x>
-           <y>110</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="minimum">
-          <double>-1000.000000000000000</double>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_hardnessEdit">
-         <property name="geometry">
-          <rect>
-           <x>940</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="w1_raEdit">
-         <property name="geometry">
-          <rect>
-           <x>1020</x>
-           <y>50</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="minimum">
-          <double>-1000.000000000000000</double>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QLabel" name="raLabel">
-         <property name="geometry">
-          <rect>
-           <x>1020</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>RA</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_raEdit">
-         <property name="geometry">
-          <rect>
-           <x>1020</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="minimum">
-          <double>-1000.000000000000000</double>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="wb_hardnessEdit">
-         <property name="geometry">
-          <rect>
-           <x>940</x>
-           <y>140</y>
-           <width>71</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="readOnly">
-          <bool>true</bool>
-         </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>1000.000000000000000</double>
-         </property>
-        </widget>
-        <widget class="QLabel" name="hardnessLabel">
-         <property name="geometry">
-          <rect>
-           <x>940</x>
-           <y>20</y>
-           <width>71</width>
-           <height>21</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Hardness</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-       </widget>
        <widget class="QGroupBox" name="brewsaltsBox">
         <property name="geometry">
          <rect>
           <x>10</x>
-          <y>230</y>
-          <width>271</width>
+          <y>220</y>
+          <width>291</width>
           <height>241</height>
          </rect>
         </property>
@@ -4092,7 +2442,7 @@
           <rect>
            <x>10</x>
            <y>20</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -4111,7 +2461,7 @@
           <rect>
            <x>10</x>
            <y>50</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -4130,7 +2480,7 @@
           <rect>
            <x>10</x>
            <y>80</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -4149,7 +2499,7 @@
           <rect>
            <x>10</x>
            <y>110</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -4168,7 +2518,7 @@
           <rect>
            <x>10</x>
            <y>140</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -4187,7 +2537,7 @@
           <rect>
            <x>10</x>
            <y>170</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -4206,7 +2556,7 @@
           <rect>
            <x>10</x>
            <y>200</y>
-           <width>151</width>
+           <width>71</width>
            <height>20</height>
           </rect>
          </property>
@@ -4223,7 +2573,7 @@
         <widget class="QDoubleSpinBox" name="bs_cacl2Edit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>20</y>
            <width>91</width>
            <height>24</height>
@@ -4255,7 +2605,7 @@
         <widget class="QDoubleSpinBox" name="bs_caso4Edit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>50</y>
            <width>91</width>
            <height>24</height>
@@ -4287,7 +2637,7 @@
         <widget class="QDoubleSpinBox" name="bs_mgso4Edit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>80</y>
            <width>91</width>
            <height>24</height>
@@ -4318,7 +2668,7 @@
         <widget class="QDoubleSpinBox" name="bs_naclEdit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>110</y>
            <width>91</width>
            <height>24</height>
@@ -4350,7 +2700,7 @@
         <widget class="QDoubleSpinBox" name="bs_mgcl2Edit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>140</y>
            <width>91</width>
            <height>24</height>
@@ -4381,7 +2731,7 @@
         <widget class="QDoubleSpinBox" name="bs_nahco3Edit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>170</y>
            <width>91</width>
            <height>24</height>
@@ -4412,7 +2762,7 @@
         <widget class="QDoubleSpinBox" name="bs_caco3Edit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>90</x>
            <y>200</y>
            <width>91</width>
            <height>24</height>
@@ -4440,88 +2790,18 @@
           <double>0.100000000000000</double>
          </property>
         </widget>
-       </widget>
-       <widget class="QGroupBox" name="mashBox">
-        <property name="geometry">
-         <rect>
-          <x>350</x>
-          <y>230</y>
-          <width>421</width>
-          <height>91</height>
-         </rect>
-        </property>
-        <property name="title">
-         <string>Mash water</string>
-        </property>
-        <widget class="QLabel" name="mw_phLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>20</y>
-           <width>111</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Desired pH:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="mw_autoLabel">
+        <widget class="QDoubleSpinBox" name="ss_cacl2Edit">
          <property name="geometry">
           <rect>
-           <x>235</x>
+           <x>190</x>
            <y>20</y>
-           <width>141</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Auto calculate:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="mw_acidLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>50</y>
-           <width>111</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Acid to use:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QComboBox" name="mw_acidPick">
-         <property name="geometry">
-          <rect>
-           <x>130</x>
-           <y>50</y>
-           <width>101</width>
-           <height>23</height>
-          </rect>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="mw_phEdit">
-         <property name="geometry">
-          <rect>
-           <x>130</x>
-           <y>20</y>
-           <width>101</width>
+           <width>91</width>
            <height>24</height>
           </rect>
          </property>
          <property name="toolTip">
-          <string>Mash pH should be between 5.2 and 5.6. Use 5.2 for light and 5.5 for dark beers.</string>
+          <string>To change the water profile. This adds Calcium and Chloride.
+To improve sweet style beers.</string>
          </property>
          <property name="alignment">
           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
@@ -4529,59 +2809,63 @@
          <property name="accelerated">
           <bool>true</bool>
          </property>
+         <property name="suffix">
+          <string> gr</string>
+         </property>
          <property name="decimals">
           <number>2</number>
          </property>
          <property name="maximum">
-          <double>14.000000000000000</double>
+          <double>1000.000000000000000</double>
          </property>
          <property name="singleStep">
           <double>0.100000000000000</double>
          </property>
         </widget>
-        <widget class="QDoubleSpinBox" name="mw_acidpercEdit">
+        <widget class="QDoubleSpinBox" name="ss_mgso4Edit">
          <property name="geometry">
           <rect>
-           <x>240</x>
-           <y>50</y>
-           <width>61</width>
+           <x>190</x>
+           <y>80</y>
+           <width>91</width>
            <height>24</height>
           </rect>
          </property>
+         <property name="toolTip">
+          <string>Epsom salt to change the water profile. Use with caution!</string>
+         </property>
          <property name="alignment">
           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
          </property>
-         <property name="readOnly">
+         <property name="accelerated">
           <bool>true</bool>
          </property>
-         <property name="buttonSymbols">
-          <enum>QAbstractSpinBox::NoButtons</enum>
-         </property>
-         <property name="accelerated">
-          <bool>false</bool>
-         </property>
          <property name="suffix">
-          <string>%</string>
+          <string> gr</string>
          </property>
          <property name="decimals">
-          <number>0</number>
+          <number>2</number>
          </property>
          <property name="maximum">
-          <double>100.000000000000000</double>
+          <double>1000.000000000000000</double>
          </property>
          <property name="singleStep">
-          <double>1.000000000000000</double>
+          <double>0.100000000000000</double>
          </property>
         </widget>
-        <widget class="QDoubleSpinBox" name="mw_acidvolEdit">
+        <widget class="QDoubleSpinBox" name="ss_naclEdit">
          <property name="geometry">
           <rect>
-           <x>310</x>
-           <y>50</y>
-           <width>89</width>
+           <x>190</x>
+           <y>110</y>
+           <width>91</width>
            <height>24</height>
           </rect>
          </property>
+         <property name="toolTip">
+          <string>Table salt to change the water profile. This adds Sodium and Chloride.
+Improves the sweetness of the beer. The beer will become salty at high doses.</string>
+         </property>
          <property name="alignment">
           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
          </property>
@@ -4589,100 +2873,105 @@
           <bool>true</bool>
          </property>
          <property name="suffix">
-          <string> ml</string>
+          <string> gr</string>
          </property>
          <property name="decimals">
           <number>2</number>
          </property>
          <property name="maximum">
-          <double>10000.000000000000000</double>
+          <double>1000.000000000000000</double>
          </property>
          <property name="singleStep">
           <double>0.100000000000000</double>
          </property>
         </widget>
-        <widget class="QCheckBox" name="mw_autoEdit">
+        <widget class="QDoubleSpinBox" name="ss_caso4Edit">
          <property name="geometry">
           <rect>
-           <x>385</x>
-           <y>20</y>
-           <width>16</width>
-           <height>21</height>
+           <x>190</x>
+           <y>50</y>
+           <width>91</width>
+           <height>24</height>
           </rect>
          </property>
+         <property name="toolTip">
+          <string>Gypsum to change the water profile. This adds Calcium and Sulfate.
+To improve bitter beers.</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+         <property name="accelerated">
+          <bool>true</bool>
+         </property>
+         <property name="suffix">
+          <string> gr</string>
+         </property>
+         <property name="decimals">
+          <number>2</number>
+         </property>
+         <property name="maximum">
+          <double>1000.000000000000000</double>
+         </property>
+         <property name="singleStep">
+          <double>0.100000000000000</double>
+         </property>
+        </widget>
+        <widget class="QDoubleSpinBox" name="ss_mgcl2Edit">
+         <property name="geometry">
+          <rect>
+           <x>190</x>
+           <y>140</y>
+           <width>91</width>
+           <height>24</height>
+          </rect>
+         </property>
+         <property name="toolTip">
+          <string>Magnesium Chloride</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+         <property name="accelerated">
+          <bool>true</bool>
+         </property>
+         <property name="suffix">
+          <string> gr</string>
+         </property>
+         <property name="decimals">
+          <number>2</number>
+         </property>
+         <property name="maximum">
+          <double>1000.000000000000000</double>
+         </property>
+         <property name="singleStep">
+          <double>0.100000000000000</double>
+         </property>
         </widget>
        </widget>
        <widget class="QGroupBox" name="spargeBox">
         <property name="geometry">
          <rect>
-          <x>840</x>
-          <y>230</y>
-          <width>271</width>
+          <x>780</x>
+          <y>220</y>
+          <width>331</width>
           <height>241</height>
          </rect>
         </property>
         <property name="title">
-         <string>Sparge water</string>
-        </property>
-        <widget class="QLabel" name="sp_volLabel">
+         <string>Acid Additions</string>
+        </property>
+        <widget class="QLabel" name="sp_phLabel">
          <property name="geometry">
           <rect>
            <x>10</x>
-           <y>20</y>
-           <width>151</width>
+           <y>140</y>
+           <width>131</width>
            <height>20</height>
           </rect>
          </property>
          <property name="text">
-          <string>Sparge water supply:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="sp_tempLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>50</y>
-           <width>151</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Sparge temperature:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="sp_sourceLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>80</y>
-           <width>151</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Water source:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
-        <widget class="QLabel" name="sp_phLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>110</y>
-           <width>151</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Desired pH:</string>
+          <string>Desired sparge pH:</string>
          </property>
          <property name="alignment">
           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
@@ -4692,8 +2981,8 @@
          <property name="geometry">
           <rect>
            <x>10</x>
-           <y>140</y>
-           <width>151</width>
+           <y>170</y>
+           <width>131</width>
            <height>20</height>
           </rect>
          </property>
@@ -4704,94 +2993,28 @@
           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
          </property>
         </widget>
-        <widget class="QLabel" name="sp_acidpercLabel">
-         <property name="geometry">
-          <rect>
-           <x>10</x>
-           <y>170</y>
-           <width>151</width>
-           <height>20</height>
-          </rect>
-         </property>
-         <property name="text">
-          <string>Acid strength:</string>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-        </widget>
         <widget class="QLabel" name="sp_acidvolLabel">
          <property name="geometry">
           <rect>
            <x>10</x>
            <y>200</y>
-           <width>151</width>
+           <width>131</width>
            <height>20</height>
           </rect>
          </property>
          <property name="text">
-          <string>Acid needed:</string>
+          <string>Acid amount:</string>
          </property>
          <property name="alignment">
           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
          </property>
         </widget>
-        <widget class="QDoubleSpinBox" name="sp_volEdit">
-         <property name="geometry">
-          <rect>
-           <x>170</x>
-           <y>20</y>
-           <width>91</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="accelerated">
-          <bool>true</bool>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>100000.000000000000000</double>
-         </property>
-         <property name="singleStep">
-          <double>0.500000000000000</double>
-         </property>
-        </widget>
-        <widget class="QDoubleSpinBox" name="sp_tempEdit">
-         <property name="geometry">
-          <rect>
-           <x>170</x>
-           <y>50</y>
-           <width>91</width>
-           <height>24</height>
-          </rect>
-         </property>
-         <property name="alignment">
-          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-         </property>
-         <property name="accelerated">
-          <bool>true</bool>
-         </property>
-         <property name="decimals">
-          <number>1</number>
-         </property>
-         <property name="maximum">
-          <double>100.000000000000000</double>
-         </property>
-         <property name="singleStep">
-          <double>0.500000000000000</double>
-         </property>
-        </widget>
         <widget class="QDoubleSpinBox" name="sp_phEdit">
          <property name="geometry">
           <rect>
-           <x>170</x>
-           <y>110</y>
-           <width>91</width>
+           <x>150</x>
+           <y>140</y>
+           <width>101</width>
            <height>24</height>
           </rect>
          </property>
@@ -4814,9 +3037,9 @@
         <widget class="QDoubleSpinBox" name="sp_acidpercEdit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>260</x>
            <y>170</y>
-           <width>91</width>
+           <width>61</width>
            <height>24</height>
           </rect>
          </property>
@@ -4848,9 +3071,97 @@
         <widget class="QDoubleSpinBox" name="sp_acidvolEdit">
          <property name="geometry">
           <rect>
-           <x>170</x>
+           <x>150</x>
            <y>200</y>
-           <width>91</width>
+           <width>89</width>
+           <height>24</height>
+          </rect>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+         <property name="readOnly">
+          <bool>false</bool>
+         </property>
+         <property name="buttonSymbols">
+          <enum>QAbstractSpinBox::UpDownArrows</enum>
+         </property>
+         <property name="accelerated">
+          <bool>true</bool>
+         </property>
+         <property name="suffix">
+          <string> ml</string>
+         </property>
+         <property name="decimals">
+          <number>2</number>
+         </property>
+         <property name="maximum">
+          <double>10000.000000000000000</double>
+         </property>
+         <property name="singleStep">
+          <double>0.100000000000000</double>
+         </property>
+        </widget>
+        <widget class="QComboBox" name="sp_acidtypeEdit">
+         <property name="geometry">
+          <rect>
+           <x>150</x>
+           <y>170</y>
+           <width>101</width>
+           <height>23</height>
+          </rect>
+         </property>
+        </widget>
+        <widget class="QDoubleSpinBox" name="mw_acidvolEdit">
+         <property name="geometry">
+          <rect>
+           <x>150</x>
+           <y>110</y>
+           <width>89</width>
+           <height>24</height>
+          </rect>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+         <property name="accelerated">
+          <bool>true</bool>
+         </property>
+         <property name="suffix">
+          <string> ml</string>
+         </property>
+         <property name="decimals">
+          <number>2</number>
+         </property>
+         <property name="maximum">
+          <double>10000.000000000000000</double>
+         </property>
+         <property name="singleStep">
+          <double>0.100000000000000</double>
+         </property>
+        </widget>
+        <widget class="QLabel" name="mw_acidvolLabel">
+         <property name="geometry">
+          <rect>
+           <x>10</x>
+           <y>110</y>
+           <width>131</width>
+           <height>20</height>
+          </rect>
+         </property>
+         <property name="text">
+          <string>Acid amount:</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+        </widget>
+        <widget class="QDoubleSpinBox" name="mw_acidpercEdit">
+         <property name="geometry">
+          <rect>
+           <x>260</x>
+           <y>80</y>
+           <width>61</width>
            <height>24</height>
           </rect>
          </property>
@@ -4867,35 +3178,111 @@
           <bool>false</bool>
          </property>
          <property name="suffix">
-          <string> ml</string>
+          <string>%</string>
+         </property>
+         <property name="decimals">
+          <number>0</number>
+         </property>
+         <property name="maximum">
+          <double>100.000000000000000</double>
+         </property>
+         <property name="singleStep">
+          <double>1.000000000000000</double>
+         </property>
+        </widget>
+        <widget class="QComboBox" name="mw_acidPick">
+         <property name="geometry">
+          <rect>
+           <x>150</x>
+           <y>80</y>
+           <width>101</width>
+           <height>23</height>
+          </rect>
+         </property>
+        </widget>
+        <widget class="QLabel" name="mw_acidLabel">
+         <property name="geometry">
+          <rect>
+           <x>10</x>
+           <y>80</y>
+           <width>131</width>
+           <height>20</height>
+          </rect>
+         </property>
+         <property name="text">
+          <string>Acid to use:</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+        </widget>
+        <widget class="QDoubleSpinBox" name="mw_phEdit">
+         <property name="geometry">
+          <rect>
+           <x>150</x>
+           <y>50</y>
+           <width>101</width>
+           <height>24</height>
+          </rect>
+         </property>
+         <property name="toolTip">
+          <string>Mash pH should be between 5.2 and 5.6. Use 5.2 for light and 5.5 for dark beers.</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+         <property name="accelerated">
+          <bool>true</bool>
          </property>
          <property name="decimals">
           <number>2</number>
          </property>
          <property name="maximum">
-          <double>10000.000000000000000</double>
+          <double>14.000000000000000</double>
          </property>
          <property name="singleStep">
           <double>0.100000000000000</double>
          </property>
         </widget>
-        <widget class="QComboBox" name="sp_sourceEdit">
+        <widget class="QLabel" name="mw_phLabel">
+         <property name="geometry">
+          <rect>
+           <x>10</x>
+           <y>50</y>
+           <width>131</width>
+           <height>20</height>
+          </rect>
+         </property>
+         <property name="text">
+          <string>Desired mash pH:</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
+        </widget>
+        <widget class="QLabel" name="mw_autoLabel">
          <property name="geometry">
           <rect>
-           <x>170</x>
-           <y>80</y>
-           <width>91</width>
-           <height>23</height>
+           <x>0</x>
+           <y>20</y>
+           <width>141</width>
+           <height>20</height>
           </rect>
          </property>
+         <property name="text">
+          <string>Auto calculate:</string>
+         </property>
+         <property name="alignment">
+          <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+         </property>
         </widget>
-        <widget class="QComboBox" name="sp_acidtypeEdit">
+        <widget class="QCheckBox" name="mw_autoEdit">
          <property name="geometry">
           <rect>
-           <x>170</x>
-           <y>140</y>
-           <width>91</width>
-           <height>23</height>
+           <x>150</x>
+           <y>20</y>
+           <width>16</width>
+           <height>21</height>
           </rect>
          </property>
         </widget>
@@ -4903,8 +3290,8 @@
        <widget class="QLabel" name="buguLabel">
         <property name="geometry">
          <rect>
-          <x>290</x>
-          <y>340</y>
+          <x>310</x>
+          <y>240</y>
           <width>181</width>
           <height>20</height>
          </rect>
@@ -4919,8 +3306,8 @@
        <widget class="QDoubleSpinBox" name="buguEdit">
         <property name="geometry">
          <rect>
-          <x>480</x>
-          <y>340</y>
+          <x>500</x>
+          <y>240</y>
           <width>71</width>
           <height>24</height>
          </rect>
@@ -4950,9 +3337,9 @@
        <widget class="QLabel" name="buguResult">
         <property name="geometry">
          <rect>
-          <x>560</x>
-          <y>340</y>
-          <width>211</width>
+          <x>580</x>
+          <y>240</y>
+          <width>191</width>
           <height>20</height>
          </rect>
         </property>
@@ -4971,8 +3358,8 @@
        <widget class="QLabel" name="so4clLabel">
         <property name="geometry">
          <rect>
-          <x>290</x>
-          <y>370</y>
+          <x>310</x>
+          <y>270</y>
           <width>181</width>
           <height>20</height>
          </rect>
@@ -4987,8 +3374,8 @@
        <widget class="QDoubleSpinBox" name="so4clEdit">
         <property name="geometry">
          <rect>
-          <x>480</x>
-          <y>370</y>
+          <x>500</x>
+          <y>270</y>
           <width>71</width>
           <height>24</height>
          </rect>
@@ -5018,9 +3405,9 @@
        <widget class="QLabel" name="so4clResult">
         <property name="geometry">
          <rect>
-          <x>560</x>
-          <y>370</y>
-          <width>211</width>
+          <x>580</x>
+          <y>270</y>
+          <width>191</width>
           <height>20</height>
          </rect>
         </property>
@@ -5039,8 +3426,8 @@
        <widget class="QLabel" name="cur_so4clLabel">
         <property name="geometry">
          <rect>
-          <x>290</x>
-          <y>400</y>
+          <x>310</x>
+          <y>300</y>
           <width>181</width>
           <height>20</height>
          </rect>
@@ -5055,8 +3442,8 @@
        <widget class="QDoubleSpinBox" name="cur_so4clEdit">
         <property name="geometry">
          <rect>
-          <x>480</x>
-          <y>400</y>
+          <x>500</x>
+          <y>300</y>
           <width>71</width>
           <height>24</height>
          </rect>
@@ -5086,9 +3473,9 @@
        <widget class="RangedSlider" name="cur_so4clResult">
         <property name="geometry">
          <rect>
-          <x>559</x>
-          <y>400</y>
-          <width>211</width>
+          <x>579</x>
+          <y>300</y>
+          <width>191</width>
           <height>20</height>
          </rect>
         </property>
@@ -5096,8 +3483,8 @@
        <widget class="QLabel" name="preboil_phLabel">
         <property name="geometry">
          <rect>
-          <x>290</x>
-          <y>430</y>
+          <x>310</x>
+          <y>330</y>
           <width>181</width>
           <height>20</height>
          </rect>
@@ -5112,8 +3499,972 @@
        <widget class="QDoubleSpinBox" name="preboil_phEdit">
         <property name="geometry">
          <rect>
+          <x>500</x>
+          <y>330</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_naEdit">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_so4Edit">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_hco3Edit">
+        <property name="geometry">
+         <rect>
           <x>480</x>
-          <y>430</y>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QComboBox" name="wt_sourceEdit">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>150</y>
+          <width>181</width>
+          <height>23</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>If needed, choose a target water profile.</string>
+        </property>
+        <property name="placeholderText">
+         <string>Choose example water</string>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_raEdit">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="minimum">
+         <double>-1000.000000000000000</double>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_clEdit">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_hardnessEdit">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_caEdit">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_mgEdit">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wt_caco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>150</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_caco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_so4Edit">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The ideal Sulfate amount should be between 50 and 400.
+Together with Chloride it must be below 500.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_caEdit">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The ideal amount of Calcium is between 40 and 150.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_hco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>0 to 50 for light beers, 50 to 150 for amber beers, 150 to 250 for dark beers.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_hardnessEdit">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_clEdit">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The ideal Chloride amount is between 50 and 150.
+Together with Sulfate it must be below 500.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_phEdit">
+        <property name="geometry">
+         <rect>
+          <x>880</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>Mash pH should be between 5.2 and 5.6. Use 5.2 for light and 5.5 for dark beers.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_raEdit">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="minimum">
+         <double>-1000.000000000000000</double>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_mgEdit">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The ideal amount of Magnesium is between 5 and 40.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="treatedLabel">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>120</y>
+          <width>171</width>
+          <height>21</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Treated mash water</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wb_naEdit">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>120</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The ideal amount of Natrium should be below 150.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="mixedLabel">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>90</y>
+          <width>171</width>
+          <height>21</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Mixed water</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_hco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_volEdit">
+        <property name="geometry">
+         <rect>
+          <x>230</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>100000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_hco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_clEdit">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_hardnessEdit">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_volEdit">
+        <property name="geometry">
+         <rect>
+          <x>230</x>
+          <y>60</y>
+          <width>85</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The division between the main and dilution water. The total volume does not change.</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>false</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::UpDownArrows</enum>
+        </property>
+        <property name="accelerated">
+         <bool>true</bool>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>100000.000000000000000</double>
+        </property>
+        <property name="singleStep">
+         <double>0.500000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_hardnessEdit">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_raEdit">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="minimum">
+         <double>-1000.000000000000000</double>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_caco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_naEdit">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_caEdit">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_naEdit">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_caEdit">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_so4Edit">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_so4Edit">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_phEdit">
+        <property name="geometry">
+         <rect>
+          <x>880</x>
+          <y>60</y>
           <width>71</width>
           <height>24</height>
          </rect>
@@ -5134,6 +4485,1040 @@
          <double>1000.000000000000000</double>
         </property>
        </widget>
+       <widget class="QDoubleSpinBox" name="wg_mgEdit">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_clEdit">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_phEdit">
+        <property name="geometry">
+         <rect>
+          <x>880</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_caco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w2_mgEdit">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>60</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="wg_raEdit">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>90</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="minimum">
+         <double>-1000.000000000000000</double>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QComboBox" name="w2_nameEdit">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>60</y>
+          <width>181</width>
+          <height>23</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>Optional dilution water</string>
+        </property>
+        <property name="placeholderText">
+         <string>Choose dilution</string>
+        </property>
+       </widget>
+       <widget class="QLabel" name="so4Label">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>SO4</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QComboBox" name="w1_nameEdit">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>30</y>
+          <width>181</width>
+          <height>23</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The main brewing water</string>
+        </property>
+        <property name="currentText">
+         <string/>
+        </property>
+        <property name="placeholderText">
+         <string>Choose water</string>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_clEdit">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="hardnessLabel">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Hardness</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="caco3Label">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>CaCO3</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="caLabel">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Ca</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="hco3Label">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>HCO3</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_so4Edit">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_naEdit">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_raEdit">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="minimum">
+         <double>-1000.000000000000000</double>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="phLabel">
+        <property name="geometry">
+         <rect>
+          <x>880</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>pH</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="profileLabel">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>10</y>
+          <width>171</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Water profile</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_hco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_volEdit">
+        <property name="geometry">
+         <rect>
+          <x>230</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="accelerated">
+         <bool>false</bool>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>100000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="volLabel">
+        <property name="geometry">
+         <rect>
+          <x>230</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Volume</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_hardnessEdit">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_caEdit">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_mgEdit">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_phEdit">
+        <property name="geometry">
+         <rect>
+          <x>880</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="naLabel">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Na</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="raLabel">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>RA</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="clLabel">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Cl</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QLabel" name="mgLabel">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>10</y>
+          <width>71</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Mg</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="w1_caco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>30</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_raEdit">
+        <property name="geometry">
+         <rect>
+          <x>1040</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="minimum">
+         <double>-1000.000000000000000</double>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_caEdit">
+        <property name="geometry">
+         <rect>
+          <x>320</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="sp_treatedLabel">
+        <property name="geometry">
+         <rect>
+          <x>10</x>
+          <y>180</y>
+          <width>171</width>
+          <height>21</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Treated sparge water</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_mgEdit">
+        <property name="geometry">
+         <rect>
+          <x>400</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_naEdit">
+        <property name="geometry">
+         <rect>
+          <x>640</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_hco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>480</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_so4Edit">
+        <property name="geometry">
+         <rect>
+          <x>800</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_hardnessEdit">
+        <property name="geometry">
+         <rect>
+          <x>960</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_volEdit">
+        <property name="geometry">
+         <rect>
+          <x>230</x>
+          <y>180</y>
+          <width>81</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>The total prepared amount of sparge water</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="accelerated">
+         <bool>true</bool>
+        </property>
+        <property name="suffix">
+         <string> L</string>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>100000.000000000000000</double>
+        </property>
+        <property name="singleStep">
+         <double>0.500000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_caco3Edit">
+        <property name="geometry">
+         <rect>
+          <x>560</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_phShow">
+        <property name="geometry">
+         <rect>
+          <x>880</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>2</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QDoubleSpinBox" name="sp_clEdit">
+        <property name="geometry">
+         <rect>
+          <x>720</x>
+          <y>180</y>
+          <width>71</width>
+          <height>24</height>
+         </rect>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="readOnly">
+         <bool>true</bool>
+        </property>
+        <property name="buttonSymbols">
+         <enum>QAbstractSpinBox::NoButtons</enum>
+        </property>
+        <property name="decimals">
+         <number>1</number>
+        </property>
+        <property name="maximum">
+         <double>1000.000000000000000</double>
+        </property>
+       </widget>
+       <widget class="QLabel" name="wspLabel">
+        <property name="geometry">
+         <rect>
+          <x>180</x>
+          <y>10</y>
+          <width>61</width>
+          <height>20</height>
+         </rect>
+        </property>
+        <property name="text">
+         <string>Sparge</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignCenter</set>
+        </property>
+       </widget>
+       <widget class="QRadioButton" name="wg_spButton">
+        <property name="enabled">
+         <bool>false</bool>
+        </property>
+        <property name="geometry">
+         <rect>
+          <x>200</x>
+          <y>90</y>
+          <width>21</width>
+          <height>21</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>Sparge water mixed</string>
+        </property>
+        <attribute name="buttonGroup">
+         <string notr="true">spargeGroup</string>
+        </attribute>
+       </widget>
+       <widget class="QRadioButton" name="w1_spButton">
+        <property name="geometry">
+         <rect>
+          <x>200</x>
+          <y>30</y>
+          <width>21</width>
+          <height>21</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>Sparge water source 1</string>
+        </property>
+        <property name="checked">
+         <bool>true</bool>
+        </property>
+        <attribute name="buttonGroup">
+         <string notr="true">spargeGroup</string>
+        </attribute>
+       </widget>
+       <widget class="QRadioButton" name="w2_spButton">
+        <property name="enabled">
+         <bool>false</bool>
+        </property>
+        <property name="geometry">
+         <rect>
+          <x>200</x>
+          <y>60</y>
+          <width>21</width>
+          <height>21</height>
+         </rect>
+        </property>
+        <property name="toolTip">
+         <string>Sparge water source 2</string>
+        </property>
+        <attribute name="buttonGroup">
+         <string notr="true">spargeGroup</string>
+        </attribute>
+       </widget>
       </widget>
      </widget>
      <widget class="QPushButton" name="exportButton">
@@ -5190,4 +5575,7 @@
   <include location="../../../../../../home/mbroek/MyProjects/bmsapp/resources/icons.qrc"/>
  </resources>
  <connections/>
+ <buttongroups>
+  <buttongroup name="spargeGroup"/>
+ </buttongroups>
 </ui>

mercurial