summaryrefslogtreecommitdiffstats
path: root/kate/snippets
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-18 17:00:31 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-18 17:00:31 +0000
commit395a904bff7b4d6ead445c342f7ac0c5fbf29121 (patch)
tree9829cadb79d2cc7c29a940627fadb28b11e54150 /kate/snippets
parent399f47c376fdf4d19192732a701ea9578d11619d (diff)
downloadtdeaddons-395a904bff7b4d6ead445c342f7ac0c5fbf29121.tar.gz
tdeaddons-395a904bff7b4d6ead445c342f7ac0c5fbf29121.zip
TQt4 port kdeaddons
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeaddons@1237404 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kate/snippets')
-rw-r--r--kate/snippets/CWidgetSnippetsBase.ui36
-rw-r--r--kate/snippets/CWidgetSnippetsBase.ui.h2
-rw-r--r--kate/snippets/csnippet.cpp4
-rw-r--r--kate/snippets/csnippet.h3
-rw-r--r--kate/snippets/cwidgetsnippets.cpp4
-rw-r--r--kate/snippets/cwidgetsnippets.h2
-rw-r--r--kate/snippets/plugin_katesnippets.cpp20
-rw-r--r--kate/snippets/plugin_katesnippets.h4
8 files changed, 39 insertions, 36 deletions
diff --git a/kate/snippets/CWidgetSnippetsBase.ui b/kate/snippets/CWidgetSnippetsBase.ui
index 7f370f9..b694158 100644
--- a/kate/snippets/CWidgetSnippetsBase.ui
+++ b/kate/snippets/CWidgetSnippetsBase.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.1" stdsetdef="1">
<class>CWidgetSnippetsBase</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>CWidgetSnippetsBase</cstring>
</property>
@@ -29,14 +29,14 @@
<property name="margin">
<number>0</number>
</property>
- <widget class="QSplitter">
+ <widget class="TQSplitter">
<property name="name">
<cstring>splitter13</cstring>
</property>
<property name="orientation">
<enum>Vertical</enum>
</property>
- <widget class="QListView">
+ <widget class="TQListView">
<column>
<property name="text">
<string>Snippet</string>
@@ -91,9 +91,9 @@
<string>A list of Snippets, what else</string>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout24</cstring>
+ <cstring>tqlayout24</cstring>
</property>
<vbox>
<property name="name">
@@ -102,9 +102,9 @@
<property name="margin">
<number>0</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout11</cstring>
+ <cstring>tqlayout11</cstring>
</property>
<hbox>
<property name="name">
@@ -113,7 +113,7 @@
<property name="margin">
<number>0</number>
</property>
- <widget class="QToolButton">
+ <widget class="TQToolButton">
<property name="name">
<cstring>btnNew</cstring>
</property>
@@ -124,7 +124,7 @@
<iconset>image1</iconset>
</property>
</widget>
- <widget class="QToolButton">
+ <widget class="TQToolButton">
<property name="name">
<cstring>btnSave</cstring>
</property>
@@ -135,7 +135,7 @@
<iconset>image2</iconset>
</property>
</widget>
- <widget class="QToolButton">
+ <widget class="TQToolButton">
<property name="name">
<cstring>btnDelete</cstring>
</property>
@@ -156,7 +156,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>200</width>
<height>20</height>
@@ -165,7 +165,7 @@
</spacer>
</hbox>
</widget>
- <widget class="QTextEdit">
+ <widget class="TQTextEdit">
<property name="name">
<cstring>teSnippetText</cstring>
</property>
@@ -201,14 +201,14 @@
<includes>
<include location="local" impldecl="in implementation">CWidgetSnippetsBase.ui.h</include>
</includes>
-<signals>
+<Q_SIGNALS>
<signal>lalala()</signal>
-</signals>
-<slots>
+</Q_SIGNALS>
+<Q_SLOTS>
<slot>init()</slot>
-</slots>
+</Q_SLOTS>
<functions>
- <function returnType="QListViewItem *">insertItem( const QString&amp; name, bool bRename )</function>
+ <function returnType="TQListViewItem *">insertItem( const TQString&amp; name, bool bRename )</function>
</functions>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kate/snippets/CWidgetSnippetsBase.ui.h b/kate/snippets/CWidgetSnippetsBase.ui.h
index 539442a..4fdd814 100644
--- a/kate/snippets/CWidgetSnippetsBase.ui.h
+++ b/kate/snippets/CWidgetSnippetsBase.ui.h
@@ -2,7 +2,7 @@
** ui.h extension file, included from the uic-generated form implementation.
**
** If you wish to add, delete or rename functions or slots use
-** Qt Designer which will update this file, preserving your code. Create an
+** TQt Designer which will update this file, preserving your code. Create an
** init() function in place of a constructor, and a destroy() function in
** place of a destructor.
*****************************************************************************/
diff --git a/kate/snippets/csnippet.cpp b/kate/snippets/csnippet.cpp
index 2aebb5d..c873949 100644
--- a/kate/snippets/csnippet.cpp
+++ b/kate/snippets/csnippet.cpp
@@ -9,8 +9,8 @@
***************************************************************************/
#include "csnippet.h"
-CSnippet::CSnippet(TQString sKey, TQString sValue, TQListViewItem *lvi, TQObject *parent, const char *name)
- : TQObject(parent, name), _sKey(sKey), _sValue(sValue), _lvi(lvi) {}
+CSnippet::CSnippet(TQString sKey, TQString sValue, TQListViewItem *lvi, TQObject *tqparent, const char *name)
+ : TQObject(tqparent, name), _sKey(sKey), _sValue(sValue), _lvi(lvi) {}
CSnippet::~CSnippet() {}
diff --git a/kate/snippets/csnippet.h b/kate/snippets/csnippet.h
index 3c75db4..ae9bef6 100644
--- a/kate/snippets/csnippet.h
+++ b/kate/snippets/csnippet.h
@@ -21,8 +21,9 @@
class CSnippet : public TQObject {
Q_OBJECT
+ TQ_OBJECT
public:
- CSnippet(TQString sKey, TQString sValue, TQListViewItem *lvi, TQObject *parent = 0, const char *name = 0);
+ CSnippet(TQString sKey, TQString sValue, TQListViewItem *lvi, TQObject *tqparent = 0, const char *name = 0);
~CSnippet();
TQString getKey() { return _sKey; }
TQString getValue() { return _sValue; }
diff --git a/kate/snippets/cwidgetsnippets.cpp b/kate/snippets/cwidgetsnippets.cpp
index e58c15f..819bcaf 100644
--- a/kate/snippets/cwidgetsnippets.cpp
+++ b/kate/snippets/cwidgetsnippets.cpp
@@ -9,8 +9,8 @@
***************************************************************************/
#include "cwidgetsnippets.h"
-CWidgetSnippets::CWidgetSnippets( TQWidget* parent, const char* name, WFlags fl)
- : CWidgetSnippetsBase(parent, name, fl)
+CWidgetSnippets::CWidgetSnippets( TQWidget* tqparent, const char* name, WFlags fl)
+ : CWidgetSnippetsBase(tqparent, name, fl)
{
}
diff --git a/kate/snippets/cwidgetsnippets.h b/kate/snippets/cwidgetsnippets.h
index 831f335..f3962e1 100644
--- a/kate/snippets/cwidgetsnippets.h
+++ b/kate/snippets/cwidgetsnippets.h
@@ -17,7 +17,7 @@
*/
class CWidgetSnippets : public CWidgetSnippetsBase {
public:
- CWidgetSnippets( TQWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
+ CWidgetSnippets( TQWidget* tqparent = 0, const char* name = 0, WFlags fl = 0 );
~CWidgetSnippets();
diff --git a/kate/snippets/plugin_katesnippets.cpp b/kate/snippets/plugin_katesnippets.cpp
index fd594e1..8e0d6cb 100644
--- a/kate/snippets/plugin_katesnippets.cpp
+++ b/kate/snippets/plugin_katesnippets.cpp
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2004 Stephan Möres <Erdling@gmx.net>
+ * Copyright (C) 2004 Stephan M�res <Erdling@gmx.net>
*/
#include "plugin_katesnippets.h"
@@ -95,12 +95,12 @@ KatePluginSnippetsView::~ KatePluginSnippetsView() {
/**
* ctor KatePluginSnippets
- * @param parent
+ * @param tqparent
* @param name
* @return
*/
-KatePluginSnippets::KatePluginSnippets( TQObject* parent, const char* name, const TQStringList& )
- : Kate::Plugin ( (Kate::Application*)parent, name ) {}
+KatePluginSnippets::KatePluginSnippets( TQObject* tqparent, const char* name, const TQStringList& )
+ : Kate::Plugin ( (Kate::Application*)tqparent, name ) {}
/**
* dtor KatePluginSnippets
@@ -170,9 +170,9 @@ void KatePluginSnippetsView::slot_lvSnippetsClicked (TQListViewItem * item) {
kv->keyDelete();
}
- sText.replace( TQRegExp("<mark/>"), sSelection );
- sText.replace( TQRegExp("<date/>"), TQDate::currentDate().toString(Qt::LocalDate) );
- sText.replace( TQRegExp("<time/>"), TQTime::currentTime().toString(Qt::LocalDate) );
+ sText.tqreplace( TQRegExp("<mark/>"), sSelection );
+ sText.tqreplace( TQRegExp("<date/>"), TQDate::tqcurrentDate().toString(Qt::LocalDate) );
+ sText.tqreplace( TQRegExp("<time/>"), TQTime::currentTime().toString(Qt::LocalDate) );
kv->insertText ( sText );
}
kv->setFocus();
@@ -254,7 +254,7 @@ void KatePluginSnippetsView::readConfig() {
lvi = insertItem(sKey, false);
- lSnippets.append( new CSnippet(sKey, sValue, lvi, this) );
+ lSnippets.append( new CSnippet(sKey, sValue, lvi, TQT_TQOBJECT(this)) );
}
// <defaults>
@@ -262,12 +262,12 @@ void KatePluginSnippetsView::readConfig() {
sKey = "DEBUG variable";
sValue = "## < DEBUG >\nout \"<pre>\\$<mark/> : \\\"$<mark/>\\\"\\n</pre>\"\n## </DEBUG >\n";
lvi = insertItem(sKey, false);
- lSnippets.append( new CSnippet(sKey, sValue, lvi, this) );
+ lSnippets.append( new CSnippet(sKey, sValue, lvi, TQT_TQOBJECT(this)) );
sKey = "proc-header";
sValue = "## [created : <date/>, <time/>]\n## Description:\n## ============\n## The function \"<mark/>\" ...\n##\n##\n##\n##\n## Input:\n## ======\n##\n##\n##\nproc <mark/> {args} {\n\n ## add your code here\n\n return \"\"\n}\n";
lvi = insertItem(sKey, false);
- lSnippets.append( new CSnippet(sKey, sValue, lvi, this) );
+ lSnippets.append( new CSnippet(sKey, sValue, lvi, TQT_TQOBJECT(this)) );
}
// </defaults>
diff --git a/kate/snippets/plugin_katesnippets.h b/kate/snippets/plugin_katesnippets.h
index aac5049..0aca230 100644
--- a/kate/snippets/plugin_katesnippets.h
+++ b/kate/snippets/plugin_katesnippets.h
@@ -31,6 +31,7 @@
class KatePluginSnippetsView : public CWidgetSnippets, public KXMLGUIClient {
Q_OBJECT
+ TQ_OBJECT
friend class KatePluginSnippets;
@@ -62,9 +63,10 @@ public:
class KatePluginSnippets : public Kate::Plugin, Kate::PluginViewInterface {
Q_OBJECT
+ TQ_OBJECT
public:
- KatePluginSnippets( TQObject* parent = 0, const char* name = 0, const TQStringList& = TQStringList() );
+ KatePluginSnippets( TQObject* tqparent = 0, const char* name = 0, const TQStringList& = TQStringList() );
virtual ~KatePluginSnippets();
void addView (Kate::MainWindow *win);