A seam allowance value can be 0.
--HG-- branch : feature
This commit is contained in:
parent
d7d9deb536
commit
19400f5b83
|
@ -376,7 +376,7 @@ void DialogPiecePath::EvalWidth()
|
||||||
labelEditFormula = ui->labelEditWidth;
|
labelEditFormula = ui->labelEditWidth;
|
||||||
const QString postfix = VDomDocument::UnitsToStr(qApp->patternUnit(), true);
|
const QString postfix = VDomDocument::UnitsToStr(qApp->patternUnit(), true);
|
||||||
const QString formula = ui->plainTextEditFormulaWidth->toPlainText();
|
const QString formula = ui->plainTextEditFormulaWidth->toPlainText();
|
||||||
m_saWidth = Eval(formula, flagFormula, ui->labelResultWidth, postfix, true, true);
|
m_saWidth = Eval(formula, flagFormula, ui->labelResultWidth, postfix, false, true);
|
||||||
|
|
||||||
if (m_saWidth >= 0)
|
if (m_saWidth >= 0)
|
||||||
{
|
{
|
||||||
|
@ -397,7 +397,7 @@ void DialogPiecePath::EvalWidthBefore()
|
||||||
const QString postfix = VDomDocument::UnitsToStr(qApp->patternUnit(), true);
|
const QString postfix = VDomDocument::UnitsToStr(qApp->patternUnit(), true);
|
||||||
const QString formula = ui->plainTextEditFormulaWidthBefore->toPlainText();
|
const QString formula = ui->plainTextEditFormulaWidthBefore->toPlainText();
|
||||||
bool flagFormula = false; // fake flag
|
bool flagFormula = false; // fake flag
|
||||||
Eval(formula, flagFormula, ui->labelResultBefore, postfix, true, true);
|
Eval(formula, flagFormula, ui->labelResultBefore, postfix, false, true);
|
||||||
|
|
||||||
UpdateNodeSABefore(GetFormulaSAWidthBefore());
|
UpdateNodeSABefore(GetFormulaSAWidthBefore());
|
||||||
}
|
}
|
||||||
|
@ -409,7 +409,7 @@ void DialogPiecePath::EvalWidthAfter()
|
||||||
const QString postfix = VDomDocument::UnitsToStr(qApp->patternUnit(), true);
|
const QString postfix = VDomDocument::UnitsToStr(qApp->patternUnit(), true);
|
||||||
const QString formula = ui->plainTextEditFormulaWidthAfter->toPlainText();
|
const QString formula = ui->plainTextEditFormulaWidthAfter->toPlainText();
|
||||||
bool flagFormula = false; // fake flag
|
bool flagFormula = false; // fake flag
|
||||||
Eval(formula, flagFormula, ui->labelResultAfter, postfix, true, true);
|
Eval(formula, flagFormula, ui->labelResultAfter, postfix, false, true);
|
||||||
|
|
||||||
UpdateNodeSABefore(GetFormulaSAWidthAfter());
|
UpdateNodeSABefore(GetFormulaSAWidthAfter());
|
||||||
}
|
}
|
||||||
|
|
|
@ -1081,7 +1081,7 @@ void DialogSeamAllowance::EvalWidth()
|
||||||
labelEditFormula = ui->labelEditWidth;
|
labelEditFormula = ui->labelEditWidth;
|
||||||
const QString postfix = VDomDocument::UnitsToStr(qApp->patternUnit(), true);
|
const QString postfix = VDomDocument::UnitsToStr(qApp->patternUnit(), true);
|
||||||
const QString formula = ui->plainTextEditFormulaWidth->toPlainText();
|
const QString formula = ui->plainTextEditFormulaWidth->toPlainText();
|
||||||
m_saWidth = Eval(formula, flagFormula, ui->labelResultWidth, postfix, true, true);
|
m_saWidth = Eval(formula, flagFormula, ui->labelResultWidth, postfix, false, true);
|
||||||
|
|
||||||
if (m_saWidth >= 0)
|
if (m_saWidth >= 0)
|
||||||
{
|
{
|
||||||
|
@ -1102,7 +1102,7 @@ void DialogSeamAllowance::EvalWidthBefore()
|
||||||
const QString postfix = VDomDocument::UnitsToStr(qApp->patternUnit(), true);
|
const QString postfix = VDomDocument::UnitsToStr(qApp->patternUnit(), true);
|
||||||
const QString formula = ui->plainTextEditFormulaWidthBefore->toPlainText();
|
const QString formula = ui->plainTextEditFormulaWidthBefore->toPlainText();
|
||||||
bool flagFormula = false; // fake flag
|
bool flagFormula = false; // fake flag
|
||||||
Eval(formula, flagFormula, ui->labelResultBefore, postfix, true, true);
|
Eval(formula, flagFormula, ui->labelResultBefore, postfix, false, true);
|
||||||
|
|
||||||
UpdateNodeSABefore(GetFormulaSAWidthBefore());
|
UpdateNodeSABefore(GetFormulaSAWidthBefore());
|
||||||
}
|
}
|
||||||
|
@ -1114,7 +1114,7 @@ void DialogSeamAllowance::EvalWidthAfter()
|
||||||
const QString postfix = VDomDocument::UnitsToStr(qApp->patternUnit(), true);
|
const QString postfix = VDomDocument::UnitsToStr(qApp->patternUnit(), true);
|
||||||
const QString formula = ui->plainTextEditFormulaWidthAfter->toPlainText();
|
const QString formula = ui->plainTextEditFormulaWidthAfter->toPlainText();
|
||||||
bool flagFormula = false; // fake flag
|
bool flagFormula = false; // fake flag
|
||||||
Eval(formula, flagFormula, ui->labelResultAfter, postfix, true, true);
|
Eval(formula, flagFormula, ui->labelResultAfter, postfix, false, true);
|
||||||
|
|
||||||
UpdateNodeSAAfter(GetFormulaSAWidthAfter());
|
UpdateNodeSAAfter(GetFormulaSAWidthAfter());
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user