summaryrefslogtreecommitdiff
path: root/noncore/apps
authordrw <drw>2004-02-23 18:12:57 (UTC)
committer drw <drw>2004-02-23 18:12:57 (UTC)
commit398c7d54acfc203ec90644d6c63e5b200391e906 (patch) (side-by-side diff)
tree84a1f495a5a2450f7eb2f401037b6fd81162d72b /noncore/apps
parentf5762a3bee0ca4a176048f6552acaea2af827914 (diff)
downloadopie-398c7d54acfc203ec90644d6c63e5b200391e906.zip
opie-398c7d54acfc203ec90644d6c63e5b200391e906.tar.gz
opie-398c7d54acfc203ec90644d6c63e5b200391e906.tar.bz2
TinyKate: libopie->libopie2
Diffstat (limited to 'noncore/apps') (more/less context) (show whitespace changes)
-rw-r--r--noncore/apps/tinykate/config.in2
-rw-r--r--noncore/apps/tinykate/libkate/config.in2
-rw-r--r--noncore/apps/tinykate/libkate/document/katesyntaxdocument.h2
-rw-r--r--noncore/apps/tinykate/libkate/libkate.pro2
-rw-r--r--noncore/apps/tinykate/libkate/microkde/kcolorbtn.cpp5
-rw-r--r--noncore/apps/tinykate/libkate/view/kateviewdialog.cpp2
-rw-r--r--noncore/apps/tinykate/main.cpp6
-rw-r--r--noncore/apps/tinykate/opie-tinykate.control2
-rw-r--r--noncore/apps/tinykate/tinykate.cpp6
-rw-r--r--noncore/apps/tinykate/tinykate.h2
-rw-r--r--noncore/apps/tinykate/tinykate.pro2
11 files changed, 16 insertions, 17 deletions
diff --git a/noncore/apps/tinykate/config.in b/noncore/apps/tinykate/config.in
index 39aedcf..2efc13e 100644
--- a/noncore/apps/tinykate/config.in
+++ b/noncore/apps/tinykate/config.in
@@ -1,6 +1,6 @@
config TINYKATE
boolean "opie-tinykate (programmers editor Kate from KDE)"
default "y"
- depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE && LIBKATE
+ depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE2CORE && LIBOPIE2UI && LIBKATE
source "noncore/apps/tinykate/libkate/config.in"
diff --git a/noncore/apps/tinykate/libkate/config.in b/noncore/apps/tinykate/libkate/config.in
index 47d7ef5..2e7e62c 100644
--- a/noncore/apps/tinykate/libkate/config.in
+++ b/noncore/apps/tinykate/libkate/config.in
@@ -1,4 +1,4 @@
config LIBKATE
boolean "libkate"
default "y"
- depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE
+ depends ( LIBQPE || LIBQPE-X11 ) && LIBQTAUX && LIBOPIE2CORE && LIBOPIE2UI
diff --git a/noncore/apps/tinykate/libkate/document/katesyntaxdocument.h b/noncore/apps/tinykate/libkate/document/katesyntaxdocument.h
index 5c5c5a4..5eefc77 100644
--- a/noncore/apps/tinykate/libkate/document/katesyntaxdocument.h
+++ b/noncore/apps/tinykate/libkate/document/katesyntaxdocument.h
@@ -1,45 +1,45 @@
/***************************************************************************
katesyntaxdocument.h - description
-------------------
begin : Sat 31 March 2001
copyright : (C) 2001,2002 by Joseph Wenninger
email : jowenn@kde.org
***************************************************************************/
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
#ifndef SYNTAXDOCUMENT_H
#define SYNTAXDOCUMENT_H
-#include <opie/xmltree.h>
+#include <opie2/xmltree.h>
#include <qlist.h>
#include <qstringlist.h>
class syntaxModeListItem
{
public:
QString name;
QString section;
QString mimetype;
QString extension;
QString identifier;
};
class syntaxContextData
{
public:
Opie::XMLElement *parent;
Opie::XMLElement *currentGroup;
Opie::XMLElement *item;
};
typedef QList<syntaxModeListItem> SyntaxModeList;
diff --git a/noncore/apps/tinykate/libkate/libkate.pro b/noncore/apps/tinykate/libkate/libkate.pro
index 7266b18..f1b8063 100644
--- a/noncore/apps/tinykate/libkate/libkate.pro
+++ b/noncore/apps/tinykate/libkate/libkate.pro
@@ -60,31 +60,31 @@ SOURCES = microkde/kapplication.cpp \
\
\
qt3back/qregexp3.cpp \
ktexteditor/ktexteditor.cpp \
document/katebuffer.cpp document/katedialogs.cpp \
document/katehighlight.cpp \
document/katecmd.cpp \
document/katesyntaxdocument.cpp document/katecmds.cpp \
document/katedocument.cpp document/katetextline.cpp \
view/kateundohistory.cpp \
view/kateview.cpp \
view/kateviewdialog.cpp \
interfaces/interfaces.cpp
INTERFACES =
INCLUDEPATH += $(OPIEDIR)/include \
$(OPIEDIR)/noncore/apps/tinykate/libkate \
$(OPIEDIR)/noncore/apps/tinykate/libkate/microkde \
$(OPIEDIR)/noncore/apps/tinykate/libkate/document \
$(OPIEDIR)/noncore/apps/tinykate/libkate/view \
$(OPIEDIR)/noncore/apps/tinykate/libkate/interfaces \
$(OPIEDIR)/noncore/apps/tinykate/libkate/ktexteditor \
$(OPIEDIR)/noncore/apps/tinykate/libkate/qt3back
DEPENDPATH += $(OPIEDIR)/include
-LIBS += -lqpe -lopie
+LIBS += -lqpe -lqtaux2 -lopiecore2 -lopieui2
TARGET = tinykate
INCLUDEPATH += $(OPIEDIR)/include
DESTDIR = $(OPIEDIR)/lib$(PROJMAK)
include ( $(OPIEDIR)/include.pro )
diff --git a/noncore/apps/tinykate/libkate/microkde/kcolorbtn.cpp b/noncore/apps/tinykate/libkate/microkde/kcolorbtn.cpp
index 7be5af5..1320cbc 100644
--- a/noncore/apps/tinykate/libkate/microkde/kcolorbtn.cpp
+++ b/noncore/apps/tinykate/libkate/microkde/kcolorbtn.cpp
@@ -2,84 +2,83 @@
Copyright (C) 1997 Martin Jones (mjones@kde.org)
Copyright (C) 1999 Cristian Tibirna (ctibirna@kde.org)
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
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 <qdialog.h>
#include <qpainter.h>
#include <qdrawutil.h>
#include <qapplication.h>
#include <kglobalsettings.h>
-//#include "kcolordialog.h"
#include "kcolorbtn.h"
-#include <opie/colordialog.h>
+#include <opie2/qcolordialog.h>
KColorButton::KColorButton( QWidget *parent, const char *name )
: QPushButton( parent, name ), dragFlag(false)
{
// 2000-10-15 (putzer): fixes broken keyboard usage
connect (this, SIGNAL(clicked()), this, SLOT(chooseColor()));
}
KColorButton::KColorButton( const QColor &c, QWidget *parent,
const char *name )
: QPushButton( parent, name ), col(c), dragFlag(false)
{
// 2000-10-15 (putzer): fixes broken keyboard usage
connect (this, SIGNAL(clicked()), this, SLOT(chooseColor()));
}
void KColorButton::setColor( const QColor &c )
{
col = c;
repaint( false );
}
void KColorButton::drawButtonLabel( QPainter *painter )
{
QRect r = QApplication::style().buttonRect( 0, 0, width(), height() );
int l = r.x();
int t = r.y();
int w = r.width();
int h = r.height();
int b = 5;
QColor lnCol = colorGroup().text();
QColor fillCol = isEnabled() ? col : backgroundColor();
if ( isDown() ) {
qDrawPlainRect( painter, l+b+1, t+b+1, w-b*2, h-b*2, lnCol, 1, 0 );
b++;
painter->fillRect( l+b+1, t+b+1, w-b*2, h-b*2, fillCol );
} else {
qDrawPlainRect( painter, l+b, t+b, w-b*2, h-b*2, lnCol, 1, 0 );
b++;
painter->fillRect( l+b, t+b, w-b*2, h-b*2, fillCol );
}
}
void KColorButton::chooseColor()
{
- QColor newCol=OColorDialog::getColor( col);
+ QColor newCol=QColorDialog::getColor( col);
if( newCol != QDialog::Rejected )
{
col=newCol;
repaint( false );
emit changed( col );
}
}
diff --git a/noncore/apps/tinykate/libkate/view/kateviewdialog.cpp b/noncore/apps/tinykate/libkate/view/kateviewdialog.cpp
index 6a19e01..4cb13e8 100644
--- a/noncore/apps/tinykate/libkate/view/kateviewdialog.cpp
+++ b/noncore/apps/tinykate/libkate/view/kateviewdialog.cpp
@@ -25,49 +25,49 @@
#include <qlabel.h>
#include <qlayout.h>
#include <qlistbox.h>
#include <qspinbox.h>
#include <qcombobox.h>
#include <qgroupbox.h>
#include <qlineedit.h>
#include <qcheckbox.h>
#include <qcollection.h>
#include <qpushbutton.h>
#include <qobjectlist.h>
#include <qradiobutton.h>
#include <qwhatsthis.h>
#include <qstringlist.h>
#include <klocale.h>
#include <kcolorbtn.h>
#include <qcombobox.h>
#include <kglobal.h>
#include <qvbox.h>
#include <qspinbox.h>
#include <kfontdialog.h>
#include "../document/katedocument.h"
#include "kateviewdialog.h"
-#include <opie/ofontselector.h>
+#include <opie2/ofontselector.h>
SearchDialog::SearchDialog( QWidget *parent, QStringList &searchFor, QStringList &replaceWith, int flags )
: KDialogBase( parent, 0L, true, i18n( "Find Text" ), Ok | Cancel, Ok )
, m_replace( 0L )
{
QWidget *page = new QWidget( this );
setMainWidget( page );
QVBoxLayout *topLayout = new QVBoxLayout( page, 0, spacingHint() );
m_search = new QComboBox( true, page );
m_search->insertStringList( searchFor );
m_search->setMinimumWidth( m_search->sizeHint().width() );
m_search->lineEdit()->selectAll();
QLabel *label = new QLabel( m_search, i18n( "&Text To Find:" ), page );
m_optRegExp = new QCheckBox( i18n( "Regular Expression" ), page );
topLayout->addWidget( label );
topLayout->addWidget( m_search );
topLayout->addWidget( m_optRegExp );
if( flags & KateView::sfReplace )
{
// make it a replace dialog
diff --git a/noncore/apps/tinykate/main.cpp b/noncore/apps/tinykate/main.cpp
index e21c040..e62930c 100644
--- a/noncore/apps/tinykate/main.cpp
+++ b/noncore/apps/tinykate/main.cpp
@@ -1,22 +1,22 @@
/***************************************************************************
main.cpp
-------------------
begin : November 2002
copyright : (C) 2002 by Joseph Wenninger <jowenn@kde.org>
***************************************************************************/
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation. *
* ONLY VERSION 2 OF THE LICENSE IS APPLICABLE *
* *
***************************************************************************/
-#include <qmainwindow.h>
-#include "tinykate.h"
-#include <opie/oapplicationfactory.h>
+#include <opie2/oapplicationfactory.h>
+
+#include "tinykate.h"
OPIE_EXPORT_APP( OApplicationFactory<TinyKate> )
diff --git a/noncore/apps/tinykate/opie-tinykate.control b/noncore/apps/tinykate/opie-tinykate.control
index 66e17ad..fd806cc 100644
--- a/noncore/apps/tinykate/opie-tinykate.control
+++ b/noncore/apps/tinykate/opie-tinykate.control
@@ -1,9 +1,9 @@
Package: opie-tinykate
Files: plugins/application/libkate.so* bin/kate apps/Applications/tinykate.desktop pics/tinykate lib/libtinykate.so.1.0.0 lib/libtinykate.so.1.0 lib/libtinykate.so.1
Priority: optional
Section: opie/applications
Maintainer: Opie Team <opie@handhelds.org>
Architecture: arm
-Depends: task-opie-minimal
+Depends: task-opie-minimal, libopiecore2, libopieui2
Description: Kate for Opie
Version: $QPE_VERSION$EXTRAVERSION
diff --git a/noncore/apps/tinykate/tinykate.cpp b/noncore/apps/tinykate/tinykate.cpp
index f470645..bbf80ce 100644
--- a/noncore/apps/tinykate/tinykate.cpp
+++ b/noncore/apps/tinykate/tinykate.cpp
@@ -2,49 +2,49 @@
tinykate.cpp
Tiny KATE mainwindow
-------------------
begin : November 2002
copyright : (C) 2002 by Joseph Wenninger <jowenn@kde.org>
***************************************************************************/
/***************************************************************************
* *
* This program is free softwaSre; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation. *
* ONLY VERSION 2 OF THE LICENSE IS APPLICABLE *
* *
***************************************************************************/
#include <qwidget.h>
#include <qaction.h>
#include <qlayout.h>
#include <qtoolbutton.h>
#include <qmenubar.h>
#include <qpe/resource.h>
#include <qpe/global.h>
#include <qpe/qpeapplication.h>
-#include <opie/ofiledialog.h>
+#include <opie2/ofiledialog.h>
#include "tinykate.h"
#include <katedocument.h>
#include <katehighlight.h>
#include <kateview.h>
#include <kglobal.h>
TinyKate::TinyKate( QWidget *parent, const char *name, WFlags f) :
QMainWindow( parent, name, f )
{
shutDown=false;
nextUnnamed=0;
currentView=0;
viewCount=0;
setCaption(tr("TinyKATE"));
KGlobal::setAppName("TinyKATE");
QMenuBar *mb = new QMenuBar( this );
mb->setMargin( 0 );
tabwidget=new OTabWidget(this);
setCentralWidget(tabwidget);
connect(tabwidget,SIGNAL(currentChanged( QWidget *)),this,SLOT(slotCurrentChanged(QWidget *)));
@@ -150,49 +150,49 @@ TinyKate::TinyKate( QWidget *parent, const char *name, WFlags f) :
utilSettings->addTo( popup);
if( qApp->argc() > 1) open(qApp->argv()[1]);
else slotNew();
}
TinyKate::~TinyKate( )
{
qWarning("TinyKate destructor\n");
shutDown=true;
while (currentView!=0) {
slotClose();
}
if( KGlobal::config() != 0 ) {
qWarning("deleting KateConfig object..\n");
delete KGlobal::config();
}
}
void TinyKate::slotOpen( )
{
- QString filename = OFileDialog::getOpenFileName( OFileSelector::EXTENDED_ALL,
+ QString filename = Opie::OFileDialog::getOpenFileName( OFileSelector::EXTENDED_ALL,
QString::null);
if (!filename.isEmpty()) {
open(filename);
}
}
void TinyKate::open(const QString & filename)
{
KateDocument *kd= new KateDocument(false, false, this,0,this);
KTextEditor::View *kv;
QFileInfo fi(filename);
QString filenamed = fi.fileName();
tabwidget->addTab(kv=kd->createView(tabwidget,"bLAH"),"tinykate/tinykate", filenamed );
qDebug(filename);
kd->setDocName( filenamed);
kd->open( filename );
viewCount++;
}
void TinyKate::setDocument(const QString& fileref)
{
open( fileref );
}
@@ -245,39 +245,39 @@ void TinyKate::slotClose( )
delete dv->document();
viewCount--;
if ((!viewCount) && (!shutDown)) slotNew();
}
void TinyKate::slotSave() {
// feel free to make this how you want
if (currentView==0) return;
// KateView *kv = (KateView*) currentView;
KateDocument *kd = (KateDocument*) currentView->document();
// qDebug("saving file "+kd->docName());
if( kd->docName().isEmpty())
slotSaveAs();
else
kd->saveFile();
// kv->save();
// kd->saveFile();
}
void TinyKate::slotSaveAs() {
if (currentView==0) return;
KateDocument *kd = (KateDocument*) currentView->document();
- QString filename=OFileDialog::getSaveFileName(OFileSelector::EXTENDED_ALL,
+ QString filename= Opie::OFileDialog::getSaveFileName(OFileSelector::EXTENDED_ALL,
QString::null);
if (!filename.isEmpty()) {
qDebug("saving file "+filename);
QFileInfo fi(filename);
QString filenamed = fi.fileName();
kd->setDocFile( filename);
kd->setDocName( filenamed);
kd->saveFile();
// KTextEditor::View *dv = currentView;
// tabwidget->changeTab( dv, filenamed);
// need to change tab label here
}
}
diff --git a/noncore/apps/tinykate/tinykate.h b/noncore/apps/tinykate/tinykate.h
index a5ee9b9..f844c55 100644
--- a/noncore/apps/tinykate/tinykate.h
+++ b/noncore/apps/tinykate/tinykate.h
@@ -1,47 +1,47 @@
/***************************************************************************
tinykate.h
Tiny KATE mainwindow
-------------------
begin : November 2002
copyright : (C) 2002 by Joseph Wenninger <jowenn@kde.org>
***************************************************************************/
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation. *
* ONLY VERSION 2 OF THE LICENSE IS APPLICABLE *
* *
***************************************************************************/
#ifndef __TINYKATE_H__
#define __TINYKATE_H__
#include <qmainwindow.h>
-#include <opie/otabwidget.h>
+#include <opie2/otabwidget.h>
#include <ktexteditor.h>
class QToolButton;
class QAction;
class QPopupMenu;
class TinyKate : public QMainWindow
{
Q_OBJECT
public:
TinyKate( QWidget *parent=0, const char *name=0, WFlags f = 0);
~TinyKate( );
static QString appName() { return QString::fromLatin1( "kate" ); };
public slots:
void slotNew();
void setDocument(const QString& fileref);
protected slots:
void slotOpen();
void slotClose();
void slotCurrentChanged(QWidget *);
void slotSave();
diff --git a/noncore/apps/tinykate/tinykate.pro b/noncore/apps/tinykate/tinykate.pro
index 91d4230..ce22f8e 100644
--- a/noncore/apps/tinykate/tinykate.pro
+++ b/noncore/apps/tinykate/tinykate.pro
@@ -1,22 +1,22 @@
TEMPLATE = app
CONFIG = qt warn_on release quick-app
DESTDIR = $(OPIEDIR)/bin
HEADERS = tinykate.h
SOURCES = tinykate.cpp main.cpp
INTERFACES =
INCLUDEPATH += $(OPIEDIR)/include \
$(OPIEDIR)/noncore/apps/tinykate/libkate \
$(OPIEDIR)/noncore/apps/tinykate/libkate/microkde \
$(OPIEDIR)/noncore/apps/tinykate/libkate/document \
$(OPIEDIR)/noncore/apps/tinykate/libkate/view \
$(OPIEDIR)/noncore/apps/tinykate/libkate/interfaces \
$(OPIEDIR)/noncore/apps/tinykate/libkate/ktexteditor \
$(OPIEDIR)/noncore/apps/tinykate/libkate/qt3back
DEPENDPATH += $(OPIEDIR)/include
-LIBS += -lqpe -ltinykate -lopie
+LIBS += -lqpe -ltinykate -lopiecore2 -lopieui2
TARGET = kate
include ( $(OPIEDIR)/include.pro )