diff --git a/kcmkwin/kwinoptions/windows.cpp b/kcmkwin/kwinoptions/windows.cpp index fd65ecc691..bfe7e237d5 100644 --- a/kcmkwin/kwinoptions/windows.cpp +++ b/kcmkwin/kwinoptions/windows.cpp @@ -1198,16 +1198,17 @@ KTranslucencyConfig::KTranslucencyConfig (bool _standAlone, KConfig *_config, QW QVBoxLayout *vLay = new QVBoxLayout (tGroup,KDialog::marginHint(), KDialog::spacingHint()); vLay->addSpacing(11); // to get the proper gb top offset -// QHBoxLayout *hLay = new QHBoxLayout(vLay); -// QLabel *label0 = new QLabel(i18n("Apply translucency on"),tGroup); -// hLay->addWidget(label0); -// transMode = new QComboBox(tGroup); -// transMode->insertItem ("i18n(The whole window)"); -// transMode->insertItem ("i18n(The titlebar only)"); -// transMode->insertItem ("i18n(The content only)"); -// hLay->addWidget(transMode); + QHBoxLayout *hLay = new QHBoxLayout(vLay); + QLabel *label0 = new QLabel(i18n("Apply translucency on"),tGroup); + hLay->addWidget(label0); + transMode = new QComboBox(tGroup); + transMode->insertItem (i18n("The whole window")); + transMode->insertItem (i18n("The titlebar only")); + transMode->insertItem (i18n("The content only")); + hLay->addWidget(transMode); + hLay->addStretch(); -// vLay->addSpacing(11); + vLay->addSpacing(11); QGridLayout *gLay = new QGridLayout(vLay,4,2,KDialog::spacingHint()); gLay->setColStretch(1,1); @@ -1249,7 +1250,7 @@ KTranslucencyConfig::KTranslucencyConfig (bool _standAlone, KConfig *_config, QW vLay->addWidget(disableARGB); vLay->addStretch(); - tabW->addTab(tGroup, i18n("Translucency")); + tabW->addTab(tGroup, i18n("Opacity")); QWidget *sGroup = new QWidget(tabW); // sGroup->setCheckable(TRUE); @@ -1342,7 +1343,7 @@ KTranslucencyConfig::KTranslucencyConfig (bool _standAlone, KConfig *_config, QW connect(dockWindowTransparency, SIGNAL(toggled(bool)), dockWindowOpacity, SLOT(setEnabled(bool))); connect(useTranslucency, SIGNAL(toggled(bool)), SLOT(changed())); -// connect(transMode, SIGNAL(activated(int)), SLOT(changed())); + connect(transMode, SIGNAL(activated(int)), SLOT(changed())); connect(activeWindowTransparency, SIGNAL(toggled(bool)), SLOT(changed())); connect(inactiveWindowTransparency, SIGNAL(toggled(bool)), SLOT(changed())); connect(movingWindowTransparency, SIGNAL(toggled(bool)), SLOT(changed())); @@ -1383,7 +1384,7 @@ KTranslucencyConfig::KTranslucencyConfig (bool _standAlone, KConfig *_config, QW // handle kompmgr restarts if necessary connect(useTranslucency, SIGNAL(toggled(bool)), SLOT(resetKompmgr())); -// connect(transMode, SIGNAL(activated(int)), SLOT(resetKompmgr())); + connect(transMode, SIGNAL(activated(int)), SLOT(resetKompmgr())); connect(disableARGB, SIGNAL(toggled(bool)), SLOT(resetKompmgr())); connect(useShadows, SIGNAL(toggled(bool)), SLOT(resetKompmgr())); connect(inactiveWindowShadowSize, SIGNAL(valueChanged(int)), SLOT(resetKompmgr())); @@ -1437,8 +1438,8 @@ void KTranslucencyConfig::load( void ) KConfig conf_(QDir::homeDirPath() + "/.xcompmgrrc"); conf_.setGroup("xcompmgr"); -// QString modeString = conf_.readEntry("TransMode","All"); -// transMode->setCurrentItem(!modeString.compare("Content")?2:!modeString.compare("Title")?1:0); + QString modeString = conf_.readEntry("TransMode","All"); + transMode->setCurrentItem(!modeString.compare("Content")?2:!modeString.compare("Title")?1:0); disableARGB->setChecked(conf_.readBoolEntry("DisableARGB",FALSE)); @@ -1504,7 +1505,7 @@ void KTranslucencyConfig::save( void ) conf_->writeEntry("DisableARGB",disableARGB->isChecked()); conf_->writeEntry("ShadowOffsetY",-1*shadowTopOffset->value()); conf_->writeEntry("ShadowOffsetX",-1*shadowLeftOffset->value()); -// conf_->writeEntry("TransMode",transMode->currentItem()==0?"All":transMode->currentItem()==1?"Title":"Content"); + conf_->writeEntry("TransMode",transMode->currentItem()==0?"All":transMode->currentItem()==1?"Title":"Content"); int r, g, b; @@ -1535,7 +1536,7 @@ void KTranslucencyConfig::defaults() if (!kompmgrAvailable_) return; useTranslucency->setChecked(false); -// transMode->setCurrentItem(0); + transMode->setCurrentItem(0); activeWindowTransparency->setChecked(false); inactiveWindowTransparency->setChecked(true); movingWindowTransparency->setChecked(false);