25 , m_ui(new
Ui::WGConfigWidget)
26 , m_shadeLineGroup(new QButtonGroup(this))
35 m_ui->btnSelectorShape, SLOT(hidePopupWidget()));
96 cfg.setCustomSelectionColorSpace(
m_ui->wdgColorspace->currentColorSpace());
112 lineConfig.resize(
m_ui->sbShadeLineCount->value());
113 cfg.setShadeSelectorLines(lineConfig);
128 m_ui->sbCommonColorsPatchHeight->value() });
154 : cfg.colorSelectorConfiguration();
164 m_ui->wdgColorspace->setCurrentColorSpace(cfg.customSelectionColorSpace(defaults));
169 if (patchOrientation == Qt::Horizontal) {
170 m_ui->rbPopupHorizontal->setChecked(
true);
172 m_ui->rbPopupVertical->setChecked(
true);
175 m_ui->sbPatchWidth->setValue(colorPatchSize.width());
176 m_ui->sbPatchHeight->setValue(colorPatchSize.height());
196 if (patchOrientation == Qt::Horizontal) {
197 m_ui->rbHistoryHorizontal->setChecked(
true);
199 m_ui->rbHistoryVertical->setChecked(
true);
202 m_ui->sbHistoryPatchWidth->setValue(colorPatchSize.width());
203 m_ui->sbHistoryPatchHeight->setValue(colorPatchSize.height());
211 if (patchOrientation == Qt::Horizontal) {
212 m_ui->rbCommonColorsHorizontal->setChecked(
true);
214 m_ui->rbCommonColorsVertical->setChecked(
true);
217 m_ui->sbCommonColorsPatchWidth->setValue(colorPatchSize.width());
218 m_ui->sbCommonColorsPatchHeight->setValue(colorPatchSize.height());
308 QLayout* layout =
new QVBoxLayout(
this);
313 QDialogButtonBox* buttonBox =
new QDialogButtonBox(QDialogButtonBox::Ok|QDialogButtonBox::Cancel|QDialogButtonBox::RestoreDefaults,
316 layout->addWidget(buttonBox);
318 connect(buttonBox, SIGNAL(accepted()),
m_widget, SLOT(savePreferences()));
319 connect(buttonBox, SIGNAL(accepted()),
this, SLOT(accept()));
320 connect(buttonBox, SIGNAL(rejected()),
this, SLOT(reject()));
321 connect(buttonBox->button(QDialogButtonBox::RestoreDefaults),
322 SIGNAL(clicked()),
m_widget, SLOT(loadDefaultPreferences()));