summaryrefslogtreecommitdiffstats
path: root/ksvg
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-08-02 19:23:46 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-08-02 19:23:46 +0000
commiteba47f8f0637f451e21348187591e1f1fd58ac74 (patch)
tree448f10b95c656604acc331a3236c1e59bde5c1ad /ksvg
parentc7e8736c69373f48b0401319757c742e8607431a (diff)
downloadtdegraphics-eba47f8f0637f451e21348187591e1f1fd58ac74.tar.gz
tdegraphics-eba47f8f0637f451e21348187591e1f1fd58ac74.zip
TQt conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegraphics@1158446 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'ksvg')
-rw-r--r--ksvg/core/CanvasFactory.cpp32
-rw-r--r--ksvg/core/CanvasFactory.h12
-rw-r--r--ksvg/core/CanvasItem.h18
-rw-r--r--ksvg/core/CanvasItems.cpp26
-rw-r--r--ksvg/core/CanvasItems.h6
-rw-r--r--ksvg/core/DocumentFactory.cpp8
-rw-r--r--ksvg/core/DocumentFactory.h4
-rw-r--r--ksvg/core/KSVGCanvas.cpp102
-rw-r--r--ksvg/core/KSVGCanvas.h54
-rw-r--r--ksvg/core/KSVGHelper.h14
-rw-r--r--ksvg/core/KSVGLoader.cpp112
-rw-r--r--ksvg/core/KSVGLoader.h20
-rw-r--r--ksvg/core/KSVGReader.cc82
-rw-r--r--ksvg/core/KSVGReader.h14
-rw-r--r--ksvg/core/KSVGTextChunk.cpp4
-rw-r--r--ksvg/core/KSVGTextChunk.h10
-rw-r--r--ksvg/ecma/ksvg_ecma.cpp28
-rw-r--r--ksvg/ecma/ksvg_ecma.h12
-rw-r--r--ksvg/ecma/ksvg_ecmaeventlistener.cpp8
-rw-r--r--ksvg/ecma/ksvg_ecmaeventlistener.h6
-rw-r--r--ksvg/ecma/ksvg_helper.cpp14
-rw-r--r--ksvg/ecma/ksvg_scriptinterpreter.h4
-rw-r--r--ksvg/ecma/ksvg_window.cpp30
-rw-r--r--ksvg/ecma/ksvg_window.h16
-rw-r--r--ksvg/impl/LRUCache.h4
-rw-r--r--ksvg/impl/SVGAngleImpl.cc2
-rw-r--r--ksvg/impl/SVGAnimateColorElementImpl.cc6
-rw-r--r--ksvg/impl/SVGAnimateColorElementImpl.h2
-rw-r--r--ksvg/impl/SVGAnimateElementImpl.cc4
-rw-r--r--ksvg/impl/SVGAnimateElementImpl.h4
-rw-r--r--ksvg/impl/SVGAnimateMotionElementImpl.cc6
-rw-r--r--ksvg/impl/SVGAnimateTransformElementImpl.cc14
-rw-r--r--ksvg/impl/SVGAnimateTransformElementImpl.h6
-rw-r--r--ksvg/impl/SVGAnimatedPointsImpl.cc12
-rw-r--r--ksvg/impl/SVGAnimatedPointsImpl.h4
-rw-r--r--ksvg/impl/SVGAnimationElementImpl.cc36
-rw-r--r--ksvg/impl/SVGAnimationElementImpl.h24
-rw-r--r--ksvg/impl/SVGColorImpl.cc20
-rw-r--r--ksvg/impl/SVGColorImpl.h2
-rw-r--r--ksvg/impl/SVGColorProfileElementImpl.cc14
-rw-r--r--ksvg/impl/SVGColorProfileElementImpl.h6
-rw-r--r--ksvg/impl/SVGContainerImpl.cc2
-rw-r--r--ksvg/impl/SVGDocumentImpl.cc34
-rw-r--r--ksvg/impl/SVGDocumentImpl.h42
-rw-r--r--ksvg/impl/SVGEcma.cc2
-rw-r--r--ksvg/impl/SVGElementImpl.cc44
-rw-r--r--ksvg/impl/SVGElementImpl.h28
-rw-r--r--ksvg/impl/SVGEventImpl.cc10
-rw-r--r--ksvg/impl/SVGEventImpl.h10
-rw-r--r--ksvg/impl/SVGFitToViewBoxImpl.cc10
-rw-r--r--ksvg/impl/SVGFitToViewBoxImpl.h4
-rw-r--r--ksvg/impl/SVGGlyphElementImpl.cc2
-rw-r--r--ksvg/impl/SVGGlyphElementImpl.h4
-rw-r--r--ksvg/impl/SVGGradientElementImpl.cc12
-rw-r--r--ksvg/impl/SVGGradientElementImpl.h4
-rw-r--r--ksvg/impl/SVGHelperImpl.cc42
-rw-r--r--ksvg/impl/SVGHelperImpl.h18
-rw-r--r--ksvg/impl/SVGImageElementImpl.cc32
-rw-r--r--ksvg/impl/SVGImageElementImpl.h20
-rw-r--r--ksvg/impl/SVGLangSpaceImpl.cc12
-rw-r--r--ksvg/impl/SVGLangSpaceImpl.h2
-rw-r--r--ksvg/impl/SVGLengthImpl.cc28
-rw-r--r--ksvg/impl/SVGLengthImpl.h6
-rw-r--r--ksvg/impl/SVGLinearGradientElementImpl.cc6
-rw-r--r--ksvg/impl/SVGLinearGradientElementImpl.h2
-rw-r--r--ksvg/impl/SVGList.h4
-rw-r--r--ksvg/impl/SVGMarkerElementImpl.cc2
-rw-r--r--ksvg/impl/SVGMaskElementImpl.cc24
-rw-r--r--ksvg/impl/SVGMaskElementImpl.h16
-rw-r--r--ksvg/impl/SVGMatrixImpl.cc32
-rw-r--r--ksvg/impl/SVGMatrixImpl.h12
-rw-r--r--ksvg/impl/SVGPaintImpl.cc2
-rw-r--r--ksvg/impl/SVGPaintImpl.h2
-rw-r--r--ksvg/impl/SVGPaintServerImpl.cc2
-rw-r--r--ksvg/impl/SVGPaintServerImpl.h2
-rw-r--r--ksvg/impl/SVGPathElementImpl.cc10
-rw-r--r--ksvg/impl/SVGPathElementImpl.h8
-rw-r--r--ksvg/impl/SVGPathSegArcImpl.h4
-rw-r--r--ksvg/impl/SVGPathSegClosePathImpl.h2
-rw-r--r--ksvg/impl/SVGPathSegCurvetoCubicImpl.h4
-rw-r--r--ksvg/impl/SVGPathSegCurvetoCubicSmoothImpl.h4
-rw-r--r--ksvg/impl/SVGPathSegCurvetoQuadraticImpl.h4
-rw-r--r--ksvg/impl/SVGPathSegCurvetoQuadraticSmoothImpl.h4
-rw-r--r--ksvg/impl/SVGPathSegImpl.h2
-rw-r--r--ksvg/impl/SVGPathSegLinetoHorizontalImpl.h4
-rw-r--r--ksvg/impl/SVGPathSegLinetoImpl.h4
-rw-r--r--ksvg/impl/SVGPathSegLinetoVerticalImpl.h4
-rw-r--r--ksvg/impl/SVGPathSegMovetoImpl.h4
-rw-r--r--ksvg/impl/SVGPatternElementImpl.cc28
-rw-r--r--ksvg/impl/SVGPatternElementImpl.h22
-rw-r--r--ksvg/impl/SVGPreserveAspectRatioImpl.cc8
-rw-r--r--ksvg/impl/SVGPreserveAspectRatioImpl.h4
-rw-r--r--ksvg/impl/SVGRadialGradientElementImpl.cc6
-rw-r--r--ksvg/impl/SVGRadialGradientElementImpl.h2
-rw-r--r--ksvg/impl/SVGRectImpl.cc10
-rw-r--r--ksvg/impl/SVGRectImpl.h8
-rw-r--r--ksvg/impl/SVGSVGElementImpl.cc32
-rw-r--r--ksvg/impl/SVGSVGElementImpl.h14
-rw-r--r--ksvg/impl/SVGScriptElementImpl.cc24
-rw-r--r--ksvg/impl/SVGScriptElementImpl.h12
-rw-r--r--ksvg/impl/SVGSetElementImpl.h2
-rw-r--r--ksvg/impl/SVGShapeImpl.cc4
-rw-r--r--ksvg/impl/SVGShapeImpl.h4
-rw-r--r--ksvg/impl/SVGStringListImpl.cc4
-rw-r--r--ksvg/impl/SVGStringListImpl.h4
-rw-r--r--ksvg/impl/SVGStylableImpl.cc74
-rw-r--r--ksvg/impl/SVGStylableImpl.h48
-rw-r--r--ksvg/impl/SVGTRefElementImpl.cc4
-rw-r--r--ksvg/impl/SVGTSpanElementImpl.cc2
-rw-r--r--ksvg/impl/SVGTSpanElementImpl.h2
-rw-r--r--ksvg/impl/SVGTestsImpl.cc8
-rw-r--r--ksvg/impl/SVGTestsImpl.h6
-rw-r--r--ksvg/impl/SVGTextContentElementImpl.cc10
-rw-r--r--ksvg/impl/SVGTextContentElementImpl.h2
-rw-r--r--ksvg/impl/SVGTextElementImpl.cc6
-rw-r--r--ksvg/impl/SVGTextElementImpl.h4
-rw-r--r--ksvg/impl/SVGTextPathElementImpl.cc10
-rw-r--r--ksvg/impl/SVGTextPathElementImpl.h2
-rw-r--r--ksvg/impl/SVGTimeScheduler.cc26
-rw-r--r--ksvg/impl/SVGTimeScheduler.h24
-rw-r--r--ksvg/impl/SVGTransformImpl.cc18
-rw-r--r--ksvg/impl/SVGTransformImpl.h4
-rw-r--r--ksvg/impl/SVGTransformableImpl.h2
-rw-r--r--ksvg/impl/SVGURIReferenceImpl.cc8
-rw-r--r--ksvg/impl/SVGURIReferenceImpl.h8
-rw-r--r--ksvg/impl/SVGUnitConverter.h12
-rw-r--r--ksvg/impl/SVGUseElementImpl.cc16
-rw-r--r--ksvg/impl/SVGViewSpecImpl.cc8
-rw-r--r--ksvg/impl/SVGViewSpecImpl.h2
-rw-r--r--ksvg/impl/SVGWindowImpl.cc22
-rw-r--r--ksvg/impl/SVGWindowImpl.h8
-rw-r--r--ksvg/impl/libs/libtext2path/src/QtUnicode.cpp4
-rw-r--r--ksvg/impl/svgpathparser.cc6
-rw-r--r--ksvg/impl/svgpathparser.h4
-rw-r--r--ksvg/plugin/backends/agg/AggCanvasFactory.cpp2
-rw-r--r--ksvg/plugin/backends/agg/AggCanvasFactory.h2
-rw-r--r--ksvg/plugin/backends/agg/AggCanvasItems.cpp64
-rw-r--r--ksvg/plugin/backends/agg/AggCanvasItems.h32
-rw-r--r--ksvg/plugin/backends/libart/BezierPathLibart.h4
-rw-r--r--ksvg/plugin/backends/libart/LibartCanvas.cpp22
-rw-r--r--ksvg/plugin/backends/libart/LibartCanvas.h10
-rw-r--r--ksvg/plugin/backends/libart/LibartCanvasFactory.cpp2
-rw-r--r--ksvg/plugin/backends/libart/LibartCanvasFactory.h2
-rw-r--r--ksvg/plugin/backends/libart/LibartCanvasItems.cpp82
-rw-r--r--ksvg/plugin/backends/libart/LibartCanvasItems.h64
-rw-r--r--ksvg/plugin/ksvg_factory.cpp14
-rw-r--r--ksvg/plugin/ksvg_factory.h4
-rw-r--r--ksvg/plugin/ksvg_plugin.cpp78
-rw-r--r--ksvg/plugin/ksvg_plugin.h22
-rw-r--r--ksvg/plugin/ksvg_widget.cpp38
-rw-r--r--ksvg/plugin/ksvg_widget.h28
-rw-r--r--ksvg/plugin/svgcreator.cpp10
-rw-r--r--ksvg/plugin/svgcreator.h4
-rw-r--r--ksvg/test/external/SVGTestWidget.cc34
-rw-r--r--ksvg/test/external/SVGTestWidget.h22
-rw-r--r--ksvg/test/external/printnodetest.cpp4
-rw-r--r--ksvg/test/external/printnodetest.h4
157 files changed, 1210 insertions, 1210 deletions
diff --git a/ksvg/core/CanvasFactory.cpp b/ksvg/core/CanvasFactory.cpp
index ca2822b2..e03bf9ea 100644
--- a/ksvg/core/CanvasFactory.cpp
+++ b/ksvg/core/CanvasFactory.cpp
@@ -18,7 +18,7 @@
Boston, MA 02110-1301, USA.
*/
-#include <qfile.h>
+#include <tqfile.h>
#include <kdebug.h>
#include <ksimpleconfig.h>
@@ -57,14 +57,14 @@ void CanvasFactory::queryCanvas()
{
m_canvasList.clear();
- QValueList<KService::Ptr> traderList = KTrader::self()->query("KSVG/Renderer", "(Type == 'Service')");
+ TQValueList<KService::Ptr> traderList = KTrader::self()->query("KSVG/Renderer", "(Type == 'Service')");
KTrader::OfferList::Iterator it(traderList.begin());
for( ; it != traderList.end(); ++it)
{
KService::Ptr ptr = (*it);
- QString name = ptr->property("Name").toString();
- QString internal = ptr->property("X-KSVG-InternalName").toString();
+ TQString name = ptr->property("Name").toString();
+ TQString internal = ptr->property("X-KSVG-InternalName").toString();
if(name.isEmpty() || internal.isEmpty())
continue;
@@ -90,20 +90,20 @@ KSVGCanvas *CanvasFactory::loadCanvas(int width, int height)
KSimpleConfig *config = new KSimpleConfig("ksvgpluginrc", false);
config->setGroup("Canvas");
- QString load = config->readEntry("ActiveCanvas", "libart");
+ TQString load = config->readEntry("ActiveCanvas", "libart");
delete config;
- QPtrListIterator<CanvasInfo> it(m_canvasList);
+ TQPtrListIterator<CanvasInfo> it(m_canvasList);
CanvasInfo *info = it.current();
while((info = it.current()) != 0)
{
if(info->internal == load)
{
- QStringList args;
- args.prepend(QString::number(width));
- args.prepend(QString::number(height));
+ TQStringList args;
+ args.prepend(TQString::number(width));
+ args.prepend(TQString::number(height));
- info->canvas = KParts::ComponentFactory::createInstanceFromLibrary<KSVGCanvas>(QFile::encodeName(info->service->library()), 0, 0, args);
+ info->canvas = KParts::ComponentFactory::createInstanceFromLibrary<KSVGCanvas>(TQFile::encodeName(info->service->library()), 0, 0, args);
if(info->canvas)
return info->canvas;
@@ -122,7 +122,7 @@ KSVGCanvas *CanvasFactory::loadCanvas(int width, int height)
int CanvasFactory::itemInList(KSVGCanvas *canvas)
{
- QPtrListIterator<CanvasInfo> it(m_canvasList);
+ TQPtrListIterator<CanvasInfo> it(m_canvasList);
CanvasInfo *info = it.current();
unsigned int i = 0;
while((info = it.current()) != 0)
@@ -137,9 +137,9 @@ int CanvasFactory::itemInList(KSVGCanvas *canvas)
return 0;
}
-QString CanvasFactory::internalNameFor(const QString &name)
+TQString CanvasFactory::internalNameFor(const TQString &name)
{
- QPtrListIterator<CanvasInfo> it(m_canvasList);
+ TQPtrListIterator<CanvasInfo> it(m_canvasList);
CanvasInfo *info = it.current();
while((info = it.current()) != 0)
{
@@ -149,12 +149,12 @@ QString CanvasFactory::internalNameFor(const QString &name)
++it;
}
- return QString::null;
+ return TQString::null;
}
void CanvasFactory::deleteCanvas(KSVGCanvas *canvas)
{
- QPtrListIterator<CanvasInfo> it(m_canvasList);
+ TQPtrListIterator<CanvasInfo> it(m_canvasList);
CanvasInfo *info = it.current();
while((info = it.current()) != 0)
{
@@ -168,7 +168,7 @@ void CanvasFactory::deleteCanvas(KSVGCanvas *canvas)
}
}
-QPtrList<CanvasInfo> CanvasFactory::canvasList()
+TQPtrList<CanvasInfo> CanvasFactory::canvasList()
{
return m_canvasList;
}
diff --git a/ksvg/core/CanvasFactory.h b/ksvg/core/CanvasFactory.h
index dc272700..24c59ba6 100644
--- a/ksvg/core/CanvasFactory.h
+++ b/ksvg/core/CanvasFactory.h
@@ -23,8 +23,8 @@
#include <ktrader.h>
-#include <qstring.h>
-#include <qptrlist.h>
+#include <tqstring.h>
+#include <tqptrlist.h>
namespace KSVG
{
@@ -35,7 +35,7 @@ class CanvasInfo
public:
KService::Ptr service;
KSVGCanvas *canvas;
- QString name, internal;
+ TQString name, internal;
};
class CanvasFactory
@@ -50,16 +50,16 @@ public:
KSVGCanvas *loadCanvas(int width, int height);
int itemInList(KSVGCanvas *canvas);
- QString internalNameFor(const QString &name);
+ TQString internalNameFor(const TQString &name);
void deleteCanvas(KSVGCanvas *canvas);
- QPtrList<CanvasInfo> canvasList();
+ TQPtrList<CanvasInfo> canvasList();
private:
void queryCanvas();
static CanvasFactory *s_factory;
- QPtrList<CanvasInfo> m_canvasList;
+ TQPtrList<CanvasInfo> m_canvasList;
};
}
diff --git a/ksvg/core/CanvasItem.h b/ksvg/core/CanvasItem.h
index 7ffc7ad9..1c6b1e34 100644
--- a/ksvg/core/CanvasItem.h
+++ b/ksvg/core/CanvasItem.h
@@ -21,9 +21,9 @@
#ifndef CANVASITEM_H
#define CANVASITEM_H
-#include <qrect.h>
-#include <qpoint.h>
-#include <qvaluelist.h>
+#include <tqrect.h>
+#include <tqpoint.h>
+#include <tqvaluelist.h>
#define CHUNK_SIZE_HORIZONTAL 32
#define CHUNK_SIZE_VERTICAL 32
@@ -60,9 +60,9 @@ public:
CanvasItem() { m_zIndex = 0; m_referenced = false; }
virtual ~CanvasItem() { }
- virtual QRect bbox() const = 0;
- virtual bool fillContains(const QPoint &) = 0;
- virtual bool strokeContains(const QPoint &) = 0;
+ virtual TQRect bbox() const = 0;
+ virtual bool fillContains(const TQPoint &) = 0;
+ virtual bool strokeContains(const TQPoint &) = 0;
virtual void update(CanvasItemUpdate reason, int param1 = 0, int param2 = 0) = 0;
virtual void draw() = 0;
virtual bool isVisible() = 0;
@@ -114,10 +114,10 @@ private:
CanvasItem *ptr;
};
-class CanvasItemList : public QValueList<CanvasItem *>
+class CanvasItemList : public TQValueList<CanvasItem *>
{
public:
- void sort() { qHeapSort(*((QValueList<CanvasItemPtr> *) this)); }
+ void sort() { qHeapSort(*((TQValueList<CanvasItemPtr> *) this)); }
};
class CanvasChunk
@@ -138,7 +138,7 @@ public:
short x() const { return m_x; }
short y() const { return m_y; }
- QRect bbox() const { return QRect(m_x * CHUNK_SIZE_HORIZONTAL, m_y * CHUNK_SIZE_VERTICAL, CHUNK_SIZE_HORIZONTAL, CHUNK_SIZE_VERTICAL); }
+ TQRect bbox() const { return TQRect(m_x * CHUNK_SIZE_HORIZONTAL, m_y * CHUNK_SIZE_VERTICAL, CHUNK_SIZE_HORIZONTAL, CHUNK_SIZE_VERTICAL); }
private:
CanvasItemList m_list;
diff --git a/ksvg/core/CanvasItems.cpp b/ksvg/core/CanvasItems.cpp
index 0ffd017c..333f4608 100644
--- a/ksvg/core/CanvasItems.cpp
+++ b/ksvg/core/CanvasItems.cpp
@@ -104,7 +104,7 @@ void CanvasText::handleTSpan(KSVGCanvas *canvas, const SVGMatrixImpl *screenCTM,
usey = int(tspan->y()->baseVal()->getItem(0)->value());
}
- QString text = tspan->text();
+ TQString text = tspan->text();
if(!text.isEmpty())
{
T2P::GlyphLayoutParams *params = tspan->layoutParams();
@@ -118,7 +118,7 @@ void CanvasText::handleTSpan(KSVGCanvas *canvas, const SVGMatrixImpl *screenCTM,
if(bMultipleY && i < tspan->y()->baseVal()->numberOfItems())
usey = int(tspan->y()->baseVal()->getItem(i)->value());
- textChunk->addText(QString(text.at(i)), tspan);
+ textChunk->addText(TQString(text.at(i)), tspan);
createGlyphs(textChunk, canvas, screenCTM, usex, usey, endx, endy, bpath);
textChunk->clear();
@@ -159,7 +159,7 @@ void CanvasText::handleTSpan(KSVGCanvas *canvas, const SVGMatrixImpl *screenCTM,
if(tspanFound)
{
DOM::Text text = node;
- QString temp = text.data().string();
+ TQString temp = text.data().string();
textChunk->addText(temp, tspan);
}
}
@@ -199,13 +199,13 @@ KSVGTextChunk *CanvasText::createTextChunk(KSVGCanvas *canvas, const SVGMatrixIm
if(node.nodeType() == DOM::Node::TEXT_NODE)
{
DOM::Text text = node;
- QString temp = text.data().string();
+ TQString temp = text.data().string();
if(!temp.isEmpty())
{
if(m_text->getTextDirection() != LTR)
{
- QString convert = temp;
+ TQString convert = temp;
for(int i = temp.length(); i > 0; i--)
convert[temp.length() - i] = temp[i - 1];
@@ -229,7 +229,7 @@ KSVGTextChunk *CanvasText::createTextChunk(KSVGCanvas *canvas, const SVGMatrixIm
}
SVGTextPathElementImpl *tpath = dynamic_cast<SVGTextPathElementImpl *>(element);
- QString target = SVGURIReferenceImpl::getTarget(tpath->href()->baseVal().string());
+ TQString target = SVGURIReferenceImpl::getTarget(tpath->href()->baseVal().string());
SVGPathElementImpl *path = dynamic_cast<SVGPathElementImpl *>(tpath->ownerSVGElement()->getElementById(target));
T2P::BezierPath *bpath = 0;
@@ -242,7 +242,7 @@ KSVGTextChunk *CanvasText::createTextChunk(KSVGCanvas *canvas, const SVGMatrixIm
if(iterate.nodeType() == DOM::Node::TEXT_NODE)
{
DOM::Text text = iterate;
- QString temp = text.data().string();
+ TQString temp = text.data().string();
if(!temp.isEmpty())
textChunk->addText(temp, tpath);
@@ -287,7 +287,7 @@ KSVGTextChunk *CanvasText::createTextChunk(KSVGCanvas *canvas, const SVGMatrixIm
void CanvasText::createGlyphs(KSVGTextChunk *textChunk, KSVGCanvas *canvas, const SVGMatrixImpl *screenCTM, int curx, int cury, int &endx, int &endy, T2P::BezierPath *bpath) const
{
double _curx = double(curx);
- QMemArray<double> _cury(1);
+ TQMemArray<double> _cury(1);
_cury[0] = double(cury);
T2P::GlyphLayoutParams *params = m_text->layoutParams();
@@ -296,8 +296,8 @@ void CanvasText::createGlyphs(KSVGTextChunk *textChunk, KSVGCanvas *canvas, cons
SVGTextContentElementImpl *tc0 = tc;
T2P::SharedFont font;
- QString text;
- QPtrList<T2P::GlyphSet> glyphs;
+ TQString text;
+ TQPtrList<T2P::GlyphSet> glyphs;
glyphs.setAutoDelete(true);
double pathAdvance = 0;
@@ -323,7 +323,7 @@ void CanvasText::createGlyphs(KSVGTextChunk *textChunk, KSVGCanvas *canvas, cons
text = textChunk->getText(i);
if(i != textChunk->count() - 1)
- text += QChar(' ');
+ text += TQChar(' ');
if(!canvas->fontContext()->ready())
canvas->fontContext()->init();
@@ -380,7 +380,7 @@ void CanvasText::createGlyphs(KSVGTextChunk *textChunk, KSVGCanvas *canvas, cons
params->setTextPathStartOffset(pathAdvance);
if(tp && tp->dy()->baseVal()->numberOfItems() > 0)
pathDy += tp->dy()->baseVal()->getItem(0)->value();
- QString shift = QString("%1%%").arg((pathDy / font->fontParams()->size()) * -100.0);
+ TQString shift = TQString("%1%%").arg((pathDy / font->fontParams()->size()) * -100.0);
params->setBaselineShift(shift.latin1());
}
@@ -484,7 +484,7 @@ void CanvasText::createGlyphs(KSVGTextChunk *textChunk, KSVGCanvas *canvas, cons
// #####
-void MarkerHelper::doMarker(SVGShapeImpl *shape, SVGStylableImpl *style, double x, double y, double angle, const QString &markerId)
+void MarkerHelper::doMarker(SVGShapeImpl *shape, SVGStylableImpl *style, double x, double y, double angle, const TQString &markerId)
{
SVGMarkerElementImpl *marker = dynamic_cast<SVGMarkerElementImpl *>(shape->ownerSVGElement()->getElementById(markerId));
if(marker)
diff --git a/ksvg/core/CanvasItems.h b/ksvg/core/CanvasItems.h
index 8959d6ba..9f5eed43 100644
--- a/ksvg/core/CanvasItems.h
+++ b/ksvg/core/CanvasItems.h
@@ -21,7 +21,7 @@
#ifndef CANVASITEMS_H
#define CANVASITEMS_H
-#include <qptrlist.h>
+#include <tqptrlist.h>
#include "CanvasItem.h"
#include "SVGTextElementImpl.h"
#include "SVGTextPathElementImpl.h"
@@ -85,7 +85,7 @@ protected:
void doEndMarker(SVGShapeImpl *shape, SVGStylableImpl *style, double x, double y, double angle = 0.0);
private:
- void doMarker(SVGShapeImpl *shape, SVGStylableImpl *style, double x, double y, double angle, const QString &marker);
+ void doMarker(SVGShapeImpl *shape, SVGStylableImpl *style, double x, double y, double angle, const TQString &marker);
};
class CanvasText : public CanvasItem
@@ -120,7 +120,7 @@ public:
bool finalized() { return m_finalized; }
virtual void finalizePaintServer() = 0;
- virtual void reference(const QString &href) = 0;
+ virtual void reference(const TQString &href) = 0;
private:
bool m_finalized;
diff --git a/ksvg/core/DocumentFactory.cpp b/ksvg/core/DocumentFactory.cpp
index bcc0ddcb..4ae743be 100644
--- a/ksvg/core/DocumentFactory.cpp
+++ b/ksvg/core/DocumentFactory.cpp
@@ -18,7 +18,7 @@
Boston, MA 02110-1301, USA.
*/
-#include <qobject.h>
+#include <tqobject.h>
#include <kdebug.h>
#include <kstaticdeleter.h>
@@ -42,7 +42,7 @@ namespace KSVG
SVGDocumentImpl *doc() const { return m_docs.current(); }
private:
- QPtrList<SVGDocumentImpl> m_docs;
+ TQPtrList<SVGDocumentImpl> m_docs;
};
}
@@ -65,10 +65,10 @@ DocumentFactory *DocumentFactory::self()
return s_factory;
}
-SVGDocument *DocumentFactory::requestDocument(QObject *notifyObject, const char *notifySlot) const
+SVGDocument *DocumentFactory::requestDocument(TQObject *notifyObject, const char *notifySlot) const
{
SVGDocumentImpl *impl = requestDocumentImpl(false);
- QObject::connect(impl, SIGNAL(finishedParsing(bool, const QString &)), notifyObject, notifySlot);
+ TQObject::connect(impl, TQT_SIGNAL(finishedParsing(bool, const TQString &)), notifyObject, notifySlot);
return new SVGDocument(impl);
}
diff --git a/ksvg/core/DocumentFactory.h b/ksvg/core/DocumentFactory.h
index 290d54ac..6225b37d 100644
--- a/ksvg/core/DocumentFactory.h
+++ b/ksvg/core/DocumentFactory.h
@@ -22,7 +22,7 @@
#define DocumentFactory_H
#include <kurl.h>
-#include <qobject.h>
+#include <tqobject.h>
namespace KSVG
{
@@ -39,7 +39,7 @@ public:
static DocumentFactory *self();
// Creates a document and connects the parsingFinished() signal to the notifySlot...
- SVGDocument *requestDocument(QObject *notifyObject, const char *notifySlot) const;
+ SVGDocument *requestDocument(TQObject *notifyObject, const char *notifySlot) const;
// Loads 'url' and emits parsingFinisihed() signal, when done
bool startParsing(SVGDocument *document, const KURL &url);
diff --git a/ksvg/core/KSVGCanvas.cpp b/ksvg/core/KSVGCanvas.cpp
index d4e75d79..1f504c02 100644
--- a/ksvg/core/KSVGCanvas.cpp
+++ b/ksvg/core/KSVGCanvas.cpp
@@ -32,10 +32,10 @@
#include <kdebug.h>
#include <kglobal.h>
-#include <qstring.h>
-#include <qdatetime.h>
-#include <qpaintdevicemetrics.h>
-#include <qwmatrix.h>
+#include <tqstring.h>
+#include <tqdatetime.h>
+#include <tqpaintdevicemetrics.h>
+#include <tqwmatrix.h>
#include <X11/Xlib.h>
@@ -63,12 +63,12 @@ KSVGCanvas::KSVGCanvas(unsigned int width, unsigned int height) : m_viewportWidt
m_buffer = 0;
- m_backgroundColor = QColor(250, 250, 250);
+ m_backgroundColor = TQColor(250, 250, 250);
m_immediateUpdate = false;
}
-void KSVGCanvas::setup(QPaintDevice *drawWindow, QPaintDevice *directWindow)
+void KSVGCanvas::setup(TQPaintDevice *drawWindow, TQPaintDevice *directWindow)
{
m_drawWindow = drawWindow;
m_directWindow = directWindow;
@@ -151,10 +151,10 @@ void KSVGCanvas::resize(unsigned int w, unsigned int h)
int diffw = w - m_width;
int diffh = h - m_height;
- QRect r(m_width, 0, diffw, m_height + diffh);
- QRect r3(0, m_height, m_width + diffw, diffh);
+ TQRect r(m_width, 0, diffw, m_height + diffh);
+ TQRect r3(0, m_height, m_width + diffw, diffh);
- QWMatrix mtx;
+ TQWMatrix mtx;
mtx.translate(m_pan.x(), m_pan.y());
mtx.scale(m_zoom, m_zoom);
@@ -169,7 +169,7 @@ void KSVGCanvas::resize(unsigned int w, unsigned int h)
CanvasItemList drawables;
if(diffw > 0)
{
- QRect r2 = mtx.invert().map(r);
+ TQRect r2 = mtx.invert().map(r);
// Recalc items
for(int j = r2.top() / int(m_chunkSizeVer); j <= r2.bottom() / int(m_chunkSizeVer); j++)
@@ -191,7 +191,7 @@ void KSVGCanvas::resize(unsigned int w, unsigned int h)
if(diffh > 0)
{
- QRect r4 = mtx.invert().map(r3);
+ TQRect r4 = mtx.invert().map(r3);
// Recalc items
for(int j = r4.top() / int(m_chunkSizeVer); j <= r4.bottom() / int(m_chunkSizeVer); j++)
@@ -234,7 +234,7 @@ void KSVGCanvas::setRenderBufferSize(int w, int h)
if(needsRedraw)
{
- QPaintDeviceMetrics metrics(m_drawWindow);
+ TQPaintDeviceMetrics metrics(m_drawWindow);
m_width = kMin(int(w), metrics.width());
m_height = kMin(int(h), metrics.height());
@@ -248,9 +248,9 @@ void KSVGCanvas::setRenderBufferSize(int w, int h)
fill();
}
-void KSVGCanvas::clear(const QRect &r)
+void KSVGCanvas::clear(const TQRect &r)
{
- QRect r2 = r & QRect(0, 0, m_width, m_height);
+ TQRect r2 = r & TQRect(0, 0, m_width, m_height);
if(!r2.isEmpty() && m_buffer)
{
for(int i = 0; i < r2.height(); i++)
@@ -322,7 +322,7 @@ T2P::FontVisualParams *KSVGCanvas::fontVisualParams(SVGStylableImpl *style) cons
// Calc weight & slant
int weight = 0, slant = 0;
EFontStyle fontStyle = style->getFontStyle();
- QString fontWeight = style->getFontWeight();
+ TQString fontWeight = style->getFontWeight();
if(fontWeight.contains("bold"))
weight |= FC_WEIGHT_DEMIBOLD;
@@ -372,7 +372,7 @@ void KSVGCanvas::invalidate(CanvasItem *item, bool recalc)
addToChunks(item);
}
- QPtrListIterator<CanvasChunk> it = m_chunksByItem[item];
+ TQPtrListIterator<CanvasChunk> it = m_chunksByItem[item];
for(it.toFirst(); it.current(); ++it)
{
(*it)->setDirty();
@@ -389,7 +389,7 @@ void KSVGCanvas::insert(CanvasItem *item, int z)
if(z == -1)
{
item->setZIndex(m_chunksByItem.size());
- m_chunksByItem[item] = QPtrList<CanvasChunk>();
+ m_chunksByItem[item] = TQPtrList<CanvasChunk>();
addToChunks(item);
m_items.append(item);
@@ -402,7 +402,7 @@ void KSVGCanvas::insert(CanvasItem *item, int z)
if(visible)
{
item->draw();
- QRect bbox = item->bbox();
+ TQRect bbox = item->bbox();
blit(bbox, true);
}
}
@@ -425,7 +425,7 @@ void KSVGCanvas::removeItem(CanvasItem *item)
void KSVGCanvas::removeFromChunks(CanvasItem *item)
{
- QPtrListIterator<CanvasChunk> it = m_chunksByItem[item];
+ TQPtrListIterator<CanvasChunk> it = m_chunksByItem[item];
for(it.toFirst(); it.current(); ++it)
{
(*it)->remove(item);
@@ -437,8 +437,8 @@ void KSVGCanvas::removeFromChunks(CanvasItem *item)
void KSVGCanvas::addToChunks(CanvasItem *item)
{
- QRect bbox = item->bbox();
- QWMatrix mtx;
+ TQRect bbox = item->bbox();
+ TQWMatrix mtx;
mtx.translate(m_pan.x(), m_pan.y());
mtx.scale(m_zoom, m_zoom);
@@ -498,10 +498,10 @@ unsigned int KSVGCanvas::setElementItemZIndexRecursive(SVGElementImpl *element,
return z;
}
-void KSVGCanvas::update(const QPoint &panPoint, bool erase)
+void KSVGCanvas::update(const TQPoint &panPoint, bool erase)
{
#ifdef USE_TIMER
- QTime t;
+ TQTime t;
t.start();
#endif
@@ -513,16 +513,16 @@ void KSVGCanvas::update(const QPoint &panPoint, bool erase)
fill();
// reset clip paths
- QDictIterator<CanvasClipPath> itr(m_clipPaths);
+ TQDictIterator<CanvasClipPath> itr(m_clipPaths);
for(; itr.current(); ++itr)
(*itr)->update(UPDATE_TRANSFORM);
- QWMatrix mtx;
+ TQWMatrix mtx;
mtx.translate(m_pan.x(), m_pan.y());
mtx.scale(m_zoom, m_zoom);
- QRect r(0, 0, m_width, m_height);
- QRect r2 = mtx.invert().map(r);
+ TQRect r(0, 0, m_width, m_height);
+ TQRect r2 = mtx.invert().map(r);
// pan all items
for(unsigned int i = 0; i < m_items.count(); i++)
@@ -530,7 +530,7 @@ void KSVGCanvas::update(const QPoint &panPoint, bool erase)
// recalc items
CanvasItemList drawables;
- QPtrListIterator<CanvasItem> it = m_items;
+ TQPtrListIterator<CanvasItem> it = m_items;
for(int j = r2.top() / m_chunkSizeVer; j <= (r2.bottom() / m_chunkSizeVer); j++)
{
for(int i = r2.left() / m_chunkSizeHor; i <= (r2.right() / m_chunkSizeHor); i++)
@@ -552,7 +552,7 @@ void KSVGCanvas::update(const QPoint &panPoint, bool erase)
(*it)->draw();
if(m_drawWindow)
- blit(QRect(0, 0, m_width, m_height), false);
+ blit(TQRect(0, 0, m_width, m_height), false);
m_dirtyChunks.clear();
@@ -564,7 +564,7 @@ void KSVGCanvas::update(const QPoint &panPoint, bool erase)
void KSVGCanvas::update(float zoomFactor)
{
#ifdef USE_TIMER
- QTime t;
+ TQTime t;
t.start();
#endif
@@ -578,18 +578,18 @@ void KSVGCanvas::update(float zoomFactor)
fill();
// reset clip paths
- QDictIterator<CanvasClipPath> itr(m_clipPaths);
+ TQDictIterator<CanvasClipPath> itr(m_clipPaths);
for(; itr.current(); ++itr)
(*itr)->update(UPDATE_TRANSFORM);
m_zoom = zoomFactor;
- QWMatrix mtx;
+ TQWMatrix mtx;
mtx.translate(m_pan.x(), m_pan.y());
mtx.scale(m_zoom, m_zoom);
- QRect r(0, 0, m_width, m_height);
- QRect r2 = mtx.invert().map(r);
+ TQRect r(0, 0, m_width, m_height);
+ TQRect r2 = mtx.invert().map(r);
// zoom all items
for(unsigned int i = 0; i < m_items.count(); i++)
@@ -597,7 +597,7 @@ void KSVGCanvas::update(float zoomFactor)
// recalc items
CanvasItemList drawables;
- QPtrListIterator<CanvasItem> it = m_items;
+ TQPtrListIterator<CanvasItem> it = m_items;
for(int j = r2.top() / m_chunkSizeVer; j <= (r2.bottom() / m_chunkSizeVer); j++)
{
for(int i = r2.left() / m_chunkSizeHor; i <= (r2.right() / m_chunkSizeHor); i++)
@@ -619,7 +619,7 @@ void KSVGCanvas::update(float zoomFactor)
(*it)->draw();
if(m_drawWindow)
- blit(QRect(0, 0, m_width, m_height), false);
+ blit(TQRect(0, 0, m_width, m_height), false);
m_dirtyChunks.clear();
@@ -642,24 +642,24 @@ void KSVGCanvas::reset()
void KSVGCanvas::update()
{
#ifdef USE_TIMER
- QTime t;
+ TQTime t;
t.start();
#endif
- QWMatrix mtx;
+ TQWMatrix mtx;
mtx.translate(m_pan.x(), m_pan.y());
mtx.scale(m_zoom, m_zoom);
// Process dirty chunks
- QPtrList<CanvasChunk> chunkList;
+ TQPtrList<CanvasChunk> chunkList;
CanvasItemList drawables;
for(unsigned int i = 0; i < m_dirtyChunks.count(); i++)
{
CanvasChunk *chunk = m_dirtyChunks[i];
Q_ASSERT(chunk->isDirty());
- QRect r = chunk->bbox();
- QRect chunkbox(mtx.map(r.topLeft()), mtx.map(r.bottomRight()));
+ TQRect r = chunk->bbox();
+ TQRect chunkbox(mtx.map(r.topLeft()), mtx.map(r.bottomRight()));
clear(chunkbox);
chunkList.append(chunk);
@@ -686,11 +686,11 @@ void KSVGCanvas::update()
}
// Blit dirty chunks
- QPtrListIterator<CanvasChunk> it = chunkList;
+ TQPtrListIterator<CanvasChunk> it = chunkList;
for(it.toFirst(); it.current(); ++it)
{
- QRect r = (*it)->bbox();
- QRect chunkbox(mtx.map(r.topLeft()), mtx.map(r.bottomRight()));
+ TQRect r = (*it)->bbox();
+ TQRect chunkbox(mtx.map(r.topLeft()), mtx.map(r.bottomRight()));
blit(chunkbox, false);
}
@@ -701,13 +701,13 @@ void KSVGCanvas::update()
#endif
}
-CanvasItemList KSVGCanvas::collisions(const QPoint &p, bool exact) const
+CanvasItemList KSVGCanvas::collisions(const TQPoint &p, bool exact) const
{
- QWMatrix mtx;
+ TQWMatrix mtx;
mtx.translate(m_pan.x(), m_pan.y());
mtx.scale(m_zoom, m_zoom);
- QPoint p2 = mtx.invert().map(p);
+ TQPoint p2 = mtx.invert().map(p);
if(p2.x() < 0 || p2.y() < 0)
return CanvasItemList();
@@ -734,7 +734,7 @@ CanvasItemList KSVGCanvas::collisions(const QPoint &p, bool exact) const
return list;
}
-void KSVGCanvas::blit(const QRect &rect, bool direct)
+void KSVGCanvas::blit(const TQRect &rect, bool direct)
{
if(m_drawWindow && m_width && m_height)
{
@@ -761,12 +761,12 @@ void KSVGCanvas::blit(const QRect &rect, bool direct)
void KSVGCanvas::blit()
{
- return blit(QRect(0, 0, m_width, m_height), false);
+ return blit(TQRect(0, 0, m_width, m_height), false);
}
void KSVGCanvas::ChunkManager::addChunk(CanvasChunk *chunk)
{
- QString key = QString("%1 %2").arg(chunk->x()).arg(chunk->y());
+ TQString key = TQString("%1 %2").arg(chunk->x()).arg(chunk->y());
// kdDebug(26005) << k_funcinfo << "Adding chunk : " << chunk << endl;
m_chunks.insert(key, chunk);
}
@@ -774,7 +774,7 @@ void KSVGCanvas::ChunkManager::addChunk(CanvasChunk *chunk)
CanvasChunk *KSVGCanvas::ChunkManager::getChunk(short x, short y) const
{
// kdDebug(26005) << k_funcinfo << "getting chunk from : " << x << ", " << y << endl;
- QString key = QString("%1 %2").arg(x).arg(y);
+ TQString key = TQString("%1 %2").arg(x).arg(y);
return m_chunks[key];
}
diff --git a/ksvg/core/KSVGCanvas.h b/ksvg/core/KSVGCanvas.h
index 7b26997c..aa41e6c2 100644
--- a/ksvg/core/KSVGCanvas.h
+++ b/ksvg/core/KSVGCanvas.h
@@ -21,12 +21,12 @@
#ifndef KSVGCANVAS_H
#define KSVGCANVAS_H
-#include <qmap.h>
-#include <qdict.h>
-#include <qcolor.h>
-#include <qobject.h>
-#include <qptrlist.h>
-#include <qdict.h>
+#include <tqmap.h>
+#include <tqdict.h>
+#include <tqcolor.h>
+#include <tqobject.h>
+#include <tqptrlist.h>
+#include <tqdict.h>
#include <Converter.h>
@@ -55,7 +55,7 @@ class CanvasItemList;
class CanvasClipPath;
class CanvasPaintServer;
-// Must be a QObject to be able to be loaded by KLibLoader...
+// Must be a TQObject to be able to be loaded by KLibLoader...
class KSVGCanvas : public QObject
{
Q_OBJECT
@@ -65,25 +65,25 @@ public:
void setViewportDimension(unsigned int w, unsigned int h);
- void setup(QPaintDevice *drawWidget, QPaintDevice *directWindow);
+ void setup(TQPaintDevice *drawWidget, TQPaintDevice *directWindow);
void setup(unsigned char *buffer, unsigned int width = 0, unsigned int height = 0);
void reset();
void update();
void update(float zoomFactor);
- void update(const QPoint &panPoint, bool erase = true);
+ void update(const TQPoint &panPoint, bool erase = true);
void resize(unsigned int w, unsigned int h);
void retune(unsigned int csh, unsigned int csv);
void invalidate(CanvasItem *item, bool recalc = true);
- CanvasItemList collisions(const QPoint &p, bool exact = false) const;
+ CanvasItemList collisions(const TQPoint &p, bool exact = false) const;
- void setBackgroundColor(const QColor &c) { m_backgroundColor = c; }
+ void setBackgroundColor(const TQColor &c) { m_backgroundColor = c; }
void blit();
- void blit(const QRect &rect, bool direct);
+ void blit(const TQRect &rect, bool direct);
float zoom() const { return m_zoom; }
- QPoint pan() const { return m_pan; }
- void setPan(const QPoint &pan) { m_pan = pan; }
+ TQPoint pan() const { return m_pan; }
+ void setPan(const TQPoint &pan) { m_pan = pan; }
int width() const { return m_width; }
int height() const { return m_height; }
@@ -112,15 +112,15 @@ public:
void setImmediateUpdate(bool immediateUpdate) { m_immediateUpdate = immediateUpdate; }
bool immediateUpdate() const { return m_immediateUpdate; }
- QPtrList<CanvasItem> allItems() const { return m_items; }
+ TQPtrList<CanvasItem> allItems() const { return m_items; }
unsigned char *renderingBuffer() const { return m_buffer; }
unsigned int nrChannels() const { return m_nrChannels; }
unsigned int rowStride() const { return m_nrChannels * m_width; }
T2P::Converter *fontContext() { return m_fontContext; }
- QPaintDevice *drawWindow() { return m_drawWindow; }
- QPaintDevice *directWindow() { return m_directWindow; }
+ TQPaintDevice *drawWindow() { return m_drawWindow; }
+ TQPaintDevice *directWindow() { return m_directWindow; }
T2P::FontVisualParams *fontVisualParams(SVGStylableImpl *style) const;
virtual T2P::BezierPath *toBezierPath(CanvasItem *item) const { Q_UNUSED(item); return 0; }
@@ -136,7 +136,7 @@ protected:
void initVars();
void fill();
- void clear(const QRect &r);
+ void clear(const TQRect &r);
virtual void setBuffer(unsigned char *buffer);
@@ -151,25 +151,25 @@ protected:
void clear();
private:
- QDict<CanvasChunk> m_chunks;
+ TQDict<CanvasChunk> m_chunks;
} m_chunkManager;
- QValueList<CanvasChunk *> m_dirtyChunks;
+ TQValueList<CanvasChunk *> m_dirtyChunks;
- QMap<CanvasItem *, QPtrList<CanvasChunk> > m_chunksByItem;
- QPtrList<CanvasItem> m_items;
+ TQMap<CanvasItem *, TQPtrList<CanvasChunk> > m_chunksByItem;
+ TQPtrList<CanvasItem> m_items;
- QDict<CanvasClipPath> m_clipPaths;
+ TQDict<CanvasClipPath> m_clipPaths;
unsigned int m_viewportWidth, m_viewportHeight;
int m_width, m_height;
int m_chunkSizeHor, m_chunkSizeVer;
- QPaintDevice *m_drawWindow;
- QPaintDevice *m_directWindow;
+ TQPaintDevice *m_drawWindow;
+ TQPaintDevice *m_directWindow;
float m_zoom;
- QPoint m_pan;
+ TQPoint m_pan;
GC m_gc;
@@ -178,7 +178,7 @@ protected:
unsigned char *m_buffer;
unsigned int m_nrChannels;
- QColor m_backgroundColor;
+ TQColor m_backgroundColor;
bool m_immediateUpdate;
};
diff --git a/ksvg/core/KSVGHelper.h b/ksvg/core/KSVGHelper.h
index e310889f..27c8b88f 100644
--- a/ksvg/core/KSVGHelper.h
+++ b/ksvg/core/KSVGHelper.h
@@ -23,8 +23,8 @@
#ifdef __cplusplus
-#include <qcolor.h>
-#include <qvaluevector.h>
+#include <tqcolor.h>
+#include <tqvaluevector.h>
#include "Affine.h"
#include "Point.h"
#include "SVGMatrixImpl.h"
@@ -62,21 +62,21 @@ public:
KSVGHelper::matrixToAffine(matrix, affine.data());
}
- static QString toColorString(QColor color)
+ static TQString toColorString(TQColor color)
{
int r = color.red();
int g = color.green();
int b = color.blue();
- return "rgb(" + QString::number(r) + "," + QString::number(g) + "," + QString::number(b) + ")";
+ return "rgb(" + TQString::number(r) + "," + TQString::number(g) + "," + TQString::number(b) + ")";
}
- static unsigned int toArtColor(const QColor &color)
+ static unsigned int toArtColor(const TQColor &color)
{
return (qRed(color.rgb()) << 24) | (qGreen(color.rgb()) << 16) | ( qBlue(color.rgb()) << 8) | (qAlpha(color.rgb()));
}
- static unsigned int toArtColor(const QColor &color, short opacity)
+ static unsigned int toArtColor(const TQColor &color, short opacity)
{
return (qRed(color.rgb()) << 24) | (qGreen(color.rgb()) << 16) | ( qBlue(color.rgb()) << 8) | (opacity);
}
@@ -113,7 +113,7 @@ public:
void clear() { m_points.clear(); }
private:
- QValueVector<KSVGPoint> m_points;
+ TQValueVector<KSVGPoint> m_points;
};
class KSVGRectangle : public KSVGPolygon
diff --git a/ksvg/core/KSVGLoader.cpp b/ksvg/core/KSVGLoader.cpp
index 7f7591d7..63c3efc8 100644
--- a/ksvg/core/KSVGLoader.cpp
+++ b/ksvg/core/KSVGLoader.cpp
@@ -18,10 +18,10 @@
Boston, MA 02110-1301, USA.
*/
-#include <qxml.h>
-#include <qfile.h>
-#include <qimage.h>
-#include <qbuffer.h>
+#include <tqxml.h>
+#include <tqfile.h>
+#include <tqimage.h>
+#include <tqbuffer.h>
#include <kurl.h>
#include <kdebug.h>
@@ -46,21 +46,21 @@ KSVGLoader::~KSVGLoader()
{
}
-QString KSVGLoader::loadXML(::KURL url)
+TQString KSVGLoader::loadXML(::KURL url)
{
- QString tmpFile;
+ TQString tmpFile;
if(KIO::NetAccess::download(url, tmpFile, 0))
{
- QIODevice *dev = KFilterDev::deviceForFile(tmpFile, "application/x-gzip", true);
- QByteArray contents;
+ TQIODevice *dev = KFilterDev::deviceForFile(tmpFile, "application/x-gzip", true);
+ TQByteArray contents;
if(dev->open(IO_ReadOnly))
contents = dev->readAll();
delete dev;
KIO::NetAccess::removeTempFile(tmpFile);
- return QString(contents);
+ return TQString(contents);
}
- return QString::null;
+ return TQString::null;
}
void KSVGLoader::getSVGContent(::KURL url)
@@ -72,8 +72,8 @@ void KSVGLoader::getSVGContent(::KURL url)
m_job->setAutoErrorHandlingEnabled(true);
- connect(m_job, SIGNAL(data(KIO::Job *, const QByteArray &)), this, SLOT(slotData(KIO::Job *, const QByteArray &)));
- connect(m_job, SIGNAL(result(KIO::Job *)), this, SLOT(slotResult(KIO::Job *)));
+ connect(m_job, TQT_SIGNAL(data(KIO::Job *, const TQByteArray &)), this, TQT_SLOT(slotData(KIO::Job *, const TQByteArray &)));
+ connect(m_job, TQT_SIGNAL(result(KIO::Job *)), this, TQT_SLOT(slotResult(KIO::Job *)));
}
}
@@ -86,31 +86,31 @@ void KSVGLoader::newImageJob(SVGImageElementImpl *image, ::KURL baseURL)
}
ImageStreamMap *map = new ImageStreamMap();
- map->data = new QByteArray();
+ map->data = new TQByteArray();
map->imageElement = image;
KIO::TransferJob *imageJob = KIO::get(::KURL(baseURL, map->imageElement->fileName()), false, false);
- connect(imageJob, SIGNAL(data(KIO::Job *, const QByteArray &)), this, SLOT(slotData(KIO::Job *, const QByteArray &)));
- connect(imageJob, SIGNAL(result(KIO::Job *)), this, SLOT(slotResult(KIO::Job *)));
+ connect(imageJob, TQT_SIGNAL(data(KIO::Job *, const TQByteArray &)), this, TQT_SLOT(slotData(KIO::Job *, const TQByteArray &)));
+ connect(imageJob, TQT_SIGNAL(result(KIO::Job *)), this, TQT_SLOT(slotResult(KIO::Job *)));
m_imageJobs.insert(imageJob, map);
}
-void KSVGLoader::slotData(KIO::Job *job, const QByteArray &data)
+void KSVGLoader::slotData(KIO::Job *job, const TQByteArray &data)
{
if(job == m_job)
{
- QDataStream dataStream(m_data, IO_WriteOnly | IO_Append);
+ TQDataStream dataStream(m_data, IO_WriteOnly | IO_Append);
dataStream.writeRawBytes(data.data(), data.size());
}
else
{
- QMap<KIO::TransferJob *, ImageStreamMap *>::Iterator it;
+ TQMap<KIO::TransferJob *, ImageStreamMap *>::Iterator it;
for(it = m_imageJobs.begin(); it != m_imageJobs.end(); ++it)
{
if(it.key() == job)
{
- QDataStream dataStream(*(it.data())->data, IO_WriteOnly | IO_Append);
+ TQDataStream dataStream(*(it.data())->data, IO_WriteOnly | IO_Append);
dataStream.writeRawBytes(data.data(), data.size());
break;
}
@@ -124,18 +124,18 @@ void KSVGLoader::slotResult(KIO::Job *job)
{
if(m_job->error() == 0)
{
- QString check = static_cast<KIO::TransferJob *>(job)->url().prettyURL();
+ TQString check = static_cast<KIO::TransferJob *>(job)->url().prettyURL();
if(check.contains(".svgz") || check.contains(".svg.gz"))
{
// decode the gzipped svg and emit it
- QIODevice *dev = KFilterDev::device(new QBuffer(m_data), "application/x-gzip");
+ TQIODevice *dev = KFilterDev::device(new TQBuffer(m_data), "application/x-gzip");
dev->open(IO_ReadOnly);
emit gotResult(dev);
}
else
{
m_job = 0;
- emit gotResult(new QBuffer(m_data));
+ emit gotResult(new TQBuffer(m_data));
m_data.resize(0);
}
}
@@ -151,29 +151,29 @@ void KSVGLoader::slotResult(KIO::Job *job)
}
else
{
- QMap<KIO::TransferJob *, ImageStreamMap *>::Iterator it;
+ TQMap<KIO::TransferJob *, ImageStreamMap *>::Iterator it;
for(it = m_imageJobs.begin(); it != m_imageJobs.end(); ++it)
{
if(it.key() == job)
{
ImageStreamMap *streamMap = it.data();
- QBuffer buffer(*(streamMap->data));
+ TQBuffer buffer(*(streamMap->data));
if(buffer.open(IO_ReadOnly))
{
- const char *imageFormat = QImageIO::imageFormat(&buffer);
+ const char *imageFormat = TQImageIO::imageFormat(&buffer);
if(imageFormat != 0)
{
- QImageIO imageIO(&buffer, imageFormat);
+ TQImageIO imageIO(&buffer, imageFormat);
// Gamma correction
imageIO.setGamma(1/0.45454);
if(imageIO.read())
{
- QImage *image = new QImage(imageIO.image());
+ TQImage *image = new TQImage(imageIO.image());
image->detach();
(streamMap->imageElement)->setImage(image);
}
@@ -193,16 +193,16 @@ void KSVGLoader::slotResult(KIO::Job *job)
}
}
-QString KSVGLoader::getUrl(::KURL url, bool local)
+TQString KSVGLoader::getUrl(::KURL url, bool local)
{
// Security issue: Only retrieve http and https
if(local || (!url.prettyURL().isEmpty()) && ((url.protocol() == "http") || (url.protocol() == "https")))
return loadXML(url);
- return QString::null;
+ return TQString::null;
}
-void KSVGLoader::postUrl(::KURL url, const QByteArray &data, const QString &mimeType, KJS::ExecState *exec, KJS::Object &callBackFunction, KJS::Object &status)
+void KSVGLoader::postUrl(::KURL url, const TQByteArray &data, const TQString &mimeType, KJS::ExecState *exec, KJS::Object &callBackFunction, KJS::Object &status)
{
KIO::TransferJob *job = KIO::http_post(url, data, false);
job->addMetaData("content-type", mimeType);
@@ -212,13 +212,13 @@ void KSVGLoader::postUrl(::KURL url, const QByteArray &data, const QString &mime
m_postUrlData.status = &status;
m_postUrlData.callBackFunction = &callBackFunction;
- connect(job, SIGNAL(result(KIO::Job *)), SLOT(slotResult(KIO::Job *)));
+ connect(job, TQT_SIGNAL(result(KIO::Job *)), TQT_SLOT(slotResult(KIO::Job *)));
}
class CharacterDataSearcher : public QXmlDefaultHandler
{
public:
- CharacterDataSearcher(const QString &id) : m_id(id) { }
+ CharacterDataSearcher(const TQString &id) : m_id(id) { }
virtual bool startDocument()
{
@@ -226,7 +226,7 @@ public:
return true;
}
- virtual bool startElement(const QString &, const QString &, const QString &qName, const QXmlAttributes &atts)
+ virtual bool startElement(const TQString &, const TQString &, const TQString &qName, const TQXmlAttributes &atts)
{
kdDebug(26001) << "CharacterDataSearcher::startElement, qName " << qName << endl;
@@ -240,7 +240,7 @@ public:
return true;
}
- virtual bool endElement(const QString &, const QString &, const QString &qName)
+ virtual bool endElement(const TQString &, const TQString &, const TQString &qName)
{
if(m_tagFound == qName && m_foundCount > 0)
{
@@ -252,7 +252,7 @@ public:
return true;
}
- virtual bool characters(const QString &ch)
+ virtual bool characters(const TQString &ch)
{
kdDebug(26001) << "CharacterDataSearcher::characters, read " << ch.latin1() << endl;
@@ -262,24 +262,24 @@ public:
return true;
}
- QString result() { return m_result; }
+ TQString result() { return m_result; }
private:
- QString m_id, m_result, m_tagFound;
+ TQString m_id, m_result, m_tagFound;
int m_foundCount;
};
-QString KSVGLoader::getCharacterData(::KURL url, const QString &id)
+TQString KSVGLoader::getCharacterData(::KURL url, const TQString &id)
{
- QXmlSimpleReader reader;
+ TQXmlSimpleReader reader;
CharacterDataSearcher searcher(id);
reader.setContentHandler(&searcher);
reader.setErrorHandler(&searcher);
- QString s = loadXML(url);
+ TQString s = loadXML(url);
- QXmlInputSource source;
+ TQXmlInputSource source;
source.setData(s);
reader.parse(&source);
@@ -292,7 +292,7 @@ QString KSVGLoader::getCharacterData(::KURL url, const QString &id)
class SVGFragmentSearcher : public QXmlDefaultHandler
{
public:
- SVGFragmentSearcher(SVGDocumentImpl *doc, const QString &id, ::KURL url) : m_id(id), m_url(url), m_doc(doc) { }
+ SVGFragmentSearcher(SVGDocumentImpl *doc, const TQString &id, ::KURL url) : m_id(id), m_url(url), m_doc(doc) { }
virtual bool startDocument()
{
@@ -302,7 +302,7 @@ public:
return true;
}
- virtual bool startElement(const QString &namespaceURI, const QString &, const QString &qName, const QXmlAttributes &attrs)
+ virtual bool startElement(const TQString &namespaceURI, const TQString &, const TQString &qName, const TQXmlAttributes &attrs)
{
kdDebug(26001) << "SVGFragmentSearcher::startElement, namespaceURI " << namespaceURI << ", qName " << qName << endl;
bool parse = m_result;
@@ -324,12 +324,12 @@ public:
else
m_result = newElement;
- QXmlAttributes newAttrs;
+ TQXmlAttributes newAttrs;
for(int i = 0; i < attrs.count(); i++)
{
- QString name = attrs.localName(i);
- QString value = attrs.value(i);
+ TQString name = attrs.localName(i);
+ TQString value = attrs.value(i);
if(name == "id")
{
@@ -346,7 +346,7 @@ public:
value.remove(0, 1);
// Convert the id to its mangled version.
- QString id = "@fragment@" + m_url.prettyURL() + "@" + value;
+ TQString id = "@fragment@" + m_url.prettyURL() + "@" + value;
if(m_idMap.contains(id))
{
@@ -373,7 +373,7 @@ public:
return true;
}
- virtual bool endElement(const QString &, const QString &, const QString &)
+ virtual bool endElement(const TQString &, const TQString &, const TQString &)
{
if(m_result)
{
@@ -388,7 +388,7 @@ public:
return true;
}
- virtual bool characters(const QString &ch)
+ virtual bool characters(const TQString &ch)
{
kdDebug(26001) << "SVGFragmentSearcher::characters, read " << ch.latin1() << endl;
@@ -397,7 +397,7 @@ public:
SVGElementImpl *element = m_result->ownerDoc()->getElementFromHandle(m_currentNode->handle());
if(element)
{
- QString t = ch;
+ TQString t = ch;
SVGLangSpaceImpl *langSpace = dynamic_cast<SVGLangSpaceImpl *>(element);
if(langSpace)
@@ -417,28 +417,28 @@ public:
SVGElementImpl *result() { return m_result; }
private:
- QString m_id;
+ TQString m_id;
::KURL m_url;
SVGDocumentImpl *m_doc;
SVGElementImpl *m_result;
DOM::Node *m_currentNode, m_parentNode;
- QMap<QString, SVGElementImpl *> m_idMap;
+ TQMap<TQString, SVGElementImpl *> m_idMap;
};
-SVGElementImpl *KSVGLoader::getSVGFragment(::KURL url, SVGDocumentImpl *doc, const QString &id)
+SVGElementImpl *KSVGLoader::getSVGFragment(::KURL url, SVGDocumentImpl *doc, const TQString &id)
{
- QXmlSimpleReader reader;
+ TQXmlSimpleReader reader;
kdDebug(26001) << "getSVGFragment: " << url.prettyURL() << "#" << id << endl;
SVGFragmentSearcher searcher(doc, id, url);
reader.setContentHandler(&searcher);
reader.setErrorHandler(&searcher);
- QString s = loadXML(url);
+ TQString s = loadXML(url);
- QXmlInputSource source;
+ TQXmlInputSource source;
source.setData(s);
reader.parse(&source);
diff --git a/ksvg/core/KSVGLoader.h b/ksvg/core/KSVGLoader.h
index d0418411..443d0fb7 100644
--- a/ksvg/core/KSVGLoader.h
+++ b/ksvg/core/KSVGLoader.h
@@ -21,7 +21,7 @@
#ifndef KSVGLoader_H
#define KSVGLoader_H
-#include <qobject.h>
+#include <tqobject.h>
class KURL;
@@ -62,27 +62,27 @@ public:
void getSVGContent(::KURL url);
void newImageJob(SVGImageElementImpl *impl, ::KURL url);
- static QString getUrl(::KURL url, bool local = false);
- void postUrl(::KURL url, const QByteArray &data, const QString &mimeType, KJS::ExecState *exec, KJS::Object &callBackFunction, KJS::Object &status);
- static QString getCharacterData(::KURL url, const QString &id);
- static SVGElementImpl *getSVGFragment(::KURL, SVGDocumentImpl *doc, const QString &id);
+ static TQString getUrl(::KURL url, bool local = false);
+ void postUrl(::KURL url, const TQByteArray &data, const TQString &mimeType, KJS::ExecState *exec, KJS::Object &callBackFunction, KJS::Object &status);
+ static TQString getCharacterData(::KURL url, const TQString &id);
+ static SVGElementImpl *getSVGFragment(::KURL, SVGDocumentImpl *doc, const TQString &id);
signals:
- void gotResult(QIODevice *);
+ void gotResult(TQIODevice *);
void imageReady(SVGImageElementImpl *);
private slots:
- void slotData(KIO::Job *, const QByteArray &);
+ void slotData(KIO::Job *, const TQByteArray &);
void slotResult(KIO::Job *);
private:
- static QString loadXML(::KURL);
+ static TQString loadXML(::KURL);
PostUrlData m_postUrlData;
- QByteArray m_data;
+ TQByteArray m_data;
KIO::TransferJob *m_job;
- QMap<KIO::TransferJob *, ImageStreamMap *> m_imageJobs;
+ TQMap<KIO::TransferJob *, ImageStreamMap *> m_imageJobs;
};
}
diff --git a/ksvg/core/KSVGReader.cc b/ksvg/core/KSVGReader.cc
index dd73e420..e479b9a1 100644
--- a/ksvg/core/KSVGReader.cc
+++ b/ksvg/core/KSVGReader.cc
@@ -21,7 +21,7 @@
#include <dom/dom_exception.h>
#include <kdebug.h>
#include <klocale.h>
-#include <qmap.h>
+#include <tqmap.h>
#include <ksimpleconfig.h>
#include <KSVGCanvas.h>
#include "KSVGReader.moc"
@@ -54,18 +54,18 @@ public:
void addSVGElement(SVGSVGElementImpl *one, DOM::NodeImpl *two) { m_svgMap.insert(two, one); }
SVGSVGElementImpl *nextSVGElement(SVGElementImpl *elem);
SVGSVGElementImpl *nextSVGElement(DOM::Node elem);
- void setFinished(bool error, const QString &errorDesc = "") { m_reader->setFinished(error, errorDesc); }
+ void setFinished(bool error, const TQString &errorDesc = "") { m_reader->setFinished(error, errorDesc); }
// Error handling
- void setErrorDescription(const QString &err) { m_errorDesc = err; }
- QString errorDescription() { return m_errorDesc; }
+ void setErrorDescription(const TQString &err) { m_errorDesc = err; }
+ TQString errorDescription() { return m_errorDesc; }
bool hasError() const { return !m_errorDesc.isEmpty(); }
bool getURLMode() const { return m_getURLMode; }
void setGetURLMode(bool mode) { m_getURLMode = mode; }
- QString SVGFragmentId() const { return m_SVGFragmentId; }
- void setSVGFragmentId(const QString &SVGFragmentId) { m_SVGFragmentId = SVGFragmentId; }
+ TQString SVGFragmentId() const { return m_SVGFragmentId; }
+ void setSVGFragmentId(const TQString &SVGFragmentId) { m_SVGFragmentId = SVGFragmentId; }
protected:
Helper(KSVGReader *reader);
@@ -76,12 +76,12 @@ private:
Helper &operator=(const Helper &rhs);
static Helper *m_instance;
- QMap<DOM::NodeImpl *, SVGSVGElementImpl *> m_svgMap;
+ TQMap<DOM::NodeImpl *, SVGSVGElementImpl *> m_svgMap;
KSVGReader *m_reader;
bool m_bFit;
bool m_getURLMode;
- QString m_errorDesc;
- QString m_SVGFragmentId;
+ TQString m_errorDesc;
+ TQString m_SVGFragmentId;
};
class InputHandler : public QXmlDefaultHandler
@@ -89,17 +89,17 @@ class InputHandler : public QXmlDefaultHandler
public:
virtual bool startDocument();
virtual bool endDocument();
- virtual bool startElement(const QString &namespaceURI,
- const QString &localName,
- const QString &qName,
- const QXmlAttributes &atts);
- virtual bool endElement(const QString &namespaceURI,
- const QString &localName,
- const QString &qName);
- virtual bool characters(const QString &ch);
- virtual bool warning(const QXmlParseException &e);
- virtual bool error(const QXmlParseException &e);
- virtual bool fatalError(const QXmlParseException &e);
+ virtual bool startElement(const TQString &namespaceURI,
+ const TQString &localName,
+ const TQString &qName,
+ const TQXmlAttributes &atts);
+ virtual bool endElement(const TQString &namespaceURI,
+ const TQString &localName,
+ const TQString &qName);
+ virtual bool characters(const TQString &ch);
+ virtual bool warning(const TQXmlParseException &e);
+ virtual bool error(const TQXmlParseException &e);
+ virtual bool fatalError(const TQXmlParseException &e);
private:
DOM::Node *m_rootNode;
@@ -186,14 +186,14 @@ bool InputHandler::endDocument()
return true;
}
-bool InputHandler::characters(const QString &ch)
+bool InputHandler::characters(const TQString &ch)
{
kdDebug(26001) << "InputHandler::characters, read " << ch << endl;
if(ch.simplifyWhiteSpace().isEmpty())
return true;
- QString t = ch;
+ TQString t = ch;
SVGSVGElementImpl *root = Helper::self()->nextSVGElement(*m_currentNode);
if(root)
@@ -214,7 +214,7 @@ bool InputHandler::characters(const QString &ch)
return true;
}
-bool InputHandler::startElement(const QString &namespaceURI, const QString &, const QString &qName, const QXmlAttributes &attrs)
+bool InputHandler::startElement(const TQString &namespaceURI, const TQString &, const TQString &qName, const TQXmlAttributes &attrs)
{
kdDebug(26001) << "InputHandler::startElement, namespaceURI " << namespaceURI << " qName " << qName << endl;
@@ -245,14 +245,14 @@ bool InputHandler::startElement(const QString &namespaceURI, const QString &, co
SVGLengthImpl *height = SVGSVGElementImpl::createSVGLength();
width->setValueAsString(svg->getAttribute("width").string());
height->setValueAsString(svg->getAttribute("height").string());
- QString viewbox = QString("0 0 %1 %2").arg(width->value()).arg(height->value());
+ TQString viewbox = TQString("0 0 %1 %2").arg(width->value()).arg(height->value());
//kdDebug(26001) << "VIEWBOX : " << viewbox.latin1() << endl;
svg->setAttribute("viewBox", viewbox);
width->deref();
height->deref();
}
- svg->setAttribute("width", QString::number(Helper::self()->canvas()->width()));
- svg->setAttribute("height", QString::number(Helper::self()->canvas()->height()));
+ svg->setAttribute("width", TQString::number(Helper::self()->canvas()->width()));
+ svg->setAttribute("height", TQString::number(Helper::self()->canvas()->height()));
}
if(!Helper::self()->SVGFragmentId().isEmpty())
@@ -341,7 +341,7 @@ bool InputHandler::startElement(const QString &namespaceURI, const QString &, co
return !Helper::self()->hasError();
}
-bool InputHandler::endElement(const QString &, const QString &, const QString &qName)
+bool InputHandler::endElement(const TQString &, const TQString &, const TQString &qName)
{
kdDebug(26001) << "InputHandler::endElement, qName " << qName << endl;
@@ -364,12 +364,12 @@ bool InputHandler::endElement(const QString &, const QString &, const QString &q
Helper::self()->canvas()->blit();
- QValueList<SVGUseElementImpl *> forwardReferencingUseElements = Helper::self()->doc()->forwardReferencingUseElements();
+ TQValueList<SVGUseElementImpl *> forwardReferencingUseElements = Helper::self()->doc()->forwardReferencingUseElements();
if(!forwardReferencingUseElements.isEmpty())
{
// Create the elements again now that we have parsed the whole document.
- QValueList<SVGUseElementImpl *>::iterator it;
+ TQValueList<SVGUseElementImpl *>::iterator it;
Helper::self()->canvas()->setImmediateUpdate(false);
@@ -407,29 +407,29 @@ bool InputHandler::endElement(const QString &, const QString &, const QString &q
return true;
}
-bool InputHandler::warning(const QXmlParseException &e)
+bool InputHandler::warning(const TQXmlParseException &e)
{
kdDebug(26001) << "[" << e.lineNumber() << ":" << e.columnNumber() << "]: WARNING: " << e.message() << endl;
return true;
}
-bool InputHandler::error(const QXmlParseException &e)
+bool InputHandler::error(const TQXmlParseException &e)
{
kdDebug(26001) << "[" << e.lineNumber() << ":" << e.columnNumber() << "]: ERROR: " << e.message() << endl;
return true;
}
-bool InputHandler::fatalError(const QXmlParseException &e)
+bool InputHandler::fatalError(const TQXmlParseException &e)
{
- QString error;
+ TQString error;
if(Helper::self()->hasError())
{
error = Helper::self()->errorDescription();
- Helper::self()->setErrorDescription(QString::null);
+ Helper::self()->setErrorDescription(TQString::null);
}
else
- error = QString("[%1:%2]: FATAL ERROR: %3").arg(e.lineNumber()).arg(e.columnNumber()).arg(e.message());
+ error = TQString("[%1:%2]: FATAL ERROR: %3").arg(e.lineNumber()).arg(e.columnNumber()).arg(e.message());
kdDebug(26001) << "InputHandler::fatalError, " << error << endl;
@@ -439,18 +439,18 @@ bool InputHandler::fatalError(const QXmlParseException &e)
struct KSVGReader::Private
{
- QXmlSimpleReader *reader;
+ TQXmlSimpleReader *reader;
InputHandler *inputHandler;
SVGDocumentImpl *doc;
KSVGCanvas *canvas;
};
-KSVGReader::KSVGReader(SVGDocumentImpl *doc, KSVGCanvas *canvas, ParsingArgs args) : QObject(), d(new Private)
+KSVGReader::KSVGReader(SVGDocumentImpl *doc, KSVGCanvas *canvas, ParsingArgs args) : TQObject(), d(new Private)
{
d->doc = doc;
d->canvas = canvas;
- d->reader = new QXmlSimpleReader();
+ d->reader = new TQXmlSimpleReader();
d->inputHandler = new InputHandler();
Helper::self(this);
@@ -471,17 +471,17 @@ KSVGReader::~KSVGReader()
delete d;
}
-void KSVGReader::parse(QXmlInputSource *source)
+void KSVGReader::parse(TQXmlInputSource *source)
{
d->reader->parse(source);
}
-void KSVGReader::finishParsing(bool, const QString &errorDesc)
+void KSVGReader::finishParsing(bool, const TQString &errorDesc)
{
Helper::self()->setErrorDescription(errorDesc);
}
-void KSVGReader::setFinished(bool error, const QString &errorDesc)
+void KSVGReader::setFinished(bool error, const TQString &errorDesc)
{
kdDebug(26001) << "KSVGReader::setFinished" << endl;
emit finished(error, errorDesc);
diff --git a/ksvg/core/KSVGReader.h b/ksvg/core/KSVGReader.h
index 722720e1..49259d7d 100644
--- a/ksvg/core/KSVGReader.h
+++ b/ksvg/core/KSVGReader.h
@@ -21,8 +21,8 @@
#ifndef KSVGReader_H
#define KSVGReader_H
-#include <qxml.h>
-#include <qobject.h>
+#include <tqxml.h>
+#include <tqobject.h>
namespace KSVG
{
@@ -37,17 +37,17 @@ public:
bool fit;
bool getURLMode;
- QString SVGFragmentId;
+ TQString SVGFragmentId;
};
KSVGReader(SVGDocumentImpl *doc, KSVGCanvas *canvas, ParsingArgs args);
virtual ~KSVGReader();
- void parse(QXmlInputSource *source);
- void finishParsing(bool, const QString &);
+ void parse(TQXmlInputSource *source);
+ void finishParsing(bool, const TQString &);
signals:
- void finished(bool, const QString &);
+ void finished(bool, const TQString &);
protected:
friend class Helper;
@@ -55,7 +55,7 @@ protected:
SVGDocumentImpl *doc();
KSVGCanvas *canvas();
- void setFinished(bool error, const QString &errorDesc = 0);
+ void setFinished(bool error, const TQString &errorDesc = 0);
private:
struct Private;
diff --git a/ksvg/core/KSVGTextChunk.cpp b/ksvg/core/KSVGTextChunk.cpp
index b8eddcad..4d8111e8 100644
--- a/ksvg/core/KSVGTextChunk.cpp
+++ b/ksvg/core/KSVGTextChunk.cpp
@@ -38,7 +38,7 @@ unsigned int KSVGTextChunk::count() const
return m_text.count();
}
-QString KSVGTextChunk::getText(unsigned int index) const
+TQString KSVGTextChunk::getText(unsigned int index) const
{
return m_text[index];
}
@@ -60,7 +60,7 @@ void KSVGTextChunk::clear()
m_textElements.clear();
}
-void KSVGTextChunk::addText(const QString &text, SVGTextContentElementImpl *textElement)
+void KSVGTextChunk::addText(const TQString &text, SVGTextContentElementImpl *textElement)
{
m_text.append(text);
m_textElements.append(textElement);
diff --git a/ksvg/core/KSVGTextChunk.h b/ksvg/core/KSVGTextChunk.h
index d684087a..21efa055 100644
--- a/ksvg/core/KSVGTextChunk.h
+++ b/ksvg/core/KSVGTextChunk.h
@@ -21,7 +21,7 @@
#ifndef KSVGTEXTCHUNK_H
#define KSVGTEXTCHUNK_H
-#include <qstringlist.h>
+#include <tqstringlist.h>
namespace KSVG
{
@@ -35,16 +35,16 @@ public:
~KSVGTextChunk();
unsigned int count() const;
- QString getText(unsigned int index) const;
+ TQString getText(unsigned int index) const;
SVGTextPositioningElementImpl *getTextElement(unsigned int index);
SVGTextContentElementImpl *getTextContentElement(unsigned int index);
void clear();
- void addText(const QString &text, SVGTextContentElementImpl *textElement);
+ void addText(const TQString &text, SVGTextContentElementImpl *textElement);
private:
- QStringList m_text;
- QPtrList<SVGTextContentElementImpl> m_textElements;
+ TQStringList m_text;
+ TQPtrList<SVGTextContentElementImpl> m_textElements;
};
}
diff --git a/ksvg/ecma/ksvg_ecma.cpp b/ksvg/ecma/ksvg_ecma.cpp
index a2aed6ce..a42d69ad 100644
--- a/ksvg/ecma/ksvg_ecma.cpp
+++ b/ksvg/ecma/ksvg_ecma.cpp
@@ -20,7 +20,7 @@
#include <kdebug.h>
-#include <qvariant.h>
+#include <tqvariant.h>
#include <dom/dom2_events.h>
@@ -71,7 +71,7 @@ KSVGEcma::KSVGEcma(SVGDocumentImpl *doc) : m_doc(doc)
KSVGEcma::~KSVGEcma()
{
// We are 0 soon so event listeners may NOT call us
- QPtrListIterator<KSVGEcmaEventListener> it(m_ecmaEventListeners);
+ TQPtrListIterator<KSVGEcmaEventListener> it(m_ecmaEventListeners);
for(; it.current(); ++it)
it.current()->forbidRemove();
@@ -129,7 +129,7 @@ ExecState *KSVGEcma::globalExec()
SVGEventListener *KSVGEcma::createEventListener(DOM::DOMString type)
{
- QPtrListIterator<KSVGEcmaEventListener> it(m_ecmaEventListeners);
+ TQPtrListIterator<KSVGEcmaEventListener> it(m_ecmaEventListeners);
for(; it.current(); ++it)
{
@@ -159,11 +159,11 @@ SVGEventListener *KSVGEcma::createEventListener(DOM::DOMString type)
return event;
}
-QString KSVGEcma::valueOfEventListener(SVGEventListener *listener) const
+TQString KSVGEcma::valueOfEventListener(SVGEventListener *listener) const
{
KSVGEcmaEventListener *event = static_cast<KSVGEcmaEventListener *>(listener);
if(!event)
- return QString::null;
+ return TQString::null;
return event->type();
}
@@ -197,7 +197,7 @@ Value KSVGEcma::getUrl(ExecState *exec, ::KURL url)
Object *status = new Object(new AsyncStatus());
// FIXME: Security issue, allows local testing of getURL(), REMOVE BEFORE RELEASE! (Niko)
- QString svgDocument = KSVGLoader::getUrl(url, true);
+ TQString svgDocument = KSVGLoader::getUrl(url, true);
if(svgDocument.length() > 0)
{
status->put(exec, Identifier("success"), Boolean(true));
@@ -212,14 +212,14 @@ Value KSVGEcma::getUrl(ExecState *exec, ::KURL url)
return Value(*status);
}
-void KSVGEcma::postUrl(ExecState *exec, ::KURL url, const QString &data, const QString &mimeType, const QString &contentEncoding, Object &callBackFunction)
+void KSVGEcma::postUrl(ExecState *exec, ::KURL url, const TQString &data, const TQString &mimeType, const TQString &contentEncoding, Object &callBackFunction)
{
Object *status = new Object(new AsyncStatus());
status->put(exec, Identifier("content"), String(""));
status->put(exec, Identifier("success"), Boolean(false));
- QByteArray byteArray;
- QDataStream ds(byteArray, IO_WriteOnly);
+ TQByteArray byteArray;
+ TQDataStream ds(byteArray, IO_WriteOnly);
ds << data;
// Support gzip compression
@@ -310,20 +310,20 @@ DOM::Node KSVG::toNode(const Value &val)
return DOM::Node();
}
-QVariant KSVG::valueToVariant(ExecState *exec, const Value &val)
+TQVariant KSVG::valueToVariant(ExecState *exec, const Value &val)
{
- QVariant res;
+ TQVariant res;
switch(val.type())
{
case BooleanType:
- res = QVariant(val.toBoolean(exec), 0);
+ res = TQVariant(val.toBoolean(exec), 0);
break;
case NumberType:
- res = QVariant(val.toNumber(exec));
+ res = TQVariant(val.toNumber(exec));
break;
case StringType:
- res = QVariant(val.toString(exec).qstring());
+ res = TQVariant(val.toString(exec).qstring());
break;
default:
// everything else will be 'invalid'
diff --git a/ksvg/ecma/ksvg_ecma.h b/ksvg/ecma/ksvg_ecma.h
index 7c236454..ab58f67a 100644
--- a/ksvg/ecma/ksvg_ecma.h
+++ b/ksvg/ecma/ksvg_ecma.h
@@ -21,7 +21,7 @@
#ifndef KSVGEcma_H
#define KSVGEcma_H
-#include <qptrlist.h>
+#include <tqptrlist.h>
#include "ksvg_bridge.h"
@@ -49,7 +49,7 @@ namespace KSVG
class SVGDOMNodeBridge;
}
-class QVariant;
+class TQVariant;
class KSVGEcmaEventListener;
class KSVGScriptInterpreter;
@@ -63,7 +63,7 @@ namespace KSVG
KJS::Value getDOMEvent(KJS::ExecState *, KSVG::SVGEventImpl *);
KJS::Value getString(DOM::DOMString);
- QVariant valueToVariant(KJS::ExecState *, const KJS::Value &);
+ TQVariant valueToVariant(KJS::ExecState *, const KJS::Value &);
DOM::Node toNode(const KJS::Value &);
@@ -88,7 +88,7 @@ public:
KSVGScriptInterpreter *interpreter() { return m_interpreter; }
KSVG::SVGEventListener *createEventListener(DOM::DOMString type);
- QString valueOfEventListener(KSVG::SVGEventListener *listener) const;
+ TQString valueOfEventListener(KSVG::SVGEventListener *listener) const;
void addEventListener(KSVGEcmaEventListener *listener);
void removeEventListener(KSVGEcmaEventListener *listener);
bool hasEventListeners();
@@ -96,7 +96,7 @@ public:
void finishedWithEvent(KSVG::SVGEventImpl *event);
KJS::Value getUrl(KJS::ExecState *exec, ::KURL url);
- void postUrl(KJS::ExecState *exec, ::KURL url, const QString &data, const QString &mimeType, const QString &contentEncoding, KJS::Object &callBackFunction);
+ void postUrl(KJS::ExecState *exec, ::KURL url, const TQString &data, const TQString &mimeType, const TQString &contentEncoding, KJS::Object &callBackFunction);
private:
bool m_init, m_hasListeners;
@@ -105,7 +105,7 @@ private:
KSVG::Window *m_window;
KSVGScriptInterpreter *m_interpreter;
- QPtrList<KSVGEcmaEventListener> m_ecmaEventListeners;
+ TQPtrList<KSVGEcmaEventListener> m_ecmaEventListeners;
};
diff --git a/ksvg/ecma/ksvg_ecmaeventlistener.cpp b/ksvg/ecma/ksvg_ecmaeventlistener.cpp
index 4b59f924..2dd81131 100644
--- a/ksvg/ecma/ksvg_ecmaeventlistener.cpp
+++ b/ksvg/ecma/ksvg_ecmaeventlistener.cpp
@@ -20,7 +20,7 @@
#include <kdebug.h>
-#include <qvariant.h>
+#include <tqvariant.h>
#include "SVGDocumentImpl.h"
#include "SVGSVGElementImpl.h"
@@ -32,7 +32,7 @@
using namespace KSVG;
using namespace KJS;
-KSVGEcmaEventListener::KSVGEcmaEventListener(KJS::Object _listener, QString _type, KSVGEcma *_ecma) : SVGEventListener()
+KSVGEcmaEventListener::KSVGEcmaEventListener(KJS::Object _listener, TQString _type, KSVGEcma *_ecma) : SVGEventListener()
{
m_listener = _listener;
m_remove = true;
@@ -84,8 +84,8 @@ void KSVGEcmaEventListener::handleEvent(SVGEventImpl *evt)
}
else
{
- QVariant ret = valueToVariant(exec, retval);
- if(ret.type() == QVariant::Bool && ret.toBool() == false)
+ TQVariant ret = valueToVariant(exec, retval);
+ if(ret.type() == TQVariant::Bool && ret.toBool() == false)
evt->preventDefault();
}
}
diff --git a/ksvg/ecma/ksvg_ecmaeventlistener.h b/ksvg/ecma/ksvg_ecmaeventlistener.h
index 16ebe3bc..ee80c212 100644
--- a/ksvg/ecma/ksvg_ecmaeventlistener.h
+++ b/ksvg/ecma/ksvg_ecmaeventlistener.h
@@ -31,19 +31,19 @@ namespace KJS
class KSVGEcmaEventListener : public KSVG::SVGEventListener
{
public:
- KSVGEcmaEventListener(KJS::Object _listener, QString _type, KSVGEcma *_ecma);
+ KSVGEcmaEventListener(KJS::Object _listener, TQString _type, KSVGEcma *_ecma);
virtual ~KSVGEcmaEventListener();
virtual void handleEvent(KSVG::SVGEventImpl *evt);
virtual DOM::DOMString eventListenerType();
- QString type() { return m_type; }
+ TQString type() { return m_type; }
void forbidRemove();
private:
KSVGEcma *m_ecma;
- QString m_type;
+ TQString m_type;
bool m_remove;
KJS::Object m_listener;
diff --git a/ksvg/ecma/ksvg_helper.cpp b/ksvg/ecma/ksvg_helper.cpp
index 597f9a06..24f05101 100644
--- a/ksvg/ecma/ksvg_helper.cpp
+++ b/ksvg/ecma/ksvg_helper.cpp
@@ -37,7 +37,7 @@ KJS::UString::UString(const DOM::DOMString &d)
rep = KJS::UString::Rep::create(dat, len);
}
-KJS::UString::UString(const QString &d)
+KJS::UString::UString(const TQString &d)
{
unsigned int len = d.length();
KJS::UChar *dat = new UChar[len];
@@ -45,24 +45,24 @@ KJS::UString::UString(const QString &d)
rep = KJS::UString::Rep::create(dat, len);
}
-QString KJS::UString::qstring() const
+TQString KJS::UString::qstring() const
{
- return QString(reinterpret_cast<QChar *>(const_cast<KJS::UChar *>(data())), size());
+ return TQString(reinterpret_cast<TQChar *>(const_cast<KJS::UChar *>(data())), size());
}
DOM::DOMString KJS::UString::string() const
{
- return DOM::DOMString(reinterpret_cast<QChar *>(const_cast<KJS::UChar *>(data())), size());
+ return DOM::DOMString(reinterpret_cast<TQChar *>(const_cast<KJS::UChar *>(data())), size());
}
DOM::DOMString KJS::Identifier::string() const
{
- return DOM::DOMString((QChar*) data(), size());
+ return DOM::DOMString((TQChar*) data(), size());
}
-QString KJS::Identifier::qstring() const
+TQString KJS::Identifier::qstring() const
{
- return QString((QChar*) data(), size());
+ return TQString((TQChar*) data(), size());
}
// vim:ts=4:noet
diff --git a/ksvg/ecma/ksvg_scriptinterpreter.h b/ksvg/ecma/ksvg_scriptinterpreter.h
index ed7c6af8..e3f7cc42 100644
--- a/ksvg/ecma/ksvg_scriptinterpreter.h
+++ b/ksvg/ecma/ksvg_scriptinterpreter.h
@@ -21,7 +21,7 @@
#ifndef KSVGScriptInterpreter_H
#define KSVGScriptInterpreter_H
-#include <qptrdict.h>
+#include <tqptrdict.h>
namespace KJS
{
@@ -63,7 +63,7 @@ private:
bool m_attributeGetMode, m_attributeSetMode;
- QPtrDict<KJS::ObjectImp> m_domObjects;
+ TQPtrDict<KJS::ObjectImp> m_domObjects;
};
#endif
diff --git a/ksvg/ecma/ksvg_window.cpp b/ksvg/ecma/ksvg_window.cpp
index d4c04de3..80a4ee14 100644
--- a/ksvg/ecma/ksvg_window.cpp
+++ b/ksvg/ecma/ksvg_window.cpp
@@ -42,7 +42,7 @@
#include <kparts/part.h>
#include <assert.h>
#include <kdebug.h>
-#include <qstylesheet.h>
+#include <tqstylesheet.h>
#include <kmessagebox.h>
#include <klocale.h>
#include <kinputdialog.h>
@@ -303,7 +303,7 @@ Value WindowFunc::call(ExecState *exec, Object &thisObj, const List &args)
Window *window = static_cast<Window *>(thisObj.imp());
Value v = args[0];
UString s = v.toString(exec);
- QString str = s.qstring();
+ TQString str = s.qstring();
switch(id)
{
@@ -342,9 +342,9 @@ Value WindowFunc::call(ExecState *exec, Object &thisObj, const List &args)
case KSVG::Window::_PostURL:
{
KURL url((const_cast<Window *>(window))->doc()->baseUrl(), args[0].toString(exec).qstring());
- QString data = args[1].toString(exec).qstring();
- QString mimeType = args[3].toString(exec).qstring();
- QString contentEncoding = args[4].toString(exec).qstring();
+ TQString data = args[1].toString(exec).qstring();
+ TQString mimeType = args[3].toString(exec).qstring();
+ TQString contentEncoding = args[4].toString(exec).qstring();
Object callBackFunction = Object::dynamicCast(args[2]);
(const_cast<Window *>(window))->doc()->ecmaEngine()->postUrl(exec, url, data, mimeType, contentEncoding, callBackFunction);
@@ -364,7 +364,7 @@ Value WindowFunc::call(ExecState *exec, Object &thisObj, const List &args)
SVGDocumentImpl *curDoc = (const_cast<Window *>(window))->doc();
doc->addToDocumentDict(curDoc->handle(), curDoc);
- QXmlInputSource *svgFragment = new QXmlInputSource();
+ TQXmlInputSource *svgFragment = new TQXmlInputSource();
svgFragment->setData(args[0].toString(exec).qstring());
doc->parseSVG(svgFragment, true);
@@ -384,15 +384,15 @@ Value WindowFunc::call(ExecState *exec, Object &thisObj, const List &args)
// mop: from khtml. do we need that?
// part->xmlDocImpl()->updateRendering();
bool ok;
- QString str2;
+ TQString str2;
if (args.size() >= 2)
str2 = KInputDialog::getText(i18n("Prompt"),
- QStyleSheet::convertFromPlainText(str),
+ TQStyleSheet::convertFromPlainText(str),
args[1].toString(exec).qstring(), &ok);
else
str2 = KInputDialog::getText(i18n("Prompt"),
- QStyleSheet::convertFromPlainText(str),
- QString::null, &ok);
+ TQStyleSheet::convertFromPlainText(str),
+ TQString::null, &ok);
if ( ok )
return String(str2);
else
@@ -455,7 +455,7 @@ ScheduledAction::ScheduledAction(Object _func, List _args, bool _singleShot)
singleShot = _singleShot;
}
-ScheduledAction::ScheduledAction(QString _code, bool _singleShot)
+ScheduledAction::ScheduledAction(TQString _code, bool _singleShot)
{
code = _code;
isFunction = false;
@@ -503,7 +503,7 @@ void WindowQObject::parentDestroyed()
{
killTimers();
- QMapIterator<int, ScheduledAction *> it;
+ TQMapIterator<int, ScheduledAction *> it;
for(it = scheduledActions.begin(); it != scheduledActions.end(); ++it)
{
ScheduledAction *action = *it;
@@ -535,7 +535,7 @@ void WindowQObject::clearTimeout(int timerId, bool delAction)
if(delAction)
{
- QMapIterator<int, ScheduledAction *> it = scheduledActions.find(timerId);
+ TQMapIterator<int, ScheduledAction *> it = scheduledActions.find(timerId);
if(it != scheduledActions.end())
{
ScheduledAction *action = *it;
@@ -545,9 +545,9 @@ void WindowQObject::clearTimeout(int timerId, bool delAction)
}
}
-void WindowQObject::timerEvent(QTimerEvent *e)
+void WindowQObject::timerEvent(TQTimerEvent *e)
{
- QMapIterator<int, ScheduledAction *> it = scheduledActions.find(e->timerId());
+ TQMapIterator<int, ScheduledAction *> it = scheduledActions.find(e->timerId());
if(it != scheduledActions.end())
{
ScheduledAction *action = *it;
diff --git a/ksvg/ecma/ksvg_window.h b/ksvg/ecma/ksvg_window.h
index 28c9699e..db6ac9a3 100644
--- a/ksvg/ecma/ksvg_window.h
+++ b/ksvg/ecma/ksvg_window.h
@@ -20,7 +20,7 @@
#define KSVG_WINDOW_H
#include <kjs/object.h>
-#include <qguardedptr.h>
+#include <tqguardedptr.h>
namespace KSVG {
@@ -58,7 +58,7 @@ public:
*/
static Window *retrieveActive(KJS::ExecState *exec);
- QGuardedPtr<KSVG::SVGDocumentImpl> doc() const { return m_doc; }
+ TQGuardedPtr<KSVG::SVGDocumentImpl> doc() const { return m_doc; }
int installTimeout(const KJS::UString &handler, int t, bool singleShot);
void clearTimeout(int timerId);
@@ -82,23 +82,23 @@ public:
private:
WindowQObject *winq;
- QGuardedPtr<KSVG::SVGDocumentImpl> m_doc;
+ TQGuardedPtr<KSVG::SVGDocumentImpl> m_doc;
};
class ScheduledAction {
public:
ScheduledAction(KJS::Object _func, KJS::List _args, bool _singleShot);
- ScheduledAction(QString _code, bool _singleShot);
+ ScheduledAction(TQString _code, bool _singleShot);
~ScheduledAction();
void execute(Window *window);
KJS::Object func;
KJS::List args;
- QString code;
+ TQString code;
bool isFunction;
bool singleShot;
};
-class WindowQObject : public QObject {
+class WindowQObject : public TQObject {
Q_OBJECT
public:
WindowQObject(Window *w);
@@ -111,11 +111,11 @@ public slots:
protected slots:
void parentDestroyed();
protected:
- void timerEvent(QTimerEvent *e);
+ void timerEvent(TQTimerEvent *e);
private:
Window *parent;
//KHTMLPart *part; // not guarded, may be dangling
- QMap<int, ScheduledAction*> scheduledActions;
+ TQMap<int, ScheduledAction*> scheduledActions;
};
}
diff --git a/ksvg/impl/LRUCache.h b/ksvg/impl/LRUCache.h
index 879f1856..f9045262 100644
--- a/ksvg/impl/LRUCache.h
+++ b/ksvg/impl/LRUCache.h
@@ -21,7 +21,7 @@
#ifndef LRUCACHE_H
#define LRUCACHE_H
-#include <qvaluelist.h>
+#include <tqvaluelist.h>
namespace KSVG
{
@@ -61,7 +61,7 @@ protected:
int m_cost;
};
- typedef QValueList<CacheItem> CacheItemList;
+ typedef TQValueList<CacheItem> CacheItemList;
typename CacheItemList::iterator find(const keyType& key);
void enforceCostConstraint();
diff --git a/ksvg/impl/SVGAngleImpl.cc b/ksvg/impl/SVGAngleImpl.cc
index 6102329d..26e70b1b 100644
--- a/ksvg/impl/SVGAngleImpl.cc
+++ b/ksvg/impl/SVGAngleImpl.cc
@@ -89,7 +89,7 @@ void SVGAngleImpl::setValueAsString(const DOM::DOMString &valueAsString)
{
m_valueAsString = valueAsString;
- QString s = valueAsString.string();
+ TQString s = valueAsString.string();
bool bOK;
m_valueInSpecifiedUnits = s.toFloat(&bOK);
diff --git a/ksvg/impl/SVGAnimateColorElementImpl.cc b/ksvg/impl/SVGAnimateColorElementImpl.cc
index c4cc0ad4..55d71e40 100644
--- a/ksvg/impl/SVGAnimateColorElementImpl.cc
+++ b/ksvg/impl/SVGAnimateColorElementImpl.cc
@@ -75,14 +75,14 @@ void SVGAnimateColorElementImpl::handleTimerEvent()
}
else
{
- QColor fromColor(m_fromColor->rgbColor().color());
- QColor toColor(m_toColor->rgbColor().color());
+ TQColor fromColor(m_fromColor->rgbColor().color());
+ TQColor toColor(m_toColor->rgbColor().color());
int red = (int) rint(((toColor.red() - fromColor.red()) / static_cast<double>(m_steps)) * m_step + fromColor.red());
int green = (int) rint(((toColor.green() - fromColor.green()) / static_cast<double>(m_steps)) * m_step + fromColor.green());
int blue = (int) rint(((toColor.blue() - fromColor.blue()) / static_cast<double>(m_steps)) * m_step + fromColor.blue());
- QString color = "rgb(" + QString::number(red) + "," + QString::number(green) + "," + QString::number(blue) + ")";
+ TQString color = "rgb(" + TQString::number(red) + "," + TQString::number(green) + "," + TQString::number(blue) + ")";
applyAttribute(getAttributeName(), color);
}
diff --git a/ksvg/impl/SVGAnimateColorElementImpl.h b/ksvg/impl/SVGAnimateColorElementImpl.h
index 2832802e..5e6fc24d 100644
--- a/ksvg/impl/SVGAnimateColorElementImpl.h
+++ b/ksvg/impl/SVGAnimateColorElementImpl.h
@@ -25,7 +25,7 @@
#include "SVGAnimationElementImpl.h"
-class QTimer;
+class TQTimer;
namespace KSVG
{
diff --git a/ksvg/impl/SVGAnimateElementImpl.cc b/ksvg/impl/SVGAnimateElementImpl.cc
index ab9bc52c..ccf8565d 100644
--- a/ksvg/impl/SVGAnimateElementImpl.cc
+++ b/ksvg/impl/SVGAnimateElementImpl.cc
@@ -81,7 +81,7 @@ void SVGAnimateElementImpl::handleTimerEvent()
else
{
m_animVal += m_addStep;
- applyAttribute(getAttributeName(), QString::number(m_animVal));
+ applyAttribute(getAttributeName(), TQString::number(m_animVal));
}
if(m_step < m_steps)
@@ -130,7 +130,7 @@ void SVGAnimateElementImpl::handleTimerEvent()
if(m_additive == "replace" && needCombine)
needCombine = false;
- applyAttribute(m_attributeName, QString::number(m_from), needCombine);
+ applyAttribute(m_attributeName, TQString::number(m_from), needCombine);
m_step++;
diff --git a/ksvg/impl/SVGAnimateElementImpl.h b/ksvg/impl/SVGAnimateElementImpl.h
index 855ced6e..7418f7b1 100644
--- a/ksvg/impl/SVGAnimateElementImpl.h
+++ b/ksvg/impl/SVGAnimateElementImpl.h
@@ -24,7 +24,7 @@
#include "ksvg_lookup.h"
#include "SVGAnimationElementImpl.h"
-class QTimer;
+class TQTimer;
namespace KSVG
{
@@ -40,7 +40,7 @@ public:
private:
double m_addStep, m_animVal;
- QTimer *m_timer;
+ TQTimer *m_timer;
int m_steps, m_step;
diff --git a/ksvg/impl/SVGAnimateMotionElementImpl.cc b/ksvg/impl/SVGAnimateMotionElementImpl.cc
index ce756d55..fe816769 100644
--- a/ksvg/impl/SVGAnimateMotionElementImpl.cc
+++ b/ksvg/impl/SVGAnimateMotionElementImpl.cc
@@ -85,9 +85,9 @@ void SVGAnimateMotionElementImpl::handleTimerEvent(bool /*needCombine*/)
if(m_step <= m_pathArray->count() - 1)
{
- QPoint p = m_pathArray->point(m_step - 50);
- applyAttribute("x", QString::number(p.x()));
- applyAttribute("y", QString::number(p.y()));
+ TQPoint p = m_pathArray->point(m_step - 50);
+ applyAttribute("x", TQString::number(p.x()));
+ applyAttribute("y", TQString::number(p.y()));
kdDebug() << " X " << p.x() << " Y " << p.y() << " (" << m_pathArray->count() << "; " << m_step << ")" <<endl;
}
diff --git a/ksvg/impl/SVGAnimateTransformElementImpl.cc b/ksvg/impl/SVGAnimateTransformElementImpl.cc
index d2634bb1..cf3922f8 100644
--- a/ksvg/impl/SVGAnimateTransformElementImpl.cc
+++ b/ksvg/impl/SVGAnimateTransformElementImpl.cc
@@ -18,7 +18,7 @@
Boston, MA 02110-1301, USA.
*/
-#include <qstringlist.h>
+#include <tqstringlist.h>
#include "SVGLengthImpl.h"
#include "SVGHelperImpl.h"
@@ -85,7 +85,7 @@ void SVGAnimateTransformElementImpl::setAttributes()
m_from = list->getFirst()->angle();
- QStringList stringList = QStringList::split(' ', list->getFirst()->toString());
+ TQStringList stringList = TQStringList::split(' ', list->getFirst()->toString());
m_rotateX = stringList[1].toInt();
m_rotateY = stringList[2].mid(0, stringList[2].length() - 1).toInt();
@@ -127,13 +127,13 @@ void SVGAnimateTransformElementImpl::setAttributes()
DOM::DOMString _values = getAttribute("values");
if(!_values.isNull())
{
- QString test = _values.string();
+ TQString test = _values.string();
if(test.contains(";"))
{
SVGLengthImpl *temp = SVGSVGElementImpl::createSVGLength();
- QStringList list = QStringList::split(';', test);
+ TQStringList list = TQStringList::split(';', test);
temp->setValueAsString(list[0]);
m_from = temp->value();
temp->setValueAsString(list[1]);
@@ -192,8 +192,8 @@ void SVGAnimateTransformElementImpl::handleTimerEvent(bool)
else if(m_type == "skewy")
transform->setSkewY(m_from);
- QString trans = transform->toString();
- QString last = trans;
+ TQString trans = transform->toString();
+ TQString last = trans;
if(targetElement()->hasAttribute("transform"))
{
@@ -203,7 +203,7 @@ void SVGAnimateTransformElementImpl::handleTimerEvent(bool)
{
int pos = trans.find(m_lastTransform);
- QString extract;
+ TQString extract;
extract += trans.mid(0, pos);
extract += trans.mid(pos + m_lastTransform.length() + 1, trans.length());
diff --git a/ksvg/impl/SVGAnimateTransformElementImpl.h b/ksvg/impl/SVGAnimateTransformElementImpl.h
index 7e6e2653..ddd73989 100644
--- a/ksvg/impl/SVGAnimateTransformElementImpl.h
+++ b/ksvg/impl/SVGAnimateTransformElementImpl.h
@@ -25,7 +25,7 @@
#include "SVGAnimationElementImpl.h"
-class QTimer;
+class TQTimer;
namespace KSVG
{
@@ -42,7 +42,7 @@ public:
virtual void setAttributes();
private:
- QString m_type, m_lastTransform;
+ TQString m_type, m_lastTransform;
int m_times;
@@ -53,7 +53,7 @@ private:
double m_from, m_to, m_newFrom, m_newTo;
double m_addStep;
- QTimer *m_transformTimer;
+ TQTimer *m_transformTimer;
SVGTransformListImpl *m_transformList;
bool m_firstEvent;
diff --git a/ksvg/impl/SVGAnimatedPointsImpl.cc b/ksvg/impl/SVGAnimatedPointsImpl.cc
index 093ded77..07db7d3b 100644
--- a/ksvg/impl/SVGAnimatedPointsImpl.cc
+++ b/ksvg/impl/SVGAnimatedPointsImpl.cc
@@ -20,7 +20,7 @@
#include <kdebug.h>
-#include <qstringlist.h>
+#include <tqstringlist.h>
#include "CanvasItem.h"
#include "SVGPointListImpl.h"
@@ -62,7 +62,7 @@ SVGPointListImpl *SVGAnimatedPointsImpl::animatedPoints() const
return m_animatedPoints;
}
-void SVGAnimatedPointsImpl::parsePoints(QString _points, SVGPointListImpl *points)
+void SVGAnimatedPointsImpl::parsePoints(TQString _points, SVGPointListImpl *points)
{
if(_points.isEmpty())
return;
@@ -73,13 +73,13 @@ void SVGAnimatedPointsImpl::parsePoints(QString _points, SVGPointListImpl *point
return;
_points.replace(',', ' ');
- _points.replace('\r', QString::null);
- _points.replace('\n', QString::null);
+ _points.replace('\r', TQString::null);
+ _points.replace('\n', TQString::null);
_points = _points.simplifyWhiteSpace();
- QStringList pointList = QStringList::split(' ', _points);
- for(QStringList::Iterator it = pointList.begin(); it != pointList.end(); it++)
+ TQStringList pointList = TQStringList::split(' ', _points);
+ for(TQStringList::Iterator it = pointList.begin(); it != pointList.end(); it++)
{
SVGPointImpl *point = SVGSVGElementImpl::createSVGPoint();
point->setX((*(it++)).toFloat());
diff --git a/ksvg/impl/SVGAnimatedPointsImpl.h b/ksvg/impl/SVGAnimatedPointsImpl.h
index ef4dafca..9c4c88d7 100644
--- a/ksvg/impl/SVGAnimatedPointsImpl.h
+++ b/ksvg/impl/SVGAnimatedPointsImpl.h
@@ -25,7 +25,7 @@
#include "ksvg_lookup.h"
-class QString;
+class TQString;
namespace KSVG
{
@@ -40,7 +40,7 @@ public:
SVGPointListImpl *points() const;
SVGPointListImpl *animatedPoints() const;
- static void parsePoints(QString _points, SVGPointListImpl *points);
+ static void parsePoints(TQString _points, SVGPointListImpl *points);
protected:
SVGPointListImpl *m_points;
diff --git a/ksvg/impl/SVGAnimationElementImpl.cc b/ksvg/impl/SVGAnimationElementImpl.cc
index 454a323e..45c4af2b 100644
--- a/ksvg/impl/SVGAnimationElementImpl.cc
+++ b/ksvg/impl/SVGAnimationElementImpl.cc
@@ -22,7 +22,7 @@
#include <kdebug.h>
-#include <qtimer.h>
+#include <tqtimer.h>
#include "CanvasItem.h"
#include "SVGHelperImpl.h"
@@ -74,10 +74,10 @@ SVGElementImpl *SVGAnimationElementImpl::targetElement() const
return m_targetElement;
}
-double SVGAnimationElementImpl::parseClockValue(const QString &data) const
+double SVGAnimationElementImpl::parseClockValue(const TQString &data) const
{
- QString parse = data.stripWhiteSpace();
- QString debugOutput = "parseClockValue(" + parse + ") -> ";
+ TQString parse = data.stripWhiteSpace();
+ TQString debugOutput = "parseClockValue(" + parse + ") -> ";
if(parse == "indefinite") // Saves some time...
return -1;
@@ -98,7 +98,7 @@ double SVGAnimationElementImpl::parseClockValue(const QString &data) const
if(parse.find('.') != -1)
{
- QString temp = parse.mid(9, 2);
+ TQString temp = parse.mid(9, 2);
milliseconds = temp.toUInt();
result += (milliseconds * (1 / pow(10.0, temp.length())));
}
@@ -113,7 +113,7 @@ double SVGAnimationElementImpl::parseClockValue(const QString &data) const
if(parse.find('.') != -1)
{
- QString temp = parse.mid(6, 2);
+ TQString temp = parse.mid(6, 2);
milliseconds = temp.toUInt();
result += (milliseconds * (1 / pow(10.0, temp.length())));
}
@@ -129,7 +129,7 @@ double SVGAnimationElementImpl::parseClockValue(const QString &data) const
else
{
result = parse.mid(0, dotPosition).toUInt() * 3600;
- QString temp = parse.mid(dotPosition + 1, parse.length() - dotPosition - 2);
+ TQString temp = parse.mid(dotPosition + 1, parse.length() - dotPosition - 2);
result += (3600.0 * temp.toUInt()) * (1 / pow(10.0, temp.length()));
}
}
@@ -140,7 +140,7 @@ double SVGAnimationElementImpl::parseClockValue(const QString &data) const
else
{
result = parse.mid(0, dotPosition).toUInt() * 60;
- QString temp = parse.mid(dotPosition + 1, parse.length() - dotPosition - 4);
+ TQString temp = parse.mid(dotPosition + 1, parse.length() - dotPosition - 4);
result += (60.0 * temp.toUInt()) * (1 / pow(10.0, temp.length()));
}
}
@@ -151,7 +151,7 @@ double SVGAnimationElementImpl::parseClockValue(const QString &data) const
else
{
result = parse.mid(0, dotPosition).toUInt() / 1000.0;
- QString temp = parse.mid(dotPosition + 1, parse.length() - dotPosition - 3);
+ TQString temp = parse.mid(dotPosition + 1, parse.length() - dotPosition - 3);
result += (temp.toUInt() / 1000.0) * (1 / pow(10.0, temp.length()));
}
}
@@ -162,7 +162,7 @@ double SVGAnimationElementImpl::parseClockValue(const QString &data) const
else
{
result = parse.mid(0, dotPosition).toUInt();
- QString temp = parse.mid(dotPosition + 1, parse.length() - dotPosition - 2);
+ TQString temp = parse.mid(dotPosition + 1, parse.length() - dotPosition - 2);
result += temp.toUInt() * (1 / pow(10.0, temp.length()));
}
}
@@ -229,7 +229,7 @@ void SVGAnimationElementImpl::putValueProperty(ExecState *exec, int token, const
if(!(attr & KJS::Internal))
return;
- QString val = value.toString(exec).qstring();
+ TQString val = value.toString(exec).qstring();
switch(token)
{
case Href:
@@ -293,12 +293,12 @@ void SVGAnimationElementImpl::putValueProperty(ExecState *exec, int token, const
// Parse data
for(unsigned int i = 0; i < temp->numberOfItems(); i++)
{
- QString current = temp->getItem(i)->string();
+ TQString current = temp->getItem(i)->string();
if(current.startsWith("accessKey"))
{
// Register keyDownEventListener for the character
- QString character = current.mid(current.length() - 2, 1);
+ TQString character = current.mid(current.length() - 2, 1);
kdDebug() << "ACCESSKEY CHARACTER " << character << endl;
}
@@ -307,7 +307,7 @@ void SVGAnimationElementImpl::putValueProperty(ExecState *exec, int token, const
int firstBrace = current.find("(");
int secondBrace = current.find(")");
- QString wallclockValue = current.mid(firstBrace + 1, secondBrace - firstBrace - 2);
+ TQString wallclockValue = current.mid(firstBrace + 1, secondBrace - firstBrace - 2);
kdDebug() << "WALLCLOCK VALUE " << wallclockValue << endl;
}
@@ -315,8 +315,8 @@ void SVGAnimationElementImpl::putValueProperty(ExecState *exec, int token, const
{
int dotPosition = current.find(".");
- QString element = current.mid(0, dotPosition);
- QString clockValue;
+ TQString element = current.mid(0, dotPosition);
+ TQString clockValue;
if(current.contains("begin"))
clockValue = current.mid(dotPosition + 6);
@@ -333,7 +333,7 @@ void SVGAnimationElementImpl::putValueProperty(ExecState *exec, int token, const
else if(current.contains("-"))
plusMinusPosition = current.find("-");
- QString event = current.mid(dotPosition + 1, plusMinusPosition - dotPosition - 1);
+ TQString event = current.mid(dotPosition + 1, plusMinusPosition - dotPosition - 1);
clockValue = current.mid(dotPosition + event.length() + 1);
kdDebug() << "EVENT " << event << endl;
@@ -427,7 +427,7 @@ void SVGAnimationElementImpl::setTargetElement(SVGElementImpl *target)
m_targetElement->ref();
}
-void SVGAnimationElementImpl::applyAttribute(const QString &name, const QString &value)
+void SVGAnimationElementImpl::applyAttribute(const TQString &name, const TQString &value)
{
SVGElementImpl *target = targetElement();
if(!target)
diff --git a/ksvg/impl/SVGAnimationElementImpl.h b/ksvg/impl/SVGAnimationElementImpl.h
index 9fd9446e..7a42a77e 100644
--- a/ksvg/impl/SVGAnimationElementImpl.h
+++ b/ksvg/impl/SVGAnimationElementImpl.h
@@ -81,7 +81,7 @@ public:
SVGElementImpl *targetElement() const;
void setTargetElement(SVGElementImpl *target);
- void applyAttribute(const QString &name, const QString &value);
+ void applyAttribute(const TQString &name, const TQString &value);
virtual void handleTimerEvent() { } //= 0;
virtual void setAttributes();
@@ -90,16 +90,16 @@ public:
double getCurrentTime() const;
double getSimpleDuration() const;
- QString getRepeatCount() const { return m_repeatCount; }
- QString getRepeatDuration() const { return m_repeatDur; }
+ TQString getRepeatCount() const { return m_repeatCount; }
+ TQString getRepeatDuration() const { return m_repeatDur; }
- QString getAttributeName() const { return m_attributeName; }
- QString getFrom() const { return m_from; }
- QString getTo() const { return m_to; }
- QString getBy() const { return m_by; }
+ TQString getAttributeName() const { return m_attributeName; }
+ TQString getFrom() const { return m_from; }
+ TQString getTo() const { return m_to; }
+ TQString getBy() const { return m_by; }
protected:
- double parseClockValue(const QString &data) const;
+ double parseClockValue(const TQString &data) const;
bool m_connected;
EFillMode m_fill : 1;
@@ -110,13 +110,13 @@ protected:
EAttributeType m_attributeType : 2;
SVGElementImpl *m_targetElement;
- QString m_href;
- QString m_attributeName;
- QString m_from, m_to, m_by;
+ TQString m_href;
+ TQString m_attributeName;
+ TQString m_from, m_to, m_by;
double m_begin, m_end, m_duration;
- QString m_repeatCount, m_repeatDur;
+ TQString m_repeatCount, m_repeatDur;
SVGStringListImpl *m_values, *m_keyTimes, *m_keySplines;
diff --git a/ksvg/impl/SVGColorImpl.cc b/ksvg/impl/SVGColorImpl.cc
index a01e1113..799c43ec 100644
--- a/ksvg/impl/SVGColorImpl.cc
+++ b/ksvg/impl/SVGColorImpl.cc
@@ -20,7 +20,7 @@
#include <kdebug.h>
-#include <qstringlist.h>
+#include <tqstringlist.h>
#include "SVGColor.h"
@@ -83,7 +83,7 @@ SVGICCColorImpl *SVGColorImpl::iccColor() const
return m_iccColor;
}
-void SVGColorImpl::setRGBColor(QColor color)
+void SVGColorImpl::setRGBColor(TQColor color)
{
m_colorType = SVG_COLORTYPE_RGBCOLOR;
m_rgbColor = DOM::RGBColor(color.rgb());
@@ -92,7 +92,7 @@ void SVGColorImpl::setRGBColor(QColor color)
void SVGColorImpl::setRGBColor(int r, int g, int b)
{
m_colorType = SVG_COLORTYPE_RGBCOLOR;
- m_rgbColor = DOM::RGBColor(QColor(r, g, b).rgb());
+ m_rgbColor = DOM::RGBColor(TQColor(r, g, b).rgb());
}
void SVGColorImpl::setRGBColor(const DOM::DOMString &rgbColor)
@@ -395,15 +395,15 @@ void SVGColorImpl::setRGBColor(const DOM::DOMString &rgbColor)
void SVGColorImpl::setRGBColorICCColor(const DOM::DOMString &rgbColor, const DOM::DOMString &iccColor)
{
- QColor color;
+ TQColor color;
- QString content = iccColor.string().right(iccColor.string().length() - 10);
- QString iccTarget = content.mid(0, content.find(','));
+ TQString content = iccColor.string().right(iccColor.string().length() - 10);
+ TQString iccTarget = content.mid(0, content.find(','));
- QStringList colors = QStringList::split(',', content);
- QString r = colors[1];
- QString g = colors[2];
- QString b = colors[3].left(colors[3].length() - 1);
+ TQStringList colors = TQStringList::split(',', content);
+ TQString r = colors[1];
+ TQString g = colors[2];
+ TQString b = colors[3].left(colors[3].length() - 1);
iccTarget = SVGURIReferenceImpl::getTarget(iccTarget);
diff --git a/ksvg/impl/SVGColorImpl.h b/ksvg/impl/SVGColorImpl.h
index d49c6f82..abefd069 100644
--- a/ksvg/impl/SVGColorImpl.h
+++ b/ksvg/impl/SVGColorImpl.h
@@ -47,7 +47,7 @@ public:
virtual void setRGBColor(const DOM::DOMString &rgbColor);
virtual void setRGBColor(int r, int g, int b);
- virtual void setRGBColor(QColor color);
+ virtual void setRGBColor(TQColor color);
virtual void setRGBColorICCColor(const DOM::DOMString &rgbColor, const DOM::DOMString &iccColor);
virtual void setColor(unsigned short colorType, const DOM::DOMString &rgbColor, const DOM::DOMString &iccColor);
diff --git a/ksvg/impl/SVGColorProfileElementImpl.cc b/ksvg/impl/SVGColorProfileElementImpl.cc
index f898188b..385a836b 100644
--- a/ksvg/impl/SVGColorProfileElementImpl.cc
+++ b/ksvg/impl/SVGColorProfileElementImpl.cc
@@ -22,7 +22,7 @@
#include <kdebug.h>
#include <kio/netaccess.h>
-#include <qimage.h>
+#include <tqimage.h>
#include "SVGDocumentImpl.h"
#include "SVGSVGElementImpl.h"
@@ -97,7 +97,7 @@ void SVGColorProfileElementImpl::putValueProperty(ExecState *exec, int token, co
break;
case RenderingIntent:
{
- QString compare = value.toString(exec).qstring().lower();
+ TQString compare = value.toString(exec).qstring().lower();
if(compare == "perceptual")
m_renderingIntent = RENDERING_INTENT_PERCEPTUAL;
@@ -148,12 +148,12 @@ unsigned short SVGColorProfileElementImpl::renderingIntent() const
bool SVGColorProfileElementImpl::canLoad()
{
- QString open;
+ TQString open;
bool temp;
return canLoad(false, temp, open, true);
}
-bool SVGColorProfileElementImpl::canLoad(bool remote, bool &tempFile, QString &open, bool verbose)
+bool SVGColorProfileElementImpl::canLoad(bool remote, bool &tempFile, TQString &open, bool verbose)
{
KURL file;
@@ -174,7 +174,7 @@ bool SVGColorProfileElementImpl::canLoad(bool remote, bool &tempFile, QString &o
{
open = file.path();
- if(!QFile::exists(open))
+ if(!TQFile::exists(open))
{
if(verbose)
kdDebug() << "Couldn't load color profile " << file.path() << "! It does not exist." << endl;
@@ -196,7 +196,7 @@ bool SVGColorProfileElementImpl::canLoad(bool remote, bool &tempFile, QString &o
bool SVGColorProfileElementImpl::loadColorProfile()
{
- QString open;
+ TQString open;
bool tempFile = false;
if(!canLoad(true, tempFile, open, false))
@@ -251,7 +251,7 @@ QRgb SVGColorProfileElementImpl::correctPixel(float r, float g, float b)
return qRgb(0, 0, 0);
}
-QImage *SVGColorProfileElementImpl::correctImage(QImage *input)
+TQImage *SVGColorProfileElementImpl::correctImage(TQImage *input)
{
if(!canLoad())
return input;
diff --git a/ksvg/impl/SVGColorProfileElementImpl.h b/ksvg/impl/SVGColorProfileElementImpl.h
index 2f735f03..ad498c4b 100644
--- a/ksvg/impl/SVGColorProfileElementImpl.h
+++ b/ksvg/impl/SVGColorProfileElementImpl.h
@@ -33,7 +33,7 @@
#include "ksvg_lookup.h"
-class QImage;
+class TQImage;
namespace KSVG
{
@@ -54,7 +54,7 @@ public:
void setRenderingIntent(unsigned short renderingIntent);
unsigned short renderingIntent() const;
- QImage *correctImage(QImage *input);
+ TQImage *correctImage(TQImage *input);
QRgb correctPixel(float r, float g, float b);
private:
@@ -62,7 +62,7 @@ private:
void closeColorProfile();
bool canLoad();
- bool canLoad(bool remote, bool &tempFile, QString &open, bool verbose);
+ bool canLoad(bool remote, bool &tempFile, TQString &open, bool verbose);
DOM::DOMString m_local;
DOM::DOMString m_name;
diff --git a/ksvg/impl/SVGContainerImpl.cc b/ksvg/impl/SVGContainerImpl.cc
index 88fb87a8..e4a7c0db 100644
--- a/ksvg/impl/SVGContainerImpl.cc
+++ b/ksvg/impl/SVGContainerImpl.cc
@@ -37,7 +37,7 @@ SVGContainerImpl::~SVGContainerImpl()
SVGRectImpl *SVGContainerImpl::getBBox()
{
// just get the union of the children bboxes
- QRect rect;
+ TQRect rect;
DOM::Node node = firstChild();
for(; !node.isNull(); node = node.nextSibling())
{
diff --git a/ksvg/impl/SVGDocumentImpl.cc b/ksvg/impl/SVGDocumentImpl.cc
index 4bbe2664..c2b412f3 100644
--- a/ksvg/impl/SVGDocumentImpl.cc
+++ b/ksvg/impl/SVGDocumentImpl.cc
@@ -42,7 +42,7 @@
#include "KSVGCanvas.h"
#include "CanvasItem.h"
-#include <qpaintdevicemetrics.h>
+#include <tqpaintdevicemetrics.h>
using namespace KSVG;
@@ -53,7 +53,7 @@ using namespace KSVG;
// A sequence of prime numbers that sets the m_elemDict's hash table size as the
// number of elements in the dictionary passes each level. This keeps the lookup
-// performance high as the number of elements grows. See the QDict documentation.
+// performance high as the number of elements grows. See the TQDict documentation.
unsigned int SVGDocumentImpl::elemDictHashSizes [] =
{
101,
@@ -74,7 +74,7 @@ unsigned int SVGDocumentImpl::elemDictHashSizes [] =
const int SVGDocumentImpl::numElemDictHashSizes = sizeof(elemDictHashSizes) / sizeof(elemDictHashSizes[0]);
-SVGDocumentImpl::SVGDocumentImpl(bool anim, bool fit, SVGImageElementImpl *parentImage) : QObject(), DOM::DomShared(), DOM::Document(), SVGDOMNodeBridge(static_cast<DOM::Node>(*this))
+SVGDocumentImpl::SVGDocumentImpl(bool anim, bool fit, SVGImageElementImpl *parentImage) : TQObject(), DOM::DomShared(), DOM::Document(), SVGDOMNodeBridge(static_cast<DOM::Node>(*this))
{
m_animations = anim;
@@ -107,7 +107,7 @@ SVGDocumentImpl::~SVGDocumentImpl()
if(rootElement() && rootElement()->hasEventListener(SVGEvent::UNLOAD_EVENT, true))
rootElement()->dispatchEvent(SVGEvent::UNLOAD_EVENT, false, false);
- QPtrList<SVGShapeImpl> killList;
+ TQPtrList<SVGShapeImpl> killList;
DOM::Node node = firstChild();
for(; !node.isNull(); node = node.nextSibling())
@@ -148,7 +148,7 @@ float SVGDocumentImpl::screenPixelsPerMillimeterX() const
{
if(canvas() && canvas()->drawWindow())
{
- QPaintDeviceMetrics metrics(canvas()->drawWindow());
+ TQPaintDeviceMetrics metrics(canvas()->drawWindow());
return float(metrics.width()) / float(metrics.widthMM());
}
else
@@ -159,7 +159,7 @@ float SVGDocumentImpl::screenPixelsPerMillimeterY() const
{
if(canvas() && canvas()->drawWindow())
{
- QPaintDeviceMetrics metrics(canvas()->drawWindow());
+ TQPaintDeviceMetrics metrics(canvas()->drawWindow());
return float(metrics.height()) / float(metrics.heightMM());
}
else
@@ -231,7 +231,7 @@ bool SVGDocumentImpl::open(const ::KURL &url)
if(!m_loader)
m_loader = new KSVGLoader();
- connect(m_loader, SIGNAL(gotResult(QIODevice *)), this, SLOT(slotSVGContent(QIODevice *)));
+ connect(m_loader, TQT_SIGNAL(gotResult(TQIODevice *)), this, TQT_SLOT(slotSVGContent(TQIODevice *)));
m_loader->getSVGContent(url);
}
else
@@ -240,9 +240,9 @@ bool SVGDocumentImpl::open(const ::KURL &url)
return true;
}
-void SVGDocumentImpl::slotSVGContent(QIODevice *dev)
+void SVGDocumentImpl::slotSVGContent(TQIODevice *dev)
{
- QXmlInputSource *inputSource = new QXmlInputSource(dev);
+ TQXmlInputSource *inputSource = new TQXmlInputSource(dev);
if(m_reader)
delete m_reader;
@@ -251,13 +251,13 @@ void SVGDocumentImpl::slotSVGContent(QIODevice *dev)
args.fit = m_fit;
args.getURLMode = false;
- QString url = m_baseURL.prettyURL();
+ TQString url = m_baseURL.prettyURL();
int pos = url.find('#'); // url can become like this.svg#svgView(viewBox(63,226,74,74)), get part after '#'
if(pos > -1)
args.SVGFragmentId = url.mid(pos + 1);
m_reader = new KSVGReader(this, m_canvas, args);
- connect(m_reader, SIGNAL(finished(bool, const QString &)), this, SLOT(slotFinishedParsing(bool, const QString &)));
+ connect(m_reader, TQT_SIGNAL(finished(bool, const TQString &)), this, TQT_SLOT(slotFinishedParsing(bool, const TQString &)));
m_t.start();
#if USE_VALGRIND
@@ -268,7 +268,7 @@ void SVGDocumentImpl::slotSVGContent(QIODevice *dev)
delete dev;
}
-void SVGDocumentImpl::parseSVG(QXmlInputSource *inputSource, bool getURLMode)
+void SVGDocumentImpl::parseSVG(TQXmlInputSource *inputSource, bool getURLMode)
{
if(m_reader)
delete m_reader;
@@ -277,7 +277,7 @@ void SVGDocumentImpl::parseSVG(QXmlInputSource *inputSource, bool getURLMode)
args.fit = m_fit;
args.getURLMode = getURLMode;
m_reader = new KSVGReader(this, 0, args);
- connect(m_reader, SIGNAL(finished(bool, const QString &)), this, SLOT(slotFinishedParsing(bool, const QString &)));
+ connect(m_reader, TQT_SIGNAL(finished(bool, const TQString &)), this, TQT_SLOT(slotFinishedParsing(bool, const TQString &)));
#if USE_VALGRIND
CALLTREE_ZERO_STATS();
@@ -286,13 +286,13 @@ void SVGDocumentImpl::parseSVG(QXmlInputSource *inputSource, bool getURLMode)
m_reader->parse(inputSource);
}
-void SVGDocumentImpl::finishParsing(bool error, const QString &errorDesc)
+void SVGDocumentImpl::finishParsing(bool error, const TQString &errorDesc)
{
if(m_reader)
m_reader->finishParsing(error, errorDesc);
}
-void SVGDocumentImpl::slotFinishedParsing(bool error, const QString &errorDesc)
+void SVGDocumentImpl::slotFinishedParsing(bool error, const TQString &errorDesc)
{
kdDebug(26000) << k_funcinfo << "total time : " << m_t.elapsed() << endl;
@@ -454,7 +454,7 @@ void SVGDocumentImpl::executeScripts()
bool test = executeScriptsRecursiveCheck(*rootElement());
if(!test)
- QTimer::singleShot(50, this, SLOT(executeScripts()));
+ TQTimer::singleShot(50, this, TQT_SLOT(executeScripts()));
else
{
executeScriptsRecursive(*rootElement());
@@ -690,7 +690,7 @@ SVGElementImpl *SVGDocumentImpl::getElementByIdRecursive(SVGSVGElementImpl *star
// #3 Search in other documents
if(!dontSearch)
{
- QPtrDictIterator<SVGDocumentImpl> it(m_documentDict);
+ TQPtrDictIterator<SVGDocumentImpl> it(m_documentDict);
for(; it.current(); ++it)
{
SVGElementImpl *temp = it.current()->getElementByIdRecursive(0, elementId, true);
diff --git a/ksvg/impl/SVGDocumentImpl.h b/ksvg/impl/SVGDocumentImpl.h
index c4156910..10eae77e 100644
--- a/ksvg/impl/SVGDocumentImpl.h
+++ b/ksvg/impl/SVGDocumentImpl.h
@@ -23,12 +23,12 @@
#include <kurl.h>
-#include <qxml.h>
-#include <qobject.h>
-#include <qptrdict.h>
-#include <qptrlist.h>
-#include <qdatetime.h>
-#include <qstringlist.h>
+#include <tqxml.h>
+#include <tqobject.h>
+#include <tqptrdict.h>
+#include <tqptrlist.h>
+#include <tqdatetime.h>
+#include <tqstringlist.h>
#include <kjs/object.h>
@@ -66,7 +66,7 @@ class SVGScriptElementImpl;
class SVGDescElementImpl;
class SVGTitleElementImpl;
class SVGUseElementImpl;
-class SVGDocumentImpl : public QObject,
+class SVGDocumentImpl : public TQObject,
public DOM::DomShared,
public DOM::Document,
public SVGDOMNodeBridge
@@ -109,7 +109,7 @@ public:
// Ecma stuff
KSVGEcma *ecmaEngine() { return m_ecmaEngine; }
- void parseSVG(QXmlInputSource *inputSource, bool getURLMode = false);
+ void parseSVG(TQXmlInputSource *inputSource, bool getURLMode = false);
virtual bool implementsCall() const { return true; }
@@ -139,7 +139,7 @@ public:
SVGElementImpl *recursiveSearch(DOM::Node start, const DOM::DOMString &id);
- void finishParsing(bool error, const QString &errorDesc);
+ void finishParsing(bool error, const TQString &errorDesc);
void newImageJob(SVGImageElementImpl *);
@@ -148,7 +148,7 @@ public:
void resortZIndicesOnFinishedLoading() { m_resortZIndicesOnFinishedLoading = true; }
void addForwardReferencingUseElement(SVGUseElementImpl *use);
- QValueList<SVGUseElementImpl *> forwardReferencingUseElements() const { return m_forwardReferencingUseElements; }
+ TQValueList<SVGUseElementImpl *> forwardReferencingUseElements() const { return m_forwardReferencingUseElements; }
// Traverse the element hierarchy and update any cached matrices that are
// no longer valid.
@@ -159,18 +159,18 @@ public slots:
void executeScripts();
private slots:
- void slotSVGContent(QIODevice *);
- void slotFinishedParsing(bool error, const QString &errorDesc);
+ void slotSVGContent(TQIODevice *);
+ void slotFinishedParsing(bool error, const TQString &errorDesc);
// KDE invents public signals :)
#undef signals
#define signals public
signals:
- void gotDescription(const QString &);
- void gotTitle(const QString &);
- void gotURL(const QString &);
+ void gotDescription(const TQString &);
+ void gotTitle(const TQString &);
+ void gotURL(const TQString &);
- void finishedParsing(bool error, const QString &errorDesc);
+ void finishedParsing(bool error, const TQString &errorDesc);
void finishedRendering();
void finishedLoading();
@@ -195,8 +195,8 @@ private:
KSVGEcma *m_ecmaEngine;
- QPtrDict<SVGElementImpl> m_elemDict;
- QPtrDict<SVGDocumentImpl> m_documentDict;
+ TQPtrDict<SVGElementImpl> m_elemDict;
+ TQPtrDict<SVGDocumentImpl> m_documentDict;
static uint elemDictHashSizes[];
static const int numElemDictHashSizes;
@@ -211,12 +211,12 @@ private:
bool m_fit;
- QTime m_t;
+ TQTime m_t;
- QValueList<SVGImageElementImpl *> m_imagesLoading;
+ TQValueList<SVGImageElementImpl *> m_imagesLoading;
bool m_resortZIndicesOnFinishedLoading;
- QValueList<SVGUseElementImpl *> m_forwardReferencingUseElements;
+ TQValueList<SVGUseElementImpl *> m_forwardReferencingUseElements;
public:
KSVG_BASECLASS_GET
diff --git a/ksvg/impl/SVGEcma.cc b/ksvg/impl/SVGEcma.cc
index 08870d0c..39843a07 100644
--- a/ksvg/impl/SVGEcma.cc
+++ b/ksvg/impl/SVGEcma.cc
@@ -405,7 +405,7 @@ Value SVGDOMNodeBridgeProtoFunc::call(ExecState *exec, Object &thisObj, const Li
{
SVGEvent::EventId eventId = SVGEvent::typeToId(args[0].toString(exec).string());
if(eventId != SVGEvent::UNKNOWN_EVENT)
- element->setEventListener(eventId, new KSVGEcmaEventListener(Object::dynamicCast(args[1]), QString::null, doc->ecmaEngine()));
+ element->setEventListener(eventId, new KSVGEcmaEventListener(Object::dynamicCast(args[1]), TQString::null, doc->ecmaEngine()));
}
return Undefined();
}
diff --git a/ksvg/impl/SVGElementImpl.cc b/ksvg/impl/SVGElementImpl.cc
index 2f3d70c6..940790f2 100644
--- a/ksvg/impl/SVGElementImpl.cc
+++ b/ksvg/impl/SVGElementImpl.cc
@@ -18,7 +18,7 @@
Boston, MA 02110-1301, USA.
*/
-#include <qxml.h>
+#include <tqxml.h>
#include <kdebug.h>
@@ -78,7 +78,7 @@ int SVGElementImpl::getEventListeners(bool local)
{
int events = 0;
- QPtrListIterator<SVGRegisteredEventListener> it(m_eventListeners);
+ TQPtrListIterator<SVGRegisteredEventListener> it(m_eventListeners);
for(; it.current(); ++it)
events |= (1 << it.current()->id);
@@ -91,7 +91,7 @@ int SVGElementImpl::getEventListeners(bool local)
if(element)
{
- QPtrListIterator<SVGRegisteredEventListener> it(element->m_eventListeners);
+ TQPtrListIterator<SVGRegisteredEventListener> it(element->m_eventListeners);
for(; it.current(); ++it)
events |= (1 << it.current()->id);
}
@@ -109,12 +109,12 @@ void SVGElementImpl::setupEventListeners(SVGDocumentImpl *doc, SVGDocumentImpl *
// Needed for parseXML'ed elements with events, their listeners
// are created in the temporary document fragment and need to be
// registered in the main document (Niko)
- QPtrListIterator<SVGRegisteredEventListener> it(m_eventListeners);
+ TQPtrListIterator<SVGRegisteredEventListener> it(m_eventListeners);
for(; it.current(); ++it)
{
SVGRegisteredEventListener *current = it.current();
- QString valueOfCurrent = newDoc->ecmaEngine()->valueOfEventListener(current->listener);
+ TQString valueOfCurrent = newDoc->ecmaEngine()->valueOfEventListener(current->listener);
setEventListener(current->id, doc->createEventListener(valueOfCurrent));
}
}
@@ -122,7 +122,7 @@ void SVGElementImpl::setupEventListeners(SVGDocumentImpl *doc, SVGDocumentImpl *
bool SVGElementImpl::hasEventListener(int id, bool local)
{
// First check if we have the listener, locally
- QPtrListIterator<SVGRegisteredEventListener> it(m_eventListeners);
+ TQPtrListIterator<SVGRegisteredEventListener> it(m_eventListeners);
for(; it.current(); ++it)
{
if(it.current()->id == id)
@@ -141,7 +141,7 @@ bool SVGElementImpl::hasEventListener(int id, bool local)
if(element)
{
- QPtrListIterator<SVGRegisteredEventListener> it(element->m_eventListeners);
+ TQPtrListIterator<SVGRegisteredEventListener> it(element->m_eventListeners);
for(; it.current(); ++it)
{
if(it.current()->id == id)
@@ -155,7 +155,7 @@ bool SVGElementImpl::hasEventListener(int id, bool local)
void SVGElementImpl::removeEventListener(int id)
{
- QPtrListIterator<SVGRegisteredEventListener> it(m_eventListeners);
+ TQPtrListIterator<SVGRegisteredEventListener> it(m_eventListeners);
for(; it.current(); ++it)
{
if(it.current()->id == id)
@@ -168,7 +168,7 @@ void SVGElementImpl::removeEventListener(int id)
void SVGElementImpl::handleLocalEvents(SVGEventImpl *evt, bool useCapture)
{
- QPtrListIterator<SVGRegisteredEventListener> it(m_eventListeners);
+ TQPtrListIterator<SVGRegisteredEventListener> it(m_eventListeners);
for(; it.current(); ++it)
{
if(it.current()->id == evt->id() && it.current()->useCapture == useCapture)
@@ -320,7 +320,7 @@ Value SVGElementImplProtoFunc::call(ExecState *exec, Object &thisObj, const List
return Undefined();
}
-QDict<DOM::DOMString> &SVGElementImpl::attributes()
+TQDict<DOM::DOMString> &SVGElementImpl::attributes()
{
return m_attributes;
}
@@ -376,11 +376,11 @@ bool SVGElementImpl::hasAttributes()
return m_attributes.count() > 0;
}
-void SVGElementImpl::setApplyAttribute(const QString &name, const QString &value)
+void SVGElementImpl::setApplyAttribute(const TQString &name, const TQString &value)
{
if(hasAttribute(name))
{
- QString cur = getAttribute(name).string();
+ TQString cur = getAttribute(name).string();
cur = cur.simplifyWhiteSpace();
if(!cur.endsWith(";"))
@@ -451,7 +451,7 @@ SVGElementImpl *SVGElementImpl::viewportElement() const
return m_viewportElement;
}
-void SVGElementImpl::setAttributes(const QXmlAttributes &attrs)
+void SVGElementImpl::setAttributes(const TQXmlAttributes &attrs)
{
for(int i = 0; i < attrs.length(); i++)
{
@@ -494,7 +494,7 @@ void SVGElementImpl::setAttributes(bool deep)
}
}
-bool SVGElementImpl::prepareMouseEvent(const QPoint &p, const QPoint &a, SVGMouseEventImpl *mev)
+bool SVGElementImpl::prepareMouseEvent(const TQPoint &p, const TQPoint &a, SVGMouseEventImpl *mev)
{
SVGShapeImpl *shape = dynamic_cast<SVGShapeImpl *>(this);
if(shape)
@@ -519,7 +519,7 @@ bool SVGElementImpl::dispatchEvent(SVGEventImpl *evt, bool tempEvent)
evt->setTarget(this);
// Find out, where to send to -> collect parent nodes
- QPtrList<SVGElementImpl> nodeChain;
+ TQPtrList<SVGElementImpl> nodeChain;
for(DOM::Element e = *this; !e.isNull(); e = e.parentNode())
nodeChain.prepend(ownerDoc()->getElementFromHandle(e.handle()));
@@ -527,7 +527,7 @@ bool SVGElementImpl::dispatchEvent(SVGEventImpl *evt, bool tempEvent)
// Trigger any capturing event handlers on our way down
evt->setEventPhase(DOM::Event::CAPTURING_PHASE);
- QPtrListIterator<SVGElementImpl> it(nodeChain);
+ TQPtrListIterator<SVGElementImpl> it(nodeChain);
for(; it.current() && it.current() != this && !evt->propagationStopped(); ++it)
{
evt->setCurrentTarget(it.current());
@@ -583,17 +583,17 @@ bool SVGElementImpl::dispatchEvent(SVGEventImpl *evt, bool tempEvent)
return !evt->defaultPrevented(); // ### what if defaultPrevented was called before dispatchEvent?
}
-bool SVGElementImpl::dispatchKeyEvent(QKeyEvent *ke)
+bool SVGElementImpl::dispatchKeyEvent(TQKeyEvent *ke)
{
DOM::AbstractView temp;
SVGEvent::EventId evtId = SVGEvent::UNKNOWN_EVENT;
- if(ke->type() == QEvent::KeyRelease && !ke->isAutoRepeat())
+ if(ke->type() == TQEvent::KeyRelease && !ke->isAutoRepeat())
evtId = SVGEvent::KEYUP_EVENT;
else if(ke->isAutoRepeat())
evtId = SVGEvent::KEYPRESS_EVENT;
- else if(ke->type() == QEvent::KeyPress)
+ else if(ke->type() == TQEvent::KeyPress)
evtId = SVGEvent::KEYDOWN_EVENT;
if(evtId == SVGEvent::KEYUP_EVENT && hasEventListener(SVGEvent::DOMACTIVATE_EVENT, false))
@@ -679,7 +679,7 @@ void SVGElementImpl::cloneChildNodes(SVGElementImpl *clone)
}
}
-void SVGElementImpl::gotError(const QString &errorDesc)
+void SVGElementImpl::gotError(const TQString &errorDesc)
{
if(ownerDoc())
{
@@ -689,9 +689,9 @@ void SVGElementImpl::gotError(const QString &errorDesc)
}
}
-QString SVGElementImpl::collectText()
+TQString SVGElementImpl::collectText()
{
- QString text;
+ TQString text;
if(hasChildNodes())
{
diff --git a/ksvg/impl/SVGElementImpl.h b/ksvg/impl/SVGElementImpl.h
index c69a83e8..a12098ab 100644
--- a/ksvg/impl/SVGElementImpl.h
+++ b/ksvg/impl/SVGElementImpl.h
@@ -24,8 +24,8 @@
#include <map>
#include <string>
-#include <qdict.h>
-#include <qptrlist.h>
+#include <tqdict.h>
+#include <tqptrlist.h>
#include <dom/dom_string.h>
@@ -33,8 +33,8 @@
#include "ksvg_lookup.h"
-class QKeyEvent;
-class QXmlAttributes;
+class TQKeyEvent;
+class TQXmlAttributes;
namespace KJS
{
@@ -70,8 +70,8 @@ public:
bool hasAttribute(const DOM::DOMString &name);
bool hasAttributes();
- QDict<DOM::DOMString> &attributes();
- void setApplyAttribute(const QString &name, const QString &value);
+ TQDict<DOM::DOMString> &attributes();
+ void setApplyAttribute(const TQString &name, const TQString &value);
void setId(DOM::DOMString);
DOM::DOMString id() const;
@@ -85,11 +85,11 @@ public:
SVGSVGElementImpl *ownerSVGElement() const;
SVGElementImpl *viewportElement() const;
- void setAttributes(const QXmlAttributes &);
+ void setAttributes(const TQXmlAttributes &);
virtual void setAttributes();
void setAttributes(bool deep);
- QString collectText();
+ TQString collectText();
void setOwnerDoc(SVGDocumentImpl *doc);
SVGDocumentImpl *ownerDoc() const;
@@ -101,7 +101,7 @@ public:
bool dispatchEvent(int id, bool canBubbleArg, bool cancelableArg);
bool dispatchEvent(SVGEventImpl *evt, bool tempEvent);
bool dispatchMouseEvent(int id, bool canBubbleArg, bool cancelableArg, long detailArg, long screenXArg, long screenYArg, long clientXArg, long clientYArg, bool ctrlKeyArg, bool altKeyArg, bool shiftKeyArg, bool metaKeyArg, unsigned short buttonArg, SVGElementImpl *relatedTargetArg);
- bool dispatchKeyEvent(QKeyEvent *ke);
+ bool dispatchKeyEvent(TQKeyEvent *ke);
void setEventListener(int id, SVGEventListener *listener);
bool hasEventListener(int id, bool local);
@@ -110,7 +110,7 @@ public:
void setupEventListeners(SVGDocumentImpl *doc, SVGDocumentImpl *newDoc);
// Use with care! Internal only.
- const QPtrList<SVGRegisteredEventListener> &eventListeners() { return m_eventListeners; }
+ const TQPtrList<SVGRegisteredEventListener> &eventListeners() { return m_eventListeners; }
void handleLocalEvents(SVGEventImpl *evt, bool useCapture);
virtual void defaultEventHandler(SVGEventImpl *evt);
@@ -121,7 +121,7 @@ public:
bool focus() { return m_focus; }
void setFocus(bool v) { m_focus = v; }
- virtual bool prepareMouseEvent(const QPoint &, const QPoint &, SVGMouseEventImpl *);
+ virtual bool prepareMouseEvent(const TQPoint &, const TQPoint &, SVGMouseEventImpl *);
virtual void createItem(KSVGCanvas *c = 0) { Q_UNUSED(c); }
virtual void removeItem(KSVGCanvas *c) { Q_UNUSED(c); }
@@ -183,7 +183,7 @@ public:
static SVGElementImpl::Registrar<Class> Class##Registrar(Tag);
protected:
- void gotError(const QString &errorDesc);
+ void gotError(const TQString &errorDesc);
private:
SVGSVGElementImpl *m_ownerSVGElement;
@@ -193,8 +193,8 @@ private:
bool m_mouseOver : 1;
bool m_focus : 1;
- QPtrList<SVGRegisteredEventListener> m_eventListeners;
- QDict<DOM::DOMString> m_attributes;
+ TQPtrList<SVGRegisteredEventListener> m_eventListeners;
+ TQDict<DOM::DOMString> m_attributes;
public:
KSVG_BASECLASS_GET
diff --git a/ksvg/impl/SVGEventImpl.cc b/ksvg/impl/SVGEventImpl.cc
index 418e0044..17338f45 100644
--- a/ksvg/impl/SVGEventImpl.cc
+++ b/ksvg/impl/SVGEventImpl.cc
@@ -43,7 +43,7 @@ SVGEventImpl::SVGEventImpl()
m_defaultPrevented = false;
m_id = SVGEvent::UNKNOWN_EVENT;
m_eventPhase = 0;
- m_createTime = QDateTime::currentDateTime();
+ m_createTime = TQDateTime::currentDateTime();
m_defaultHandled = false;
m_target = 0;
@@ -62,7 +62,7 @@ SVGEventImpl::SVGEventImpl(SVGEvent::EventId _id, bool canBubbleArg, bool cancel
m_defaultPrevented = false;
m_id = _id;
m_eventPhase = 0;
- m_createTime = QDateTime::currentDateTime();
+ m_createTime = TQDateTime::currentDateTime();
m_defaultHandled = false;
m_target = 0;
@@ -120,7 +120,7 @@ bool SVGEventImpl::cancelable() const
DOM::DOMTimeStamp SVGEventImpl::timeStamp()
{
- QDateTime epoch(QDate(1970, 1, 1), QTime(0, 0));
+ TQDateTime epoch(TQDate(1970, 1, 1), TQTime(0, 0));
// ### kjs does not yet support long long (?) so the value wraps around
return epoch.secsTo(m_createTime) * 1000 + m_createTime.time().msec();
@@ -341,9 +341,9 @@ SVGKeyEventImpl::SVGKeyEventImpl() : SVGUIEventImpl()
qKeyEvent = 0;
}
-SVGKeyEventImpl::SVGKeyEventImpl(QKeyEvent *key, DOM::AbstractView &view, SVGEvent::EventId _id) : SVGUIEventImpl(_id, true, true, view, 0)
+SVGKeyEventImpl::SVGKeyEventImpl(TQKeyEvent *key, DOM::AbstractView &view, SVGEvent::EventId _id) : SVGUIEventImpl(_id, true, true, view, 0)
{
- qKeyEvent = new QKeyEvent(key->type(), key->key(), key->ascii(), key->state(), key->text(), key->isAutoRepeat(), key->count());
+ qKeyEvent = new TQKeyEvent(key->type(), key->key(), key->ascii(), key->state(), key->text(), key->isAutoRepeat(), key->count());
// Events are supposed to be accepted by default in Qt!
// This line made QLineEdit's keyevents be ignored, so they were sent to the khtmlview
diff --git a/ksvg/impl/SVGEventImpl.h b/ksvg/impl/SVGEventImpl.h
index a123b09e..2c70c0d2 100644
--- a/ksvg/impl/SVGEventImpl.h
+++ b/ksvg/impl/SVGEventImpl.h
@@ -25,8 +25,8 @@
#ifndef SVGEventImpl_H
#define SVGEventImpl_H
-#include <qevent.h>
-#include <qdatetime.h>
+#include <tqevent.h>
+#include <tqdatetime.h>
#include <dom/dom_misc.h>
#include <dom/dom_node.h>
@@ -98,7 +98,7 @@ protected:
SVGElementImpl *m_target;
unsigned short m_eventPhase;
- QDateTime m_createTime;
+ TQDateTime m_createTime;
public:
KSVG_BASECLASS_GET
@@ -278,7 +278,7 @@ public:
bool inputGeneratedArg,
bool numPadArg);
- SVGKeyEventImpl(QKeyEvent *key, DOM::AbstractView &view, SVGEvent::EventId _id);
+ SVGKeyEventImpl(TQKeyEvent *key, DOM::AbstractView &view, SVGEvent::EventId _id);
virtual bool isKeyEvent() { return true; }
@@ -363,7 +363,7 @@ public:
unsigned long virtKeyVal() const { return m_virtKeyVal; }
- QKeyEvent *qKeyEvent;
+ TQKeyEvent *qKeyEvent;
private:
unsigned long m_keyVal;
diff --git a/ksvg/impl/SVGFitToViewBoxImpl.cc b/ksvg/impl/SVGFitToViewBoxImpl.cc
index fee367b9..aaee3045 100644
--- a/ksvg/impl/SVGFitToViewBoxImpl.cc
+++ b/ksvg/impl/SVGFitToViewBoxImpl.cc
@@ -20,8 +20,8 @@
#include <kdebug.h>
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
#include "SVGPreserveAspectRatio.h"
@@ -65,7 +65,7 @@ SVGAnimatedPreserveAspectRatioImpl *SVGFitToViewBoxImpl::preserveAspectRatio() c
return m_preserveAspectRatio;
}
-void SVGFitToViewBoxImpl::parseViewBox(const QString &s)
+void SVGFitToViewBoxImpl::parseViewBox(const TQString &s)
{
// Set default if preserveAspectRatio wasnt parsed earlier (Rob)
if(m_preserveAspectRatio->baseVal()->align() == SVG_PRESERVEASPECTRATIO_UNKNOWN)
@@ -74,8 +74,8 @@ void SVGFitToViewBoxImpl::parseViewBox(const QString &s)
m_preserveAspectRatio->baseVal()->setMeetOrSlice(SVG_MEETORSLICE_MEET);
// allow for viewbox def with ',' or whitespace
- QString viewbox(s);
- QStringList points = QStringList::split(' ', viewbox.replace(',', ' ').simplifyWhiteSpace());
+ TQString viewbox(s);
+ TQStringList points = TQStringList::split(' ', viewbox.replace(',', ' ').simplifyWhiteSpace());
viewBox()->baseVal()->setX(points[0].toFloat());
viewBox()->baseVal()->setY(points[1].toFloat());
diff --git a/ksvg/impl/SVGFitToViewBoxImpl.h b/ksvg/impl/SVGFitToViewBoxImpl.h
index b511d63e..501a4061 100644
--- a/ksvg/impl/SVGFitToViewBoxImpl.h
+++ b/ksvg/impl/SVGFitToViewBoxImpl.h
@@ -23,7 +23,7 @@
#include "ksvg_lookup.h"
-class QString;
+class TQString;
namespace KSVG
{
@@ -40,7 +40,7 @@ public:
SVGAnimatedRectImpl *viewBox() const;
SVGAnimatedPreserveAspectRatioImpl *preserveAspectRatio() const;
- void parseViewBox(const QString &);
+ void parseViewBox(const TQString &);
SVGMatrixImpl *viewBoxToViewTransform(float viewWidth, float viewHeight) const;
diff --git a/ksvg/impl/SVGGlyphElementImpl.cc b/ksvg/impl/SVGGlyphElementImpl.cc
index dd201466..4fbc6bb7 100644
--- a/ksvg/impl/SVGGlyphElementImpl.cc
+++ b/ksvg/impl/SVGGlyphElementImpl.cc
@@ -35,7 +35,7 @@ SVGGlyphElementImpl::~SVGGlyphElementImpl()
{
}
-QString SVGGlyphElementImpl::d() const
+TQString SVGGlyphElementImpl::d() const
{
return m_d;
}
diff --git a/ksvg/impl/SVGGlyphElementImpl.h b/ksvg/impl/SVGGlyphElementImpl.h
index 35781b2c..576e554e 100644
--- a/ksvg/impl/SVGGlyphElementImpl.h
+++ b/ksvg/impl/SVGGlyphElementImpl.h
@@ -36,10 +36,10 @@ public:
SVGGlyphElementImpl(DOM::ElementImpl *);
virtual ~SVGGlyphElementImpl();
- QString d() const;
+ TQString d() const;
private:
- QString m_d;
+ TQString m_d;
public:
KSVG_GET
diff --git a/ksvg/impl/SVGGradientElementImpl.cc b/ksvg/impl/SVGGradientElementImpl.cc
index 180b230a..eae9059e 100644
--- a/ksvg/impl/SVGGradientElementImpl.cc
+++ b/ksvg/impl/SVGGradientElementImpl.cc
@@ -129,7 +129,7 @@ void SVGGradientElementImpl::putValueProperty(ExecState *exec, int token, const
break;
case SpreadMethod:
{
- QString spreadMethod = value.toString(exec).qstring();
+ TQString spreadMethod = value.toString(exec).qstring();
if(spreadMethod == "repeat")
m_spreadMethod->setBaseVal(SVG_SPREADMETHOD_REPEAT);
@@ -160,7 +160,7 @@ void SVGGradientElementImpl::setAttributes()
void SVGGradientElementImpl::setAttributesFromHref()
{
- QString _href = SVGURIReferenceImpl::getTarget(href()->baseVal().string());
+ TQString _href = SVGURIReferenceImpl::getTarget(href()->baseVal().string());
if(!_href.isEmpty())
{
@@ -168,12 +168,12 @@ void SVGGradientElementImpl::setAttributesFromHref()
if(refGradient)
{
- QMap<QString, DOM::DOMString> refAttributes = refGradient->gradientAttributes();
- QMap<QString, DOM::DOMString>::iterator it;
+ TQMap<TQString, DOM::DOMString> refAttributes = refGradient->gradientAttributes();
+ TQMap<TQString, DOM::DOMString>::iterator it;
for(it = refAttributes.begin(); it != refAttributes.end(); ++it)
{
- QString name = it.key();
+ TQString name = it.key();
DOM::DOMString value = it.data();
if(!hasAttribute(name))
@@ -210,7 +210,7 @@ SVGGradientElementImpl *SVGGradientElementImpl::stopsSource()
if(!haveStops)
{
- QString _href = SVGURIReferenceImpl::getTarget(href()->baseVal().string());
+ TQString _href = SVGURIReferenceImpl::getTarget(href()->baseVal().string());
if(!_href.isEmpty())
{
diff --git a/ksvg/impl/SVGGradientElementImpl.h b/ksvg/impl/SVGGradientElementImpl.h
index e9be92d8..60b9d3a9 100644
--- a/ksvg/impl/SVGGradientElementImpl.h
+++ b/ksvg/impl/SVGGradientElementImpl.h
@@ -21,7 +21,7 @@
#ifndef SVGGradientElementImpl_H
#define SVGGradientElementImpl_H
-#include <qmap.h>
+#include <tqmap.h>
#include "SVGElementImpl.h"
#include "SVGStylableImpl.h"
@@ -64,7 +64,7 @@ public:
// Returns the linear/radial gradient attributes set on this element,
// taking into account indirection through href.
- virtual QMap<QString, DOM::DOMString> gradientAttributes() = 0;
+ virtual TQMap<TQString, DOM::DOMString> gradientAttributes() = 0;
protected:
void setAttributesFromHref();
diff --git a/ksvg/impl/SVGHelperImpl.cc b/ksvg/impl/SVGHelperImpl.cc
index ed7e8be4..7378b8f4 100644
--- a/ksvg/impl/SVGHelperImpl.cc
+++ b/ksvg/impl/SVGHelperImpl.cc
@@ -20,7 +20,7 @@
#include <kdebug.h>
-#include <qregexp.h>
+#include <tqregexp.h>
#include "SVGRectImpl.h"
#include "SVGMatrixImpl.h"
@@ -77,7 +77,7 @@ void SVGHelperImpl::updateItem(KJS::ExecState *exec, const DOM::Node node)
void SVGHelperImpl::copyAttributes(SVGElementImpl *src, SVGElementImpl *dst)
{
- QDictIterator<DOM::DOMString> it(src->attributes());
+ TQDictIterator<DOM::DOMString> it(src->attributes());
for(; it.current(); ++it)
{
DOM::DOMString name = it.currentKey();
@@ -91,14 +91,14 @@ void SVGHelperImpl::copyAttributes(SVGElementImpl *src, SVGElementImpl *dst)
}
}
-void SVGHelperImpl::parseList(SVGStringListImpl *list, char seperator, const QString &data)
+void SVGHelperImpl::parseList(SVGStringListImpl *list, char seperator, const TQString &data)
{
// TODO : more error checking/reporting
list->clear();
- QStringList substrings = QStringList::split(seperator, data);
- QStringList::ConstIterator it = substrings.begin();
- QStringList::ConstIterator end = substrings.end();
+ TQStringList substrings = TQStringList::split(seperator, data);
+ TQStringList::ConstIterator it = substrings.begin();
+ TQStringList::ConstIterator end = substrings.end();
for(; it != end; ++it)
{
SharedString *string = new SharedString(*it);
@@ -108,13 +108,13 @@ void SVGHelperImpl::parseList(SVGStringListImpl *list, char seperator, const QSt
}
}
-void SVGHelperImpl::parseLengthList(SVGAnimatedLengthListImpl *list, const QString &lengths, LengthMode mode, SVGElementImpl *object)
+void SVGHelperImpl::parseLengthList(SVGAnimatedLengthListImpl *list, const TQString &lengths, LengthMode mode, SVGElementImpl *object)
{
// get either comma or space delimited lists
// TODO : more error checking/reporting
- QStringList sublengths = QStringList::split(QRegExp("[, ]"), lengths);
- QStringList::ConstIterator it = sublengths.begin();
- QStringList::ConstIterator end = sublengths.end();
+ TQStringList sublengths = TQStringList::split(TQRegExp("[, ]"), lengths);
+ TQStringList::ConstIterator it = sublengths.begin();
+ TQStringList::ConstIterator end = sublengths.end();
SVGLengthImpl *lengthImpl = 0;
for(; it != end; ++it)
@@ -127,32 +127,32 @@ void SVGHelperImpl::parseLengthList(SVGAnimatedLengthListImpl *list, const QStri
}
}
-void SVGHelperImpl::parseCommaSeperatedList(SVGStringListImpl *list, const QString &data)
+void SVGHelperImpl::parseCommaSeperatedList(SVGStringListImpl *list, const TQString &data)
{
parseList(list, ',', data);
}
-void SVGHelperImpl::parseSemicolonSeperatedList(SVGStringListImpl *list, const QString &data)
+void SVGHelperImpl::parseSemicolonSeperatedList(SVGStringListImpl *list, const TQString &data)
{
parseList(list, ';', data);
}
-void SVGHelperImpl::parseTransformAttribute(SVGTransformListImpl *list, const QString &transform)
+void SVGHelperImpl::parseTransformAttribute(SVGTransformListImpl *list, const TQString &transform)
{
// Split string for handling 1 transform statement at a time
- QStringList subtransforms = QStringList::split(')', transform);
- QStringList::ConstIterator it = subtransforms.begin();
- QStringList::ConstIterator end = subtransforms.end();
+ TQStringList subtransforms = TQStringList::split(')', transform);
+ TQStringList::ConstIterator it = subtransforms.begin();
+ TQStringList::ConstIterator end = subtransforms.end();
for(; it != end; ++it)
{
- QStringList subtransform = QStringList::split('(', (*it));
+ TQStringList subtransform = TQStringList::split('(', (*it));
subtransform[0] = subtransform[0].stripWhiteSpace().lower();
subtransform[1] = subtransform[1].simplifyWhiteSpace();
- QRegExp reg("([-]?\\d*\\.?\\d+(?:e[-]?\\d+)?)");
+ TQRegExp reg("([-]?\\d*\\.?\\d+(?:e[-]?\\d+)?)");
int pos = 0;
- QStringList params;
+ TQStringList params;
while(pos >= 0)
{
@@ -215,9 +215,9 @@ void SVGHelperImpl::parseTransformAttribute(SVGTransformListImpl *list, const QS
}
/// convert from user space to "real" pixels on rendering area
-QRect SVGHelperImpl::fromUserspace(SVGElementImpl *obj, const QRect &r)
+TQRect SVGHelperImpl::fromUserspace(SVGElementImpl *obj, const TQRect &r)
{
- QRect sr;
+ TQRect sr;
SVGLocatableImpl *locate = dynamic_cast<SVGLocatableImpl *>(obj);
diff --git a/ksvg/impl/SVGHelperImpl.h b/ksvg/impl/SVGHelperImpl.h
index e8bbdb39..86edbf66 100644
--- a/ksvg/impl/SVGHelperImpl.h
+++ b/ksvg/impl/SVGHelperImpl.h
@@ -30,8 +30,8 @@
#include "ksvg_lookup.h"
-class QRect;
-class QString;
+class TQRect;
+class TQString;
namespace KSVG
{
@@ -47,7 +47,7 @@ public:
// Dynamic attribute updating
template<class T>
- static void applyContainer(T *obj, int token, const QString &value)
+ static void applyContainer(T *obj, int token, const TQString &value)
{
SVGElementImpl *element = dynamic_cast<SVGElementImpl *>(obj);
if(!element || !element->hasChildNodes())
@@ -67,18 +67,18 @@ public:
static void copyAttributes(SVGElementImpl *src, SVGElementImpl *dst);
// SVGAnimatedLengthList
- static void parseLengthList(SVGAnimatedLengthListImpl *list, const QString &lengths, LengthMode mode = LENGTHMODE_UNKNOWN, SVGElementImpl *object = 0);
+ static void parseLengthList(SVGAnimatedLengthListImpl *list, const TQString &lengths, LengthMode mode = LENGTHMODE_UNKNOWN, SVGElementImpl *object = 0);
// SVGStringList
- static void parseList(SVGStringListImpl *list, char seperator, const QString &data);
- static void parseCommaSeperatedList(SVGStringListImpl *list, const QString &data);
- static void parseSemicolonSeperatedList(SVGStringListImpl *list, const QString &data);
+ static void parseList(SVGStringListImpl *list, char seperator, const TQString &data);
+ static void parseCommaSeperatedList(SVGStringListImpl *list, const TQString &data);
+ static void parseSemicolonSeperatedList(SVGStringListImpl *list, const TQString &data);
// SVGTransformList
- static void parseTransformAttribute(SVGTransformListImpl *list, const QString &transform);
+ static void parseTransformAttribute(SVGTransformListImpl *list, const TQString &transform);
// Tools
- static QRect fromUserspace(SVGElementImpl *, const QRect &);
+ static TQRect fromUserspace(SVGElementImpl *, const TQRect &);
};
}
diff --git a/ksvg/impl/SVGImageElementImpl.cc b/ksvg/impl/SVGImageElementImpl.cc
index 608dbda5..49f48e7d 100644
--- a/ksvg/impl/SVGImageElementImpl.cc
+++ b/ksvg/impl/SVGImageElementImpl.cc
@@ -18,8 +18,8 @@
Boston, MA 02110-1301, USA.
*/
-#include <qimage.h>
-#include <qtimer.h>
+#include <tqimage.h>
+#include <tqtimer.h>
#include <kdebug.h>
@@ -51,7 +51,7 @@ using namespace KSVG;
#include "ksvg_bridge.h"
#include "ksvg_ecma.h"
-SVGImageElementImpl::SVGImageElementImpl(DOM::ElementImpl *impl) : QObject(), SVGShapeImpl(impl), SVGURIReferenceImpl(), SVGTestsImpl(), SVGLangSpaceImpl(), SVGExternalResourcesRequiredImpl(), SVGStylableImpl(this), SVGTransformableImpl()
+SVGImageElementImpl::SVGImageElementImpl(DOM::ElementImpl *impl) : TQObject(), SVGShapeImpl(impl), SVGURIReferenceImpl(), SVGTestsImpl(), SVGLangSpaceImpl(), SVGExternalResourcesRequiredImpl(), SVGStylableImpl(this), SVGTransformableImpl()
{
KSVG_EMPTY_FLAGS
@@ -240,7 +240,7 @@ void SVGImageElementImpl::setAttributes()
}
}
-void SVGImageElementImpl::slotParsingFinished(bool error, const QString &errorDesc)
+void SVGImageElementImpl::slotParsingFinished(bool error, const TQString &errorDesc)
{
if(error)
kdDebug(26003) << "Finished with error : " << errorDesc << endl;
@@ -273,8 +273,8 @@ void SVGImageElementImpl::createItem(KSVGCanvas *c)
m_doc->ref();
m_doc->attach(c);
- connect(m_doc, SIGNAL(finishedParsing(bool, const QString &)), this, SLOT(slotParsingFinished(bool, const QString &)));
- connect(m_doc, SIGNAL(finishedLoading()), this, SLOT(slotLoadingFinished()));
+ connect(m_doc, TQT_SIGNAL(finishedParsing(bool, const TQString &)), this, TQT_SLOT(slotParsingFinished(bool, const TQString &)));
+ connect(m_doc, TQT_SIGNAL(finishedLoading()), this, TQT_SLOT(slotLoadingFinished()));
KURL file;
@@ -320,12 +320,12 @@ void SVGImageElementImpl::removeItem(KSVGCanvas *c)
void SVGImageElementImpl::setupSVGElement(SVGSVGElementImpl *svg)
{
// Set up the root svg for an svg image.
- svg->setAttributeInternal("x", QString("%1").arg(x()->baseVal()->value()));
- svg->setAttributeInternal("y", QString("%1").arg(y()->baseVal()->value()));
- svg->setAttributeInternal("width", QString("%1").arg(width()->baseVal()->value()));
- svg->setAttributeInternal("height", QString("%1").arg(height()->baseVal()->value()));
+ svg->setAttributeInternal("x", TQString("%1").arg(x()->baseVal()->value()));
+ svg->setAttributeInternal("y", TQString("%1").arg(y()->baseVal()->value()));
+ svg->setAttributeInternal("width", TQString("%1").arg(width()->baseVal()->value()));
+ svg->setAttributeInternal("height", TQString("%1").arg(height()->baseVal()->value()));
- QString par = getAttribute("preserveAspectRatio").string().stripWhiteSpace();
+ TQString par = getAttribute("preserveAspectRatio").string().stripWhiteSpace();
if(par.startsWith("defer"))
{
@@ -358,7 +358,7 @@ void SVGImageElementImpl::onScreenCTMUpdated()
}
}
-bool SVGImageElementImpl::prepareMouseEvent(const QPoint &p, const QPoint &, SVGMouseEventImpl *mev)
+bool SVGImageElementImpl::prepareMouseEvent(const TQPoint &p, const TQPoint &, SVGMouseEventImpl *mev)
{
// TODO : pointer-events should be stored here, not in SVGStylableImpl.
SVGStylableImpl *style = dynamic_cast<SVGStylableImpl *>(this);
@@ -390,7 +390,7 @@ bool SVGImageElementImpl::prepareMouseEvent(const QPoint &p, const QPoint &, SVG
return false;
}
-void SVGImageElementImpl::setImage(QImage *image)
+void SVGImageElementImpl::setImage(TQImage *image)
{
m_image = image;
@@ -416,7 +416,7 @@ void SVGImageElementImpl::setImage(QImage *image)
ownerDoc()->notifyImageLoaded(this);
}
-QImage SVGImageElementImpl::scaledImage()
+TQImage SVGImageElementImpl::scaledImage()
{
SVGMatrixImpl *matrix = imageMatrix();
double sx, sy;
@@ -424,7 +424,7 @@ QImage SVGImageElementImpl::scaledImage()
matrix->removeScale(&sx, &sy);
matrix->deref();
- QImage img;
+ TQImage img;
if(sx != 1 || sy != 1)
{
@@ -488,7 +488,7 @@ KSVGPolygon SVGImageElementImpl::clippingShape()
return p;
}
-QString SVGImageElementImpl::fileName() const
+TQString SVGImageElementImpl::fileName() const
{
return href()->baseVal().string();
}
diff --git a/ksvg/impl/SVGImageElementImpl.h b/ksvg/impl/SVGImageElementImpl.h
index 35ae161f..922ef3f8 100644
--- a/ksvg/impl/SVGImageElementImpl.h
+++ b/ksvg/impl/SVGImageElementImpl.h
@@ -21,7 +21,7 @@
#ifndef SVGImageElementImpl_H
#define SVGImageElementImpl_H
-#include <qobject.h>
+#include <tqobject.h>
#include "ksvg_lookup.h"
@@ -42,7 +42,7 @@ class SVGSVGElementImpl;
class SVGAnimatedLengthImpl;
class SVGColorProfileElementImpl;
class SVGAnimatedPreserveAspectRatioImpl;
-class SVGImageElementImpl : public QObject,
+class SVGImageElementImpl : public TQObject,
public SVGShapeImpl,
public SVGURIReferenceImpl,
public SVGTestsImpl,
@@ -67,12 +67,12 @@ public:
virtual void setAttributes();
- virtual bool prepareMouseEvent(const QPoint &p, const QPoint &a, SVGMouseEventImpl *mev);
+ virtual bool prepareMouseEvent(const TQPoint &p, const TQPoint &a, SVGMouseEventImpl *mev);
- void setImage(QImage *image);
- QImage *image() { return m_image; }
+ void setImage(TQImage *image);
+ TQImage *image() { return m_image; }
- QImage scaledImage();
+ TQImage scaledImage();
SVGMatrixImpl *imageMatrix();
SVGMatrixImpl *scaledImageMatrix();
@@ -81,7 +81,7 @@ public:
void applyColorProfile();
static void applyColorProfile(SVGColorProfileElementImpl *profile, SVGImageElementImpl *image);
- QString fileName() const;
+ TQString fileName() const;
virtual SVGRectImpl *getBBox();
@@ -93,7 +93,7 @@ public:
void setupSVGElement(SVGSVGElementImpl *svg);
private slots:
- void slotParsingFinished(bool error, const QString &errorDesc);
+ void slotParsingFinished(bool error, const TQString &errorDesc);
void slotLoadingFinished();
private:
@@ -102,7 +102,7 @@ private:
SVGAnimatedLengthImpl *m_width;
SVGAnimatedLengthImpl *m_height;
- QImage *m_image;
+ TQImage *m_image;
bool m_colorProfileApplied;
SVGAnimatedPreserveAspectRatioImpl *m_preserveAspectRatio;
@@ -127,7 +127,7 @@ public:
struct ImageStreamMap
{
- QByteArray *data;
+ TQByteArray *data;
SVGImageElementImpl *imageElement;
};
diff --git a/ksvg/impl/SVGLangSpaceImpl.cc b/ksvg/impl/SVGLangSpaceImpl.cc
index 0eaada47..92919698 100644
--- a/ksvg/impl/SVGLangSpaceImpl.cc
+++ b/ksvg/impl/SVGLangSpaceImpl.cc
@@ -59,16 +59,16 @@ DOM::DOMString SVGLangSpaceImpl::xmlspace() const
return m_xmlspace;
}
-QString SVGLangSpaceImpl::handleText(const QString &data) const
+TQString SVGLangSpaceImpl::handleText(const TQString &data) const
{
- QString result = data;
+ TQString result = data;
if(xmlspace() == "preserve")
{
// Spec: What to do here?
// It will convert all newline and tab characters into space characters
- result.replace("\n\r", QString(" "));
- result.replace("\r\n", QString(" "));
+ result.replace("\n\r", TQString(" "));
+ result.replace("\r\n", TQString(" "));
result.replace('\t', ' ');
}
else if(xmlspace() == "default")
@@ -78,8 +78,8 @@ QString SVGLangSpaceImpl::handleText(const QString &data) const
// Then it will convert all tab characters into space characters (simplifyWhiteSpace)
// Then, it will strip off all leading and trailing space characters (stripWhiteSpace)
// Then, all contiguous space characters will be consolidated. (simplifyWhiteSpace)
- result.replace('\n', QString::null);
- result.replace('\r', QString::null);
+ result.replace('\n', TQString::null);
+ result.replace('\r', TQString::null);
result = result.stripWhiteSpace().simplifyWhiteSpace();
}
diff --git a/ksvg/impl/SVGLangSpaceImpl.h b/ksvg/impl/SVGLangSpaceImpl.h
index 4a8c199a..099884dc 100644
--- a/ksvg/impl/SVGLangSpaceImpl.h
+++ b/ksvg/impl/SVGLangSpaceImpl.h
@@ -40,7 +40,7 @@ public:
void setXmlspace(const DOM::DOMString &xmlspace);
DOM::DOMString xmlspace() const;
- QString handleText(const QString &data) const;
+ TQString handleText(const TQString &data) const;
private:
DOM::DOMString m_xmllang;
diff --git a/ksvg/impl/SVGLengthImpl.cc b/ksvg/impl/SVGLengthImpl.cc
index 46529022..a8c9080c 100644
--- a/ksvg/impl/SVGLengthImpl.cc
+++ b/ksvg/impl/SVGLengthImpl.cc
@@ -20,10 +20,10 @@
#include <kdebug.h>
-#include <qfont.h>
-#include <qregexp.h>
-#include <qwidget.h>
-#include <qpaintdevicemetrics.h>
+#include <tqfont.h>
+#include <tqregexp.h>
+#include <tqwidget.h>
+#include <tqpaintdevicemetrics.h>
#include "SVGLength.h"
@@ -48,7 +48,7 @@ using namespace KSVG;
#include "ksvg_cacheimpl.h"
// keep track of textual description of the unit type
-QString UnitText[] =
+TQString UnitText[] =
{
"", "", "%", "em", "ex", "px", "cm", "mm", "in", "pt", "pc"
};
@@ -153,7 +153,7 @@ void SVGLengthImpl::setValueAsString(const DOM::DOMString &valueAsString)
DOM::DOMString SVGLengthImpl::valueAsString() const
{
- DOM::DOMString valueAsString = QString::number(m_valueInSpecifiedUnits);
+ DOM::DOMString valueAsString = TQString::number(m_valueInSpecifiedUnits);
valueAsString += UnitText[m_unitType];
return valueAsString;
}
@@ -209,7 +209,7 @@ bool SVGLengthImpl::getValFromPx()
return true;
}
-void SVGLengthImpl::convertStringToPx(QString s)
+void SVGLengthImpl::convertStringToPx(TQString s)
{
if(s.isEmpty())
return;
@@ -289,7 +289,7 @@ void SVGLengthImpl::convertNumToPx()
// Look up font-size in a SAFE way, because at this place
// processStyle() has NOT yet been called, so we need
// a different solution (Niko)
- QString useFont = "Arial";
+ TQString useFont = "Arial";
double useSize = 12;
if(sizeLocal)
@@ -307,10 +307,10 @@ void SVGLengthImpl::convertNumToPx()
else
{
// Easiest way, use qfont (Niko)
- QFont font(useFont);
+ TQFont font(useFont);
font.setPixelSize(static_cast<int>(useSize));
- QFontMetrics fm(font);
+ TQFontMetrics fm(font);
m_value = m_valueInSpecifiedUnits * fm.boundingRect('x').height();
}
}
@@ -318,7 +318,7 @@ void SVGLengthImpl::convertNumToPx()
};
}
-void SVGLengthImpl::convertPercentageToFloat(const QString &perc, float &result)
+void SVGLengthImpl::convertPercentageToFloat(const TQString &perc, float &result)
{
// TODO : more error checking ?
if(perc.endsWith("%"))
@@ -327,12 +327,12 @@ void SVGLengthImpl::convertPercentageToFloat(const QString &perc, float &result)
result = perc.toFloat();
}
-QString SVGLengthImpl::convertValToPercentage(const QString &val, float benchmark)
+TQString SVGLengthImpl::convertValToPercentage(const TQString &val, float benchmark)
{
if(val.endsWith("%"))
return val;
- QString result;
+ TQString result;
float temp = val.toFloat();
temp = (temp / benchmark) * 100.0;
@@ -388,7 +388,7 @@ float SVGLengthImpl::percentageOfViewport()
if(!m_context->ownerDoc()->canvas()) // Happens when parsing <svg width="100%"> with printnodetest
return 0.0;
- QPaintDeviceMetrics metrics(m_context->ownerDoc()->canvas()->drawWindow());
+ TQPaintDeviceMetrics metrics(m_context->ownerDoc()->canvas()->drawWindow());
if(m_mode == LENGTHMODE_WIDTH)
return value * metrics.width();
diff --git a/ksvg/impl/SVGLengthImpl.h b/ksvg/impl/SVGLengthImpl.h
index 5879a091..f1254c25 100644
--- a/ksvg/impl/SVGLengthImpl.h
+++ b/ksvg/impl/SVGLengthImpl.h
@@ -64,7 +64,7 @@ public:
operator float();
- static void convertPercentageToFloat(const QString &perc, float &result);
+ static void convertPercentageToFloat(const TQString &perc, float &result);
// This method converts the value val to percentage notation ("xxx%").
// If the value string ends with the percentage sign it is returned,
@@ -72,7 +72,7 @@ public:
// for benchmark 1.0. This method should be useful in contexts that
// know the values should be in percentages up front, like bbox
// calculations.
- static QString convertValToPercentage(const QString &val, float benchmark = 1.0);
+ static TQString convertValToPercentage(const TQString &val, float benchmark = 1.0);
SVGElementImpl *context() const;
void setContext(SVGElementImpl *context);
@@ -84,7 +84,7 @@ private:
float percentageOfViewport();
- void convertStringToPx(QString s);
+ void convertStringToPx(TQString s);
void convertNumToPx();
bool getValFromPx();
diff --git a/ksvg/impl/SVGLinearGradientElementImpl.cc b/ksvg/impl/SVGLinearGradientElementImpl.cc
index 54c97f01..c08f1417 100644
--- a/ksvg/impl/SVGLinearGradientElementImpl.cc
+++ b/ksvg/impl/SVGLinearGradientElementImpl.cc
@@ -177,12 +177,12 @@ void SVGLinearGradientElementImpl::setAttributes()
KSVG_SET_ALT_ATTRIBUTE(Y2, "0")
}
-QMap<QString, DOM::DOMString> SVGLinearGradientElementImpl::gradientAttributes()
+TQMap<TQString, DOM::DOMString> SVGLinearGradientElementImpl::gradientAttributes()
{
setAttributes();
- QMap<QString, DOM::DOMString> gradAttributes;
- QDictIterator<DOM::DOMString> it(attributes());
+ TQMap<TQString, DOM::DOMString> gradAttributes;
+ TQDictIterator<DOM::DOMString> it(attributes());
for(; it.current(); ++it)
{
diff --git a/ksvg/impl/SVGLinearGradientElementImpl.h b/ksvg/impl/SVGLinearGradientElementImpl.h
index a230a0fe..87744708 100644
--- a/ksvg/impl/SVGLinearGradientElementImpl.h
+++ b/ksvg/impl/SVGLinearGradientElementImpl.h
@@ -42,7 +42,7 @@ public:
virtual void setAttributes();
- virtual QMap<QString, DOM::DOMString> gradientAttributes();
+ virtual TQMap<TQString, DOM::DOMString> gradientAttributes();
private:
SVGAnimatedLengthImpl *m_x1;
diff --git a/ksvg/impl/SVGList.h b/ksvg/impl/SVGList.h
index dfa07dd0..fdf13bd9 100644
--- a/ksvg/impl/SVGList.h
+++ b/ksvg/impl/SVGList.h
@@ -24,7 +24,7 @@
#include "ksvg_bridge.h"
#include "ksvg_lookup.h"
#include "ksvg_scriptinterpreter.h"
-#include <qptrlist.h>
+#include <tqptrlist.h>
#include <dom/dom_misc.h>
namespace KSVG
@@ -162,7 +162,7 @@ public:
}
private:
- QPtrList<T> m_impl;
+ TQPtrList<T> m_impl;
};
}
diff --git a/ksvg/impl/SVGMarkerElementImpl.cc b/ksvg/impl/SVGMarkerElementImpl.cc
index 0fc1d263..a621b47f 100644
--- a/ksvg/impl/SVGMarkerElementImpl.cc
+++ b/ksvg/impl/SVGMarkerElementImpl.cc
@@ -356,7 +356,7 @@ void SVGMarkerElementImpl::putValueProperty(ExecState *exec, int token, const Va
break;
case Orient:
{
- QString param = value.toString(exec).qstring();
+ TQString param = value.toString(exec).qstring();
if(param == "auto")
orientType()->setBaseVal(SVG_MARKER_ORIENT_AUTO);
diff --git a/ksvg/impl/SVGMaskElementImpl.cc b/ksvg/impl/SVGMaskElementImpl.cc
index 5cd2151e..d0f90974 100644
--- a/ksvg/impl/SVGMaskElementImpl.cc
+++ b/ksvg/impl/SVGMaskElementImpl.cc
@@ -21,7 +21,7 @@
#include <cfloat>
#include <kdebug.h>
-#include <qimage.h>
+#include <tqimage.h>
#include "SVGMaskElement.h"
@@ -336,12 +336,12 @@ SVGMaskElementImpl::Mask SVGMaskElementImpl::createMask(SVGShapeImpl *referencin
{
// Note: r and b reversed
- //QImage maskImage(reinterpret_cast<unsigned char *>(imageBits), imageWidth, imageHeight, 32, 0, 0, QImage::IgnoreEndian);
+ //TQImage maskImage(reinterpret_cast<unsigned char *>(imageBits), imageWidth, imageHeight, 32, 0, 0, TQImage::IgnoreEndian);
//maskImage.setAlphaBuffer(true);
//maskImage.save("mask.png", "PNG");
}
- QByteArray maskData(imageWidth * imageHeight);
+ TQByteArray maskData(imageWidth * imageHeight);
const double epsilon = DBL_EPSILON;
// Convert the rgba image into an 8-bit mask, according to the specs.
@@ -390,7 +390,7 @@ SVGMaskElementImpl::Mask SVGMaskElementImpl::createMask(SVGShapeImpl *referencin
// The screenToMask matrix is calculated each time the mask is used so we don't
// need to set it here.
- QWMatrix tempMatrix;
+ TQWMatrix tempMatrix;
return Mask(maskData, tempMatrix, imageWidth, imageHeight);
}
@@ -444,7 +444,7 @@ SVGMaskElementImpl::Mask SVGMaskElementImpl::createMask(SVGShapeImpl *referencin
matrix->scaleNonUniform(1 / xScale, 1 / yScale);
- QWMatrix screenToMask = matrix->qmatrix().invert();
+ TQWMatrix screenToMask = matrix->qmatrix().invert();
matrix->deref();
mask.setScreenToMask(screenToMask);
@@ -453,9 +453,9 @@ SVGMaskElementImpl::Mask SVGMaskElementImpl::createMask(SVGShapeImpl *referencin
return mask;
}
-QByteArray SVGMaskElementImpl::maskRectangle(SVGShapeImpl *shape, const QRect& screenRectangle)
+TQByteArray SVGMaskElementImpl::maskRectangle(SVGShapeImpl *shape, const TQRect& screenRectangle)
{
- QByteArray cumulativeMask;
+ TQByteArray cumulativeMask;
do
{
@@ -475,7 +475,7 @@ QByteArray SVGMaskElementImpl::maskRectangle(SVGShapeImpl *shape, const QRect& s
if(!mask.isEmpty())
{
- QByteArray maskData = mask.rectangle(screenRectangle);
+ TQByteArray maskData = mask.rectangle(screenRectangle);
if(cumulativeMask.size() == 0)
cumulativeMask = maskData;
@@ -514,14 +514,14 @@ QByteArray SVGMaskElementImpl::maskRectangle(SVGShapeImpl *shape, const QRect& s
return cumulativeMask;
}
-SVGMaskElementImpl::Mask::Mask(const QByteArray& mask, const QWMatrix& screenToMask, int width, int height)
+SVGMaskElementImpl::Mask::Mask(const TQByteArray& mask, const TQWMatrix& screenToMask, int width, int height)
: m_width(width), m_height(height), m_mask(mask), m_screenToMask(screenToMask)
{
}
-QByteArray SVGMaskElementImpl::Mask::rectangle(int screenX, int screenY, int width, int height)
+TQByteArray SVGMaskElementImpl::Mask::rectangle(int screenX, int screenY, int width, int height)
{
- QByteArray rect(width * height);
+ TQByteArray rect(width * height);
for(int x = 0; x < width; x++)
{
@@ -534,7 +534,7 @@ QByteArray SVGMaskElementImpl::Mask::rectangle(int screenX, int screenY, int wid
return rect;
}
-QByteArray SVGMaskElementImpl::Mask::rectangle(const QRect& rect)
+TQByteArray SVGMaskElementImpl::Mask::rectangle(const TQRect& rect)
{
return rectangle(rect.x(), rect.y(), rect.width(), rect.height());
}
diff --git a/ksvg/impl/SVGMaskElementImpl.h b/ksvg/impl/SVGMaskElementImpl.h
index cdd1c125..2a96967c 100644
--- a/ksvg/impl/SVGMaskElementImpl.h
+++ b/ksvg/impl/SVGMaskElementImpl.h
@@ -21,7 +21,7 @@
#ifndef SVGMaskElementImpl_H
#define SVGMaskElementImpl_H
-#include <qwmatrix.h>
+#include <tqwmatrix.h>
#include "SVGTestsImpl.h"
#include "SVGBBoxTarget.h"
@@ -56,20 +56,20 @@ public:
{
public:
Mask() : m_width(0), m_height(0) {}
- Mask(const QByteArray& mask, const QWMatrix& screenToMask, int width, int height);
+ Mask(const TQByteArray& mask, const TQWMatrix& screenToMask, int width, int height);
~Mask() {}
bool isEmpty() const { return m_width == 0; }
unsigned char value(int screenX, int screenY) const;
- QByteArray rectangle(int screenX, int screenY, int width, int height);
- QByteArray rectangle(const QRect& rect);
- void setScreenToMask(const QWMatrix& matrix) { m_screenToMask = matrix; }
+ TQByteArray rectangle(int screenX, int screenY, int width, int height);
+ TQByteArray rectangle(const TQRect& rect);
+ void setScreenToMask(const TQWMatrix& matrix) { m_screenToMask = matrix; }
private:
int m_width;
int m_height;
- QByteArray m_mask;
- QWMatrix m_screenToMask;
+ TQByteArray m_mask;
+ TQWMatrix m_screenToMask;
};
SVGMaskElementImpl(DOM::ElementImpl *);
@@ -92,7 +92,7 @@ public:
// Compute the mask on a given shape, taking into account all masks defined
// on the shape's ancestors. This is a workaround for us not having a buffer
// for container elements, so we can't mask containers directly.
- static QByteArray maskRectangle(SVGShapeImpl *shape, const QRect& screenRectangle);
+ static TQByteArray maskRectangle(SVGShapeImpl *shape, const TQRect& screenRectangle);
private:
class CacheKey
diff --git a/ksvg/impl/SVGMatrixImpl.cc b/ksvg/impl/SVGMatrixImpl.cc
index 81f14f66..0210b8f7 100644
--- a/ksvg/impl/SVGMatrixImpl.cc
+++ b/ksvg/impl/SVGMatrixImpl.cc
@@ -37,7 +37,7 @@ SVGMatrixImpl::SVGMatrixImpl()
KSVG_EMPTY_FLAGS
}
-SVGMatrixImpl::SVGMatrixImpl(QWMatrix mat)
+SVGMatrixImpl::SVGMatrixImpl(TQWMatrix mat)
{
m_mat = mat;
}
@@ -118,7 +118,7 @@ void SVGMatrixImpl::copy(const SVGMatrixImpl *other)
SVGMatrixImpl *SVGMatrixImpl::postMultiply(const SVGMatrixImpl *secondMatrix)
{
- QWMatrix temp(secondMatrix->a(), secondMatrix->b(), secondMatrix->c(), secondMatrix->d(), secondMatrix->e(), secondMatrix->f());
+ TQWMatrix temp(secondMatrix->a(), secondMatrix->b(), secondMatrix->c(), secondMatrix->d(), secondMatrix->e(), secondMatrix->f());
m_mat *= temp;
return this;
}
@@ -132,7 +132,7 @@ SVGMatrixImpl *SVGMatrixImpl::inverse()
SVGMatrixImpl *SVGMatrixImpl::postTranslate(const double &x, const double &y)
{
// Could optimise these.
- QWMatrix temp;
+ TQWMatrix temp;
temp.translate(x, y);
m_mat *= temp;
return this;
@@ -140,7 +140,7 @@ SVGMatrixImpl *SVGMatrixImpl::postTranslate(const double &x, const double &y)
SVGMatrixImpl *SVGMatrixImpl::postScale(const double &scaleFactor)
{
- QWMatrix temp;
+ TQWMatrix temp;
temp.scale(scaleFactor, scaleFactor);
m_mat *= temp;
return this;
@@ -148,7 +148,7 @@ SVGMatrixImpl *SVGMatrixImpl::postScale(const double &scaleFactor)
SVGMatrixImpl *SVGMatrixImpl::postScaleNonUniform(const double &scaleFactorX, const double &scaleFactorY)
{
- QWMatrix temp;
+ TQWMatrix temp;
temp.scale(scaleFactorX, scaleFactorY);
m_mat *= temp;
return this;
@@ -156,7 +156,7 @@ SVGMatrixImpl *SVGMatrixImpl::postScaleNonUniform(const double &scaleFactorX, co
SVGMatrixImpl *SVGMatrixImpl::postRotate(const double &angle)
{
- QWMatrix temp;
+ TQWMatrix temp;
temp.rotate(angle);
m_mat *= temp;
return this;
@@ -164,7 +164,7 @@ SVGMatrixImpl *SVGMatrixImpl::postRotate(const double &angle)
SVGMatrixImpl *SVGMatrixImpl::postRotateFromVector(const double &x, const double &y)
{
- QWMatrix temp;
+ TQWMatrix temp;
temp.rotate(SVGAngleImpl::todeg(atan2(y, x)));
m_mat *= temp;
return this;
@@ -172,21 +172,21 @@ SVGMatrixImpl *SVGMatrixImpl::postRotateFromVector(const double &x, const double
SVGMatrixImpl *SVGMatrixImpl::postFlipX()
{
- QWMatrix temp(-1.0F, 0.0F, 0.0F, 1.0F, 0.0F, 0.0F);
+ TQWMatrix temp(-1.0F, 0.0F, 0.0F, 1.0F, 0.0F, 0.0F);
m_mat *= temp;
return this;
}
SVGMatrixImpl *SVGMatrixImpl::postFlipY()
{
- QWMatrix temp(1.0F, 0.0F, 0.0F, -1.0F, 0.0F, 0.0F);
+ TQWMatrix temp(1.0F, 0.0F, 0.0F, -1.0F, 0.0F, 0.0F);
m_mat *= temp;
return this;
}
SVGMatrixImpl *SVGMatrixImpl::postSkewX(const double &angle)
{
- QWMatrix temp;
+ TQWMatrix temp;
temp.shear(tan(SVGAngleImpl::torad(angle)), 0.0F);
m_mat *= temp;
return this;
@@ -194,7 +194,7 @@ SVGMatrixImpl *SVGMatrixImpl::postSkewX(const double &angle)
SVGMatrixImpl *SVGMatrixImpl::postSkewY(const double &angle)
{
- QWMatrix temp;
+ TQWMatrix temp;
temp.shear(0.0F, tan(SVGAngleImpl::torad(angle)));
m_mat *= temp;
return this;
@@ -202,7 +202,7 @@ SVGMatrixImpl *SVGMatrixImpl::postSkewY(const double &angle)
SVGMatrixImpl *SVGMatrixImpl::multiply(const SVGMatrixImpl *secondMatrix)
{
- QWMatrix temp(secondMatrix->a(), secondMatrix->b(), secondMatrix->c(), secondMatrix->d(), secondMatrix->e(), secondMatrix->f());
+ TQWMatrix temp(secondMatrix->a(), secondMatrix->b(), secondMatrix->c(), secondMatrix->d(), secondMatrix->e(), secondMatrix->f());
temp *= m_mat;
m_mat = temp;
return this;
@@ -262,17 +262,17 @@ SVGMatrixImpl *SVGMatrixImpl::skewY(const double &angle)
return this;
}
-void SVGMatrixImpl::setMatrix(QWMatrix mat)
+void SVGMatrixImpl::setMatrix(TQWMatrix mat)
{
m_mat = mat;
}
-QWMatrix &SVGMatrixImpl::qmatrix()
+TQWMatrix &SVGMatrixImpl::qmatrix()
{
return m_mat;
}
-const QWMatrix &SVGMatrixImpl::qmatrix() const
+const TQWMatrix &SVGMatrixImpl::qmatrix() const
{
return m_mat;
}
@@ -315,7 +315,7 @@ KSVGPolygon SVGMatrixImpl::map(const KSVGPolygon& polygon) const
KSVGPolygon SVGMatrixImpl::inverseMap(const KSVGPolygon& polygon) const
{
- QWMatrix inverse = m_mat.invert();
+ TQWMatrix inverse = m_mat.invert();
KSVGPolygon mapped;
for(unsigned int i = 0; i < polygon.numPoints(); i++)
diff --git a/ksvg/impl/SVGMatrixImpl.h b/ksvg/impl/SVGMatrixImpl.h
index a5d8edf3..7cf7ed92 100644
--- a/ksvg/impl/SVGMatrixImpl.h
+++ b/ksvg/impl/SVGMatrixImpl.h
@@ -21,7 +21,7 @@
#ifndef SVGMatrixImpl_H
#define SVGMatrixImpl_H
-#include <qwmatrix.h>
+#include <tqwmatrix.h>
#include <dom/dom_misc.h>
@@ -35,7 +35,7 @@ class SVGMatrixImpl : public DOM::DomShared
{
public:
SVGMatrixImpl();
- SVGMatrixImpl(QWMatrix mat);
+ SVGMatrixImpl(TQWMatrix mat);
SVGMatrixImpl(double, double, double, double, double, double);
~SVGMatrixImpl();
@@ -88,8 +88,8 @@ public:
void reset();
// KSVG helper method
- QWMatrix &qmatrix();
- const QWMatrix &qmatrix() const;
+ TQWMatrix &qmatrix();
+ const TQWMatrix &qmatrix() const;
// Determine the scaling component of the matrix and factor it out. After
// this operation, the matrix has x and y scale of one.
@@ -99,8 +99,8 @@ public:
KSVGPolygon inverseMap(const KSVGPolygon& polygon) const;
private:
- void setMatrix(QWMatrix mat);
- QWMatrix m_mat;
+ void setMatrix(TQWMatrix mat);
+ TQWMatrix m_mat;
public:
KSVG_GET
diff --git a/ksvg/impl/SVGPaintImpl.cc b/ksvg/impl/SVGPaintImpl.cc
index c1818892..aa52811a 100644
--- a/ksvg/impl/SVGPaintImpl.cc
+++ b/ksvg/impl/SVGPaintImpl.cc
@@ -77,7 +77,7 @@ void SVGPaintImpl::setPaint(unsigned short paintType, const DOM::DOMString &/*ur
m_paintType = paintType;
}
-void SVGPaintImpl::setRGBColor(QColor color)
+void SVGPaintImpl::setRGBColor(TQColor color)
{
m_paintType = SVG_PAINTTYPE_RGBCOLOR;
SVGColorImpl::setRGBColor(color);
diff --git a/ksvg/impl/SVGPaintImpl.h b/ksvg/impl/SVGPaintImpl.h
index f2aa0691..03cb2153 100644
--- a/ksvg/impl/SVGPaintImpl.h
+++ b/ksvg/impl/SVGPaintImpl.h
@@ -46,7 +46,7 @@ public:
virtual void setRGBColor(const DOM::DOMString &rgbColor);
virtual void setRGBColor(int r, int g, int b);
- virtual void setRGBColor(QColor color);
+ virtual void setRGBColor(TQColor color);
virtual void setRGBColorICCColor(const DOM::DOMString &rgbColor, const DOM::DOMString &iccColor);
virtual void setColor(unsigned short colorType, const DOM::DOMString &rgbColor, const DOM::DOMString &iccColor);
diff --git a/ksvg/impl/SVGPaintServerImpl.cc b/ksvg/impl/SVGPaintServerImpl.cc
index b3275231..e87882b1 100644
--- a/ksvg/impl/SVGPaintServerImpl.cc
+++ b/ksvg/impl/SVGPaintServerImpl.cc
@@ -35,7 +35,7 @@ SVGPaintServerImpl::~SVGPaintServerImpl()
{
}
-CanvasPaintServer *SVGPaintServerImpl::paintServer(SVGDocumentImpl *doc, const QString& id)
+CanvasPaintServer *SVGPaintServerImpl::paintServer(SVGDocumentImpl *doc, const TQString& id)
{
CanvasPaintServer *pserver = 0;
SVGElementImpl *element = doc->rootElement()->getElementById(id);
diff --git a/ksvg/impl/SVGPaintServerImpl.h b/ksvg/impl/SVGPaintServerImpl.h
index df276758..d9f4a898 100644
--- a/ksvg/impl/SVGPaintServerImpl.h
+++ b/ksvg/impl/SVGPaintServerImpl.h
@@ -36,7 +36,7 @@ public:
CanvasPaintServer *paintServer() { return m_paintServer; }
- static CanvasPaintServer *paintServer(SVGDocumentImpl *doc, const QString& id);
+ static CanvasPaintServer *paintServer(SVGDocumentImpl *doc, const TQString& id);
protected:
CanvasPaintServer *m_paintServer;
diff --git a/ksvg/impl/SVGPathElementImpl.cc b/ksvg/impl/SVGPathElementImpl.cc
index f34600b8..506ad01a 100644
--- a/ksvg/impl/SVGPathElementImpl.cc
+++ b/ksvg/impl/SVGPathElementImpl.cc
@@ -446,7 +446,7 @@ Value SVGPathElementImpl::getValueProperty(ExecState *exec, int token) const
case D:
// if(!attributeMode)
{
- QString d;
+ TQString d;
unsigned int nrSegs = pathSegList()->numberOfItems();
SVGPathSegImpl *curseg = 0;
for(unsigned int i = 0; i < nrSegs; i++)
@@ -475,7 +475,7 @@ void SVGPathElementImpl::putValueProperty(ExecState *exec, int token, const Valu
case D:
{
pathSegList()->clear();
- QString d = value.toString(exec).qstring();
+ TQString d = value.toString(exec).qstring();
parseSVG(d, false);
if(hasMarkers())
m_markerData = MarkerData(pathSegList());
@@ -596,7 +596,7 @@ SVGPathElementImpl::MarkerData::MarkerData(SVGPathSegListImpl *path)
double previousCubicX2 = 0;
double previousCubicY2 = 0;
- QValueVector<SegmentData> pathSegmentData(numSegments);
+ TQValueVector<SegmentData> pathSegmentData(numSegments);
for(unsigned int i = 0; i < numSegments; i++)
{
@@ -797,7 +797,7 @@ SVGPathElementImpl::MarkerData::MarkerData(SVGPathSegListImpl *path)
}
}
-bool SVGPathElementImpl::MarkerData::getStartSlope(QValueVector<SegmentData> segments, unsigned int i, double *pStartSlope)
+bool SVGPathElementImpl::MarkerData::getStartSlope(TQValueVector<SegmentData> segments, unsigned int i, double *pStartSlope)
{
if(i > segments.count() - 1 || segments[i].type == PATHSEG_MOVETO_ABS || segments[i].type == PATHSEG_MOVETO_REL)
return false;
@@ -831,7 +831,7 @@ bool SVGPathElementImpl::MarkerData::getStartSlope(QValueVector<SegmentData> seg
}
}
-bool SVGPathElementImpl::MarkerData::getEndSlope(QValueVector<SegmentData> segments, unsigned int i, double *pEndSlope)
+bool SVGPathElementImpl::MarkerData::getEndSlope(TQValueVector<SegmentData> segments, unsigned int i, double *pEndSlope)
{
if(i > segments.count() - 1 || segments[i].type == PATHSEG_MOVETO_ABS || segments[i].type == PATHSEG_MOVETO_REL)
return false;
diff --git a/ksvg/impl/SVGPathElementImpl.h b/ksvg/impl/SVGPathElementImpl.h
index a9af56fc..8dda0f8f 100644
--- a/ksvg/impl/SVGPathElementImpl.h
+++ b/ksvg/impl/SVGPathElementImpl.h
@@ -21,7 +21,7 @@
#ifndef SVGPathElementImpl_H
#define SVGPathElementImpl_H
-#include <qvaluevector.h>
+#include <tqvaluevector.h>
#include "svgpathparser.h"
@@ -133,10 +133,10 @@ public:
int type;
};
- static bool getStartSlope(QValueVector<SegmentData> segments, unsigned int i, double *pStartSlope);
- static bool getEndSlope(QValueVector<SegmentData> segments, unsigned int i, double *pEndSlope);
+ static bool getStartSlope(TQValueVector<SegmentData> segments, unsigned int i, double *pStartSlope);
+ static bool getEndSlope(TQValueVector<SegmentData> segments, unsigned int i, double *pEndSlope);
- QValueVector<Marker> m_markers;
+ TQValueVector<Marker> m_markers;
};
MarkerData markerData() const { return m_markerData; }
diff --git a/ksvg/impl/SVGPathSegArcImpl.h b/ksvg/impl/SVGPathSegArcImpl.h
index f0e375d6..d8a1f8f9 100644
--- a/ksvg/impl/SVGPathSegArcImpl.h
+++ b/ksvg/impl/SVGPathSegArcImpl.h
@@ -36,7 +36,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_ARC_ABS; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "A"; }
- virtual QString toString() const { return QString("A %1 %2 %3 %4 %5 %6 %7").arg(m_r1).arg(m_r2).arg(m_angle).arg(m_largeArcFlag).arg(m_sweepFlag).arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("A %1 %2 %3 %4 %5 %6 %7").arg(m_r1).arg(m_r2).arg(m_angle).arg(m_largeArcFlag).arg(m_sweepFlag).arg(m_x).arg(m_y); }
void setX(double x);
double x() const;
@@ -94,7 +94,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_ARC_REL; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "a"; }
- virtual QString toString() const { return QString("a %1 %2 %3 %4 %5 %6 %7").arg(m_r1).arg(m_r2).arg(m_angle).arg(m_largeArcFlag).arg(m_sweepFlag).arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("a %1 %2 %3 %4 %5 %6 %7").arg(m_r1).arg(m_r2).arg(m_angle).arg(m_largeArcFlag).arg(m_sweepFlag).arg(m_x).arg(m_y); }
void setX(double x);
double x() const;
diff --git a/ksvg/impl/SVGPathSegClosePathImpl.h b/ksvg/impl/SVGPathSegClosePathImpl.h
index c4cf63ce..c9c93ca0 100644
--- a/ksvg/impl/SVGPathSegClosePathImpl.h
+++ b/ksvg/impl/SVGPathSegClosePathImpl.h
@@ -36,7 +36,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_CLOSEPATH; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "Z"; }
- virtual QString toString() const { return "Z"; }
+ virtual TQString toString() const { return "Z"; }
void setX(double x) { m_x = x; }
void setY(double y) { m_y = y; }
diff --git a/ksvg/impl/SVGPathSegCurvetoCubicImpl.h b/ksvg/impl/SVGPathSegCurvetoCubicImpl.h
index 8f408f91..83f4de6b 100644
--- a/ksvg/impl/SVGPathSegCurvetoCubicImpl.h
+++ b/ksvg/impl/SVGPathSegCurvetoCubicImpl.h
@@ -36,7 +36,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_CURVETO_CUBIC_ABS; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "C"; }
- virtual QString toString() const { return QString("C %1 %2 %3 %4 %5 %6").arg(m_x1).arg(m_y1).arg(m_x2).arg(m_y2).arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("C %1 %2 %3 %4 %5 %6").arg(m_x1).arg(m_y1).arg(m_x2).arg(m_y2).arg(m_x).arg(m_y); }
void setX(const double &);
double x() const;
@@ -88,7 +88,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_CURVETO_CUBIC_REL; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "c"; }
- virtual QString toString() const { return QString("c %1 %2 %3 %4 %5 %6").arg(m_x1).arg(m_y1).arg(m_x2).arg(m_y2).arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("c %1 %2 %3 %4 %5 %6").arg(m_x1).arg(m_y1).arg(m_x2).arg(m_y2).arg(m_x).arg(m_y); }
void setX(const double &);
double x() const;
diff --git a/ksvg/impl/SVGPathSegCurvetoCubicSmoothImpl.h b/ksvg/impl/SVGPathSegCurvetoCubicSmoothImpl.h
index 0def6514..3bcc8c87 100644
--- a/ksvg/impl/SVGPathSegCurvetoCubicSmoothImpl.h
+++ b/ksvg/impl/SVGPathSegCurvetoCubicSmoothImpl.h
@@ -36,7 +36,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_CURVETO_CUBIC_SMOOTH_ABS; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "S"; }
- virtual QString toString() const { return QString("S %1 %2 %3 %4").arg(m_x2).arg(m_y2).arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("S %1 %2 %3 %4").arg(m_x2).arg(m_y2).arg(m_x).arg(m_y); }
void setX(const double &);
double x() const;
@@ -88,7 +88,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_CURVETO_CUBIC_SMOOTH_REL; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "s"; }
- virtual QString toString() const { return QString("s %1 %2 %3 %4").arg(m_x2).arg(m_y2).arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("s %1 %2 %3 %4").arg(m_x2).arg(m_y2).arg(m_x).arg(m_y); }
void setX(const double &);
double x() const;
diff --git a/ksvg/impl/SVGPathSegCurvetoQuadraticImpl.h b/ksvg/impl/SVGPathSegCurvetoQuadraticImpl.h
index 6fe9ef15..6772605f 100644
--- a/ksvg/impl/SVGPathSegCurvetoQuadraticImpl.h
+++ b/ksvg/impl/SVGPathSegCurvetoQuadraticImpl.h
@@ -36,7 +36,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_CURVETO_QUADRATIC_ABS; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "Q"; }
- virtual QString toString() const { return QString("Q %1 %2 %3 %4").arg(m_x1).arg(m_y1).arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("Q %1 %2 %3 %4").arg(m_x1).arg(m_y1).arg(m_x).arg(m_y); }
void setX(const double &);
double x() const;
@@ -80,7 +80,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_CURVETO_QUADRATIC_REL; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "q"; }
- virtual QString toString() const { return QString("q %1 %2 %3 %4").arg(m_x1).arg(m_y1).arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("q %1 %2 %3 %4").arg(m_x1).arg(m_y1).arg(m_x).arg(m_y); }
void setX(const double &);
double x() const;
diff --git a/ksvg/impl/SVGPathSegCurvetoQuadraticSmoothImpl.h b/ksvg/impl/SVGPathSegCurvetoQuadraticSmoothImpl.h
index dffa3355..6c471bd6 100644
--- a/ksvg/impl/SVGPathSegCurvetoQuadraticSmoothImpl.h
+++ b/ksvg/impl/SVGPathSegCurvetoQuadraticSmoothImpl.h
@@ -36,7 +36,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "T"; }
- virtual QString toString() const { return QString("T %1 %2").arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("T %1 %2").arg(m_x).arg(m_y); }
void setX(const double &);
double x() const;
@@ -80,7 +80,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "t"; }
- virtual QString toString() const { return QString("t %1 %2").arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("t %1 %2").arg(m_x).arg(m_y); }
void setX(const double &);
double x() const;
diff --git a/ksvg/impl/SVGPathSegImpl.h b/ksvg/impl/SVGPathSegImpl.h
index 64d8b5b0..8f07baea 100644
--- a/ksvg/impl/SVGPathSegImpl.h
+++ b/ksvg/impl/SVGPathSegImpl.h
@@ -39,7 +39,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_UNKNOWN; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return ""; }
- virtual QString toString() const { return ""; }
+ virtual TQString toString() const { return ""; }
virtual void getDeltasAndSlopes(double curx, double cury, double *dx, double *dy, double *startSlope, double *endSlope) const;
diff --git a/ksvg/impl/SVGPathSegLinetoHorizontalImpl.h b/ksvg/impl/SVGPathSegLinetoHorizontalImpl.h
index 020d29d7..52355c5d 100644
--- a/ksvg/impl/SVGPathSegLinetoHorizontalImpl.h
+++ b/ksvg/impl/SVGPathSegLinetoHorizontalImpl.h
@@ -36,7 +36,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_LINETO_HORIZONTAL_ABS; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "H"; }
- virtual QString toString() const { return QString("H %1").arg(m_x); }
+ virtual TQString toString() const { return TQString("H %1").arg(m_x); }
void setX(const double &);
double x() const;
@@ -68,7 +68,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_LINETO_HORIZONTAL_REL; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "h"; }
- virtual QString toString() const { return QString("h %1").arg(m_x); }
+ virtual TQString toString() const { return TQString("h %1").arg(m_x); }
void setX(const double &);
double x() const;
diff --git a/ksvg/impl/SVGPathSegLinetoImpl.h b/ksvg/impl/SVGPathSegLinetoImpl.h
index 3e315022..78df51b9 100644
--- a/ksvg/impl/SVGPathSegLinetoImpl.h
+++ b/ksvg/impl/SVGPathSegLinetoImpl.h
@@ -36,7 +36,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_LINETO_ABS; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "L"; }
- virtual QString toString() const { return QString("L %1 %2").arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("L %1 %2").arg(m_x).arg(m_y); }
void setX(const double &);
double x() const;
@@ -72,7 +72,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_LINETO_REL; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "l"; }
- virtual QString toString() const { return QString("l %1 %2").arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("l %1 %2").arg(m_x).arg(m_y); }
void setX(const double &);
double x() const;
diff --git a/ksvg/impl/SVGPathSegLinetoVerticalImpl.h b/ksvg/impl/SVGPathSegLinetoVerticalImpl.h
index c50906d9..1bbf41f4 100644
--- a/ksvg/impl/SVGPathSegLinetoVerticalImpl.h
+++ b/ksvg/impl/SVGPathSegLinetoVerticalImpl.h
@@ -36,7 +36,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_LINETO_VERTICAL_ABS; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "V"; }
- virtual QString toString() const { return QString("V %1").arg(m_y); }
+ virtual TQString toString() const { return TQString("V %1").arg(m_y); }
void setY(const double &);
double y() const;
@@ -68,7 +68,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_LINETO_VERTICAL_REL; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "v"; }
- virtual QString toString() const { return QString("v %1").arg(m_y); }
+ virtual TQString toString() const { return TQString("v %1").arg(m_y); }
void setY(const double &);
double y() const;
diff --git a/ksvg/impl/SVGPathSegMovetoImpl.h b/ksvg/impl/SVGPathSegMovetoImpl.h
index dfbad355..6db95702 100644
--- a/ksvg/impl/SVGPathSegMovetoImpl.h
+++ b/ksvg/impl/SVGPathSegMovetoImpl.h
@@ -36,7 +36,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_MOVETO_ABS; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "M"; }
- virtual QString toString() const { return QString("M %1 %2").arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("M %1 %2").arg(m_x).arg(m_y); }
void setX(const double &);
double x() const;
@@ -72,7 +72,7 @@ public:
virtual unsigned short pathSegType() const { return PATHSEG_MOVETO_REL; }
virtual DOM::DOMString pathSegTypeAsLetter() const { return "m"; }
- virtual QString toString() const { return QString("m %1 %2").arg(m_x).arg(m_y); }
+ virtual TQString toString() const { return TQString("m %1 %2").arg(m_x).arg(m_y); }
void setX(const double &);
double x() const;
diff --git a/ksvg/impl/SVGPatternElementImpl.cc b/ksvg/impl/SVGPatternElementImpl.cc
index 0b591487..24d03239 100644
--- a/ksvg/impl/SVGPatternElementImpl.cc
+++ b/ksvg/impl/SVGPatternElementImpl.cc
@@ -47,7 +47,7 @@ using namespace KSVG;
#include "ksvg_bridge.h"
#include "ksvg_ecma.h"
-QValueList<SVGPatternElementImpl *> SVGPatternElementImpl::m_patternElements;
+TQValueList<SVGPatternElementImpl *> SVGPatternElementImpl::m_patternElements;
SVGPatternElementImpl::SVGPatternElementImpl(DOM::ElementImpl *impl) : SVGElementImpl(impl), SVGURIReferenceImpl(), SVGTestsImpl(), SVGLangSpaceImpl(), SVGExternalResourcesRequiredImpl(), SVGStylableImpl(this), SVGFitToViewBoxImpl(), SVGPaintServerImpl()
{
@@ -293,7 +293,7 @@ void SVGPatternElementImpl::setAttributes()
void SVGPatternElementImpl::flushCachedTiles()
{
- QValueList<SVGPatternElementImpl *>::iterator it;
+ TQValueList<SVGPatternElementImpl *>::iterator it;
for(it = m_patternElements.begin(); it != m_patternElements.end(); it++)
{
@@ -304,11 +304,11 @@ void SVGPatternElementImpl::flushCachedTiles()
}
}
-QImage SVGPatternElementImpl::createTile(SVGShapeImpl *referencingElement, int imageWidth, int imageHeight)
+TQImage SVGPatternElementImpl::createTile(SVGShapeImpl *referencingElement, int imageWidth, int imageHeight)
{
converter()->finalize(referencingElement, ownerSVGElement(), patternUnits()->baseVal());
- QImage image(imageWidth, imageHeight, 32);
+ TQImage image(imageWidth, imageHeight, 32);
image.setAlphaBuffer(true);
if(m_canvas == 0)
@@ -376,15 +376,15 @@ QImage SVGPatternElementImpl::createTile(SVGShapeImpl *referencingElement, int i
if(getOverflow())
{
- QPtrList<CanvasItem> items = m_canvas->allItems();
- QRect allItemsBBox;
+ TQPtrList<CanvasItem> items = m_canvas->allItems();
+ TQRect allItemsBBox;
- QPtrListIterator<CanvasItem> it(items);
+ TQPtrListIterator<CanvasItem> it(items);
CanvasItem *item;
while((item = *it) != 0)
{
- QRect bbox = item->bbox();
+ TQRect bbox = item->bbox();
allItemsBBox |= bbox;
++it;
}
@@ -404,7 +404,7 @@ QImage SVGPatternElementImpl::createTile(SVGShapeImpl *referencingElement, int i
{
if(tileX != 0 || tileY !=0)
{
- QPoint panPoint(-(tileX * imageWidth), -(tileY * imageHeight));
+ TQPoint panPoint(-(tileX * imageWidth), -(tileY * imageHeight));
m_canvas->update(panPoint, false);
}
}
@@ -423,7 +423,7 @@ QImage SVGPatternElementImpl::createTile(SVGShapeImpl *referencingElement, int i
return image;
}
-void SVGPatternElementImpl::reference(const QString &href)
+void SVGPatternElementImpl::reference(const TQString &href)
{
// Copy attributes
SVGElementImpl *src = ownerSVGElement()->getElementById(href);
@@ -445,7 +445,7 @@ void SVGPatternElementImpl::finalizePaintServer()
// inside a pattern has finished loading.
m_tileCache.clear();
- QString _href = SVGURIReferenceImpl::getTarget(href()->baseVal().string());
+ TQString _href = SVGURIReferenceImpl::getTarget(href()->baseVal().string());
if(!_href.isEmpty())
reference(_href);
}
@@ -483,8 +483,8 @@ SVGPatternElementImpl::Tile SVGPatternElementImpl::createTile(SVGShapeImpl *refe
if(imageWidth > 0 && imageHeight > 0)
{
- QSize size(imageWidth, imageHeight);
- QImage image;
+ TQSize size(imageWidth, imageHeight);
+ TQImage image;
if(!m_tileCache.find(size, image))
{
@@ -497,7 +497,7 @@ SVGPatternElementImpl::Tile SVGPatternElementImpl::createTile(SVGShapeImpl *refe
double adjustYScale = tileHeight / imageHeight;
matrix->scaleNonUniform(adjustXScale, adjustYScale);
- QWMatrix screenToTile = matrix->qmatrix().invert();
+ TQWMatrix screenToTile = matrix->qmatrix().invert();
tile = Tile(image, screenToTile);
}
diff --git a/ksvg/impl/SVGPatternElementImpl.h b/ksvg/impl/SVGPatternElementImpl.h
index 612fcfae..0c9abc8e 100644
--- a/ksvg/impl/SVGPatternElementImpl.h
+++ b/ksvg/impl/SVGPatternElementImpl.h
@@ -21,8 +21,8 @@
#ifndef SVGPatternElementImpl_H
#define SVGPatternElementImpl_H
-#include <qimage.h>
-#include <qwmatrix.h>
+#include <tqimage.h>
+#include <tqwmatrix.h>
#include "SVGTestsImpl.h"
#include "SVGElementImpl.h"
@@ -72,21 +72,21 @@ public:
SVGUnitConverter *converter() const { return m_converter; }
- void reference(const QString &href);
+ void reference(const TQString &href);
void finalizePaintServer();
class Tile
{
public:
Tile() {}
- Tile(const QImage& image, const QWMatrix& screenToTile) : m_image(image), m_screenToTile(screenToTile) {}
+ Tile(const TQImage& image, const TQWMatrix& screenToTile) : m_image(image), m_screenToTile(screenToTile) {}
- QImage image() const { return m_image; }
- const QWMatrix& screenToTile() const { return m_screenToTile; }
+ TQImage image() const { return m_image; }
+ const TQWMatrix& screenToTile() const { return m_screenToTile; }
private:
- QImage m_image;
- QWMatrix m_screenToTile;
+ TQImage m_image;
+ TQWMatrix m_screenToTile;
};
Tile createTile(SVGShapeImpl *referencingElement);
@@ -94,7 +94,7 @@ public:
static void flushCachedTiles();
private:
- QImage createTile(SVGShapeImpl *referencingElement, int imageWidth, int imageHeight);
+ TQImage createTile(SVGShapeImpl *referencingElement, int imageWidth, int imageHeight);
SVGAnimatedEnumerationImpl *m_patternUnits;
SVGAnimatedEnumerationImpl *m_patternContentUnits;
@@ -108,9 +108,9 @@ private:
KSVGCanvas *m_canvas;
SVGElementImpl *m_location; // the referenced element
- MinOneLRUCache<QSize, QImage> m_tileCache;
+ MinOneLRUCache<TQSize, TQImage> m_tileCache;
- static QValueList<SVGPatternElementImpl *> m_patternElements;
+ static TQValueList<SVGPatternElementImpl *> m_patternElements;
public:
KSVG_GET
diff --git a/ksvg/impl/SVGPreserveAspectRatioImpl.cc b/ksvg/impl/SVGPreserveAspectRatioImpl.cc
index c8660e61..f9e95405 100644
--- a/ksvg/impl/SVGPreserveAspectRatioImpl.cc
+++ b/ksvg/impl/SVGPreserveAspectRatioImpl.cc
@@ -20,8 +20,8 @@
#include <kdebug.h>
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
#include "SVGPreserveAspectRatio.h"
@@ -68,13 +68,13 @@ unsigned short SVGPreserveAspectRatioImpl::meetOrSlice() const
return m_meetOrSlice;
}
-void SVGPreserveAspectRatioImpl::parsePreserveAspectRatio(const QString &str)
+void SVGPreserveAspectRatioImpl::parsePreserveAspectRatio(const TQString &str)
{
// Spec: set the defaults
setAlign(SVG_PRESERVEASPECTRATIO_NONE);
setMeetOrSlice(SVG_MEETORSLICE_MEET);
- QStringList params = QStringList::split(' ', str.simplifyWhiteSpace());
+ TQStringList params = TQStringList::split(' ', str.simplifyWhiteSpace());
if(params[0].compare("none") == 0)
m_align = SVG_PRESERVEASPECTRATIO_NONE;
diff --git a/ksvg/impl/SVGPreserveAspectRatioImpl.h b/ksvg/impl/SVGPreserveAspectRatioImpl.h
index 4a14a6b0..2a768521 100644
--- a/ksvg/impl/SVGPreserveAspectRatioImpl.h
+++ b/ksvg/impl/SVGPreserveAspectRatioImpl.h
@@ -25,7 +25,7 @@
#include "ksvg_lookup.h"
-class QString;
+class TQString;
namespace KSVG
{
@@ -43,7 +43,7 @@ public:
void setMeetOrSlice(unsigned short);
unsigned short meetOrSlice() const;
- void parsePreserveAspectRatio(const QString &);
+ void parsePreserveAspectRatio(const TQString &);
SVGMatrixImpl *getCTM(float logicX, float logicY, float logicWidth, float logicHeight,
float physX, float physY, float physWidth, float physHeight);
diff --git a/ksvg/impl/SVGRadialGradientElementImpl.cc b/ksvg/impl/SVGRadialGradientElementImpl.cc
index 8d00cf15..44ece001 100644
--- a/ksvg/impl/SVGRadialGradientElementImpl.cc
+++ b/ksvg/impl/SVGRadialGradientElementImpl.cc
@@ -192,12 +192,12 @@ void SVGRadialGradientElementImpl::setAttributes()
KSVG_SET_ALT_ATTRIBUTE(R, "50%")
}
-QMap<QString, DOM::DOMString> SVGRadialGradientElementImpl::gradientAttributes()
+TQMap<TQString, DOM::DOMString> SVGRadialGradientElementImpl::gradientAttributes()
{
setAttributes();
- QMap<QString, DOM::DOMString> gradAttributes;
- QDictIterator<DOM::DOMString> it(attributes());
+ TQMap<TQString, DOM::DOMString> gradAttributes;
+ TQDictIterator<DOM::DOMString> it(attributes());
for(; it.current(); ++it)
{
diff --git a/ksvg/impl/SVGRadialGradientElementImpl.h b/ksvg/impl/SVGRadialGradientElementImpl.h
index 2f6c58c1..54edea08 100644
--- a/ksvg/impl/SVGRadialGradientElementImpl.h
+++ b/ksvg/impl/SVGRadialGradientElementImpl.h
@@ -43,7 +43,7 @@ public:
virtual void setAttributes();
- virtual QMap<QString, DOM::DOMString> gradientAttributes();
+ virtual TQMap<TQString, DOM::DOMString> gradientAttributes();
private:
SVGAnimatedLengthImpl *m_cx;
diff --git a/ksvg/impl/SVGRectImpl.cc b/ksvg/impl/SVGRectImpl.cc
index 1f6c0d51..3889ec79 100644
--- a/ksvg/impl/SVGRectImpl.cc
+++ b/ksvg/impl/SVGRectImpl.cc
@@ -20,7 +20,7 @@
#include <kdebug.h>
-#include <qrect.h>
+#include <tqrect.h>
#include "SVGRectImpl.h"
@@ -40,7 +40,7 @@ SVGRectImpl::SVGRectImpl()
m_height = 0;
}
-SVGRectImpl::SVGRectImpl(const QRect &other)
+SVGRectImpl::SVGRectImpl(const TQRect &other)
{
(*this) = other;
}
@@ -89,13 +89,13 @@ float SVGRectImpl::height() const
return m_height;
}
-QRect SVGRectImpl::qrect() const
+TQRect SVGRectImpl::qrect() const
{
// ceil() so the integer rectangle contains the whole real one.
- return QRect(int(m_x), int(m_y), int(ceil(m_width)), int(ceil(m_height)));
+ return TQRect(int(m_x), int(m_y), int(ceil(m_width)), int(ceil(m_height)));
}
-SVGRectImpl &SVGRectImpl::operator=(const QRect &other)
+SVGRectImpl &SVGRectImpl::operator=(const TQRect &other)
{
m_x = other.x();
m_y = other.y();
diff --git a/ksvg/impl/SVGRectImpl.h b/ksvg/impl/SVGRectImpl.h
index e0b0e889..dab7bbcf 100644
--- a/ksvg/impl/SVGRectImpl.h
+++ b/ksvg/impl/SVGRectImpl.h
@@ -25,7 +25,7 @@
#include "ksvg_lookup.h"
-class QRect;
+class TQRect;
namespace KSVG
{
@@ -34,7 +34,7 @@ class SVGRectImpl : public DOM::DomShared
{
public:
SVGRectImpl();
- SVGRectImpl(const QRect &);
+ SVGRectImpl(const TQRect &);
virtual ~SVGRectImpl();
void setX(float x);
@@ -49,9 +49,9 @@ public:
void setHeight(float height);
float height() const;
- QRect qrect() const;
+ TQRect qrect() const;
- SVGRectImpl &operator=(const QRect &);
+ SVGRectImpl &operator=(const TQRect &);
private:
float m_x;
diff --git a/ksvg/impl/SVGSVGElementImpl.cc b/ksvg/impl/SVGSVGElementImpl.cc
index b54cf521..c9b82445 100644
--- a/ksvg/impl/SVGSVGElementImpl.cc
+++ b/ksvg/impl/SVGSVGElementImpl.cc
@@ -20,9 +20,9 @@
#include <kdebug.h>
-#include <qtimer.h>
-#include <qstringlist.h>
-#include <qdatetime.h>
+#include <tqtimer.h>
+#include <tqstringlist.h>
+#include <tqdatetime.h>
#define USE_VALGRIND 0
@@ -283,7 +283,7 @@ float SVGSVGElementImpl::currentScale() const
return m_currentScale;
}
-void SVGSVGElementImpl::setCurrentTranslate(const QPoint &p)
+void SVGSVGElementImpl::setCurrentTranslate(const TQPoint &p)
{
if(m_currentTranslate->x() != p.x() || m_currentTranslate->y() != p.y())
{
@@ -319,7 +319,7 @@ void SVGSVGElementImpl::forceRedraw()
CALLTREE_ZERO_STATS();
#endif
- QTime timer;
+ TQTime timer;
timer.start();
if(ownerDoc() && ownerDoc()->canvas())
@@ -461,7 +461,7 @@ SVGMatrixImpl *SVGSVGElementImpl::createSVGMatrix()
{
// Spec: Creates an SVGMatrix object outside of any document
// trees. The object is initialized to the identity matrix.
- SVGMatrixImpl *ret = new SVGMatrixImpl(QWMatrix(1.0F, 0.0F, 0.0F, 1.0F, 0.0F, 0.0F));
+ SVGMatrixImpl *ret = new SVGMatrixImpl(TQWMatrix(1.0F, 0.0F, 0.0F, 1.0F, 0.0F, 0.0F));
ret->ref();
return ret;
}
@@ -503,7 +503,7 @@ SVGElementImpl *SVGSVGElementImpl::getElementById(const DOM::DOMString &elementI
return m_map[elementId.string()];
}
-void SVGSVGElementImpl::addToIdMap(const QString &id, SVGElementImpl *obj)
+void SVGSVGElementImpl::addToIdMap(const TQString &id, SVGElementImpl *obj)
{
m_map.insert(id, obj);
}
@@ -542,15 +542,15 @@ const SVGMatrixImpl *SVGSVGElementImpl::localMatrix()
return m_localMatrix;
}
-void SVGSVGElementImpl::setClip(const QString &clip)
+void SVGSVGElementImpl::setClip(const TQString &clip)
{
// TODO : this routine should probably be shared between all classes that establish new viewports (Rob)
if(!clip.startsWith("rect(") || !clip.endsWith(")"))
return;
- QString work = clip.mid(5, clip.length() - 6);
- QStringList substrings = QStringList::split(',', clip);
- QStringList::ConstIterator it = substrings.begin();
+ TQString work = clip.mid(5, clip.length() - 6);
+ TQStringList substrings = TQStringList::split(',', clip);
+ TQStringList::ConstIterator it = substrings.begin();
if(m_clip[0])
m_clip[0]->deref();
@@ -584,13 +584,13 @@ void SVGSVGElementImpl::setClip(const QString &clip)
m_clip[3]->setValueAsString(*it);
}
-QRect SVGSVGElementImpl::clip()
+TQRect SVGSVGElementImpl::clip()
{
// Get viewport in user coordinates.
- QRect v(0, 0, m_viewport->qrect().width(), m_viewport->qrect().height());
+ TQRect v(0, 0, m_viewport->qrect().width(), m_viewport->qrect().height());
SVGMatrixImpl *ctm = getCTM();
- QRect r = ctm->qmatrix().invert().mapRect(v);
+ TQRect r = ctm->qmatrix().invert().mapRect(v);
ctm->deref();
if(m_clip[0])
@@ -614,14 +614,14 @@ void SVGSVGElementImpl::setRootParentScreenCTM(SVGMatrixImpl *screenCTM)
screenCTM->ref();
}
-bool SVGSVGElementImpl::prepareMouseEvent(const QPoint &p, const QPoint &a, SVGMouseEventImpl *mev)
+bool SVGSVGElementImpl::prepareMouseEvent(const TQPoint &p, const TQPoint &a, SVGMouseEventImpl *mev)
{
// mop: central bool var which turns to true once the current "mouseover" element has been found
bool ret = false, dorerender = false;
SVGElementImpl *elem = 0;
SVGMatrixImpl *ctm = getCTM();
- QPoint userA = ctm->qmatrix().invert().map(a);
+ TQPoint userA = ctm->qmatrix().invert().map(a);
ctm->deref();
// Just check the lastTarget once (mop)
diff --git a/ksvg/impl/SVGSVGElementImpl.h b/ksvg/impl/SVGSVGElementImpl.h
index 2405458e..d2667a35 100644
--- a/ksvg/impl/SVGSVGElementImpl.h
+++ b/ksvg/impl/SVGSVGElementImpl.h
@@ -23,7 +23,7 @@
#include <dom/dom_string.h>
-#include <qmap.h>
+#include <tqmap.h>
#include "SVGTestsImpl.h"
#include "SVGElementImpl.h"
@@ -91,7 +91,7 @@ public:
float currentScale() const;
SVGPointImpl *currentTranslate();
- void setCurrentTranslate(const QPoint &p);
+ void setCurrentTranslate(const TQPoint &p);
unsigned long suspendRedraw(unsigned long max_wait_milliseconds);
void unsuspendRedraw(unsigned long suspend_handle_id);
@@ -122,19 +122,19 @@ public:
static SVGTransformImpl *createSVGTransformFromMatrix(SVGMatrixImpl *matrix);
SVGElementImpl *getElementById(const DOM::DOMString &elementId);
- void addToIdMap(const QString &id, SVGElementImpl *obj);
+ void addToIdMap(const TQString &id, SVGElementImpl *obj);
virtual SVGMatrixImpl *getCTM();
virtual const SVGMatrixImpl *localMatrix();
void setAttributes();
- bool prepareMouseEvent(const QPoint &p, const QPoint &a, SVGMouseEventImpl *event);
+ bool prepareMouseEvent(const TQPoint &p, const TQPoint &a, SVGMouseEventImpl *event);
virtual bool isContainer() const { return true; }
- virtual void setClip(const QString &clip);
- virtual QRect clip();
+ virtual void setClip(const TQString &clip);
+ virtual TQRect clip();
void setRootParentScreenCTM(SVGMatrixImpl *screenCTM);
@@ -156,7 +156,7 @@ private:
SVGLengthImpl *m_clip[4];
- QMap<QString, SVGElementImpl *> m_map;
+ TQMap<TQString, SVGElementImpl *> m_map;
// Transformation provided by the 'parent' of the outermost svg element
SVGMatrixImpl *m_rootParentScreenCTM;
diff --git a/ksvg/impl/SVGScriptElementImpl.cc b/ksvg/impl/SVGScriptElementImpl.cc
index 9a211425..230adf25 100644
--- a/ksvg/impl/SVGScriptElementImpl.cc
+++ b/ksvg/impl/SVGScriptElementImpl.cc
@@ -22,7 +22,7 @@
#include <kio/job.h>
#include <kfilterdev.h>
-#include <qbuffer.h>
+#include <tqbuffer.h>
#include "SVGDocumentImpl.h"
#include "SVGAnimatedStringImpl.h"
@@ -35,7 +35,7 @@ using namespace KSVG;
#include "ksvg_bridge.h"
#include "ksvg_ecma.h"
-SVGScriptElementImpl::SVGScriptElementImpl(DOM::ElementImpl *impl) : QObject(), SVGElementImpl(impl), SVGURIReferenceImpl(), SVGExternalResourcesRequiredImpl()
+SVGScriptElementImpl::SVGScriptElementImpl(DOM::ElementImpl *impl) : TQObject(), SVGElementImpl(impl), SVGURIReferenceImpl(), SVGExternalResourcesRequiredImpl()
{
KSVG_EMPTY_FLAGS
@@ -66,7 +66,7 @@ void SVGScriptElementImpl::setAttributes()
KSVG_SET_ALT_ATTRIBUTE(Type, "text/ecmascript")
// Remote downloading
- QString href = m_href->baseVal().string();
+ TQString href = m_href->baseVal().string();
if(!href.isEmpty())
{
@@ -75,14 +75,14 @@ void SVGScriptElementImpl::setAttributes()
if(m_job == 0)
m_job = KIO::get(url, false, false);
- connect(m_job, SIGNAL(data(KIO::Job *, const QByteArray &)), this, SLOT(slotData(KIO::Job *, const QByteArray &)));
- connect(m_job, SIGNAL(result(KIO::Job *)), this, SLOT(slotResult(KIO::Job *)));
+ connect(m_job, TQT_SIGNAL(data(KIO::Job *, const TQByteArray &)), this, TQT_SLOT(slotData(KIO::Job *, const TQByteArray &)));
+ connect(m_job, TQT_SIGNAL(result(KIO::Job *)), this, TQT_SLOT(slotResult(KIO::Job *)));
}
}
-void SVGScriptElementImpl::slotData(KIO::Job *, const QByteArray &data)
+void SVGScriptElementImpl::slotData(KIO::Job *, const TQByteArray &data)
{
- QDataStream dataStream(m_data, IO_WriteOnly | IO_Append);
+ TQDataStream dataStream(m_data, IO_WriteOnly | IO_Append);
dataStream.writeRawBytes(data.data(), data.size());
}
@@ -94,13 +94,13 @@ void SVGScriptElementImpl::slotResult(KIO::Job *)
m_data.resize(m_data.size() + 1);
m_data[m_data.size() - 1] = '\0';
- QBuffer buf(m_data);
- QIODevice *dev = KFilterDev::device(&buf, "application/x-gzip", false);
- QByteArray contents;
+ TQBuffer buf(m_data);
+ TQIODevice *dev = KFilterDev::device(&buf, "application/x-gzip", false);
+ TQByteArray contents;
if(dev->open(IO_ReadOnly))
contents = dev->readAll();
delete dev;
- m_text = QString::fromUtf8(contents.data());
+ m_text = TQString::fromUtf8(contents.data());
m_data.resize(0);
}
@@ -124,7 +124,7 @@ bool SVGScriptElementImpl::executeScript(DOM::Node node)
return SVGScriptElementImpl::executeScript(node, ownerDoc(), m_text);
}
-bool SVGScriptElementImpl::executeScript(DOM::Node node, SVGDocumentImpl *document, const QString &text)
+bool SVGScriptElementImpl::executeScript(DOM::Node node, SVGDocumentImpl *document, const TQString &text)
{
#ifdef KJS_VERBOSE
kdDebug(6070) << "SVGScriptElementImpl::executeScript n=" << node.nodeName().string().latin1() << "(" << (node.isNull() ? 0 : node.nodeType()) << ") " << text << endl;
diff --git a/ksvg/impl/SVGScriptElementImpl.h b/ksvg/impl/SVGScriptElementImpl.h
index 95affee2..f3662fa6 100644
--- a/ksvg/impl/SVGScriptElementImpl.h
+++ b/ksvg/impl/SVGScriptElementImpl.h
@@ -25,7 +25,7 @@
#include <kio/jobclasses.h>
-#include <qobject.h>
+#include <tqobject.h>
#include "SVGElementImpl.h"
#include "SVGURIReferenceImpl.h"
@@ -36,7 +36,7 @@
namespace KSVG
{
-class SVGScriptElementImpl : public QObject,
+class SVGScriptElementImpl : public TQObject,
public SVGElementImpl,
public SVGURIReferenceImpl,
public SVGExternalResourcesRequiredImpl
@@ -54,16 +54,16 @@ public:
bool canExecuteScript();
bool executeScript(DOM::Node node);
- static bool executeScript(DOM::Node node, SVGDocumentImpl *document, const QString &text);
+ static bool executeScript(DOM::Node node, SVGDocumentImpl *document, const TQString &text);
private slots:
- void slotData(KIO::Job *, const QByteArray &);
+ void slotData(KIO::Job *, const TQByteArray &);
void slotResult(KIO::Job *);
private:
KIO::TransferJob *m_job;
- QByteArray m_data;
- QString m_text;
+ TQByteArray m_data;
+ TQString m_text;
bool m_added;
public:
diff --git a/ksvg/impl/SVGSetElementImpl.h b/ksvg/impl/SVGSetElementImpl.h
index ab9f5ec5..0a0c050c 100644
--- a/ksvg/impl/SVGSetElementImpl.h
+++ b/ksvg/impl/SVGSetElementImpl.h
@@ -25,7 +25,7 @@
#include "SVGAnimationElementImpl.h"
-class QTimer;
+class TQTimer;
namespace KSVG
{
diff --git a/ksvg/impl/SVGShapeImpl.cc b/ksvg/impl/SVGShapeImpl.cc
index 68e89aaa..d8ef45c5 100644
--- a/ksvg/impl/SVGShapeImpl.cc
+++ b/ksvg/impl/SVGShapeImpl.cc
@@ -77,7 +77,7 @@ SVGRectImpl *SVGShapeImpl::getBBoxInternal()
SVGRectImpl *ret = SVGSVGElementImpl::createSVGRect();
if(m_item)
{
- QRect r = m_item->bbox();
+ TQRect r = m_item->bbox();
ret->setX(r.x());
ret->setY(r.y());
ret->setWidth(r.width());
@@ -86,7 +86,7 @@ SVGRectImpl *SVGShapeImpl::getBBoxInternal()
return ret;
}
-bool SVGShapeImpl::prepareMouseEvent(const QPoint &p, const QPoint &, SVGMouseEventImpl *mev)
+bool SVGShapeImpl::prepareMouseEvent(const TQPoint &p, const TQPoint &, SVGMouseEventImpl *mev)
{
// TODO : pointer-events should be stored here, not in SVGStylableImpl.
SVGStylableImpl *style = dynamic_cast<SVGStylableImpl *>(this);
diff --git a/ksvg/impl/SVGShapeImpl.h b/ksvg/impl/SVGShapeImpl.h
index ae183251..c61038d2 100644
--- a/ksvg/impl/SVGShapeImpl.h
+++ b/ksvg/impl/SVGShapeImpl.h
@@ -24,7 +24,7 @@
#include "SVGElementImpl.h"
#include "CanvasItem.h"
-class QPoint;
+class TQPoint;
namespace KSVG
{
@@ -43,7 +43,7 @@ public:
virtual SVGRectImpl *getBBox();
virtual SVGRectImpl *getBBoxInternal();
- virtual bool prepareMouseEvent(const QPoint &p, const QPoint &a, SVGMouseEventImpl *mev);
+ virtual bool prepareMouseEvent(const TQPoint &p, const TQPoint &a, SVGMouseEventImpl *mev);
virtual bool directRender();
virtual bool isContainer() const { return false; }
diff --git a/ksvg/impl/SVGStringListImpl.cc b/ksvg/impl/SVGStringListImpl.cc
index b70adfdd..58a0dc0f 100644
--- a/ksvg/impl/SVGStringListImpl.cc
+++ b/ksvg/impl/SVGStringListImpl.cc
@@ -68,11 +68,11 @@ Value SVGStringListImplProtoFunc::call(ExecState *exec, Object &thisObj, const L
return obj->call(exec, static_cast<SVGList<SharedString> *>(obj), args, id);
}
-QString SVGStringListImpl::join(const QString &seperator) const
+TQString SVGStringListImpl::join(const TQString &seperator) const
{
SVGStringListImpl *self = const_cast<SVGStringListImpl *>(this);
- QString result;
+ TQString result;
if(!self->getItem(0))
return result;
diff --git a/ksvg/impl/SVGStringListImpl.h b/ksvg/impl/SVGStringListImpl.h
index 7f69a3c9..8d92b660 100644
--- a/ksvg/impl/SVGStringListImpl.h
+++ b/ksvg/impl/SVGStringListImpl.h
@@ -35,7 +35,7 @@ class SharedString : public DOM::DomShared,
{
public:
SharedString() : DOM::DomShared(), DOM::DOMString() { }
- SharedString(const QString &string) : DOM::DomShared(), DOM::DOMString(string) { }
+ SharedString(const TQString &string) : DOM::DomShared(), DOM::DOMString(string) { }
SharedString(const SharedString &string) : DOM::DomShared(), DOM::DOMString(string) { }
SharedString(DOM::DOMString *string) : DOM::DomShared(), DOM::DOMString(string->implementation()) { }
virtual ~SharedString() { }
@@ -69,7 +69,7 @@ public:
KJS::Value getValueProperty(KJS::ExecState *exec, int token) const;
- QString join(const QString &seperator) const;
+ TQString join(const TQString &seperator) const;
};
}
diff --git a/ksvg/impl/SVGStylableImpl.cc b/ksvg/impl/SVGStylableImpl.cc
index 096ebf93..17a3e8cd 100644
--- a/ksvg/impl/SVGStylableImpl.cc
+++ b/ksvg/impl/SVGStylableImpl.cc
@@ -20,7 +20,7 @@
#include <kdebug.h>
-#include <qrect.h>
+#include <tqrect.h>
#include "CanvasItem.h"
#include "KSVGCanvas.h"
@@ -484,7 +484,7 @@ void SVGStylableImpl::processStyle()
if(parentStyle)
m_startMarker = parentStyle->getStartMarker();
else
- m_startMarker = QString::null;
+ m_startMarker = TQString::null;
}
// Spec: default "none"
@@ -493,7 +493,7 @@ void SVGStylableImpl::processStyle()
if(parentStyle)
m_midMarker = parentStyle->getMidMarker();
else
- m_midMarker = QString::null;
+ m_midMarker = TQString::null;
}
// Spec: default "none"
@@ -502,7 +502,7 @@ void SVGStylableImpl::processStyle()
if(parentStyle)
m_endMarker = parentStyle->getEndMarker();
else
- m_endMarker = QString::null;
+ m_endMarker = TQString::null;
}
}
@@ -526,9 +526,9 @@ bool SVGStylableImpl::isFilled() const
m_fillColor->paintType() != SVG_PAINTTYPE_URI_NONE;
}
-QString SVGStylableImpl::extractUrlId(const QString &url)
+TQString SVGStylableImpl::extractUrlId(const TQString &url)
{
- QString id;
+ TQString id;
if(url.startsWith("url(#"))
{
@@ -541,14 +541,14 @@ QString SVGStylableImpl::extractUrlId(const QString &url)
return id;
}
-void SVGStylableImpl::setMarkers(const QString &marker)
+void SVGStylableImpl::setMarkers(const TQString &marker)
{
setStartMarker(marker);
setMidMarker(marker);
setEndMarker(marker);
}
-void SVGStylableImpl::setStartMarker(const QString &startMarker)
+void SVGStylableImpl::setStartMarker(const TQString &startMarker)
{
if(startMarker.startsWith("url(#"))
{
@@ -556,10 +556,10 @@ void SVGStylableImpl::setStartMarker(const QString &startMarker)
m_startMarker = startMarker.mid(idstart, startMarker.length() - idstart - 1);
}
else if(startMarker == "none")
- m_startMarker = QString::null;
+ m_startMarker = TQString::null;
}
-void SVGStylableImpl::setMidMarker(const QString &midMarker)
+void SVGStylableImpl::setMidMarker(const TQString &midMarker)
{
if(midMarker.startsWith("url(#"))
{
@@ -567,10 +567,10 @@ void SVGStylableImpl::setMidMarker(const QString &midMarker)
m_midMarker = midMarker.mid(idstart, midMarker.length() - idstart - 1);
}
else if(midMarker == "none")
- m_midMarker = QString::null;
+ m_midMarker = TQString::null;
}
-void SVGStylableImpl::setEndMarker(const QString &endMarker)
+void SVGStylableImpl::setEndMarker(const TQString &endMarker)
{
if(endMarker.startsWith("url(#"))
{
@@ -578,7 +578,7 @@ void SVGStylableImpl::setEndMarker(const QString &endMarker)
m_endMarker = endMarker.mid(idstart, endMarker.length() - idstart - 1);
}
else if(endMarker == "none")
- m_endMarker = QString::null;
+ m_endMarker = TQString::null;
}
bool SVGStylableImpl::hasMarkers() const
@@ -586,7 +586,7 @@ bool SVGStylableImpl::hasMarkers() const
return !m_startMarker.isEmpty() || !m_midMarker.isEmpty() || !m_endMarker.isEmpty();
}
-void SVGStylableImpl::setPaint(const QString &param, SVGPaintImpl *svgPaint)
+void SVGStylableImpl::setPaint(const TQString &param, SVGPaintImpl *svgPaint)
{
if(param.stripWhiteSpace() == "none")
svgPaint->setPaint(SVG_PAINTTYPE_NONE, DOM::DOMString(""), DOM::DOMString(""));
@@ -596,48 +596,48 @@ void SVGStylableImpl::setPaint(const QString &param, SVGPaintImpl *svgPaint)
setColor(param, svgPaint);
}
-void SVGStylableImpl::setColor(const QString &param, SVGColorImpl *svgColor)
+void SVGStylableImpl::setColor(const TQString &param, SVGColorImpl *svgColor)
{
if(param.stripWhiteSpace().startsWith("#"))
{
if(param.contains("icc-color"))
{
- QString first = param.left(7);
- QString last = param.right(param.length() - 8);
+ TQString first = param.left(7);
+ TQString last = param.right(param.length() - 8);
svgColor->setRGBColorICCColor(first, last);
}
else
{
- QColor color;
+ TQColor color;
color.setNamedColor(param.stripWhiteSpace());
svgColor->setRGBColor(color);
}
}
else if(param.stripWhiteSpace().startsWith("rgb("))
{
- QString parse = param.stripWhiteSpace();
- QStringList colors = QStringList::split(',', parse);
- QString r = colors[0].right((colors[0].length() - 4));
- QString g = colors[1];
- QString b = colors[2].left((colors[2].length() - 1));
+ TQString parse = param.stripWhiteSpace();
+ TQStringList colors = TQStringList::split(',', parse);
+ TQString r = colors[0].right((colors[0].length() - 4));
+ TQString g = colors[1];
+ TQString b = colors[2].left((colors[2].length() - 1));
if(r.contains("%"))
{
r = r.left(r.length() - 1);
- r = QString::number(int((double(255 * r.toDouble()) / 100.0)));
+ r = TQString::number(int((double(255 * r.toDouble()) / 100.0)));
}
if(g.contains("%"))
{
g = g.left(g.length() - 1);
- g = QString::number(int((double(255 * g.toDouble()) / 100.0)));
+ g = TQString::number(int((double(255 * g.toDouble()) / 100.0)));
}
if(b.contains("%"))
{
b = b.left(b.length() - 1);
- b = QString::number(int((double(255 * b.toDouble()) / 100.0)));
+ b = TQString::number(int((double(255 * b.toDouble()) / 100.0)));
}
svgColor->setRGBColor(int(r.toFloat()), int(g.toFloat()), int(b.toFloat()));
@@ -651,16 +651,16 @@ void SVGStylableImpl::setColor(const QString &param, SVGColorImpl *svgColor)
}
}
-QRect SVGStylableImpl::clip()
+TQRect SVGStylableImpl::clip()
{
- return QRect();
+ return TQRect();
}
-void SVGStylableImpl::setClip(const QString &)
+void SVGStylableImpl::setClip(const TQString &)
{
}
-float SVGStylableImpl::fontSizeForText(const QString &value)
+float SVGStylableImpl::fontSizeForText(const TQString &value)
{
float ret = -1;
@@ -772,7 +772,7 @@ void SVGStylableImpl::putValueProperty(ExecState *exec, int token, const Value &
if(!(attr & KJS::Internal))
return;
- QString param = value.toString(exec).qstring();
+ TQString param = value.toString(exec).qstring();
if (param.isEmpty())
return;
@@ -788,10 +788,10 @@ void SVGStylableImpl::putValueProperty(ExecState *exec, int token, const Value &
if(!m_object)
return;
- QStringList substyles = QStringList::split(';', param);
- for(QStringList::Iterator it = substyles.begin(); it != substyles.end(); ++it)
+ TQStringList substyles = TQStringList::split(';', param);
+ for(TQStringList::Iterator it = substyles.begin(); it != substyles.end(); ++it)
{
- QStringList substyle = QStringList::split(':', (*it));
+ TQStringList substyle = TQStringList::split(':', (*it));
m_object->setAttributeInternal(substyle[0].stripWhiteSpace(), substyle[1].stripWhiteSpace());
}
break;
@@ -946,7 +946,7 @@ void SVGStylableImpl::putValueProperty(ExecState *exec, int token, const Value &
// Hacks
// #1 Replace "'" characters by ""
- param = param.replace('\'', QString::null);
+ param = param.replace('\'', TQString::null);
// #2 Replace "MS-Gothic" by "MS Gothic"
param = param.replace("MS-Gothic", "MS Gothic");
// #3 Replace "Helvetica" by "Arial"
@@ -983,8 +983,8 @@ void SVGStylableImpl::putValueProperty(ExecState *exec, int token, const Value &
{
// CSS2 allows multiple decorations
m_textDecoration = TDNONE;
- QStringList decorations = QStringList::split(' ', param);
- for(QStringList::Iterator it = decorations.begin(); it != decorations.end(); ++it)
+ TQStringList decorations = TQStringList::split(' ', param);
+ for(TQStringList::Iterator it = decorations.begin(); it != decorations.end(); ++it)
{
if(*it == "underline")
m_textDecoration |= UNDERLINE;
diff --git a/ksvg/impl/SVGStylableImpl.h b/ksvg/impl/SVGStylableImpl.h
index 0a399a4c..50a37568 100644
--- a/ksvg/impl/SVGStylableImpl.h
+++ b/ksvg/impl/SVGStylableImpl.h
@@ -21,14 +21,14 @@
#ifndef SVGStylableImpl_H
#define SVGStylableImpl_H
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
#include <dom/dom_string.h>
#include "ksvg_lookup.h"
-class QRect;
+class TQRect;
// from libart, but now no dependency
typedef enum
@@ -210,7 +210,7 @@ public:
SVGStylableImpl(SVGElementImpl *object);
virtual ~SVGStylableImpl();
- static void setColor(const QString &, SVGColorImpl *);
+ static void setColor(const TQString &, SVGColorImpl *);
STYLE_GET(SVGAnimatedLengthImpl *, DashOffset, m_dashOffset)
STYLE_GET(SVGAnimatedLengthListImpl *, DashArray, m_dashArray)
@@ -221,17 +221,17 @@ public:
STYLE_GET(SVGAnimatedLengthImpl *, StrokeWidth, m_strokeWidth)
STYLE_GET(SVGStringListImpl *, FontFamily, m_fontFamily);
STYLE_GET(float, FontSize, m_fontSize)
- STYLE_GET(QString, LetterSpacing, m_letterSpacing)
- STYLE_GET(QString, WordSpacing, m_wordSpacing)
- STYLE_GET(QString, FontWeight, m_fontWeight)
- STYLE_GET(QString, ClipPath, m_clipPath)
- STYLE_GET(QString, Mask, m_mask)
- STYLE_GET(QString, StartMarker, m_startMarker)
- STYLE_GET(QString, MidMarker, m_midMarker)
- STYLE_GET(QString, EndMarker, m_endMarker)
- STYLE_GET(QString, BaselineShift, m_baselineShift)
- STYLE_GET(QString, GlyphOrientationVertical, m_glyphOrientationVertical)
- STYLE_GET(QString, GlyphOrientationHorizontal, m_glyphOrientationHorizontal)
+ STYLE_GET(TQString, LetterSpacing, m_letterSpacing)
+ STYLE_GET(TQString, WordSpacing, m_wordSpacing)
+ STYLE_GET(TQString, FontWeight, m_fontWeight)
+ STYLE_GET(TQString, ClipPath, m_clipPath)
+ STYLE_GET(TQString, Mask, m_mask)
+ STYLE_GET(TQString, StartMarker, m_startMarker)
+ STYLE_GET(TQString, MidMarker, m_midMarker)
+ STYLE_GET(TQString, EndMarker, m_endMarker)
+ STYLE_GET(TQString, BaselineShift, m_baselineShift)
+ STYLE_GET(TQString, GlyphOrientationVertical, m_glyphOrientationVertical)
+ STYLE_GET(TQString, GlyphOrientationHorizontal, m_glyphOrientationHorizontal)
STYLE_GET(float, Opacity, m_opacity)
STYLE_GET(float, FillOpacity, m_fillOpacity)
STYLE_GET(float, StrokeOpacity, m_strokeOpacity)
@@ -261,10 +261,10 @@ public:
STYLE_HAS(EndMarker, m_endMarker)
// Special "set" cases
- void setStartMarker(const QString &);
- void setMidMarker(const QString &);
- void setEndMarker(const QString &);
- void setMarkers(const QString &);
+ void setStartMarker(const TQString &);
+ void setMidMarker(const TQString &);
+ void setEndMarker(const TQString &);
+ void setMarkers(const TQString &);
// Special "has" cases
bool hasMarkers() const;
@@ -277,17 +277,17 @@ public:
void processStyle();
// Special virtual functions
- virtual void setClip(const QString &clip);
- virtual QRect clip();
+ virtual void setClip(const TQString &clip);
+ virtual TQRect clip();
protected:
- float fontSizeForText(const QString &);
+ float fontSizeForText(const TQString &);
SVGElementImpl *m_object;
private:
- void setPaint(const QString &, SVGPaintImpl *);
- QString extractUrlId(const QString& string);
+ void setPaint(const TQString &, SVGPaintImpl *);
+ TQString extractUrlId(const TQString& string);
unsigned long long m_flags;
diff --git a/ksvg/impl/SVGTRefElementImpl.cc b/ksvg/impl/SVGTRefElementImpl.cc
index c1c7e540..73cb2532 100644
--- a/ksvg/impl/SVGTRefElementImpl.cc
+++ b/ksvg/impl/SVGTRefElementImpl.cc
@@ -46,9 +46,9 @@ void SVGTRefElementImpl::setAttributes()
href()->setBaseVal(DOM::DOMString(SVGURIReferenceImpl::getTarget(_href.string())));
// get the text of the referenced element
- QString text;
+ TQString text;
- QString url = _href.string().stripWhiteSpace(), filename, id;
+ TQString url = _href.string().stripWhiteSpace(), filename, id;
if(!SVGURIReferenceImpl::parseURIReference(url, filename, id))
return;
diff --git a/ksvg/impl/SVGTSpanElementImpl.cc b/ksvg/impl/SVGTSpanElementImpl.cc
index 7265c66e..2d3fef15 100644
--- a/ksvg/impl/SVGTSpanElementImpl.cc
+++ b/ksvg/impl/SVGTSpanElementImpl.cc
@@ -44,7 +44,7 @@ long SVGTSpanElementImpl::getNumberOfChars()
return text().length();
}
-QString SVGTSpanElementImpl::text()
+TQString SVGTSpanElementImpl::text()
{
// Otherwhise some js scripts which require a child, don't work (Niko)
if(!hasChildNodes())
diff --git a/ksvg/impl/SVGTSpanElementImpl.h b/ksvg/impl/SVGTSpanElementImpl.h
index 26e4903d..631b7896 100644
--- a/ksvg/impl/SVGTSpanElementImpl.h
+++ b/ksvg/impl/SVGTSpanElementImpl.h
@@ -34,7 +34,7 @@ public:
SVGTSpanElementImpl(DOM::ElementImpl *);
virtual ~SVGTSpanElementImpl();
- QString text();
+ TQString text();
virtual long getNumberOfChars();
diff --git a/ksvg/impl/SVGTestsImpl.cc b/ksvg/impl/SVGTestsImpl.cc
index 8bbccf80..b88de60a 100644
--- a/ksvg/impl/SVGTestsImpl.cc
+++ b/ksvg/impl/SVGTestsImpl.cc
@@ -52,17 +52,17 @@ SVGTestsImpl::~SVGTestsImpl()
m_systemLanguage->deref();
}
-void SVGTestsImpl::parseRequiredFeatures(const QString &/*value*/)
+void SVGTestsImpl::parseRequiredFeatures(const TQString &/*value*/)
{
// FIXME
}
-void SVGTestsImpl::parseRequiredExtensions(const QString &value)
+void SVGTestsImpl::parseRequiredExtensions(const TQString &value)
{
m_requiredExtensions->appendItem(new SharedString(value));
}
-void SVGTestsImpl::parseSystemLanguage(const QString &value)
+void SVGTestsImpl::parseSystemLanguage(const TQString &value)
{
m_systemLanguage->appendItem(new SharedString(value));
}
@@ -91,7 +91,7 @@ bool SVGTestsImpl::ok()
}
for(unsigned int i = 0;i < m_systemLanguage->numberOfItems();i++)
{
- QString value = m_systemLanguage->getItem(i)->string();
+ TQString value = m_systemLanguage->getItem(i)->string();
if(value.isEmpty() || value != (KGlobal::locale()->language()).left(2))
return false;
}
diff --git a/ksvg/impl/SVGTestsImpl.h b/ksvg/impl/SVGTestsImpl.h
index c5b05a5f..25c0e02b 100644
--- a/ksvg/impl/SVGTestsImpl.h
+++ b/ksvg/impl/SVGTestsImpl.h
@@ -35,9 +35,9 @@ public:
SVGTestsImpl();
~SVGTestsImpl();
- void parseRequiredFeatures(const QString &value);
- void parseRequiredExtensions(const QString &value);
- void parseSystemLanguage(const QString &value);
+ void parseRequiredFeatures(const TQString &value);
+ void parseRequiredExtensions(const TQString &value);
+ void parseSystemLanguage(const TQString &value);
SVGStringListImpl *requiredFeatures() const;
SVGStringListImpl *requiredExtensions() const;
diff --git a/ksvg/impl/SVGTextContentElementImpl.cc b/ksvg/impl/SVGTextContentElementImpl.cc
index f51d8807..302b54b7 100644
--- a/ksvg/impl/SVGTextContentElementImpl.cc
+++ b/ksvg/impl/SVGTextContentElementImpl.cc
@@ -59,9 +59,9 @@ SVGTextContentElementImpl::~SVGTextContentElementImpl()
m_textLength->deref();
}
-QString SVGTextContentElementImpl::textDirectionAwareText()
+TQString SVGTextContentElementImpl::textDirectionAwareText()
{
- QString text;
+ TQString text;
if(hasChildNodes())
{
@@ -73,11 +73,11 @@ QString SVGTextContentElementImpl::textDirectionAwareText()
if(node.nodeType() == TEXT_NODE)
{
DOM::Text textNode = node;
- QString temp = textNode.data().string();
+ TQString temp = textNode.data().string();
if(!ltr)
{
- QString convert = temp;
+ TQString convert = temp;
for(int i = temp.length(); i > 0; i--)
convert[temp.length() - i] = temp[i - 1];
@@ -237,7 +237,7 @@ void SVGTextContentElementImpl::putValueProperty(ExecState *exec, int token, con
break;
case LengthAdjust:
{
- QString temp = value.toString(exec).qstring();
+ TQString temp = value.toString(exec).qstring();
if(temp == "spacingAndGlyphs")
m_lengthAdjust->setBaseVal(LENGTHADJUST_SPACINGANDGLYPHS);
else if(temp == "spacing")
diff --git a/ksvg/impl/SVGTextContentElementImpl.h b/ksvg/impl/SVGTextContentElementImpl.h
index 26bbc041..bd962037 100644
--- a/ksvg/impl/SVGTextContentElementImpl.h
+++ b/ksvg/impl/SVGTextContentElementImpl.h
@@ -50,7 +50,7 @@ public:
SVGTextContentElementImpl(DOM::ElementImpl *impl);
virtual ~SVGTextContentElementImpl();
- QString textDirectionAwareText();
+ TQString textDirectionAwareText();
virtual T2P::GlyphLayoutParams *layoutParams() const;
diff --git a/ksvg/impl/SVGTextElementImpl.cc b/ksvg/impl/SVGTextElementImpl.cc
index 634c227d..82a53ea9 100644
--- a/ksvg/impl/SVGTextElementImpl.cc
+++ b/ksvg/impl/SVGTextElementImpl.cc
@@ -49,7 +49,7 @@ long SVGTextElementImpl::getNumberOfChars()
return text().length();
}
-QString SVGTextElementImpl::text()
+TQString SVGTextElementImpl::text()
{
// Otherwhise some js scripts which require a child, don't work (Niko)
if(!hasChildNodes())
@@ -80,7 +80,7 @@ void SVGTextElementImpl::createItem(KSVGCanvas *c )
{
m_item = c->createText(this);
// Set up bbox before insert(), as that may render the item
- QRect rect = m_item->bbox();
+ TQRect rect = m_item->bbox();
m_bboxX = rect.x();
m_bboxY = rect.y();
m_bboxWidth = rect.width();
@@ -89,7 +89,7 @@ void SVGTextElementImpl::createItem(KSVGCanvas *c )
}
}
-bool SVGTextElementImpl::prepareMouseEvent(const QPoint &p, const QPoint &, SVGMouseEventImpl *mev)
+bool SVGTextElementImpl::prepareMouseEvent(const TQPoint &p, const TQPoint &, SVGMouseEventImpl *mev)
{
// TODO : pointer-events should be stored here, not in SVGStylableImpl.
SVGStylableImpl *style = dynamic_cast<SVGStylableImpl *>(this);
diff --git a/ksvg/impl/SVGTextElementImpl.h b/ksvg/impl/SVGTextElementImpl.h
index e0c2ca8d..fe87848a 100644
--- a/ksvg/impl/SVGTextElementImpl.h
+++ b/ksvg/impl/SVGTextElementImpl.h
@@ -37,7 +37,7 @@ public:
SVGTextElementImpl(DOM::ElementImpl *);
virtual ~SVGTextElementImpl();
- QString text();
+ TQString text();
virtual long getNumberOfChars();
@@ -45,7 +45,7 @@ public:
virtual SVGRectImpl *getBBox();
- virtual bool prepareMouseEvent(const QPoint &p, const QPoint &a, SVGMouseEventImpl *mev);
+ virtual bool prepareMouseEvent(const TQPoint &p, const TQPoint &a, SVGMouseEventImpl *mev);
private:
int m_bboxX, m_bboxY, m_bboxWidth, m_bboxHeight;
diff --git a/ksvg/impl/SVGTextPathElementImpl.cc b/ksvg/impl/SVGTextPathElementImpl.cc
index ec218046..78c272f8 100644
--- a/ksvg/impl/SVGTextPathElementImpl.cc
+++ b/ksvg/impl/SVGTextPathElementImpl.cc
@@ -75,7 +75,7 @@ SVGAnimatedEnumerationImpl *SVGTextPathElementImpl::spacing() const
return m_spacing;
}
-QString SVGTextPathElementImpl::text()
+TQString SVGTextPathElementImpl::text()
{
// Otherwhise some js scripts which require a child, don't work (Niko)
if(!hasChildNodes())
@@ -161,11 +161,11 @@ void SVGTextPathElementImpl::putValueProperty(ExecState *exec, int token, const
{
case StartOffset:
{
- QString param = value.toString(exec).qstring();
+ TQString param = value.toString(exec).qstring();
if(param.endsWith("%"))
{
- QString value = param.left(param.length() - 1);
+ TQString value = param.left(param.length() - 1);
bool ok = false;
double dValue = value.toDouble(&ok);
if(ok)
@@ -182,7 +182,7 @@ void SVGTextPathElementImpl::putValueProperty(ExecState *exec, int token, const
}
case Method:
{
- QString param = value.toString(exec).qstring();
+ TQString param = value.toString(exec).qstring();
if(param == "align")
method()->setBaseVal(TEXTPATH_METHODTYPE_ALIGN);
@@ -195,7 +195,7 @@ void SVGTextPathElementImpl::putValueProperty(ExecState *exec, int token, const
}
case Spacing:
{
- QString param = value.toString(exec).qstring();
+ TQString param = value.toString(exec).qstring();
if(param == "auto")
spacing()->setBaseVal(TEXTPATH_SPACINGTYPE_AUTO);
diff --git a/ksvg/impl/SVGTextPathElementImpl.h b/ksvg/impl/SVGTextPathElementImpl.h
index 8231f0cd..98a88d33 100644
--- a/ksvg/impl/SVGTextPathElementImpl.h
+++ b/ksvg/impl/SVGTextPathElementImpl.h
@@ -34,7 +34,7 @@ public:
SVGTextPathElementImpl(DOM::ElementImpl *);
virtual ~SVGTextPathElementImpl();
- QString text();
+ TQString text();
SVGAnimatedLengthImpl *startOffset() const;
SVGAnimatedEnumerationImpl *method() const;
diff --git a/ksvg/impl/SVGTimeScheduler.cc b/ksvg/impl/SVGTimeScheduler.cc
index efff77ac..caddf81f 100644
--- a/ksvg/impl/SVGTimeScheduler.cc
+++ b/ksvg/impl/SVGTimeScheduler.cc
@@ -26,11 +26,11 @@
using namespace KSVG;
-SVGTimer::SVGTimer(QObject *scheduler, unsigned int ms, bool singleShot)
+SVGTimer::SVGTimer(TQObject *scheduler, unsigned int ms, bool singleShot)
{
m_ms = ms;
m_singleShot = singleShot;
- m_timer = new QTimer(scheduler);
+ m_timer = new TQTimer(scheduler);
}
SVGTimer::~SVGTimer()
@@ -38,19 +38,19 @@ SVGTimer::~SVGTimer()
delete m_timer;
}
-bool SVGTimer::operator==(const QTimer *timer)
+bool SVGTimer::operator==(const TQTimer *timer)
{
return (m_timer == timer);
}
-const QTimer *SVGTimer::qtimer() const
+const TQTimer *SVGTimer::qtimer() const
{
return m_timer;
}
-void SVGTimer::start(QObject *receiver, const char *member)
+void SVGTimer::start(TQObject *receiver, const char *member)
{
- QObject::connect(m_timer, SIGNAL(timeout()), receiver, member);
+ TQObject::connect(m_timer, TQT_SIGNAL(timeout()), receiver, member);
m_timer->start(m_ms, m_singleShot);
}
@@ -79,7 +79,7 @@ void SVGTimer::notifyAll()
if(m_notifyList.isEmpty())
return;
- QValueList<SVGElementImpl *> elements;
+ TQValueList<SVGElementImpl *> elements;
for(unsigned int i = m_notifyList.count();i > 0; i--)
{
SVGElementImpl *element = m_notifyList[i - 1];
@@ -98,7 +98,7 @@ void SVGTimer::notifyAll()
}
// Optimized update logic (to avoid 4 updates, on the same element)
- QValueList<SVGElementImpl *>::iterator it2;
+ TQValueList<SVGElementImpl *>::iterator it2;
for(it2 = elements.begin(); it2 != elements.end(); ++it2)
{
SVGShapeImpl *shape = dynamic_cast<SVGShapeImpl *>(*it2);
@@ -122,7 +122,7 @@ void SVGTimer::removeNotify(SVGElementImpl *element)
const unsigned int SVGTimeScheduler::staticTimerInterval = 15; // milliseconds
-SVGTimeScheduler::SVGTimeScheduler(SVGDocumentImpl *doc) : QObject(), m_doc(doc)
+SVGTimeScheduler::SVGTimeScheduler(SVGDocumentImpl *doc) : TQObject(), m_doc(doc)
{
// Create static interval timers but don't start it yet!
m_intervalTimer = new SVGTimer(this, staticTimerInterval, false);
@@ -165,7 +165,7 @@ void SVGTimeScheduler::startAnimations()
{
SVGTimer *svgTimer = *it;
if(svgTimer && !svgTimer->isActive())
- svgTimer->start(this, SLOT(slotTimerNotify()));
+ svgTimer->start(this, TQT_SLOT(slotTimerNotify()));
}
}
@@ -174,7 +174,7 @@ void SVGTimeScheduler::toggleAnimations()
if(m_intervalTimer->isActive())
m_intervalTimer->stop();
else
- m_intervalTimer->start(this, SLOT(slotTimerNotify()));
+ m_intervalTimer->start(this, TQT_SLOT(slotTimerNotify()));
}
bool SVGTimeScheduler::animationsPaused() const
@@ -184,7 +184,7 @@ bool SVGTimeScheduler::animationsPaused() const
void SVGTimeScheduler::slotTimerNotify()
{
- QTimer *senderTimer = const_cast<QTimer *>(static_cast<const QTimer *>(sender()));
+ TQTimer *senderTimer = const_cast<TQTimer *>(static_cast<const TQTimer *>(sender()));
SVGTimer *svgTimer = 0;
SVGTimerList::iterator it;
@@ -223,7 +223,7 @@ void SVGTimeScheduler::slotTimerNotify()
// by the previous call, and now all connections to the interval timer
// are created and now we just need to fire that timer (Niko)
if(svgTimer != m_intervalTimer && !m_intervalTimer->isActive())
- m_intervalTimer->start(this, SLOT(slotTimerNotify()));
+ m_intervalTimer->start(this, TQT_SLOT(slotTimerNotify()));
}
float SVGTimeScheduler::elapsed() const
diff --git a/ksvg/impl/SVGTimeScheduler.h b/ksvg/impl/SVGTimeScheduler.h
index ae4c6d37..52f9c9b9 100644
--- a/ksvg/impl/SVGTimeScheduler.h
+++ b/ksvg/impl/SVGTimeScheduler.h
@@ -21,10 +21,10 @@
#ifndef SVGTimeScheduler_H
#define SVGTimeScheduler_H
-#include <qtimer.h>
-#include <qdatetime.h>
-#include <qobject.h>
-#include <qvaluelist.h>
+#include <tqtimer.h>
+#include <tqdatetime.h>
+#include <tqobject.h>
+#include <tqvaluelist.h>
#include "SVGElementImpl.h"
#include "SVGAnimationElementImpl.h"
@@ -32,17 +32,17 @@
namespace KSVG
{
-typedef QValueList<SVGElementImpl *> SVGNotifyList;
+typedef TQValueList<SVGElementImpl *> SVGNotifyList;
class SVGTimer
{
public:
- SVGTimer(QObject *scheduler, unsigned int ms, bool singleShot);
+ SVGTimer(TQObject *scheduler, unsigned int ms, bool singleShot);
~SVGTimer();
- bool operator==(const QTimer *timer);
- const QTimer *qtimer() const;
+ bool operator==(const TQTimer *timer);
+ const TQTimer *qtimer() const;
- void start(QObject *receiver, const char *member);
+ void start(TQObject *receiver, const char *member);
void stop();
bool isActive() const;
@@ -58,11 +58,11 @@ private:
unsigned int m_ms;
bool m_invoked, m_singleShot;
- QTimer *m_timer;
+ TQTimer *m_timer;
SVGNotifyList m_notifyList;
};
-typedef QValueList<SVGTimer *> SVGTimerList;
+typedef TQValueList<SVGTimer *> SVGTimerList;
class SVGDocumentImpl;
class SVGTimeScheduler : public QObject
{
@@ -94,7 +94,7 @@ private:
SVGDocumentImpl *m_doc;
SVGTimerList m_timerList;
SVGTimer *m_intervalTimer;
- QTime m_creationTime;
+ TQTime m_creationTime;
};
}
diff --git a/ksvg/impl/SVGTransformImpl.cc b/ksvg/impl/SVGTransformImpl.cc
index 53ea9bf3..5b2d754a 100644
--- a/ksvg/impl/SVGTransformImpl.cc
+++ b/ksvg/impl/SVGTransformImpl.cc
@@ -120,27 +120,27 @@ void SVGTransformImpl::setSkewY(double angle)
m_matrix->skewY(angle);
}
-QString SVGTransformImpl::toString() const
+TQString SVGTransformImpl::toString() const
{
switch (m_type)
{
case SVG_TRANSFORM_UNKNOWN:
- return QString();
+ return TQString();
case SVG_TRANSFORM_MATRIX:
- return QString("matrix(" + QString::number(m_matrix->a()) + " " + QString::number(m_matrix->b()) + " " + QString::number(m_matrix->c()) + " " + QString::number(m_matrix->d()) + " " + QString::number(m_matrix->e()) + " " + QString::number(m_matrix->f()) + ")");
+ return TQString("matrix(" + TQString::number(m_matrix->a()) + " " + TQString::number(m_matrix->b()) + " " + TQString::number(m_matrix->c()) + " " + TQString::number(m_matrix->d()) + " " + TQString::number(m_matrix->e()) + " " + TQString::number(m_matrix->f()) + ")");
case SVG_TRANSFORM_TRANSLATE:
- return QString("translate(" + QString::number(m_matrix->e()) + " " + QString::number(m_matrix->f()) + ")");
+ return TQString("translate(" + TQString::number(m_matrix->e()) + " " + TQString::number(m_matrix->f()) + ")");
case SVG_TRANSFORM_SCALE:
- return QString("scale(" + QString::number(m_matrix->a()) + " " + QString::number(m_matrix->d()) + ")");
+ return TQString("scale(" + TQString::number(m_matrix->a()) + " " + TQString::number(m_matrix->d()) + ")");
case SVG_TRANSFORM_ROTATE:
- return QString("rotate(" + QString::number(m_angle) + " " + QString::number(m_cx) + " " + QString::number(m_cy) + ")");
+ return TQString("rotate(" + TQString::number(m_angle) + " " + TQString::number(m_cx) + " " + TQString::number(m_cy) + ")");
case SVG_TRANSFORM_SKEWX:
- return QString("skewX(" + QString::number(m_angle) + ")");
+ return TQString("skewX(" + TQString::number(m_angle) + ")");
case SVG_TRANSFORM_SKEWY:
- return QString("skewY(" + QString::number(m_angle) + ")");
+ return TQString("skewY(" + TQString::number(m_angle) + ")");
default:
kdWarning() << "Unknown transform type " << m_type << endl;
- return QString();
+ return TQString();
}
}
diff --git a/ksvg/impl/SVGTransformImpl.h b/ksvg/impl/SVGTransformImpl.h
index 69d71b8f..c52ffdf2 100644
--- a/ksvg/impl/SVGTransformImpl.h
+++ b/ksvg/impl/SVGTransformImpl.h
@@ -26,7 +26,7 @@
#include "ksvg_lookup.h"
-class QString;
+class TQString;
namespace KSVG
{
@@ -51,7 +51,7 @@ public:
void setSkewX(double);
void setSkewY(double);
- QString toString() const;
+ TQString toString() const;
private:
// mop: we have to store the optional rotate stuff :( anyone with a better solution please fix that ;)
diff --git a/ksvg/impl/SVGTransformableImpl.h b/ksvg/impl/SVGTransformableImpl.h
index edff5831..0ccd4908 100644
--- a/ksvg/impl/SVGTransformableImpl.h
+++ b/ksvg/impl/SVGTransformableImpl.h
@@ -21,7 +21,7 @@
#ifndef SVGTransformableImpl_H
#define SVGTransformableImpl_H
-#include <qstring.h>
+#include <tqstring.h>
#include "SVGLocatableImpl.h"
diff --git a/ksvg/impl/SVGURIReferenceImpl.cc b/ksvg/impl/SVGURIReferenceImpl.cc
index a68b7442..8a6fda76 100644
--- a/ksvg/impl/SVGURIReferenceImpl.cc
+++ b/ksvg/impl/SVGURIReferenceImpl.cc
@@ -48,7 +48,7 @@ SVGAnimatedStringImpl *SVGURIReferenceImpl::href() const
return m_href;
}
-bool SVGURIReferenceImpl::parseURIReference(const QString &urireference, QString &uri, QString &elementreference)
+bool SVGURIReferenceImpl::parseURIReference(const TQString &urireference, TQString &uri, TQString &elementreference)
{
int seperator = urireference.find("#");
@@ -61,13 +61,13 @@ bool SVGURIReferenceImpl::parseURIReference(const QString &urireference, QString
return true;
}
-bool SVGURIReferenceImpl::isUrl(const QString &url)
+bool SVGURIReferenceImpl::isUrl(const TQString &url)
{
- QString temp = url.stripWhiteSpace();
+ TQString temp = url.stripWhiteSpace();
return temp.startsWith("url(#") && temp.endsWith(")");
}
-QString SVGURIReferenceImpl::getTarget(const QString &url)
+TQString SVGURIReferenceImpl::getTarget(const TQString &url)
{
if(url.startsWith("url(")) // URI References, ie. fill:url(#target)
{
diff --git a/ksvg/impl/SVGURIReferenceImpl.h b/ksvg/impl/SVGURIReferenceImpl.h
index d6ee42c5..8d6500b0 100644
--- a/ksvg/impl/SVGURIReferenceImpl.h
+++ b/ksvg/impl/SVGURIReferenceImpl.h
@@ -23,7 +23,7 @@
#include "ksvg_lookup.h"
-class QString;
+class TQString;
namespace KSVG
{
@@ -36,9 +36,9 @@ public:
~SVGURIReferenceImpl();
SVGAnimatedStringImpl *href() const;
- static QString getTarget(const QString &url);
- static bool isUrl(const QString &url);
- static bool parseURIReference(const QString &urireference, QString &uri, QString &elementreference);
+ static TQString getTarget(const TQString &url);
+ static bool isUrl(const TQString &url);
+ static bool parseURIReference(const TQString &urireference, TQString &uri, TQString &elementreference);
protected:
SVGAnimatedStringImpl *m_href;
diff --git a/ksvg/impl/SVGUnitConverter.h b/ksvg/impl/SVGUnitConverter.h
index 90c95796..78eb2528 100644
--- a/ksvg/impl/SVGUnitConverter.h
+++ b/ksvg/impl/SVGUnitConverter.h
@@ -21,7 +21,7 @@
#ifndef SVGUnitConverter_H
#define SVGUnitConverter_H
-#include <qptrdict.h>
+#include <tqptrdict.h>
#include <dom/dom_string.h>
@@ -41,12 +41,12 @@ public:
void add(SVGAnimatedLengthImpl *obj)
{
UnitData *data = new UnitData();
- data->valueAsString = QString::null;
+ data->valueAsString = TQString::null;
m_dict.insert(obj, data);
}
- void modify(SVGAnimatedLengthImpl *obj, const QString &value)
+ void modify(SVGAnimatedLengthImpl *obj, const TQString &value)
{
UnitData *data = m_dict.find(obj);
@@ -62,7 +62,7 @@ public:
if(!user && !bbox) // Invalid unit type
return;
- QPtrDictIterator<UnitData> it(m_dict);
+ TQPtrDictIterator<UnitData> it(m_dict);
for(; it.current(); ++it)
{
UnitData *data = it.current();
@@ -87,10 +87,10 @@ public:
private:
typedef struct
{
- QString valueAsString; // Original value
+ TQString valueAsString; // Original value
} UnitData;
- QPtrDict<UnitData> m_dict;
+ TQPtrDict<UnitData> m_dict;
};
}
diff --git a/ksvg/impl/SVGUseElementImpl.cc b/ksvg/impl/SVGUseElementImpl.cc
index 3bd38a42..457436cb 100644
--- a/ksvg/impl/SVGUseElementImpl.cc
+++ b/ksvg/impl/SVGUseElementImpl.cc
@@ -20,7 +20,7 @@
#include <kdebug.h>
-#include <qstring.h>
+#include <tqstring.h>
#include "KSVGLoader.h"
#include "KSVGCanvas.h"
@@ -169,7 +169,7 @@ void SVGUseElementImpl::putValueProperty(ExecState *exec, int token, const Value
break;
case Href:
{
- QString url = value.toString(exec).qstring();
+ TQString url = value.toString(exec).qstring();
href()->setBaseVal(SVGURIReferenceImpl::getTarget(url));
break;
}
@@ -212,7 +212,7 @@ void SVGUseElementImpl::createItem(KSVGCanvas *c)
{
// ownerSVGElement()->getElementById() is wrong here.
// It could reference elements from other documents when using getURL (Niko)
- QString filename, id;
+ TQString filename, id;
DOM::DOMString url = getAttribute("href");
if(!SVGURIReferenceImpl::parseURIReference(url.string(), filename, id))
return;
@@ -223,7 +223,7 @@ void SVGUseElementImpl::createItem(KSVGCanvas *c)
KURL fragmentUrl(ownerDoc()->baseUrl(), url.string());
id = fragmentUrl.ref();
- fragmentUrl.setRef(QString::null);
+ fragmentUrl.setRef(TQString::null);
orig = KSVGLoader::getSVGFragment(fragmentUrl, ownerDoc(), id);
}
@@ -250,11 +250,11 @@ void SVGUseElementImpl::createItem(KSVGCanvas *c)
SVGElementImpl *clone = orig->cloneNode(true);
// Apply the use-correction
- QString trans;
+ TQString trans;
trans += " translate(";
- trans += QString::number(x()->baseVal()->value());
+ trans += TQString::number(x()->baseVal()->value());
trans += " ";
- trans += QString::number(y()->baseVal()->value());
+ trans += TQString::number(y()->baseVal()->value());
trans += ")";
// Apply the transform attribute and render the element
@@ -304,7 +304,7 @@ void SVGUseElementImpl::createItem(KSVGCanvas *c)
dynamic_cast<SVGLocatableImpl *>(parent)->updateCachedScreenCTM(screenCTM());
// Redirect local ecma event handlers to the correspondingElement
- QPtrListIterator<SVGRegisteredEventListener> it(eventListeners());
+ TQPtrListIterator<SVGRegisteredEventListener> it(eventListeners());
SVGRegisteredEventListener *eventListener;
while((eventListener = it.current()) != 0)
{
diff --git a/ksvg/impl/SVGViewSpecImpl.cc b/ksvg/impl/SVGViewSpecImpl.cc
index 07412cc5..6a225626 100644
--- a/ksvg/impl/SVGViewSpecImpl.cc
+++ b/ksvg/impl/SVGViewSpecImpl.cc
@@ -20,7 +20,7 @@
#include <kdebug.h>
-#include <qstringlist.h>
+#include <tqstringlist.h>
#include "SVGElementImpl.h"
#include "SVGViewSpecImpl.h"
@@ -75,15 +75,15 @@ DOM::DOMString SVGViewSpecImpl::viewTargetString() const
return m_viewTargetString;
}
-bool SVGViewSpecImpl::parseViewSpec(const QString &s)
+bool SVGViewSpecImpl::parseViewSpec(const TQString &s)
{
if(!s.startsWith("svgView("))
return false;
// remove 'svgView(' and ')'
- QStringList subAttrs = QStringList::split(';', s.mid(8));
+ TQStringList subAttrs = TQStringList::split(';', s.mid(8));
- for(QStringList::ConstIterator it = subAttrs.begin() ; it != subAttrs.end(); ++it)
+ for(TQStringList::ConstIterator it = subAttrs.begin() ; it != subAttrs.end(); ++it)
{
if((*it).startsWith("viewBox("))
m_viewBoxString = (*it).mid(8);
diff --git a/ksvg/impl/SVGViewSpecImpl.h b/ksvg/impl/SVGViewSpecImpl.h
index f9e01e48..2bdf849b 100644
--- a/ksvg/impl/SVGViewSpecImpl.h
+++ b/ksvg/impl/SVGViewSpecImpl.h
@@ -47,7 +47,7 @@ public:
DOM::DOMString transformString() const;
DOM::DOMString viewTargetString() const;
- bool parseViewSpec(const QString &);
+ bool parseViewSpec(const TQString &);
private:
SVGTransformListImpl *m_transform;
diff --git a/ksvg/impl/SVGWindowImpl.cc b/ksvg/impl/SVGWindowImpl.cc
index b19847a4..476185f1 100644
--- a/ksvg/impl/SVGWindowImpl.cc
+++ b/ksvg/impl/SVGWindowImpl.cc
@@ -26,7 +26,7 @@
#include <ksvg_ecma.h>
#include <ksvg_scriptinterpreter.h>
-#include <qstylesheet.h>
+#include <tqstylesheet.h>
#include <kurl.h>
#include <kmessagebox.h>
@@ -113,7 +113,7 @@ void SVGWindowImpl::postURL(const DOM::DOMString &/*uri*/, const DOM::DOMString
DOM::DOMString SVGWindowImpl::printNode(const DOM::Node &node, unsigned short level)
{
- QString ret;
+ TQString ret;
if(node.isNull()) return ret;
SVGElementImpl *elem = m_document->getElementFromHandle(node.handle());
if(node.nodeType() == DOM::Node::DOCUMENT_NODE)
@@ -130,7 +130,7 @@ DOM::DOMString SVGWindowImpl::printNode(const DOM::Node &node, unsigned short le
printIndentation(ret, level);
ret += "<" + elem->tagName().string();
// handle attrs
- QDictIterator<DOM::DOMString> it(elem->attributes());
+ TQDictIterator<DOM::DOMString> it(elem->attributes());
for(;it.current(); ++it)
ret += " " + it.currentKey() + "=\"" + it.current()->string() + '\"';
if(elem->firstChild().isNull()) // no children
@@ -147,7 +147,7 @@ DOM::DOMString SVGWindowImpl::printNode(const DOM::Node &node, unsigned short le
return ret;
}
-void SVGWindowImpl::printIndentation(QString &ret, unsigned short level, unsigned short indent)
+void SVGWindowImpl::printIndentation(TQString &ret, unsigned short level, unsigned short indent)
{
for(int i = 0;i < indent * level;i++)
ret += " ";
@@ -163,21 +163,21 @@ long SVGWindowImpl::setTimeout(const DOM::DOMString &/*code*/, const long &/*del
return 0;
}
-void SVGWindowImpl::alert(const DOM::DOMString &message, const QString &title)
+void SVGWindowImpl::alert(const DOM::DOMString &message, const TQString &title)
{
- KMessageBox::error(0L, QStyleSheet::convertFromPlainText(message.string()), title);
+ KMessageBox::error(0L, TQStyleSheet::convertFromPlainText(message.string()), title);
}
-bool SVGWindowImpl::confirm(const DOM::DOMString &message, const QString &title)
+bool SVGWindowImpl::confirm(const DOM::DOMString &message, const TQString &title)
{
- return KMessageBox::warningContinueCancel(0L, QStyleSheet::convertFromPlainText(message.string()), title, KStdGuiItem::ok()) == KMessageBox::Continue;
+ return KMessageBox::warningContinueCancel(0L, TQStyleSheet::convertFromPlainText(message.string()), title, KStdGuiItem::ok()) == KMessageBox::Continue;
}
-DOM::DOMString SVGWindowImpl::prompt(const DOM::DOMString &message, const DOM::DOMString &_default, const QString &)
+DOM::DOMString SVGWindowImpl::prompt(const DOM::DOMString &message, const DOM::DOMString &_default, const TQString &)
{
bool ok;
- QString str;
- str = KInputDialog::getText(i18n("Prompt"), QStyleSheet::convertFromPlainText(message.string()), _default.string(), &ok);
+ TQString str;
+ str = KInputDialog::getText(i18n("Prompt"), TQStyleSheet::convertFromPlainText(message.string()), _default.string(), &ok);
if(ok)
return str;
else
diff --git a/ksvg/impl/SVGWindowImpl.h b/ksvg/impl/SVGWindowImpl.h
index 0861809e..72e95741 100644
--- a/ksvg/impl/SVGWindowImpl.h
+++ b/ksvg/impl/SVGWindowImpl.h
@@ -54,12 +54,12 @@ public:
DOM::DOMString printNode(const DOM::Node &node, unsigned short level = 0);
long setInterval(const DOM::DOMString &code, const long &delay);
long setTimeout(const DOM::DOMString &code, const long &delay);
- static void alert(const DOM::DOMString &message, const QString &title = "SVG Window");
- static bool confirm(const DOM::DOMString &message, const QString &title = "SVG Window");
- static DOM::DOMString prompt(const DOM::DOMString &message, const DOM::DOMString &_default, const QString &title = "SVG Window");
+ static void alert(const DOM::DOMString &message, const TQString &title = "SVG Window");
+ static bool confirm(const DOM::DOMString &message, const TQString &title = "SVG Window");
+ static DOM::DOMString prompt(const DOM::DOMString &message, const DOM::DOMString &_default, const TQString &title = "SVG Window");
private:
- void printIndentation(QString &ret, unsigned short level, unsigned short indent = 2);
+ void printIndentation(TQString &ret, unsigned short level, unsigned short indent = 2);
private:
//StyleSheet m_defaultStyleSheet;
diff --git a/ksvg/impl/libs/libtext2path/src/QtUnicode.cpp b/ksvg/impl/libs/libtext2path/src/QtUnicode.cpp
index 694ed5c7..33855a81 100644
--- a/ksvg/impl/libs/libtext2path/src/QtUnicode.cpp
+++ b/ksvg/impl/libs/libtext2path/src/QtUnicode.cpp
@@ -38,8 +38,8 @@
using namespace T2P;
// START OF GENERATED DATA
-// copied form qfont.h, as we can't include it in tools. Do not modify without
-// changing the script enum in qfont.h aswell.
+// copied form tqfont.h, as we can't include it in tools. Do not modify without
+// changing the script enum in tqfont.h aswell.
const unsigned char QtUnicode::otherScripts [120] = {
#define SCRIPTS_02 0
0xaf, Latin, 0xff, SpacingModifiers, // row 0x02, index 0
diff --git a/ksvg/impl/svgpathparser.cc b/ksvg/impl/svgpathparser.cc
index 0f7521e0..590ac2ba 100644
--- a/ksvg/impl/svgpathparser.cc
+++ b/ksvg/impl/svgpathparser.cc
@@ -18,7 +18,7 @@
*/
#include "svgpathparser.h"
-#include <qstring.h>
+#include <tqstring.h>
#include <math.h>
// parses the number into parameter number
@@ -95,11 +95,11 @@ SVGPathParser::getCoord( const char *ptr, double &number )
}
void
-SVGPathParser::parseSVG( const QString &s, bool process )
+SVGPathParser::parseSVG( const TQString &s, bool process )
{
if(!s.isEmpty())
{
- QString d = s;
+ TQString d = s;
d = d.replace(',', ' ');
d = d.simplifyWhiteSpace();
const char *ptr = d.latin1();
diff --git a/ksvg/impl/svgpathparser.h b/ksvg/impl/svgpathparser.h
index 3a9495d0..efbe4b79 100644
--- a/ksvg/impl/svgpathparser.h
+++ b/ksvg/impl/svgpathparser.h
@@ -20,7 +20,7 @@
#ifndef __SVGPATHPARSER_H__
#define __SVGPATHPARSER_H__
-class QString;
+class TQString;
namespace KSVG
{
@@ -41,7 +41,7 @@ namespace KSVG
class SVGPathParser
{
public:
- void parseSVG( const QString &d, bool process = false );
+ void parseSVG( const TQString &d, bool process = false );
static const char *getCoord( const char *, double & );
diff --git a/ksvg/plugin/backends/agg/AggCanvasFactory.cpp b/ksvg/plugin/backends/agg/AggCanvasFactory.cpp
index 439623ad..368cb252 100644
--- a/ksvg/plugin/backends/agg/AggCanvasFactory.cpp
+++ b/ksvg/plugin/backends/agg/AggCanvasFactory.cpp
@@ -35,7 +35,7 @@ AggCanvasFactory::~AggCanvasFactory()
{
}
-QObject *AggCanvasFactory::createObject(QObject *, const char *, const char *, const QStringList &args)
+TQObject *AggCanvasFactory::createObject(TQObject *, const char *, const char *, const TQStringList &args)
{
unsigned int width = (*args.at(1)).toUInt();
unsigned int height = (*args.at(0)).toUInt();
diff --git a/ksvg/plugin/backends/agg/AggCanvasFactory.h b/ksvg/plugin/backends/agg/AggCanvasFactory.h
index 9fb3ffbf..8e7d4747 100644
--- a/ksvg/plugin/backends/agg/AggCanvasFactory.h
+++ b/ksvg/plugin/backends/agg/AggCanvasFactory.h
@@ -35,7 +35,7 @@ public:
AggCanvasFactory();
virtual ~AggCanvasFactory();
- virtual QObject *createObject(QObject *parent = 0, const char *pname = 0, const char *name = "QObject", const QStringList &args = QStringList());
+ virtual TQObject *createObject(TQObject *parent = 0, const char *pname = 0, const char *name = "TQObject", const TQStringList &args = TQStringList());
};
};
diff --git a/ksvg/plugin/backends/agg/AggCanvasItems.cpp b/ksvg/plugin/backends/agg/AggCanvasItems.cpp
index 4ceb6109..be4727ac 100644
--- a/ksvg/plugin/backends/agg/AggCanvasItems.cpp
+++ b/ksvg/plugin/backends/agg/AggCanvasItems.cpp
@@ -18,7 +18,7 @@
Boston, MA 02110-1301, USA.
*/
-#include <qimage.h>
+#include <tqimage.h>
#include "SVGPaint.h"
#include "SVGRectImpl.h"
@@ -207,12 +207,12 @@ AggShape::~AggShape()
delete m_strokePainter;
}
-QRect AggShape::bbox() const
+TQRect AggShape::bbox() const
{
return m_bbox;
}
-bool AggShape::fillContains(const QPoint &p)
+bool AggShape::fillContains(const TQPoint &p)
{
agg::rasterizer_scanline_aa<> ras;
ras.filling_rule(m_style->getFillRule() == RULE_EVENODD ? agg::fill_even_odd : agg::fill_non_zero);
@@ -221,7 +221,7 @@ bool AggShape::fillContains(const QPoint &p)
return b;
}
-bool AggShape::strokeContains(const QPoint &p)
+bool AggShape::strokeContains(const TQPoint &p)
{
agg::rasterizer_scanline_aa<> ras;
ras.add_path(m_curved_stroked_trans);
@@ -287,7 +287,7 @@ void AggShape::draw(SVGShapeImpl *shape)
double x1, y1, x2, y2;
agg::bounding_rect(m_curved_trans, *this, 0, 1, &x1, &y1, &x2, &y2);
- m_bbox = QRect(int(x1), int(y1), int(x2 - x1), int(y2 - y1));
+ m_bbox = TQRect(int(x1), int(y1), int(x2 - x1), int(y2 - y1));
m_curved.approximation_scale(pow(m_transform.scale(), 0.75));
@@ -309,7 +309,7 @@ void AggShape::calcSVPs(const SVGMatrixImpl *matrix)
double x1, y1, x2, y2;
agg::bounding_rect(m_curved_trans, *this, 0, 1, &x1, &y1, &x2, &y2);
- m_bbox = QRect(int(x1), int(y1), int(x2 - x1), int(y2 - y1));
+ m_bbox = TQRect(int(x1), int(y1), int(x2 - x1), int(y2 - y1));
}
void AggShape::init(const SVGMatrixImpl *)
@@ -358,7 +358,7 @@ void AggStrokePaintServer::update(SVGStylableImpl *style)
{
if(style->getStrokeColor()->paintType() != SVG_PAINTTYPE_URI)
{
- QColor qcolor;
+ TQColor qcolor;
if(style->getStrokeColor()->paintType() == SVG_PAINTTYPE_CURRENTCOLOR)
qcolor = style->getColor()->rgbColor().color();
else
@@ -407,7 +407,7 @@ void AggFillPaintServer::update(SVGStylableImpl *style)
{
if(style->getFillColor()->paintType() != SVG_PAINTTYPE_URI)
{
- QColor qcolor;
+ TQColor qcolor;
if(style->getFillColor()->paintType() == SVG_PAINTTYPE_CURRENTCOLOR)
qcolor = style->getColor()->rgbColor().color();
else
@@ -678,7 +678,7 @@ void AggLine::draw()
{
m_canvas->m_ras.reset();
m_canvas->m_ras.add_path(m_curved_stroked_trans);
- QColor qcolor;
+ TQColor qcolor;
if(m_style->getStrokeColor()->paintType() == SVG_PAINTTYPE_CURRENTCOLOR)
qcolor = m_style->getColor()->rgbColor().color();
else
@@ -995,9 +995,9 @@ void AggImage::draw()
{
//KSVGPolygon clippingPolygon = m_image->clippingShape();
- QImage *img = m_image->image();
+ TQImage *img = m_image->image();
if(!img) return;
- QImage image = m_image->scaledImage();
+ TQImage image = m_image->scaledImage();
agg::rendering_buffer source_buffer;
source_buffer.attach(image.bits(), image.width(), image.height(), image.width() * 4);
@@ -1053,9 +1053,9 @@ void AggImage::init()
{
}
-QRect AggImage::bbox() const
+TQRect AggImage::bbox() const
{
- QRect bbox(static_cast<int>(m_image->x()->baseVal()->value()),
+ TQRect bbox(static_cast<int>(m_image->x()->baseVal()->value()),
static_cast<int>(m_image->y()->baseVal()->value()),
static_cast<int>(m_image->width()->baseVal()->value()),
static_cast<int>(m_image->height()->baseVal()->value()));
@@ -1077,9 +1077,9 @@ AggText::~AggText()
{
}
-bool AggText::fillContains(const QPoint &p)
+bool AggText::fillContains(const TQPoint &p)
{
- QPtrListIterator<SVPElement> it(m_drawItems);
+ TQPtrListIterator<SVPElement> it(m_drawItems);
SVPElement *fill = it.current();
while(fill)
@@ -1099,9 +1099,9 @@ bool AggText::fillContains(const QPoint &p)
return false;
}
-bool AggText::strokeContains(const QPoint &p)
+bool AggText::strokeContains(const TQPoint &p)
{
- QPtrListIterator<SVPElement> it(m_drawItems);
+ TQPtrListIterator<SVPElement> it(m_drawItems);
SVPElement *stroke = it.current();
while(stroke)
@@ -1121,11 +1121,11 @@ bool AggText::strokeContains(const QPoint &p)
return false;
}
-QRect AggText::bbox() const
+TQRect AggText::bbox() const
{
- QRect result, rect;
+ TQRect result, rect;
- QPtrListIterator<SVPElement> it(m_drawItems);
+ TQPtrListIterator<SVPElement> it(m_drawItems);
SVPElement *elem = it.current();
while(elem)
@@ -1152,7 +1152,7 @@ void AggText::update(CanvasItemUpdate reason, int param1, int param2)
{
if(reason == UPDATE_STYLE)
{
- QPtrListIterator<SVPElement> it(m_drawItems);
+ TQPtrListIterator<SVPElement> it(m_drawItems);
SVPElement *svpelement = it.current();
SVGTextContentElementImpl *text;
@@ -1181,7 +1181,7 @@ void AggText::update(CanvasItemUpdate reason, int param1, int param2)
}
else if(reason == UPDATE_PAN)
{
- QPtrListIterator<SVPElement> it(m_drawItems);
+ TQPtrListIterator<SVPElement> it(m_drawItems);
SVPElement *svpelement = it.current();
T2P::BezierPathAgg *bpath;
@@ -1202,7 +1202,7 @@ void AggText::update(CanvasItemUpdate reason, int param1, int param2)
void AggText::draw()
{
- QPtrListIterator<SVPElement> it(m_drawItems);
+ TQPtrListIterator<SVPElement> it(m_drawItems);
SVPElement *svpelement = it.current();
BezierPathAggStroked *bpath;
@@ -1229,7 +1229,7 @@ void AggText::draw()
bool AggText::isVisible()
{
bool foundVisible = false;
- QPtrListIterator<SVPElement> it(m_drawItems);
+ TQPtrListIterator<SVPElement> it(m_drawItems);
SVPElement *svpelement = it.current();
SVGTextContentElementImpl *text;
@@ -1361,7 +1361,7 @@ void AggGradient::parseGradientStops(SVGGradientElementImpl *gradient)
//offsets++;
// Get color
- QColor qStopColor;
+ TQColor qStopColor;
if(elem->getStopColor()->colorType() == SVG_COLORTYPE_CURRENTCOLOR)
qStopColor = elem->getColor()->rgbColor().color();
@@ -1369,7 +1369,7 @@ void AggGradient::parseGradientStops(SVGGradientElementImpl *gradient)
qStopColor = elem->getStopColor()->rgbColor().color();
// Convert in an agg suitable form
- QString tempName = qStopColor.name();
+ TQString tempName = qStopColor.name();
const char *str = tempName.latin1();
// We need to take into account fill/stroke opacity, if available (Rob)
@@ -1449,14 +1449,14 @@ void AggGradient::finalizePaintServer()
{
parseGradientStops(m_gradient->stopsSource());
- QString _href = SVGURIReferenceImpl::getTarget(m_gradient->href()->baseVal().string());
+ TQString _href = SVGURIReferenceImpl::getTarget(m_gradient->href()->baseVal().string());
if(!_href.isEmpty())
reference(_href);
setFinalized();
}
-void AggGradient::reference(const QString &/*href*/)
+void AggGradient::reference(const TQString &/*href*/)
{
}
@@ -1475,7 +1475,7 @@ void AggLinearGradient::render(AggCanvas *c)
SVGMatrixImpl *gradTrans = linear->gradientTransform()->baseVal()->concatenate();
if(gradTrans)
{
- QWMatrix m = gradTrans->qmatrix();
+ TQWMatrix m = gradTrans->qmatrix();
m.map(_x1, _y1, &_x1, &_y1);
m.map(_x2, _y2, &_x2, &_y2);
gradTrans->deref();
@@ -1613,7 +1613,7 @@ void AggRadialGradient::render(AggCanvas *c)
if(gradTrans)
{
agg::trans_affine mtx;
- QWMatrix m = gradTrans->qmatrix();
+ TQWMatrix m = gradTrans->qmatrix();
mtx = agg::trans_affine(m.m11(), m.m12(), m.m21(), m.m22(), m.dx(), m.dy());
gradTrans->deref();
mtx_g1 *= mtx;
@@ -1693,7 +1693,7 @@ void AggPattern::finalizePaintServer()
setFinalized();
}
-void AggPattern::reference(const QString &href)
+void AggPattern::reference(const TQString &href)
{
m_pattern->reference(href);
}
@@ -1704,7 +1704,7 @@ void AggPattern::render(AggCanvas *c)
if(!tile.image().isNull())
{
- QWMatrix m = tile.screenToTile();
+ TQWMatrix m = tile.screenToTile();
double affine[6];
affine[0] = m.m11();
diff --git a/ksvg/plugin/backends/agg/AggCanvasItems.h b/ksvg/plugin/backends/agg/AggCanvasItems.h
index a8c242ec..b5599952 100644
--- a/ksvg/plugin/backends/agg/AggCanvasItems.h
+++ b/ksvg/plugin/backends/agg/AggCanvasItems.h
@@ -200,7 +200,7 @@ namespace KSVG
virtual ~AggPaintServer() {}
virtual void finalizePaintServer() = 0;
- virtual void reference(const QString &href) = 0;
+ virtual void reference(const TQString &href) = 0;
virtual void render(AggCanvas *c) = 0;
};
@@ -214,7 +214,7 @@ namespace KSVG
void parseGradientStops(SVGGradientElementImpl *gradient);
virtual void finalizePaintServer();
- virtual void reference(const QString &href);
+ virtual void reference(const TQString &href);
protected:
SVGGradientElementImpl *m_gradient;
@@ -254,7 +254,7 @@ namespace KSVG
virtual ~AggPattern() {}
virtual void finalizePaintServer();
- virtual void reference(const QString &);
+ virtual void reference(const TQString &);
virtual void render(AggCanvas *c);
@@ -307,9 +307,9 @@ namespace KSVG
AggShape(AggCanvas *c, SVGStylableImpl *style);
virtual ~AggShape();
- virtual QRect bbox() const;
- virtual bool fillContains(const QPoint &p);
- virtual bool strokeContains(const QPoint &p);
+ virtual TQRect bbox() const;
+ virtual bool fillContains(const TQPoint &p);
+ virtual bool strokeContains(const TQPoint &p);
virtual void update(CanvasItemUpdate reason, int param1 = 0, int param2 = 0);
void draw(SVGShapeImpl *shape);
void calcSVPs(const SVGMatrixImpl *matrix);
@@ -416,9 +416,9 @@ namespace KSVG
AggMarker(AggCanvas *c, SVGMarkerElementImpl *marker);
virtual ~AggMarker();
- virtual QRect bbox() const { return QRect(); }
- virtual bool fillContains(const QPoint &) { return true; }
- virtual bool strokeContains(const QPoint &) { return true; }
+ virtual TQRect bbox() const { return TQRect(); }
+ virtual bool fillContains(const TQPoint &) { return true; }
+ virtual bool strokeContains(const TQPoint &) { return true; }
virtual void update(CanvasItemUpdate, int = 0, int = 0) { }
virtual void init();
virtual void draw();
@@ -438,9 +438,9 @@ namespace KSVG
AggImage(AggCanvas *c, SVGImageElementImpl *image);
virtual ~AggImage();
- virtual QRect bbox() const;
- virtual bool fillContains(const QPoint &) { return true; }
- virtual bool strokeContains(const QPoint &) { return true; }
+ virtual TQRect bbox() const;
+ virtual bool fillContains(const TQPoint &) { return true; }
+ virtual bool strokeContains(const TQPoint &) { return true; }
virtual void update(CanvasItemUpdate, int = 0, int = 0) { }
virtual void init();
virtual void draw();
@@ -459,9 +459,9 @@ namespace KSVG
AggText(AggCanvas *c, SVGTextElementImpl *text);
virtual ~AggText();
- virtual QRect bbox() const;
- virtual bool fillContains(const QPoint &p);
- virtual bool strokeContains(const QPoint &p);
+ virtual TQRect bbox() const;
+ virtual bool fillContains(const TQPoint &p);
+ virtual bool strokeContains(const TQPoint &p);
virtual void update(CanvasItemUpdate, int param1 = 0, int param2 = 0);
virtual void draw();
virtual bool isVisible();
@@ -491,7 +491,7 @@ namespace KSVG
AggStrokePaintServer *strokePainter;
};
- mutable QPtrList<SVPElement> m_drawItems;
+ mutable TQPtrList<SVPElement> m_drawItems;
};
};
diff --git a/ksvg/plugin/backends/libart/BezierPathLibart.h b/ksvg/plugin/backends/libart/BezierPathLibart.h
index a6dfd2b9..dd8fda6f 100644
--- a/ksvg/plugin/backends/libart/BezierPathLibart.h
+++ b/ksvg/plugin/backends/libart/BezierPathLibart.h
@@ -22,7 +22,7 @@
#define T2P_BEZIERPATH_LIBART_H
#include "BezierPath.h"
-#include <qmemarray.h>
+#include <tqmemarray.h>
class _ArtBpath;
@@ -42,7 +42,7 @@ namespace T2P
virtual void boundingBox(Point *topLeft, Point *bottomRight);
// Don't make those private members, these are all internal anyway...
- QMemArray<_ArtBpath> m_array;
+ TQMemArray<_ArtBpath> m_array;
double m_length;
};
}
diff --git a/ksvg/plugin/backends/libart/LibartCanvas.cpp b/ksvg/plugin/backends/libart/LibartCanvas.cpp
index 5697b623..55b371dd 100644
--- a/ksvg/plugin/backends/libart/LibartCanvas.cpp
+++ b/ksvg/plugin/backends/libart/LibartCanvas.cpp
@@ -44,9 +44,9 @@
#include "SVGPaint.h"
-#include <qdatetime.h>
-#include <qstring.h>
-#include <qimage.h>
+#include <tqdatetime.h>
+#include <tqstring.h>
+#include <tqimage.h>
#include "KSVGHelper.h"
#include "KSVGTextChunk.h"
@@ -91,7 +91,7 @@ ArtSVP *art_svp_from_irect(ArtIRect *bbox)
return art_svp_from_rect(bbox->x0, bbox->y0, bbox->x1, bbox->y1);
}
-ArtSVP *art_svp_from_qrect(const QRect& rect)
+ArtSVP *art_svp_from_qrect(const TQRect& rect)
{
return art_svp_from_rect(rect.left(), rect.top(), rect.right() + 1, rect.bottom() + 1);
}
@@ -153,7 +153,7 @@ CanvasItem *LibartCanvas::createPath(SVGPathElementImpl *path)
CanvasItem *LibartCanvas::createClipPath(SVGClipPathElementImpl *clippath)
{
CanvasClipPath *result = new LibartClipPath(this, clippath);
- QString index = clippath->id().string();
+ TQString index = clippath->id().string();
m_clipPaths.insert(index, result);
return result;
}
@@ -185,7 +185,7 @@ CanvasPaintServer *LibartCanvas::createPaintServer(SVGElementImpl *pserver)
return result;
}
-void LibartCanvas::drawImage(QImage image, SVGStylableImpl *style, const SVGMatrixImpl *matrix, const KSVGPolygon& clippingPolygon)
+void LibartCanvas::drawImage(TQImage image, SVGStylableImpl *style, const SVGMatrixImpl *matrix, const KSVGPolygon& clippingPolygon)
{
SVGShapeImpl *shape = dynamic_cast<SVGShapeImpl *>(style);
@@ -212,9 +212,9 @@ void LibartCanvas::drawImage(QImage image, SVGStylableImpl *style, const SVGMatr
{
clipToBuffer(x0, y0, x1, y1);
- QRect screenBBox(x0, y0, x1 - x0 + 1, y1 - y0 + 1);
+ TQRect screenBBox(x0, y0, x1 - x0 + 1, y1 - y0 + 1);
- QByteArray mask = SVGMaskElementImpl::maskRectangle(shape, screenBBox);
+ TQByteArray mask = SVGMaskElementImpl::maskRectangle(shape, screenBBox);
double affine[6];
KSVGHelper::matrixToAffine(matrix, affine);
@@ -227,7 +227,7 @@ void LibartCanvas::drawImage(QImage image, SVGStylableImpl *style, const SVGMatr
}
}
-ArtSVP *LibartCanvas::clippingRect(const QRect &rect, const SVGMatrixImpl *ctm)
+ArtSVP *LibartCanvas::clippingRect(const TQRect &rect, const SVGMatrixImpl *ctm)
{
ArtVpath *vec = allocVPath(6);
// Order of points in clipping rectangle must be counter-clockwise
@@ -273,7 +273,7 @@ ArtSVP *LibartCanvas::clipSingleSVP(ArtSVP *svp, SVGShapeImpl *shape)
if(style)
{
- QString clipPathRef = style->getClipPath();
+ TQString clipPathRef = style->getClipPath();
if(!clipPathRef.isEmpty())
{
@@ -354,7 +354,7 @@ ArtSVP *LibartCanvas::clipSingleSVP(ArtSVP *svp, SVGShapeImpl *shape)
return clippedSvp;
}
-void LibartCanvas::drawSVP(ArtSVP *svp, art_u32 color, QByteArray mask, QRect screenBBox)
+void LibartCanvas::drawSVP(ArtSVP *svp, art_u32 color, TQByteArray mask, TQRect screenBBox)
{
int x0 = screenBBox.left();
int y0 = screenBBox.top();
diff --git a/ksvg/plugin/backends/libart/LibartCanvas.h b/ksvg/plugin/backends/libart/LibartCanvas.h
index e0da1682..9232789a 100644
--- a/ksvg/plugin/backends/libart/LibartCanvas.h
+++ b/ksvg/plugin/backends/libart/LibartCanvas.h
@@ -32,8 +32,8 @@
#include <Converter.h>
#include "GlyphTracerLibart.h"
-class QString;
-class QImage;
+class TQString;
+class TQImage;
struct _ArtSVP;
@@ -50,8 +50,8 @@ class LibartCanvas : public KSVGCanvas
public:
LibartCanvas(unsigned int width, unsigned int height);
- void drawSVP(_ArtSVP *svp, art_u32 color, QByteArray mask, QRect screenBBox);
- void drawImage(QImage image, SVGStylableImpl *style, const SVGMatrixImpl *matrix, const KSVGPolygon& clippingPolygon);
+ void drawSVP(_ArtSVP *svp, art_u32 color, TQByteArray mask, TQRect screenBBox);
+ void drawImage(TQImage image, SVGStylableImpl *style, const SVGMatrixImpl *matrix, const KSVGPolygon& clippingPolygon);
virtual T2P::BezierPath *toBezierPath(CanvasItem *item) const;
@@ -69,7 +69,7 @@ public:
virtual CanvasItem *createText(SVGTextElementImpl *text);
virtual CanvasPaintServer *createPaintServer(SVGElementImpl *pserver);
- _ArtSVP *clippingRect(const QRect &rect, const SVGMatrixImpl *ctm);
+ _ArtSVP *clippingRect(const TQRect &rect, const SVGMatrixImpl *ctm);
_ArtSVP *svpFromPolygon(const KSVGPolygon& polygon);
static ArtSVP *copy_svp(const ArtSVP *svp);
diff --git a/ksvg/plugin/backends/libart/LibartCanvasFactory.cpp b/ksvg/plugin/backends/libart/LibartCanvasFactory.cpp
index 48d37f05..9360389c 100644
--- a/ksvg/plugin/backends/libart/LibartCanvasFactory.cpp
+++ b/ksvg/plugin/backends/libart/LibartCanvasFactory.cpp
@@ -35,7 +35,7 @@ LibartCanvasFactory::~LibartCanvasFactory()
{
}
-QObject *LibartCanvasFactory::createObject(QObject *, const char *, const char *, const QStringList &args)
+TQObject *LibartCanvasFactory::createObject(TQObject *, const char *, const char *, const TQStringList &args)
{
int width = (*args.at(1)).toInt();
int height = (*args.at(0)).toInt();
diff --git a/ksvg/plugin/backends/libart/LibartCanvasFactory.h b/ksvg/plugin/backends/libart/LibartCanvasFactory.h
index 5b3ed0b3..58ad5047 100644
--- a/ksvg/plugin/backends/libart/LibartCanvasFactory.h
+++ b/ksvg/plugin/backends/libart/LibartCanvasFactory.h
@@ -35,7 +35,7 @@ public:
LibartCanvasFactory();
virtual ~LibartCanvasFactory();
- virtual QObject *createObject(QObject *parent = 0, const char *pname = 0, const char *name = "QObject", const QStringList &args = QStringList());
+ virtual TQObject *createObject(TQObject *parent = 0, const char *pname = 0, const char *name = "TQObject", const TQStringList &args = TQStringList());
};
}
diff --git a/ksvg/plugin/backends/libart/LibartCanvasItems.cpp b/ksvg/plugin/backends/libart/LibartCanvasItems.cpp
index 5dd97be1..998fb51f 100644
--- a/ksvg/plugin/backends/libart/LibartCanvasItems.cpp
+++ b/ksvg/plugin/backends/libart/LibartCanvasItems.cpp
@@ -20,8 +20,8 @@
#include <cfloat>
-#include <qimage.h>
-#include <qwmatrix.h>
+#include <tqimage.h>
+#include <tqwmatrix.h>
#include "SVGPaint.h"
#include "SVGRectImpl.h"
@@ -108,9 +108,9 @@ LibartShape::~LibartShape()
delete m_strokePainter;
}
-QRect LibartShape::bbox() const
+TQRect LibartShape::bbox() const
{
- QRect rect;
+ TQRect rect;
if(m_strokeSVP || m_fillSVP)
{
ArtIRect *irect = new ArtIRect();
@@ -134,7 +134,7 @@ bool LibartShape::isVisible(SVGShapeImpl *shape)
return m_referenced || (m_style->getVisible() && m_style->getDisplay() && shape->directRender());
}
-bool LibartShape::fillContains(const QPoint &p)
+bool LibartShape::fillContains(const TQPoint &p)
{
if(m_fillSVP)
return art_svp_point_wind(m_fillSVP, p.x(), p.y()) != 0;
@@ -142,7 +142,7 @@ bool LibartShape::fillContains(const QPoint &p)
return false;
}
-bool LibartShape::strokeContains(const QPoint &p)
+bool LibartShape::strokeContains(const TQPoint &p)
{
if(m_strokeSVP)
return art_svp_point_wind(m_strokeSVP, p.x(), p.y()) != 0;
@@ -214,7 +214,7 @@ void LibartPainter::update(SVGStylableImpl *style)
{
if(paintType(style) != SVG_PAINTTYPE_URI)
{
- QColor qcolor;
+ TQColor qcolor;
if(paintType(style) == SVG_PAINTTYPE_CURRENTCOLOR)
qcolor = style->getColor()->rgbColor().color();
else
@@ -250,9 +250,9 @@ void LibartPainter::draw(LibartCanvas *canvas, _ArtSVP *svp, SVGStylableImpl *st
{
canvas->clipToBuffer(x0, y0, x1, y1);
- QRect screenBBox(x0, y0, x1 - x0 + 1, y1 - y0 + 1);
+ TQRect screenBBox(x0, y0, x1 - x0 + 1, y1 - y0 + 1);
- QByteArray mask = SVGMaskElementImpl::maskRectangle(shape, screenBBox);
+ TQByteArray mask = SVGMaskElementImpl::maskRectangle(shape, screenBBox);
if(paintType(style) == SVG_PAINTTYPE_URI)
{
@@ -1356,7 +1356,7 @@ void LibartImage::draw()
if(isVisible())
{
SVGMatrixImpl *ctm = m_image->scaledImageMatrix();
- QImage image = m_image->scaledImage();
+ TQImage image = m_image->scaledImage();
KSVGPolygon clippingPolygon = m_image->clippingShape();
m_canvas->drawImage(image, m_image, ctm, clippingPolygon);
@@ -1374,9 +1374,9 @@ void LibartImage::init()
{
}
-QRect LibartImage::bbox() const
+TQRect LibartImage::bbox() const
{
- QRect bbox(static_cast<int>(m_image->x()->baseVal()->value()),
+ TQRect bbox(static_cast<int>(m_image->x()->baseVal()->value()),
static_cast<int>(m_image->y()->baseVal()->value()),
static_cast<int>(m_image->width()->baseVal()->value()),
static_cast<int>(m_image->height()->baseVal()->value()));
@@ -1428,12 +1428,12 @@ LibartText::SVPElement::~SVPElement()
art_svp_free(svp);
}
-QRect LibartText::bbox() const
+TQRect LibartText::bbox() const
{
- QRect result, rect;
+ TQRect result, rect;
- QPtrListIterator<SVPElement> it1(m_drawFillItems);
- QPtrListIterator<SVPElement> it2(m_drawStrokeItems);
+ TQPtrListIterator<SVPElement> it1(m_drawFillItems);
+ TQPtrListIterator<SVPElement> it2(m_drawStrokeItems);
SVPElement *fill = it1.current(), *stroke = it2.current();
while(fill != 0 || stroke != 0)
@@ -1458,9 +1458,9 @@ QRect LibartText::bbox() const
return result;
}
-bool LibartText::fillContains(const QPoint &p)
+bool LibartText::fillContains(const TQPoint &p)
{
- QPtrListIterator<SVPElement> it(m_drawFillItems);
+ TQPtrListIterator<SVPElement> it(m_drawFillItems);
SVPElement *fill = it.current();
while(fill && fill->svp)
@@ -1474,9 +1474,9 @@ bool LibartText::fillContains(const QPoint &p)
return false;
}
-bool LibartText::strokeContains(const QPoint &p)
+bool LibartText::strokeContains(const TQPoint &p)
{
- QPtrListIterator<SVPElement> it(m_drawStrokeItems);
+ TQPtrListIterator<SVPElement> it(m_drawStrokeItems);
SVPElement *stroke = it.current();
while(stroke && stroke->svp)
@@ -1494,8 +1494,8 @@ void LibartText::update(CanvasItemUpdate reason, int param1, int param2)
{
if(reason == UPDATE_STYLE)
{
- QPtrListIterator<SVPElement> it1(m_drawFillItems);
- QPtrListIterator<SVPElement> it2(m_drawStrokeItems);
+ TQPtrListIterator<SVPElement> it1(m_drawFillItems);
+ TQPtrListIterator<SVPElement> it2(m_drawStrokeItems);
SVPElement *fill = it1.current(), *stroke = it2.current();
while(fill != 0 || stroke != 0)
{
@@ -1529,8 +1529,8 @@ void LibartText::update(CanvasItemUpdate reason, int param1, int param2)
}
else if(reason == UPDATE_PAN)
{
- QPtrListIterator<SVPElement> it1(m_drawFillItems);
- QPtrListIterator<SVPElement> it2(m_drawStrokeItems);
+ TQPtrListIterator<SVPElement> it1(m_drawFillItems);
+ TQPtrListIterator<SVPElement> it2(m_drawStrokeItems);
double affine[6];
KSVGHelper::matrixToAffine(m_text->screenCTM(), affine);
@@ -1559,8 +1559,8 @@ void LibartText::update(CanvasItemUpdate reason, int param1, int param2)
void LibartText::draw()
{
- QPtrListIterator<SVPElement> it1(m_drawFillItems);
- QPtrListIterator<SVPElement> it2(m_drawStrokeItems);
+ TQPtrListIterator<SVPElement> it1(m_drawFillItems);
+ TQPtrListIterator<SVPElement> it2(m_drawStrokeItems);
SVPElement *fill = it1.current(), *stroke = it2.current();
while(fill != 0 || stroke != 0)
@@ -1588,8 +1588,8 @@ void LibartText::draw()
bool LibartText::isVisible()
{
bool foundVisible = false;
- QPtrListIterator<SVPElement> it1(m_drawFillItems);
- QPtrListIterator<SVPElement> it2(m_drawStrokeItems);
+ TQPtrListIterator<SVPElement> it1(m_drawFillItems);
+ TQPtrListIterator<SVPElement> it2(m_drawStrokeItems);
SVPElement *fill = it1.current(), *stroke = it2.current();
while(fill != 0 || stroke != 0)
@@ -1767,7 +1767,7 @@ void LibartText::initClipItem()
ArtSVP *LibartText::clipSVP()
{
ArtSVP *svp = 0;
- QPtrListIterator<SVPElement> it(m_drawFillItems);
+ TQPtrListIterator<SVPElement> it(m_drawFillItems);
SVPElement *fill = it.current();
while(fill && fill->svp)
@@ -1787,7 +1787,7 @@ ArtSVP *LibartText::clipSVP()
return svp;
}
-ArtRender *LibartPaintServer::createRenderer(QRect bbox, KSVGCanvas *c)
+ArtRender *LibartPaintServer::createRenderer(TQRect bbox, KSVGCanvas *c)
{
int x0 = bbox.x();
int y0 = bbox.y();
@@ -1836,7 +1836,7 @@ void LibartGradient::parseGradientStops(SVGGradientElementImpl *gradient)
stop->offset = (stop - 1)->offset;
// Get color
- QColor qStopColor;
+ TQColor qStopColor;
if(elem->getStopColor()->colorType() == SVG_COLORTYPE_CURRENTCOLOR)
qStopColor = elem->getColor()->rgbColor().color();
@@ -1844,7 +1844,7 @@ void LibartGradient::parseGradientStops(SVGGradientElementImpl *gradient)
qStopColor = elem->getStopColor()->rgbColor().color();
// Convert in a libart suitable form
- QString tempName = qStopColor.name();
+ TQString tempName = qStopColor.name();
const char *str = tempName.latin1();
int stopColor = 0;
@@ -1888,18 +1888,18 @@ void LibartGradient::finalizePaintServer()
{
parseGradientStops(m_gradient->stopsSource());
- QString _href = SVGURIReferenceImpl::getTarget(m_gradient->href()->baseVal().string());
+ TQString _href = SVGURIReferenceImpl::getTarget(m_gradient->href()->baseVal().string());
if(!_href.isEmpty())
reference(_href);
setFinalized();
}
-void LibartGradient::reference(const QString &)
+void LibartGradient::reference(const TQString &)
{
}
-void LibartLinearGradient::render(KSVGCanvas *c, ArtSVP *svp, float opacity, QByteArray mask, QRect screenBBox)
+void LibartLinearGradient::render(KSVGCanvas *c, ArtSVP *svp, float opacity, TQByteArray mask, TQRect screenBBox)
{
if(!m_stops.isEmpty())
{
@@ -1995,7 +1995,7 @@ void LibartLinearGradient::render(KSVGCanvas *c, ArtSVP *svp, float opacity, QBy
matrix->deref();
- QMemArray<ArtGradientStop> stops = m_stops;
+ TQMemArray<ArtGradientStop> stops = m_stops;
stops.detach();
for(unsigned int i = 0; i < stops.size(); i++)
@@ -2032,7 +2032,7 @@ void LibartLinearGradient::render(KSVGCanvas *c, ArtSVP *svp, float opacity, QBy
}
}
-void LibartRadialGradient::render(KSVGCanvas *c, ArtSVP *svp, float opacity, QByteArray mask, QRect screenBBox)
+void LibartRadialGradient::render(KSVGCanvas *c, ArtSVP *svp, float opacity, TQByteArray mask, TQRect screenBBox)
{
if(!m_stops.isEmpty())
{
@@ -2146,7 +2146,7 @@ void LibartRadialGradient::render(KSVGCanvas *c, ArtSVP *svp, float opacity, QBy
matrix->deref();
- QMemArray<ArtGradientStop> stops = m_stops;
+ TQMemArray<ArtGradientStop> stops = m_stops;
stops.detach();
for(unsigned int i = 0; i < stops.size(); i++)
@@ -2179,18 +2179,18 @@ void LibartPattern::finalizePaintServer()
setFinalized();
}
-void LibartPattern::reference(const QString &href)
+void LibartPattern::reference(const TQString &href)
{
m_pattern->reference(href);
}
-void LibartPattern::render(KSVGCanvas *c, ArtSVP *svp, float opacity, QByteArray mask, QRect screenBBox)
+void LibartPattern::render(KSVGCanvas *c, ArtSVP *svp, float opacity, TQByteArray mask, TQRect screenBBox)
{
SVGPatternElementImpl::Tile tile = m_pattern->createTile(getBBoxTarget());
if(!tile.image().isNull())
{
- QWMatrix m = tile.screenToTile();
+ TQWMatrix m = tile.screenToTile();
double affine[6];
affine[0] = m.m11();
diff --git a/ksvg/plugin/backends/libart/LibartCanvasItems.h b/ksvg/plugin/backends/libart/LibartCanvasItems.h
index c62224e5..d34ec9f4 100644
--- a/ksvg/plugin/backends/libart/LibartCanvasItems.h
+++ b/ksvg/plugin/backends/libart/LibartCanvasItems.h
@@ -21,7 +21,7 @@
#ifndef LIBARTCANVASITEMS_H
#define LIBARTCANVASITEMS_H
-#include <qptrlist.h>
+#include <tqptrlist.h>
#include "CanvasItems.h"
#include "LibartCanvas.h"
@@ -73,9 +73,9 @@ namespace KSVG
LibartPaintServer() : CanvasPaintServer() {}
virtual ~LibartPaintServer() {}
- virtual void render(KSVGCanvas *c, _ArtSVP *svp, float opacity, QByteArray mask, QRect screenBBox) = 0;
+ virtual void render(KSVGCanvas *c, _ArtSVP *svp, float opacity, TQByteArray mask, TQRect screenBBox) = 0;
- _ArtRender *createRenderer(QRect rect, KSVGCanvas *c);
+ _ArtRender *createRenderer(TQRect rect, KSVGCanvas *c);
};
class LibartGradient : public LibartPaintServer
@@ -87,11 +87,11 @@ namespace KSVG
void parseGradientStops(SVGGradientElementImpl *gradient);
virtual void finalizePaintServer();
- virtual void reference(const QString &href);
+ virtual void reference(const TQString &href);
protected:
SVGGradientElementImpl *m_gradient;
- QMemArray<_ArtGradientStop> m_stops;
+ TQMemArray<_ArtGradientStop> m_stops;
};
class LibartLinearGradient : public LibartGradient
@@ -99,7 +99,7 @@ namespace KSVG
public:
LibartLinearGradient(SVGLinearGradientElementImpl *linear) : LibartGradient(linear), m_linear(linear) {}
- virtual void render(KSVGCanvas *c, _ArtSVP *svp, float opacity, QByteArray mask, QRect screenBBox);
+ virtual void render(KSVGCanvas *c, _ArtSVP *svp, float opacity, TQByteArray mask, TQRect screenBBox);
protected:
SVGLinearGradientElementImpl *m_linear;
@@ -110,7 +110,7 @@ namespace KSVG
public:
LibartRadialGradient(SVGRadialGradientElementImpl *radial) : LibartGradient(radial), m_radial(radial) {}
- virtual void render(KSVGCanvas *c, _ArtSVP *svp, float opacity, QByteArray mask, QRect screenBBox);
+ virtual void render(KSVGCanvas *c, _ArtSVP *svp, float opacity, TQByteArray mask, TQRect screenBBox);
protected:
SVGRadialGradientElementImpl *m_radial;
@@ -123,9 +123,9 @@ namespace KSVG
virtual ~LibartPattern() {}
virtual void finalizePaintServer();
- virtual void reference(const QString &href);
+ virtual void reference(const TQString &href);
- virtual void render(KSVGCanvas *c, _ArtSVP *svp, float opacity, QByteArray mask, QRect screenBBox);
+ virtual void render(KSVGCanvas *c, _ArtSVP *svp, float opacity, TQByteArray mask, TQRect screenBBox);
protected:
SVGPatternElementImpl *m_pattern;
@@ -142,7 +142,7 @@ namespace KSVG
virtual float opacity(SVGStylableImpl *style) const = 0;
virtual unsigned short paintType(SVGStylableImpl *style) const = 0;
- virtual QString paintUri(SVGStylableImpl *style) const = 0;
+ virtual TQString paintUri(SVGStylableImpl *style) const = 0;
virtual QRgb color(SVGStylableImpl *style) const = 0;
protected:
@@ -156,7 +156,7 @@ namespace KSVG
float opacity(SVGStylableImpl *style) const { return style->getFillOpacity() * style->getOpacity(); }
unsigned short paintType(SVGStylableImpl *style) const { return style->getFillColor()->paintType(); }
- QString paintUri(SVGStylableImpl *style) const { return style->getFillColor()->uri().string(); }
+ TQString paintUri(SVGStylableImpl *style) const { return style->getFillColor()->uri().string(); }
QRgb color(SVGStylableImpl *style) const { return style->getFillColor()->rgbColor().color(); }
};
@@ -167,7 +167,7 @@ namespace KSVG
float opacity(SVGStylableImpl *style) const { return style->getStrokeOpacity() * style->getOpacity(); }
unsigned short paintType(SVGStylableImpl *style) const { return style->getStrokeColor()->paintType(); }
- QString paintUri(SVGStylableImpl *style) const { return style->getStrokeColor()->uri().string(); }
+ TQString paintUri(SVGStylableImpl *style) const { return style->getStrokeColor()->uri().string(); }
QRgb color(SVGStylableImpl *style) const { return style->getStrokeColor()->rgbColor().color(); }
};
@@ -191,9 +191,9 @@ namespace KSVG
LibartShape(LibartCanvas *c, SVGStylableImpl *style);
virtual ~LibartShape();
- virtual QRect bbox() const;
- virtual bool fillContains(const QPoint &p);
- virtual bool strokeContains(const QPoint &p);
+ virtual TQRect bbox() const;
+ virtual bool fillContains(const TQPoint &p);
+ virtual bool strokeContains(const TQPoint &p);
virtual void update(CanvasItemUpdate reason, int param1 = 0, int param2 = 0);
void draw(SVGShapeImpl *shape);
bool isVisible(SVGShapeImpl *shape);
@@ -307,9 +307,9 @@ namespace KSVG
LibartClipPath(LibartCanvas *c, SVGClipPathElementImpl *clipPath);
virtual ~LibartClipPath();
- virtual QRect bbox() const { return QRect(); }
- virtual bool fillContains(const QPoint &) { return true; }
- virtual bool strokeContains(const QPoint &) { return true; }
+ virtual TQRect bbox() const { return TQRect(); }
+ virtual bool fillContains(const TQPoint &) { return true; }
+ virtual bool strokeContains(const TQPoint &) { return true; }
virtual void update(CanvasItemUpdate, int param1 = 0, int param2 = 0);
virtual void init();
virtual void draw();
@@ -321,7 +321,7 @@ namespace KSVG
LibartCanvas *m_canvas;
_ArtSVP *m_clipSVP;
- QPtrList<CanvasItem> m_clipItems;
+ TQPtrList<CanvasItem> m_clipItems;
};
class LibartImage : public CanvasItem
@@ -330,9 +330,9 @@ namespace KSVG
LibartImage(LibartCanvas *c, SVGImageElementImpl *image);
virtual ~LibartImage();
- virtual QRect bbox() const;
- virtual bool fillContains(const QPoint &) { return true; }
- virtual bool strokeContains(const QPoint &) { return true; }
+ virtual TQRect bbox() const;
+ virtual bool fillContains(const TQPoint &) { return true; }
+ virtual bool strokeContains(const TQPoint &) { return true; }
virtual void update(CanvasItemUpdate, int = 0, int = 0) { }
virtual void init();
virtual void draw();
@@ -353,9 +353,9 @@ namespace KSVG
LibartMarker(LibartCanvas *c, SVGMarkerElementImpl *marker);
virtual ~LibartMarker();
- virtual QRect bbox() const { return QRect(); }
- virtual bool fillContains(const QPoint &) { return true; }
- virtual bool strokeContains(const QPoint &) { return true; }
+ virtual TQRect bbox() const { return TQRect(); }
+ virtual bool fillContains(const TQPoint &) { return true; }
+ virtual bool strokeContains(const TQPoint &) { return true; }
virtual void update(CanvasItemUpdate, int = 0, int = 0) { }
virtual void init();
virtual void draw();
@@ -371,9 +371,9 @@ namespace KSVG
LibartText(LibartCanvas *c, SVGTextElementImpl *text);
virtual ~LibartText();
- virtual QRect bbox() const;
- virtual bool fillContains(const QPoint &p);
- virtual bool strokeContains(const QPoint &p);
+ virtual TQRect bbox() const;
+ virtual bool fillContains(const TQPoint &p);
+ virtual bool strokeContains(const TQPoint &p);
virtual void update(CanvasItemUpdate reason, int param1 = 0, int param2 = 0);
virtual void draw();
virtual bool isVisible();
@@ -403,10 +403,10 @@ namespace KSVG
};
// renderCallback() is const.
- mutable QPtrList<SVPElement> m_drawFillItems;
- mutable QPtrList<SVPElement> m_drawStrokeItems;
- mutable QPtrDict<LibartFillPainter> m_fillPainters;
- mutable QPtrDict<LibartStrokePainter> m_strokePainters;
+ mutable TQPtrList<SVPElement> m_drawFillItems;
+ mutable TQPtrList<SVPElement> m_drawStrokeItems;
+ mutable TQPtrDict<LibartFillPainter> m_fillPainters;
+ mutable TQPtrDict<LibartStrokePainter> m_strokePainters;
};
}
diff --git a/ksvg/plugin/ksvg_factory.cpp b/ksvg/plugin/ksvg_factory.cpp
index b231783c..d5e5e1dc 100644
--- a/ksvg/plugin/ksvg_factory.cpp
+++ b/ksvg/plugin/ksvg_factory.cpp
@@ -28,8 +28,8 @@
#include "ksvg_factory.moc"
#include <kdebug.h>
-#include <qstringlist.h>
-#include <qregexp.h>
+#include <tqstringlist.h>
+#include <tqregexp.h>
extern "C"
{
@@ -43,7 +43,7 @@ extern "C"
KInstance *KSVGPluginFactory::s_instance = 0;
KAboutData *KSVGPluginFactory::s_about = 0;
-KSVGPluginFactory::KSVGPluginFactory(QObject *parent, const char *name) : KParts::Factory(parent, name)
+KSVGPluginFactory::KSVGPluginFactory(TQObject *parent, const char *name) : KParts::Factory(parent, name)
{
}
@@ -56,15 +56,15 @@ KSVGPluginFactory::~KSVGPluginFactory()
s_about = 0;
}
-KParts::Part *KSVGPluginFactory::createPartObject(QWidget *parentWidget, const char *wname, QObject *parent, const char *name, const char *, const QStringList &args)
+KParts::Part *KSVGPluginFactory::createPartObject(TQWidget *parentWidget, const char *wname, TQObject *parent, const char *name, const char *, const TQStringList &args)
{
// Get the width and height of the <embed>
// TODO : <object>
unsigned int width = 0, height = 0;
bool dummy;
- QRegExp r1("(WIDTH)(\\s*=\\s*\")(\\d+)(\\w*)(\")");
- QRegExp r2("(HEIGHT)(\\s*=\\s*\")(\\d+)(\\w*)(\")");
- for(QValueListConstIterator<QString> it = args.begin(); it != args.end(); ++it)
+ TQRegExp r1("(WIDTH)(\\s*=\\s*\")(\\d+)(\\w*)(\")");
+ TQRegExp r2("(HEIGHT)(\\s*=\\s*\")(\\d+)(\\w*)(\")");
+ for(TQValueListConstIterator<TQString> it = args.begin(); it != args.end(); ++it)
{
if(r1.search(*it) > -1)
width = r1.cap(3).toUInt(&dummy);
diff --git a/ksvg/plugin/ksvg_factory.h b/ksvg/plugin/ksvg_factory.h
index b462c782..c931e503 100644
--- a/ksvg/plugin/ksvg_factory.h
+++ b/ksvg/plugin/ksvg_factory.h
@@ -31,10 +31,10 @@ class KSVGPluginFactory : public KParts::Factory
{
Q_OBJECT
public:
- KSVGPluginFactory(QObject *parent = 0, const char *name = 0);
+ KSVGPluginFactory(TQObject *parent = 0, const char *name = 0);
virtual ~KSVGPluginFactory();
- virtual KParts::Part *createPartObject(QWidget *parentWidget = 0, const char *widgetName = 0, QObject *parent = 0, const char *name = 0, const char *classname = "KParts::Part", const QStringList &args = QStringList());
+ virtual KParts::Part *createPartObject(TQWidget *parentWidget = 0, const char *widgetName = 0, TQObject *parent = 0, const char *name = 0, const char *classname = "KParts::Part", const TQStringList &args = TQStringList());
static KInstance *instance();
diff --git a/ksvg/plugin/ksvg_plugin.cpp b/ksvg/plugin/ksvg_plugin.cpp
index 37e0a0dd..75699ec7 100644
--- a/ksvg/plugin/ksvg_plugin.cpp
+++ b/ksvg/plugin/ksvg_plugin.cpp
@@ -42,7 +42,7 @@
#include "SVGDocumentImpl.h"
#include "SVGSVGElementImpl.h"
-#include <qimage.h>
+#include <tqimage.h>
using namespace KSVG;
@@ -67,21 +67,21 @@ struct KSVGPlugin::Private
KToggleAction *progressiveAction;
KSelectAction *renderingBackendAction;
- QString description;
+ TQString description;
- QPoint panPoint;
+ TQPoint panPoint;
float zoomFactor;
SVGDocumentImpl *doc;
KSVGCanvas *canvas;
- QPixmap *backgroundPixmap;
+ TQPixmap *backgroundPixmap;
KAboutApplication *aboutKSVG;
unsigned int width;
unsigned int height;
};
-KSVGPlugin::KSVGPlugin(QWidget *wparent, const char *, QObject *parent, const char *name, unsigned int width, unsigned int height) : KParts::ReadOnlyPart(parent, name)
+KSVGPlugin::KSVGPlugin(TQWidget *wparent, const char *, TQObject *parent, const char *name, unsigned int width, unsigned int height) : KParts::ReadOnlyPart(parent, name)
{
kdDebug(26003) << "KSVGPlugin::KSVGPlugin" << endl;
setInstance(KSVGPluginFactory::instance());
@@ -96,14 +96,14 @@ KSVGPlugin::KSVGPlugin(QWidget *wparent, const char *, QObject *parent, const ch
ksvgd->doc = 0;
ksvgd->window = new KSVGWidget(this, wparent, "Rendering Widget");
- connect(ksvgd->window, SIGNAL(browseURL(const QString &)), this, SLOT(browseURL(const QString &)));
+ connect(ksvgd->window, TQT_SIGNAL(browseURL(const TQString &)), this, TQT_SLOT(browseURL(const TQString &)));
ksvgd->window->show();
KParts::Part::setWidget(ksvgd->window);
ksvgd->extension = new KSVGPluginBrowserExtension(this);
- ksvgd->backgroundPixmap = new QPixmap(width > 0 ? width : DEFAULT_WIDTH, height > 0 ? height : DEFAULT_HEIGHT);
+ ksvgd->backgroundPixmap = new TQPixmap(width > 0 ? width : DEFAULT_WIDTH, height > 0 ? height : DEFAULT_HEIGHT);
ksvgd->backgroundPixmap->fill();
ksvgd->canvas = KSVG::CanvasFactory::self()->loadCanvas(width > 0 ? width : DEFAULT_WIDTH, height > 0 ? height : DEFAULT_HEIGHT);
@@ -112,28 +112,28 @@ KSVGPlugin::KSVGPlugin(QWidget *wparent, const char *, QObject *parent, const ch
ksvgd->canvas->setup(ksvgd->backgroundPixmap, ksvgd->window);
- ksvgd->zoomInAction = KStdAction::zoomIn(this, SLOT(slotZoomIn()), actionCollection());
- ksvgd->zoomOutAction = KStdAction::zoomOut(this, SLOT(slotZoomOut()), actionCollection());
- ksvgd->zoomResetAction = new KAction(i18n("Zoom &Reset"), "viewmag", this, SLOT(slotZoomReset()), actionCollection(), "zoom_reset");
- ksvgd->stopAnimationsAction = new KAction(i18n("&Stop Animations"), "stop", Key_Escape, this, SLOT(slotStop()), actionCollection(), "stop_anims");
- ksvgd->viewSourceAction = new KAction(i18n("View &Source"), "document2", Key_F6, this, SLOT(slotViewSource()), actionCollection(), "view_source");
- ksvgd->viewMemoryAction = new KAction(i18n("View &Memory"), "document2", Key_F7, this, SLOT(slotViewMemory()), actionCollection(), "view_memory");
- ksvgd->saveToPNG = new KAction(i18n("Save to PNG..."), "save", 0, this, SLOT(slotSaveToPNG()), actionCollection(), "save_to_png");
-// ksvgd->aboutApp = KStdAction::aboutApp(this, SLOT(slotAboutKSVG()), actionCollection());//, "KSVG");
- ksvgd->aboutApp = new KAction(i18n("About KSVG"), "vectorgfx", 0, this, SLOT(slotAboutKSVG()), actionCollection(), "help_about_app");
- ksvgd->fontKerningAction = new KToggleAction(i18n("Use Font &Kerning"), "viewmagfit", Key_F8, this, SLOT(slotFontKerning()), actionCollection(), "font_kerning");
- ksvgd->progressiveAction = new KToggleAction(i18n("Use &Progressive Rendering"), "", Key_F9, this, SLOT(slotProgressiveRendering()), actionCollection(), "progressive");
+ ksvgd->zoomInAction = KStdAction::zoomIn(this, TQT_SLOT(slotZoomIn()), actionCollection());
+ ksvgd->zoomOutAction = KStdAction::zoomOut(this, TQT_SLOT(slotZoomOut()), actionCollection());
+ ksvgd->zoomResetAction = new KAction(i18n("Zoom &Reset"), "viewmag", this, TQT_SLOT(slotZoomReset()), actionCollection(), "zoom_reset");
+ ksvgd->stopAnimationsAction = new KAction(i18n("&Stop Animations"), "stop", Key_Escape, this, TQT_SLOT(slotStop()), actionCollection(), "stop_anims");
+ ksvgd->viewSourceAction = new KAction(i18n("View &Source"), "document2", Key_F6, this, TQT_SLOT(slotViewSource()), actionCollection(), "view_source");
+ ksvgd->viewMemoryAction = new KAction(i18n("View &Memory"), "document2", Key_F7, this, TQT_SLOT(slotViewMemory()), actionCollection(), "view_memory");
+ ksvgd->saveToPNG = new KAction(i18n("Save to PNG..."), "save", 0, this, TQT_SLOT(slotSaveToPNG()), actionCollection(), "save_to_png");
+// ksvgd->aboutApp = KStdAction::aboutApp(this, TQT_SLOT(slotAboutKSVG()), actionCollection());//, "KSVG");
+ ksvgd->aboutApp = new KAction(i18n("About KSVG"), "vectorgfx", 0, this, TQT_SLOT(slotAboutKSVG()), actionCollection(), "help_about_app");
+ ksvgd->fontKerningAction = new KToggleAction(i18n("Use Font &Kerning"), "viewmagfit", Key_F8, this, TQT_SLOT(slotFontKerning()), actionCollection(), "font_kerning");
+ ksvgd->progressiveAction = new KToggleAction(i18n("Use &Progressive Rendering"), "", Key_F9, this, TQT_SLOT(slotProgressiveRendering()), actionCollection(), "progressive");
KSimpleConfig config("ksvgpluginrc", true);
config.setGroup("Rendering");
ksvgd->fontKerningAction->setChecked(config.readBoolEntry("FontKerning", true));
ksvgd->progressiveAction->setChecked(config.readBoolEntry("ProgressiveRendering", true));
- ksvgd->renderingBackendAction = new KSelectAction(i18n("Rendering &Backend"), 0, this, SLOT(slotRenderingBackend()), actionCollection(), "rendering_backend");
+ ksvgd->renderingBackendAction = new KSelectAction(i18n("Rendering &Backend"), 0, this, TQT_SLOT(slotRenderingBackend()), actionCollection(), "rendering_backend");
- QStringList items;
- QPtrList<KSVG::CanvasInfo> canvasList = KSVG::CanvasFactory::self()->canvasList();
- QPtrListIterator<KSVG::CanvasInfo> it(canvasList);
+ TQStringList items;
+ TQPtrList<KSVG::CanvasInfo> canvasList = KSVG::CanvasFactory::self()->canvasList();
+ TQPtrListIterator<KSVG::CanvasInfo> it(canvasList);
KSVG::CanvasInfo *canvasInfo = 0;
while((canvasInfo = it.current()) != 0)
{
@@ -184,7 +184,7 @@ void KSVGPlugin::reset()
ksvgd->zoomFactor = 1;
ksvgd->window->reset();
- ksvgd->panPoint = QPoint(0, 0);
+ ksvgd->panPoint = TQPoint(0, 0);
}
bool KSVGPlugin::openURL(const KURL &url)
@@ -204,12 +204,12 @@ bool KSVGPlugin::openURL(const KURL &url)
ksvgd->doc->addToDocumentDict(ksvgd->doc->handle(), ksvgd->doc);
ksvgd->doc->setReferrer(ksvgd->extension->urlArgs().metaData()["referrer"]);
- connect(ksvgd->doc, SIGNAL(finishedParsing(bool, const QString &)), this, SLOT(slotParsingFinished(bool, const QString &)));
- connect(ksvgd->doc, SIGNAL(finishedRendering()), this, SLOT(slotRenderingFinished()));
- connect(ksvgd->doc, SIGNAL(gotDescription(const QString &)), this, SLOT(slotSetDescription(const QString &)));
- connect(ksvgd->doc, SIGNAL(gotTitle(const QString &)), this, SLOT(slotSetTitle(const QString &)));
- connect(ksvgd->doc, SIGNAL(gotURL(const QString &)), this, SLOT(slotGotURL(const QString &)));
- connect(ksvgd->window, SIGNAL(redraw(const QRect &)), this, SLOT(slotRedraw(const QRect &)));
+ connect(ksvgd->doc, TQT_SIGNAL(finishedParsing(bool, const TQString &)), this, TQT_SLOT(slotParsingFinished(bool, const TQString &)));
+ connect(ksvgd->doc, TQT_SIGNAL(finishedRendering()), this, TQT_SLOT(slotRenderingFinished()));
+ connect(ksvgd->doc, TQT_SIGNAL(gotDescription(const TQString &)), this, TQT_SLOT(slotSetDescription(const TQString &)));
+ connect(ksvgd->doc, TQT_SIGNAL(gotTitle(const TQString &)), this, TQT_SLOT(slotSetTitle(const TQString &)));
+ connect(ksvgd->doc, TQT_SIGNAL(gotURL(const TQString &)), this, TQT_SLOT(slotGotURL(const TQString &)));
+ connect(ksvgd->window, TQT_SIGNAL(redraw(const TQRect &)), this, TQT_SLOT(slotRedraw(const TQRect &)));
ksvgd->backgroundPixmap->fill();
bitBlt(ksvgd->window, 0, 0, ksvgd->backgroundPixmap, 0, 0, ksvgd->backgroundPixmap->width(), ksvgd->backgroundPixmap->height());
@@ -225,7 +225,7 @@ bool KSVGPlugin::openURL(const KURL &url)
return true;
}
-void KSVGPlugin::browseURL(const QString &url)
+void KSVGPlugin::browseURL(const TQString &url)
{
ksvgd->doc->rootElement()->pauseAnimations();
KParts::URLArgs args;
@@ -233,7 +233,7 @@ void KSVGPlugin::browseURL(const QString &url)
emit ksvgd->extension->openURLRequest(KURL(m_url, url), args);
}
-void KSVGPlugin::slotRedraw(const QRect &r)
+void KSVGPlugin::slotRedraw(const TQRect &r)
{
if(ksvgd->window->width() != ksvgd->backgroundPixmap->width() ||
ksvgd->window->height() != ksvgd->backgroundPixmap->height())
@@ -316,7 +316,7 @@ void KSVGPlugin::slotStop()
ksvgd->doc->rootElement()->pauseAnimations();
}
-void KSVGPlugin::slotParsingFinished(bool error, const QString &errorDesc)
+void KSVGPlugin::slotParsingFinished(bool error, const TQString &errorDesc)
{
emit completed();
@@ -356,14 +356,14 @@ void KSVGPlugin::slotSaveToPNG()
{
if(ksvgd && ksvgd->backgroundPixmap)
{
- QImage img = ksvgd->backgroundPixmap->convertToImage();
- QString filename = KFileDialog::getSaveFileName();
+ TQImage img = ksvgd->backgroundPixmap->convertToImage();
+ TQString filename = KFileDialog::getSaveFileName();
if(!filename.isEmpty())
img.save(filename, "PNG");
}
}
-void KSVGPlugin::setPanPoint(const QPoint &translate)
+void KSVGPlugin::setPanPoint(const TQPoint &translate)
{
ksvgd->panPoint = translate;
update();
@@ -391,22 +391,22 @@ void KSVGPlugin::update()
ksvgd->doc->canvas()->update(ksvgd->panPoint);
// Fixes drawing glitches
- slotRedraw(QRect(0, 0, ksvgd->backgroundPixmap->width(), ksvgd->backgroundPixmap->height()));
+ slotRedraw(TQRect(0, 0, ksvgd->backgroundPixmap->width(), ksvgd->backgroundPixmap->height()));
}
}
-void KSVGPlugin::slotSetDescription(const QString &desc)
+void KSVGPlugin::slotSetDescription(const TQString &desc)
{
ksvgd->description = desc;
emit setStatusBarText(i18n("Description: %1").arg(desc));
}
-void KSVGPlugin::slotSetTitle(const QString &title)
+void KSVGPlugin::slotSetTitle(const TQString &title)
{
emit setWindowCaption(title);
}
-void KSVGPlugin::slotGotURL(const QString &text)
+void KSVGPlugin::slotGotURL(const TQString &text)
{
if(text.isNull() && !ksvgd->description.isEmpty())
emit setStatusBarText(i18n("Description: %1").arg(ksvgd->description));
diff --git a/ksvg/plugin/ksvg_plugin.h b/ksvg/plugin/ksvg_plugin.h
index 87286be9..669d3661 100644
--- a/ksvg/plugin/ksvg_plugin.h
+++ b/ksvg/plugin/ksvg_plugin.h
@@ -21,7 +21,7 @@
#ifndef KSVGPlugin_H
#define KSVGPlugin_H
-#include <qobject.h>
+#include <tqobject.h>
#include <kparts/part.h>
namespace KSVG
@@ -36,7 +36,7 @@ class KSVGPlugin : public KParts::ReadOnlyPart
{
Q_OBJECT
public:
- KSVGPlugin(QWidget *parentWidget, const char *wname, QObject *parent, const char *name, unsigned int width = 0, unsigned int height = 0);
+ KSVGPlugin(TQWidget *parentWidget, const char *wname, TQObject *parent, const char *name, unsigned int width = 0, unsigned int height = 0);
virtual ~KSVGPlugin();
virtual bool openFile() { return false; }
@@ -46,19 +46,19 @@ public:
KSVG::SVGDocumentImpl *docImpl();
void reset();
- void setPanPoint(const QPoint &translate);
+ void setPanPoint(const TQPoint &translate);
void update();
void setPopupActive(bool);
signals:
- void gotHyperlink(const QString &);
- void gotHyperlinkCoordinate(const QRect &);
+ void gotHyperlink(const TQString &);
+ void gotHyperlinkCoordinate(const TQRect &);
public slots:
- void slotRedraw(const QRect &);
+ void slotRedraw(const TQRect &);
private slots:
- void browseURL(const QString &url);
+ void browseURL(const TQString &url);
void slotStop();
void slotViewSource();
void slotViewMemory();
@@ -71,11 +71,11 @@ private slots:
void slotAboutKSVG();
void slotSaveToPNG();
- void slotParsingFinished(bool error, const QString &errorDesc);
+ void slotParsingFinished(bool error, const TQString &errorDesc);
void slotRenderingFinished();
- void slotSetDescription(const QString &);
- void slotSetTitle(const QString &);
- void slotGotURL(const QString &);
+ void slotSetDescription(const TQString &);
+ void slotSetTitle(const TQString &);
+ void slotGotURL(const TQString &);
private:
class Private;
diff --git a/ksvg/plugin/ksvg_widget.cpp b/ksvg/plugin/ksvg_widget.cpp
index 073e60a5..0f1b9d3e 100644
--- a/ksvg/plugin/ksvg_widget.cpp
+++ b/ksvg/plugin/ksvg_widget.cpp
@@ -27,8 +27,8 @@
#include "SVGDocumentImpl.h"
#include "SVGSVGElementImpl.h"
-KSVGWidget::KSVGWidget(KSVGPlugin *part, QWidget *parent, const char *name)
-: QWidget(parent, name), m_part(part)
+KSVGWidget::KSVGWidget(KSVGPlugin *part, TQWidget *parent, const char *name)
+: TQWidget(parent, name), m_part(part)
{
setMouseTracking(true);
setFocusPolicy(WheelFocus);
@@ -55,12 +55,12 @@ void KSVGWidget::reset()
m_panningPos.setY(0);
}
-void KSVGWidget::paintEvent(QPaintEvent *e)
+void KSVGWidget::paintEvent(TQPaintEvent *e)
{
emit redraw(e->rect());
}
-KSVG::SVGMouseEventImpl *KSVGWidget::newMouseEvent(KSVG::SVGEvent::EventId id, QMouseEvent *event)
+KSVG::SVGMouseEventImpl *KSVGWidget::newMouseEvent(KSVG::SVGEvent::EventId id, TQMouseEvent *event)
{
DOM::AbstractView temp;
@@ -102,9 +102,9 @@ KSVG::SVGMouseEventImpl *KSVGWidget::newMouseEvent(KSVG::SVGEvent::EventId id, Q
return mev;
}
-void KSVGWidget::mouseMoveEvent(QMouseEvent *event)
+void KSVGWidget::mouseMoveEvent(TQMouseEvent *event)
{
- if(event->state() & QMouseEvent::ControlButton && event->state() & QMouseEvent::LeftButton)
+ if(event->state() & TQMouseEvent::ControlButton && event->state() & TQMouseEvent::LeftButton)
{
if(m_panningPos.isNull())
m_panningPos = event->pos();
@@ -113,7 +113,7 @@ void KSVGWidget::mouseMoveEvent(QMouseEvent *event)
return;
}
- else if(event->state() & QMouseEvent::ControlButton)
+ else if(event->state() & TQMouseEvent::ControlButton)
return;
KSVG::SVGMouseEventImpl *mev = newMouseEvent(KSVG::SVGEvent::MOUSEMOVE_EVENT, event);
@@ -181,16 +181,16 @@ void KSVGWidget::mouseMoveEvent(QMouseEvent *event)
mev->deref();
}
-void KSVGWidget::mousePressEvent(QMouseEvent *event)
+void KSVGWidget::mousePressEvent(TQMouseEvent *event)
{
- if(event->state() & QMouseEvent::ControlButton)
+ if(event->state() & TQMouseEvent::ControlButton)
return;
if(event->button() == RightButton)
{
if(part() && part()->factory())
{
- QPopupMenu *popup = static_cast<QPopupMenu *>(part()->factory()->container("popupmenu", part()));
+ TQPopupMenu *popup = static_cast<TQPopupMenu *>(part()->factory()->container("popupmenu", part()));
if(popup)
popup->popup(event->globalPos());
}
@@ -204,7 +204,7 @@ void KSVGWidget::mousePressEvent(QMouseEvent *event)
mev->deref();
}
-void KSVGWidget::mouseReleaseEvent(QMouseEvent *event)
+void KSVGWidget::mouseReleaseEvent(TQMouseEvent *event)
{
if(!m_panningPos.isNull())
{
@@ -213,7 +213,7 @@ void KSVGWidget::mouseReleaseEvent(QMouseEvent *event)
m_panningPos.setY(0);
}
- if(event->state() & QMouseEvent::ControlButton)
+ if(event->state() & TQMouseEvent::ControlButton)
return;
KSVG::SVGMouseEventImpl *mev = newMouseEvent(KSVG::SVGEvent::MOUSEUP_EVENT, event);
@@ -223,7 +223,7 @@ void KSVGWidget::mouseReleaseEvent(QMouseEvent *event)
if(!mev->url().string().isEmpty())
{
- QString url = mev->url().string();
+ TQString url = mev->url().string();
if(url.startsWith("#"))
url.prepend(part()->docImpl()->baseUrl().prettyURL());
emit browseURL(url);
@@ -232,9 +232,9 @@ void KSVGWidget::mouseReleaseEvent(QMouseEvent *event)
mev->deref();
}
-void KSVGWidget::keyPressEvent(QKeyEvent *ke)
+void KSVGWidget::keyPressEvent(TQKeyEvent *ke)
{
- if(ke->stateAfter() & QMouseEvent::ControlButton)
+ if(ke->stateAfter() & TQMouseEvent::ControlButton)
{
setCursor(KCursor::sizeAllCursor());
return;
@@ -244,9 +244,9 @@ void KSVGWidget::keyPressEvent(QKeyEvent *ke)
part()->docImpl()->lastTarget()->dispatchKeyEvent(ke);
}
-void KSVGWidget::keyReleaseEvent(QKeyEvent *ke)
+void KSVGWidget::keyReleaseEvent(TQKeyEvent *ke)
{
- if(ke->state() & QMouseEvent::ControlButton)
+ if(ke->state() & TQMouseEvent::ControlButton)
{
setCursor(KCursor::arrowCursor());
return;
@@ -256,12 +256,12 @@ void KSVGWidget::keyReleaseEvent(QKeyEvent *ke)
part()->docImpl()->lastTarget()->dispatchKeyEvent(ke);
}
-void KSVGWidget::resizeEvent(QResizeEvent *e)
+void KSVGWidget::resizeEvent(TQResizeEvent *e)
{
if(part()->docImpl() && part()->docImpl()->rootElement())
part()->docImpl()->rootElement()->dispatchEvent(KSVG::SVGEvent::RESIZE_EVENT, true, false);
- emit redraw(QRect(0, 0, e->size().width(), e->size().height()));
+ emit redraw(TQRect(0, 0, e->size().width(), e->size().height()));
}
// vim:ts=4:noet
diff --git a/ksvg/plugin/ksvg_widget.h b/ksvg/plugin/ksvg_widget.h
index 3cd94849..c25fddbc 100644
--- a/ksvg/plugin/ksvg_widget.h
+++ b/ksvg/plugin/ksvg_widget.h
@@ -21,7 +21,7 @@
#ifndef KSVGWidget_H
#define KSVGWidget_H
-#include <qwidget.h>
+#include <tqwidget.h>
#include <kpopupmenu.h>
@@ -32,7 +32,7 @@ class KSVGWidget : public QWidget
{
Q_OBJECT
public:
- KSVGWidget(KSVGPlugin *part, QWidget *parent, const char *name);
+ KSVGWidget(KSVGPlugin *part, TQWidget *parent, const char *name);
virtual ~KSVGWidget();
KSVGPlugin *part() const;
@@ -40,26 +40,26 @@ public:
void reset();
protected:
- virtual void paintEvent(QPaintEvent *);
+ virtual void paintEvent(TQPaintEvent *);
- virtual void mouseMoveEvent(QMouseEvent *);
- virtual void mousePressEvent(QMouseEvent *);
- virtual void mouseReleaseEvent(QMouseEvent *);
+ virtual void mouseMoveEvent(TQMouseEvent *);
+ virtual void mousePressEvent(TQMouseEvent *);
+ virtual void mouseReleaseEvent(TQMouseEvent *);
- virtual void keyPressEvent(QKeyEvent *);
- virtual void keyReleaseEvent(QKeyEvent *);
+ virtual void keyPressEvent(TQKeyEvent *);
+ virtual void keyReleaseEvent(TQKeyEvent *);
- virtual void resizeEvent(QResizeEvent *);
+ virtual void resizeEvent(TQResizeEvent *);
signals:
- void browseURL(const QString &);
- void redraw(const QRect &);
+ void browseURL(const TQString &);
+ void redraw(const TQRect &);
private:
- KSVG::SVGMouseEventImpl *newMouseEvent(KSVG::SVGEvent::EventId id, QMouseEvent *event);
+ KSVG::SVGMouseEventImpl *newMouseEvent(KSVG::SVGEvent::EventId id, TQMouseEvent *event);
- QPoint m_panningPos;
- QPoint m_oldPanningPos;
+ TQPoint m_panningPos;
+ TQPoint m_oldPanningPos;
KSVGPlugin *m_part;
};
diff --git a/ksvg/plugin/svgcreator.cpp b/ksvg/plugin/svgcreator.cpp
index c6689c9a..dc20e06f 100644
--- a/ksvg/plugin/svgcreator.cpp
+++ b/ksvg/plugin/svgcreator.cpp
@@ -21,8 +21,8 @@
#include <time.h>
-#include <qpixmap.h>
-#include <qimage.h>
+#include <tqpixmap.h>
+#include <tqimage.h>
#include "KSVGCanvas.h"
#include "CanvasFactory.h"
@@ -50,19 +50,19 @@ SVGCreator::~SVGCreator()
{
}
-bool SVGCreator::create(const QString &path, int width, int height, QImage &img)
+bool SVGCreator::create(const TQString &path, int width, int height, TQImage &img)
{
KSVG::SVGDocumentImpl *doc = new KSVG::SVGDocumentImpl(false, true);
doc->ref();
- QPixmap pix(width, height);
+ TQPixmap pix(width, height);
pix.fill(Qt::white);
KSVG::KSVGCanvas *c = KSVG::CanvasFactory::self()->loadCanvas(width, height);
c->setup(&pix, &pix);
doc->attach(c);
- connect(doc, SIGNAL(finishedRendering()), SLOT(slotFinished()));
+ connect(doc, TQT_SIGNAL(finishedRendering()), TQT_SLOT(slotFinished()));
doc->open( KURL::fromPathOrURL(path));
m_finished = false;
diff --git a/ksvg/plugin/svgcreator.h b/ksvg/plugin/svgcreator.h
index ad1b8f30..403f0a78 100644
--- a/ksvg/plugin/svgcreator.h
+++ b/ksvg/plugin/svgcreator.h
@@ -24,13 +24,13 @@
#include <kio/thumbcreator.h>
-class SVGCreator : public QObject, public ThumbCreator
+class SVGCreator : public TQObject, public ThumbCreator
{
Q_OBJECT
public:
SVGCreator();
virtual ~SVGCreator();
- virtual bool create(const QString &path, int width, int height, QImage &img);
+ virtual bool create(const TQString &path, int width, int height, TQImage &img);
virtual Flags flags() const;
private slots:
diff --git a/ksvg/test/external/SVGTestWidget.cc b/ksvg/test/external/SVGTestWidget.cc
index b954e94b..aa968e24 100644
--- a/ksvg/test/external/SVGTestWidget.cc
+++ b/ksvg/test/external/SVGTestWidget.cc
@@ -20,7 +20,7 @@ SVGTestWidget::SVGTestWidget(const KURL &url)
setMouseTracking(true);
setFocusPolicy(WheelFocus);
- m_doc = DocumentFactory::self()->requestDocument(this, SLOT(slotRenderingFinished()));
+ m_doc = DocumentFactory::self()->requestDocument(this, TQT_SLOT(slotRenderingFinished()));
if(!m_doc)
return;
@@ -46,7 +46,7 @@ SVGTestWidget::~SVGTestWidget()
void SVGTestWidget::slotRenderingFinished()
{
- QRect rect(0, 0, width(), height());
+ TQRect rect(0, 0, width(), height());
m_canvas->blit(rect, true);
SVGElement test = m_doc->rootElement().getElementById("test");
@@ -58,13 +58,13 @@ void SVGTestWidget::slotRenderingFinished()
}
}
-void SVGTestWidget::paintEvent(QPaintEvent *event)
+void SVGTestWidget::paintEvent(TQPaintEvent *event)
{
m_canvas->update();
m_canvas->blit(event->rect(), true);
}
-void SVGTestWidget::resizeEvent(QResizeEvent *event)
+void SVGTestWidget::resizeEvent(TQResizeEvent *event)
{
int w = event->size().width();
int h = event->size().height();
@@ -74,7 +74,7 @@ void SVGTestWidget::resizeEvent(QResizeEvent *event)
m_canvas->blit();
}
/*
-KSVG::SVGMouseEventImpl *newMouseEvent(SVGDocument *doc, KSVG::SVGEventImpl::EventId id, QMouseEvent *event)
+KSVG::SVGMouseEventImpl *newMouseEvent(SVGDocument *doc, KSVG::SVGEventImpl::EventId id, TQMouseEvent *event)
{
DOM::AbstractView temp;
@@ -116,28 +116,28 @@ KSVG::SVGMouseEventImpl *newMouseEvent(SVGDocument *doc, KSVG::SVGEventImpl::Eve
return mev;
}
-void SVGTestWidget::mouseMoveEvent(QMouseEvent *event)
+void SVGTestWidget::mouseMoveEvent(TQMouseEvent *event)
{
- if(event->state() & QMouseEvent::ControlButton && event->state() & QMouseEvent::LeftButton)
+ if(event->state() & TQMouseEvent::ControlButton && event->state() & TQMouseEvent::LeftButton)
{
if(m_panningPos.isNull())
m_panningPos = event->pos();
else
{
- QPoint panPoint = m_oldPanningPos - (m_panningPos - event->pos());
+ TQPoint panPoint = m_oldPanningPos - (m_panningPos - event->pos());
m_doc->rootElement()->setCurrentTranslate(panPoint);
// m_doc->syncCachedMatrices(); FIXME
m_canvas->update(panPoint);
}
return;
}
- else if(event->state() & QMouseEvent::ControlButton)
+ else if(event->state() & TQMouseEvent::ControlButton)
return;
}
-void SVGTestWidget::mousePressEvent(QMouseEvent *event)
+void SVGTestWidget::mousePressEvent(TQMouseEvent *event)
{
- if(event->state() & QMouseEvent::ControlButton)
+ if(event->state() & TQMouseEvent::ControlButton)
return;
KSVG::SVGMouseEventImpl *mev = newMouseEvent(m_doc, KSVG::SVGEventImpl::MOUSEDOWN_EVENT, event);
@@ -147,7 +147,7 @@ void SVGTestWidget::mousePressEvent(QMouseEvent *event)
mev->deref();
}
-void SVGTestWidget::mouseReleaseEvent(QMouseEvent *event)
+void SVGTestWidget::mouseReleaseEvent(TQMouseEvent *event)
{
if(!m_panningPos.isNull())
{
@@ -156,7 +156,7 @@ void SVGTestWidget::mouseReleaseEvent(QMouseEvent *event)
m_panningPos.setY(0);
}
- if(event->state() & QMouseEvent::ControlButton)
+ if(event->state() & TQMouseEvent::ControlButton)
return;
// only simulate mouse clicks for now
@@ -167,18 +167,18 @@ void SVGTestWidget::mouseReleaseEvent(QMouseEvent *event)
mev->deref();
}
-void SVGTestWidget::keyPressEvent(QKeyEvent *event)
+void SVGTestWidget::keyPressEvent(TQKeyEvent *event)
{
- if(event->stateAfter() & QMouseEvent::ControlButton)
+ if(event->stateAfter() & TQMouseEvent::ControlButton)
{
setCursor(KCursor::sizeAllCursor());
return;
}
}
-void SVGTestWidget::keyReleaseEvent(QKeyEvent *event)
+void SVGTestWidget::keyReleaseEvent(TQKeyEvent *event)
{
- if(event->state() & QMouseEvent::ControlButton)
+ if(event->state() & TQMouseEvent::ControlButton)
{
setCursor(KCursor::arrowCursor());
return;
diff --git a/ksvg/test/external/SVGTestWidget.h b/ksvg/test/external/SVGTestWidget.h
index 10ece576..676f3269 100644
--- a/ksvg/test/external/SVGTestWidget.h
+++ b/ksvg/test/external/SVGTestWidget.h
@@ -1,8 +1,8 @@
#ifndef _SVGTESTWIDGET_H
#define _SVGTESTWIDGET_H
-#include <qwidget.h>
-#include <qobject.h>
+#include <tqwidget.h>
+#include <tqobject.h>
#include "SVGDocument.h"
#include "KSVGCanvas.h"
@@ -17,17 +17,17 @@ private slots:
void slotRenderingFinished();
protected:
- virtual void paintEvent(QPaintEvent *event);
- virtual void resizeEvent(QResizeEvent *event);
-/* virtual void mousePressEvent(QMouseEvent *event);
- virtual void mouseReleaseEvent(QMouseEvent *event);
- virtual void keyPressEvent(QKeyEvent *event);
- virtual void keyReleaseEvent(QKeyEvent *event);
- virtual void mouseMoveEvent(QMouseEvent *event);
+ virtual void paintEvent(TQPaintEvent *event);
+ virtual void resizeEvent(TQResizeEvent *event);
+/* virtual void mousePressEvent(TQMouseEvent *event);
+ virtual void mouseReleaseEvent(TQMouseEvent *event);
+ virtual void keyPressEvent(TQKeyEvent *event);
+ virtual void keyReleaseEvent(TQKeyEvent *event);
+ virtual void mouseMoveEvent(TQMouseEvent *event);
*/
private:
- QPoint m_panningPos;
- QPoint m_oldPanningPos;
+ TQPoint m_panningPos;
+ TQPoint m_oldPanningPos;
KSVG::SVGDocument *m_doc;
KSVG::KSVGCanvas *m_canvas;
diff --git a/ksvg/test/external/printnodetest.cpp b/ksvg/test/external/printnodetest.cpp
index b2547e7f..1c2921f4 100644
--- a/ksvg/test/external/printnodetest.cpp
+++ b/ksvg/test/external/printnodetest.cpp
@@ -21,7 +21,7 @@ static KCmdLineOptions options[] =
Worker::Worker(const KURL &url)
{
- m_doc = DocumentFactory::self()->requestDocument(this, SLOT(slotParsingFinished(bool, const QString &)));
+ m_doc = DocumentFactory::self()->requestDocument(this, TQT_SLOT(slotParsingFinished(bool, const TQString &)));
if(!m_doc)
return;
@@ -35,7 +35,7 @@ Worker::~Worker()
delete m_doc;
}
-void Worker::slotParsingFinished(bool, const QString &)
+void Worker::slotParsingFinished(bool, const TQString &)
{
SVGWindow win = m_doc->window();
SVGSVGElement root = m_doc->rootElement();
diff --git a/ksvg/test/external/printnodetest.h b/ksvg/test/external/printnodetest.h
index e95a46a9..19385014 100644
--- a/ksvg/test/external/printnodetest.h
+++ b/ksvg/test/external/printnodetest.h
@@ -2,7 +2,7 @@
#define PRINTNODETEST_H
#include <kurl.h>
-#include <qobject.h>
+#include <tqobject.h>
namespace KSVG
{
@@ -16,7 +16,7 @@ public:
~Worker();
private slots:
- void slotParsingFinished(bool error, const QString &errorDesc);
+ void slotParsingFinished(bool error, const TQString &errorDesc);
private:
// It's not allowed to store a m_doc object here,