summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/settings/appearance2/appearance.cpp62
-rw-r--r--noncore/settings/appearance2/appearance.h50
-rw-r--r--noncore/settings/appearance2/colorlistitem.h28
-rw-r--r--noncore/settings/appearance2/decolistitem.h27
-rw-r--r--noncore/settings/appearance2/editScheme.cpp116
-rw-r--r--noncore/settings/appearance2/editScheme.h73
-rw-r--r--noncore/settings/appearance2/main.cpp46
-rw-r--r--noncore/settings/appearance2/sample.cpp29
-rw-r--r--noncore/settings/appearance2/sample.h29
-rw-r--r--noncore/settings/appearance2/stylelistitem.h28
10 files changed, 318 insertions, 170 deletions
diff --git a/noncore/settings/appearance2/appearance.cpp b/noncore/settings/appearance2/appearance.cpp
index 23630c5..66cf2c3 100644
--- a/noncore/settings/appearance2/appearance.cpp
+++ b/noncore/settings/appearance2/appearance.cpp
@@ -1,47 +1,51 @@
-/**********************************************************************
-** Copyright (C) 2000-2002 Trolltech AS. All rights reserved.
-**
-** This file is part of the Qtopia Environment.
-**
-** This file may be distributed and/or modified under the terms of the
-** GNU General Public License version 2 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file.
-**
-** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
-** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-**
-** See http://www.trolltech.com/gpl/ for GPL licensing information.
-**
-** Contact info@trolltech.com if any conditions of this licensing are
-** not clear to you.
-**
-***********************************************************************
-**
-** Enhancements by: Dan Williams, <williamsdr@acm.org>
-**
-**********************************************************************/
+/*
+               =. This file is part of the OPIE Project
+             .=l. Copyright (c) 2002 Robert Griebl <sandman@handhelds.org>
+           .>+-=
+ _;:,     .>    :=|. This library is free software; you can
+.> <`_,   >  .   <= redistribute it and/or modify it under
+:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
+.="- .-=="i,     .._ License as published by the Free Software
+ - .   .-<_>     .<> Foundation; either version 2 of the License,
+     ._= =}       : or (at your option) any later version.
+    .%`+i>       _;_.
+    .i_,=:_.      -<s. This library is distributed in the hope that
+     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
+    : ..    .:,     . . . without even the implied warranty of
+    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
+  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
+..}^=.=       =       ; Library General Public License for more
+++=   -.     .`     .: details.
+ :     =  ...= . :.=-
+ -.   .:....=;==+<; You should have received a copy of the GNU
+  -_. . .   )=.  = Library General Public License along with
+    --        :-=` this library; see the file COPYING.LIB.
+ If not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA.
+
+*/
#include "appearance.h"
#include "editScheme.h"
#include <opie/ofiledialog.h>
#include <opie/otabwidget.h>
#include <qpe/applnk.h>
#include <qpe/config.h>
#include <qpe/global.h>
#include <qpe/resource.h>
#include <qpe/qpeapplication.h>
#if defined(Q_WS_QWS) && !defined(QT_NO_COP)
#include <qpe/qcopenvelope_qws.h>
#endif
#include <qaction.h>
#include <qbuttongroup.h>
#include <qcheckbox.h>
#include <qcombobox.h>
#include <qdialog.h>
#include <qdir.h>
#include <qlabel.h>
#include <qlayout.h>
@@ -469,71 +473,71 @@ void Appearance::decoClicked ( int index )
}
void Appearance::fontClicked ( const QFont &f )
{
m_font_changed |= ( f != m_sample-> font ( ));
m_sample-> setFont ( f );
}
void Appearance::colorClicked ( int index )
{
ColorListItem *item = (ColorListItem *) m_color_list-> item ( index );
if ( item )
m_sample-> setPalette ( item-> palette ( ));
m_color_changed |= ( item-> palette ( ) != qApp-> palette ( ));
}
void Appearance::editSchemeClicked ( )
{
ColorListItem *item = (ColorListItem *) m_color_list-> item ( m_color_list-> currentItem ( ));
int cnt = 0;
- QString controlLabel [QColorGroup::NColorRoles];
- QString controlColor [QColorGroup::NColorRoles];
+ QString labels [QColorGroup::NColorRoles];
+ QColor colors [QColorGroup::NColorRoles];
for ( QColorGroup::ColorRole role = (QColorGroup::ColorRole) 0; role != QColorGroup::NColorRoles; ((int) role )++ ) {
QColor col = item-> color ( role );
if ( col. isValid ( )) {
- controlLabel [cnt] = item-> label ( role );
- controlColor [cnt] = col. name ( );
+ labels [cnt] = item-> label ( role );
+ colors [cnt] = col;
cnt++;
}
}
- EditScheme* editdlg = new EditScheme( this, "editScheme", true, 0, cnt, controlLabel, controlColor );
+ EditScheme* editdlg = new EditScheme( cnt, labels, colors, this, "editScheme", true );
editdlg-> showMaximized ( );
if ( editdlg-> exec ( ) == QDialog::Accepted ) {
ColorListItem *citem = (ColorListItem *) m_color_list-> item ( 0 );
cnt = 0;
for ( QColorGroup::ColorRole role = (QColorGroup::ColorRole) 0; role != QColorGroup::NColorRoles; ((int) role )++ ) {
if ( item-> color ( role ). isValid ( )) {
- citem-> setColor ( role, QColor ( controlColor [cnt] ));
+ citem-> setColor ( role, colors [cnt] );
cnt++;
}
}
m_color_list-> setCurrentItem ( 0 );
colorClicked ( 0 );
m_color_changed = true;
}
delete editdlg;
}
void Appearance::saveSchemeClicked()
{
ColorListItem *item = (ColorListItem *) m_color_list-> item ( m_color_list-> currentItem ( ));
if ( !item )
return;
QDialog *d = new QDialog ( this, 0, true );
d-> setCaption ( tr( "Save Scheme" ));
QLineEdit *ed = new QLineEdit ( this );
( new QVBoxLayout ( d, 4, 4 ))-> addWidget ( ed );
diff --git a/noncore/settings/appearance2/appearance.h b/noncore/settings/appearance2/appearance.h
index 4a86e57..ddf94f2 100644
--- a/noncore/settings/appearance2/appearance.h
+++ b/noncore/settings/appearance2/appearance.h
@@ -1,47 +1,51 @@
-/**********************************************************************
-** Copyright (C) 2000-2002 Trolltech AS. All rights reserved.
-**
-** This file is part of the Qtopia Environment.
-**
-** This file may be distributed and/or modified under the terms of the
-** GNU General Public License version 2 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file.
-**
-** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
-** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-**
-** See http://www.trolltech.com/gpl/ for GPL licensing information.
-**
-** Contact info@trolltech.com if any conditions of this licensing are
-** not clear to you.
-**
-***********************************************************************
-**
-** Enhancements by: Dan Williams, <williamsdr@acm.org>
-**
-**********************************************************************/
+/*
+               =. This file is part of the OPIE Project
+             .=l. Copyright (c) 2002 Robert Griebl <sandman@handhelds.org>
+           .>+-=
+ _;:,     .>    :=|. This library is free software; you can
+.> <`_,   >  .   <= redistribute it and/or modify it under
+:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
+.="- .-=="i,     .._ License as published by the Free Software
+ - .   .-<_>     .<> Foundation; either version 2 of the License,
+     ._= =}       : or (at your option) any later version.
+    .%`+i>       _;_.
+    .i_,=:_.      -<s. This library is distributed in the hope that
+     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
+    : ..    .:,     . . . without even the implied warranty of
+    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
+  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
+..}^=.=       =       ; Library General Public License for more
+++=   -.     .`     .: details.
+ :     =  ...= . :.=-
+ -.   .:....=;==+<; You should have received a copy of the GNU
+  -_. . .   )=.  = Library General Public License along with
+    --        :-=` this library; see the file COPYING.LIB.
+ If not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA.
+
+*/
#ifndef APPEARANCESETTINGS_H
#define APPEARANCESETTINGS_H
#include <qpe/fontdatabase.h>
#include <qmainwindow.h>
#include <qdialog.h>
class QCheckBox;
class QComboBox;
class QLabel;
class QLineEdit;
class QListBox;
class QMultiLineEdit;
class QPushButton;
class QRadioButton;
class QToolButton;
class SampleWindow;
class OFontSelector;
class Appearance : public QDialog
{
Q_OBJECT
diff --git a/noncore/settings/appearance2/colorlistitem.h b/noncore/settings/appearance2/colorlistitem.h
index 1ff6ecc..1df541b 100644
--- a/noncore/settings/appearance2/colorlistitem.h
+++ b/noncore/settings/appearance2/colorlistitem.h
@@ -1,24 +1,52 @@
+/*
+               =. This file is part of the OPIE Project
+             .=l. Copyright (c) 2002 Robert Griebl <sandman@handhelds.org>
+           .>+-=
+ _;:,     .>    :=|. This library is free software; you can
+.> <`_,   >  .   <= redistribute it and/or modify it under
+:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
+.="- .-=="i,     .._ License as published by the Free Software
+ - .   .-<_>     .<> Foundation; either version 2 of the License,
+     ._= =}       : or (at your option) any later version.
+    .%`+i>       _;_.
+    .i_,=:_.      -<s. This library is distributed in the hope that
+     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
+    : ..    .:,     . . . without even the implied warranty of
+    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
+  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
+..}^=.=       =       ; Library General Public License for more
+++=   -.     .`     .: details.
+ :     =  ...= . :.=-
+ -.   .:....=;==+<; You should have received a copy of the GNU
+  -_. . .   )=.  = Library General Public License along with
+    --        :-=` this library; see the file COPYING.LIB.
+ If not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA.
+
+*/
+
#ifndef COLORLISTITEM_H
#define COLORLISTITEM_H
#include <qlistbox.h>
#include <qpalette.h>
#include <qapplication.h>
#include <qpe/config.h>
class Appearance;
class ColorListItem : public QListBoxText {
public:
ColorListItem ( const QString &t, Config &cfg ) : QListBoxText ( t )
{
m_colors = new QColor [s_colorcount];
load ( cfg );
}
virtual ~ColorListItem ( )
{
delete [] m_colors;
}
diff --git a/noncore/settings/appearance2/decolistitem.h b/noncore/settings/appearance2/decolistitem.h
index dfdce47..953a939 100644
--- a/noncore/settings/appearance2/decolistitem.h
+++ b/noncore/settings/appearance2/decolistitem.h
@@ -1,24 +1,51 @@
+/*
+               =. This file is part of the OPIE Project
+             .=l. Copyright (c) 2002 Robert Griebl <sandman@handhelds.org>
+           .>+-=
+ _;:,     .>    :=|. This library is free software; you can
+.> <`_,   >  .   <= redistribute it and/or modify it under
+:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
+.="- .-=="i,     .._ License as published by the Free Software
+ - .   .-<_>     .<> Foundation; either version 2 of the License,
+     ._= =}       : or (at your option) any later version.
+    .%`+i>       _;_.
+    .i_,=:_.      -<s. This library is distributed in the hope that
+     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
+    : ..    .:,     . . . without even the implied warranty of
+    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
+  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
+..}^=.=       =       ; Library General Public License for more
+++=   -.     .`     .: details.
+ :     =  ...= . :.=-
+ -.   .:....=;==+<; You should have received a copy of the GNU
+  -_. . .   )=.  = Library General Public License along with
+    --        :-=` this library; see the file COPYING.LIB.
+ If not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA.
+
+*/
#ifndef DECOLISTITEM_H
#define DECOLISTITEM_H
#include <qpe/windowdecorationinterface.h>
#include <qlistbox.h>
class DecoListItem : public QListBoxText {
public:
DecoListItem ( const QString &t ) : QListBoxText ( t )
{
m_lib = 0;
m_window_if = 0;
// m_settings_if = 0;
}
DecoListItem ( QLibrary *lib, WindowDecorationInterface *iface ) : QListBoxText ( iface-> name ( ))
{
m_lib = lib;
m_window_if = iface;
// iface-> queryInterface ( IID_WindowDecoration, (QUnknownInterface **) &m_settings_if );
}
virtual ~DecoListItem ( )
diff --git a/noncore/settings/appearance2/editScheme.cpp b/noncore/settings/appearance2/editScheme.cpp
index 4f2ac2c..8cb0f1c 100644
--- a/noncore/settings/appearance2/editScheme.cpp
+++ b/noncore/settings/appearance2/editScheme.cpp
@@ -1,87 +1,73 @@
-/**********************************************************************
-** EditScheme
-**
-** Dialog for editing color scheme
-**
-** Copyright (C) 2002, Dan Williams
-** williamsdr@acm.org
-** http://draknor.net
-**
-** This file may be distributed and/or modified under the terms of the
-** GNU General Public License version 2 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file.
-**
-** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
-** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-**
-**********************************************************************/
+/*
+               =. This file is part of the OPIE Project
+             .=l. Copyright (c) 2002 Robert Griebl <sandman@handhelds.org>
+           .>+-=
+ _;:,     .>    :=|. This library is free software; you can
+.> <`_,   >  .   <= redistribute it and/or modify it under
+:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
+.="- .-=="i,     .._ License as published by the Free Software
+ - .   .-<_>     .<> Foundation; either version 2 of the License,
+     ._= =}       : or (at your option) any later version.
+    .%`+i>       _;_.
+    .i_,=:_.      -<s. This library is distributed in the hope that
+     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
+    : ..    .:,     . . . without even the implied warranty of
+    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
+  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
+..}^=.=       =       ; Library General Public License for more
+++=   -.     .`     .: details.
+ :     =  ...= . :.=-
+ -.   .:....=;==+<; You should have received a copy of the GNU
+  -_. . .   )=.  = Library General Public License along with
+    --        :-=` this library; see the file COPYING.LIB.
+ If not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA.
+
+*/
#include "editScheme.h"
-#include "opie/colorpopupmenu.h"
+#include <opie/ocolorbutton.h>
#include <qaction.h>
#include <qlabel.h>
#include <qlayout.h>
#include <qpopupmenu.h>
#include <qscrollview.h>
#include <qtoolbutton.h>
-EditScheme::EditScheme( QWidget* parent, const char* name, bool modal, WFlags fl,
- int max, QString *list, QString *colors )
- : QDialog( parent, name, modal, fl )
+EditScheme::EditScheme ( int cnt, const QString *labels, QColor *colors, QWidget* parent, const char* name, bool modal, WFlags fl )
+ : QDialog ( parent, name, modal, fl )
{
- setCaption( tr( "Edit scheme" ) );
- QGridLayout* layout = new QGridLayout( this );
- layout->setSpacing( 4 );
- layout->setMargin( 4 );
-
+ setCaption ( tr( "Edit scheme" ) );
+ QGridLayout *layout = new QGridLayout ( this, 0, 0, 4, 4 );
- maxCount = max;
- colorList = colors;
- surfaceList = list;
- colorButtons = new QToolButton * [max];
- int i;
- QLabel* label;
- ColorPopupMenu* colorPopupMenu;
- for ( i = 0; i < max; i++ )
+ m_count = cnt;
+ m_buttons = new OColorButton * [cnt];
+ m_colors = colors;
+
+ for ( int i = 0; i < cnt; i++ )
{
-// colorList[i] = colors[i];
-// surfaceList[i] = list[i];
- label = new QLabel( tr( surfaceList[i] ), this );
- layout->addWidget( label, i, 0 );
- colorButtons[i] = new QToolButton( this, list[i] );
- colorButtons[i]->setPalette( QPalette( QColor( colors[i] ) ) );
- layout->addWidget( colorButtons[i], i, 1 );
-
- colorPopupMenu = new ColorPopupMenu( colors[i], 0, list[i] );
- colorButtons[i]->setPopup( colorPopupMenu );
- colorButtons[i]->setPopupDelay( 0 );
- connect( colorPopupMenu, SIGNAL( colorSelected( const QColor& ) ), this, SLOT( changeColor( const QColor& ) ) );
+ QLabel *l = new QLabel ( labels [i], this );
+ layout-> addWidget ( l, i, 0 );
+
+ m_buttons [i] = new OColorButton ( this );
+ m_buttons [i]-> setColor ( colors [i] );
+ layout-> addWidget ( m_buttons [i], i, 1 );
}
}
-EditScheme::~EditScheme()
+EditScheme::~EditScheme ( )
{
- delete [] colorButtons;
+ delete [] m_buttons;
}
-void EditScheme::changeColor( const QColor& color )
+void EditScheme::accept ( )
{
- QString name( sender()->name() );
- int i;
-
- for ( i = 0; i < maxCount; i++ )
- {
- if ( name == colorButtons[i]->name() )
- {
- break;
- }
- }
- if ( i < maxCount && name == colorButtons[i]->name() )
- {
- colorList[i] = color.name();
- colorButtons[i]->setPalette( QPalette( QColor( colorList[i] ) ) );
- }
+ for ( int i = 0; i < m_count; i++ )
+ m_colors [i] = m_buttons [i]-> color ( );
+
+ QDialog::accept ( );
}
+
diff --git a/noncore/settings/appearance2/editScheme.h b/noncore/settings/appearance2/editScheme.h
index 583050f..0a025bd 100644
--- a/noncore/settings/appearance2/editScheme.h
+++ b/noncore/settings/appearance2/editScheme.h
@@ -1,48 +1,53 @@
-/**********************************************************************
-** EditScheme
-**
-** Dialog for editing color scheme
-**
-** Copyright (C) 2002, Dan Williams
-** williamsdr@acm.org
-** http://draknor.net
-**
-** This file may be distributed and/or modified under the terms of the
-** GNU General Public License version 2 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file.
-**
-** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
-** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-**
-**********************************************************************/
+/*
+               =. This file is part of the OPIE Project
+             .=l. Copyright (c) 2002 Robert Griebl <sandman@handhelds.org>
+           .>+-=
+ _;:,     .>    :=|. This library is free software; you can
+.> <`_,   >  .   <= redistribute it and/or modify it under
+:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
+.="- .-=="i,     .._ License as published by the Free Software
+ - .   .-<_>     .<> Foundation; either version 2 of the License,
+     ._= =}       : or (at your option) any later version.
+    .%`+i>       _;_.
+    .i_,=:_.      -<s. This library is distributed in the hope that
+     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
+    : ..    .:,     . . . without even the implied warranty of
+    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
+  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
+..}^=.=       =       ; Library General Public License for more
+++=   -.     .`     .: details.
+ :     =  ...= . :.=-
+ -.   .:....=;==+<; You should have received a copy of the GNU
+  -_. . .   )=.  = Library General Public License along with
+    --        :-=` this library; see the file COPYING.LIB.
+ If not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA.
+
+*/
#ifndef EDITSCHEME_H
#define EDITSCHEME_H
#include <qdialog.h>
-#include <qtoolbutton.h>
class QColor;
+class OColorButton;
-class EditScheme : public QDialog
-{
- Q_OBJECT
+class EditScheme : public QDialog {
+ Q_OBJECT
public:
- EditScheme( QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0,
- int = 0, QString * = 0, QString * = 0 );
- ~EditScheme();
-
- int maxCount;
- QString * surfaceList;
- QString * colorList;
-
-
- QToolButton** colorButtons;
+ EditScheme ( int cnt, const QString *labels, QColor *colors, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0 );
+ virtual ~EditScheme ( );
protected slots:
- void changeColor( const QColor& );
+ virtual void accept ( );
+
+private:
+ int m_count;
+ QColor *m_colors;
+ OColorButton **m_buttons;
};
-#endif // EDITSCHEME_H
+#endif
diff --git a/noncore/settings/appearance2/main.cpp b/noncore/settings/appearance2/main.cpp
index cfbab0b..3afec46 100644
--- a/noncore/settings/appearance2/main.cpp
+++ b/noncore/settings/appearance2/main.cpp
@@ -1,35 +1,43 @@
-/**********************************************************************
-** Copyright (C) 2000 Trolltech AS. All rights reserved.
-**
-** This file is part of Qtopia Environment.
-**
-** This file may be distributed and/or modified under the terms of the
-** GNU General Public License version 2 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file.
-**
-** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
-** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-**
-** See http://www.trolltech.com/gpl/ for GPL licensing information.
-**
-** Contact info@trolltech.com if any conditions of this licensing are
-** not clear to you.
-**
-**********************************************************************/
+/*
+               =. This file is part of the OPIE Project
+             .=l. Copyright (c) 2002 Robert Griebl <sandman@handhelds.org>
+           .>+-=
+ _;:,     .>    :=|. This library is free software; you can
+.> <`_,   >  .   <= redistribute it and/or modify it under
+:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
+.="- .-=="i,     .._ License as published by the Free Software
+ - .   .-<_>     .<> Foundation; either version 2 of the License,
+     ._= =}       : or (at your option) any later version.
+    .%`+i>       _;_.
+    .i_,=:_.      -<s. This library is distributed in the hope that
+     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
+    : ..    .:,     . . . without even the implied warranty of
+    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
+  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
+..}^=.=       =       ; Library General Public License for more
+++=   -.     .`     .: details.
+ :     =  ...= . :.=-
+ -.   .:....=;==+<; You should have received a copy of the GNU
+  -_. . .   )=.  = Library General Public License along with
+    --        :-=` this library; see the file COPYING.LIB.
+ If not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA.
+
+*/
#include "appearance.h"
#include <qpe/qpeapplication.h>
int main ( int argc, char **argv )
{
QPEApplication app ( argc, argv );
Appearance m;
app. showMainDocumentWidget ( &m );
return app. exec ( );
}
diff --git a/noncore/settings/appearance2/sample.cpp b/noncore/settings/appearance2/sample.cpp
index e447002..0d8b003 100644
--- a/noncore/settings/appearance2/sample.cpp
+++ b/noncore/settings/appearance2/sample.cpp
@@ -1,24 +1,53 @@
+/*
+                This file is part of the OPIE Project
+ =. Copyright (c) 2002 Trolltech AS <info@trolltech.com>
+             .=l. Copyright (c) 2002 Robert Griebl <sandman@handhelds.org>
+           .>+-=
+ _;:,     .>    :=|. This library is free software; you can
+.> <`_,   >  .   <= redistribute it and/or modify it under
+:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
+.="- .-=="i,     .._ License as published by the Free Software
+ - .   .-<_>     .<> Foundation; either version 2 of the License,
+     ._= =}       : or (at your option) any later version.
+    .%`+i>       _;_.
+    .i_,=:_.      -<s. This library is distributed in the hope that
+     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
+    : ..    .:,     . . . without even the implied warranty of
+    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
+  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
+..}^=.=       =       ; Library General Public License for more
+++=   -.     .`     .: details.
+ :     =  ...= . :.=-
+ -.   .:....=;==+<; You should have received a copy of the GNU
+  -_. . .   )=.  = Library General Public License along with
+    --        :-=` this library; see the file COPYING.LIB.
+ If not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA.
+
+*/
+
#include <qvbox.h>
#include <qpopupmenu.h>
#include <qpainter.h>
#include <qmenubar.h>
#include <qcheckbox.h>
#include <qpushbutton.h>
#include <qscrollbar.h>
#include <qlayout.h>
#include <qwhatsthis.h>
#include <qpixmapcache.h>
#include <qtimer.h>
#include <qobjectlist.h>
#include <qcommonstyle.h>
#include "sample.h"
class SampleText : public QWidget
{
public:
SampleText( const QString &t, bool h, QWidget *parent )
: QWidget( parent ), hl(h), text(t)
{
if ( hl )
diff --git a/noncore/settings/appearance2/sample.h b/noncore/settings/appearance2/sample.h
index c6f9b5a..a189f69 100644
--- a/noncore/settings/appearance2/sample.h
+++ b/noncore/settings/appearance2/sample.h
@@ -1,24 +1,53 @@
+/*
+                This file is part of the OPIE Project
+ =. Copyright (c) 2002 Trolltech AS <info@trolltech.com>
+             .=l. Copyright (c) 2002 Robert Griebl <sandman@handhelds.org>
+           .>+-=
+ _;:,     .>    :=|. This library is free software; you can
+.> <`_,   >  .   <= redistribute it and/or modify it under
+:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
+.="- .-=="i,     .._ License as published by the Free Software
+ - .   .-<_>     .<> Foundation; either version 2 of the License,
+     ._= =}       : or (at your option) any later version.
+    .%`+i>       _;_.
+    .i_,=:_.      -<s. This library is distributed in the hope that
+     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
+    : ..    .:,     . . . without even the implied warranty of
+    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
+  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
+..}^=.=       =       ; Library General Public License for more
+++=   -.     .`     .: details.
+ :     =  ...= . :.=-
+ -.   .:....=;==+<; You should have received a copy of the GNU
+  -_. . .   )=.  = Library General Public License along with
+    --        :-=` this library; see the file COPYING.LIB.
+ If not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA.
+
+*/
+
#ifndef __PREVIEW_H__
#define __PREVIEW_H__
#include <qwidget.h>
#include <qpe/windowdecorationinterface.h>
class QVBox;
class QPopupMenu;
class SampleText;
class SampleWindow : public QWidget
{
Q_OBJECT
public:
SampleWindow( QWidget *parent );
QSize sizeHint() const;
virtual void setFont( const QFont &f );
void setStyle2 ( QStyle *sty );
void setDecoration( WindowDecorationInterface *i );
void setPalette ( const QPalette & );
diff --git a/noncore/settings/appearance2/stylelistitem.h b/noncore/settings/appearance2/stylelistitem.h
index 3cc63dc..bbfbd41 100644
--- a/noncore/settings/appearance2/stylelistitem.h
+++ b/noncore/settings/appearance2/stylelistitem.h
@@ -1,24 +1,52 @@
+/*
+               =. This file is part of the OPIE Project
+             .=l. Copyright (c) 2002 Robert Griebl <sandman@handhelds.org>
+           .>+-=
+ _;:,     .>    :=|. This library is free software; you can
+.> <`_,   >  .   <= redistribute it and/or modify it under
+:`=1 )Y*s>-.--   : the terms of the GNU Library General Public
+.="- .-=="i,     .._ License as published by the Free Software
+ - .   .-<_>     .<> Foundation; either version 2 of the License,
+     ._= =}       : or (at your option) any later version.
+    .%`+i>       _;_.
+    .i_,=:_.      -<s. This library is distributed in the hope that
+     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
+    : ..    .:,     . . . without even the implied warranty of
+    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
+  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
+..}^=.=       =       ; Library General Public License for more
+++=   -.     .`     .: details.
+ :     =  ...= . :.=-
+ -.   .:....=;==+<; You should have received a copy of the GNU
+  -_. . .   )=.  = Library General Public License along with
+    --        :-=` this library; see the file COPYING.LIB.
+ If not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA.
+
+*/
+
#ifndef STYLELISTITEM_H
#define STYLELISTITEM_H
#include <qlistbox.h>
#include <qpe/styleinterface.h>
#include <stdio.h>
class StyleListItem : public QListBoxText {
public:
StyleListItem ( const QString &t, QStyle *sty ) : QListBoxText ( t )
{
m_lib = 0;
m_style_if = 0;
m_settings_if = 0;
m_style = sty;
}
StyleListItem ( QLibrary *lib, StyleInterface *iface ) : QListBoxText ( iface-> name ( ))
{
m_lib = lib;
m_style_if = iface;
m_settings_if = 0;
m_style = iface-> create ( );