From a4e2e1f1bffc975cca5dde9c9c1080cfb2dcdd93 Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Sat, 6 Apr 2024 11:54:37 +0300 Subject: [PATCH] Disable piece gap if option Sticky edges is not active. --- src/app/puzzle/vpmainwindow.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/app/puzzle/vpmainwindow.cpp b/src/app/puzzle/vpmainwindow.cpp index 8ac7fd5dd..ab2a1469b 100644 --- a/src/app/puzzle/vpmainwindow.cpp +++ b/src/app/puzzle/vpmainwindow.cpp @@ -1246,6 +1246,8 @@ void VPMainWindow::InitPropertyTabLayout() connect(ui->checkBoxSheetStickyEdges, &QCheckBox::toggled, this, [this](bool checked) { + ui->doubleSpinBoxSheetPiecesGap->setEnabled(checked); + if (not m_layout.isNull()) { m_layout->LayoutSettings().SetStickyEdges(checked); @@ -1607,6 +1609,7 @@ void VPMainWindow::SetPropertyTabLayoutData() SetDoubleSpinBoxValue(ui->doubleSpinBoxSheetPiecesGap, m_layout->LayoutSettings().GetPiecesGapConverted()); ui->doubleSpinBoxSheetPiecesGap->setSuffix(" " + UnitsToStr(LayoutUnit(), true)); + ui->doubleSpinBoxSheetPiecesGap->setEnabled(ui->checkBoxSheetStickyEdges->isChecked()); ui->groupBoxLayoutScale->setDisabled(false);