author | zecke <zecke> | 2004-10-12 12:46:01 (UTC) |
---|---|---|
committer | zecke <zecke> | 2004-10-12 12:46:01 (UTC) |
commit | 2005178f060ca366f78624508400aec8a6b0d291 (patch) (unidiff) | |
tree | b2d58d785341cc84c1224a36ee8ae4327170af55 | |
parent | 363cc582d2a6c9b6fa1409bccaef861ea1bcce15 (diff) | |
download | opie-2005178f060ca366f78624508400aec8a6b0d291.zip opie-2005178f060ca366f78624508400aec8a6b0d291.tar.gz opie-2005178f060ca366f78624508400aec8a6b0d291.tar.bz2 |
Minor GUI polishing
-Use 'better' icons and always QIconSet::Large
-Make the 'Search For' Label to have the same color as the rest of the toolbar
-rw-r--r-- | core/pim/osearch/adresssearch.cpp | 2 | ||||
-rw-r--r-- | core/pim/osearch/applnksearch.cpp | 2 | ||||
-rw-r--r-- | core/pim/osearch/datebooksearch.cpp | 2 | ||||
-rw-r--r-- | core/pim/osearch/doclnksearch.cpp | 4 | ||||
-rw-r--r-- | core/pim/osearch/mainwindow.cpp | 2 | ||||
-rw-r--r-- | core/pim/osearch/todosearch.cpp | 2 |
6 files changed, 8 insertions, 6 deletions
diff --git a/core/pim/osearch/adresssearch.cpp b/core/pim/osearch/adresssearch.cpp index f0495c6..e1f575d 100644 --- a/core/pim/osearch/adresssearch.cpp +++ b/core/pim/osearch/adresssearch.cpp | |||
@@ -9,33 +9,33 @@ | |||
9 | // | 9 | // |
10 | // Copyright: See COPYING file that comes with this distribution | 10 | // Copyright: See COPYING file that comes with this distribution |
11 | // | 11 | // |
12 | // | 12 | // |
13 | #include "adresssearch.h" | 13 | #include "adresssearch.h" |
14 | #include "contactitem.h" | 14 | #include "contactitem.h" |
15 | 15 | ||
16 | #include <qpe/resource.h> | 16 | #include <qpe/resource.h> |
17 | 17 | ||
18 | //#include <qwhatsthis.h> | 18 | //#include <qwhatsthis.h> |
19 | 19 | ||
20 | using namespace Opie; | 20 | using namespace Opie; |
21 | AdressSearch::AdressSearch(QListView* parent, QString name): | 21 | AdressSearch::AdressSearch(QListView* parent, QString name): |
22 | SearchGroup(parent, name) | 22 | SearchGroup(parent, name) |
23 | { | 23 | { |
24 | _contacts = 0; | 24 | _contacts = 0; |
25 | QIconSet is = Resource::loadIconSet( "addressbook/AddressBookSmall" ); | 25 | QIconSet is = Resource::loadIconSet( "addressbook/AddressBook" ); |
26 | setPixmap( 0, is.pixmap( QIconSet::Large, true ) ); | 26 | setPixmap( 0, is.pixmap( QIconSet::Large, true ) ); |
27 | 27 | ||
28 | 28 | ||
29 | //QWhatsThis::add( this, QObject::tr("Search the addressbook") ); | 29 | //QWhatsThis::add( this, QObject::tr("Search the addressbook") ); |
30 | /*QPixmap pix = Resource::loadPixmap( "addressbook/AddressBook" ); | 30 | /*QPixmap pix = Resource::loadPixmap( "addressbook/AddressBook" ); |
31 | QImage img = pix.convertToImage(); | 31 | QImage img = pix.convertToImage(); |
32 | img.smoothScale( 14, 14 ); | 32 | img.smoothScale( 14, 14 ); |
33 | pix.convertFromImage( img ); | 33 | pix.convertFromImage( img ); |
34 | setPixmap( 0, pix );*/ | 34 | setPixmap( 0, pix );*/ |
35 | } | 35 | } |
36 | 36 | ||
37 | 37 | ||
38 | AdressSearch::~AdressSearch() | 38 | AdressSearch::~AdressSearch() |
39 | { | 39 | { |
40 | delete _contacts; | 40 | delete _contacts; |
41 | } | 41 | } |
diff --git a/core/pim/osearch/applnksearch.cpp b/core/pim/osearch/applnksearch.cpp index 758baf2..474dbb2 100644 --- a/core/pim/osearch/applnksearch.cpp +++ b/core/pim/osearch/applnksearch.cpp | |||
@@ -8,33 +8,33 @@ | |||
8 | // Author: Patrick S. Vogt <tille@handhelds.org>, (C) 2003 | 8 | // Author: Patrick S. Vogt <tille@handhelds.org>, (C) 2003 |
9 | // | 9 | // |
10 | // Copyright: See COPYING file that comes with this distribution | 10 | // Copyright: See COPYING file that comes with this distribution |
11 | // | 11 | // |
12 | // | 12 | // |
13 | #include "applnksearch.h" | 13 | #include "applnksearch.h" |
14 | #include "applnkitem.h" | 14 | #include "applnkitem.h" |
15 | 15 | ||
16 | #include <qpe/applnk.h> | 16 | #include <qpe/applnk.h> |
17 | #include <qpe/qpeapplication.h> | 17 | #include <qpe/qpeapplication.h> |
18 | #include <qpe/resource.h> | 18 | #include <qpe/resource.h> |
19 | 19 | ||
20 | 20 | ||
21 | AppLnkSearch::AppLnkSearch(QListView* parent, QString name): SearchGroup(parent, name) | 21 | AppLnkSearch::AppLnkSearch(QListView* parent, QString name): SearchGroup(parent, name) |
22 | { | 22 | { |
23 | _apps = 0; | 23 | _apps = 0; |
24 | QIconSet is = Resource::loadIconSet( "osearch/applicationsSmall" ); | 24 | QIconSet is = Resource::loadIconSet( "osearch/applications" ); |
25 | //QIconSet is = Resource::loadIconSet( "AppsIcon" ); | 25 | //QIconSet is = Resource::loadIconSet( "AppsIcon" ); |
26 | setPixmap( 0, is.pixmap( QIconSet::Large, true ) ); | 26 | setPixmap( 0, is.pixmap( QIconSet::Large, true ) ); |
27 | } | 27 | } |
28 | 28 | ||
29 | 29 | ||
30 | AppLnkSearch::~AppLnkSearch() | 30 | AppLnkSearch::~AppLnkSearch() |
31 | { | 31 | { |
32 | delete _apps; | 32 | delete _apps; |
33 | } | 33 | } |
34 | 34 | ||
35 | 35 | ||
36 | void AppLnkSearch::load() | 36 | void AppLnkSearch::load() |
37 | { | 37 | { |
38 | _apps = new AppLnkSet(QPEApplication::qpeDir()); | 38 | _apps = new AppLnkSet(QPEApplication::qpeDir()); |
39 | } | 39 | } |
40 | 40 | ||
diff --git a/core/pim/osearch/datebooksearch.cpp b/core/pim/osearch/datebooksearch.cpp index 1b44be2..ef3b006 100644 --- a/core/pim/osearch/datebooksearch.cpp +++ b/core/pim/osearch/datebooksearch.cpp | |||
@@ -15,33 +15,33 @@ | |||
15 | 15 | ||
16 | #include <opie2/odebug.h> | 16 | #include <opie2/odebug.h> |
17 | #include <opie2/opimevent.h> | 17 | #include <opie2/opimevent.h> |
18 | #include <opie2/opimrecurrence.h> | 18 | #include <opie2/opimrecurrence.h> |
19 | 19 | ||
20 | #include <qpe/resource.h> | 20 | #include <qpe/resource.h> |
21 | #include <qpe/config.h> | 21 | #include <qpe/config.h> |
22 | 22 | ||
23 | #include <qaction.h> | 23 | #include <qaction.h> |
24 | #include <qpopupmenu.h> | 24 | #include <qpopupmenu.h> |
25 | 25 | ||
26 | 26 | ||
27 | 27 | ||
28 | DatebookSearch::DatebookSearch(QListView* parent, QString name) | 28 | DatebookSearch::DatebookSearch(QListView* parent, QString name) |
29 | : SearchGroup(parent, name), _dates(0), _popupMenu(0) | 29 | : SearchGroup(parent, name), _dates(0), _popupMenu(0) |
30 | { | 30 | { |
31 | QIconSet is = Resource::loadIconSet( "datebook/DateBookSmall" ); | 31 | QIconSet is = Resource::loadIconSet( "datebook/DateBook" ); |
32 | setPixmap( 0, is.pixmap( QIconSet::Large, true ) ); | 32 | setPixmap( 0, is.pixmap( QIconSet::Large, true ) ); |
33 | actionShowPastEvents = new QAction( QObject::tr("Show past events"),QString::null, 0, 0, 0, true ); | 33 | actionShowPastEvents = new QAction( QObject::tr("Show past events"),QString::null, 0, 0, 0, true ); |
34 | actionSearchInDates = new QAction( QObject::tr("Search in dates"),QString::null, 0, 0, 0, true ); | 34 | actionSearchInDates = new QAction( QObject::tr("Search in dates"),QString::null, 0, 0, 0, true ); |
35 | Config cfg( "osearch", Config::User ); | 35 | Config cfg( "osearch", Config::User ); |
36 | cfg.setGroup( "datebook_settings" ); | 36 | cfg.setGroup( "datebook_settings" ); |
37 | actionShowPastEvents->setOn( cfg.readBoolEntry( "show_past_events", false ) ); | 37 | actionShowPastEvents->setOn( cfg.readBoolEntry( "show_past_events", false ) ); |
38 | actionSearchInDates->setOn( cfg.readBoolEntry( "search_in_dates", true ) ); | 38 | actionSearchInDates->setOn( cfg.readBoolEntry( "search_in_dates", true ) ); |
39 | } | 39 | } |
40 | 40 | ||
41 | DatebookSearch::~DatebookSearch() | 41 | DatebookSearch::~DatebookSearch() |
42 | { | 42 | { |
43 | odebug << "SAVE DATEBOOK SEARCH CONFIG" << oendl; | 43 | odebug << "SAVE DATEBOOK SEARCH CONFIG" << oendl; |
44 | Config cfg( "osearch", Config::User ); | 44 | Config cfg( "osearch", Config::User ); |
45 | cfg.setGroup( "datebook_settings" ); | 45 | cfg.setGroup( "datebook_settings" ); |
46 | cfg.writeEntry( "show_past_events", actionShowPastEvents->isOn() ); | 46 | cfg.writeEntry( "show_past_events", actionShowPastEvents->isOn() ); |
47 | cfg.writeEntry( "search_in_dates", actionSearchInDates->isOn() ); | 47 | cfg.writeEntry( "search_in_dates", actionSearchInDates->isOn() ); |
diff --git a/core/pim/osearch/doclnksearch.cpp b/core/pim/osearch/doclnksearch.cpp index 4631dce..3d91c1f 100644 --- a/core/pim/osearch/doclnksearch.cpp +++ b/core/pim/osearch/doclnksearch.cpp | |||
@@ -18,34 +18,34 @@ | |||
18 | #include <opie2/owait.h> | 18 | #include <opie2/owait.h> |
19 | 19 | ||
20 | #include <qpe/applnk.h> | 20 | #include <qpe/applnk.h> |
21 | #include <qpe/config.h> | 21 | #include <qpe/config.h> |
22 | #include <qpe/resource.h> | 22 | #include <qpe/resource.h> |
23 | #include <qpe/qpeapplication.h> | 23 | #include <qpe/qpeapplication.h> |
24 | 24 | ||
25 | #include <qaction.h> | 25 | #include <qaction.h> |
26 | #include <qfile.h> | 26 | #include <qfile.h> |
27 | #include <qpopupmenu.h> | 27 | #include <qpopupmenu.h> |
28 | #include <qtextstream.h> | 28 | #include <qtextstream.h> |
29 | 29 | ||
30 | 30 | ||
31 | DocLnkSearch::DocLnkSearch(QListView* parent, QString name) | 31 | DocLnkSearch::DocLnkSearch(QListView* parent, QString name) |
32 | : AppLnkSearch(parent, name), _popupMenu(0) | 32 | : AppLnkSearch(parent, name), _popupMenu(0) |
33 | { | 33 | { |
34 | QIconSet is = Resource::loadIconSet( "osearch/documentsSmall" ); | 34 | QIconSet is = Resource::loadIconSet( "osearch/documents" ); |
35 | setPixmap( 0, is.pixmap( QIconSet::Automatic, true ) ); | 35 | setPixmap( 0, is.pixmap( QIconSet::Large, true ) ); |
36 | 36 | ||
37 | actionSearchInFiles = new QAction( QObject::tr("Search content"),QString::null, 0, 0, 0, true ); | 37 | actionSearchInFiles = new QAction( QObject::tr("Search content"),QString::null, 0, 0, 0, true ); |
38 | Config cfg( "osearch", Config::User ); | 38 | Config cfg( "osearch", Config::User ); |
39 | cfg.setGroup( "doclnk_settings" ); | 39 | cfg.setGroup( "doclnk_settings" ); |
40 | actionSearchInFiles->setOn( cfg.readBoolEntry( "search_content", false ) ); | 40 | actionSearchInFiles->setOn( cfg.readBoolEntry( "search_content", false ) ); |
41 | } | 41 | } |
42 | 42 | ||
43 | 43 | ||
44 | DocLnkSearch::~DocLnkSearch() | 44 | DocLnkSearch::~DocLnkSearch() |
45 | { | 45 | { |
46 | Config cfg( "osearch", Config::User ); | 46 | Config cfg( "osearch", Config::User ); |
47 | cfg.setGroup( "doclnk_settings" ); | 47 | cfg.setGroup( "doclnk_settings" ); |
48 | cfg.writeEntry( "search_content", actionSearchInFiles->isOn() ); | 48 | cfg.writeEntry( "search_content", actionSearchInFiles->isOn() ); |
49 | } | 49 | } |
50 | 50 | ||
51 | void DocLnkSearch::load() | 51 | void DocLnkSearch::load() |
diff --git a/core/pim/osearch/mainwindow.cpp b/core/pim/osearch/mainwindow.cpp index 4589c9d..1d0331c 100644 --- a/core/pim/osearch/mainwindow.cpp +++ b/core/pim/osearch/mainwindow.cpp | |||
@@ -170,32 +170,34 @@ void MainWindow::makeMenu() | |||
170 | connect( SearchAllAction, SIGNAL(activated()), this, SLOT(searchAll()) ); | 170 | connect( SearchAllAction, SIGNAL(activated()), this, SLOT(searchAll()) ); |
171 | SearchAllAction->addTo( searchMenu ); | 171 | SearchAllAction->addTo( searchMenu ); |
172 | searchMenu->insertItem( tr( "Options" ), searchOptions ); | 172 | searchMenu->insertItem( tr( "Options" ), searchOptions ); |
173 | 173 | ||
174 | //SEARCH OPTIONS | 174 | //SEARCH OPTIONS |
175 | //actionWholeWordsOnly = new QAction( tr("Whole words only"),QString::null, 0, this, 0, true ); | 175 | //actionWholeWordsOnly = new QAction( tr("Whole words only"),QString::null, 0, this, 0, true ); |
176 | //actionWholeWordsOnly->addTo( searchOptions ); | 176 | //actionWholeWordsOnly->addTo( searchOptions ); |
177 | actionCaseSensitiv = new QAction( tr("Case sensitive"),QString::null, 0, this, 0, true ); | 177 | actionCaseSensitiv = new QAction( tr("Case sensitive"),QString::null, 0, this, 0, true ); |
178 | actionCaseSensitiv->addTo( searchOptions ); | 178 | actionCaseSensitiv->addTo( searchOptions ); |
179 | actionWildcards = new QAction( tr("Use wildcards"),QString::null, 0, this, 0, true ); | 179 | actionWildcards = new QAction( tr("Use wildcards"),QString::null, 0, this, 0, true ); |
180 | actionWildcards->addTo( searchOptions ); | 180 | actionWildcards->addTo( searchOptions ); |
181 | 181 | ||
182 | //SEARCH BAR | 182 | //SEARCH BAR |
183 | LabelEnterText = new QLabel( searchBar, "Label" ); | 183 | LabelEnterText = new QLabel( searchBar, "Label" ); |
184 | LabelEnterText->setAutoMask( FALSE ); | 184 | LabelEnterText->setAutoMask( FALSE ); |
185 | LabelEnterText->setText( tr( "Search for: " ) ); | 185 | LabelEnterText->setText( tr( "Search for: " ) ); |
186 | LabelEnterText->setFrameStyle( QFrame::NoFrame ); | ||
187 | LabelEnterText->setBackgroundMode( PaletteButton ); | ||
186 | 188 | ||
187 | addToolBar( searchBar, "Search", QMainWindow::Top, TRUE ); | 189 | addToolBar( searchBar, "Search", QMainWindow::Top, TRUE ); |
188 | QLineEdit *searchEdit = new QLineEdit( searchBar, "seachEdit" ); | 190 | QLineEdit *searchEdit = new QLineEdit( searchBar, "seachEdit" ); |
189 | QWhatsThis::add( searchEdit, tr("Enter your search terms here") ); | 191 | QWhatsThis::add( searchEdit, tr("Enter your search terms here") ); |
190 | searchEdit->setFocus(); | 192 | searchEdit->setFocus(); |
191 | searchBar->setHorizontalStretchable( TRUE ); | 193 | searchBar->setHorizontalStretchable( TRUE ); |
192 | searchBar->setStretchableWidget( searchEdit ); | 194 | searchBar->setStretchableWidget( searchEdit ); |
193 | 195 | ||
194 | //Search button | 196 | //Search button |
195 | SearchAllAction->addTo( searchBar ); | 197 | SearchAllAction->addTo( searchBar ); |
196 | 198 | ||
197 | //image ripped of off opie-login/loginwindow.cpp | 199 | //image ripped of off opie-login/loginwindow.cpp |
198 | QPixmap image1( ( const char** ) image1_data ); | 200 | QPixmap image1( ( const char** ) image1_data ); |
199 | 201 | ||
200 | //Clear text | 202 | //Clear text |
201 | ClearSearchText = new QToolButton( searchBar, "ClearSearchText"); | 203 | ClearSearchText = new QToolButton( searchBar, "ClearSearchText"); |
diff --git a/core/pim/osearch/todosearch.cpp b/core/pim/osearch/todosearch.cpp index 48fa909..1ed7370 100644 --- a/core/pim/osearch/todosearch.cpp +++ b/core/pim/osearch/todosearch.cpp | |||
@@ -12,33 +12,33 @@ | |||
12 | // | 12 | // |
13 | #include "todosearch.h" | 13 | #include "todosearch.h" |
14 | #include "todoitem.h" | 14 | #include "todoitem.h" |
15 | 15 | ||
16 | #include <qpe/resource.h> | 16 | #include <qpe/resource.h> |
17 | #include <qpe/config.h> | 17 | #include <qpe/config.h> |
18 | 18 | ||
19 | #include <qaction.h> | 19 | #include <qaction.h> |
20 | #include <qpopupmenu.h> | 20 | #include <qpopupmenu.h> |
21 | 21 | ||
22 | using namespace Opie; | 22 | using namespace Opie; |
23 | TodoSearch::TodoSearch(QListView* parent, QString name) | 23 | TodoSearch::TodoSearch(QListView* parent, QString name) |
24 | : SearchGroup(parent, name), _todos(0), _popupMenu(0) | 24 | : SearchGroup(parent, name), _todos(0), _popupMenu(0) |
25 | { | 25 | { |
26 | //AppLnkSet als(QPEApplication::qpeDir()); | 26 | //AppLnkSet als(QPEApplication::qpeDir()); |
27 | //setPixmap( 0, als.findExec("todolist")->pixmap() ); | 27 | //setPixmap( 0, als.findExec("todolist")->pixmap() ); |
28 | QIconSet is = Resource::loadIconSet( "todo/TodoListSmall" ); | 28 | QIconSet is = Resource::loadIconSet( "todo/TodoList" ); |
29 | setPixmap( 0, is.pixmap( QIconSet::Large, true ) ); | 29 | setPixmap( 0, is.pixmap( QIconSet::Large, true ) ); |
30 | actionShowCompleted = new QAction( QObject::tr("Show completed tasks"),QString::null, 0, 0, 0, true ); | 30 | actionShowCompleted = new QAction( QObject::tr("Show completed tasks"),QString::null, 0, 0, 0, true ); |
31 | Config cfg( "osearch", Config::User ); | 31 | Config cfg( "osearch", Config::User ); |
32 | cfg.setGroup( "todo_settings" ); | 32 | cfg.setGroup( "todo_settings" ); |
33 | actionShowCompleted->setOn( cfg.readBoolEntry( "show_completed_tasks", false ) ); | 33 | actionShowCompleted->setOn( cfg.readBoolEntry( "show_completed_tasks", false ) ); |
34 | 34 | ||
35 | } | 35 | } |
36 | 36 | ||
37 | 37 | ||
38 | TodoSearch::~TodoSearch() | 38 | TodoSearch::~TodoSearch() |
39 | { | 39 | { |
40 | Config cfg( "osearch", Config::User ); | 40 | Config cfg( "osearch", Config::User ); |
41 | cfg.setGroup( "todo_settings" ); | 41 | cfg.setGroup( "todo_settings" ); |
42 | cfg.writeEntry( "show_completed_tasks", actionShowCompleted->isOn() ); | 42 | cfg.writeEntry( "show_completed_tasks", actionShowCompleted->isOn() ); |
43 | delete _popupMenu; | 43 | delete _popupMenu; |
44 | delete actionShowCompleted; | 44 | delete actionShowCompleted; |