@ -28,126 +28,126 @@ DEALINGS IN THE SOFTWARE.
*/
# include < qcheckbox.h>
# include < qlayout.h>
# include < qhbox.h>
# include < qsettings.h>
# include < qcolor.h>
# include < qlabel.h>
# include < qcombobox.h>
# include < t qcheckbox.h>
# include < t qlayout.h>
# include < t qhbox.h>
# include < t qsettings.h>
# include < t qcolor.h>
# include < t qlabel.h>
# include < t qcombobox.h>
# include <kglobal.h>
# include <klocale.h>
# include <kcolorbutton.h>
# include < qtabwidget.h>
# include < qvgroupbox.h>
# include < qspinbox.h>
# include < qgrid.h>
# include < t qtabwidget.h>
# include < t qvgroupbox.h>
# include < t qspinbox.h>
# include < t qgrid.h>
# include "lipstikconf.h"
extern " C "
{
QWidget* allocate_kstyle_config ( QWidget* parent)
T QWidget* allocate_kstyle_config ( T QWidget* tq parent)
{
KGlobal : : locale ( ) - > insertCatalogue ( " kstyle_lipstik_config " ) ;
return new LipstikStyleConfig ( parent) ;
return new LipstikStyleConfig ( tq parent) ;
}
}
LipstikStyleConfig : : LipstikStyleConfig ( QWidget* parent) : QWidget( parent)
LipstikStyleConfig : : LipstikStyleConfig ( T QWidget* tq parent) : T QWidget( tq parent)
{
QVBoxLayout* layout = new QVBoxLayout( this , 0 , 0 ) ;
QGridLayout* tabLayout = new QGridLayout( this , 2 , 1 , 10 ) ;
T QVBoxLayout* tq layout = new T QVBoxLayout( this , 0 , 0 ) ;
T QGridLayout* tabLayout = new T QGridLayout( this , 2 , 1 , 10 ) ;
KGlobal : : locale ( ) - > insertCatalogue ( " kstyle_lipstik_config " ) ;
///Init tabs
QTabWidget * tabWidget = new QTabWidget( this ) ;
layout- > addWidget ( tabWidget ) ;
T QTabWidget * tabWidget = new T QTabWidget( this ) ;
tq layout- > addWidget ( tabWidget ) ;
///Init tab1
QWidget * page1 = new QWidget( tabWidget ) ;
layout = new QVBoxLayout( page1 ) ;
T QWidget * page1 = new T QWidget( tabWidget ) ;
tq layout = new T QVBoxLayout( page1 ) ;
tabWidget - > insertTab ( page1 , i18n ( " Configuration " ) ) ;
layout- > addLayout ( tabLayout ) ;
tq layout- > addLayout ( tabLayout ) ;
///General group
QVGroupBox * generalGrp = new QVGroupBox( i18n ( " General " ) , page1 ) ;
T QVGroupBox * generalGrp = new T QVGroupBox( i18n ( " General " ) , page1 ) ;
reverseGradients = new QCheckBox( i18n ( " Plastik gradients " ) , generalGrp ) ;
drawTriangularExpander = new QCheckBox( i18n ( " Triangular tree expander " ) , generalGrp ) ;
drawStatusBarFrame = new QCheckBox( i18n ( " Draw status bar frame " ) , generalGrp ) ;
animateProgressBar = new QCheckBox( i18n ( " Animate progress bars " ) , generalGrp ) ;
flatHeaders = new QCheckBox( i18n ( " Flatten column headers " ) , generalGrp ) ;
tickCheckMark = new QCheckBox( i18n ( " Use a tick for checkmarks " ) , generalGrp ) ;
reverseGradients = new T QCheckBox( i18n ( " Plastik gradients " ) , generalGrp ) ;
drawTriangularExpander = new T QCheckBox( i18n ( " Triangular tree expander " ) , generalGrp ) ;
drawStatusBarFrame = new T QCheckBox( i18n ( " Draw status bar frame " ) , generalGrp ) ;
animateProgressBar = new T QCheckBox( i18n ( " Animate progress bars " ) , generalGrp ) ;
flatHeaders = new T QCheckBox( i18n ( " Flatten column headers " ) , generalGrp ) ;
tickCheckMark = new T QCheckBox( i18n ( " Use a tick for checkmarks " ) , generalGrp ) ;
tabLayout - > addWidget ( generalGrp , 0 , 0 , 0 ) ;
///Toolbar group
QVGroupBox * toolbarGrp = new QVGroupBox( i18n ( " Toolbars " ) , page1 ) ;
QLabel* toolBarSpacingLabel ;
T QVGroupBox * toolbarGrp = new T QVGroupBox( i18n ( " Toolbars " ) , page1 ) ;
T QLabel* toolBarSpacingLabel ;
drawToolBarSeparator = new QCheckBox( i18n ( " Draw separators " ) , toolbarGrp ) ;
drawToolBarItemSeparator = new QCheckBox( i18n ( " Draw item separators " ) , toolbarGrp ) ;
drawToolBarHandle = new QCheckBox( i18n ( " Draw handles " ) , toolbarGrp ) ;
drawToolBarGradient = new QCheckBox( i18n ( " Draw gradients " ) , toolbarGrp ) ;
invertBarGrad = new QCheckBox( i18n ( " Invert gradients " ) , toolbarGrp ) ;
drawToolBarSeparator = new T QCheckBox( i18n ( " Draw separators " ) , toolbarGrp ) ;
drawToolBarItemSeparator = new T QCheckBox( i18n ( " Draw item separators " ) , toolbarGrp ) ;
drawToolBarHandle = new T QCheckBox( i18n ( " Draw handles " ) , toolbarGrp ) ;
drawToolBarGradient = new T QCheckBox( i18n ( " Draw gradients " ) , toolbarGrp ) ;
invertBarGrad = new T QCheckBox( i18n ( " Invert gradients " ) , toolbarGrp ) ;
toolBarSpacingLabel = new QLabel( toolbarGrp ) ;
toolBarSpacingLabel = new T QLabel( toolbarGrp ) ;
toolBarSpacingLabel - > setText ( i18n ( " Items spacing : " ) ) ;
toolBarSpacing = new QSpinBox ( 0 , 6 , 1 , toolbarGrp ) ;
toolBarSpacing = new T QSpinBox ( 0 , 6 , 1 , toolbarGrp ) ;
tabLayout - > addWidget ( toolbarGrp , 0 , 1 , 0 ) ;
///Menus group
QVGroupBox * menusGrp = new QVGroupBox( i18n ( " Menus " ) , page1 ) ;
QLabel* menuSpacingLabel ;
T QVGroupBox * menusGrp = new T QVGroupBox( i18n ( " Menus " ) , page1 ) ;
T QLabel* menuSpacingLabel ;
alterMenuGradients = new QCheckBox( i18n ( " Button-like menu gradients " ) , menusGrp ) ;
sharperMenuGradient = new QCheckBox( i18n ( " Sharper menu gradients " ) , menusGrp ) ;
alterMenuGradients = new T QCheckBox( i18n ( " Button-like menu gradients " ) , menusGrp ) ;
sharperMenuGradient = new T QCheckBox( i18n ( " Sharper menu gradients " ) , menusGrp ) ;
menuLeftSideBar = new QCheckBox( i18n ( " Menu Stripe " ) , menusGrp ) ;
flatStripe = new QCheckBox( i18n ( " Flatten Stripe " ) , menusGrp ) ;
customMenuStripeColor = new QCheckBox( i18n ( " Custom Stripe color : " ) , menusGrp ) ;
QHBox * menuColorBox = new QHBox( menusGrp ) ;
menuColorBox - > layout( ) - > addItem ( new QSpacerItem( 20 , 0 , QSizePolicy: : Fixed , QSizePolicy: : Minimum ) ) ;
menuLeftSideBar = new T QCheckBox( i18n ( " Menu Stripe " ) , menusGrp ) ;
flatStripe = new T QCheckBox( i18n ( " Flatten Stripe " ) , menusGrp ) ;
customMenuStripeColor = new T QCheckBox( i18n ( " Custom Stripe color : " ) , menusGrp ) ;
T QHBox * menuColorBox = new T QHBox( menusGrp ) ;
menuColorBox - > tq layout( ) - > addItem ( new T QSpacerItem( 20 , 0 , T QSizePolicy: : Fixed , T QSizePolicy: : Minimum ) ) ;
menuStripeColor = new KColorButton ( menuColorBox ) ;
menuSpacingLabel = new QLabel( menusGrp ) ;
menuSpacingLabel = new T QLabel( menusGrp ) ;
menuSpacingLabel - > setText ( i18n ( " Menu spacing : " ) ) ;
menuSpacing = new QSpinBox ( 0 , 8 , 1 , menusGrp ) ;
menuSpacing = new T QSpinBox ( 0 , 8 , 1 , menusGrp ) ;
tabLayout - > addWidget ( menusGrp , 1 , 0 , 0 ) ;
///Scrollbar group
QVGroupBox * scrollGrp = new QVGroupBox( i18n ( " Scrollbars and Sliders " ) , page1 ) ;
QLabel* scrollBarStyleLabel ;
QLabel* scrollBarWidthLabel ;
QLabel* sliderStyleLabel ;
T QVGroupBox * scrollGrp = new T QVGroupBox( i18n ( " Scrollbars and Sliders " ) , page1 ) ;
T QLabel* scrollBarStyleLabel ;
T QLabel* scrollBarWidthLabel ;
T QLabel* sliderStyleLabel ;
paintGroove = new QCheckBox( i18n ( " Draw Scrollbar grooves " ) , scrollGrp ) ;
paintGroove = new T QCheckBox( i18n ( " Draw Scrollbar grooves " ) , scrollGrp ) ;
scrollBarStyleLabel = new QLabel( scrollGrp ) ;
scrollBarStyleLabel = new T QLabel( scrollGrp ) ;
scrollBarStyleLabel - > setText ( i18n ( " Scrollbar style : " ) ) ;
scrollBarStyle = new QComboBox( i18n ( " Scrollbar style " ) , scrollGrp ) ;
scrollBarStyle = new T QComboBox( i18n ( " Scrollbar style " ) , scrollGrp ) ;
scrollBarStyle - > setEditable ( false ) ;
scrollBarStyle - > insertItem ( " Windows style " ) ;
scrollBarStyle - > insertItem ( " Platinum style " ) ;
scrollBarStyle - > insertItem ( " KDE style " ) ;
scrollBarStyle - > insertItem ( " Next style " ) ;
scrollBarWidthLabel = new QLabel( scrollGrp ) ;
scrollBarWidthLabel = new T QLabel( scrollGrp ) ;
scrollBarWidthLabel - > setText ( i18n ( " Scrollbar width : " ) ) ;
scrollBarWidth = new QComboBox( i18n ( " Scrollbar width " ) , scrollGrp ) ;
scrollBarWidth = new T QComboBox( i18n ( " Scrollbar width " ) , scrollGrp ) ;
scrollBarWidth - > setEditable ( false ) ;
scrollBarWidth - > insertItem ( " Small " ) ;
scrollBarWidth - > insertItem ( " Normal " ) ;
scrollBarWidth - > insertItem ( " Large " ) ;
sliderStyleLabel = new QLabel( scrollGrp ) ;
sliderStyleLabel = new T QLabel( scrollGrp ) ;
sliderStyleLabel - > setText ( i18n ( " Slider handle size : " ) ) ;
sliderStyle = new QComboBox( i18n ( " Slider handle size " ) , scrollGrp ) ;
sliderStyle = new T QComboBox( i18n ( " Slider handle size " ) , scrollGrp ) ;
sliderStyle - > setEditable ( false ) ;
sliderStyle - > insertItem ( " Small " ) ;
sliderStyle - > insertItem ( " Medium " ) ;
@ -156,143 +156,143 @@ LipstikStyleConfig::LipstikStyleConfig(QWidget* parent): QWidget(parent)
tabLayout - > addWidget ( scrollGrp , 1 , 1 , 0 ) ;
///Highlighting group
QVGroupBox * lightGrp = new QVGroupBox( i18n ( " Highlighting " ) , page1 ) ;
T QVGroupBox * lightGrp = new T QVGroupBox( i18n ( " Highlighting " ) , page1 ) ;
drawFocusRect = new QCheckBox( i18n ( " Colored focus rectangle " ) , lightGrp ) ;
comboboxColored = new QCheckBox( i18n ( " Colored comboboxes handles " ) , lightGrp ) ;
coloredMenuBar = new QCheckBox( i18n ( " Colored menu bar items " ) , lightGrp ) ;
drawTabHighlight = new QCheckBox( i18n ( " Highlight active tab " ) , lightGrp ) ;
inputFocusHighlight = new QCheckBox( i18n ( " Highlight focused input fields " ) , lightGrp ) ;
drawFocusRect = new T QCheckBox( i18n ( " Colored focus rectangle " ) , lightGrp ) ;
comboboxColored = new T QCheckBox( i18n ( " Colored comboboxes handles " ) , lightGrp ) ;
coloredMenuBar = new T QCheckBox( i18n ( " Colored menu bar items " ) , lightGrp ) ;
drawTabHighlight = new T QCheckBox( i18n ( " Highlight active tab " ) , lightGrp ) ;
inputFocusHighlight = new T QCheckBox( i18n ( " Highlight focused input fields " ) , lightGrp ) ;
tabLayout - > addWidget ( lightGrp , 0 , 2 , 0 ) ;
///Other colors group
QVGroupBox * otherGrp = new QVGroupBox( i18n ( " Custom colors " ) , page1 ) ;
T QVGroupBox * otherGrp = new T QVGroupBox( i18n ( " Custom colors " ) , page1 ) ;
customFocusHighlightColor = new QCheckBox( i18n ( " Input fields highlight : " ) , otherGrp ) ;
QHBox * hbox1 = new QHBox( otherGrp ) ;
hbox1 - > layout( ) - > addItem ( new QSpacerItem( 20 , 0 , QSizePolicy: : Fixed , QSizePolicy: : Minimum ) ) ;
customFocusHighlightColor = new T QCheckBox( i18n ( " Input fields highlight : " ) , otherGrp ) ;
T QHBox * hbox1 = new T QHBox( otherGrp ) ;
hbox1 - > tq layout( ) - > addItem ( new T QSpacerItem( 20 , 0 , T QSizePolicy: : Fixed , T QSizePolicy: : Minimum ) ) ;
focusHighlightColor = new KColorButton ( hbox1 ) ;
customOverHighlightColor = new QCheckBox( i18n ( " Mouse hover highlight : " ) , otherGrp ) ;
QHBox * hbox2 = new QHBox( otherGrp ) ;
hbox2 - > layout( ) - > addItem ( new QSpacerItem( 20 , 0 , QSizePolicy: : Fixed , QSizePolicy: : Minimum ) ) ;
customOverHighlightColor = new T QCheckBox( i18n ( " Mouse hover highlight : " ) , otherGrp ) ;
T QHBox * hbox2 = new T QHBox( otherGrp ) ;
hbox2 - > tq layout( ) - > addItem ( new T QSpacerItem( 20 , 0 , T QSizePolicy: : Fixed , T QSizePolicy: : Minimum ) ) ;
overHighlightColor = new KColorButton ( hbox2 ) ;
customCheckMarkColor = new QCheckBox( i18n ( " Checkmark/Radiobuttons : " ) , otherGrp ) ;
QHBox * hbox3 = new QHBox( otherGrp ) ;
hbox3 - > layout( ) - > addItem ( new QSpacerItem( 20 , 0 , QSizePolicy: : Fixed , QSizePolicy: : Minimum ) ) ;
customCheckMarkColor = new T QCheckBox( i18n ( " Checkmark/Radiobuttons : " ) , otherGrp ) ;
T QHBox * hbox3 = new T QHBox( otherGrp ) ;
hbox3 - > tq layout( ) - > addItem ( new T QSpacerItem( 20 , 0 , T QSizePolicy: : Fixed , T QSizePolicy: : Minimum ) ) ;
checkMarkColor = new KColorButton ( hbox3 ) ;
customTabHighlightColor = new QCheckBox( i18n ( " Active tab highlight : " ) , otherGrp ) ;
QHBox * hbox4 = new QHBox( otherGrp ) ;
hbox4 - > layout( ) - > addItem ( new QSpacerItem( 20 , 0 , QSizePolicy: : Fixed , QSizePolicy: : Minimum ) ) ;
customTabHighlightColor = new T QCheckBox( i18n ( " Active tab highlight : " ) , otherGrp ) ;
T QHBox * hbox4 = new T QHBox( otherGrp ) ;
hbox4 - > tq layout( ) - > addItem ( new T QSpacerItem( 20 , 0 , T QSizePolicy: : Fixed , T QSizePolicy: : Minimum ) ) ;
tabHighlightColor = new KColorButton ( hbox4 ) ;
tabLayout - > addWidget ( otherGrp , 1 , 2 , 0 ) ;
///Init tab2
QWidget * page2 = new QWidget( tabWidget ) ;
QLabel* lipstikLabel ;
QLabel* authorLabel ;
QLabel* authorAddressLabel ;
QLabel* authorWebLabel ;
QLabel* plastikLabel ;
QLabel* alsoLabel ;
QLabel* cuLabel ;
QLabel* dnLabel ;
QLabel* pqLabel ;
QLabel* cxLabel ;
QLabel* kpLabel ;
QLabel* blLabel ;
QLabel* ksLabel ;
QLabel* peLabel ;
QLabel* bastianLabel ;
QLabel* pcbsdLabel ;
QLabel* othersLabel ;
layout = new QVBoxLayout( page2 , 10 , - 1 ) ;
T QWidget * page2 = new T QWidget( tabWidget ) ;
T QLabel* lipstikLabel ;
T QLabel* authorLabel ;
T QLabel* authorAddressLabel ;
T QLabel* authorWebLabel ;
T QLabel* plastikLabel ;
T QLabel* alsoLabel ;
T QLabel* cuLabel ;
T QLabel* dnLabel ;
T QLabel* pqLabel ;
T QLabel* cxLabel ;
T QLabel* kpLabel ;
T QLabel* blLabel ;
T QLabel* ksLabel ;
T QLabel* peLabel ;
T QLabel* bastianLabel ;
T QLabel* pcbsdLabel ;
T QLabel* othersLabel ;
tq layout = new T QVBoxLayout( page2 , 10 , - 1 ) ;
tabWidget - > insertTab ( page2 , i18n ( " About " ) ) ;
lipstikLabel = new QLabel( page2 ) ;
lipstikLabel = new T QLabel( page2 ) ;
lipstikLabel - > setText ( i18n ( " Lipstik 2.2.3 " ) ) ;
lipstikLabel - > setFrameStyle ( QFrame: : StyledPanel | QFrame: : Raised ) ;
lipstikLabel - > setFrameStyle ( T QFrame: : StyledPanel | T QFrame: : Raised ) ;
authorLabel = new QLabel( page2 ) ;
authorLabel = new T QLabel( page2 ) ;
authorLabel - > setText ( i18n ( " Copyright 2004-2005-2006-2007 (C) Patrice Tremblay (Poplix) " ) ) ;
authorAddressLabel = new QLabel( page2 ) ;
authorAddressLabel = new T QLabel( page2 ) ;
authorAddressLabel - > setText ( i18n ( " poplixos@gmail.com " ) ) ;
authorWebLabel = new QLabel( page2 ) ;
authorWebLabel = new T QLabel( page2 ) ;
authorWebLabel - > setText ( i18n ( " http://poplix.homelinux.com/lipstik " ) ) ;
plastikLabel = new QLabel( page2 ) ;
plastikLabel = new T QLabel( page2 ) ;
plastikLabel - > setText ( i18n ( " Based on plastik [thanks to Sandro Giessl] " ) ) ;
alsoLabel = new QLabel( page2 ) ;
alsoLabel = new T QLabel( page2 ) ;
alsoLabel - > setText ( i18n ( " Also based on : " ) ) ;
cuLabel = new QLabel( page2 ) ;
cuLabel - > setText ( i18n ( " QtCurve [thanks to Craig Drummond]," ) ) ;
cuLabel = new T QLabel( page2 ) ;
cuLabel - > setText ( i18n ( " T QtCurve [thanks to Craig Drummond]," ) ) ;
dnLabel = new QLabel( page2 ) ;
dnLabel = new T QLabel( page2 ) ;
dnLabel - > setText ( i18n ( " DotNET [thanks to Chris Lee], " ) ) ;
pqLabel = new QLabel( page2 ) ;
pqLabel = new T QLabel( page2 ) ;
pqLabel - > setText ( i18n ( " PlastikQ [thanks to Martin Beck], " ) ) ;
cxLabel = new QLabel( page2 ) ;
cxLabel = new T QLabel( page2 ) ;
cxLabel - > setText ( i18n ( " Comix [thanks to Jens Luetkens], " ) ) ;
kpLabel = new QLabel( page2 ) ;
kpLabel = new T QLabel( page2 ) ;
kpLabel - > setText ( i18n ( " Krisp [thanks to Keith Meehl], " ) ) ;
blLabel = new QLabel( page2 ) ;
blLabel = new T QLabel( page2 ) ;
blLabel - > setText ( i18n ( " Ballistik [thanks to Florian Merz], " ) ) ;
ksLabel = new QLabel( page2 ) ;
ksLabel = new T QLabel( page2 ) ;
ksLabel - > setText ( i18n ( " Kerastik [thanks to Victor Perez Q], " ) ) ;
peLabel = new QLabel( page2 ) ;
peLabel = new T QLabel( page2 ) ;
peLabel - > setText ( i18n ( " Polyester [thanks to Marco Martin]. " ) ) ;
bastianLabel = new QLabel( page2 ) ;
bastianLabel = new T QLabel( page2 ) ;
bastianLabel - > setText ( i18n ( " Thanks to Bastian Venthur, the Debian maintainer of kde-style-lipstik. " ) ) ;
pcbsdLabel = new QLabel( page2 ) ;
pcbsdLabel = new T QLabel( page2 ) ;
pcbsdLabel - > setText ( i18n ( " Thanks to Charles A. Landemaine, of PC-BSD, for the feature suggestion. " ) ) ;
othersLabel = new QLabel( page2 ) ;
othersLabel = new T QLabel( page2 ) ;
othersLabel - > setText ( i18n ( " Special thanks to Dominique and all the kde-look.org users. " ) ) ;
layout- > add ( lipstikLabel ) ;
layout- > add ( authorLabel ) ;
layout- > add ( authorAddressLabel ) ;
layout- > add ( authorWebLabel ) ;
layout- > addSpacing ( 10 ) ;
layout- > add ( plastikLabel ) ;
layout- > addSpacing ( 10 ) ;
layout- > add ( alsoLabel ) ;
layout- > add ( cuLabel ) ;
layout- > add ( dnLabel ) ;
layout- > add ( pqLabel ) ;
layout- > add ( cxLabel ) ;
layout- > add ( kpLabel ) ;
layout- > add ( blLabel ) ;
layout- > add ( ksLabel ) ;
layout- > add ( peLabel ) ;
layout- > addSpacing ( 10 ) ;
layout- > add ( bastianLabel ) ;
layout- > add ( pcbsdLabel ) ;
layout- > add ( othersLabel ) ;
tq layout- > add ( lipstikLabel ) ;
tq layout- > add ( authorLabel ) ;
tq layout- > add ( authorAddressLabel ) ;
tq layout- > add ( authorWebLabel ) ;
tq layout- > addSpacing ( 10 ) ;
tq layout- > add ( plastikLabel ) ;
tq layout- > addSpacing ( 10 ) ;
tq layout- > add ( alsoLabel ) ;
tq layout- > add ( cuLabel ) ;
tq layout- > add ( dnLabel ) ;
tq layout- > add ( pqLabel ) ;
tq layout- > add ( cxLabel ) ;
tq layout- > add ( kpLabel ) ;
tq layout- > add ( blLabel ) ;
tq layout- > add ( ksLabel ) ;
tq layout- > add ( peLabel ) ;
tq layout- > addSpacing ( 10 ) ;
tq layout- > add ( bastianLabel ) ;
tq layout- > add ( pcbsdLabel ) ;
tq layout- > add ( othersLabel ) ;
///Populate!
QSettings s ;
T QSettings s ;
origReverseGradients = s . readBoolEntry ( " /lipstikstyle/Settings/reverseGradients " , false ) ;
reverseGradients - > setChecked ( origReverseGradients ) ;
@ -375,69 +375,69 @@ LipstikStyleConfig::LipstikStyleConfig(QWidget* parent): QWidget(parent)
origCustomOverHighlightColor = s . readBoolEntry ( " /lipstikstyle/Settings/customOverHighlightColor " , false ) ;
customOverHighlightColor - > setChecked ( origCustomOverHighlightColor ) ;
origOverHighlightColor = s . readEntry ( " /lipstikstyle/Settings/overHighlightColor " , " / Qt/KWinPalette/activeBackground" ) ;
origOverHighlightColor = s . readEntry ( " /lipstikstyle/Settings/overHighlightColor " , " / T Qt/KWinPalette/activeBackground" ) ;
overHighlightColor - > setColor ( origOverHighlightColor ) ;
origCustomMenuStripeColor = s . readBoolEntry ( " /lipstikstyle/Settings/customMenuStripeColor " , false ) ;
customMenuStripeColor - > setChecked ( origCustomMenuStripeColor ) ;
origMenuStripeColor = s . readEntry ( " /lipstikstyle/Settings/menuStripeColor " , " / Qt/KWinPalette/activeBackground" ) ;
origMenuStripeColor = s . readEntry ( " /lipstikstyle/Settings/menuStripeColor " , " / T Qt/KWinPalette/activeBackground" ) ;
menuStripeColor - > setColor ( origMenuStripeColor ) ;
origCustomFocusHighlightColor = s . readBoolEntry ( " /lipstikstyle/Settings/customFocusHighlightColor " , false ) ;
customFocusHighlightColor - > setChecked ( origCustomFocusHighlightColor ) ;
origFocusHighlightColor = s . readEntry ( " /lipstikstyle/Settings/focusHighlightColor " , " / Qt/KWinPalette/activeBackground" ) ;
origFocusHighlightColor = s . readEntry ( " /lipstikstyle/Settings/focusHighlightColor " , " / T Qt/KWinPalette/activeBackground" ) ;
focusHighlightColor - > setColor ( origFocusHighlightColor ) ;
origCustomCheckMarkColor = s . readBoolEntry ( " /lipstikstyle/Settings/customCheckMarkColor " , false ) ;
customCheckMarkColor - > setChecked ( origCustomCheckMarkColor ) ;
origCheckMarkColor = s . readEntry ( " /lipstikstyle/Settings/checkMarkColor " , " / Qt/KWinPalette/activeBackground" ) ;
origCheckMarkColor = s . readEntry ( " /lipstikstyle/Settings/checkMarkColor " , " / T Qt/KWinPalette/activeBackground" ) ;
checkMarkColor - > setColor ( origCheckMarkColor ) ;
origCustomTabHighlightColor = s . readBoolEntry ( " /lipstikstyle/Settings/customTabHighlightColor " , false ) ;
customTabHighlightColor - > setChecked ( origCustomTabHighlightColor ) ;
origTabHighlightColor = s . readEntry ( " /lipstikstyle/Settings/tabHighlightColor " , " / Qt/KWinPalette/activeBackground" ) ;
origTabHighlightColor = s . readEntry ( " /lipstikstyle/Settings/tabHighlightColor " , " / T Qt/KWinPalette/activeBackground" ) ;
tabHighlightColor - > setColor ( origTabHighlightColor ) ;
connect ( reverseGradients , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( paintGroove , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( sharperMenuGradient , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( alterMenuGradients , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( menuLeftSideBar , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( flatStripe , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( drawStatusBarFrame , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( drawToolBarHandle , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( comboboxColored , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( coloredMenuBar , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( drawTabHighlight , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( menuSpacing , SIGNAL( valueChanged ( int ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( toolBarSpacing , SIGNAL( valueChanged ( int ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( scrollBarStyle , SIGNAL( activated ( int ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( scrollBarWidth , SIGNAL( activated ( int ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( sliderStyle , SIGNAL( activated ( int ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( animateProgressBar , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( drawToolBarSeparator , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( drawToolBarGradient , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( invertBarGrad , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( drawToolBarItemSeparator , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( drawFocusRect , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( flatHeaders , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( tickCheckMark , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( drawTriangularExpander , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( inputFocusHighlight , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( customOverHighlightColor , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( overHighlightColor , SIGNAL( pressed ( ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( customMenuStripeColor , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( menuStripeColor , SIGNAL( pressed ( ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( customFocusHighlightColor , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( focusHighlightColor , SIGNAL( pressed ( ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( customCheckMarkColor , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( checkMarkColor , SIGNAL( pressed ( ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( customTabHighlightColor , SIGNAL( toggled ( bool ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( tabHighlightColor , SIGNAL( pressed ( ) ) , SLOT( updateChanged ( ) ) ) ;
connect ( reverseGradients , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( paintGroove , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( sharperMenuGradient , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( alterMenuGradients , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( menuLeftSideBar , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( flatStripe , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( drawStatusBarFrame , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( drawToolBarHandle , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( comboboxColored , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( coloredMenuBar , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( drawTabHighlight , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( menuSpacing , TQT_ SIGNAL( valueChanged ( int ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( toolBarSpacing , TQT_ SIGNAL( valueChanged ( int ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( scrollBarStyle , TQT_ SIGNAL( activated ( int ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( scrollBarWidth , TQT_ SIGNAL( activated ( int ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( sliderStyle , TQT_ SIGNAL( activated ( int ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( animateProgressBar , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( drawToolBarSeparator , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( drawToolBarGradient , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( invertBarGrad , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( drawToolBarItemSeparator , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( drawFocusRect , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( flatHeaders , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( tickCheckMark , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( drawTriangularExpander , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( inputFocusHighlight , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( customOverHighlightColor , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( overHighlightColor , TQT_ SIGNAL( pressed ( ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( customMenuStripeColor , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( menuStripeColor , TQT_ SIGNAL( pressed ( ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( customFocusHighlightColor , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( focusHighlightColor , TQT_ SIGNAL( pressed ( ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( customCheckMarkColor , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( checkMarkColor , TQT_ SIGNAL( pressed ( ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( customTabHighlightColor , TQT_ SIGNAL( toggled ( bool ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
connect ( tabHighlightColor , TQT_ SIGNAL( pressed ( ) ) , TQT_ SLOT( updateChanged ( ) ) ) ;
//Menu Stripe
if ( menuLeftSideBar - > isChecked ( ) ) {
@ -496,7 +496,7 @@ LipstikStyleConfig::~LipstikStyleConfig()
void LipstikStyleConfig : : save ( )
{
QSettings s ;
T QSettings s ;
s . writeEntry ( " /lipstikstyle/Settings/reverseGradients " , reverseGradients - > isChecked ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/paintGroove " , paintGroove - > isChecked ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/sharperMenuGradient " , sharperMenuGradient - > isChecked ( ) ) ;
@ -524,15 +524,15 @@ void LipstikStyleConfig::save()
s . writeEntry ( " /lipstikstyle/Settings/drawTriangularExpander " , drawTriangularExpander - > isChecked ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/inputFocusHighlight " , inputFocusHighlight - > isChecked ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/customOverHighlightColor " , customOverHighlightColor - > isChecked ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/overHighlightColor " , QColor( overHighlightColor - > color ( ) ) . name ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/overHighlightColor " , T QColor( overHighlightColor - > color ( ) ) . name ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/customMenuStripeColor " , customMenuStripeColor - > isChecked ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/menuStripeColor " , QColor( menuStripeColor - > color ( ) ) . name ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/menuStripeColor " , T QColor( menuStripeColor - > color ( ) ) . name ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/customFocusHighlightColor " , customFocusHighlightColor - > isChecked ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/focusHighlightColor " , QColor( focusHighlightColor - > color ( ) ) . name ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/focusHighlightColor " , T QColor( focusHighlightColor - > color ( ) ) . name ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/customCheckMarkColor " , customCheckMarkColor - > isChecked ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/checkMarkColor " , QColor( checkMarkColor - > color ( ) ) . name ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/checkMarkColor " , T QColor( checkMarkColor - > color ( ) ) . name ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/customTabHighlightColor " , customTabHighlightColor - > isChecked ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/tabHighlightColor " , QColor( tabHighlightColor - > color ( ) ) . name ( ) ) ;
s . writeEntry ( " /lipstikstyle/Settings/tabHighlightColor " , T QColor( tabHighlightColor - > color ( ) ) . name ( ) ) ;
}
void LipstikStyleConfig : : defaults ( )
@ -564,15 +564,15 @@ void LipstikStyleConfig::defaults()
drawTriangularExpander - > setChecked ( false ) ;
inputFocusHighlight - > setChecked ( true ) ;
customOverHighlightColor - > setChecked ( false ) ;
overHighlightColor - > setColor ( " / Qt/KWinPalette/activeBackground" ) ;
overHighlightColor - > setColor ( " / T Qt/KWinPalette/activeBackground" ) ;
customMenuStripeColor - > setChecked ( false ) ;
menuStripeColor - > setColor ( " / Qt/KWinPalette/activeBackground" ) ;
menuStripeColor - > setColor ( " / T Qt/KWinPalette/activeBackground" ) ;
customFocusHighlightColor - > setChecked ( false ) ;
focusHighlightColor - > setColor ( " / Qt/KWinPalette/activeBackground" ) ;
focusHighlightColor - > setColor ( " / T Qt/KWinPalette/activeBackground" ) ;
customCheckMarkColor - > setChecked ( false ) ;
checkMarkColor - > setColor ( " / Qt/KWinPalette/activeBackground" ) ;
checkMarkColor - > setColor ( " / T Qt/KWinPalette/activeBackground" ) ;
customTabHighlightColor - > setChecked ( false ) ;
tabHighlightColor - > setColor ( " / Qt/KWinPalette/activeBackground" ) ;
tabHighlightColor - > setColor ( " / T Qt/KWinPalette/activeBackground" ) ;
//updateChanged would be done by setChecked already
}
@ -677,23 +677,23 @@ void LipstikStyleConfig::updateChanged()
}
//Scrollbar types
QString LipstikStyleConfig : : scrollBarType ( int listnr )
T QString LipstikStyleConfig : : scrollBarType ( int listnr )
{
switch ( listnr ) {
case 0 :
return QString( " WindowsStyleScrollBar " ) ;
return T QString( " WindowsStyleScrollBar " ) ;
case 1 :
return QString( " PlatinumStyleScrollBar " ) ;
return T QString( " PlatinumStyleScrollBar " ) ;
case 2 :
return QString( " ThreeButtonScrollBar " ) ;
return T QString( " ThreeButtonScrollBar " ) ;
case 3 :
return QString( " NextStyleScrollBar " ) ;
return T QString( " NextStyleScrollBar " ) ;
default :
return QString( " PlatinumStyleScrollBar " ) ;
return T QString( " PlatinumStyleScrollBar " ) ;
}
}
int LipstikStyleConfig : : scrollBarItem ( QString kSBType )
int LipstikStyleConfig : : scrollBarItem ( T QString kSBType )
{
if ( ! strcmp ( kSBType , " WindowsStyleScrollBar " ) )
return 0 ;
@ -708,21 +708,21 @@ int LipstikStyleConfig::scrollBarItem( QString kSBType )
}
//Scrollbar Widths
QString LipstikStyleConfig : : scrollBarWidthType ( int widthListnr )
T QString LipstikStyleConfig : : scrollBarWidthType ( int widthListnr )
{
switch ( widthListnr ) {
case 0 :
return QString( " Small " ) ;
return T QString( " Small " ) ;
case 1 :
return QString( " Normal " ) ;
return T QString( " Normal " ) ;
case 2 :
return QString( " Large " ) ;
return T QString( " Large " ) ;
default :
return QString( " Small " ) ;
return T QString( " Small " ) ;
}
}
int LipstikStyleConfig : : scrollBarWidthItem ( QString kSBWidthType )
int LipstikStyleConfig : : scrollBarWidthItem ( T QString kSBWidthType )
{
if ( ! strcmp ( kSBWidthType , " Small " ) )
return 0 ;
@ -735,7 +735,7 @@ int LipstikStyleConfig::scrollBarWidthItem( QString kSBWidthType )
}
//Slider types
int LipstikStyleConfig : : sliderItem ( QString kSliderType )
int LipstikStyleConfig : : sliderItem ( T QString kSliderType )
{
if ( ! strcmp ( kSliderType , " sliderPlastikStyle " ) )
return 0 ;
@ -747,17 +747,17 @@ int LipstikStyleConfig::sliderItem( QString kSliderType )
return 2 ;
}
QString LipstikStyleConfig : : sliderType ( int sliderlistnr )
T QString LipstikStyleConfig : : sliderType ( int sliderlistnr )
{
switch ( sliderlistnr ) {
case 0 :
return QString( " sliderPlastikStyle " ) ;
return T QString( " sliderPlastikStyle " ) ;
case 1 :
return QString( " sliderLipstikStyle " ) ;
return T QString( " sliderLipstikStyle " ) ;
case 2 :
return QString( " sliderGtkStyle " ) ;
return T QString( " sliderGtkStyle " ) ;
default :
return QString( " sliderGtkStyle " ) ;
return T QString( " sliderGtkStyle " ) ;
}
}