kcms/colors: rephrase UI to indicate changes to colorsapplicator (previous commit)

wilder-5.26
Jan Blackquill 4 years ago committed by Nate Graham
parent a671178a8f
commit 75d4b69da1
  1. 20
      kcms/colors/editor/scmeditoroptions.cpp
  2. 3
      kcms/colors/editor/scmeditoroptions.h
  3. 21
      kcms/colors/editor/scmeditoroptions.ui

@ -31,8 +31,7 @@ void SchemeEditorOptions::loadOptions()
KConfigGroup generalGroup(m_config, "General"); KConfigGroup generalGroup(m_config, "General");
shadeSortedColumn->setChecked(generalGroup.readEntry("shadeSortColumn", true)); shadeSortedColumn->setChecked(generalGroup.readEntry("shadeSortColumn", true));
accentActiveTitlebar->setChecked(generalGroup.readEntry("accentActiveTitlebar", false)); accentTitlebar->setChecked(generalGroup.readEntry("TitlebarIsAccentColored", generalGroup.readEntry("accentActiveTitlebar", false)));
accentInactiveTitlebar->setChecked(generalGroup.readEntry("accentInactiveTitlebar", false));
KConfigGroup KDEgroup(m_config, "KDE"); KConfigGroup KDEgroup(m_config, "KDE");
contrastSlider->setValue(KDEgroup.readEntry("contrast", KColorScheme::contrastF() * 10)); contrastSlider->setValue(KDEgroup.readEntry("contrast", KColorScheme::contrastF() * 10));
@ -120,24 +119,15 @@ void SchemeEditorOptions::on_inactiveSelectionEffect_stateChanged(int state)
Q_EMIT changed(true); Q_EMIT changed(true);
} }
void SchemeEditorOptions::on_accentActiveTitlebar_stateChanged(int state) void SchemeEditorOptions::on_accentTitlebar_stateChanged(int state)
{ {
if (m_disableUpdates) if (m_disableUpdates)
return; return;
KConfigGroup group(m_config, "General"); KConfigGroup group(m_config, "General");
group.writeEntry("accentActiveTitlebar", bool(state == Qt::Checked)); group.writeEntry("TitlebarIsAccentColored", bool(state == Qt::Checked));
group.deleteEntry("accentActiveTitlebar");
Q_EMIT changed(true); group.deleteEntry("accentInactiveTitlebar");
}
void SchemeEditorOptions::on_accentInactiveTitlebar_stateChanged(int state)
{
if (m_disableUpdates)
return;
KConfigGroup group(m_config, "General");
group.writeEntry("accentInactiveTitlebar", bool(state == Qt::Checked));
Q_EMIT changed(true); Q_EMIT changed(true);
} }

@ -33,8 +33,7 @@ private Q_SLOTS:
void on_shadeSortedColumn_stateChanged(int state); void on_shadeSortedColumn_stateChanged(int state);
void on_inactiveSelectionEffect_stateChanged(int state); void on_inactiveSelectionEffect_stateChanged(int state);
void on_useInactiveEffects_stateChanged(int state); void on_useInactiveEffects_stateChanged(int state);
void on_accentActiveTitlebar_stateChanged(int state); void on_accentTitlebar_stateChanged(int state);
void on_accentInactiveTitlebar_stateChanged(int state);
void on_tintColors_stateChanged(int state); void on_tintColors_stateChanged(int state);
void on_tintStrengthSlider_valueChanged(int value); void on_tintStrengthSlider_valueChanged(int value);

@ -7,7 +7,7 @@
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>464</width> <width>464</width>
<height>382</height> <height>436</height>
</rect> </rect>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
@ -26,30 +26,23 @@
</widget> </widget>
</item> </item>
<item> <item>
<widget class="QCheckBox" name="accentActiveTitlebar"> <widget class="QCheckBox" name="shadeSortedColumn">
<property name="text">
<string>Apply a&amp;ccent color to active window titlebars</string>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="accentInactiveTitlebar">
<property name="text"> <property name="text">
<string>Apply acce&amp;nt color to inactive window titlebars</string> <string>Shade sorted column &amp;in lists</string>
</property> </property>
</widget> </widget>
</item> </item>
<item> <item>
<widget class="QCheckBox" name="shadeSortedColumn"> <widget class="QCheckBox" name="tintColors">
<property name="text"> <property name="text">
<string>Shade sorted column &amp;in lists</string> <string>Tint all colors with accent color</string>
</property> </property>
</widget> </widget>
</item> </item>
<item> <item>
<widget class="QCheckBox" name="tintColors"> <widget class="QCheckBox" name="accentTitlebar">
<property name="text"> <property name="text">
<string>Tint all colors with accent color</string> <string>Make window titlebars a&amp;ccent-colored</string>
</property> </property>
</widget> </widget>
</item> </item>

Loading…
Cancel
Save