summaryrefslogtreecommitdiff
authorhrw <hrw>2005-10-17 13:28:09 (UTC)
committer hrw <hrw>2005-10-17 13:28:09 (UTC)
commit9f41cd10ef92daa889f86cb43793dc75de18e786 (patch) (side-by-side diff)
treee4df791fa7922f6857d645d81481de98e5bfeaeb
parent965a373e7685c8ae2cfc9955efe20424aa95e10c (diff)
downloadopie-9f41cd10ef92daa889f86cb43793dc75de18e786.zip
opie-9f41cd10ef92daa889f86cb43793dc75de18e786.tar.gz
opie-9f41cd10ef92daa889f86cb43793dc75de18e786.tar.bz2
Appearance: Added configuration options to set smallIconSize, bigIconSize, useBigPixmaps
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--ChangeLog2
-rw-r--r--noncore/settings/appearance2/appearance.cpp37
-rw-r--r--noncore/settings/appearance2/appearance.h5
3 files changed, 43 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 85a26bd..2922afd 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,54 +1,54 @@
2005-??-?? Opie 1.2.2
New Features
------------
-
+ * Appearance: Added configuration options to set smallIconSize, bigIconSize, useBigPixmaps (hrw)
Fixed Bugs
----------
* #1695 - Date selector use too small fontsize on VGA screen (hrw)
* #1686 - opie-console lack UI setting for switching scrollbar (hrw)
* #1624 - Button settngs changes are applied only after restart (hrw)
* #1492 - Backup and Restore does not show list of backups to restore on start (hrw)
* n.a. - remove hardcoded font size from wellenreiter (hrw)
* n.a. - added patch to build QT/E 2.3.10 with gc 4.x.x (hrw)
2005-09-11 Opie 1.2.1
New Features
------------
* OpieStumbler: Scans WiFi networks using the wireless extension scanning (skyhusker)
* Opie-Reader: Support for document formats ArriereGo and Reb, add flite output (tim,pohly)
* Opie-Networksettings: Add support for wlan-ng devices and improve WEP handling (Dirk Opfer)
* Wellenreiter: Remove Joining networks - use OpieStumbler for that (mickeyl)
* Opie-Mobilemsg has gone unsupported - it never really worked and there will be a replacement (mickeyl)
* Opie-Tabmanager has gone unsupported - it barely works and there is not much of a use of it anyway (mickeyl)
* Checkbook: Added configuration option to use smaller font for checkbook transaction tab (hrw)
* ZSafe: Made UI conform to Opie standards (drw)
* Today Addressbook plugin: Fixed configuration to show/not show birthdays, use checkboxes for selection (hrw)
* Opie-Console: Read initial fixed font configuration from qpe.conf (mickeyl)
* Opie-PcmciaApplet: Configure insert/resume actions and bind unsupported cards (mickeyl)
* SysInfo: Remove CPU tab and add Devices tab instead (mickeyl)
* Opie-smb: Added Opie front end for Samba (ljp)
* Opie-Bluetooth: Replace obex send implementation and patch libopieobex and the bluetoothapplet (Michael Haynie)
* Opieplayer: rudimentary podcast support (ljp)
Fixed Bugs
----------
* #1377 - Suspend Powermanagement when switched to another VT (mickeyl)
- We actually suspend the complete Opie now in that case.
* #1384 - Battery status updated improperly when charging (skyhusker)
* #1476 - Wrong order of application entries in the O-menu (skyhusker)
* #1514 - Remove usage of cardmon/pcmcia picture in applications. pcmcia is now an inline picture (mickeyl)
* #1535 - Missing line break and unnecessary location shown with Today-Calendar plugin (deller)
* #1543 - Time Settings: "predict" tab is displayed twice after reopen (hrw)
* #1546 - Battery applet popup is not always large enough to show jacket remaining info (skyhusker)
* #1557 - Light&Power-Settings don't store warning intervall and warning levels (skyhusker)
* #1565 - crash-fix in odevice.cpp while scanning the distribution table (deller)
* #1614 - Make Opie-console start in $HOME instead of / (skyhusker)
* #1635 - opie-today, datebook-plugin does not show notes (skyhusker)
* #1665 - Opie-IRC displays the host prepended to the message when peer is using and ipv6 address (skyhusker)
* #1666 - Opie-IRC does not allow to add !channels in config as autojoin ones (skyhusker)
* #1667 - Opie-IRC does not show messages from !channel (skyhusker)
diff --git a/noncore/settings/appearance2/appearance.cpp b/noncore/settings/appearance2/appearance.cpp
index eea1a19..054b645 100644
--- a/noncore/settings/appearance2/appearance.cpp
+++ b/noncore/settings/appearance2/appearance.cpp
@@ -349,96 +349,129 @@ QWidget *Appearance::createAdvancedTab ( QWidget *parent, Config &cfg )
m_original_tabpos = tabtop;
vertLayout-> addSpacing ( 3 );
QHBoxLayout *rotLay = new QHBoxLayout ( vertLayout, 3 );
QLabel* rotlabel = new QLabel( tr( "Rotation direction:" ), tab );
m_rotdir_cw = new QRadioButton( tab, "rotdir_cw" );
m_rotdir_ccw = new QRadioButton( tab, "rotdir_ccw" );
m_rotdir_flip = new QRadioButton( tab, "rotdir_flip" );
QButtonGroup* rotbtngrp = new QButtonGroup( tab, "rotbuttongroup" );
rotbtngrp-> hide ( );
rotbtngrp-> setExclusive ( true );
rotbtngrp-> insert ( m_rotdir_cw );
rotbtngrp-> insert ( m_rotdir_ccw );
rotbtngrp-> insert ( m_rotdir_flip );
QImage ccwImage = Opie::Core::OResource::loadImage( "redo", Opie::Core::OResource::SmallIcon );
QPixmap cw, ccw, flip;
cw.convertFromImage( ccwImage );
ccw.convertFromImage( ccwImage.mirror( 1, 0 ) );
flip.convertFromImage( Opie::Core::OResource::loadImage( "pass", Opie::Core::OResource::SmallIcon ) );
m_rotdir_cw-> setPixmap( cw );
m_rotdir_ccw-> setPixmap( ccw );
m_rotdir_flip-> setPixmap( flip );
rotLay-> addWidget ( rotlabel, 0 );
rotLay-> addWidget ( m_rotdir_cw, 0 );
rotLay-> addWidget ( m_rotdir_ccw, 0 );
rotLay-> addWidget ( m_rotdir_flip, 0 );
int rotDirection = cfg.readNumEntry( "rotatedir" );
ODirection rot = CW;
if (rotDirection == -1)
{
rot = ODevice::inst ( )-> direction ( );
}
else
{
rot = (ODirection)rotDirection;
}
m_rotdir_cw-> setChecked ( rot == CW );
m_rotdir_ccw-> setChecked ( rot == CCW );
m_rotdir_flip-> setChecked ( rot == Flip );
+ QFrame *f2 = new QFrame ( tab );
+ f2-> setFrameStyle ( QFrame::HLine | QFrame::Sunken );
+ vertLayout-> addWidget ( f2 );
+ vertLayout-> addSpacing ( 3 );
+
+ QHBoxLayout *bigIconlay = new QHBoxLayout ( vertLayout, 3 );
+
+ QLabel* label2 = new QLabel( tr( "&Big Icon size:" ), tab );
+ bigIconlay-> addWidget ( label2, 0, 0 );
+
+ m_bigIconSize = new QSpinBox(0, 128, 1, tab);
+ m_bigIconSize->setValue(cfg.readNumEntry( "BigIconSize" ));
+ bigIconlay->addWidget( m_bigIconSize );
+ label2->setBuddy( m_bigIconSize );
+ QWhatsThis::add( label2, tr( "Big Icon Size determines the size of the application icons in Launcher" ) );
+ QWhatsThis::add( m_bigIconSize, tr( "Big Icon Size determines the size of the application icons in Launcher" ) );
+
+ QHBoxLayout *smallIconlay = new QHBoxLayout ( vertLayout, 3 );
+
+ QLabel* label3 = new QLabel( tr( "&Small Icon size:" ), tab );
+ smallIconlay-> addWidget ( label3, 0, 0 );
+
+ m_smallIconSize = new QSpinBox(0, 128, 1, tab);
+ m_smallIconSize->setValue(cfg.readNumEntry( "SmallIconSize" ));
+ smallIconlay->addWidget( m_smallIconSize );
+ label3->setBuddy( m_smallIconSize );
+ QWhatsThis::add( label3, tr( "Small Icon Size determines the size of many of the icons seen in applications (in menus, tab bars, tool bars, etc.), as well as the size of taskbar." ) );
+ QWhatsThis::add( m_smallIconSize, tr( "Small Icon Size determines the size of many of the icons seen in applications (in menus, tab bars, tool bars, etc.), as well as the size of taskbar." ) );
+
+ m_useBigPixmaps = new QCheckBox( tr("use Big &Pixmaps"), tab);
+ m_useBigPixmaps->setChecked(cfg.readBoolEntry( "useBigPixmaps" ));
+ vertLayout->addWidget( m_useBigPixmaps );
+ QWhatsThis::add( m_useBigPixmaps, tr( "Enlarge toolbar pixmaps" ) );
/*
* add a spacing
*/
vertLayout->addItem( new QSpacerItem( 1, 1, QSizePolicy::MinimumExpanding, QSizePolicy::MinimumExpanding ) );
return tab;
}
Appearance::Appearance( QWidget* parent, const char* name, WFlags )
: QDialog ( parent, name, true, WStyle_ContextHelp )
{
setCaption( tr( "Appearance Settings" ) );
Config config( "qpe" );
config.setGroup( "Appearance" );
QVBoxLayout *top = new QVBoxLayout ( this, 3, 3 );
m_sample = new SampleWindow ( this );
m_sample-> setDecoration ( new DefaultWindowDecoration ( ) );
QWhatsThis::add( m_sample, tr( "This is a preview window. Look here to see your new appearance as options are changed." ) );
OTabWidget* tw = new OTabWidget ( this, "tabwidget", OTabWidget::Global, OTabWidget::Bottom );
QWidget *styletab;
m_color_list = 0;
tw-> addTab ( styletab = createStyleTab ( tw, config ), "appearance", tr( "Style" ));
tw-> addTab ( createFontTab ( tw, config ), "font", tr( "Font" ));
tw-> addTab ( createColorTab ( tw, config ), "appearance/color", tr( "Colors" ) );
tw-> addTab ( createDecoTab ( tw, config ), "appearance/deco", tr( "Windows" ) );
tw-> addTab ( m_advtab = createAdvancedTab ( tw, config ), "SettingsIcon", tr( "Advanced" ) );
top-> addWidget ( tw, 10 );
top-> addWidget ( m_sample, 1 );
tw-> setCurrentTab ( styletab );
connect ( tw, SIGNAL( currentChanged(QWidget*)), this, SLOT( tabChanged(QWidget*)));
m_style_changed = m_font_changed = m_color_changed = m_deco_changed = false;
}
Appearance::~Appearance()
{}
void Appearance::tabChanged ( QWidget *w )
@@ -468,96 +501,100 @@ void Appearance::accept ( )
}
if ( m_deco_changed )
{
DecoListItem *item = (DecoListItem *) m_deco_list-> item ( m_deco_list-> currentItem ( ));
if ( item )
config.writeEntry( "Decoration", item-> key ( ));
}
if (( newtabstyle != m_original_tabstyle ) || ( newtabpos != m_original_tabpos ))
{
config. writeEntry ( "TabStyle", newtabstyle + 1 );
config. writeEntry ( "TabPosition", newtabpos ? "Top" : "Bottom" );
}
if ( m_font_changed )
{
config. writeEntry ( "FontFamily", m_fontselect-> fontFamily ( ));
config. writeEntry ( "FontStyle", m_fontselect-> fontStyle ( ));
config. writeEntry ( "FontSize", m_fontselect-> fontSize ( ));
}
if ( m_color_changed )
{
ColorListItem *item = (ColorListItem *) m_color_list-> item ( m_color_list-> currentItem ( ));
if ( item )
item-> save ( config );
}
ODirection rot;
if (m_rotdir_ccw-> isChecked ( ))
{
rot = CCW;
}
else if (m_rotdir_cw-> isChecked ( ))
{
rot = CW;
}
else
{
rot = Flip;
}
config. writeEntry ( "rotatedir", (int)rot );
config. writeEntry( "LeftHand", m_leftHand->isChecked() );
+ config. writeEntry( "useBigPixmaps", m_useBigPixmaps->isChecked() );
+ config. writeEntry( "BigIconSize", m_bigIconSize->value() );
+ config. writeEntry( "SmallIconSize", m_smallIconSize->value() );
+
config. write ( ); // need to flush the config info first
Global::applyStyle ( );
QDialog::accept ( );
}
void Appearance::done ( int r )
{
QDialog::done ( r );
close ( );
}
void Appearance::styleClicked ( int index )
{
StyleListItem *sli = (StyleListItem *) m_style_list-> item ( index );
m_style_settings-> setEnabled ( sli ? sli-> hasSettings ( ) : false );
if ( m_sample && sli && sli-> style ( ))
{
int ci = m_color_list ? m_color_list-> currentItem ( ) : -1;
m_sample-> setStyle2 ( sli-> style ( ), ci < 0 ? palette ( ) : ((ColorListItem *) m_color_list-> item ( ci ))-> palette ( ));
}
m_style_changed |= ( index != m_original_style );
}
void Appearance::styleSettingsClicked ( )
{
StyleListItem *item = (StyleListItem *) m_style_list-> item ( m_style_list-> currentItem ( ));
if ( item && item-> hasSettings ( ))
{
QDialog *d = new QDialog ( this, "SETTINGS-DLG", true );
QVBoxLayout *vbox = new QVBoxLayout ( d, 3, 0 );
QWidget *w = item-> settings ( d );
if ( w )
{
vbox-> addWidget ( w );
d-> setCaption ( w-> caption ( ));
bool accepted = ( QPEApplication::execDialog ( d ) == QDialog::Accepted );
if ( item-> setSettings ( accepted ))
diff --git a/noncore/settings/appearance2/appearance.h b/noncore/settings/appearance2/appearance.h
index ef7e874..79e71eb 100644
--- a/noncore/settings/appearance2/appearance.h
+++ b/noncore/settings/appearance2/appearance.h
@@ -1,128 +1,133 @@
/*
                This file is part of the Opie Project
Copyright (c) 2002 Dan Williams <drw@handhelds.org>
Copyright (c) 2002 Robert Griebl <sandman@handhelds.org>
=.
.=l.
           .>+-=
 _;:,     .>    :=|. This program 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 program 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 <opie2/ofontselector.h>
#include <qpe/fontdatabase.h>
#include <qdialog.h>
+#include <qspinbox.h>
using Opie::Ui::OFontSelector;
class QCheckBox;
class QComboBox;
class QLabel;
class QLineEdit;
class QListBox;
class QMultiLineEdit;
class QPushButton;
class QRadioButton;
class QToolButton;
class SampleWindow;
namespace Opie {namespace Ui {class OFontSelector;}}
class QListView;
class QListViewItem;
class Config;
class Appearance : public QDialog
{
Q_OBJECT
public:
Appearance( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
~Appearance();
static QString appName() { return QString::fromLatin1("appearance"); }
protected:
virtual void accept ( );
virtual void done ( int r );
protected slots:
void styleClicked ( int );
void styleSettingsClicked ( );
void decoClicked ( int );
void fontClicked ( const QFont & );
void colorClicked ( int );
void editSchemeClicked();
void saveSchemeClicked();
void deleteSchemeClicked();
void tabChanged ( QWidget * );
private:
void changeText();
QWidget *createStyleTab ( QWidget *parent, Config &cfg );
QWidget *createDecoTab ( QWidget *parent, Config &cfg );
QWidget *createFontTab ( QWidget *parent, Config &cfg );
QWidget *createColorTab ( QWidget *parent, Config &cfg );
QWidget *createAdvancedTab ( QWidget *parent, Config &cfg );
private:
bool m_style_changed;
bool m_font_changed;
bool m_scheme_changed;
bool m_deco_changed;
bool m_color_changed;
int m_original_style;
int m_original_deco;
int m_original_tabstyle;
bool m_original_tabpos;
QListBox * m_style_list;
QPushButton * m_style_settings;
QListBox * m_deco_list;
QListBox * m_color_list;
Opie::Ui::OFontSelector *m_fontselect;
SampleWindow *m_sample;
QComboBox * m_tabstyle_list;
QRadioButton *m_tabstyle_top;
QRadioButton *m_tabstyle_bottom;
QRadioButton *m_rotdir_cw;
QRadioButton *m_rotdir_ccw;
QRadioButton *m_rotdir_flip;
QWidget * m_advtab;
QCheckBox *m_leftHand;
+
+ QSpinBox *m_bigIconSize;
+ QSpinBox *m_smallIconSize;
+ QCheckBox *m_useBigPixmaps;
};
#endif