summaryrefslogtreecommitdiff
path: root/noncore/apps
Unidiff
Diffstat (limited to 'noncore/apps') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/checkbook/mainwindow.cpp6
-rw-r--r--noncore/apps/confedit/mainwindow.h2
-rw-r--r--noncore/apps/opie-bartender/bartender.cpp4
-rw-r--r--noncore/apps/opie-bartender/bartender.h4
-rw-r--r--noncore/apps/opie-reader/QTReaderApp.cpp6
-rw-r--r--noncore/apps/opie-reader/QTReaderApp.h4
-rw-r--r--noncore/apps/opie-sheet/mainwindow.cpp6
-rw-r--r--noncore/apps/opie-sheet/mainwindow.h4
-rw-r--r--noncore/apps/tableviewer/tableviewer.cpp4
9 files changed, 20 insertions, 20 deletions
diff --git a/noncore/apps/checkbook/mainwindow.cpp b/noncore/apps/checkbook/mainwindow.cpp
index 25f9910..9fc2125 100644
--- a/noncore/apps/checkbook/mainwindow.cpp
+++ b/noncore/apps/checkbook/mainwindow.cpp
@@ -15,83 +15,83 @@
15    : ..    .:,     . . . without even the implied warranty of 15    : ..    .:,     . . . without even the implied warranty of
16    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A 16    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
17  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU General 17  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU General
18..}^=.=       =       ; Public License for more details. 18..}^=.=       =       ; Public License for more details.
19++=   -.     .`     .: 19++=   -.     .`     .:
20 :     =  ...= . :.=- You should have received a copy of the GNU 20 :     =  ...= . :.=- You should have received a copy of the GNU
21 -.   .:....=;==+<; General Public License along with this file; 21 -.   .:....=;==+<; General Public License along with this file;
22  -_. . .   )=.  = see the file COPYING. If not, write to the 22  -_. . .   )=.  = see the file COPYING. If not, write to the
23    --        :-=` Free Software Foundation, Inc., 23    --        :-=` Free Software Foundation, Inc.,
24 59 Temple Place - Suite 330, 24 59 Temple Place - Suite 330,
25 Boston, MA 02111-1307, USA. 25 Boston, MA 02111-1307, USA.
26 26
27*/ 27*/
28 28
29#include "mainwindow.h" 29#include "mainwindow.h"
30#include "cbinfo.h" 30#include "cbinfo.h"
31#include "configuration.h" 31#include "configuration.h"
32#include "password.h" 32#include "password.h"
33#include "checkbook.h" 33#include "checkbook.h"
34#include "listedit.h" 34#include "listedit.h"
35 35
36#include <qpe/config.h> 36#include <qpe/config.h>
37#include <qpe/global.h> 37#include <qpe/global.h>
38#include <qpe/qpeapplication.h> 38#include <qpe/qpeapplication.h>
39#include <qpe/qpemenubar.h> 39#include <qmenubar.h>
40#include <qpe/qpemessagebox.h> 40#include <qpe/qpemessagebox.h>
41#include <qpe/qpetoolbar.h> 41#include <qpe/qpetoolbar.h>
42#include <qpe/resource.h> 42#include <qpe/resource.h>
43 43
44#include <qaction.h> 44#include <qaction.h>
45#include <qcheckbox.h> 45#include <qcheckbox.h>
46#include <qdir.h> 46#include <qdir.h>
47#include <qlineedit.h> 47#include <qlineedit.h>
48#include <qwhatsthis.h> 48#include <qwhatsthis.h>
49 49
50 50
51MainWindow::MainWindow( QWidget* parent, const char* name, WFlags fl ) 51MainWindow::MainWindow( QWidget* parent, const char* name, WFlags fl )
52 : QMainWindow( parent, name, fl || WStyle_ContextHelp ) 52 : QMainWindow( parent, name, fl || WStyle_ContextHelp )
53{ 53{
54 setCaption( tr( "Checkbook" ) ); 54 setCaption( tr( "Checkbook" ) );
55 55
56 cbDir = Global::applicationFileName( "checkbook", "" ); 56 cbDir = Global::applicationFileName( "checkbook", "" );
57 lockIcon = Resource::loadPixmap( "locked" ); 57 lockIcon = Resource::loadPixmap( "locked" );
58 58
59 // Load configuration options 59 // Load configuration options
60 Config config( "checkbook" ); 60 Config config( "checkbook" );
61 _cfg.readConfig( config ); 61 _cfg.readConfig( config );
62 62
63 63
64 // Build menu and tool bars 64 // Build menu and tool bars
65 setToolBarsMovable( FALSE ); 65 setToolBarsMovable( FALSE );
66 66
67 QPEToolBar *bar = new QPEToolBar( this ); 67 QToolBar *bar = new QToolBar( this );
68 bar->setHorizontalStretchable( TRUE ); 68 bar->setHorizontalStretchable( TRUE );
69 QMenuBar *mb = new QMenuBar( bar ); 69 QMenuBar *mb = new QMenuBar( bar );
70 mb->setMargin( 0 ); 70 mb->setMargin( 0 );
71 QPopupMenu *popup = new QPopupMenu( this ); 71 QPopupMenu *popup = new QPopupMenu( this );
72 72
73 bar = new QPEToolBar( this ); 73 bar = new QToolBar( this );
74 QAction *a = new QAction( tr( "New" ), Resource::loadPixmap( "new" ), QString::null, 0, this, 0 ); 74 QAction *a = new QAction( tr( "New" ), Resource::loadPixmap( "new" ), QString::null, 0, this, 0 );
75 a->setWhatsThis( tr( "Click here to create a new checkbook.\n\nYou also can select New from the Checkbook menu." ) ); 75 a->setWhatsThis( tr( "Click here to create a new checkbook.\n\nYou also can select New from the Checkbook menu." ) );
76 connect( a, SIGNAL( activated() ), this, SLOT( slotNew() ) ); 76 connect( a, SIGNAL( activated() ), this, SLOT( slotNew() ) );
77 a->addTo( popup ); 77 a->addTo( popup );
78 a->addTo( bar ); 78 a->addTo( bar );
79 79
80 actionOpen = new QAction( tr( "Edit" ), Resource::loadPixmap( "edit" ), QString::null, 80 actionOpen = new QAction( tr( "Edit" ), Resource::loadPixmap( "edit" ), QString::null,
81 0, this, 0 ); 81 0, this, 0 );
82 actionOpen->setWhatsThis( tr( "Select a checkbook and then click here to edit it.\n\nYou also can select Edit from the Checkbook menu, or click and hold on a checkbook name." ) ); 82 actionOpen->setWhatsThis( tr( "Select a checkbook and then click here to edit it.\n\nYou also can select Edit from the Checkbook menu, or click and hold on a checkbook name." ) );
83 connect( actionOpen, SIGNAL( activated() ), this, SLOT( slotEdit() ) ); 83 connect( actionOpen, SIGNAL( activated() ), this, SLOT( slotEdit() ) );
84 actionOpen->addTo( popup ); 84 actionOpen->addTo( popup );
85 actionOpen->addTo( bar ); 85 actionOpen->addTo( bar );
86 86
87 actionDelete = new QAction( tr( "Delete" ), Resource::loadPixmap( "trash" ), QString::null, 87 actionDelete = new QAction( tr( "Delete" ), Resource::loadPixmap( "trash" ), QString::null,
88 0, this, 0 ); 88 0, this, 0 );
89 actionDelete->setWhatsThis( tr( "Select a checkbook and then click here delete it.\n\nYou also can select Delete from the Checkbook menu." ) ); 89 actionDelete->setWhatsThis( tr( "Select a checkbook and then click here delete it.\n\nYou also can select Delete from the Checkbook menu." ) );
90 connect( actionDelete, SIGNAL( activated() ), this, SLOT( slotDelete() ) ); 90 connect( actionDelete, SIGNAL( activated() ), this, SLOT( slotDelete() ) );
91 actionDelete->addTo( popup ); 91 actionDelete->addTo( popup );
92 actionDelete->addTo( bar ); 92 actionDelete->addTo( bar );
93 93
94 popup->insertSeparator(); 94 popup->insertSeparator();
95 95
96 a = new QAction( tr( "Configure" ), Resource::loadPixmap( "SettingsIcon" ), QString::null, 0, this, 0 ); 96 a = new QAction( tr( "Configure" ), Resource::loadPixmap( "SettingsIcon" ), QString::null, 0, this, 0 );
97 a->setWhatsThis( tr( "Click here to configure this app." ) ); 97 a->setWhatsThis( tr( "Click here to configure this app." ) );
diff --git a/noncore/apps/confedit/mainwindow.h b/noncore/apps/confedit/mainwindow.h
index 96331db..23aca52 100644
--- a/noncore/apps/confedit/mainwindow.h
+++ b/noncore/apps/confedit/mainwindow.h
@@ -1,46 +1,46 @@
1/*************************************************************************** 1/***************************************************************************
2 * * 2 * *
3 * This program is free software; you can redistribute it and/or modify * 3 * This program is free software; you can redistribute it and/or modify *
4 * it under the terms of the GNU General Public License as published by * 4 * it under the terms of the GNU General Public License as published by *
5 * the Free Software Foundation; either version 2 of the License, or * 5 * the Free Software Foundation; either version 2 of the License, or *
6 * (at your option) any later version. * 6 * (at your option) any later version. *
7 * * 7 * *
8 ***************************************************************************/ 8 ***************************************************************************/
9 9
10// (c) 2002 Patrick S. Vogt <tille@handhelds.org> 10// (c) 2002 Patrick S. Vogt <tille@handhelds.org>
11 11
12#ifndef MAINWINDOW_H 12#ifndef MAINWINDOW_H
13#define MAINWINDOW_H 13#define MAINWINDOW_H
14 14
15#include <qmainwindow.h> 15#include <qmainwindow.h>
16#include <qdialog.h> 16#include <qdialog.h>
17#include <qaction.h> 17#include <qaction.h>
18#include <qtimer.h> 18#include <qtimer.h>
19#include <qpopupmenu.h> 19#include <qpopupmenu.h>
20#include "editwidget.h" 20#include "editwidget.h"
21 21
22class QPEToolBar; 22class QToolBar;
23class ListViewItemConfFile; 23class ListViewItemConfFile;
24class ListViewConfDir; 24class ListViewConfDir;
25class ListViewItemConf; 25class ListViewItemConf;
26 26
27class MainWindow : public QMainWindow 27class MainWindow : public QMainWindow
28{ 28{
29 Q_OBJECT 29 Q_OBJECT
30 30
31 31
32public: 32public:
33 MainWindow( QWidget *parent = 0, const char *name = 0, WFlags f = 0 ); 33 MainWindow( QWidget *parent = 0, const char *name = 0, WFlags f = 0 );
34 ~MainWindow(); 34 ~MainWindow();
35 static QString appName() { return QString::fromLatin1("confedit"); } 35 static QString appName() { return QString::fromLatin1("confedit"); }
36 36
37public slots: 37public slots:
38 void setCurrent(QListViewItem*); 38 void setCurrent(QListViewItem*);
39 void groupChanged(const QString&); 39 void groupChanged(const QString&);
40 void keyChanged(const QString&); 40 void keyChanged(const QString&);
41 void valueChanged(const QString&); 41 void valueChanged(const QString&);
42 void showPopup(); 42 void showPopup();
43 void stopTimer( QListViewItem* ); 43 void stopTimer( QListViewItem* );
44 void saveConfFile(); 44 void saveConfFile();
45 void revertConfFile(); 45 void revertConfFile();
46 void removeConfFile(); 46 void removeConfFile();
diff --git a/noncore/apps/opie-bartender/bartender.cpp b/noncore/apps/opie-bartender/bartender.cpp
index 3a0d8d1..8c4ee93 100644
--- a/noncore/apps/opie-bartender/bartender.cpp
+++ b/noncore/apps/opie-bartender/bartender.cpp
@@ -1,90 +1,90 @@
1/**************************************************************************** 1/****************************************************************************
2** 2**
3** Created: Sat Jul 20 08:10:53 2002 3** Created: Sat Jul 20 08:10:53 2002
4** by: L.J. Potter <ljp@llornkcor.com> 4** by: L.J. Potter <ljp@llornkcor.com>
5** copyright : (C) 2002 by ljp 5** copyright : (C) 2002 by ljp
6 email : ljp@llornkcor.com 6 email : ljp@llornkcor.com
7 * This program is free software; you can redistribute it and/or modify * 7 * This program is free software; you can redistribute it and/or modify *
8 * it under the terms of the GNU General Public License as published by * 8 * it under the terms of the GNU General Public License as published by *
9 * the Free Software Foundation; either version 2 of the License, or * 9 * the Free Software Foundation; either version 2 of the License, or *
10 * (at your option) any later version. * 10 * (at your option) any later version. *
11 ***************************************************************************/ 11 ***************************************************************************/
12 12
13#include "bartender.h" 13#include "bartender.h"
14#include "newdrinks.h" 14#include "newdrinks.h"
15#include "showdrinks.h" 15#include "showdrinks.h"
16#include "inputDialog.h" 16#include "inputDialog.h"
17#include "searchresults.h" 17#include "searchresults.h"
18#include "bac.h" 18#include "bac.h"
19 19
20#include <qpe/qpetoolbar.h> 20#include <qpe/qpetoolbar.h>
21#include <qpe/qpemenubar.h> 21#include <qmenubar.h>
22#include <opie/colorpopupmenu.h> 22#include <opie/colorpopupmenu.h>
23#include <qpe/qpeapplication.h> 23#include <qpe/qpeapplication.h>
24#include <qpe/resource.h> 24#include <qpe/resource.h>
25 25
26#include <qcstring.h> 26#include <qcstring.h>
27#include <qlineedit.h> 27#include <qlineedit.h>
28#include <qdir.h> 28#include <qdir.h>
29#include <qpushbutton.h> 29#include <qpushbutton.h>
30#include <qlistbox.h> 30#include <qlistbox.h>
31#include <qstringlist.h> 31#include <qstringlist.h>
32#include <qmultilineedit.h> 32#include <qmultilineedit.h>
33#include <qmessagebox.h> 33#include <qmessagebox.h>
34#include <qfile.h> 34#include <qfile.h>
35#include <qtextstream.h> 35#include <qtextstream.h>
36#include <qfile.h> 36#include <qfile.h>
37#include <qaction.h> 37#include <qaction.h>
38#include <qheader.h> 38#include <qheader.h>
39#include <qlistview.h> 39#include <qlistview.h>
40#include <qwidget.h> 40#include <qwidget.h>
41#include <qlayout.h> 41#include <qlayout.h>
42#include <qvariant.h> 42#include <qvariant.h>
43#include <qtooltip.h> 43#include <qtooltip.h>
44#include <qwhatsthis.h> 44#include <qwhatsthis.h>
45#include <qimage.h> 45#include <qimage.h>
46#include <qpixmap.h> 46#include <qpixmap.h>
47 47
48#include <fcntl.h> 48#include <fcntl.h>
49#include <unistd.h> 49#include <unistd.h>
50#include <stdlib.h> 50#include <stdlib.h>
51#include <stdio.h> 51#include <stdio.h>
52#include <errno.h> 52#include <errno.h>
53 53
54 54
55Bartender::Bartender( QWidget* parent, const char* name, WFlags fl ) 55Bartender::Bartender( QWidget* parent, const char* name, WFlags fl )
56 : QMainWindow( parent, name, fl ) { 56 : QMainWindow( parent, name, fl ) {
57 if ( !name ) 57 if ( !name )
58 setName( "Bartender" ); 58 setName( "Bartender" );
59 QGridLayout *layout = new QGridLayout( this ); 59 QGridLayout *layout = new QGridLayout( this );
60 layout->setSpacing( 2); 60 layout->setSpacing( 2);
61 layout->setMargin( 2); 61 layout->setMargin( 2);
62 connect( qApp,SIGNAL( aboutToQuit()),SLOT( cleanUp()) ); 62 connect( qApp,SIGNAL( aboutToQuit()),SLOT( cleanUp()) );
63 63
64 setCaption( tr( "Bartender" ) ); 64 setCaption( tr( "Bartender" ) );
65 65
66 ToolBar1 = new QPEToolBar( this, "ToolBar1" ); 66 ToolBar1 = new QToolBar( this, "ToolBar1" );
67 ToolBar1->setFixedHeight(22); 67 ToolBar1->setFixedHeight(22);
68 layout->addMultiCellWidget( ToolBar1, 0, 0, 0, 4 ); 68 layout->addMultiCellWidget( ToolBar1, 0, 0, 0, 4 );
69 69
70 QMenuBar *menuBar = new QMenuBar( ToolBar1 ); 70 QMenuBar *menuBar = new QMenuBar( ToolBar1 );
71 QPopupMenu *fileMenu; 71 QPopupMenu *fileMenu;
72 fileMenu = new QPopupMenu( this); 72 fileMenu = new QPopupMenu( this);
73 menuBar->insertItem( tr("File"), fileMenu ); 73 menuBar->insertItem( tr("File"), fileMenu );
74 74
75 fileMenu->insertItem(tr("New Drink")); 75 fileMenu->insertItem(tr("New Drink"));
76 fileMenu->insertItem(tr("Open Drink")); 76 fileMenu->insertItem(tr("Open Drink"));
77 fileMenu->insertItem(tr("Find by Drink Name")); 77 fileMenu->insertItem(tr("Find by Drink Name"));
78 fileMenu->insertItem(tr("Find by Alcohol")); 78 fileMenu->insertItem(tr("Find by Alcohol"));
79 79
80 QPopupMenu *editMenu; 80 QPopupMenu *editMenu;
81 editMenu = new QPopupMenu( this); 81 editMenu = new QPopupMenu( this);
82 menuBar->insertItem( tr("Edit"), editMenu ); 82 menuBar->insertItem( tr("Edit"), editMenu );
83 editMenu->insertItem(tr("edit")); 83 editMenu->insertItem(tr("edit"));
84 84
85 connect( fileMenu, SIGNAL( activated(int) ), this, SLOT( fileMenuActivated(int) )); 85 connect( fileMenu, SIGNAL( activated(int) ), this, SLOT( fileMenuActivated(int) ));
86 connect( editMenu, SIGNAL( activated(int) ), this, SLOT( editMenuActivated(int) )); 86 connect( editMenu, SIGNAL( activated(int) ), this, SLOT( editMenuActivated(int) ));
87 87
88 88
89 QAction *a = new QAction( tr( "New" ), Resource::loadPixmap( "new" ), "New", 0, this, 0 ); 89 QAction *a = new QAction( tr( "New" ), Resource::loadPixmap( "new" ), "New", 0, this, 0 );
90 connect( a, SIGNAL( activated() ), this, SLOT( fileNew() ) ); 90 connect( a, SIGNAL( activated() ), this, SLOT( fileNew() ) );
diff --git a/noncore/apps/opie-bartender/bartender.h b/noncore/apps/opie-bartender/bartender.h
index 69cfa82..df1af76 100644
--- a/noncore/apps/opie-bartender/bartender.h
+++ b/noncore/apps/opie-bartender/bartender.h
@@ -1,59 +1,59 @@
1/**************************************************************************** 1/****************************************************************************
2** Created: Sat Jul 20 08:10:31 2002 2** Created: Sat Jul 20 08:10:31 2002
3** by: L.J. Potter <ljp@llornkcor.com> 3** by: L.J. Potter <ljp@llornkcor.com>
4** copyright : (C) 2002 by ljp 4** copyright : (C) 2002 by ljp
5 email : ljp@llornkcor.com 5 email : ljp@llornkcor.com
6 * This program is free software; you can redistribute it and/or modify * 6 * This program is free software; you can redistribute it and/or modify *
7 * it under the terms of the GNU General Public License as published by * 7 * it under the terms of the GNU General Public License as published by *
8 * the Free Software Foundation; either version 2 of the License, or * 8 * the Free Software Foundation; either version 2 of the License, or *
9 * (at your option) any later version. * 9 * (at your option) any later version. *
10 ***************************************************************************/ 10 ***************************************************************************/
11#ifndef BARTENDER_H 11#ifndef BARTENDER_H
12#define BARTENDER_H 12#define BARTENDER_H
13#include "newdrinks.h" 13#include "newdrinks.h"
14 14
15#include <qvariant.h> 15#include <qvariant.h>
16#include <qwidget.h> 16#include <qwidget.h>
17#include <qmainwindow.h> 17#include <qmainwindow.h>
18#include <qfile.h> 18#include <qfile.h>
19 19
20class QVBoxLayout; 20class QVBoxLayout;
21class QHBoxLayout; 21class QHBoxLayout;
22class QGridLayout; 22class QGridLayout;
23class QListView; 23class QListView;
24class QListViewItem; 24class QListViewItem;
25class QPEToolBar; 25class QToolBar;
26 26
27class Bartender : public QMainWindow 27class Bartender : public QMainWindow
28{ 28{
29 Q_OBJECT 29 Q_OBJECT
30 30
31public: 31public:
32 Bartender( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 ); 32 Bartender( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
33 ~Bartender(); 33 ~Bartender();
34 34
35 QPEToolBar* ToolBar1; 35 QToolBar* ToolBar1;
36 QListView* DrinkView; 36 QListView* DrinkView;
37 QFile dbFile; 37 QFile dbFile;
38public slots: 38public slots:
39 void doEdit(); 39 void doEdit();
40 40
41protected: 41protected:
42 42
43protected slots: 43protected slots:
44 void fileMenuActivated(int); 44 void fileMenuActivated(int);
45 void editMenuActivated(int); 45 void editMenuActivated(int);
46 void cleanUp(); 46 void cleanUp();
47 void fileNew(); 47 void fileNew();
48 void showDrink( QListViewItem *); 48 void showDrink( QListViewItem *);
49 void showDrink(int, QListViewItem *, const QPoint&, int); 49 void showDrink(int, QListViewItem *, const QPoint&, int);
50 void initDrinkDb(); 50 void initDrinkDb();
51 void doSearchByName(); 51 void doSearchByName();
52 void doSearchByDrink(); 52 void doSearchByDrink();
53 void showSearchResult(QStringList &); 53 void showSearchResult(QStringList &);
54 void doBac(); 54 void doBac();
55 void openCurrentDrink(); 55 void openCurrentDrink();
56 void askSearch(); 56 void askSearch();
57private: 57private:
58 void clearList(); 58 void clearList();
59 void fillList(); 59 void fillList();
diff --git a/noncore/apps/opie-reader/QTReaderApp.cpp b/noncore/apps/opie-reader/QTReaderApp.cpp
index 8c0d138..f10020a 100644
--- a/noncore/apps/opie-reader/QTReaderApp.cpp
+++ b/noncore/apps/opie-reader/QTReaderApp.cpp
@@ -1,49 +1,49 @@
1/********************************************************************** 1/**********************************************************************
2** Copyright (C) 2000 Trolltech AS. Allrights reserved. 2** Copyright (C) 2000 Trolltech AS. Allrights reserved.
3** 3**
4** This file is part of Qt Palmtop Environment. 4** This file is part of Qt Palmtop Environment.
5** 5**
6** This file may be distributed and/or modified under the terms of the 6** This file may be distributed and/or modified under the terms of the
7** GNU General Public License version 2 as published by the Free Software 7** GNU General Public License version 2 as published by the Free Software
8** Foundation and appearing in the file LICENSE.GPL included in the 8** Foundation and appearing in the file LICENSE.GPL included in the
9** packaging of this file. 9** packaging of this file.
10** 10**
11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
13** 13**
14** See http://www.trolltech.com/gpl/ for GPL licensing information. 14** See http://www.trolltech.com/gpl/ for GPL licensing information.
15** 15**
16** Contact info@trolltech.com if any conditions of this licensing are 16** Contact info@trolltech.com if any conditions of this licensing are
17** not clear to you. 17** not clear to you.
18** 18**
19**********************************************************************/ 19**********************************************************************/
20#include "useqpe.h" 20#include "useqpe.h"
21#include <qregexp.h> 21#include <qregexp.h>
22#include <qclipboard.h> 22#include <qclipboard.h>
23#include <qwidgetstack.h> 23#include <qwidgetstack.h>
24#ifdef USEQPE 24#ifdef USEQPE
25#include <qpe/qpemenubar.h> 25#include <qmenubar.h>
26#include <qpe/qpetoolbar.h> 26#include <qpe/qpetoolbar.h>
27#endif 27#endif
28#include <qmenubar.h> 28#include <qmenubar.h>
29#include <qtoolbar.h> 29#include <qtoolbar.h>
30#ifdef USEQPE 30#ifdef USEQPE
31#include <qpe/menubutton.h> 31#include <qpe/menubutton.h>
32#include <qpe/fontdatabase.h> 32#include <qpe/fontdatabase.h>
33#endif 33#endif
34#include <qcombobox.h> 34#include <qcombobox.h>
35#include <qpopupmenu.h> 35#include <qpopupmenu.h>
36#include <qaction.h> 36#include <qaction.h>
37#include <qapplication.h> 37#include <qapplication.h>
38#include <qlineedit.h> 38#include <qlineedit.h>
39#include <qtoolbutton.h> 39#include <qtoolbutton.h>
40#include <qspinbox.h> 40#include <qspinbox.h>
41#include <qobjectlist.h> 41#include <qobjectlist.h>
42#ifdef USEQPE 42#ifdef USEQPE
43#include <qpe/global.h> 43#include <qpe/global.h>
44#include <qpe/applnk.h> 44#include <qpe/applnk.h>
45#endif 45#endif
46#include <qfileinfo.h> 46#include <qfileinfo.h>
47#include <stdlib.h> //getenv 47#include <stdlib.h> //getenv
48#include <qprogressbar.h> 48#include <qprogressbar.h>
49#ifdef USEQPE 49#ifdef USEQPE
@@ -233,50 +233,50 @@ QTReaderApp::QTReaderApp( QWidget *parent, const char *name, WFlags f )
233 int m_rot = 0; 233 int m_rot = 0;
234 if (rot.contains("Rot90")) 234 if (rot.contains("Rot90"))
235 { 235 {
236 m_rot = 90; 236 m_rot = 90;
237 } 237 }
238 else if (rot.contains("Rot180")) 238 else if (rot.contains("Rot180"))
239 { 239 {
240 m_rot = 180; 240 m_rot = 180;
241 } 241 }
242 else if (rot.contains("Rot270")) 242 else if (rot.contains("Rot270"))
243 { 243 {
244 m_rot = 270; 244 m_rot = 270;
245 } 245 }
246 246
247// qDebug("Initial Rotation(%d):%s", m_rot, (const char*)rot); 247// qDebug("Initial Rotation(%d):%s", m_rot, (const char*)rot);
248*/ 248*/
249 m_autogenstr = "^ *[A-Z].*[a-z] *$"; 249 m_autogenstr = "^ *[A-Z].*[a-z] *$";
250 250
251#ifdef USEQPE 251#ifdef USEQPE
252 setIcon( Resource::loadPixmap( PICDIR "uqtreader") ); 252 setIcon( Resource::loadPixmap( PICDIR "uqtreader") );
253#else 253#else
254 setIcon( QPixmap (PICDIR "uqtreader.png") ); 254 setIcon( QPixmap (PICDIR "uqtreader.png") );
255#endif /* USEQPE */ 255#endif /* USEQPE */
256 256
257// QPEToolBar *bar = new QPEToolBar( this ); 257// QToolBar *bar = new QToolBar( this );
258// menubar = new QPEToolBar( this ); 258// menubar = new QToolBar( this );
259#ifdef USEQPE 259#ifdef USEQPE
260 Config config( APPDIR ); 260 Config config( APPDIR );
261#else 261#else
262 QDir d = QDir::home(); // "/" 262 QDir d = QDir::home(); // "/"
263 if ( !d.cd(APPDIR) ) { // "/tmp" 263 if ( !d.cd(APPDIR) ) { // "/tmp"
264 qWarning( "Cannot find the \"~/" APPDIR "\" directory" ); 264 qWarning( "Cannot find the \"~/" APPDIR "\" directory" );
265 d = QDir::home(); 265 d = QDir::home();
266 d.mkdir(APPDIR); 266 d.mkdir(APPDIR);
267 d.cd(APPDIR); 267 d.cd(APPDIR);
268 } 268 }
269 QFileInfo fi(d, INIFILE); 269 QFileInfo fi(d, INIFILE);
270// qDebug("Path:%s", (const char*)fi.absFilePath()); 270// qDebug("Path:%s", (const char*)fi.absFilePath());
271 Config config(fi.absFilePath()); 271 Config config(fi.absFilePath());
272#endif 272#endif
273 config.setGroup("Toolbar"); 273 config.setGroup("Toolbar");
274 m_tbmovesave = m_tbmove = config.readBoolEntry("Movable", false); 274 m_tbmovesave = m_tbmove = config.readBoolEntry("Movable", false);
275 m_tbpolsave = m_tbpol = (ToolbarPolicy)config.readNumEntry("Policy", 1); 275 m_tbpolsave = m_tbpol = (ToolbarPolicy)config.readNumEntry("Policy", 1);
276 m_tbposition = (ToolBarDock)config.readNumEntry("Position", 2); 276 m_tbposition = (ToolBarDock)config.readNumEntry("Position", 2);
277 menubar = new QToolBar("Menus", this, m_tbposition); 277 menubar = new QToolBar("Menus", this, m_tbposition);
278 278
279// fileBar = new QToolBar("File", this); 279// fileBar = new QToolBar("File", this);
280// QToolBar* viewBar = new QToolBar("File", this); 280// QToolBar* viewBar = new QToolBar("File", this);
281// QToolBar* navBar = new QToolBar("File", this); 281// QToolBar* navBar = new QToolBar("File", this);
282// QToolBar* markBar = new QToolBar("File", this); 282// QToolBar* markBar = new QToolBar("File", this);
diff --git a/noncore/apps/opie-reader/QTReaderApp.h b/noncore/apps/opie-reader/QTReaderApp.h
index 86c14b1..ab6f60e 100644
--- a/noncore/apps/opie-reader/QTReaderApp.h
+++ b/noncore/apps/opie-reader/QTReaderApp.h
@@ -23,49 +23,49 @@
23//#define _SCROLLPIPE 23//#define _SCROLLPIPE
24//#define __ISEARCH 24//#define __ISEARCH
25 25
26//#define MAX_ENCODING 6 26//#define MAX_ENCODING 6
27#define MAX_ACTIONS 5 27#define MAX_ACTIONS 5
28 28
29#include "useqpe.h" 29#include "useqpe.h"
30#include <sys/timeb.h> 30#include <sys/timeb.h>
31#include <qmainwindow.h> 31#include <qmainwindow.h>
32#include "CExpander.h" 32#include "CExpander.h"
33#include "CEncoding.h" 33#include "CEncoding.h"
34#include <qlist.h> 34#include <qlist.h>
35//#include <qpe/filemanager.h> 35//#include <qpe/filemanager.h>
36#include <qmap.h> 36#include <qmap.h>
37#include <qlineedit.h> 37#include <qlineedit.h>
38#include <qstack.h> 38#include <qstack.h>
39#include <qlistbox.h> 39#include <qlistbox.h>
40//#include "Queue.h" 40//#include "Queue.h"
41 41
42class QWidgetStack; 42class QWidgetStack;
43class QToolButton; 43class QToolButton;
44class QPopupMenu; 44class QPopupMenu;
45class QToolBar; 45class QToolBar;
46#ifdef USEQPE 46#ifdef USEQPE
47class QPEToolBar; 47class QToolBar;
48class QMenuBar; 48class QMenuBar;
49#endif 49#endif
50class CBkmkSelector; 50class CBkmkSelector;
51class QProgressBar; 51class QProgressBar;
52class QAction; 52class QAction;
53class CAnnoEdit; 53class CAnnoEdit;
54class QFloatBar; 54class QFloatBar;
55class CDrawBuffer; 55class CDrawBuffer;
56class QTReader; 56class QTReader;
57class QImage; 57class QImage;
58class Config; 58class Config;
59 59
60enum ActionTypes 60enum ActionTypes
61{ 61{
62 cesNone = 0, 62 cesNone = 0,
63 cesOpenFile, 63 cesOpenFile,
64 cesAutoScroll, 64 cesAutoScroll,
65 cesActionMark, 65 cesActionMark,
66 cesActionAnno, 66 cesActionAnno,
67 cesFullScreen, 67 cesFullScreen,
68 cesZoomIn, 68 cesZoomIn,
69 cesZoomOut, 69 cesZoomOut,
70 cesBack, 70 cesBack,
71 cesForward, 71 cesForward,
@@ -359,49 +359,49 @@ private slots:
359 bool findNextBookmark(size_t start); 359 bool findNextBookmark(size_t start);
360 360
361 private: 361 private:
362 362
363 QAction* m_scrollButton; 363 QAction* m_scrollButton;
364 364
365 QAction* m_buttonAction[MAX_ACTIONS]; 365 QAction* m_buttonAction[MAX_ACTIONS];
366 366
367 CBkmkSelector* bkmkselector; 367 CBkmkSelector* bkmkselector;
368 368
369 ActionTypes m_spaceTarget, m_escapeTarget, m_returnTarget, m_leftTarget, m_rightTarget, 369 ActionTypes m_spaceTarget, m_escapeTarget, m_returnTarget, m_leftTarget, m_rightTarget,
370 m_upTarget, m_downTarget; 370 m_upTarget, m_downTarget;
371 bool m_leftScroll, m_rightScroll, m_upScroll, m_downScroll; 371 bool m_leftScroll, m_rightScroll, m_upScroll, m_downScroll;
372 bool m_bcloseDisabled, m_disableesckey; 372 bool m_bcloseDisabled, m_disableesckey;
373 size_t searchStart; 373 size_t searchStart;
374#ifdef __ISEARCH 374#ifdef __ISEARCH
375 QStack<searchrecord>* searchStack; 375 QStack<searchrecord>* searchStack;
376 bool dosearch(size_t start, CDrawBuffer& test, const QString& arg); 376 bool dosearch(size_t start, CDrawBuffer& test, const QString& arg);
377#else 377#else
378 bool dosearch(size_t start, CDrawBuffer& test, const QRegExp& arg); 378 bool dosearch(size_t start, CDrawBuffer& test, const QRegExp& arg);
379#endif 379#endif
380 QWidgetStack *editorStack; 380 QWidgetStack *editorStack;
381 QTReader* reader; 381 QTReader* reader;
382 QComboBox* m_fontSelector; 382 QComboBox* m_fontSelector;
383// QPEToolBar /* *menu,*/ *fileBar; 383// QToolBar /* *menu,*/ *fileBar;
384 QToolBar *menubar, *fileBar, *navBar, *viewBar, *markBar; 384 QToolBar *menubar, *fileBar, *navBar, *viewBar, *markBar;
385#ifdef USEQPE 385#ifdef USEQPE
386 QMenuBar *mb; 386 QMenuBar *mb;
387#else 387#else
388 QMenuBar *mb; 388 QMenuBar *mb;
389#endif 389#endif
390 QFloatBar *searchBar, *regBar/*, *m_fontBar*/; 390 QFloatBar *searchBar, *regBar/*, *m_fontBar*/;
391 QToolBar /* *searchBar, *regBar,*/ *m_fontBar; 391 QToolBar /* *searchBar, *regBar,*/ *m_fontBar;
392 QLineEdit *searchEdit, *regEdit; 392 QLineEdit *searchEdit, *regEdit;
393 bool searchVisible; 393 bool searchVisible;
394 bool regVisible; 394 bool regVisible;
395 bool m_fontVisible, m_twoTouch; 395 bool m_fontVisible, m_twoTouch;
396 bool bFromDocView; 396 bool bFromDocView;
397 static unsigned long m_uid; 397 static unsigned long m_uid;
398 long unsigned get_unique_id() { return m_uid++; } 398 long unsigned get_unique_id() { return m_uid++; }
399 /* 399 /*
400 void resizeEvent( QResizeEvent * r) 400 void resizeEvent( QResizeEvent * r)
401 { 401 {
402// qDebug("resize:(%u,%u)", r->oldSize().width(), r->oldSize().height()); 402// qDebug("resize:(%u,%u)", r->oldSize().width(), r->oldSize().height());
403// qDebug("resize:(%u,%u)", r->size().width(), r->size().height()); 403// qDebug("resize:(%u,%u)", r->size().width(), r->size().height());
404 // bgroup->move( width()-bgroup->width(), 0 ); 404 // bgroup->move( width()-bgroup->width(), 0 );
405 } 405 }
406 */ 406 */
407 CList<Bkmk>* pBkmklist; 407 CList<Bkmk>* pBkmklist;
diff --git a/noncore/apps/opie-sheet/mainwindow.cpp b/noncore/apps/opie-sheet/mainwindow.cpp
index fb2ca79..78b3073 100644
--- a/noncore/apps/opie-sheet/mainwindow.cpp
+++ b/noncore/apps/opie-sheet/mainwindow.cpp
@@ -442,86 +442,86 @@ void MainWindow::initMenu()
442 addFlyAction(tr("Arc Tangent"), tr("Arc Tan&gent"), "ATAN(", submenuFuncMath); 442 addFlyAction(tr("Arc Tangent"), tr("Arc Tan&gent"), "ATAN(", submenuFuncMath);
443 addFlyAction(tr("Arc Tangent of Coordinates"), tr("C&oor. Arc Tangent"), "ATAN2(", submenuFuncMath); 443 addFlyAction(tr("Arc Tangent of Coordinates"), tr("C&oor. Arc Tangent"), "ATAN2(", submenuFuncMath);
444 submenuFuncMath->insertSeparator(); 444 submenuFuncMath->insertSeparator();
445 addFlyAction(tr("Exponential"), tr("&Exponential"), "EXP(", submenuFuncMath); 445 addFlyAction(tr("Exponential"), tr("&Exponential"), "EXP(", submenuFuncMath);
446 addFlyAction(tr("Logarithm"), tr("&Logarithm"), "LOG(", submenuFuncMath); 446 addFlyAction(tr("Logarithm"), tr("&Logarithm"), "LOG(", submenuFuncMath);
447 addFlyAction(tr("Power"), tr("&Power"), "POW(", submenuFuncMath); 447 addFlyAction(tr("Power"), tr("&Power"), "POW(", submenuFuncMath);
448 submenuFunc->insertItem(tr("&Mathematical"), submenuFuncMath); 448 submenuFunc->insertItem(tr("&Mathematical"), submenuFuncMath);
449 449
450 submenuFuncStat=new QPopupMenu; 450 submenuFuncStat=new QPopupMenu;
451 addFlyAction(tr("Average"), tr("&Average"), "AVG(", submenuFuncStat); 451 addFlyAction(tr("Average"), tr("&Average"), "AVG(", submenuFuncStat);
452 addFlyAction(tr("Maximum"), tr("Ma&ximum"), "MAX(", submenuFuncStat); 452 addFlyAction(tr("Maximum"), tr("Ma&ximum"), "MAX(", submenuFuncStat);
453 addFlyAction(tr("Minimum"), tr("&Minimum"), "MIN(", submenuFuncStat); 453 addFlyAction(tr("Minimum"), tr("&Minimum"), "MIN(", submenuFuncStat);
454 addFlyAction(tr("Count"), tr("&Count"), "COUNT(", submenuFuncStat); 454 addFlyAction(tr("Count"), tr("&Count"), "COUNT(", submenuFuncStat);
455 submenuFunc->insertItem(tr("&Statistical"), submenuFuncStat); 455 submenuFunc->insertItem(tr("&Statistical"), submenuFuncStat);
456 456
457 menuInsert->insertSeparator(); 457 menuInsert->insertSeparator();
458 insertCells->addTo(menuInsert); 458 insertCells->addTo(menuInsert);
459 insertRows->addTo(menuInsert); 459 insertRows->addTo(menuInsert);
460 insertCols->addTo(menuInsert); 460 insertCols->addTo(menuInsert);
461 insertSheets->addTo(menuInsert); 461 insertSheets->addTo(menuInsert);
462} 462}
463 463
464void MainWindow::initStandardToolbar() 464void MainWindow::initStandardToolbar()
465{ 465{
466 toolbarStandard=new QPEToolBar(this); 466 toolbarStandard=new QToolBar(this);
467 toolbarStandard->setHorizontalStretchable(TRUE); 467 toolbarStandard->setHorizontalStretchable(TRUE);
468 moveToolBar(toolbarStandard, Top); 468 moveToolBar(toolbarStandard, Top);
469 469
470 fileNew->addTo(toolbarStandard); 470 fileNew->addTo(toolbarStandard);
471 fileOpen->addTo(toolbarStandard); 471 fileOpen->addTo(toolbarStandard);
472 fileSave->addTo(toolbarStandard); 472 fileSave->addTo(toolbarStandard);
473 473
474 comboSheets=new QComboBox(toolbarStandard); 474 comboSheets=new QComboBox(toolbarStandard);
475 toolbarStandard->setStretchableWidget(comboSheets); 475 toolbarStandard->setStretchableWidget(comboSheets);
476 connect(comboSheets, SIGNAL(activated(const QString &)), this, SLOT(slotSheetChanged(const QString &))); 476 connect(comboSheets, SIGNAL(activated(const QString &)), this, SLOT(slotSheetChanged(const QString &)));
477} 477}
478 478
479void MainWindow::initFunctionsToolbar() 479void MainWindow::initFunctionsToolbar()
480{ 480{
481 toolbarFunctions=new QPEToolBar(this); 481 toolbarFunctions=new QToolBar(this);
482 toolbarFunctions->setHorizontalStretchable(TRUE); 482 toolbarFunctions->setHorizontalStretchable(TRUE);
483 moveToolBar(toolbarFunctions, Bottom); 483 moveToolBar(toolbarFunctions, Bottom);
484 484
485 funcEqual->addTo(toolbarFunctions); 485 funcEqual->addTo(toolbarFunctions);
486 funcPlus->addTo(toolbarFunctions); 486 funcPlus->addTo(toolbarFunctions);
487 funcMinus->addTo(toolbarFunctions); 487 funcMinus->addTo(toolbarFunctions);
488 funcCross->addTo(toolbarFunctions); 488 funcCross->addTo(toolbarFunctions);
489 funcDivide->addTo(toolbarFunctions); 489 funcDivide->addTo(toolbarFunctions);
490 funcParanOpen->addTo(toolbarFunctions); 490 funcParanOpen->addTo(toolbarFunctions);
491 funcParanClose->addTo(toolbarFunctions); 491 funcParanClose->addTo(toolbarFunctions);
492 funcComma->addTo(toolbarFunctions); 492 funcComma->addTo(toolbarFunctions);
493 493
494 toolFunction=new QToolButton(toolbarFunctions); 494 toolFunction=new QToolButton(toolbarFunctions);
495 toolFunction->setPixmap(func_func_xpm); 495 toolFunction->setPixmap(func_func_xpm);
496 toolFunction->setTextLabel(tr("Functions")); 496 toolFunction->setTextLabel(tr("Functions"));
497 toolFunction->setPopup(submenuFunc); 497 toolFunction->setPopup(submenuFunc);
498 toolFunction->setPopupDelay(0); 498 toolFunction->setPopupDelay(0);
499} 499}
500 500
501void MainWindow::initEditToolbar() 501void MainWindow::initEditToolbar()
502{ 502{
503 toolbarEdit=new QPEToolBar(this); 503 toolbarEdit=new QToolBar(this);
504 toolbarEdit->setHorizontalStretchable(TRUE); 504 toolbarEdit->setHorizontalStretchable(TRUE);
505 moveToolBar(toolbarEdit, Bottom); 505 moveToolBar(toolbarEdit, Bottom);
506 506
507 editAccept->addTo(toolbarEdit); 507 editAccept->addTo(toolbarEdit);
508 editCancel->addTo(toolbarEdit); 508 editCancel->addTo(toolbarEdit);
509 509
510 editData=new QLineEdit(toolbarEdit); 510 editData=new QLineEdit(toolbarEdit);
511 toolbarEdit->setStretchableWidget(editData); 511 toolbarEdit->setStretchableWidget(editData);
512 connect(editData, SIGNAL(returnPressed()), this, SLOT(slotEditAccept())); 512 connect(editData, SIGNAL(returnPressed()), this, SLOT(slotEditAccept()));
513 513
514 editCellSelect->addTo(toolbarEdit); 514 editCellSelect->addTo(toolbarEdit);
515} 515}
516 516
517void MainWindow::slotHelpAbout() 517void MainWindow::slotHelpAbout()
518{ 518{
519 QDialog dialogAbout(this, 0, TRUE); 519 QDialog dialogAbout(this, 0, TRUE);
520 dialogAbout.resize(width()-40, height()-80); 520 dialogAbout.resize(width()-40, height()-80);
521 dialogAbout.setCaption(tr("About Opie Sheet")); 521 dialogAbout.setCaption(tr("About Opie Sheet"));
522 522
523 QLabel label(tr("Opie Sheet\nSpreadsheet Software for Opie\nQWDC Beta Winner (as Sheet/Qt)\n\nDeveloped by: Serdar Ozler\nRelease 1.0.2\nRelease Date: October 08, 2002\n\nThis product is licensed under GPL. It is freely distributable. If you want to get the latest version and also the source code, please visit the web site.\n\nhttp://qtopia.sitebest.com"), &dialogAbout); 523 QLabel label(tr("Opie Sheet\nSpreadsheet Software for Opie\nQWDC Beta Winner (as Sheet/Qt)\n\nDeveloped by: Serdar Ozler\nRelease 1.0.2\nRelease Date: October 08, 2002\n\nThis product is licensed under GPL. It is freely distributable. If you want to get the latest version and also the source code, please visit the web site.\n\nhttp://qtopia.sitebest.com"), &dialogAbout);
524 label.setGeometry(dialogAbout.rect()); 524 label.setGeometry(dialogAbout.rect());
525 label.setAlignment(Qt::AlignCenter | Qt::WordBreak); 525 label.setAlignment(Qt::AlignCenter | Qt::WordBreak);
526 526
527 dialogAbout.exec(); 527 dialogAbout.exec();
diff --git a/noncore/apps/opie-sheet/mainwindow.h b/noncore/apps/opie-sheet/mainwindow.h
index 4007f88..bd99c36 100644
--- a/noncore/apps/opie-sheet/mainwindow.h
+++ b/noncore/apps/opie-sheet/mainwindow.h
@@ -1,68 +1,68 @@
1/*************************************************************************** 1/***************************************************************************
2 * * 2 * *
3 * This program is free software; you can redistribute it and/or modify * 3 * This program is free software; you can redistribute it and/or modify *
4 * it under the terms of the GNU General Public License as published by * 4 * it under the terms of the GNU General Public License as published by *
5 * the Free Software Foundation; either version 2 of the License, or * 5 * the Free Software Foundation; either version 2 of the License, or *
6 * (at your option) any later version. * 6 * (at your option) any later version. *
7 * * 7 * *
8 ***************************************************************************/ 8 ***************************************************************************/
9 9
10/* 10/*
11 * Opie Sheet (formerly Sheet/Qt) 11 * Opie Sheet (formerly Sheet/Qt)
12 * by Serdar Ozler <sozler@sitebest.com> 12 * by Serdar Ozler <sozler@sitebest.com>
13 */ 13 */
14 14
15#ifndef MAINWINDOW_H 15#ifndef MAINWINDOW_H
16#define MAINWINDOW_H 16#define MAINWINDOW_H
17 17
18#include <qpe/applnk.h> 18#include <qpe/applnk.h>
19#include <qpe/fileselector.h> 19#include <qpe/fileselector.h>
20#include <qmenubar.h> 20#include <qmenubar.h>
21#include <qpe/qpetoolbar.h> 21#include <qtoolbar.h>
22#include <qmainwindow.h> 22#include <qmainwindow.h>
23#include <qaction.h> 23#include <qaction.h>
24#include <qlineedit.h> 24#include <qlineedit.h>
25#include <qbutton.h> 25#include <qbutton.h>
26#include <qcombobox.h> 26#include <qcombobox.h>
27#include <qtoolbutton.h> 27#include <qtoolbutton.h>
28 28
29#include "sheet.h" 29#include "sheet.h"
30 30
31typedef struct typeSheet 31typedef struct typeSheet
32{ 32{
33 QString name; 33 QString name;
34 QList<typeCellData> data; 34 QList<typeCellData> data;
35}; 35};
36 36
37class MainWindow: public QMainWindow 37class MainWindow: public QMainWindow
38{ 38{
39 Q_OBJECT 39 Q_OBJECT
40 40
41 // QPE objects 41 // QPE objects
42 DocLnk* currentDoc; 42 DocLnk* currentDoc;
43 QMenuBar *menu; 43 QMenuBar *menu;
44 QPEToolBar *toolbarFunctions, *toolbarEdit, *toolbarStandard; 44 QToolBar *toolbarFunctions, *toolbarEdit, *toolbarStandard;
45 FileSelector *fileSelector; 45 FileSelector *fileSelector;
46 46
47 // QT objects 47 // QT objects
48 QPopupMenu *menuFile, *menuEdit, *menuInsert, *menuFormat, *menuData, *menuHelp, 48 QPopupMenu *menuFile, *menuEdit, *menuInsert, *menuFormat, *menuData, *menuHelp,
49 *submenuFunc, *submenuFuncStd, *submenuFuncMath, *submenuFuncStat, 49 *submenuFunc, *submenuFuncStd, *submenuFuncMath, *submenuFuncStat,
50 *submenuRow, *submenuCol, *submenuSheet; 50 *submenuRow, *submenuCol, *submenuSheet;
51 QAction *fileNew, *fileOpen, *fileSave, *fileSaveAs, *fileQuit, *helpAbout, *editAccept, *editCancel, *formatCells, 51 QAction *fileNew, *fileOpen, *fileSave, *fileSaveAs, *fileQuit, *helpAbout, *editAccept, *editCancel, *formatCells,
52 *funcPlus, *funcMinus, *funcCross, *funcDivide, *funcParanOpen, *funcParanClose, *funcComma, *funcEqual, 52 *funcPlus, *funcMinus, *funcCross, *funcDivide, *funcParanOpen, *funcParanClose, *funcComma, *funcEqual,
53 *editCut, *editCopy, *editPaste, *editPasteContents, *editClear, *insertCols, *insertRows, *insertSheets, *insertCells, 53 *editCut, *editCopy, *editPaste, *editPasteContents, *editClear, *insertCols, *insertRows, *insertSheets, *insertCells,
54 *rowHeight, *rowShow, *rowHide, *rowAdjust, *colWidth, *colShow, *colHide, *colAdjust, *sheetRename, *sheetRemove, 54 *rowHeight, *rowShow, *rowHide, *rowAdjust, *colWidth, *colShow, *colHide, *colAdjust, *sheetRename, *sheetRemove,
55 *dataSort, *dataFindReplace, *editCellSelect, *helpGeneral; 55 *dataSort, *dataFindReplace, *editCellSelect, *helpGeneral;
56 QLineEdit *editData; 56 QLineEdit *editData;
57 QButton *buttonUp, *buttonDown, *buttonLeft, *buttonRight; 57 QButton *buttonUp, *buttonDown, *buttonLeft, *buttonRight;
58 QComboBox *comboSheets; 58 QComboBox *comboSheets;
59 QToolButton *toolFunction; 59 QToolButton *toolFunction;
60 QList<typeSheet> listSheets; 60 QList<typeSheet> listSheets;
61 QString helpFile; 61 QString helpFile;
62 62
63 // Other objects 63 // Other objects
64 Sheet *sheet; 64 Sheet *sheet;
65 65
66 // Variables 66 // Variables
67 bool documentModified; 67 bool documentModified;
68 68
diff --git a/noncore/apps/tableviewer/tableviewer.cpp b/noncore/apps/tableviewer/tableviewer.cpp
index fdf0072..207172d 100644
--- a/noncore/apps/tableviewer/tableviewer.cpp
+++ b/noncore/apps/tableviewer/tableviewer.cpp
@@ -12,49 +12,49 @@
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
13** 13**
14** See http://www.trolltech.com/gpl/ for GPL licensing information. 14** See http://www.trolltech.com/gpl/ for GPL licensing information.
15** 15**
16** Contact info@trolltech.com if any conditions of this licensing are 16** Contact info@trolltech.com if any conditions of this licensing are
17** not clear to you. 17** not clear to you.
18** 18**
19**********************************************************************/ 19**********************************************************************/
20 20
21/* local includes */ 21/* local includes */
22#include "tableviewer.h" 22#include "tableviewer.h"
23#include "ui/tvbrowseview.h" 23#include "ui/tvbrowseview.h"
24#include "ui/tvfilterview.h" 24#include "ui/tvfilterview.h"
25#include "ui/tvlistview.h" 25#include "ui/tvlistview.h"
26#include "ui/tveditview.h" 26#include "ui/tveditview.h"
27#include "ui/tvkeyedit.h" 27#include "ui/tvkeyedit.h"
28#include "db/datacache.h" 28#include "db/datacache.h"
29 29
30/* QPE includes */ 30/* QPE includes */
31#include <qpe/fileselector.h> 31#include <qpe/fileselector.h>
32#include <qpe/resource.h> 32#include <qpe/resource.h>
33#include <qpe/qpetoolbar.h> 33#include <qpe/qpetoolbar.h>
34 34
35/* QTE includes */ 35/* QTE includes */
36#include <qpe/qpemenubar.h> 36#include <qmenubar.h>
37#include <qpe/qpetoolbar.h> 37#include <qpe/qpetoolbar.h>
38#include <qpopupmenu.h> 38#include <qpopupmenu.h>
39#include <qapplication.h> 39#include <qapplication.h>
40#include <qwidgetstack.h> 40#include <qwidgetstack.h>
41#include <qlayout.h> 41#include <qlayout.h>
42#include <qbuffer.h> 42#include <qbuffer.h>
43/*! 43/*!
44 \class TableViewerWindow 44 \class TableViewerWindow
45 \brief The main window widget of the application 45 \brief The main window widget of the application
46 46
47 This is the main widget of the table viewer application. 47 This is the main widget of the table viewer application.
48 It is the co-ordination point. 48 It is the co-ordination point.
49*/ 49*/
50 50
51/*! 51/*!
52 Constructs a new TableViewerWindow 52 Constructs a new TableViewerWindow
53*/ 53*/
54TableViewerWindow::TableViewerWindow(QWidget *parent, const char *name, WFlags f) 54TableViewerWindow::TableViewerWindow(QWidget *parent, const char *name, WFlags f)
55 : QMainWindow(parent, name, f) 55 : QMainWindow(parent, name, f)
56{ 56{
57 setCaption(tr("Table Viewer")); 57 setCaption(tr("Table Viewer"));
58 58
59/* Build data */ 59/* Build data */
60 ds = new DBStore(); 60 ds = new DBStore();
@@ -71,49 +71,49 @@ TableViewerWindow::TableViewerWindow(QWidget *parent, const char *name, WFlags f
71 QPopupMenu *file_menu = new QPopupMenu; 71 QPopupMenu *file_menu = new QPopupMenu;
72 file_menu->insertItem("New", this, SLOT(newDocument())); 72 file_menu->insertItem("New", this, SLOT(newDocument()));
73 73
74 file_menu->insertItem("Open", this, SLOT(selectDocument())); 74 file_menu->insertItem("Open", this, SLOT(selectDocument()));
75 file_menu->insertSeparator(); 75 file_menu->insertSeparator();
76 file_menu->insertItem("Properties"); 76 file_menu->insertItem("Properties");
77 77
78 /* later will want to set this up to clean up first via this, SLOT(quit) */ 78 /* later will want to set this up to clean up first via this, SLOT(quit) */
79 menu->insertItem("Document", file_menu); 79 menu->insertItem("Document", file_menu);
80 80
81 QPopupMenu *edit_menu = new QPopupMenu; 81 QPopupMenu *edit_menu = new QPopupMenu;
82 edit_menu->insertItem("Edit Item", this, SLOT(editItemSlot())); 82 edit_menu->insertItem("Edit Item", this, SLOT(editItemSlot()));
83 edit_menu->insertItem("Edit Keys", this, SLOT(editKeysSlot())); 83 edit_menu->insertItem("Edit Keys", this, SLOT(editKeysSlot()));
84 edit_menu->insertItem("Edit filters", this, SLOT(filterViewSlot())); 84 edit_menu->insertItem("Edit filters", this, SLOT(filterViewSlot()));
85 menu->insertItem("Edit", edit_menu); 85 menu->insertItem("Edit", edit_menu);
86 86
87 QPopupMenu *view_menu = new QPopupMenu; 87 QPopupMenu *view_menu = new QPopupMenu;
88 view_menu->insertItem("Browse View", this, SLOT(browseViewSlot())); 88 view_menu->insertItem("Browse View", this, SLOT(browseViewSlot()));
89 view_menu->insertItem("List View", this, SLOT(listViewSlot())); 89 view_menu->insertItem("List View", this, SLOT(listViewSlot()));
90 menu->insertItem("View", view_menu); 90 menu->insertItem("View", view_menu);
91 91
92 QVBoxLayout *main_layout = new QVBoxLayout; 92 QVBoxLayout *main_layout = new QVBoxLayout;
93 93
94 /* Build tool bar */ 94 /* Build tool bar */
95 navigation = new QPEToolBar(this, "navigation"); 95 navigation = new QToolBar(this, "navigation");
96 QToolButton *newItemButton = new QToolButton( 96 QToolButton *newItemButton = new QToolButton(
97 QIconSet(Resource::loadPixmap("new")), "New Item", QString::null, 97 QIconSet(Resource::loadPixmap("new")), "New Item", QString::null,
98 this, SLOT(newItemSlot()), navigation, "New Item"); 98 this, SLOT(newItemSlot()), navigation, "New Item");
99 QToolButton *editItemButton = new QToolButton( 99 QToolButton *editItemButton = new QToolButton(
100 QIconSet(Resource::loadPixmap("edit")), "Edit Item", QString::null, 100 QIconSet(Resource::loadPixmap("edit")), "Edit Item", QString::null,
101 this, SLOT(editItemSlot()), navigation, "Edit Item"); 101 this, SLOT(editItemSlot()), navigation, "Edit Item");
102 QToolButton *deleteItemButton = new QToolButton( 102 QToolButton *deleteItemButton = new QToolButton(
103 QIconSet(Resource::loadPixmap("trash")), "Delete Item", 103 QIconSet(Resource::loadPixmap("trash")), "Delete Item",
104 QString::null, this, 104 QString::null, this,
105 SLOT(deleteItemSlot()), navigation, "Delete Item"); 105 SLOT(deleteItemSlot()), navigation, "Delete Item");
106 106
107 navigation->addSeparator(); 107 navigation->addSeparator();
108 108
109 QToolButton *firstItemButton = new QToolButton( 109 QToolButton *firstItemButton = new QToolButton(
110 QIconSet(Resource::loadPixmap("fastback")), "First Item", 110 QIconSet(Resource::loadPixmap("fastback")), "First Item",
111 QString::null, this, 111 QString::null, this,
112 SLOT(firstItem()), navigation, "First Item"); 112 SLOT(firstItem()), navigation, "First Item");
113 QToolButton *previousItemButton = new QToolButton( 113 QToolButton *previousItemButton = new QToolButton(
114 QIconSet(Resource::loadPixmap("back")), "Previous Item", 114 QIconSet(Resource::loadPixmap("back")), "Previous Item",
115 QString::null, this, 115 QString::null, this,
116 SLOT(previousItem()), navigation, "Previous Item"); 116 SLOT(previousItem()), navigation, "Previous Item");
117 QToolButton *nextItemButton = new QToolButton( 117 QToolButton *nextItemButton = new QToolButton(
118 QIconSet(Resource::loadPixmap("forward")), "Next Item", 118 QIconSet(Resource::loadPixmap("forward")), "Next Item",
119 QString::null, this, 119 QString::null, this,