Fix regression. Closes #111

Enable Pattern label position options when load not empty label template.
This commit is contained in:
Roman Telezhynskyi 2021-03-26 17:50:10 +02:00
parent e4674f6058
commit 45649f5178

View File

@ -375,6 +375,7 @@ void DialogSeamAllowance::SetPiece(const VPiece &piece)
SetDLAngle(ppData.GetRotation());
const VPatternLabelData &patternInfo = piece.GetPatternInfo();
uiTabLabels->groupBoxPatternLabel->setEnabled(not m_doc->GetPatternLabelTemplate().isEmpty());
uiTabLabels->groupBoxPatternLabel->setChecked(patternInfo.IsVisible());
ChangeCurrentData(uiTabLabels->comboBoxPLCenterPin, patternInfo.CenterPin());
ChangeCurrentData(uiTabLabels->comboBoxPLTopLeftPin, patternInfo.TopLeftPin());
@ -3862,6 +3863,7 @@ void DialogSeamAllowance::EditPatternLabel()
if (QDialog::Accepted == editor.exec())
{
m_patternTemplateLines = editor.GetTemplate();
uiTabLabels->groupBoxPatternLabel->setEnabled(not m_patternTemplateLines.isEmpty());
m_patternTemplateDataChanged = true;
}
}