Layout and whitespace update.
svn path=/trunk/kdebase/kwin/; revision=261305
This commit is contained in:
parent
26a5b0bfb4
commit
5bf63947d9
2 changed files with 32 additions and 36 deletions
|
@ -97,21 +97,23 @@ KWinDecorationModule::KWinDecorationModule(QWidget* parent, const char* name, co
|
|||
// cbUseMiniWindows = new QCheckBox( i18n( "Render mini &titlebars for all windows"), checkGroup );
|
||||
// QWhatsThis::add( cbUseMiniWindows, i18n( "Note that this option is not available on all styles yet!" ) );
|
||||
|
||||
QFrame* preview_frame = new QFrame( pluginPage );
|
||||
preview_frame->setFrameShape( QFrame::NoFrame );
|
||||
QVBoxLayout* preview_layout = new QVBoxLayout( preview_frame, 0, KDialog::spacingHint());
|
||||
preview = new KDecorationPreview( preview_frame );
|
||||
preview_layout->addWidget( preview );
|
||||
pluginLayout->addWidget( preview_frame );
|
||||
pluginLayout->setStretchFactor( preview_frame, 10 );
|
||||
QFrame* preview_frame = new QFrame( pluginPage );
|
||||
preview_frame->setFrameShape( QFrame::NoFrame );
|
||||
QVBoxLayout* preview_layout = new QVBoxLayout( preview_frame, 0 );
|
||||
preview = new KDecorationPreview( preview_frame );
|
||||
preview_layout->addWidget( preview );
|
||||
pluginLayout->addWidget( preview_frame );
|
||||
pluginLayout->setStretchFactor( preview_frame, 10 );
|
||||
|
||||
pluginSettingsLbl = new QLabel( i18n("Decoration Options"), pluginPage );
|
||||
pluginSettingsLine = new QFrame( pluginPage );
|
||||
pluginSettingsLine ->setFrameStyle( QFrame::HLine | QFrame::Plain );
|
||||
pluginConfigWidget = new QVBox(pluginPage);
|
||||
pluginLayout->addWidget(pluginSettingsLbl );
|
||||
pluginLayout->addWidget(pluginSettingsLine);
|
||||
pluginLayout->addWidget(pluginConfigWidget);
|
||||
pluginSettingsGrp = new QGroupBox( i18n("Decoration Options"), pluginPage );
|
||||
pluginSettingsGrp->setColumnLayout( 0, Vertical );
|
||||
pluginSettingsGrp->setFlat( true );
|
||||
pluginSettingsGrp->layout()->setMargin( 0 );
|
||||
pluginSettingsGrp->layout()->setSpacing( KDialog::spacingHint() );
|
||||
pluginLayout->addWidget( pluginSettingsGrp );
|
||||
|
||||
pluginConfigWidget = new QVBox(pluginSettingsGrp);
|
||||
pluginSettingsGrp->layout()->add( pluginConfigWidget );
|
||||
|
||||
// Page 2 (Button Selector)
|
||||
QVBox* buttonPage = new QVBox( tabWidget );
|
||||
|
@ -387,20 +389,15 @@ void KWinDecorationModule::resetPlugin( KConfig* conf, const QString& currentDec
|
|||
connect( this, SIGNAL(pluginLoad(KConfig*)), pluginObject, SLOT(load(KConfig*)) );
|
||||
connect( this, SIGNAL(pluginSave(KConfig*)), pluginObject, SLOT(save(KConfig*)) );
|
||||
connect( this, SIGNAL(pluginDefaults()), pluginObject, SLOT(defaults()) );
|
||||
pluginSettingsLbl->show();
|
||||
pluginSettingsLine->show();
|
||||
pluginConfigWidget->show();
|
||||
pluginSettingsGrp->show();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
pluginSettingsLbl->hide();
|
||||
pluginSettingsLine->hide();
|
||||
pluginConfigWidget->hide();
|
||||
pluginSettingsGrp->hide();
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Reads the kwin config settings, and sets all UI controls to those settings
|
||||
// Updating the config plugin if required
|
||||
void KWinDecorationModule::readConfig( KConfig* conf )
|
||||
|
|
|
@ -86,7 +86,7 @@ class KWinDecorationModule : public KCModule, virtual public KWinDecorationIface
|
|||
// Allows us to turn "save" on
|
||||
void slotSelectionChanged();
|
||||
void slotChangeDecoration( const QString & );
|
||||
void slotBorderChanged( int );
|
||||
void slotBorderChanged( int );
|
||||
|
||||
private:
|
||||
void readConfig( KConfig* conf );
|
||||
|
@ -96,12 +96,12 @@ class KWinDecorationModule : public KCModule, virtual public KWinDecorationIface
|
|||
void updateSelection();
|
||||
QString decorationLibName( const QString& name );
|
||||
QString decorationName ( QString& libName );
|
||||
static QString styleToConfigLib( QString& styleLib );
|
||||
static QString styleToConfigLib( QString& styleLib );
|
||||
void resetPlugin( KConfig* conf, const QString& currentDecoName = QString::null );
|
||||
void resetKWin();
|
||||
void checkSupportedBorderSizes();
|
||||
static int borderSizeToIndex( BorderSize size, QValueList< BorderSize > sizes );
|
||||
static BorderSize indexToBorderSize( int index, QValueList< BorderSize > sizes );
|
||||
void checkSupportedBorderSizes();
|
||||
static int borderSizeToIndex( BorderSize size, QValueList< BorderSize > sizes );
|
||||
static BorderSize indexToBorderSize( int index, QValueList< BorderSize > sizes );
|
||||
|
||||
QTabWidget* tabWidget;
|
||||
|
||||
|
@ -109,20 +109,19 @@ class KWinDecorationModule : public KCModule, virtual public KWinDecorationIface
|
|||
KComboBox* decorationList;
|
||||
QValueList<DecorationInfo> decorations;
|
||||
|
||||
KDecorationPreview* preview;
|
||||
KDecorationPlugins* plugins;
|
||||
KConfig kwinConfig;
|
||||
KDecorationPreview* preview;
|
||||
KDecorationPlugins* plugins;
|
||||
KConfig kwinConfig;
|
||||
|
||||
QCheckBox* cbUseCustomButtonPositions;
|
||||
// QCheckBox* cbUseMiniWindows;
|
||||
QCheckBox* cbShowToolTips;
|
||||
QLabel* lBorder;
|
||||
QSlider* slBorder;
|
||||
BorderSize border_size;
|
||||
QLabel* lBorder;
|
||||
QSlider* slBorder;
|
||||
BorderSize border_size;
|
||||
|
||||
QObject* pluginObject;
|
||||
QLabel* pluginSettingsLbl;
|
||||
QFrame* pluginSettingsLine;
|
||||
QGroupBox* pluginSettingsGrp;
|
||||
QWidget* pluginConfigWidget;
|
||||
QString currentLibraryName;
|
||||
QString oldLibraryName;
|
||||
|
|
Loading…
Reference in a new issue