From 1fb511965f135a7b86a508856c6a9cff547b2864 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20L=C3=BCbking?= Date: Fri, 21 Jan 2005 16:08:39 +0000 Subject: [PATCH] [kompmgr] added option to remove shadows on resizes svn path=/trunk/kdebase/kwin/; revision=380833 --- kcmkwin/kwinoptions/windows.cpp | 7 +++++++ kcmkwin/kwinoptions/windows.h | 1 + 2 files changed, 8 insertions(+) diff --git a/kcmkwin/kwinoptions/windows.cpp b/kcmkwin/kwinoptions/windows.cpp index 937e5d9270..77010770a7 100644 --- a/kcmkwin/kwinoptions/windows.cpp +++ b/kcmkwin/kwinoptions/windows.cpp @@ -1282,6 +1282,8 @@ KTranslucencyConfig::KTranslucencyConfig (bool _standAlone, KConfig *_config, QW shadowColor = new KColorButton(Qt::black,sGroup); gLay2->addWidget(shadowColor,5,1); gLay2->setColStretch(1,1); + removeShadowsOnResize = new QCheckBox(i18n("Remove shadows on resize"),sGroup); + vLay2->addWidget(removeShadowsOnResize); vLay2->addStretch(); tabW->addTab(sGroup, i18n("Shadows")); @@ -1322,6 +1324,7 @@ KTranslucencyConfig::KTranslucencyConfig (bool _standAlone, KConfig *_config, QW connect(dockWindowTransparency, SIGNAL(toggled(bool)), SLOT(changed())); connect(keepAboveAsActive, SIGNAL(toggled(bool)), SLOT(changed())); connect(useShadows, SIGNAL(toggled(bool)), SLOT(changed())); + connect(removeShadowsOnResize, SIGNAL(toggled(bool)), SLOT(changed())); connect(activeWindowOpacity, SIGNAL(valueChanged(int)), SLOT(changed())); connect(inactiveWindowOpacity, SIGNAL(valueChanged(int)), SLOT(changed())); @@ -1380,6 +1383,7 @@ void KTranslucencyConfig::load( void ) activeWindowTransparency->setChecked(config->readBoolEntry("TranslucentActiveWindows",false)); inactiveWindowTransparency->setChecked(config->readBoolEntry("TranslucentInactiveWindows",true)); movingWindowTransparency->setChecked(config->readBoolEntry("TranslucentMovingWindows",false)); + removeShadowsOnResize->setChecked(config->readBoolEntry("RemoveShadowsOnResize",TRUE)); dockWindowTransparency->setChecked(config->readBoolEntry("TranslucentDocks",true)); keepAboveAsActive->setChecked(config->readBoolEntry("TreatKeepAboveAsActive",true)); @@ -1451,6 +1455,7 @@ void KTranslucencyConfig::save( void ) config->writeEntry("DockShadowSize",(int)(100.0*dockWindowShadowSize->value()/inactiveWindowShadowSize->value())); config->writeEntry("ActiveWindowShadowSize",(int)(100.0*activeWindowShadowSize->value()/inactiveWindowShadowSize->value())); config->writeEntry("InctiveWindowShadowSize",100); + config->writeEntry("RemoveShadowsOnResize",removeShadowsOnResize->isChecked()); config->writeEntry("ResetKompmgr",resetKompmgr_); KConfig *conf_ = new KConfig(QDir::homeDirPath() + "/.xcompmgrrc"); @@ -1508,6 +1513,8 @@ void KTranslucencyConfig::defaults() inactiveWindowOpacity->setEnabled(true); movingWindowOpacity->setEnabled(false); dockWindowOpacity->setEnabled(true); + useShadows->setChecked(TRUE); + removeShadowsOnResize->setChecked(FALSE); shadowColor->setColor(Qt::black); fadeInWindows->setChecked(TRUE); fadeOnOpacityChange->setChecked(FALSE); diff --git a/kcmkwin/kwinoptions/windows.h b/kcmkwin/kwinoptions/windows.h index e07535a8d5..ffc36a66aa 100644 --- a/kcmkwin/kwinoptions/windows.h +++ b/kcmkwin/kwinoptions/windows.h @@ -249,6 +249,7 @@ private: QCheckBox *fadeInWindows; QCheckBox *fadeOnOpacityChange; QCheckBox *useShadows; + QCheckBox *removeShadowsOnResize; QGroupBox *sGroup; // QPushButton *xcompmgrButton; KIntNumInput *activeWindowOpacity;