summaryrefslogtreecommitdiffstats
path: root/kig
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-11 04:44:41 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-11 04:44:41 +0000
commita374efce3a207b39514be3c52264091400ce297e (patch)
tree77bdf654b55826d4f59b53a5621310206bcaead1 /kig
parentf81a494f3957d5cf38c787973415597941934727 (diff)
downloadtdeedu-a374efce3a207b39514be3c52264091400ce297e.tar.gz
tdeedu-a374efce3a207b39514be3c52264091400ce297e.zip
TQt4 port kdeedu
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeedu@1236073 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kig')
-rw-r--r--kig/ChangeLog18
-rw-r--r--kig/DESIGN32
-rw-r--r--kig/FEATURES4
-rw-r--r--kig/Makefile.am4
-rw-r--r--kig/README.boost-python1.30-gcc3.22
-rw-r--r--kig/TODO12
-rw-r--r--kig/configure.in.in18
-rw-r--r--kig/examples/figure_angle.fgeo26
-rw-r--r--kig/examples/figure_manyobjects.fgeo62
-rw-r--r--kig/examples/session_alotofthings.fgeo136
-rw-r--r--kig/filters/cabri-filter.cc82
-rw-r--r--kig/filters/drgeo-filter-chooser.h1
-rw-r--r--kig/filters/drgeo-filter-chooserbase.ui16
-rw-r--r--kig/filters/drgeo-filter.cc240
-rw-r--r--kig/filters/drgeo-filter.h2
-rw-r--r--kig/filters/exporter.cc38
-rw-r--r--kig/filters/filter.cc8
-rw-r--r--kig/filters/filter.h6
-rw-r--r--kig/filters/filters-common.cc2
-rw-r--r--kig/filters/imageexporteroptions.cc4
-rw-r--r--kig/filters/imageexporteroptions.h3
-rw-r--r--kig/filters/imageexporteroptionsbase.ui24
-rw-r--r--kig/filters/kgeo-filter.cc142
-rw-r--r--kig/filters/kgeo-filter.h4
-rw-r--r--kig/filters/kgeo-resource.h2
-rw-r--r--kig/filters/kseg-defs.h8
-rw-r--r--kig/filters/kseg-filter.cc188
-rw-r--r--kig/filters/kseg-filter.h2
-rw-r--r--kig/filters/latexexporter.cc16
-rw-r--r--kig/filters/latexexporteroptions.ui14
-rw-r--r--kig/filters/native-filter.cc98
-rw-r--r--kig/filters/svgexporter.cc14
-rw-r--r--kig/filters/svgexporteroptions.ui12
-rw-r--r--kig/filters/tests/locus.fgeo2
-rw-r--r--kig/kfile/Makefile.am4
-rw-r--r--kig/kfile/kfile_drgeo.cpp6
-rw-r--r--kig/kfile/kfile_drgeo.h3
-rw-r--r--kig/kfile/kfile_kig.cpp10
-rw-r--r--kig/kfile/kfile_kig.h3
-rw-r--r--kig/kig/kig.cpp24
-rw-r--r--kig/kig/kig.h3
-rw-r--r--kig/kig/kig_commands.cpp54
-rw-r--r--kig/kig/kig_commands.h7
-rw-r--r--kig/kig/kig_document.cc2
-rw-r--r--kig/kig/kig_part.cpp56
-rw-r--r--kig/kig/kig_part.h5
-rw-r--r--kig/kig/kig_view.cpp50
-rw-r--r--kig/kig/kig_view.h18
-rw-r--r--kig/misc/argsparser.cpp14
-rw-r--r--kig/misc/argsparser.h14
-rw-r--r--kig/misc/builtin_stuff.cc20
-rw-r--r--kig/misc/calcpaths.cc48
-rw-r--r--kig/misc/calcpaths.h6
-rw-r--r--kig/misc/common.cpp18
-rw-r--r--kig/misc/common.h2
-rw-r--r--kig/misc/coordinate.cpp6
-rw-r--r--kig/misc/coordinate.h4
-rw-r--r--kig/misc/coordinate_system.cpp50
-rw-r--r--kig/misc/coordinate_system.h2
-rw-r--r--kig/misc/cubic-common.cc2
-rw-r--r--kig/misc/guiaction.cc20
-rw-r--r--kig/misc/guiaction.h3
-rw-r--r--kig/misc/kigfiledialog.cc6
-rw-r--r--kig/misc/kigfiledialog.h7
-rw-r--r--kig/misc/kiginputdialog.cc28
-rw-r--r--kig/misc/kiginputdialog.h17
-rw-r--r--kig/misc/kigpainter.cpp44
-rw-r--r--kig/misc/kigpainter.h10
-rw-r--r--kig/misc/lists.cc8
-rw-r--r--kig/misc/object_constructor.cc38
-rw-r--r--kig/misc/object_constructor.h8
-rw-r--r--kig/misc/object_hierarchy.cc146
-rw-r--r--kig/misc/object_hierarchy.h12
-rw-r--r--kig/misc/rect.cc10
-rw-r--r--kig/misc/rect.h8
-rw-r--r--kig/misc/special_constructors.cc188
-rw-r--r--kig/misc/special_constructors.h18
-rw-r--r--kig/modes/base_mode.cc28
-rw-r--r--kig/modes/base_mode.h2
-rw-r--r--kig/modes/construct_mode.cc82
-rw-r--r--kig/modes/construct_mode.h2
-rw-r--r--kig/modes/dragrectmode.cc2
-rw-r--r--kig/modes/edittype.cc8
-rw-r--r--kig/modes/edittype.h3
-rw-r--r--kig/modes/edittypebase.ui40
-rw-r--r--kig/modes/label.cc68
-rw-r--r--kig/modes/label.h10
-rw-r--r--kig/modes/linkslabel.cpp34
-rw-r--r--kig/modes/linkslabel.h5
-rw-r--r--kig/modes/macro.cc6
-rw-r--r--kig/modes/macrowizard.cc8
-rw-r--r--kig/modes/macrowizard.h3
-rw-r--r--kig/modes/macrowizardbase.ui28
-rw-r--r--kig/modes/mode.h2
-rw-r--r--kig/modes/moving.cc54
-rw-r--r--kig/modes/moving.h2
-rw-r--r--kig/modes/normal.cc6
-rw-r--r--kig/modes/popup.cc52
-rw-r--r--kig/modes/popup.h2
-rw-r--r--kig/modes/textlabelwizard.cc12
-rw-r--r--kig/modes/textlabelwizard.h5
-rw-r--r--kig/modes/textlabelwizardbase.ui22
-rw-r--r--kig/modes/typesdialog.cpp14
-rw-r--r--kig/modes/typesdialog.h3
-rw-r--r--kig/modes/typesdialogbase.ui38
-rw-r--r--kig/objects/angle_type.cc30
-rw-r--r--kig/objects/arc_type.h4
-rw-r--r--kig/objects/base_type.cc42
-rw-r--r--kig/objects/bogus_imp.cc10
-rw-r--r--kig/objects/bogus_imp.h2
-rw-r--r--kig/objects/circle_imp.cc26
-rw-r--r--kig/objects/circle_imp.h2
-rw-r--r--kig/objects/conic_imp.cc22
-rw-r--r--kig/objects/conic_imp.h2
-rw-r--r--kig/objects/conic_types.cc104
-rw-r--r--kig/objects/conic_types.h22
-rw-r--r--kig/objects/cubic_imp.cc28
-rw-r--r--kig/objects/cubic_imp.h2
-rw-r--r--kig/objects/cubic_type.cc12
-rw-r--r--kig/objects/cubic_type.h6
-rw-r--r--kig/objects/intersection_types.cc70
-rw-r--r--kig/objects/intersection_types.h12
-rw-r--r--kig/objects/line_imp.cc10
-rw-r--r--kig/objects/line_imp.h6
-rw-r--r--kig/objects/line_type.cc12
-rw-r--r--kig/objects/locus_imp.cc2
-rw-r--r--kig/objects/locus_imp.h8
-rw-r--r--kig/objects/object_calcer.cc78
-rw-r--r--kig/objects/object_calcer.h66
-rw-r--r--kig/objects/object_drawer.cc22
-rw-r--r--kig/objects/object_drawer.h6
-rw-r--r--kig/objects/object_factory.cc98
-rw-r--r--kig/objects/object_factory.h18
-rw-r--r--kig/objects/object_holder.cc8
-rw-r--r--kig/objects/object_holder.h4
-rw-r--r--kig/objects/object_imp.cc6
-rw-r--r--kig/objects/object_imp.h12
-rw-r--r--kig/objects/object_imp_factory.cc138
-rw-r--r--kig/objects/object_imp_factory.h8
-rw-r--r--kig/objects/object_type.cc8
-rw-r--r--kig/objects/object_type.h18
-rw-r--r--kig/objects/object_type_factory.cc4
-rw-r--r--kig/objects/object_type_factory.h2
-rw-r--r--kig/objects/other_imp.cc8
-rw-r--r--kig/objects/other_imp.h6
-rw-r--r--kig/objects/other_type.cc20
-rw-r--r--kig/objects/other_type.h8
-rw-r--r--kig/objects/point_imp.cc6
-rw-r--r--kig/objects/point_imp.h2
-rw-r--r--kig/objects/point_type.cc106
-rw-r--r--kig/objects/point_type.h20
-rw-r--r--kig/objects/polygon_imp.cc4
-rw-r--r--kig/objects/polygon_imp.h2
-rw-r--r--kig/objects/polygon_type.cc184
-rw-r--r--kig/objects/polygon_type.h22
-rw-r--r--kig/objects/special_calcers.cc4
-rw-r--r--kig/objects/special_calcers.h2
-rw-r--r--kig/objects/tests_type.cc66
-rw-r--r--kig/objects/tests_type.h16
-rw-r--r--kig/objects/text_imp.cc4
-rw-r--r--kig/objects/text_imp.h4
-rw-r--r--kig/objects/text_type.cc32
-rw-r--r--kig/objects/text_type.h6
-rwxr-xr-xkig/pykig/pykig.py6
-rw-r--r--kig/scripting/newscriptwizard.cc18
-rw-r--r--kig/scripting/newscriptwizard.h3
-rw-r--r--kig/scripting/newscriptwizardbase.ui18
-rw-r--r--kig/scripting/python_type.cc22
-rw-r--r--kig/scripting/python_type.h12
-rw-r--r--kig/scripting/script-common.cc4
-rw-r--r--kig/scripting/script_mode.cc16
171 files changed, 2183 insertions, 2153 deletions
diff --git a/kig/ChangeLog b/kig/ChangeLog
index ec8d6042..8c60c89f 100644
--- a/kig/ChangeLog
+++ b/kig/ChangeLog
@@ -10,7 +10,7 @@
2005-09-16 Pino Toscano <toscano.pino@tiscali.it>
* Move a text label by (2,2), so the attached ones should be less
- sticky to the "parent" object.
+ sticky to the "tqparent" object.
2005-09-08 Pino Toscano <toscano.pino@tiscali.it>
@@ -936,7 +936,7 @@
and made a sort of skeleton to modify type's data.
* Made buttons of some dialogs like other KDE dialogs ones (with
- icons and correct alignment).
+ icons and correct tqalignment).
* Kig now ask the user when exporting type(s) to an already
existant file.
@@ -1142,8 +1142,8 @@
* Fix the moving system again, it now only redraws exactly those
objects that need to be redrawn. E.g. when a constrained point
- was moved, before it was assumed that all of its parents, and
- their children would move, whereas in reality, a constrained point
+ was moved, before it was assumed that all of its tqparents, and
+ their tqchildren would move, whereas in reality, a constrained point
does not move the curve it is constrained to. This is now taken
into account for. This much optimizes the case where we move the
constrained point in examples/sine-curve.kig.
@@ -1200,7 +1200,7 @@
could not open.. I'm backporting this into Kig 0.6.0 and
informing the packager..
- * clean up: Objects now store their parents in order, so that no
+ * clean up: Objects now store their tqparents in order, so that no
parsing has to be done in the calc() function.. Also some more
modifications making that function a bit simpler are included.
Specifically, ArgsParser now does the checking of the arguments,
@@ -1218,7 +1218,7 @@
2003-09-01 Dominique Devriese <devriese@kde.org>
- * only move an object if its parents are not yet moving.. This
+ * only move an object if its tqparents are not yet moving.. This
fixes bug #63250.
* remove the defective operator| and operator& implementations for
@@ -1399,7 +1399,7 @@
* show an appropriate error when trying to open an non-existing
file..
- * clean up the object parent-child relation mechanism. Rather
+ * clean up the object tqparent-child relation mechanism. Rather
large code cleanup, that simplifies a lot of code.. Needed a
backwards-compatible file format extension. This commit now also
adds proper treatment of internal objects, because it no longer
@@ -1438,7 +1438,7 @@
2003-05-24 Dominique Devriese <devriese@kde.org>
* when the user tries to construct a macro that constructs an
- object from its children, warn him instead of
+ object from its tqchildren, warn him instead of
crashing... Thanks to Stephan Binner for the bug report
* improve the export to image dialog, as suggested by Stephan Binner
@@ -1516,7 +1516,7 @@
* organise the filters directory more sanely
- * fix for deleting: remove deleted objects from their children, so
+ * fix for deleting: remove deleted objects from their tqchildren, so
they don't appear in saved files
2003-05-07 Dominique Devriese <devriese@kde.org>
diff --git a/kig/DESIGN b/kig/DESIGN
index fd887779..6d4a8c37 100644
--- a/kig/DESIGN
+++ b/kig/DESIGN
@@ -19,7 +19,7 @@ An ObjectImp represents the current state of an object in Kig. It
keeps information about what type of object it is ( e.g. a line, a
point, a circle etc. ), and its exact data ( e.g. the center and
radius of the circle ). It is *not* in any way aware of how the
-object was calculated from its parents (e.g. is this a line that is
+object was calculated from its tqparents (e.g. is this a line that is
constructed as the parallel of another line, or as the line going
through two given points ? ) or how it is drawn on the window (
e.g. the thickness of the line, its color etc. ).
@@ -50,21 +50,21 @@ calculating an ObjectImp from other ObjectImp's. It is also a node in
the dependency graph of a certain document. E.g. a LineImp can be
calculated from the two PointImp's it has to go through; every time
either of them moves, this calculation is redone. In this case, there
-would be an ObjectCalcer that keeps a reference to its two parents (
+would be an ObjectCalcer that keeps a reference to its two tqparents (
the ObjectCalcer's representing the points ), and that will calculate
its ObjectImp value every time it is asked to do so ( i.e. every time
-one of its parents moves.. ).
+one of its tqparents moves.. ).
Because of the complex relations that ObjectCalcer's hold to other
ObjectCalcer's and to other classes, they have been made
reference-counted. This means that they keep a count internally of
how much times a pointer to them is held. If this count reaches 0,
this means that nobody needs them anymore, and they delete themselves.
-E.g. an ObjectCalcer always keeps a reference to its parents, to
+E.g. an ObjectCalcer always keeps a reference to its tqparents, to
ensure that those aren't deleted before it is deleted.
In the inheritance graph of a document, the lowermost objects keep
-references to their parents and those keep reference to their parents,
+references to their tqparents and those keep reference to their tqparents,
so that all of the top of the graph is kept alive. Of course, someone
needs to keep a reference to the bottommost objects in the graph,
because otherwise, the entire graph would be deleted. As we will see
@@ -76,7 +76,7 @@ At the end of the program, this reference is released, and all the
objects are deleted.
A special case of an ObjectCalcer is the ObjectConstCalcer. This is
-an ObjectCalcer that has no parents, and only holds some data. The
+an ObjectCalcer that has no tqparents, and only holds some data. The
data is held as an ObjectImp of some type, and it will remain
constant, and no calculation needs to be done to get it, it is just
returned every time it is needed.
@@ -158,10 +158,10 @@ Most of this is handled by the TextType class.
2.1.2 TextType
-The TextType class is an implementation of an ObjectType. It contains
-code specifying how to calculate a TextImp from its parents, and for
+The TextType class is an implementation of an ObjectType. It tqcontains
+code specifying how to calculate a TextImp from its tqparents, and for
how it behaves on user input. A text object has at least three
-parents, and can handle any number of optional arguments. The three
+tqparents, and can handle any number of optional arguments. The three
mandatory arguments are an int, which is set to 1 or 0 depending on
whether the label needs a surrounding box, a PointImp, containing the
location of the text label, and a string containing the text of the
@@ -170,7 +170,7 @@ additional argument is used to replace the lowest-numbered of those
tokens, with its string representation. The function
ObjectImp::fillInNextEscape is used for this.
-For example, if a TextType has the following parents:
+For example, if a TextType has the following tqparents:
a IntImp with value 0
a PointImp with value (0,0)
a String with value "This segment is %1 units long."
@@ -185,7 +185,7 @@ All this gives labels in Kig a lot of flexibility.
2.2 Locuses
Locuses are a mathematical concept that has been modelled in Kig.
-Loosely defined, a locus is the mathematical shape defined by the set
+Loosely defined, a locus is the mathematical tqshape defined by the set
of points that a certain point moves through while another point is
moved over its constraints. This can be used to define mathematical
objects like conics, and various other things. It has been modelled
@@ -197,7 +197,7 @@ proud of this design.
In the implementation of this, we use the concept of constrained
points. This is a point that is attached to a certain curve. It is
implemented in Kig by the ConstrainedPointType, which takes a CurveImp
-and a DoubleImp as parents and calculates a Point from these by using
+and a DoubleImp as tqparents and calculates a Point from these by using
the CurveImp::getPoint function.
2.2.2 The Implementation
@@ -213,7 +213,7 @@ smallest part of the hierarchy that contains all paths from the first
point to the second point. We then determine all objects that are not
*on* one of those paths ( meaning that they are not calculated from
the first point, or another object that is on one of those paths ),
-but that are parents of one or more objects that are on those paths.
+but that are tqparents of one or more objects that are on those paths.
I call this set of objects the "side of the path" sometimes in the
code. The function that finds them is called sideOfTreePath.
@@ -221,7 +221,7 @@ Next, an ObjectHierarchy object is constructed, which stores the way
to calculate the second point from the first point and the objects
from the previous paragraph.
-An object is then constructed that has as parent the curve parent that
+An object is then constructed that has as tqparent the curve tqparent that
the first point is constrained to, the HierarchyImp containing the
ObjectHierarchy from the previous paragraph, and all the objects from
the "side of the tree". This new object is an ObjectTypeCalcer with
@@ -258,9 +258,9 @@ the constrained point. This is wrong because when the constrained
point moves within the limits of the curve constraining it, the locus
does by definition not change. Also, if the constrained point is
redefined so that it is no longer constrained to any curve, this is a
-major problem, because it would invalidate the locus. Another point
+major problem, because it would tqinvalidate the locus. Another point
is that in practice, the locus depends on more objects than its
-parents alone. This is not a good thing, because it makes it
+tqparents alone. This is not a good thing, because it makes it
impossible to optimise drawing of the objects, using the information
about which objects depend on which others, because this information
is invalid.
diff --git a/kig/FEATURES b/kig/FEATURES
index 012f49f1..054ce9bc 100644
--- a/kig/FEATURES
+++ b/kig/FEATURES
@@ -16,7 +16,7 @@ here are some nice Kig features i'd like to show off :)
- is a KPart: try opening macrotest.kig from konqueror, if it doesn't
work yet, open your kcontrol, then go to "File Browsing"->"File
Associations", click add, group:"application", name:"x-kig", open
- the "embedding" tab page for the new type, click "add", find
+ the "embedding" tab page for the new type, click "add", tqfind
"KigPart" (if you installed Kig correctly (did you get the
"--prefix" on your configure right?) , it should be there), and add
it. then try opening macrotest.kig again
@@ -30,7 +30,7 @@ here are some nice Kig features i'd like to show off :)
Moreover, the other supported formats are: XFig files, and SVG and
LaTeX documents. These are useful since not all other programs
support Kig files yet... ;)
-- Kig is very compatible with the program it was intended to replace,
+- Kig is very compatible with the program it was intended to tqreplace,
KGeo. It supports all of its Object types and most of its file
format...
- There is a very flexible mechanism for supporting TextLabels with
diff --git a/kig/Makefile.am b/kig/Makefile.am
index b2483db0..66724ec2 100644
--- a/kig/Makefile.am
+++ b/kig/Makefile.am
@@ -1,3 +1,5 @@
+INCLUDES = $(all_includes)
+
if KIG_COMPILE_PYTHON_SCRIPTING
scriptingdir = scripting
scriptinglib = scripting/libscripting.la
@@ -23,7 +25,7 @@ SUBDIRS = \
kde_module_LTLIBRARIES = libkigpart.la
libkigpart_la_SOURCES = dummy.cpp
-libkigpart_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries)
+libkigpart_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries) $(LIB_QT) $(LIB_KDECORE) $(LIB_KDEUI) $(LIB_KIO) -lktexteditor
libkigpart_la_LIBADD = $(LIB_KPARTS) \
misc/libmisc.la objects/libobjects.la filters/libfilters.la \
modes/libmodes.la kig/libkigparttemp.la $(scriptinglib)
diff --git a/kig/README.boost-python1.30-gcc3.2 b/kig/README.boost-python1.30-gcc3.2
index cafda75e..959d5264 100644
--- a/kig/README.boost-python1.30-gcc3.2
+++ b/kig/README.boost-python1.30-gcc3.2
@@ -12,7 +12,7 @@ be applied in the following way.
Open a console window, and go to the directory containing the
Boost.Python headers. This will most likely be called something like
"/usr/include/boost/python/". Then execute the following commands (
-before giving these commands, replace "/dir/to/kig/distribution/" by
+before giving these commands, tqreplace "/dir/to/kig/distribution/" by
the directory where you put the downloaded kig distribution ):
cd object
diff --git a/kig/TODO b/kig/TODO
index 8acd9949..a6f97fe3 100644
--- a/kig/TODO
+++ b/kig/TODO
@@ -50,7 +50,7 @@
- make DoubleImp a "visible" object with uses like Dr. Geo numeric
values.
-- Provide some nice stuff for differential geometry: velocity vector
+- Provide some nice stuff for differential tqgeometry: velocity vector
of a curve, curvature vector, osculating parabole. Most of this is
not too difficult to implement, but very cool :)
@@ -58,9 +58,9 @@
allow for importing from/exporting to other formula formats such as
KFormula, OOFormula and MathML.
-- other types of fillable shapes, like arc sector, arc segment...
+- other types of fillable tqshapes, like arc sector, arc segment...
-- defined integrals, as a particular case of filled shapes.
+- defined integrals, as a particular case of filled tqshapes.
- improve *a lot* the transformation support for cubics.
@@ -102,8 +102,8 @@
- extend ObjectFactory::sensiblePointCalcer to also construct
intersection points of stuff... (pino: done for lines)
-- when moving an object that wants to move its parents, try to check if
- it is itself not an indirect child of one of the parents it is
+- when moving an object that wants to move its tqparents, try to check if
+ it is itself not an indirect child of one of the tqparents it is
trying to move, and forbid the move in that case, as it will lead
to chaotic behaviour. I am not sure if this is really well
possible, but I have to look at it.
@@ -141,7 +141,7 @@
- write cabri-filter-status.txt.
-- add "Tools": easy tools designed for geometry, like Angle converter and
+- add "Tools": easy tools designed for tqgeometry, like Angle converter and
so on...
- save a "session", i.e.: record how a document is moved, and save it to
diff --git a/kig/configure.in.in b/kig/configure.in.in
index 33986af8..b9884199 100644
--- a/kig/configure.in.in
+++ b/kig/configure.in.in
@@ -121,6 +121,12 @@ AC_DEFUN([REGINA_LIB_BOOST_PYTHON], [
"$prefix/include/$pyver" "$prefix/$pyver/include"; do
CXXFLAGS="$__regina_py_save_cxxflags -I$incdir"
LDFLAGS="$__regina_py_save_ldflags -shared"
+ if test -z "$qt_libraries"; then
+ LDFLAGS="$LDFLAGS"
+ else
+ LDFLAGS="$LDFLAGS -L$qt_libraries"
+ fi
+ LDFLAGS="$LDFLAGS -ltqt"
# Check for python includes.
AC_TRY_COMPILE([
@@ -146,6 +152,12 @@ AC_DEFUN([REGINA_LIB_BOOST_PYTHON], [
for extralibs in "" "-lpthread -lm -lutil -ldl"; do
AC_MSG_CHECKING([for $pylibdir/lib$pylib and $extralibs with $incdir/Python.h])
LDFLAGS="$__regina_py_save_ldflags -L$pylibdir"
+ if test -z "$qt_libraries"; then
+ LDFLAGS="$LDFLAGS"
+ else
+ LDFLAGS="$LDFLAGS -L$qt_libraries"
+ fi
+ LDFLAGS="$LDFLAGS -ltqt"
LIBS="-l$pylib $extralibs"
AC_TRY_LINK([
#include <Python.h>
@@ -156,6 +168,12 @@ AC_DEFUN([REGINA_LIB_BOOST_PYTHON], [
for bplib in "-lboost_python-mt" "-lboost_python-gcc-mt-1_32" "-lboost_python-gcc-mt-1_31" "-lboost_python-gcc-mt" "-lboost_python"; do
AC_MSG_CHECKING([compilation of a boost.python program with $bplib])
LDFLAGS="$__regina_py_save_ldflags -L$pylibdir"
+ if test -z "$qt_libraries"; then
+ LDFLAGS="$LDFLAGS"
+ else
+ LDFLAGS="$LDFLAGS -L$qt_libraries"
+ fi
+ LDFLAGS="$LDFLAGS -ltqt"
LIBS="-l$pylib $bplib $extralibs"
AC_TRY_LINK([
#include <boost/python.hpp>
diff --git a/kig/examples/figure_angle.fgeo b/kig/examples/figure_angle.fgeo
index 22db1113..47076564 100644
--- a/kig/examples/figure_angle.fgeo
+++ b/kig/examples/figure_angle.fgeo
@@ -1,30 +1,30 @@
<?xml version="1.0"?>
<drgenius>
<drgeo name="Figure 1" scale="30.000000" origin_x="0.000000" origin_y="0.000000" grid="False">
- <point id="827A5C0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="827A5C0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-5.833333</x>
<y>2.950000</y>
</point>
- <point id="8248660" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="8248660" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-4.666666</x>
<y>-0.783334</y>
</point>
- <point id="822A6B0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="822A6B0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>2.333334</x>
<y>-0.216667</y>
</point>
- <line id="822BC80" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="827A5C0"/>
- <parent ref="8248660"/>
+ <line id="822BC80" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="827A5C0"/>
+ <tqparent ref="8248660"/>
</line>
- <line id="8249A48" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="822A6B0"/>
- <parent ref="8248660"/>
+ <line id="8249A48" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="822A6B0"/>
+ <tqparent ref="8248660"/>
</line>
- <angle id="82B86D8" type="3pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="822A6B0"/>
- <parent ref="8248660"/>
- <parent ref="827A5C0"/>
+ <angle id="82B86D8" type="3pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="822A6B0"/>
+ <tqparent ref="8248660"/>
+ <tqparent ref="827A5C0"/>
</angle>
</drgeo>
</drgenius>
diff --git a/kig/examples/figure_manyobjects.fgeo b/kig/examples/figure_manyobjects.fgeo
index c03634e3..c89c976f 100644
--- a/kig/examples/figure_manyobjects.fgeo
+++ b/kig/examples/figure_manyobjects.fgeo
@@ -1,72 +1,72 @@
<?xml version="1.0"?>
<drgenius>
<drgeo name="Figure 1" scale="30.000000" origin_x="0.000000" origin_y="0.000000" grid="False">
- <point id="82257B8" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="82257B8" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-6.700000</x>
<y>2.250000</y>
</point>
- <point id="8250458" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="8250458" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>0.266667</x>
<y>2.083333</y>
</point>
- <point id="8250D30" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="8250D30" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-0.800000</x>
<y>-2.516667</y>
</point>
- <point id="8255158" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="8255158" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-2.766667</x>
<y>1.883333</y>
</point>
- <point id="8226648" type="Middle_2pts" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
- <parent ref="82257B8"/>
- <parent ref="8255158"/>
+ <point id="8226648" type="Middle_2pts" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
+ <tqparent ref="82257B8"/>
+ <tqparent ref="8255158"/>
</point>
- <halfLine id="8225B10" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="8250D30"/>
- <parent ref="8250458"/>
+ <halfLine id="8225B10" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="8250D30"/>
+ <tqparent ref="8250458"/>
</halfLine>
- <point id="82043A0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="82043A0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-2.833333</x>
<y>-0.983334</y>
</point>
- <point id="8115668" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="8115668" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>1.500000</x>
<y>1.883333</y>
</point>
- <point id="82AED28" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="82AED28" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-0.566667</x>
<y>3.983333</y>
</point>
- <segment id="82B0888" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="82257B8"/>
- <parent ref="82AED28"/>
+ <segment id="82B0888" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="82257B8"/>
+ <tqparent ref="82AED28"/>
</segment>
- <line id="82B1B80" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="82043A0"/>
- <parent ref="8115668"/>
+ <line id="82B1B80" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="82043A0"/>
+ <tqparent ref="8115668"/>
</line>
- <point id="82B26F0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="82B26F0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-5.533333</x>
<y>-0.383333</y>
</point>
- <vector id="82A3948" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
+ <vector id="82A3948" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
<Ox>-2.800000</Ox>
<Oy>1.883333</Oy>
- <parent ref="8255158"/>
- <parent ref="82B26F0"/>
+ <tqparent ref="8255158"/>
+ <tqparent ref="82B26F0"/>
</vector>
- <point id="82B4358" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="82B4358" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>3.166667</x>
<y>-0.683333</y>
</point>
- <circle id="82B5918" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="82B4358"/>
- <parent ref="8115668"/>
+ <circle id="82B5918" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="82B4358"/>
+ <tqparent ref="8115668"/>
</circle>
- <arcCircle id="82B5D30" type="3pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="82257B8"/>
- <parent ref="82B26F0"/>
- <parent ref="8250D30"/>
+ <arcCircle id="82B5D30" type="3pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="82257B8"/>
+ <tqparent ref="82B26F0"/>
+ <tqparent ref="8250D30"/>
</arcCircle>
</drgeo>
</drgenius>
diff --git a/kig/examples/session_alotofthings.fgeo b/kig/examples/session_alotofthings.fgeo
index 967dada9..dc8bb729 100644
--- a/kig/examples/session_alotofthings.fgeo
+++ b/kig/examples/session_alotofthings.fgeo
@@ -1,69 +1,69 @@
<?xml version="1.0"?>
<drgenius>
<drgeo name="Figure 1" scale="30.000000" origin_x="0.000000" origin_y="0.000000" grid="False">
- <point id="82076B0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="82076B0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>0.766667</x>
<y>2.450000</y>
</point>
- <point id="8281F08" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="8281F08" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-3.300000</x>
<y>2.650000</y>
</point>
- <point id="82535F0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="82535F0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-7.900000</x>
<y>-2.583333</y>
</point>
- <point id="822F448" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="822F448" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-7.800000</x>
<y>0.116667</y>
</point>
- <point id="8208228" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="8208228" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-4.533333</x>
<y>1.216667</y>
</point>
- <point id="822FB88" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="822FB88" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-8.566667</x>
<y>3.116667</y>
</point>
- <point id="82B08A0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="82B08A0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-7.066667</x>
<y>1.783334</y>
</point>
- <line id="82C3C40" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="8281F08"/>
- <parent ref="82076B0"/>
+ <line id="82C3C40" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="8281F08"/>
+ <tqparent ref="82076B0"/>
</line>
- <arcCircle id="82C2F40" type="3pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="8208228"/>
- <parent ref="822F448"/>
- <parent ref="82535F0"/>
+ <arcCircle id="82C2F40" type="3pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="8208228"/>
+ <tqparent ref="822F448"/>
+ <tqparent ref="82535F0"/>
</arcCircle>
- <halfLine id="82A86B8" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="822FB88"/>
- <parent ref="82B08A0"/>
+ <halfLine id="82A86B8" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="822FB88"/>
+ <tqparent ref="82B08A0"/>
</halfLine>
- <point id="82C8738" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="82C8738" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-1.066667</x>
<y>-0.416667</y>
</point>
- <point id="82C4DC8" type="Intersection" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="" extra="0">
- <parent ref="82A86B8"/>
- <parent ref="82C2F40"/>
+ <point id="82C4DC8" type="Intersection" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="" extra="0">
+ <tqparent ref="82A86B8"/>
+ <tqparent ref="82C2F40"/>
</point>
- <point id="82C5230" type="Intersection" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="" extra="1">
- <parent ref="82A86B8"/>
- <parent ref="82C2F40"/>
+ <point id="82C5230" type="Intersection" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="" extra="1">
+ <tqparent ref="82A86B8"/>
+ <tqparent ref="82C2F40"/>
</point>
- <line id="82BF640" type="perpendicular" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="82C8738"/>
- <parent ref="82C3C40"/>
+ <line id="82BF640" type="perpendicular" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="82C8738"/>
+ <tqparent ref="82C3C40"/>
</line>
- <point id="83030E0" type="Reflexion" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
- <parent ref="82C4DC8"/>
- <parent ref="82BF640"/>
+ <point id="83030E0" type="Reflexion" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
+ <tqparent ref="82C4DC8"/>
+ <tqparent ref="82BF640"/>
</point>
</drgeo>
- <text name="Testo 1">Figure 1 contains:
+ <text name="Testo 1">Figure 1 tqcontains:
- some points;
- an arc;
- a line;
@@ -72,91 +72,91 @@
- an intersection point;
- a reflection point;
-Figure 2 contains:
+Figure 2 tqcontains:
- some points;
- 2 lines;
- a midpoint;
- a parallel;
- 2 intersection points;
-Figure 3 contains:
+Figure 3 tqcontains:
- some points;
- a circle;
- a vector;
- a moved circle;
</text>
<drgeo name="Figure 2" scale="30.000000" origin_x="0.000000" origin_y="0.000000" grid="False">
- <point id="831A340" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="831A340" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-5.200000</x>
<y>0.216667</y>
</point>
- <point id="82D1958" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="82D1958" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>1.200000</x>
<y>3.116667</y>
</point>
- <point id="82EB588" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="82EB588" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-7.666667</x>
<y>1.650000</y>
</point>
- <line id="8337158" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="82EB588"/>
- <parent ref="831A340"/>
+ <line id="8337158" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="82EB588"/>
+ <tqparent ref="831A340"/>
</line>
- <point id="8339778" type="Middle_2pts" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
- <parent ref="831A340"/>
- <parent ref="82D1958"/>
+ <point id="8339778" type="Middle_2pts" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
+ <tqparent ref="831A340"/>
+ <tqparent ref="82D1958"/>
</point>
- <line id="8322C38" type="parallel" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="8339778"/>
- <parent ref="8337158"/>
+ <line id="8322C38" type="parallel" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="8339778"/>
+ <tqparent ref="8337158"/>
</line>
- <point id="8322E28" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="8322E28" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-6.200000</x>
<y>-1.483334</y>
</point>
- <line id="831E530" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="8322E28"/>
- <parent ref="82D1958"/>
+ <line id="831E530" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="8322E28"/>
+ <tqparent ref="82D1958"/>
</line>
- <point id="8356028" type="Intersection" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="" extra="0">
- <parent ref="831E530"/>
- <parent ref="8337158"/>
+ <point id="8356028" type="Intersection" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="" extra="0">
+ <tqparent ref="831E530"/>
+ <tqparent ref="8337158"/>
</point>
- <point id="8320CC8" type="Intersection" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="" extra="0">
- <parent ref="8322C38"/>
- <parent ref="831E530"/>
+ <point id="8320CC8" type="Intersection" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="" extra="0">
+ <tqparent ref="8322C38"/>
+ <tqparent ref="831E530"/>
</point>
</drgeo>
<drgeo name="Figure 3" scale="30.000000" origin_x="0.000000" origin_y="0.000000" grid="False">
- <point id="837C5E0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="837C5E0" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-6.433334</x>
<y>2.050000</y>
</point>
- <point id="83380E8" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="83380E8" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-1.400000</x>
<y>2.583333</y>
</point>
- <point id="83565C8" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="83565C8" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-1.300000</x>
<y>-0.350000</y>
</point>
- <point id="82FBCC8" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" masked="False" name="">
+ <point id="82FBCC8" type="Free" color="Red" thickness="Dashed" style="Round" filled="False" tqmasked="False" name="">
<x>-3.433333</x>
<y>-0.883333</y>
</point>
- <vector id="8108B10" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
+ <vector id="8108B10" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
<Ox>-6.433334</Ox>
<Oy>2.050000</Oy>
- <parent ref="837C5E0"/>
- <parent ref="83380E8"/>
+ <tqparent ref="837C5E0"/>
+ <tqparent ref="83380E8"/>
</vector>
- <circle id="83A2B10" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="82FBCC8"/>
- <parent ref="83565C8"/>
+ <circle id="83A2B10" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="82FBCC8"/>
+ <tqparent ref="83565C8"/>
</circle>
- <circle id="83D6820" type="Translation" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name="">
- <parent ref="83A2B10"/>
- <parent ref="8108B10"/>
+ <circle id="83D6820" type="Translation" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name="">
+ <tqparent ref="83A2B10"/>
+ <tqparent ref="8108B10"/>
</circle>
</drgeo>
</drgenius>
diff --git a/kig/filters/cabri-filter.cc b/kig/filters/cabri-filter.cc
index 3cadf522..55ecf939 100644
--- a/kig/filters/cabri-filter.cc
+++ b/kig/filters/cabri-filter.cc
@@ -56,7 +56,7 @@
*
* Nr: Simple sequential numbering of the objects in a file.
* Type: seen so far: Pt, Axes, Line, Cir
- * NumberOfParents: The number of parents that will be specified in
+ * NumberOfParents: The number of tqparents that will be specified in
* Parents
* Color:
* R -> red
@@ -96,7 +96,7 @@
* Visible:
* V means visible, I means invisible
* Fixed:
- * St means fix this object ( if you move one of its parents, it
+ * St means fix this object ( if you move one of its tqparents, it
* won't move ), nSt ( the default ) means don't fix this object.
* Parents:
* The numbers of the objects this object depends on
@@ -118,7 +118,7 @@ struct CabriObject
int specialAppearanceSwitch;
bool visible;
bool fixed;
- std::vector<int> parents;
+ std::vector<int> tqparents;
std::vector<double> data;
};
@@ -151,25 +151,25 @@ static TQString readLine( TQFile& file )
static TQColor translatecolor( const TQString& s )
{
- if ( s == "R" ) return Qt::red;
- if ( s == "O" ) return Qt::magenta;
- if ( s == "Y" ) return Qt::yellow;
- if ( s == "P" ) return Qt::darkMagenta;
- if ( s == "V" ) return Qt::darkBlue;
- if ( s == "Bl" ) return Qt::blue;
- if ( s == "lBl" ) return Qt::cyan; // TODO: bright blue
- if ( s == "G" ) return Qt::green;
- if ( s == "dG" ) return Qt::darkGreen;
+ if ( s == "R" ) return TQt::red;
+ if ( s == "O" ) return TQt::magenta;
+ if ( s == "Y" ) return TQt::yellow;
+ if ( s == "P" ) return TQt::darkMagenta;
+ if ( s == "V" ) return TQt::darkBlue;
+ if ( s == "Bl" ) return TQt::blue;
+ if ( s == "lBl" ) return TQt::cyan; // TODO: bright blue
+ if ( s == "G" ) return TQt::green;
+ if ( s == "dG" ) return TQt::darkGreen;
if ( s == "Br" ) return TQColor( 165, 42, 42 );
if ( s == "dBr" ) return TQColor( 128, 128, 0 );
- if ( s == "lGr" ) return Qt::lightGray;
- if ( s == "Gr" ) return Qt::gray;
- if ( s == "dGr" ) return Qt::darkGray;
- if ( s == "B" ) return Qt::black;
- if ( s == "W" ) return Qt::white;
+ if ( s == "lGr" ) return TQt::lightGray;
+ if ( s == "Gr" ) return TQt::gray;
+ if ( s == "dGr" ) return TQt::darkGray;
+ if ( s == "B" ) return TQt::black;
+ if ( s == "W" ) return TQt::white;
kdDebug() << k_funcinfo << "unknown color: " << s << endl;
- return Qt::black;
+ return TQt::black;
}
bool KigFilterCabri::readObject( TQFile& f, CabriObject& myobj )
@@ -246,14 +246,14 @@ bool KigFilterCabri::readObject( TQFile& f, CabriObject& myobj )
KIG_FILTER_PARSE_ERROR;
tmp = thirdlinere.cap( 2 );
- TQStringList parentsids = TQStringList::split( ' ', tmp );
- for ( TQStringList::iterator i = parentsids.begin();
- i != parentsids.end(); ++i )
+ TQStringList tqparentsids = TQStringList::split( ' ', tmp );
+ for ( TQStringList::iterator i = tqparentsids.begin();
+ i != tqparentsids.end(); ++i )
{
- myobj.parents.push_back( ( *i ).toInt( &ok ) );
+ myobj.tqparents.push_back( ( *i ).toInt( &ok ) );
if ( ! ok ) KIG_FILTER_PARSE_ERROR;
}
- if ( myobj.parents.size() != myobj.numberOfParents )
+ if ( myobj.tqparents.size() != myobj.numberOfParents )
KIG_FILTER_PARSE_ERROR;
tmp = thirdlinere.cap( 4 );
@@ -277,8 +277,8 @@ bool KigFilterCabri::readObject( TQFile& f, CabriObject& myobj )
// << "specialAppearanceSwitch = " << myobj.specialAppearanceSwitch << endl
// << "visible = " << visible << endl
// << "fixed = " << myobj.fixed << endl
-// << "parents =" << endl;
-// for ( std::vector<int>::iterator i = myobj.parents.begin(); i != myobj.parents.end(); ++i )
+// << "tqparents =" << endl;
+// for ( std::vector<int>::iterator i = myobj.tqparents.begin(); i != myobj.tqparents.end(); ++i )
// kdDebug() << " " << *i << endl;
// kdDebug() << "vals = " << endl;
// for ( std::vector<double>::iterator i = myobj.data.begin(); i != myobj.data.end(); ++i )
@@ -352,8 +352,8 @@ KigDocument* KigFilterCabri::load( const TQString& file )
int ps = 0;
args.clear();
- for ( std::vector<int>::iterator i = obj.parents.begin();
- i != obj.parents.end(); ++i )
+ for ( std::vector<int>::iterator i = obj.tqparents.begin();
+ i != obj.tqparents.end(); ++i )
args.push_back( calcers[*i-3] );
// two fake objects at the start ( origin and axes.. )
@@ -441,10 +441,10 @@ KigDocument* KigFilterCabri::load( const TQString& file )
obj.thick *= 2;
if ( args.size() != 1 || obj.data.size() != 2 )
KIG_FILTER_PARSE_ERROR;
- ObjectCalcer* parent = args[0];
- if ( !parent->imp()->inherits( CurveImp::stype() ) )
+ ObjectCalcer* tqparent = args[0];
+ if ( !tqparent->imp()->inherits( CurveImp::stype() ) )
KIG_FILTER_PARSE_ERROR;
- const CurveImp* curve = static_cast<const CurveImp*>( parent->imp() );
+ const CurveImp* curve = static_cast<const CurveImp*>( tqparent->imp() );
Coordinate pt = Coordinate( obj.data[0], obj.data[1] );
double param = curve->getParam( pt, *ret );
args.push_back( new ObjectConstCalcer( new DoubleImp( param ) ) );
@@ -486,11 +486,11 @@ KigDocument* KigFilterCabri::load( const TQString& file )
// points, or a vector...
if ( args.size() != 1 || !obj.data.empty() )
KIG_FILTER_PARSE_ERROR;
- ObjectCalcer* parent = args[0];
- if ( parent->imp()->inherits( SegmentImp::stype() ) )
- oc = fact->propertyObjectCalcer( parent, "mid-point" ) ;
- else if ( parent->imp()->inherits( VectorImp::stype() ) )
- oc = fact->propertyObjectCalcer( parent, "vect-mid-point" );
+ ObjectCalcer* tqparent = args[0];
+ if ( tqparent->imp()->inherits( SegmentImp::stype() ) )
+ oc = fact->propertyObjectCalcer( tqparent, "mid-point" ) ;
+ else if ( tqparent->imp()->inherits( VectorImp::stype() ) )
+ oc = fact->propertyObjectCalcer( tqparent, "vect-mid-point" );
else KIG_FILTER_PARSE_ERROR;
}
else if ( obj.type == "PBiss" )
@@ -505,12 +505,12 @@ KigDocument* KigFilterCabri::load( const TQString& file )
}
if ( args.size() != 1 || !obj.data.empty() )
KIG_FILTER_PARSE_ERROR;
- ObjectCalcer* parent = args[0];
+ ObjectCalcer* tqparent = args[0];
ObjectCalcer* midpoint = 0;
- if ( parent->imp()->inherits( SegmentImp::stype() ) )
- midpoint = fact->propertyObjectCalcer( parent, "mid-point" ) ;
-// else if ( parent->imp()->inherits( VectorImp::stype() ) )
-// midpoint = fact->propertyObjectCalcer( parent, "vect-mid-point" );
+ if ( tqparent->imp()->inherits( SegmentImp::stype() ) )
+ midpoint = fact->propertyObjectCalcer( tqparent, "mid-point" ) ;
+// else if ( tqparent->imp()->inherits( VectorImp::stype() ) )
+// midpoint = fact->propertyObjectCalcer( tqparent, "vect-mid-point" );
else KIG_FILTER_PARSE_ERROR;
midpoint->calc( *ret );
args.push_back( midpoint );
@@ -549,7 +549,7 @@ KigDocument* KigFilterCabri::load( const TQString& file )
else
{
notSupported( file, i18n( "This Cabri file contains a \"%1\" object, "
- "which Kig does not currently support." ).arg( obj.type ) );
+ "which Kig does not currently support." ).tqarg( TQString(obj.type) ) );
return 0;
}
diff --git a/kig/filters/drgeo-filter-chooser.h b/kig/filters/drgeo-filter-chooser.h
index f5057361..1adb47c0 100644
--- a/kig/filters/drgeo-filter-chooser.h
+++ b/kig/filters/drgeo-filter-chooser.h
@@ -28,6 +28,7 @@ class KigFilterDrgeoChooser
: public KigFilterDrgeoChooserBase
{
Q_OBJECT
+ TQ_OBJECT
public:
KigFilterDrgeoChooser( const TQStringList& l );
diff --git a/kig/filters/drgeo-filter-chooserbase.ui b/kig/filters/drgeo-filter-chooserbase.ui
index 829d84cc..aa4361ee 100644
--- a/kig/filters/drgeo-filter-chooserbase.ui
+++ b/kig/filters/drgeo-filter-chooserbase.ui
@@ -1,10 +1,10 @@
<!DOCTYPE UI><UI version="3.1" stdsetdef="1">
<class>KigFilterDrgeoChooserBase</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>KigFilterDrgeoChooserBase</cstring>
</property>
- <property name="geometry">
+ <property name="tqgeometry">
<rect>
<x>0</x>
<y>0</y>
@@ -25,7 +25,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>ExplanationTextLabel</cstring>
</property>
@@ -33,11 +33,11 @@
<string>The current Dr. Geo file contains more than one figure.
Please select which to import:</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>WordBreak|AlignVCenter</set>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -72,7 +72,7 @@ Please select which to import:</string>
<enum>Horizontal</enum>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout7</cstring>
</property>
@@ -96,7 +96,7 @@ Please select which to import:</string>
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -131,7 +131,7 @@ Please select which to import:</string>
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>klistbox.h</includehint>
<includehint>kpushbutton.h</includehint>
diff --git a/kig/filters/drgeo-filter.cc b/kig/filters/drgeo-filter.cc
index 82438a57..3f213146 100644
--- a/kig/filters/drgeo-filter.cc
+++ b/kig/filters/drgeo-filter.cc
@@ -62,7 +62,7 @@
struct DrGeoHierarchyElement
{
TQString id;
- std::vector<TQString> parents;
+ std::vector<TQString> tqparents;
};
KigFilterDrgeo::KigFilterDrgeo()
@@ -106,9 +106,9 @@ KigDocument* KigFilterDrgeo::load( const TQString& file )
if ( figures.isEmpty() ) {
if( nmacros > 0 )
warning( i18n( "The Dr. Geo file \"%1\" is a macro file so it contains no "
- "figures." ).arg( file ) );
+ "figures." ).tqarg( file ) );
else
- warning( i18n( "There are no figures in Dr. Geo file \"%1\"." ).arg( file ) );
+ warning( i18n( "There are no figures in Dr. Geo file \"%1\"." ).tqarg( file ) );
return false;
}
@@ -201,8 +201,8 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
{
TQDomElement ce = c.toElement();
if ( ce.isNull() ) continue;
- else if ( ce.tagName() == "parent" )
- elem.parents.push_back( ce.attribute( "ref" ) );
+ else if ( ce.tagName() == "tqparent" )
+ elem.tqparents.push_back( ce.attribute( "ref" ) );
}
TQString curid = domelem.attribute( "id" );
elem.id = !curid.isNull() ? curid : TQString::number( withoutid++ ) ;
@@ -216,9 +216,9 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
for ( uint i = 0; i < elems.size(); ++i )
{
x = "";
- for ( uint j = 0; j < elems[i].parents.size(); ++j )
+ for ( uint j = 0; j < elems[i].tqparents.size(); ++j )
{
- x += elems[i].parents[j] + "_";
+ x += elems[i].tqparents[j] + "_";
}
kdDebug() << " --> " << i << " - " << elems[i].id << " - " << x << endl;
}
@@ -241,25 +241,25 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
kdDebug() << "+++ id: " << curid << endl;
#endif
const DrGeoHierarchyElement& el = elems[curid];
- std::vector<ObjectCalcer*> parents;
- for ( uint j = 0; j < el.parents.size(); ++j )
+ std::vector<ObjectCalcer*> tqparents;
+ for ( uint j = 0; j < el.tqparents.size(); ++j )
{
- int parentid = convertDrgeoIndex( elems, el.parents[j] );
- if ( parentid == -1 )
+ int tqparentid = convertDrgeoIndex( elems, el.tqparents[j] );
+ if ( tqparentid == -1 )
KIG_FILTER_PARSE_ERROR;
- parents.push_back( holders[parentid-nignored]->calcer() );
+ tqparents.push_back( holders[tqparentid-nignored]->calcer() );
};
TQDomElement domelem = a.toElement();
#ifdef DRGEO_DEBUG
- if ( parents.size() > 0 )
- for ( uint j = 0; j < parents.size(); ++j )
+ if ( tqparents.size() > 0 )
+ for ( uint j = 0; j < tqparents.size(); ++j )
{
- kdDebug() << "+++++++++ parent[" << j << "]: " << parents[j] << " - "
- << parents[j]->imp()->type()->internalName() << endl;
+ kdDebug() << "+++++++++ tqparent[" << j << "]: " << tqparents[j] << " - "
+ << tqparents[j]->imp()->type()->internalName() << endl;
}
else
- kdDebug() << "+++++++++ parents: NO" << endl;
+ kdDebug() << "+++++++++ tqparents: NO" << endl;
kdDebug() << "+++++++++ " << domelem.tagName() << " - " << domelem.attribute("type") << endl;
#endif
@@ -291,15 +291,15 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
oc = fact->fixedPointCalcer( Coordinate( x, y ) );
}
else if ( domelem.attribute( "type" ) == "Middle_2pts" )
- oc = new ObjectTypeCalcer( MidPointType::instance(), parents );
+ oc = new ObjectTypeCalcer( MidPointType::instance(), tqparents );
else if ( domelem.attribute( "type" ) == "Middle_segment" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- if ( !parents[0]->imp()->inherits( SegmentImp::stype() ) )
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ if ( !tqparents[0]->imp()->inherits( SegmentImp::stype() ) )
KIG_FILTER_PARSE_ERROR;
- ObjectPropertyCalcer* o1 = fact->propertyObjectCalcer( parents[0], "end-point-A" );
+ ObjectPropertyCalcer* o1 = fact->propertyObjectCalcer( tqparents[0], "end-point-A" );
o1->calc( *ret );
- ObjectPropertyCalcer* o2 = fact->propertyObjectCalcer( parents[0], "end-point-B" );
+ ObjectPropertyCalcer* o2 = fact->propertyObjectCalcer( tqparents[0], "end-point-B" );
o2->calc( *ret );
std::vector<ObjectCalcer*> args;
args.push_back( o1 );
@@ -312,37 +312,37 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
double value = values.toDouble( &ok3 );
if ( ! ok3 )
KIG_FILTER_PARSE_ERROR;
- if ( ( parents[0]->imp()->inherits( CircleImp::stype() ) ) ||
- ( parents[0]->imp()->inherits( SegmentImp::stype() ) ) )
- oc = fact->constrainedPointCalcer( parents[0], value );
- else if ( parents[0]->imp()->inherits( LineImp::stype() ) )
+ if ( ( tqparents[0]->imp()->inherits( CircleImp::stype() ) ) ||
+ ( tqparents[0]->imp()->inherits( SegmentImp::stype() ) ) )
+ oc = fact->constrainedPointCalcer( tqparents[0], value );
+ else if ( tqparents[0]->imp()->inherits( LineImp::stype() ) )
{
- const LineData l = static_cast<const LineImp*>( parents[0]->imp() )->data();
+ const LineData l = static_cast<const LineImp*>( tqparents[0]->imp() )->data();
const Coordinate p = convertDrgeoLineParam( value, l );
- oc = fact->constrainedPointCalcer( parents[0], p, *ret );
+ oc = fact->constrainedPointCalcer( tqparents[0], p, *ret );
}
- else if ( parents[0]->imp()->inherits( RayImp::stype() ) )
+ else if ( tqparents[0]->imp()->inherits( RayImp::stype() ) )
{
- const LineData l = static_cast<const RayImp*>( parents[0]->imp() )->data();
+ const LineData l = static_cast<const RayImp*>( tqparents[0]->imp() )->data();
const Coordinate p = convertDrgeoHalflineParam( value, l );
- oc = fact->constrainedPointCalcer( parents[0], p, *ret );
+ oc = fact->constrainedPointCalcer( tqparents[0], p, *ret );
}
- else if ( parents[0]->imp()->inherits( ArcImp::stype() ) )
- oc = fact->constrainedPointCalcer( parents[0], 1 - value );
+ else if ( tqparents[0]->imp()->inherits( ArcImp::stype() ) )
+ oc = fact->constrainedPointCalcer( tqparents[0], 1 - value );
else
{
-// oc = fact->constrainedPointCalcer( parents[0], value );
+// oc = fact->constrainedPointCalcer( tqparents[0], value );
notSupported( file, i18n( "This Dr. Geo file contains a \"%1 %2\" object, "
- "which Kig does not currently support." ).arg( domelem.tagName() ).arg(
+ "which Kig does not currently support." ).tqarg( domelem.tagName() ).tqarg(
domelem.attribute( "type" ) ) );
return false;
}
}
else if ( domelem.attribute( "type" ) == "Intersection" )
{
- if ( ( parents[0]->imp()->inherits( AbstractLineImp::stype() ) ) &&
- ( parents[1]->imp()->inherits( AbstractLineImp::stype() ) ) )
- oc = new ObjectTypeCalcer( LineLineIntersectionType::instance(), parents );
+ if ( ( tqparents[0]->imp()->inherits( AbstractLineImp::stype() ) ) &&
+ ( tqparents[1]->imp()->inherits( AbstractLineImp::stype() ) ) )
+ oc = new ObjectTypeCalcer( LineLineIntersectionType::instance(), tqparents );
else
{
bool ok;
@@ -351,21 +351,21 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
if ( which == 1 ) which = -1;
else if ( which == 0 ) which = 1;
else KIG_FILTER_PARSE_ERROR;
- std::vector<ObjectCalcer*> args = parents;
+ std::vector<ObjectCalcer*> args = tqparents;
const ObjectType* type = 0;
args.push_back( new ObjectConstCalcer( new IntImp( which ) ) );
- if ( ( parents[0]->imp()->inherits( CircleImp::stype() ) ) &&
- ( parents[1]->imp()->inherits( CircleImp::stype() ) ) )
+ if ( ( tqparents[0]->imp()->inherits( CircleImp::stype() ) ) &&
+ ( tqparents[1]->imp()->inherits( CircleImp::stype() ) ) )
type = CircleCircleIntersectionType::instance();
- else if ( ( parents[0]->imp()->inherits( CircleImp::stype() ) &&
- parents[1]->imp()->inherits( AbstractLineImp::stype() ) ) ||
- ( parents[1]->imp()->inherits( CircleImp::stype() ) &&
- parents[0]->imp()->inherits( AbstractLineImp::stype() ) ) )
+ else if ( ( tqparents[0]->imp()->inherits( CircleImp::stype() ) &&
+ tqparents[1]->imp()->inherits( AbstractLineImp::stype() ) ) ||
+ ( tqparents[1]->imp()->inherits( CircleImp::stype() ) &&
+ tqparents[0]->imp()->inherits( AbstractLineImp::stype() ) ) )
type = ConicLineIntersectionType::instance();
- else if ( ( parents[0]->imp()->inherits( ArcImp::stype() ) &&
- parents[1]->imp()->inherits( AbstractLineImp::stype() ) ) ||
- ( parents[1]->imp()->inherits( ArcImp::stype() ) &&
- parents[0]->imp()->inherits( AbstractLineImp::stype() ) ) )
+ else if ( ( tqparents[0]->imp()->inherits( ArcImp::stype() ) &&
+ tqparents[1]->imp()->inherits( AbstractLineImp::stype() ) ) ||
+ ( tqparents[1]->imp()->inherits( ArcImp::stype() ) &&
+ tqparents[0]->imp()->inherits( AbstractLineImp::stype() ) ) )
type = ArcLineIntersectionType::instance();
else
{
@@ -377,17 +377,17 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
}
}
else if ( domelem.attribute( "type" ) == "Reflexion" )
- oc = new ObjectTypeCalcer( LineReflectionType::instance(), parents );
+ oc = new ObjectTypeCalcer( LineReflectionType::instance(), tqparents );
else if ( domelem.attribute( "type" ) == "Symmetry" )
- oc = new ObjectTypeCalcer( PointReflectionType::instance(), parents );
+ oc = new ObjectTypeCalcer( PointReflectionType::instance(), tqparents );
else if ( domelem.attribute( "type" ) == "Translation" )
- oc = new ObjectTypeCalcer( TranslatedType::instance(), parents );
+ oc = new ObjectTypeCalcer( TranslatedType::instance(), tqparents );
else if ( domelem.attribute( "type" ) == "Rotation" )
- oc = new ObjectTypeCalcer( RotationType::instance(), parents );
+ oc = new ObjectTypeCalcer( RotationType::instance(), tqparents );
else
{
notSupported( file, i18n( "This Dr. Geo file contains a \"%1 %2\" object, "
- "which Kig does not currently support." ).arg( domelem.tagName() ).arg(
+ "which Kig does not currently support." ).tqarg( domelem.tagName() ).tqarg(
domelem.attribute( "type" ) ) );
return false;
}
@@ -419,11 +419,11 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
else
{
notSupported( file, i18n( "This Dr. Geo file contains a \"%1 %2\" object, "
- "which Kig does not currently support." ).arg( domelem.tagName() ).arg(
+ "which Kig does not currently support." ).tqarg( domelem.tagName() ).tqarg(
domelem.attribute( "type" ) ) );
return false;
}
- oc = new ObjectTypeCalcer( type, parents );
+ oc = new ObjectTypeCalcer( type, tqparents );
}
else if( domelem.attribute( "type" ) == "3pts" )
{
@@ -432,65 +432,65 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
else
{
notSupported( file, i18n( "This Dr. Geo file contains a \"%1 %2\" object, "
- "which Kig does not currently support." ).arg( domelem.tagName() ).arg(
+ "which Kig does not currently support." ).tqarg( domelem.tagName() ).tqarg(
domelem.attribute( "type" ) ) );
return false;
}
- oc = new ObjectTypeCalcer( type, parents );
+ oc = new ObjectTypeCalcer( type, tqparents );
}
else if( domelem.attribute( "type" ) == "segment" )
{
if( domelem.tagName() == "circle" )
{
type = CircleBPRType::instance();
- ObjectPropertyCalcer* o = fact->propertyObjectCalcer( parents[1], "length" );
+ ObjectPropertyCalcer* o = fact->propertyObjectCalcer( tqparents[1], "length" );
o->calc( *ret );
- ObjectCalcer* a = parents[0];
- parents.clear();
- parents.push_back( a );
- parents.push_back( o );
+ ObjectCalcer* a = tqparents[0];
+ tqparents.clear();
+ tqparents.push_back( a );
+ tqparents.push_back( o );
}
else
{
notSupported( file, i18n( "This Dr. Geo file contains a \"%1 %2\" object, "
- "which Kig does not currently support." ).arg( domelem.tagName() ).arg(
+ "which Kig does not currently support." ).tqarg( domelem.tagName() ).tqarg(
domelem.attribute( "type" ) ) );
return false;
}
- oc = new ObjectTypeCalcer( type, parents );
+ oc = new ObjectTypeCalcer( type, tqparents );
}
else if( domelem.attribute( "type" ) == "npts" )
{
if( domelem.tagName() == "polygon" )
{
- if ( parents.size() < 3 ) KIG_FILTER_PARSE_ERROR;
+ if ( tqparents.size() < 3 ) KIG_FILTER_PARSE_ERROR;
type = PolygonBNPType::instance();
}
else
{
notSupported( file, i18n( "This Dr. Geo file contains a \"%1 %2\" object, "
- "which Kig does not currently support." ).arg( domelem.tagName() ).arg(
+ "which Kig does not currently support." ).tqarg( domelem.tagName() ).tqarg(
domelem.attribute( "type" ) ) );
return false;
}
- oc = new ObjectTypeCalcer( type, parents );
+ oc = new ObjectTypeCalcer( type, tqparents );
}
else if ( domelem.attribute( "type" ) == "perpendicular" )
- oc = new ObjectTypeCalcer( LinePerpendLPType::instance(), parents );
+ oc = new ObjectTypeCalcer( LinePerpendLPType::instance(), tqparents );
else if ( domelem.attribute( "type" ) == "parallel" )
- oc = new ObjectTypeCalcer( LineParallelLPType::instance(), parents );
+ oc = new ObjectTypeCalcer( LineParallelLPType::instance(), tqparents );
else if ( domelem.attribute( "type" ) == "Reflexion" )
- oc = new ObjectTypeCalcer( LineReflectionType::instance(), parents );
+ oc = new ObjectTypeCalcer( LineReflectionType::instance(), tqparents );
else if ( domelem.attribute( "type" ) == "Symmetry" )
- oc = new ObjectTypeCalcer( PointReflectionType::instance(), parents );
+ oc = new ObjectTypeCalcer( PointReflectionType::instance(), tqparents );
else if ( domelem.attribute( "type" ) == "Translation" )
- oc = new ObjectTypeCalcer( TranslatedType::instance(), parents );
+ oc = new ObjectTypeCalcer( TranslatedType::instance(), tqparents );
else if ( domelem.attribute( "type" ) == "Rotation" )
- oc = new ObjectTypeCalcer( RotationType::instance(), parents );
+ oc = new ObjectTypeCalcer( RotationType::instance(), tqparents );
else
{
notSupported( file, i18n( "This Dr. Geo file contains a \"%1 %2\" object, "
- "which Kig does not currently support." ).arg( domelem.tagName() ).arg(
+ "which Kig does not currently support." ).tqarg( domelem.tagName() ).tqarg(
domelem.attribute( "type" ) ) );
return false;
}
@@ -529,76 +529,76 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
bool ok3;
double dvalue = value.toDouble( &ok3 );
if ( ok3 )
- value = TQString( "%1" ).arg( dvalue, 0, 'g', 3 );
+ value = TQString( "%1" ).tqarg( dvalue, 0, 'g', 3 );
oc = fact->labelCalcer( value, m, false, std::vector<ObjectCalcer*>(), *ret );
}
else if ( domelem.attribute( "type" ) == "pt_abscissa" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- oc = filtersConstructTextObject( m, parents[0], "coordinate-x", *ret, false );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ oc = filtersConstructTextObject( m, tqparents[0], "coordinate-x", *ret, false );
}
else if ( domelem.attribute( "type" ) == "pt_ordinate" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- oc = filtersConstructTextObject( m, parents[0], "coordinate-y", *ret, false );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ oc = filtersConstructTextObject( m, tqparents[0], "coordinate-y", *ret, false );
}
else if ( domelem.attribute( "type" ) == "segment_length" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- oc = filtersConstructTextObject( m, parents[0], "length", *ret, false );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ oc = filtersConstructTextObject( m, tqparents[0], "length", *ret, false );
}
else if ( domelem.attribute( "type" ) == "circle_perimeter" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- oc = filtersConstructTextObject( m, parents[0], "circumference", *ret, false );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ oc = filtersConstructTextObject( m, tqparents[0], "circumference", *ret, false );
}
else if ( domelem.attribute( "type" ) == "arc_length" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- oc = filtersConstructTextObject( m, parents[0], "arc-length", *ret, false );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ oc = filtersConstructTextObject( m, tqparents[0], "arc-length", *ret, false );
}
else if ( domelem.attribute( "type" ) == "distance_2pts" )
{
- if ( parents.size() != 2 ) KIG_FILTER_PARSE_ERROR;
- ObjectTypeCalcer* so = new ObjectTypeCalcer( SegmentABType::instance(), parents );
+ if ( tqparents.size() != 2 ) KIG_FILTER_PARSE_ERROR;
+ ObjectTypeCalcer* so = new ObjectTypeCalcer( SegmentABType::instance(), tqparents );
so->calc( *ret );
oc = filtersConstructTextObject( m, so, "length", *ret, false );
}
else if ( domelem.attribute( "type" ) == "vector_norm" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- oc = filtersConstructTextObject( m, parents[0], "length", *ret, false );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ oc = filtersConstructTextObject( m, tqparents[0], "length", *ret, false );
}
else if ( domelem.attribute( "type" ) == "vector_abscissa" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- oc = filtersConstructTextObject( m, parents[0], "length-x", *ret, false );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ oc = filtersConstructTextObject( m, tqparents[0], "length-x", *ret, false );
}
else if ( domelem.attribute( "type" ) == "vector_ordinate" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- oc = filtersConstructTextObject( m, parents[0], "length-y", *ret, false );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ oc = filtersConstructTextObject( m, tqparents[0], "length-y", *ret, false );
}
else if ( domelem.attribute( "type" ) == "slope" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- oc = filtersConstructTextObject( m, parents[0], "slope", *ret, false );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ oc = filtersConstructTextObject( m, tqparents[0], "slope", *ret, false );
}
else if ( domelem.attribute( "type" ) == "distance_pt_line" )
{
- if ( parents.size() != 2 ) KIG_FILTER_PARSE_ERROR;
+ if ( tqparents.size() != 2 ) KIG_FILTER_PARSE_ERROR;
std::vector<ObjectCalcer*> args;
- args.push_back( parents[1] );
- args.push_back( parents[0] );
+ args.push_back( tqparents[1] );
+ args.push_back( tqparents[0] );
ObjectTypeCalcer* po = new ObjectTypeCalcer( LinePerpendLPType::instance(), args );
po->calc( *ret );
args.clear();
- args.push_back( parents[1] );
+ args.push_back( tqparents[1] );
args.push_back( po );
ObjectTypeCalcer* io = new ObjectTypeCalcer( LineLineIntersectionType::instance(), args );
io->calc( *ret );
args.clear();
- args.push_back( parents[0] );
+ args.push_back( tqparents[0] );
args.push_back( io );
ObjectTypeCalcer* so = new ObjectTypeCalcer( SegmentABType::instance(), args );
so->calc( *ret );
@@ -607,18 +607,18 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
// types of 'equation'
else if ( domelem.attribute( "type" ) == "line" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- oc = filtersConstructTextObject( m, parents[0], "equation", *ret, false );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ oc = filtersConstructTextObject( m, tqparents[0], "equation", *ret, false );
}
else if ( domelem.attribute( "type" ) == "circle" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- oc = filtersConstructTextObject( m, parents[0], "simply-cartesian-equation", *ret, false );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ oc = filtersConstructTextObject( m, tqparents[0], "simply-cartesian-equation", *ret, false );
}
else
{
notSupported( file, i18n( "This Dr. Geo file contains a \"%1 %2\" object, "
- "which Kig does not currently support." ).arg( domelem.tagName() ).arg(
+ "which Kig does not currently support." ).tqarg( domelem.tagName() ).tqarg(
domelem.attribute( "type" ) ) );
return false;
}
@@ -630,13 +630,13 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
{
if ( domelem.attribute( "type" ) == "3pts" )
{
- if ( parents.size() != 3 ) KIG_FILTER_PARSE_ERROR;
- oc = new ObjectTypeCalcer( HalfAngleType::instance(), parents );
+ if ( tqparents.size() != 3 ) KIG_FILTER_PARSE_ERROR;
+ oc = new ObjectTypeCalcer( HalfAngleType::instance(), tqparents );
}
else
{
notSupported( file, i18n( "This Dr. Geo file contains a \"%1 %2\" object, "
- "which Kig does not currently support." ).arg( domelem.tagName() ).arg(
+ "which Kig does not currently support." ).tqarg( domelem.tagName() ).tqarg(
domelem.attribute( "type" ) ) );
return false;
}
@@ -669,7 +669,7 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
// since Kig doesn't support Guile scripts, it will write script's text
// in a label, so the user can freely see the code and make whatever
// he/she wants
- // possible idea: construct a new script object with the parents of Guile
+ // possible idea: construct a new script object with the tqparents of Guile
// one and the Guile code inserted commented... depends on a better
// handling of arguments in scripts?
if ( domelem.attribute( "type" ) == "nitems" )
@@ -677,7 +677,7 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
else
{
notSupported( file, i18n( "This Dr. Geo file contains a \"%1 %2\" object, "
- "which Kig does not currently support." ).arg( domelem.tagName() ).arg(
+ "which Kig does not currently support." ).tqarg( domelem.tagName() ).tqarg(
domelem.attribute( "type" ) ) );
return false;
}
@@ -685,11 +685,11 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
else if ( domelem.tagName() == "locus" )
{
if ( domelem.attribute( "type" ) == "None" )
- oc = fact->locusCalcer( parents[0], parents[1] );
+ oc = fact->locusCalcer( tqparents[0], tqparents[1] );
else
{
notSupported( file, i18n( "This Dr. Geo file contains a \"%1 %2\" object, "
- "which Kig does not currently support." ).arg( domelem.tagName() ).arg(
+ "which Kig does not currently support." ).tqarg( domelem.tagName() ).tqarg(
domelem.attribute( "type" ) ) );
return false;
}
@@ -709,7 +709,7 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
kdDebug() << ">>>>>>>>> UNKNOWN OBJECT" << endl;
#endif
notSupported( file, i18n( "This Dr. Geo file contains a \"%1 %2\" object, "
- "which Kig does not currently support." ).arg( domelem.tagName() ).arg(
+ "which Kig does not currently support." ).tqarg( domelem.tagName() ).tqarg(
domelem.attribute( "type" ) ) );
return false;
}
@@ -723,7 +723,7 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
if ( domelem.attribute( "color" ) == "Bordeaux" )
co.setRgb( 145, 0, 0 );
else
- co = Qt::blue;
+ co = TQt::blue;
// reading width and style
// Dashed -> the little one
// Normal -> the medium
@@ -747,8 +747,8 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
TQString ps = domelem.attribute( "style" );
int pointstyle = ObjectDrawer::pointStyleFromString( ps );
// show this object?
- bool show = ( ( domelem.attribute( "masked" ) != "True" ) &&
- ( domelem.attribute( "masked" ) != "Alway" ) );
+ bool show = ( ( domelem.attribute( "tqmasked" ) != "True" ) &&
+ ( domelem.attribute( "tqmasked" ) != "Alway" ) );
// costructing the ObjectDrawer*
ObjectDrawer* d = new ObjectDrawer( co, w, show, s, pointstyle );
// reading object name
@@ -770,16 +770,16 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
{
std::vector<ObjectCalcer*> args2;
args2.push_back( o->nameCalcer() );
- oc2 = fact->attachedLabelCalcer( TQString::fromLatin1( "%1" ), oc,
+ oc2 = fact->attachedLabelCalcer( TQString::tqfromLatin1( "%1" ), oc,
static_cast<const PointImp*>( oc->imp() )->coordinate(),
false, args2, *ret );
- co = Qt::black;
+ co = TQt::black;
}
}
else if ( domelem.tagName() == "angle" )
{
oc2 = filtersConstructTextObject(
- static_cast<const PointImp*>( holders[curid-1-nignored]->calcer()->parents()[1]->imp() )->coordinate(),
+ static_cast<const PointImp*>( holders[curid-1-nignored]->calcer()->tqparents()[1]->imp() )->coordinate(),
holders[curid-1-nignored]->calcer(), "angle-degrees", *ret, false );
}
diff --git a/kig/filters/drgeo-filter.h b/kig/filters/drgeo-filter.h
index 9b0ef369..ddd2359e 100644
--- a/kig/filters/drgeo-filter.h
+++ b/kig/filters/drgeo-filter.h
@@ -26,7 +26,7 @@ class KigDocument;
class TQString;
/**
- * This is an import filter for the GNOME geometry program DrGeo.
+ * This is an import filter for the GNOME tqgeometry program DrGeo.
*/
class KigFilterDrgeo
: public KigFilter
diff --git a/kig/filters/exporter.cc b/kig/filters/exporter.cc
index b44888f0..f2847c0a 100644
--- a/kig/filters/exporter.cc
+++ b/kig/filters/exporter.cc
@@ -65,13 +65,13 @@ class ExporterAction
KigWidget* mw;
public:
ExporterAction( const KigPart* doc, KigWidget* w,
- KActionCollection* parent, KigExporter* exp );
+ KActionCollection* tqparent, KigExporter* exp );
void slotActivated();
};
ExporterAction::ExporterAction( const KigPart* doc, KigWidget* w,
- KActionCollection* parent, KigExporter* exp )
- : KAction( exp->menuEntryName(), KShortcut(), 0, 0, parent ),
+ KActionCollection* tqparent, KigExporter* exp )
+ : KAction( exp->menuEntryName(), KShortcut(), 0, 0, tqparent ),
mexp( exp ), mdoc( doc ), mw( w )
{
TQString iconstr = exp->menuIcon();
@@ -121,7 +121,7 @@ void ImageExporter::run( const KigPart& doc, KigWidget& w )
}
KigFileDialog* kfd = new KigFileDialog(
- TQString::null, KImageIO::pattern( KImageIO::Writing ),
+ TQString(), KImageIO::pattern( KImageIO::Writing ),
i18n( "Export as Image" ), &w );
kfd->setOptionCaption( i18n( "Image Options" ) );
ImageExporterOptions* opts = new ImageExporterOptions( 0L, w.size() );
@@ -156,20 +156,20 @@ void ImageExporter::run( const KigPart& doc, KigWidget& w )
{
KMessageBox::sorry( &w,
i18n( "The file \"%1\" could not be opened. Please check if the file permissions are set correctly." )
- .arg( filename ) );
+ .tqarg( filename ) );
return;
};
TQPixmap img( TQSize( width, height ) );
- img.fill( Qt::white );
- KigPainter p( ScreenInfo( w.screenInfo().shownRect(), img.rect() ), &img, doc.document() );
+ img.fill( TQt::white );
+ KigPainter p( ScreenInfo( w.screenInfo().shownRect(), img.rect() ), TQT_TQPAINTDEVICE(&img), doc.document() );
p.setWholeWinOverlay();
p.drawGrid( doc.document().coordinateSystem(), showgrid, showaxes );
// FIXME: show the selections ?
p.drawObjects( doc.document().objects(), false );
if ( ! img.save( filename, type.latin1() ) )
{
- KMessageBox::error( &w, i18n( "Sorry, something went wrong while saving to image \"%1\"" ).arg( filename ) );
+ KMessageBox::error( &w, i18n( "Sorry, something went wrong while saving to image \"%1\"" ).tqarg( filename ) );
}
}
@@ -244,7 +244,7 @@ class XFigExportImpVisitor
// << "c: " << c << endl;
ret *= 9450;
ret /= msr.width();
- return ret.toQPoint();
+ return ret.toTQPoint();
}
void emitLine( const Coordinate& a, const Coordinate& b, int width, bool vector = false );
@@ -257,14 +257,14 @@ public:
mnextcolorid( 32 )
{
// predefined colors in XFig..
- mcolormap[Qt::black] = 0;
- mcolormap[Qt::blue] = 1;
- mcolormap[Qt::green] = 2;
- mcolormap[Qt::cyan] = 3;
- mcolormap[Qt::red] = 4;
- mcolormap[Qt::magenta] = 5;
- mcolormap[Qt::yellow] = 6;
- mcolormap[Qt::white] = 7;
+ mcolormap[TQt::black] = 0;
+ mcolormap[TQt::blue] = 1;
+ mcolormap[TQt::green] = 2;
+ mcolormap[TQt::cyan] = 3;
+ mcolormap[TQt::red] = 4;
+ mcolormap[TQt::magenta] = 5;
+ mcolormap[TQt::yellow] = 6;
+ mcolormap[TQt::white] = 7;
}
void visit( const LineImp* imp );
void visit( const PointImp* imp );
@@ -297,7 +297,7 @@ void XFigExportImpVisitor::mapColor( const ObjectDrawer* obj )
void XFigExportImpVisitor::visit( ObjectHolder* obj )
{
if ( ! obj->drawer()->shown() ) return;
- assert( mcolormap.find( obj->drawer()->color() ) != mcolormap.end() );
+ assert( mcolormap.tqfind( obj->drawer()->color() ) != mcolormap.end() );
mcurcolorid = mcolormap[ obj->drawer()->color() ];
mcurobj = obj;
obj->imp()->visit( this );
@@ -593,7 +593,7 @@ void XFigExporter::run( const KigPart& doc, KigWidget& w )
{
KMessageBox::sorry( &w, i18n( "The file \"%1\" could not be opened. Please "
"check if the file permissions are set correctly." )
- .arg( file_name ) );
+ .tqarg( file_name ) );
return;
};
TQTextStream stream( &file );
diff --git a/kig/filters/filter.cc b/kig/filters/filter.cc
index 81cd1ef4..0cfe1479 100644
--- a/kig/filters/filter.cc
+++ b/kig/filters/filter.cc
@@ -31,7 +31,7 @@
KigFilters* KigFilters::sThis;
-KigFilter* KigFilters::find(const TQString& mime)
+KigFilter* KigFilters::tqfind(const TQString& mime)
{
for (vect::iterator i = mFilters.begin(); i != mFilters.end(); ++i)
{
@@ -73,14 +73,14 @@ void KigFilter::fileNotFound( const TQString& file ) const
i18n( "The file \"%1\" could not be opened. "
"This probably means that it does not "
"exist, or that it cannot be opened due to "
- "its permissions" ).arg( file ) );
+ "its permissions" ).tqarg( file ) );
}
void KigFilter::parseError( const TQString& file, const TQString& explanation ) const
{
const TQString text =
i18n( "An error was encountered while parsing the file \"%1\". It "
- "cannot be opened." ).arg( file );
+ "cannot be opened." ).tqarg( file );
const TQString title = i18n( "Parse Error" );
if ( explanation.isNull() )
@@ -92,7 +92,7 @@ void KigFilter::parseError( const TQString& file, const TQString& explanation )
void KigFilter::notSupported( const TQString& file, const TQString& explanation ) const
{
KMessageBox::detailedSorry( 0,
- i18n( "Kig cannot open the file \"%1\"." ).arg( file ),
+ i18n( "Kig cannot open the file \"%1\"." ).tqarg( file ),
explanation, i18n( "Not Supported" ) );
}
diff --git a/kig/filters/filter.h b/kig/filters/filter.h
index c887b05c..af087818 100644
--- a/kig/filters/filter.h
+++ b/kig/filters/filter.h
@@ -34,7 +34,7 @@ class KigFilters
{
public:
static KigFilters* instance();
- KigFilter* find (const TQString& mime);
+ KigFilter* tqfind (const TQString& mime);
// bool save ( const KigDocument& data, TQTextStream& stream );
/**
@@ -55,7 +55,7 @@ protected:
{ \
TQString locs = i18n( "An error was encountered at " \
"line %1 in file %2." ) \
- .arg( __LINE__ ).arg( __FILE__ ); \
+ .tqarg( __LINE__ ).tqarg( __FILE__ ); \
parseError( file, locs ); \
return 0; \
}
@@ -71,7 +71,7 @@ class KigFilter
protected:
// shows errors to the user..
void fileNotFound( const TQString& file ) const;
- void parseError( const TQString& file, const TQString& explanation = TQString::null ) const;
+ void parseError( const TQString& file, const TQString& explanation = TQString() ) const;
void notSupported( const TQString& file, const TQString& explanation ) const;
void warning( const TQString& explanation ) const;
public:
diff --git a/kig/filters/filters-common.cc b/kig/filters/filters-common.cc
index 4ba24e9f..6ae6cef9 100644
--- a/kig/filters/filters-common.cc
+++ b/kig/filters/filters-common.cc
@@ -34,6 +34,6 @@ ObjectTypeCalcer* filtersConstructTextObject(
propo->calc( doc );
std::vector<ObjectCalcer*> args;
args.push_back( propo );
- return fact->labelCalcer( TQString::fromLatin1( "%1" ), c, needframe,
+ return fact->labelCalcer( TQString::tqfromLatin1( "%1" ), c, needframe,
args, doc );
}
diff --git a/kig/filters/imageexporteroptions.cc b/kig/filters/imageexporteroptions.cc
index cd68a0af..d88792fc 100644
--- a/kig/filters/imageexporteroptions.cc
+++ b/kig/filters/imageexporteroptions.cc
@@ -23,8 +23,8 @@
#include <knuminput.h>
-ImageExporterOptions::ImageExporterOptions( TQWidget* parent, const TQSize& s )
- : ImageExporterOptionsBase( parent, "imageexporteroptions" ), msize( s ),
+ImageExporterOptions::ImageExporterOptions( TQWidget* tqparent, const TQSize& s )
+ : ImageExporterOptionsBase( tqparent, "imageexporteroptions" ), msize( s ),
minternallysettingstuff( false )
{
keepAspectRatio->setChecked( true );
diff --git a/kig/filters/imageexporteroptions.h b/kig/filters/imageexporteroptions.h
index eacbe859..82db4950 100644
--- a/kig/filters/imageexporteroptions.h
+++ b/kig/filters/imageexporteroptions.h
@@ -26,6 +26,7 @@ class ImageExporterOptions
: public ImageExporterOptionsBase
{
Q_OBJECT
+ TQ_OBJECT
TQSize msize;
@@ -34,7 +35,7 @@ class ImageExporterOptions
// value like to user changes...
bool minternallysettingstuff;
public:
- ImageExporterOptions( TQWidget* parent, const TQSize& s );
+ ImageExporterOptions( TQWidget* tqparent, const TQSize& s );
~ImageExporterOptions();
protected slots:
diff --git a/kig/filters/imageexporteroptionsbase.ui b/kig/filters/imageexporteroptionsbase.ui
index 03145dec..6399fd7e 100644
--- a/kig/filters/imageexporteroptionsbase.ui
+++ b/kig/filters/imageexporteroptionsbase.ui
@@ -1,10 +1,10 @@
<!DOCTYPE UI><UI version="3.1" stdsetdef="1">
<class>ImageExporterOptionsBase</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>ImageExporterOptionsBase</cstring>
</property>
- <property name="geometry">
+ <property name="tqgeometry">
<rect>
<x>0</x>
<y>0</y>
@@ -22,7 +22,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox1</cstring>
</property>
@@ -33,7 +33,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout2_2</cstring>
</property>
@@ -47,7 +47,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>WidthLabel_2</cstring>
</property>
@@ -68,7 +68,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout3_2</cstring>
</property>
@@ -82,7 +82,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>HeightLabel_2</cstring>
</property>
@@ -103,7 +103,7 @@
</widget>
</hbox>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>keepAspectRatio</cstring>
</property>
@@ -113,7 +113,7 @@
</widget>
</vbox>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox2</cstring>
</property>
@@ -124,7 +124,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QCheckBox" row="0" column="0">
+ <widget class="TQCheckBox" row="0" column="0">
<property name="name">
<cstring>showGridCheckBox</cstring>
</property>
@@ -132,7 +132,7 @@
<string>Show grid</string>
</property>
</widget>
- <widget class="QCheckBox" row="0" column="1">
+ <widget class="TQCheckBox" row="0" column="1">
<property name="name">
<cstring>showAxesCheckBox</cstring>
</property>
@@ -144,7 +144,7 @@
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>knuminput.h</includehint>
<includehint>knuminput.h</includehint>
diff --git a/kig/filters/kgeo-filter.cc b/kig/filters/kgeo-filter.cc
index 02c1efde..379af11d 100644
--- a/kig/filters/kgeo-filter.cc
+++ b/kig/filters/kgeo-filter.cc
@@ -74,7 +74,7 @@ void KigFilterKGeo::loadMetrics(KSimpleConfig* c )
struct KGeoHierarchyElement
{
int id;
- std::vector<int> parents;
+ std::vector<int> tqparents;
};
static void visitElem( std::vector<KGeoHierarchyElement>& ret,
@@ -84,8 +84,8 @@ static void visitElem( std::vector<KGeoHierarchyElement>& ret,
{
if ( !seen[i] )
{
- for ( uint j = 0; j < elems[i].parents.size(); ++j )
- visitElem( ret, elems, seen, elems[i].parents[j] );
+ for ( uint j = 0; j < elems[i].tqparents.size(); ++j )
+ visitElem( ret, elems, seen, elems[i].tqparents[j] );
ret.push_back( elems[i] );
seen[i] = true;
};
@@ -111,10 +111,10 @@ KigDocument* KigFilterKGeo::loadObjects( const TQString& file, KSimpleConfig* c
c->setGroup("Main");
int number = c->readNumEntry ("Number");
- // first we determine the parent relationships, and sort the
+ // first we determine the tqparent relationships, and sort the
// elements in an order that we can be sure all of an object's
- // parents will have been handled before it is handled itself..
- // ( aka topological sort of the parent relations graph..
+ // tqparents will have been handled before it is handled itself..
+ // ( aka topological sort of the tqparent relations graph..
std::vector<KGeoHierarchyElement> elems;
elems.reserve( number );
@@ -125,15 +125,15 @@ KigDocument* KigFilterKGeo::loadObjects( const TQString& file, KSimpleConfig* c
group.setNum( i + 1 );
group.prepend( "Object " );
c->setGroup( group );
- TQStrList parents;
- c->readListEntry( "Parents", parents );
+ TQStrList tqparents;
+ c->readListEntry( "Parents", tqparents );
elems.push_back( elem );
- for ( const char* parent = parents.first(); parent; parent = parents.next() )
+ for ( const char* tqparent = tqparents.first(); tqparent; tqparent = tqparents.next() )
{
- int parentIndex = TQString::fromLatin1( parent ).toInt( &ok );
+ int tqparentIndex = TQString::tqfromLatin1( tqparent ).toInt( &ok );
if ( ! ok ) KIG_FILTER_PARSE_ERROR;
- if ( parentIndex != 0 )
- elems[i].parents.push_back( parentIndex - 1 );
+ if ( tqparentIndex != 0 )
+ elems[i].tqparents.push_back( tqparentIndex - 1 );
};
};
@@ -153,11 +153,11 @@ KigDocument* KigFilterKGeo::loadObjects( const TQString& file, KSimpleConfig* c
c->setGroup( group );
int objID = c->readNumEntry( "Geo" );
- std::vector<ObjectCalcer*> parents;
- for ( uint j = 0; j < e.parents.size(); ++j )
+ std::vector<ObjectCalcer*> tqparents;
+ for ( uint j = 0; j < e.tqparents.size(); ++j )
{
- int parentid = e.parents[j];
- parents.push_back( os[parentid]->calcer() );
+ int tqparentid = e.tqparents[j];
+ tqparents.push_back( os[tqparentid]->calcer() );
};
ObjectCalcer* o = 0;
@@ -166,84 +166,84 @@ KigDocument* KigFilterKGeo::loadObjects( const TQString& file, KSimpleConfig* c
case ID_point:
{
// fetch the coordinates...
- TQString strX = c->readEntry("QPointX");
- TQString strY = c->readEntry("QPointY");
+ TQString strX = c->readEntry("TQPointX");
+ TQString strY = c->readEntry("TQPointY");
double x = strX.toDouble(&ok);
if (!ok) KIG_FILTER_PARSE_ERROR;
double y = strY.toDouble(&ok);
if (!ok) KIG_FILTER_PARSE_ERROR;
Coordinate m( x, y );
- uint nparents = parents.size();
- if ( nparents == 0 )
+ uint ntqparents = tqparents.size();
+ if ( ntqparents == 0 )
o = factory->fixedPointCalcer( m );
- else if ( nparents == 1 )
- o = factory->constrainedPointCalcer( parents[0], m, *ret );
+ else if ( ntqparents == 1 )
+ o = factory->constrainedPointCalcer( tqparents[0], m, *ret );
else
KIG_FILTER_PARSE_ERROR;
break;
}
case ID_segment:
{
- o = new ObjectTypeCalcer( SegmentABType::instance(), parents );
+ o = new ObjectTypeCalcer( SegmentABType::instance(), tqparents );
break;
}
case ID_circle:
{
- o = new ObjectTypeCalcer( CircleBCPType::instance(), parents );
+ o = new ObjectTypeCalcer( CircleBCPType::instance(), tqparents );
break;
}
case ID_line:
{
- o = new ObjectTypeCalcer( LineABType::instance(), parents );
+ o = new ObjectTypeCalcer( LineABType::instance(), tqparents );
break;
}
case ID_bisection:
{
// if this is the bisection of two points, first build a segment
// between them..
- if ( parents.size() == 2 )
+ if ( tqparents.size() == 2 )
{
- ObjectTypeCalcer* seg = new ObjectTypeCalcer( SegmentABType::instance(), parents );
- parents.clear();
- parents.push_back( seg );
+ ObjectTypeCalcer* seg = new ObjectTypeCalcer( SegmentABType::instance(), tqparents );
+ tqparents.clear();
+ tqparents.push_back( seg );
}
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- o = factory->propertyObjectCalcer( parents[0], "mid-point" );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ o = factory->propertyObjectCalcer( tqparents[0], "mid-point" );
break;
};
case ID_perpendicular:
{
- o = new ObjectTypeCalcer( LinePerpendLPType::instance(), parents );
+ o = new ObjectTypeCalcer( LinePerpendLPType::instance(), tqparents );
break;
}
case ID_parallel:
{
- o = new ObjectTypeCalcer( LineParallelLPType::instance(), parents );
+ o = new ObjectTypeCalcer( LineParallelLPType::instance(), tqparents );
break;
}
case ID_vector:
{
- o = new ObjectTypeCalcer( VectorType::instance(), parents );
+ o = new ObjectTypeCalcer( VectorType::instance(), tqparents );
break;
}
case ID_ray:
{
- o = new ObjectTypeCalcer( RayABType::instance(), parents );
+ o = new ObjectTypeCalcer( RayABType::instance(), tqparents );
break;
}
case ID_move:
{
- o = new ObjectTypeCalcer( TranslatedType::instance(), parents );
+ o = new ObjectTypeCalcer( TranslatedType::instance(), tqparents );
break;
}
case ID_mirrorPoint:
{
- o = new ObjectTypeCalcer( PointReflectionType::instance(), parents );
+ o = new ObjectTypeCalcer( PointReflectionType::instance(), tqparents );
break;
}
case ID_pointOfConc:
{
- o = new ObjectTypeCalcer( LineLineIntersectionType::instance(), parents );
+ o = new ObjectTypeCalcer( LineLineIntersectionType::instance(), tqparents );
break;
}
case ID_text:
@@ -264,79 +264,79 @@ KigDocument* KigFilterKGeo::loadObjects( const TQString& file, KSimpleConfig* c
case ID_fixedCircle:
{
double r = c->readDoubleNumEntry( "Radius" );
- parents.push_back( new ObjectConstCalcer( new DoubleImp( r ) ) );
- o = new ObjectTypeCalcer( CircleBPRType::instance(), parents );
+ tqparents.push_back( new ObjectConstCalcer( new DoubleImp( r ) ) );
+ o = new ObjectTypeCalcer( CircleBPRType::instance(), tqparents );
break;
}
case ID_angle:
{
- if ( parents.size() == 3 )
+ if ( tqparents.size() == 3 )
{
- ObjectTypeCalcer* ao = new ObjectTypeCalcer( AngleType::instance(), parents );
+ ObjectTypeCalcer* ao = new ObjectTypeCalcer( AngleType::instance(), tqparents );
ao->calc( *ret );
- parents.clear();
- parents.push_back( ao );
+ tqparents.clear();
+ tqparents.push_back( ao );
};
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- ObjectCalcer* angle = parents[0];
- parents.clear();
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ ObjectCalcer* angle = tqparents[0];
+ tqparents.clear();
const Coordinate c =
- static_cast<const PointImp*>( angle->parents()[1]->imp() )->coordinate();
+ static_cast<const PointImp*>( angle->tqparents()[1]->imp() )->coordinate();
o = filtersConstructTextObject( c, angle, "angle-degrees", *ret, true );
break;
}
case ID_distance:
{
- if ( parents.size() != 2 ) KIG_FILTER_PARSE_ERROR;
- ObjectTypeCalcer* segment = new ObjectTypeCalcer( SegmentABType::instance(), parents );
+ if ( tqparents.size() != 2 ) KIG_FILTER_PARSE_ERROR;
+ ObjectTypeCalcer* segment = new ObjectTypeCalcer( SegmentABType::instance(), tqparents );
segment->calc( *ret );
- Coordinate m = ( static_cast<const PointImp*>( parents[0]->imp() )->coordinate() +
- static_cast<const PointImp*>( parents[1]->imp() )->coordinate() ) / 2;
+ Coordinate m = ( static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate() +
+ static_cast<const PointImp*>( tqparents[1]->imp() )->coordinate() ) / 2;
o = filtersConstructTextObject( m, segment, "length", *ret, true );
break;
}
case ID_arc:
{
- o = new ObjectTypeCalcer( AngleType::instance(), parents );
+ o = new ObjectTypeCalcer( AngleType::instance(), tqparents );
break;
}
case ID_area:
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- const CircleImp* circle = static_cast<const CircleImp*>( parents[0]->imp() );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ const CircleImp* circle = static_cast<const CircleImp*>( tqparents[0]->imp() );
const Coordinate c = circle->center() + Coordinate( circle->radius(), 0 );
- o = filtersConstructTextObject( c, parents[0], "surface", *ret, true );
+ o = filtersConstructTextObject( c, tqparents[0], "surface", *ret, true );
break;
}
case ID_slope:
{
- // if parents contains a segment, line, vector or whatever, we
- // take its parents cause we want points..
- if ( parents.size() == 1 ) parents = parents[0]->parents();
- if ( parents.size() != 2 ) KIG_FILTER_PARSE_ERROR;
+ // if tqparents contains a segment, line, vector or whatever, we
+ // take its tqparents cause we want points..
+ if ( tqparents.size() == 1 ) tqparents = tqparents[0]->tqparents();
+ if ( tqparents.size() != 2 ) KIG_FILTER_PARSE_ERROR;
const Coordinate c = (
- static_cast<const PointImp*>( parents[0]->imp() )->coordinate() +
- static_cast<const PointImp*>( parents[1]->imp() )->coordinate() ) / 2;
- ObjectTypeCalcer* line = new ObjectTypeCalcer( LineABType::instance(), parents );
+ static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate() +
+ static_cast<const PointImp*>( tqparents[1]->imp() )->coordinate() ) / 2;
+ ObjectTypeCalcer* line = new ObjectTypeCalcer( LineABType::instance(), tqparents );
line->calc( *ret );
o = filtersConstructTextObject( c, line, "slope", *ret, true );
break;
}
case ID_circumference:
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- const CircleImp* c = static_cast<const CircleImp*>( parents[0]->imp() );
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ const CircleImp* c = static_cast<const CircleImp*>( tqparents[0]->imp() );
const Coordinate m = c->center() + Coordinate( c->radius(), 0 );
- o = filtersConstructTextObject( m, parents[0], "circumference", *ret, true );
+ o = filtersConstructTextObject( m, tqparents[0], "circumference", *ret, true );
break;
}
case ID_rotation:
{
// in kig, the rotated object should be last..
- ObjectCalcer* t = parents[2];
- parents[2] = parents[0];
- parents[0] = t;
- o = new ObjectTypeCalcer( RotationType::instance(), parents );
+ ObjectCalcer* t = tqparents[2];
+ tqparents[2] = tqparents[0];
+ tqparents[0] = t;
+ o = new ObjectTypeCalcer( RotationType::instance(), tqparents );
break;
}
default:
@@ -346,7 +346,7 @@ KigDocument* KigFilterKGeo::loadObjects( const TQString& file, KSimpleConfig* c
// set the color...
TQColor co = c->readColorEntry( "Color" );
if( !co.isValid() )
- co = Qt::blue;
+ co = TQt::blue;
ObjectDrawer* d = new ObjectDrawer( co );
os[i] = new ObjectHolder( o, d );
diff --git a/kig/filters/kgeo-filter.h b/kig/filters/kgeo-filter.h
index f8accd91..0eb8d462 100644
--- a/kig/filters/kgeo-filter.h
+++ b/kig/filters/kgeo-filter.h
@@ -25,11 +25,11 @@ class KSimpleConfig;
/**
* This is an import filter for files generated by the program KGeo,
- * which was an interactive geometry program in kdeedu. Kig is
+ * which was an interactive tqgeometry program in kdeedu. Kig is
* supposed to be its successor, and this import filter is part of my
* attempt to achieve that :)
*
- * Status: a significant part of KGeo's format is supported, not all
+ * tqStatus: a significant part of KGeo's format is supported, not all
* yet, though..
*/
class KigFilterKGeo
diff --git a/kig/filters/kgeo-resource.h b/kig/filters/kgeo-resource.h
index f7af0f64..9a392ac8 100644
--- a/kig/filters/kgeo-resource.h
+++ b/kig/filters/kgeo-resource.h
@@ -71,7 +71,7 @@
#define ID_FILE_PRINT 10080
-#define ID_FILE_QUIT 10090
+#define ID_FILE_TQUIT 10090
///////////////////////////////////////////////////////////////////
// Edit-menu entries
diff --git a/kig/filters/kseg-defs.h b/kig/filters/kseg-defs.h
index 59dd3e4c..5319afaf 100644
--- a/kig/filters/kseg-defs.h
+++ b/kig/filters/kseg-defs.h
@@ -58,10 +58,10 @@ using namespace std;
inline int ROUND(double x) { return ((int)(x + 0.5)); }
inline int SIGN(double x) { return (x < 0) ? -1 : 1; }
-inline int INTRAND(int a, int b) { return QMIN(a, b) + rand() % abs(a - b); }
+inline int INTRAND(int a, int b) { return TQMIN(a, b) + rand() % abs(a - b); }
#define SQR(x) ((x) * (x))
#define CUBE(x) ((x) * (x) * (x))
-#define QUAD(x) (((x) * (x)) * ((x) * (x)))
+#define TQUAD(x) (((x) * (x)) * ((x) * (x)))
enum G_Type
{
@@ -254,9 +254,9 @@ enum MenuIDs
ID_CONSTRUCTION_MAKE_INITIAL,
ID_CONSTRUCTION_RECURSE,
- ID_PLAY_QUICKPLAY,
+ ID_PLAY_TQUICKPLAY,
- ID_QUICKPLAY_SET_DIRECTORY,
+ ID_TQUICKPLAY_SET_DIRECTORY,
ID_FILE_RECENTLIST_START //should be the last entry
};
diff --git a/kig/filters/kseg-filter.cc b/kig/filters/kseg-filter.cc
index fb96c25c..6f784759 100644
--- a/kig/filters/kseg-filter.cc
+++ b/kig/filters/kseg-filter.cc
@@ -67,7 +67,7 @@ bool KigFilterKSeg::supportMime( const TQString& mime )
struct drawstyle
{
- Q_INT8 pointstyle;
+ TQ_INT8 pointstyle;
TQFont font;
TQPen pen;
TQBrush brush;
@@ -93,50 +93,50 @@ static Coordinate readKSegCoordinate( TQDataStream& stream )
return t + Coordinate( -7, -7 );
}
-static ObjectTypeCalcer* intersectionPoint( const std::vector<ObjectCalcer*>& parents, int which )
+static ObjectTypeCalcer* intersectionPoint( const std::vector<ObjectCalcer*>& tqparents, int which )
{
- if ( parents.size() != 2 ) return 0;
+ if ( tqparents.size() != 2 ) return 0;
int nlines = 0;
int nconics = 0;
int narcs = 0;
for ( int i = 0; i < 2; ++i )
{
- if ( parents[i]->imp()->inherits( AbstractLineImp::stype() ) ) ++nlines;
- else if ( parents[i]->imp()->inherits( ConicImp::stype() ) ) ++nconics;
- else if ( parents[i]->imp()->inherits( ArcImp::stype() ) ) ++narcs;
+ if ( tqparents[i]->imp()->inherits( AbstractLineImp::stype() ) ) ++nlines;
+ else if ( tqparents[i]->imp()->inherits( ConicImp::stype() ) ) ++nconics;
+ else if ( tqparents[i]->imp()->inherits( ArcImp::stype() ) ) ++narcs;
else return 0;
};
if ( nlines == 2 )
- return which == -1 ? new ObjectTypeCalcer( LineLineIntersectionType::instance(), parents ) : 0;
+ return which == -1 ? new ObjectTypeCalcer( LineLineIntersectionType::instance(), tqparents ) : 0;
else if ( nlines == 1 && nconics == 1 )
{
- std::vector<ObjectCalcer*> intparents( parents );
- intparents.push_back( new ObjectConstCalcer( new IntImp( which ) ) );
- return new ObjectTypeCalcer( ConicLineIntersectionType::instance(), intparents );
+ std::vector<ObjectCalcer*> inttqparents( tqparents );
+ inttqparents.push_back( new ObjectConstCalcer( new IntImp( which ) ) );
+ return new ObjectTypeCalcer( ConicLineIntersectionType::instance(), inttqparents );
}
else if ( nlines == 0 && nconics == 2 )
{
- std::vector<ObjectCalcer*> rparents( parents );
- rparents.push_back( new ObjectConstCalcer( new IntImp( 1 ) ) );
- rparents.push_back( new ObjectConstCalcer( new IntImp( 1 ) ) );
- rparents.push_back( new ObjectTypeCalcer( ConicRadicalType::instance(), rparents ) );
- std::vector<ObjectCalcer*> iparents;
- iparents.push_back( parents[0] );
- iparents.push_back( rparents.back() );
- iparents.push_back( new ObjectConstCalcer( new IntImp( which ) ) );
- return new ObjectTypeCalcer( ConicLineIntersectionType::instance(), iparents );
+ std::vector<ObjectCalcer*> rtqparents( tqparents );
+ rtqparents.push_back( new ObjectConstCalcer( new IntImp( 1 ) ) );
+ rtqparents.push_back( new ObjectConstCalcer( new IntImp( 1 ) ) );
+ rtqparents.push_back( new ObjectTypeCalcer( ConicRadicalType::instance(), rtqparents ) );
+ std::vector<ObjectCalcer*> itqparents;
+ itqparents.push_back( tqparents[0] );
+ itqparents.push_back( rtqparents.back() );
+ itqparents.push_back( new ObjectConstCalcer( new IntImp( which ) ) );
+ return new ObjectTypeCalcer( ConicLineIntersectionType::instance(), itqparents );
}
else if ( nlines == 1 && narcs == 1 )
{
- std::vector<ObjectCalcer*> intparents( parents );
- intparents.push_back( new ObjectConstCalcer( new IntImp( which ) ) );
- return new ObjectTypeCalcer( ArcLineIntersectionType::instance(), intparents );
+ std::vector<ObjectCalcer*> inttqparents( tqparents );
+ inttqparents.push_back( new ObjectConstCalcer( new IntImp( which ) ) );
+ return new ObjectTypeCalcer( ArcLineIntersectionType::instance(), inttqparents );
}
else return 0;
}
ObjectCalcer* KigFilterKSeg::transformObject( const TQString& file, KigDocument& kigdoc,
- std::vector<ObjectCalcer*>& parents,
+ std::vector<ObjectCalcer*>& tqparents,
int subtype, bool& ok )
{
ok = true;
@@ -145,34 +145,34 @@ ObjectCalcer* KigFilterKSeg::transformObject( const TQString& file, KigDocument&
{
case G_TRANSLATED:
{
- std::vector<ObjectCalcer*> vectorparents( parents.begin() + 1, parents.end() );
- ObjectTypeCalcer* vector = new ObjectTypeCalcer( VectorType::instance(), vectorparents );
+ std::vector<ObjectCalcer*> vectortqparents( tqparents.begin() + 1, tqparents.end() );
+ ObjectTypeCalcer* vector = new ObjectTypeCalcer( VectorType::instance(), vectortqparents );
vector->calc( kigdoc );
std::vector<ObjectCalcer*> transparents;
- transparents.push_back( parents[0] );
+ transparents.push_back( tqparents[0] );
transparents.push_back( vector );
retobj = new ObjectTypeCalcer( TranslatedType::instance(), transparents );
break;
}
case G_ROTATED:
{
- std::vector<ObjectCalcer*> angleparents( parents.begin() + 2, parents.end() );
- ObjectTypeCalcer* angle = new ObjectTypeCalcer( AngleType::instance(), angleparents );
+ std::vector<ObjectCalcer*> angletqparents( tqparents.begin() + 2, tqparents.end() );
+ ObjectTypeCalcer* angle = new ObjectTypeCalcer( AngleType::instance(), angletqparents );
angle->calc( kigdoc );
- std::vector<ObjectCalcer*> rotparents;
- rotparents.push_back( parents[0] );
- rotparents.push_back( parents[1] );
- rotparents.push_back( angle );
- retobj = new ObjectTypeCalcer( RotationType::instance(), rotparents );
+ std::vector<ObjectCalcer*> rottqparents;
+ rottqparents.push_back( tqparents[0] );
+ rottqparents.push_back( tqparents[1] );
+ rottqparents.push_back( angle );
+ retobj = new ObjectTypeCalcer( RotationType::instance(), rottqparents );
break;
}
case G_SCALED:
{
- if ( parents.size() == 4 )
+ if ( tqparents.size() == 4 )
{
- retobj = new ObjectTypeCalcer( ScalingOverCenter2Type::instance(), parents );
+ retobj = new ObjectTypeCalcer( ScalingOverCenter2Type::instance(), tqparents );
}
else
{
@@ -187,8 +187,8 @@ ObjectCalcer* KigFilterKSeg::transformObject( const TQString& file, KigDocument&
}
case G_REFLECTED:
{
- std::vector<ObjectCalcer*> mirparents( parents.begin(), parents.end() );
- retobj = new ObjectTypeCalcer( LineReflectionType::instance(), mirparents );
+ std::vector<ObjectCalcer*> mirtqparents( tqparents.begin(), tqparents.end() );
+ retobj = new ObjectTypeCalcer( LineReflectionType::instance(), mirtqparents );
break;
}
}
@@ -250,14 +250,14 @@ KigDocument* KigFilterKSeg::load( const TQString& file )
{
short styleid;
stream >> styleid;
- short nparents;
- stream >> nparents;
- std::vector<ObjectCalcer*> parents( nparents, 0 );
- for ( short j = 0; j < nparents; ++j )
+ short ntqparents;
+ stream >> ntqparents;
+ std::vector<ObjectCalcer*> tqparents( ntqparents, 0 );
+ for ( short j = 0; j < ntqparents; ++j )
{
- int parent;
- stream >> parent;
- parents[j] = ret[parent]->calcer();
+ int tqparent;
+ stream >> tqparent;
+ tqparents[j] = ret[tqparent]->calcer();
};
// read the object..
@@ -318,13 +318,13 @@ KigDocument* KigFilterKSeg::load( const TQString& file )
case G_SCALED:
case G_REFLECTED:
{
- o = transformObject( file, *retdoc, parents, descendtype, ok );
+ o = transformObject( file, *retdoc, tqparents, descendtype, ok );
break;
}
case G_FREE_POINT:
{
// fixed point
- if ( nparents != 0 ) KIG_FILTER_PARSE_ERROR;
+ if ( ntqparents != 0 ) KIG_FILTER_PARSE_ERROR;
Coordinate c = readKSegCoordinate( stream );
o = fact->fixedPointCalcer( c );
break;
@@ -334,37 +334,37 @@ KigDocument* KigFilterKSeg::load( const TQString& file )
// constrained point
double p;
stream >> p;
- if ( nparents != 1 ) KIG_FILTER_PARSE_ERROR;
- ObjectCalcer* parent = parents[0];
- assert( parent );
- o = fact->constrainedPointCalcer( parent, p );
+ if ( ntqparents != 1 ) KIG_FILTER_PARSE_ERROR;
+ ObjectCalcer* tqparent = tqparents[0];
+ assert( tqparent );
+ o = fact->constrainedPointCalcer( tqparent, p );
break;
}
case G_INTERSECTION_POINT:
{
// KSeg has somewhat weird intersection objects..
// for all objects G_INTERSECTION_POINT gets the
- // first intersection of its parents, G_INTERSECTION2_POINT
+ // first intersection of its tqparents, G_INTERSECTION2_POINT
// represents the second, if present.
- o = intersectionPoint( parents, -1 );
+ o = intersectionPoint( tqparents, -1 );
if ( ! o ) KIG_FILTER_PARSE_ERROR;
break;
}
case G_INTERSECTION2_POINT:
{
- o = intersectionPoint( parents, 1 );
+ o = intersectionPoint( tqparents, 1 );
if ( ! o ) KIG_FILTER_PARSE_ERROR;
break;
}
case G_MID_POINT:
{
// midpoint of a segment..
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- if ( !parents[0]->imp()->inherits( SegmentImp::stype() ) )
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ if ( !tqparents[0]->imp()->inherits( SegmentImp::stype() ) )
KIG_FILTER_PARSE_ERROR;
- int index = parents[0]->imp()->propertiesInternalNames().findIndex( "mid-point" );
+ int index = tqparents[0]->imp()->propertiesInternalNames().tqfindIndex( "mid-point" );
assert( index != -1 );
- o = new ObjectPropertyCalcer( parents[0], index );
+ o = new ObjectPropertyCalcer( tqparents[0], index );
break;
}
default:
@@ -383,13 +383,13 @@ KigDocument* KigFilterKSeg::load( const TQString& file )
case G_SCALED:
case G_REFLECTED:
{
- o = transformObject( file, *retdoc, parents, descendtype, ok );
+ o = transformObject( file, *retdoc, tqparents, descendtype, ok );
break;
}
case G_ENDPOINTS_SEGMENT:
{
- if ( nparents != 2 ) KIG_FILTER_PARSE_ERROR;
- o = new ObjectTypeCalcer( SegmentABType::instance(), parents );
+ if ( ntqparents != 2 ) KIG_FILTER_PARSE_ERROR;
+ o = new ObjectTypeCalcer( SegmentABType::instance(), tqparents );
break;
}
default:
@@ -406,18 +406,18 @@ KigDocument* KigFilterKSeg::load( const TQString& file )
case G_SCALED:
case G_REFLECTED:
{
- o = transformObject( file, *retdoc, parents, descendtype, ok );
+ o = transformObject( file, *retdoc, tqparents, descendtype, ok );
break;
}
case G_TWOPOINTS_RAY:
{
- if ( nparents != 2 ) KIG_FILTER_PARSE_ERROR;
- o = new ObjectTypeCalcer( RayABType::instance(), parents );
+ if ( ntqparents != 2 ) KIG_FILTER_PARSE_ERROR;
+ o = new ObjectTypeCalcer( RayABType::instance(), tqparents );
break;
}
case G_BISECTOR_RAY:
{
- ObjectTypeCalcer* angle = new ObjectTypeCalcer( HalfAngleType::instance(), parents );
+ ObjectTypeCalcer* angle = new ObjectTypeCalcer( HalfAngleType::instance(), tqparents );
angle->calc( *retdoc );
o = fact->propertyObjectCalcer( angle, "angle-bisector" );
break;
@@ -436,25 +436,25 @@ KigDocument* KigFilterKSeg::load( const TQString& file )
case G_SCALED:
case G_REFLECTED:
{
- o = transformObject( file, *retdoc, parents, descendtype, ok );
+ o = transformObject( file, *retdoc, tqparents, descendtype, ok );
break;
}
case G_TWOPOINTS_LINE:
{
- if ( nparents != 2 ) KIG_FILTER_PARSE_ERROR;
- o = new ObjectTypeCalcer( LineABType::instance(), parents );
+ if ( ntqparents != 2 ) KIG_FILTER_PARSE_ERROR;
+ o = new ObjectTypeCalcer( LineABType::instance(), tqparents );
break;
}
case G_PARALLEL_LINE:
{
- if ( nparents != 2 ) KIG_FILTER_PARSE_ERROR;
- o = new ObjectTypeCalcer( LineParallelLPType::instance(), parents );
+ if ( ntqparents != 2 ) KIG_FILTER_PARSE_ERROR;
+ o = new ObjectTypeCalcer( LineParallelLPType::instance(), tqparents );
break;
}
case G_PERPENDICULAR_LINE:
{
- if ( nparents != 2 ) KIG_FILTER_PARSE_ERROR;
- o = new ObjectTypeCalcer( LinePerpendLPType::instance(), parents );
+ if ( ntqparents != 2 ) KIG_FILTER_PARSE_ERROR;
+ o = new ObjectTypeCalcer( LinePerpendLPType::instance(), tqparents );
break;
}
default:
@@ -471,37 +471,37 @@ KigDocument* KigFilterKSeg::load( const TQString& file )
case G_SCALED:
case G_REFLECTED:
{
- o = transformObject( file, *retdoc, parents, descendtype, ok );
+ o = transformObject( file, *retdoc, tqparents, descendtype, ok );
break;
}
case G_CENTERPOINT_CIRCLE:
{
- if ( nparents != 2 ) KIG_FILTER_PARSE_ERROR;
- o = new ObjectTypeCalcer( CircleBCPType::instance(), parents );
+ if ( ntqparents != 2 ) KIG_FILTER_PARSE_ERROR;
+ o = new ObjectTypeCalcer( CircleBCPType::instance(), tqparents );
break;
}
case G_CENTERRADIUS_CIRCLE:
{
ObjectCalcer* point;
ObjectCalcer* segment;
- if ( parents[0]->imp()->inherits( PointImp::stype() ) )
+ if ( tqparents[0]->imp()->inherits( PointImp::stype() ) )
{
- point = parents[0];
- segment = parents[1];
+ point = tqparents[0];
+ segment = tqparents[1];
}
else
{
- point = parents[1];
- segment = parents[0];
+ point = tqparents[1];
+ segment = tqparents[0];
};
- int index = segment->imp()->propertiesInternalNames().findIndex( "length" );
+ int index = segment->imp()->propertiesInternalNames().tqfindIndex( "length" );
if ( index == -1 ) KIG_FILTER_PARSE_ERROR;
ObjectPropertyCalcer* length = new ObjectPropertyCalcer( segment, index );
length->calc( *retdoc );
- std::vector<ObjectCalcer*> cparents;
- cparents.push_back( point );
- cparents.push_back( length );
- o = new ObjectTypeCalcer( CircleBPRType::instance(), cparents );
+ std::vector<ObjectCalcer*> ctqparents;
+ ctqparents.push_back( point );
+ ctqparents.push_back( length );
+ o = new ObjectTypeCalcer( CircleBPRType::instance(), ctqparents );
break;
}
default:
@@ -518,13 +518,13 @@ KigDocument* KigFilterKSeg::load( const TQString& file )
case G_SCALED:
case G_REFLECTED:
{
- o = transformObject( file, *retdoc, parents, descendtype, ok );
+ o = transformObject( file, *retdoc, tqparents, descendtype, ok );
break;
}
case G_THREEPOINTS_ARC:
{
- if ( nparents != 3 ) KIG_FILTER_PARSE_ERROR;
- o = new ObjectTypeCalcer( ArcBTPType::instance(), parents );
+ if ( ntqparents != 3 ) KIG_FILTER_PARSE_ERROR;
+ o = new ObjectTypeCalcer( ArcBTPType::instance(), tqparents );
break;
}
default:
@@ -541,13 +541,13 @@ KigDocument* KigFilterKSeg::load( const TQString& file )
case G_SCALED:
case G_REFLECTED:
{
- o = transformObject( file, *retdoc, parents, descendtype, ok );
+ o = transformObject( file, *retdoc, tqparents, descendtype, ok );
break;
}
default:
{
- if ( nparents < 3 ) KIG_FILTER_PARSE_ERROR;
- o = new ObjectTypeCalcer( PolygonBNPType::instance(), parents );
+ if ( ntqparents < 3 ) KIG_FILTER_PARSE_ERROR;
+ o = new ObjectTypeCalcer( PolygonBNPType::instance(), tqparents );
}
}
// default:
@@ -581,13 +581,13 @@ KigDocument* KigFilterKSeg::load( const TQString& file )
case G_SCALED:
case G_REFLECTED:
{
- o = transformObject( file, *retdoc, parents, descendtype, ok );
+ o = transformObject( file, *retdoc, tqparents, descendtype, ok );
break;
}
case G_OBJECT_LOCUS:
{
- if ( nparents != 2 ) KIG_FILTER_PARSE_ERROR;
- o = fact->locusCalcer( parents[0], parents[1] );
+ if ( ntqparents != 2 ) KIG_FILTER_PARSE_ERROR;
+ o = fact->locusCalcer( tqparents[0], tqparents[1] );
break;
}
default:
@@ -636,7 +636,7 @@ KigDocument* KigFilterKSeg::load( const TQString& file )
std::vector<ObjectCalcer*> args2;
args2.push_back( object->nameCalcer() );
ObjectCalcer* oc2 = fact->attachedLabelCalcer(
- TQString::fromLatin1( "%1" ), object->calcer(),
+ TQString::tqfromLatin1( "%1" ), object->calcer(),
static_cast<const PointImp*>( object->imp() )->coordinate(),
false, args2, *retdoc );
oc2->calc( *retdoc );
diff --git a/kig/filters/kseg-filter.h b/kig/filters/kseg-filter.h
index 03d03958..d8909282 100644
--- a/kig/filters/kseg-filter.h
+++ b/kig/filters/kseg-filter.h
@@ -29,7 +29,7 @@ class KigFilterKSeg
~KigFilterKSeg();
ObjectCalcer* transformObject( const TQString& file, KigDocument& kigdoc,
- std::vector<ObjectCalcer*>& parents,
+ std::vector<ObjectCalcer*>& tqparents,
int subtype, bool& ok );
public:
diff --git a/kig/filters/latexexporter.cc b/kig/filters/latexexporter.cc
index 98d3fc2e..811cfd9b 100644
--- a/kig/filters/latexexporter.cc
+++ b/kig/filters/latexexporter.cc
@@ -194,7 +194,7 @@ void LatexExportImpVisitor::mapColor( TQColor color )
ColorMap newcolor;
newcolor.color = color;
TQString tmpname = color.name();
- tmpname.replace( "#", "" );
+ tmpname.tqreplace( "#", "" );
newcolor.name = tmpname;
mcolors.push_back( newcolor );
mstream << "\\newrgbcolor{" << tmpname << "}{"
@@ -213,9 +213,9 @@ double LatexExportImpVisitor::dimRealToCoord( int dim )
TQString LatexExportImpVisitor::writeStyle( Qt::PenStyle style )
{
TQString ret( "linestyle=" );
- if ( style == Qt::DashLine )
+ if ( style == TQt::DashLine )
ret += "dashed";
- else if ( style == Qt::DotLine )
+ else if ( style == TQt::DotLine )
ret += "dotted,dotsep=2pt";
else
ret += "solid";
@@ -228,9 +228,9 @@ void LatexExportImpVisitor::plotGenericCurve( const CurveImp* imp )
if ( width == -1 ) width = 1;
TQString prefix = TQString( "\\pscurve[linecolor=%1,linewidth=%2,%3]" )
- .arg( mcurcolorid )
- .arg( width / 100.0 )
- .arg( writeStyle( mcurobj->drawer()->style() ) );
+ .tqarg( mcurcolorid )
+ .tqarg( width / 100.0 )
+ .tqarg( writeStyle( mcurobj->drawer()->style() ) );
std::vector< std::vector< Coordinate > > coordlist;
coordlist.push_back( std::vector< Coordinate >() );
@@ -483,7 +483,7 @@ void LatexExportImpVisitor::visit( const PolygonImp* imp )
void LatexExporter::run( const KigPart& doc, KigWidget& w )
{
KigFileDialog* kfd = new KigFileDialog(
- TQString::null, i18n( "*.tex|Latex Documents (*.tex)" ),
+ TQString(), i18n( "*.tex|Latex Documents (*.tex)" ),
i18n( "Export as Latex" ), &w );
kfd->setOptionCaption( i18n( "Latex Options" ) );
LatexExporterOptions* opts = new LatexExporterOptions( 0L );
@@ -507,7 +507,7 @@ void LatexExporter::run( const KigPart& doc, KigWidget& w )
{
KMessageBox::sorry( &w, i18n( "The file \"%1\" could not be opened. Please "
"check if the file permissions are set correctly." )
- .arg( file_name ) );
+ .tqarg( file_name ) );
return;
};
diff --git a/kig/filters/latexexporteroptions.ui b/kig/filters/latexexporteroptions.ui
index d2e60c5b..04275dd7 100644
--- a/kig/filters/latexexporteroptions.ui
+++ b/kig/filters/latexexporteroptions.ui
@@ -1,10 +1,10 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>LatexExporterOptions</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>LatexExporterOptions</cstring>
</property>
- <property name="geometry">
+ <property name="tqgeometry">
<rect>
<x>0</x>
<y>0</y>
@@ -22,7 +22,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox1</cstring>
</property>
@@ -33,7 +33,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QCheckBox" row="0" column="0">
+ <widget class="TQCheckBox" row="0" column="0">
<property name="name">
<cstring>showGridCheckBox</cstring>
</property>
@@ -41,7 +41,7 @@
<string>Show grid</string>
</property>
</widget>
- <widget class="QCheckBox" row="0" column="1">
+ <widget class="TQCheckBox" row="0" column="1">
<property name="name">
<cstring>showAxesCheckBox</cstring>
</property>
@@ -49,7 +49,7 @@
<string>Show axes</string>
</property>
</widget>
- <widget class="QCheckBox" row="1" column="0">
+ <widget class="TQCheckBox" row="1" column="0">
<property name="name">
<cstring>showExtraFrameCheckBox</cstring>
</property>
@@ -63,7 +63,7 @@
</widget>
<customwidgets>
</customwidgets>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
</includehints>
</UI>
diff --git a/kig/filters/native-filter.cc b/kig/filters/native-filter.cc
index a5378263..4a3d0a04 100644
--- a/kig/filters/native-filter.cc
+++ b/kig/filters/native-filter.cc
@@ -51,7 +51,7 @@
struct HierElem
{
int id;
- std::vector<int> parents;
+ std::vector<int> tqparents;
TQDomElement el;
};
@@ -73,8 +73,8 @@ static void visitElem( std::vector<HierElem>& ret,
{
if ( !seen[i] )
{
- for ( uint j = 0; j < elems[i].parents.size(); ++j )
- visitElem( ret, elems, seen, elems[i].parents[j] - 1);
+ for ( uint j = 0; j < elems[i].tqparents.size(); ++j )
+ visitElem( ret, elems, seen, elems[i].tqparents[j] - 1);
ret.push_back( elems[i] );
seen[i] = true;
};
@@ -114,7 +114,7 @@ KigDocument* KigFilterNative::load( const TQString& file )
TQFile kigdoc( file );
#ifndef KIG_NO_COMPRESSED_FILES
bool iscompressed = false;
- if ( !file.endsWith( ".kig", false ) )
+ if ( !file.tqendsWith( ".kig", false ) )
{
// the file is compressed, so we have to decompress it and fetch the
// kig file inside it...
@@ -125,7 +125,7 @@ KigDocument* KigFilterNative::load( const TQString& file )
KIG_FILTER_PARSE_ERROR;
TQString tempname = file.section( '/', -1 );
- if ( file.endsWith( ".kigz", false ) )
+ if ( file.tqendsWith( ".kigz", false ) )
{
tempname.remove( TQRegExp( "\\.[Kk][Ii][Gg][Zz]$" ) );
}
@@ -193,7 +193,7 @@ KigDocument* KigFilterNative::load( const TQString& file )
if ( major > 0 || minor > 9 )
{
notSupported( file, i18n( "This file was created by Kig version \"%1\", "
- "which this version cannot open." ).arg( version ) );
+ "which this version cannot open." ).tqarg( version ) );
return false;
}
else if ( major == 0 && minor <= 3 )
@@ -204,7 +204,7 @@ KigDocument* KigFilterNative::load( const TQString& file )
"You can try to open this file with an older Kig "
"version (0.4 to 0.6),\n"
"and then save it again, which will save it in the "
- "new format." ).arg( version ) );
+ "new format." ).tqarg( version ) );
return false;
}
else if ( major == 0 && minor <= 6 )
@@ -226,7 +226,7 @@ KigDocument* KigFilterNative::load04( const TQString& file, const TQDomElement&
if ( e.tagName() == "CoordinateSystem" )
{
const TQCString type = e.text().latin1();
- CoordinateSystem* s = CoordinateSystemFactory::build( type );
+ CoordinateSystem* s = CoordinateSystemFactory::build( type.data() );
if ( ! s )
{
warning( i18n( "This Kig file has a coordinate system "
@@ -273,7 +273,7 @@ KigDocument* KigFilterNative::load04( const TQString& file, const TQDomElement&
if ( ! ok ) KIG_FILTER_PARSE_ERROR;
extendVect( elems, id );
- elems[id-1].parents.push_back( pid );
+ elems[id-1].tqparents.push_back( pid );
}
}
};
@@ -315,14 +315,14 @@ KigDocument* KigFilterNative::load04( const TQString& file, const TQDomElement&
propname = ec.text().latin1();
};
- if ( i->parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
- ObjectCalcer* parent = retcalcers[i->parents[0] -1];
- QCStringList propnames = parent->imp()->propertiesInternalNames();
- int propid = propnames.findIndex( propname );
+ if ( i->tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ ObjectCalcer* tqparent = retcalcers[i->tqparents[0] -1];
+ QCStringList propnames = tqparent->imp()->propertiesInternalNames();
+ int propid = propnames.tqfindIndex( propname );
if ( propid == -1 )
KIG_FILTER_PARSE_ERROR;
- o = new ObjectPropertyCalcer( parent, propid );
+ o = new ObjectPropertyCalcer( tqparent, propid );
}
else if ( e.tagName() == "Object" )
{
@@ -331,23 +331,23 @@ KigDocument* KigFilterNative::load04( const TQString& file, const TQDomElement&
KIG_FILTER_PARSE_ERROR;
const ObjectType* type =
- ObjectTypeFactory::instance()->find( tmp.latin1() );
+ ObjectTypeFactory::instance()->tqfind( tmp.latin1() );
if ( !type )
{
notSupported( file, i18n( "This Kig file uses an object of type \"%1\", "
"which this Kig version does not support."
"Perhaps you have compiled Kig without support "
"for this object type,"
- "or perhaps you are using an older Kig version." ).arg( tmp ) );
+ "or perhaps you are using an older Kig version." ).tqarg( tmp ) );
return false;
};
- std::vector<ObjectCalcer*> parents;
- for ( std::vector<int>::iterator j = i->parents.begin();
- j != i->parents.end(); ++j )
- parents.push_back( retcalcers[*j - 1] );
+ std::vector<ObjectCalcer*> tqparents;
+ for ( std::vector<int>::iterator j = i->tqparents.begin();
+ j != i->tqparents.end(); ++j )
+ tqparents.push_back( retcalcers[*j - 1] );
- o = new ObjectTypeCalcer( type, parents );
+ o = new ObjectTypeCalcer( type, tqparents );
}
else continue;
@@ -415,7 +415,7 @@ KigDocument* KigFilterNative::load07( const TQString& file, const TQDomElement&
ret->setAxes( false );
}
const TQCString type = tmptype.latin1();
- CoordinateSystem* s = CoordinateSystemFactory::build( type );
+ CoordinateSystem* s = CoordinateSystemFactory::build( type.data() );
if ( ! s )
{
warning( i18n( "This Kig file has a coordinate system "
@@ -434,25 +434,25 @@ KigDocument* KigFilterNative::load07( const TQString& file, const TQDomElement&
uint id = tmp.toInt( &ok );
if ( id <= 0 ) KIG_FILTER_PARSE_ERROR;
- std::vector<ObjectCalcer*> parents;
- for ( TQDomElement parentel = e.firstChild().toElement(); ! parentel.isNull();
- parentel = parentel.nextSibling().toElement() )
+ std::vector<ObjectCalcer*> tqparents;
+ for ( TQDomElement tqparentel = e.firstChild().toElement(); ! tqparentel.isNull();
+ tqparentel = tqparentel.nextSibling().toElement() )
{
- if ( parentel.tagName() != "Parent" ) continue;
- TQString tmp = parentel.attribute( "id" );
- uint parentid = tmp.toInt( &ok );
+ if ( tqparentel.tagName() != "Parent" ) continue;
+ TQString tmp = tqparentel.attribute( "id" );
+ uint tqparentid = tmp.toInt( &ok );
if ( ! ok ) KIG_FILTER_PARSE_ERROR;
- if ( parentid == 0 || parentid > calcers.size() ) KIG_FILTER_PARSE_ERROR;
- ObjectCalcer* parent = calcers[parentid - 1].get();
- if ( ! parent ) KIG_FILTER_PARSE_ERROR;
- parents.push_back( parent );
+ if ( tqparentid == 0 || tqparentid > calcers.size() ) KIG_FILTER_PARSE_ERROR;
+ ObjectCalcer* tqparent = calcers[tqparentid - 1].get();
+ if ( ! tqparent ) KIG_FILTER_PARSE_ERROR;
+ tqparents.push_back( tqparent );
}
ObjectCalcer* o = 0;
if ( e.tagName() == "Data" )
{
- if ( !parents.empty() ) KIG_FILTER_PARSE_ERROR;
+ if ( !tqparents.empty() ) KIG_FILTER_PARSE_ERROR;
TQString tmp = e.attribute( "type" );
TQString error;
ObjectImp* imp = ObjectImpFactory::instance()->deserialize( tmp, e, error );
@@ -465,42 +465,42 @@ KigDocument* KigFilterNative::load07( const TQString& file, const TQDomElement&
}
else if ( e.tagName() == "Property" )
{
- if ( parents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
+ if ( tqparents.size() != 1 ) KIG_FILTER_PARSE_ERROR;
TQCString propname = e.attribute( "which" ).latin1();
- ObjectCalcer* parent = parents[0];
- int propid = parent->imp()->propertiesInternalNames().findIndex( propname );
+ ObjectCalcer* tqparent = tqparents[0];
+ int propid = tqparent->imp()->propertiesInternalNames().tqfindIndex( propname );
if ( propid == -1 ) KIG_FILTER_PARSE_ERROR;
- o = new ObjectPropertyCalcer( parent, propid );
+ o = new ObjectPropertyCalcer( tqparent, propid );
}
else if ( e.tagName() == "Object" )
{
TQString tmp = e.attribute( "type" );
const ObjectType* type =
- ObjectTypeFactory::instance()->find( tmp.latin1() );
+ ObjectTypeFactory::instance()->tqfind( tmp.latin1() );
if ( ! type )
{
notSupported( file, i18n( "This Kig file uses an object of type \"%1\", "
"which this Kig version does not support."
"Perhaps you have compiled Kig without support "
"for this object type,"
- "or perhaps you are using an older Kig version." ).arg( tmp ) );
+ "or perhaps you are using an older Kig version." ).tqarg( tmp ) );
return false;
}
// mp: (I take the responsibility for this!) explanation: the usual ObjectTypeCalcer
- // constructor also "sortArgs" the parents. I believe that this *must not* be done
+ // constructor also "sortArgs" the tqparents. I believe that this *must not* be done
// when loading from a saved kig file for the following reasons:
// 1. the arguments should already be in their intended order, since the file was
// saved from a working hierarchy; furthermore we actually want to restore the original
// hierarchy, not really to also fix possible problems with the original hierarchy;
// 2. calling sortArgs could have undesirable side effects in particular situations,
// since kig actually allow an ObjectType to produce different type of ObjectImp's
- // it may happen that the parents of an object do not satisfy the requirements
+ // it may happen that the tqparents of an object do not satisfy the requirements
// enforced by sortArgs (while moving around the free objects) but still be
// perfectly valid
- o = new ObjectTypeCalcer( type, parents, false );
+ o = new ObjectTypeCalcer( type, tqparents, false );
}
else KIG_FILTER_PARSE_ERROR;
@@ -604,8 +604,8 @@ bool KigFilterNative::save07( const KigDocument& kdoc, TQTextStream& stream )
const ObjectPropertyCalcer* o = static_cast<const ObjectPropertyCalcer*>( *i );
objectelem = doc.createElement( "Property" );
- TQCString propname = o->parent()->imp()->propertiesInternalNames()[o->propId()];
- objectelem.setAttribute( "which", propname );
+ TQCString propname = o->tqparent()->imp()->propertiesInternalNames()[o->propId()];
+ objectelem.setAttribute( TQString("which"), TQString(propname) );
}
else if ( dynamic_cast<const ObjectTypeCalcer*>( *i ) )
{
@@ -615,8 +615,8 @@ bool KigFilterNative::save07( const KigDocument& kdoc, TQTextStream& stream )
}
else assert( false );
- const std::vector<ObjectCalcer*> parents = ( *i )->parents();
- for ( std::vector<ObjectCalcer*>::const_iterator i = parents.begin(); i != parents.end(); ++i )
+ const std::vector<ObjectCalcer*> tqparents = ( *i )->tqparents();
+ for ( std::vector<ObjectCalcer*>::const_iterator i = tqparents.begin(); i != tqparents.end(); ++i )
{
std::map<const ObjectCalcer*,int>::const_iterator idp = idmap.find( *i );
assert( idp != idmap.end() );
@@ -642,7 +642,7 @@ bool KigFilterNative::save07( const KigDocument& kdoc, TQTextStream& stream )
TQDomElement drawelem = doc.createElement( "Draw" );
drawelem.setAttribute( "object", id );
drawelem.setAttribute( "color", d->color().name() );
- drawelem.setAttribute( "shown", TQString::fromLatin1( d->shown() ? "true" : "false" ) );
+ drawelem.setAttribute( "shown", TQString::tqfromLatin1( d->shown() ? "true" : "false" ) );
drawelem.setAttribute( "width", TQString::number( d->width() ) );
drawelem.setAttribute( "style", d->styleToString() );
drawelem.setAttribute( "point-style", d->pointStyleToString() );
@@ -683,7 +683,7 @@ bool KigFilterNative::save07( const KigDocument& data, const TQString& outfile )
return save07( data, stdoutstream );
}
#ifndef KIG_NO_COMPRESSED_FILES
- if ( !outfile.endsWith( ".kig", false ) )
+ if ( !outfile.tqendsWith( ".kig", false ) )
{
// the user wants to save a compressed file, so we have to save our kig
// file to a temp file and then compress it...
@@ -693,7 +693,7 @@ bool KigFilterNative::save07( const KigDocument& data, const TQString& outfile )
return false;
TQString tempname = outfile.section( '/', -1 );
- if ( outfile.endsWith( ".kigz", false ) )
+ if ( outfile.tqendsWith( ".kigz", false ) )
tempname.remove( TQRegExp( "\\.[Kk][Ii][Gg][Zz]$" ) );
else
return false;
diff --git a/kig/filters/svgexporter.cc b/kig/filters/svgexporter.cc
index 57413004..93801b3b 100644
--- a/kig/filters/svgexporter.cc
+++ b/kig/filters/svgexporter.cc
@@ -59,7 +59,7 @@ TQString SVGExporter::menuIcon() const
void SVGExporter::run( const KigPart& part, KigWidget& w )
{
KigFileDialog* kfd = new KigFileDialog(
- TQString::null, i18n( "*.svg|Scalable Vector Graphics (*.svg)" ),
+ TQString(), i18n( "*.svg|Scalable Vector Graphics (*.svg)" ),
i18n( "Export as SVG" ), &w );
kfd->setOptionCaption( i18n( "SVG Options" ) );
SVGExporterOptions* opts = new SVGExporterOptions( 0L );
@@ -81,7 +81,7 @@ void SVGExporter::run( const KigPart& part, KigWidget& w )
{
KMessageBox::sorry( &w, i18n( "The file \"%1\" could not be opened. Please "
"check if the file permissions are set correctly." )
- .arg( file_name ) );
+ .tqarg( file_name ) );
return;
};
@@ -91,12 +91,12 @@ void SVGExporter::run( const KigPart& part, KigWidget& w )
TQPicture pic;
pic.setBoundingRect( r );
KigPainter* p = new KigPainter( ScreenInfo( w.screenInfo().shownRect(), viewrect ),
- &pic, part.document() );
+ TQT_TQPAINTDEVICE(&pic), part.document() );
// p->setWholeWinOverlay();
-// p->setBrushColor( Qt::white );
-// p->setBrushStyle( Qt::SolidPattern );
+// p->setBrushColor( TQt::white );
+// p->setBrushStyle( TQt::SolidPattern );
// p->drawRect( r );
-// p->setBrushStyle( Qt::NoBrush );
+// p->setBrushStyle( TQt::NoBrush );
// p->setWholeWinOverlay();
p->drawGrid( part.document().coordinateSystem(), showgrid, showaxes );
p->drawObjects( part.document().objects(), false );
@@ -105,7 +105,7 @@ void SVGExporter::run( const KigPart& part, KigWidget& w )
if ( !pic.save( file_name, "SVG" ) )
{
- KMessageBox::error( &w, i18n( "Sorry, something went wrong while saving to SVG file \"%1\"" ).arg( file_name ) );
+ KMessageBox::error( &w, i18n( "Sorry, something went wrong while saving to SVG file \"%1\"" ).tqarg( file_name ) );
}
}
diff --git a/kig/filters/svgexporteroptions.ui b/kig/filters/svgexporteroptions.ui
index 2de679cb..58176edf 100644
--- a/kig/filters/svgexporteroptions.ui
+++ b/kig/filters/svgexporteroptions.ui
@@ -1,10 +1,10 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>SVGExporterOptions</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>SVGExporterOptions</cstring>
</property>
- <property name="geometry">
+ <property name="tqgeometry">
<rect>
<x>0</x>
<y>0</y>
@@ -22,7 +22,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox1</cstring>
</property>
@@ -33,7 +33,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QCheckBox" row="0" column="0">
+ <widget class="TQCheckBox" row="0" column="0">
<property name="name">
<cstring>showGridCheckBox</cstring>
</property>
@@ -41,7 +41,7 @@
<string>Show grid</string>
</property>
</widget>
- <widget class="QCheckBox" row="0" column="1">
+ <widget class="TQCheckBox" row="0" column="1">
<property name="name">
<cstring>showAxesCheckBox</cstring>
</property>
@@ -55,7 +55,7 @@
</widget>
<customwidgets>
</customwidgets>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
</includehints>
</UI>
diff --git a/kig/filters/tests/locus.fgeo b/kig/filters/tests/locus.fgeo
index a914068c..4ad79bbd 100644
--- a/kig/filters/tests/locus.fgeo
+++ b/kig/filters/tests/locus.fgeo
@@ -1,2 +1,2 @@
<?xml version="1.0"?>
-<drgenius><drgeo name="Figuur 1" scale="30.000000" origin_x="0.000000" origin_y="0.000000" grid="False"><point id="8293DE0" type="Free" color="Red" thickness="Dashed" style="Cross" filled="False" masked="False" name=""><x>-1.666666</x><y>3.216667</y></point><point id="8306C70" type="Free" color="Red" thickness="Dashed" style="Cross" filled="False" masked="False" name=""><x>-2.766667</x><y>0.550000</y></point><circle id="8307268" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name=""><parent ref="8293DE0"/><parent ref="8306C70"/></circle><point id="8309098" type="On_curve" color="Red" thickness="Dashed" style="Cross" filled="False" masked="False" name=""><value>0.080691</value><parent ref="8307268"/></point><point id="830A920" type="Free" color="Red" thickness="Dashed" style="Cross" filled="False" masked="False" name=""><x>3.000000</x><y>3.016667</y></point><line id="8172970" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name=""><parent ref="8309098"/><parent ref="830A920"/></line><point id="8339730" type="Free" color="Red" thickness="Dashed" style="Cross" filled="False" masked="False" name=""><x>2.866667</x><y>-0.750000</y></point><line id="833AD18" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name=""><parent ref="8309098"/><parent ref="8339730"/></line><point id="8338A50" type="Free" color="Red" thickness="Dashed" style="Cross" filled="False" masked="False" name=""><x>2.600000</x><y>3.816667</y></point><line id="833BBB8" type="perpendicular" color="Black" thickness="Normal" style="Cross" filled="False" masked="False" name=""><parent ref="8338A50"/><parent ref="833AD18"/></line><point id="8342478" type="Intersection" color="Red" thickness="Dashed" style="Cross" filled="False" masked="False" name="" extra="0"><parent ref="8172970"/><parent ref="833BBB8"/></point><locus id="8345D60" type="None" color="Black" thickness="Dashed" style="Cross" filled="False" masked="False" name=""><parent ref="8309098"/><parent ref="8342478"/></locus></drgeo></drgenius>
+<drgenius><drgeo name="Figuur 1" scale="30.000000" origin_x="0.000000" origin_y="0.000000" grid="False"><point id="8293DE0" type="Free" color="Red" thickness="Dashed" style="Cross" filled="False" tqmasked="False" name=""><x>-1.666666</x><y>3.216667</y></point><point id="8306C70" type="Free" color="Red" thickness="Dashed" style="Cross" filled="False" tqmasked="False" name=""><x>-2.766667</x><y>0.550000</y></point><circle id="8307268" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name=""><tqparent ref="8293DE0"/><tqparent ref="8306C70"/></circle><point id="8309098" type="On_curve" color="Red" thickness="Dashed" style="Cross" filled="False" tqmasked="False" name=""><value>0.080691</value><tqparent ref="8307268"/></point><point id="830A920" type="Free" color="Red" thickness="Dashed" style="Cross" filled="False" tqmasked="False" name=""><x>3.000000</x><y>3.016667</y></point><line id="8172970" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name=""><tqparent ref="8309098"/><tqparent ref="830A920"/></line><point id="8339730" type="Free" color="Red" thickness="Dashed" style="Cross" filled="False" tqmasked="False" name=""><x>2.866667</x><y>-0.750000</y></point><line id="833AD18" type="2pts" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name=""><tqparent ref="8309098"/><tqparent ref="8339730"/></line><point id="8338A50" type="Free" color="Red" thickness="Dashed" style="Cross" filled="False" tqmasked="False" name=""><x>2.600000</x><y>3.816667</y></point><line id="833BBB8" type="perpendicular" color="Black" thickness="Normal" style="Cross" filled="False" tqmasked="False" name=""><tqparent ref="8338A50"/><tqparent ref="833AD18"/></line><point id="8342478" type="Intersection" color="Red" thickness="Dashed" style="Cross" filled="False" tqmasked="False" name="" extra="0"><tqparent ref="8172970"/><tqparent ref="833BBB8"/></point><locus id="8345D60" type="None" color="Black" thickness="Dashed" style="Cross" filled="False" tqmasked="False" name=""><tqparent ref="8309098"/><tqparent ref="8342478"/></locus></drgeo></drgenius>
diff --git a/kig/kfile/Makefile.am b/kig/kfile/Makefile.am
index b8de2d3d..f2cc337f 100644
--- a/kig/kfile/Makefile.am
+++ b/kig/kfile/Makefile.am
@@ -9,11 +9,11 @@ kde_module_LTLIBRARIES = \
kfile_kig.la
kfile_drgeo_la_SOURCES = kfile_drgeo.cpp
-kfile_drgeo_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN)
+kfile_drgeo_la_LDFLAGS = $(all_libraries) $(LIB_QT) $(LIB_KDECORE) $(LIB_KDEUI) $(LIB_KIO) -module $(KDE_PLUGIN)
kfile_drgeo_la_LIBADD = $(LIB_KIO)
kfile_kig_la_SOURCES = kfile_kig.cpp
-kfile_kig_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN)
+kfile_kig_la_LDFLAGS = $(all_libraries) $(LIB_QT) $(LIB_KDECORE) $(LIB_KDEUI) $(LIB_KIO) -module $(KDE_PLUGIN)
kfile_kig_la_LIBADD = $(LIB_KIO)
METASOURCES = AUTO
diff --git a/kig/kfile/kfile_drgeo.cpp b/kig/kfile/kfile_drgeo.cpp
index b921131b..bbdc6869 100644
--- a/kig/kfile/kfile_drgeo.cpp
+++ b/kig/kfile/kfile_drgeo.cpp
@@ -29,8 +29,8 @@ typedef KGenericFactory<DrgeoPlugin> drgeoFactory;
K_EXPORT_COMPONENT_FACTORY( kfile_drgeo, drgeoFactory( "kfile_drgeo" ) )
-DrgeoPlugin::DrgeoPlugin( TQObject *parent, const char *name, const TQStringList &args )
- : KFilePlugin( parent, name, args )
+DrgeoPlugin::DrgeoPlugin( TQObject *tqparent, const char *name, const TQStringList &args )
+ : KFilePlugin( tqparent, name, args )
{
info = addMimeTypeInfo( "application/x-drgeo" );
@@ -41,7 +41,7 @@ DrgeoPlugin::DrgeoPlugin( TQObject *parent, const char *name, const TQStringList
item = addItemInfo( group, "NumOfMacros", i18n( "Macros" ), TQVariant::Int );
group_contents = addGroupInfo( info, "DrgeoContents", i18n( "Translators: what this drgeo "
- "file contains", "Contents" ) );
+ "file tqcontains", "Contents" ) );
}
bool DrgeoPlugin::readInfo( KFileMetaInfo& metainfo, uint /*what*/ )
diff --git a/kig/kfile/kfile_drgeo.h b/kig/kfile/kfile_drgeo.h
index 4495cd17..19b28e5b 100644
--- a/kig/kfile/kfile_drgeo.h
+++ b/kig/kfile/kfile_drgeo.h
@@ -28,9 +28,10 @@ class TQStringList;
class DrgeoPlugin: public KFilePlugin
{
Q_OBJECT
+ TQ_OBJECT
public:
- DrgeoPlugin( TQObject *parent, const char *name, const TQStringList& args );
+ DrgeoPlugin( TQObject *tqparent, const char *name, const TQStringList& args );
virtual bool readInfo( KFileMetaInfo& metainfo, uint what);
protected:
diff --git a/kig/kfile/kfile_kig.cpp b/kig/kfile/kfile_kig.cpp
index bd54a036..defae8c2 100644
--- a/kig/kfile/kfile_kig.cpp
+++ b/kig/kfile/kfile_kig.cpp
@@ -35,8 +35,8 @@ typedef KGenericFactory<KigPlugin> kigFactory;
K_EXPORT_COMPONENT_FACTORY( kfile_kig, kigFactory( "kfile_kig" ) )
-KigPlugin::KigPlugin( TQObject *parent, const char *name, const TQStringList &args )
- : KFilePlugin( parent, name, args )
+KigPlugin::KigPlugin( TQObject *tqparent, const char *name, const TQStringList &args )
+ : KFilePlugin( tqparent, name, args )
{
KFileMimeTypeInfo::ItemInfo* item;
@@ -58,7 +58,7 @@ bool KigPlugin::readInfo( KFileMetaInfo& metainfo, uint /*what*/ )
TQString sfile = metainfo.path();
bool iscompressed = false;
TQFile f( sfile );
- if ( !sfile.endsWith( ".kig", false ) )
+ if ( !sfile.tqendsWith( ".kig", false ) )
{
iscompressed = true;
@@ -67,7 +67,7 @@ bool KigPlugin::readInfo( KFileMetaInfo& metainfo, uint /*what*/ )
return false;
TQString tempname = sfile.section( '/', -1 );
- if ( sfile.endsWith( ".kigz", false ) )
+ if ( sfile.tqendsWith( ".kigz", false ) )
{
tempname.remove( TQRegExp( "\\.[Kk][Ii][Gg][Zz]$" ) );
}
@@ -114,7 +114,7 @@ bool KigPlugin::readInfo( KFileMetaInfo& metainfo, uint /*what*/ )
TQString compatversion = main.attribute( "CompatibilityVersion" );
if ( compatversion.isEmpty() )
compatversion = i18n( "%1 represents Kig version",
- "%1 (as the version)" ).arg( version );
+ "%1 (as the version)" ).tqarg( version );
appendItem( metagroup, "CompatVersion", compatversion );
// reading the Coordinate System...
diff --git a/kig/kfile/kfile_kig.h b/kig/kfile/kfile_kig.h
index d5238a4f..7c0512be 100644
--- a/kig/kfile/kfile_kig.h
+++ b/kig/kfile/kfile_kig.h
@@ -28,9 +28,10 @@ class TQStringList;
class KigPlugin: public KFilePlugin
{
Q_OBJECT
+ TQ_OBJECT
public:
- KigPlugin( TQObject *parent, const char *name, const TQStringList& args );
+ KigPlugin( TQObject *tqparent, const char *name, const TQStringList& args );
virtual bool readInfo( KFileMetaInfo& metainfo, uint what);
protected:
diff --git a/kig/kig/kig.cpp b/kig/kig/kig.cpp
index ed954d26..dc63b2dc 100644
--- a/kig/kig/kig.cpp
+++ b/kig/kig/kig.cpp
@@ -69,7 +69,7 @@ Kig::Kig()
// now that the Part is loaded, we cast it to a Part to get
// our hands on it
m_part = static_cast<KParts::ReadWritePart*>
- (factory->create(this, "kig_part", "KParts::ReadWritePart" ));
+ (factory->create(TQT_TQOBJECT(this), "kig_part", "KParts::ReadWritePart" ));
if (m_part)
{
// tell the KParts::MainWindow that this is indeed the main widget
@@ -105,30 +105,30 @@ Kig::~Kig()
void Kig::setupActions()
{
- KStdAction::openNew(this, TQT_SLOT(fileNew()), actionCollection());
- KStdAction::open(this, TQT_SLOT(fileOpen()), actionCollection());
- KStdAction::quit(this, TQT_SLOT(close()), actionCollection());
+ KStdAction::openNew(TQT_TQOBJECT(this), TQT_SLOT(fileNew()), actionCollection());
+ KStdAction::open(TQT_TQOBJECT(this), TQT_SLOT(fileOpen()), actionCollection());
+ KStdAction::quit(TQT_TQOBJECT(this), TQT_SLOT(close()), actionCollection());
#ifdef KIG_DONT_USE_NEW_KMAINWINDOW_FEATURES
- m_toolbarAction = KStdAction::showToolbar(this, TQT_SLOT(optionsShowToolbar()), actionCollection());
- m_statusbarAction = KStdAction::showStatusbar(this, TQT_SLOT(optionsShowStatusbar()), actionCollection());
+ m_toolbarAction = KStdAction::showToolbar(TQT_TQOBJECT(this), TQT_SLOT(optionsShowToolbar()), actionCollection());
+ m_statusbarAction = KStdAction::showStatusbar(TQT_TQOBJECT(this), TQT_SLOT(optionsShowStatusbar()), actionCollection());
#else
createStandardStatusBarAction();
setStandardToolBarMenuEnabled(true);
#endif
// FIXME: this (recent files) should be app-wide, not specific to each window...
- m_recentFilesAction = KStdAction::openRecent(this, TQT_SLOT(openURL(const KURL&)), actionCollection());
+ m_recentFilesAction = KStdAction::openRecent(TQT_TQOBJECT(this), TQT_SLOT(openURL(const KURL&)), actionCollection());
m_recentFilesAction->loadEntries(config);
#if KDE_IS_VERSION( 3, 2, 90 )
KStdAction::keyBindings( guiFactory(), TQT_SLOT( configureShortcuts() ), actionCollection() );
#else
- KStdAction::keyBindings(this, TQT_SLOT(optionsConfigureKeys()), actionCollection());
+ KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureKeys()), actionCollection());
#endif
- KStdAction::configureToolbars(this, TQT_SLOT(optionsConfigureToolbars()), actionCollection());
+ KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureToolbars()), actionCollection());
- KStdAction::tipOfDay( this, TQT_SLOT( tipOfDay() ), actionCollection(), "help_tipofday" );
+ KStdAction::tipOfDay( TQT_TQOBJECT(this), TQT_SLOT( tipOfDay() ), actionCollection(), "help_tipofday" );
}
void Kig::saveProperties(KConfig* config)
@@ -219,7 +219,7 @@ bool Kig::queryClose()
switch( KMessageBox::warningYesNoCancel
(
widget(),
- i18n("Save changes to document %1?").arg(m_part->url().path()),
+ i18n("Save changes to document %1?").tqarg(m_part->url().path()),
i18n("Save Changes?"),KStdGuiItem::save(),KStdGuiItem::discard()
))
{
@@ -272,7 +272,7 @@ void Kig::fileOpen()
if (!file_name.isEmpty()) openURL(file_name);
}
-// ifdef's disabled, cause Qt moc doesn't handle ifdef's..
+// ifdef's disabled, cause TQt tqmoc doesn't handle ifdef's..
// #ifdef KIG_DONT_USE_NEW_KMAINWINDOW_FEATURES
void Kig::optionsShowToolbar()
{
diff --git a/kig/kig/kig.h b/kig/kig/kig.h
index 51c236f2..71176db8 100644
--- a/kig/kig/kig.h
+++ b/kig/kig/kig.h
@@ -49,6 +49,7 @@ class KRecentFilesAction;
class Kig : public KParts::MainWindow
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Default Constructor
@@ -114,7 +115,7 @@ class Kig : public KParts::MainWindow
private slots:
void fileNew();
void fileOpen();
- // Qt moc doesn't handle ifdef's, so i'm disabling it..
+ // TQt tqmoc doesn't handle ifdef's, so i'm disabling it..
// #ifdef KIG_DONT_USE_NEW_KMAINWINDOW_FEATURES
void optionsShowToolbar();
void optionsShowStatusbar();
diff --git a/kig/kig/kig_commands.cpp b/kig/kig/kig_commands.cpp
index d4668f55..d6b79805 100644
--- a/kig/kig/kig_commands.cpp
+++ b/kig/kig/kig_commands.cpp
@@ -97,7 +97,7 @@ KigCommand* KigCommand::removeCommand( KigPart& doc, const std::vector<ObjectHol
if ( os.size() == 1 )
text = os.back()->imp()->type()->removeAStatement();
else
- text = i18n( "Remove %1 Objects" ).arg( os.size() );
+ text = i18n( "Remove %1 Objects" ).tqarg( os.size() );
KigCommand* ret = new KigCommand( doc, text );
ret->addTask( new RemoveObjectsTask( os ) );
return ret;
@@ -109,7 +109,7 @@ KigCommand* KigCommand::addCommand( KigPart& doc, const std::vector<ObjectHolder
if ( os.size() == 1 )
text = os.back()->imp()->type()->addAStatement();
else
- text = i18n( "Add %1 Objects" ).arg( os.size() );
+ text = i18n( "Add %1 Objects" ).tqarg( os.size() );
KigCommand* ret = new KigCommand( doc, text );
ret->addTask( new AddObjectsTask( os ) );
return ret;
@@ -181,11 +181,11 @@ void ChangeObjectConstCalcerTask::execute( KigPart& doc )
{
mnewimp = mcalcer->switchImp( mnewimp );
- std::set<ObjectCalcer*> allchildren = getAllChildren( mcalcer.get() );
- std::vector<ObjectCalcer*> allchildrenvect( allchildren.begin(), allchildren.end() );
- allchildrenvect = calcPath( allchildrenvect );
- for ( std::vector<ObjectCalcer*>::iterator i = allchildrenvect.begin();
- i != allchildrenvect.end(); ++i )
+ std::set<ObjectCalcer*> alltqchildren = getAllChildren( mcalcer.get() );
+ std::vector<ObjectCalcer*> alltqchildrenvect( alltqchildren.begin(), alltqchildren.end() );
+ alltqchildrenvect = calcPath( alltqchildrenvect );
+ for ( std::vector<ObjectCalcer*>::iterator i = alltqchildrenvect.begin();
+ i != alltqchildrenvect.end(); ++i )
( *i )->calc( doc.document() );
}
@@ -274,7 +274,7 @@ class ChangeParentsAndTypeTask::Private
{
public:
ObjectTypeCalcer* o;
- std::vector<ObjectCalcer::shared_ptr> newparents;
+ std::vector<ObjectCalcer::shared_ptr> newtqparents;
const ObjectType* newtype;
};
@@ -284,13 +284,13 @@ ChangeParentsAndTypeTask::~ChangeParentsAndTypeTask()
}
ChangeParentsAndTypeTask::ChangeParentsAndTypeTask(
- ObjectTypeCalcer* o, const std::vector<ObjectCalcer*>& newparents,
+ ObjectTypeCalcer* o, const std::vector<ObjectCalcer*>& newtqparents,
const ObjectType* newtype )
: KigCommandTask(), d( new Private )
{
d->o = o;
- std::copy( newparents.begin(), newparents.end(),
- std::back_inserter( d->newparents ) );
+ std::copy( newtqparents.begin(), newtqparents.end(),
+ std::back_inserter( d->newtqparents ) );
d->newtype = newtype;
}
@@ -300,24 +300,24 @@ void ChangeParentsAndTypeTask::execute( KigPart& doc )
d->o->setType( d->newtype );
d->newtype = oldtype;
- std::vector<ObjectCalcer*> oldparentso = d->o->parents();
- std::vector<ObjectCalcer::shared_ptr> oldparents(
- oldparentso.begin(), oldparentso.end() );
- std::vector<ObjectCalcer*> newparents;
- for ( std::vector<ObjectCalcer::shared_ptr>::iterator i = d->newparents.begin();
- i != d->newparents.end(); ++i )
- newparents.push_back( i->get() );
- d->o->setParents( newparents );
- d->newparents = oldparents;
-
- for ( std::vector<ObjectCalcer*>::iterator i = newparents.begin(); i != newparents.end(); ++i )
+ std::vector<ObjectCalcer*> oldtqparentso = d->o->tqparents();
+ std::vector<ObjectCalcer::shared_ptr> oldtqparents(
+ oldtqparentso.begin(), oldtqparentso.end() );
+ std::vector<ObjectCalcer*> newtqparents;
+ for ( std::vector<ObjectCalcer::shared_ptr>::iterator i = d->newtqparents.begin();
+ i != d->newtqparents.end(); ++i )
+ newtqparents.push_back( i->get() );
+ d->o->setParents( newtqparents );
+ d->newtqparents = oldtqparents;
+
+ for ( std::vector<ObjectCalcer*>::iterator i = newtqparents.begin(); i != newtqparents.end(); ++i )
( *i )->calc( doc.document() );
d->o->calc( doc.document() );
- std::set<ObjectCalcer*> allchildren = getAllChildren( d->o );
- std::vector<ObjectCalcer*> allchildrenvect( allchildren.begin(), allchildren.end() );
- allchildrenvect = calcPath( allchildrenvect );
- for ( std::vector<ObjectCalcer*>::iterator i = allchildrenvect.begin();
- i != allchildrenvect.end(); ++i )
+ std::set<ObjectCalcer*> alltqchildren = getAllChildren( d->o );
+ std::vector<ObjectCalcer*> alltqchildrenvect( alltqchildren.begin(), alltqchildren.end() );
+ alltqchildrenvect = calcPath( alltqchildrenvect );
+ for ( std::vector<ObjectCalcer*>::iterator i = alltqchildrenvect.begin();
+ i != alltqchildrenvect.end(); ++i )
( *i )->calc( doc.document() );
}
diff --git a/kig/kig/kig_commands.h b/kig/kig/kig_commands.h
index 0dd7c93a..e9df77c1 100644
--- a/kig/kig/kig_commands.h
+++ b/kig/kig/kig_commands.h
@@ -44,6 +44,7 @@ class KigCommand
: public TQObject, public KNamedCommand
{
Q_OBJECT
+ TQ_OBJECT
class Private;
Private* d;
public:
@@ -58,7 +59,7 @@ public:
static KigCommand* addCommand( KigPart& doc, ObjectHolder* os );
/**
* make sure that when you delete something, you are also deleting
- * its parents. This class assumes you've done that.
+ * its tqparents. This class assumes you've done that.
* \ref KigDocument::delObjects() takes care of this for you.
*/
static KigCommand* removeCommand( KigPart& doc, const std::vector<ObjectHolder*>& os );
@@ -123,7 +124,7 @@ protected:
* this class monitors a set of DataObjects for changes and returns an
* appropriate ChangeObjectImpsCommand if necessary..
* E.g. MovingMode wants to move certain objects, so it monitors all
- * the parents of the explicitly moving objects:
+ * the tqparents of the explicitly moving objects:
* \code
* MonitorDataObjects mon( getAllParents( emo ) );
* \endcode
@@ -180,7 +181,7 @@ class ChangeParentsAndTypeTask
class Private;
Private* d;
public:
- ChangeParentsAndTypeTask( ObjectTypeCalcer* o, const std::vector<ObjectCalcer*>& newparents,
+ ChangeParentsAndTypeTask( ObjectTypeCalcer* o, const std::vector<ObjectCalcer*>& newtqparents,
const ObjectType* newtype );
~ChangeParentsAndTypeTask();
diff --git a/kig/kig/kig_document.cc b/kig/kig/kig_document.cc
index 884b41c5..04f1e7fa 100644
--- a/kig/kig/kig_document.cc
+++ b/kig/kig/kig_document.cc
@@ -69,7 +69,7 @@ std::vector<ObjectHolder*> KigDocument::whatAmIOn( const Coordinate& p, const Ki
for ( std::set<ObjectHolder*>::const_iterator i = mobjects.begin();
i != mobjects.end(); ++i )
{
- if(!(*i)->contains(p, w, mnightvision)) continue;
+ if(!(*i)->tqcontains(p, w, mnightvision)) continue;
if ( (*i)->imp()->inherits( PointImp::stype() ) ) ret.push_back( *i );
else
if ( !(*i)->imp()->inherits( PolygonImp::stype() ) ) curves.push_back( *i );
diff --git a/kig/kig/kig_part.cpp b/kig/kig/kig_part.cpp
index 1f891bb9..137d0096 100644
--- a/kig/kig/kig_part.cpp
+++ b/kig/kig/kig_part.cpp
@@ -67,9 +67,7 @@
#include <tqpaintdevicemetrics.h>
#include <tqsizepolicy.h>
#include <tqtimer.h>
-#if QT_VERSION >= 0x030100
#include <tqeventloop.h>
-#endif
using namespace std;
@@ -89,13 +87,13 @@ class SetCoordinateSystemAction
{
KigPart& md;
public:
- SetCoordinateSystemAction( KigPart& d, KActionCollection* parent );
+ SetCoordinateSystemAction( KigPart& d, KActionCollection* tqparent );
void slotActivated( int index );
};
SetCoordinateSystemAction::SetCoordinateSystemAction(
- KigPart& d, KActionCollection* parent )
- : KSelectAction( i18n( "&Set Coordinate System" ), 0, parent, "settings_set_coordinate_system" ),
+ KigPart& d, KActionCollection* tqparent )
+ : KSelectAction( i18n( "&Set Coordinate System" ), 0, tqparent, "settings_set_coordinate_system" ),
md( d )
{
setItems( CoordinateSystemFactory::names() );
@@ -114,7 +112,7 @@ class KigPrintDialogPage
: public KPrintDialogPage
{
public:
- KigPrintDialogPage( TQWidget* parent = 0, const char* name = 0 );
+ KigPrintDialogPage( TQWidget* tqparent = 0, const char* name = 0 );
~KigPrintDialogPage();
void getOptions( TQMap<TQString,TQString>& opts, bool );
@@ -126,8 +124,8 @@ private:
TQCheckBox *showaxes;
};
-KigPrintDialogPage::KigPrintDialogPage( TQWidget* parent, const char* name )
- : KPrintDialogPage( parent, name )
+KigPrintDialogPage::KigPrintDialogPage( TQWidget* tqparent, const char* name )
+ : KPrintDialogPage( tqparent, name )
{
setTitle( i18n( "Kig Options" ) );
@@ -167,10 +165,10 @@ bool KigPrintDialogPage::isValid( TQString& )
return true;
}
-KigPart::KigPart( TQWidget *parentWidget, const char *,
- TQObject *parent, const char *name,
+KigPart::KigPart( TQWidget *tqparentWidget, const char *,
+ TQObject *tqparent, const char *name,
const TQStringList& )
- : KParts::ReadWritePart( parent, name ),
+ : KParts::ReadWritePart( tqparent, name ),
mMode( 0 ), mdocument( new KigDocument() )
{
// we need an instance
@@ -179,7 +177,7 @@ KigPart::KigPart( TQWidget *parentWidget, const char *,
mMode = new NormalMode( *this );
// we need a widget, to actually show the document
- m_widget = new KigView(this, false, parentWidget, "kig_view");
+ m_widget = new KigView(this, false, tqparentWidget, "kig_view");
// notify the part that this is our internal widget
setWidget( m_widget );
@@ -260,17 +258,17 @@ void KigPart::setupActions()
KigExportManager::instance()->addMenuAction( this, m_widget->realWidget(),
actionCollection() );
- KAction* a = KStdAction::zoomIn( m_widget, TQT_SLOT( slotZoomIn() ),
+ KAction* a = KStdAction::zoomIn( TQT_TQOBJECT(m_widget), TQT_SLOT( slotZoomIn() ),
actionCollection() );
a->setToolTip( i18n( "Zoom in on the document" ) );
a->setWhatsThis( i18n( "Zoom in on the document" ) );
- a = KStdAction::zoomOut( m_widget, TQT_SLOT( slotZoomOut() ),
+ a = KStdAction::zoomOut( TQT_TQOBJECT(m_widget), TQT_SLOT( slotZoomOut() ),
actionCollection() );
a->setToolTip( i18n( "Zoom out of the document" ) );
a->setWhatsThis( i18n( "Zoom out of the document" ) );
- a = KStdAction::fitToPage( m_widget, TQT_SLOT( slotRecenterScreen() ),
+ a = KStdAction::fitToPage( TQT_TQOBJECT(m_widget), TQT_SLOT( slotRecenterScreen() ),
actionCollection() );
// grr.. why isn't there an icon for this..
a->setIconSet( TQIconSet( l->loadIcon( "view_fit_to_page", KIcon::Toolbar ) ) );
@@ -283,7 +281,7 @@ void KigPart::setupActions()
#endif
#endif
#ifdef KIG_PART_CPP_STD_FULLSCREEN_ACTION
- a = KStdAction::fullScreen( m_widget, TQT_SLOT( toggleFullScreen() ), actionCollection(), (TQWidget*)(widget()->parent()),"fullscreen" );
+ a = KStdAction::fullScreen( TQT_TQOBJECT(m_widget), TQT_SLOT( toggleFullScreen() ), actionCollection(), (TQWidget*)(widget()->tqparent()),"fullscreen" );
#else
tmp = l->loadIcon( "window_fullscreen", KIcon::Toolbar );
a = new KAction(
@@ -296,13 +294,13 @@ void KigPart::setupActions()
// TODO: an icon for this..
a = new KAction(
- i18n( "&Select Shown Area" ), "viewmagfit", 0, m_widget, TQT_SLOT( zoomRect() ),
+ i18n( "&Select Shown Area" ), "viewmagfit", 0, TQT_TQOBJECT(m_widget), TQT_SLOT( zoomRect() ),
actionCollection(), "view_select_shown_rect" );
a->setToolTip( i18n( "Select the area that you want to be shown in the window." ) );
a->setWhatsThis( i18n( "Select the area that you want to be shown in the window." ) );
a = new KAction(
- i18n( "S&elect Zoom Area" ), "viewmag", 0, m_widget, TQT_SLOT( zoomArea() ),
+ i18n( "S&elect Zoom Area" ), "viewmag", 0, TQT_TQOBJECT(m_widget), TQT_SLOT( zoomArea() ),
actionCollection(), "view_zoom_area" );
// a->setToolTip( i18n( "Select the area that you want to be shown in the window." ) );
// a->setWhatsThis( i18n( "Select the area that you want to be shown in the window." ) );
@@ -371,7 +369,7 @@ bool KigPart::openFile()
{
KMessageBox::sorry( widget(),
i18n( "The file \"%1\" you tried to open does not exist. "
- "Please verify that you entered the correct path." ).arg( m_file ),
+ "Please verify that you entered the correct path." ).tqarg( m_file ),
i18n( "File Not Found" ) );
return false;
};
@@ -380,7 +378,7 @@ bool KigPart::openFile()
// findByURL...
KMimeType::Ptr mimeType = KMimeType::findByPath ( m_file );
kdDebug() << k_funcinfo << "mimetype: " << mimeType->name() << endl;
- KigFilter* filter = KigFilters::instance()->find( mimeType->name() );
+ KigFilter* filter = KigFilters::instance()->tqfind( mimeType->name() );
if ( !filter )
{
// we don't support this mime type...
@@ -392,7 +390,7 @@ bool KigPart::openFile()
"question would be worth implementing support for, you can "
"always ask us nicely on mailto:toscano.pino@tiscali.it "
"or do the work yourself and send me a patch."
- ).arg(mimeType->name()),
+ ).tqarg(mimeType->name()),
i18n( "Format Not Supported" )
);
return false;
@@ -468,7 +466,7 @@ void KigPart::_addObject( ObjectHolder* o )
void KigPart::delObject( ObjectHolder* o )
{
- // we delete all children and their children etc. too...
+ // we delete all tqchildren and their tqchildren etc. too...
std::vector<ObjectHolder*> os;
os.push_back( o );
delObjects( os );
@@ -621,7 +619,7 @@ bool KigPart::internalSaveAs()
{
int ret = KMessageBox::warningContinueCancel( m_widget,
i18n( "The file \"%1\" already exists. Do you wish to overwrite it?" )
- .arg( file_name ), i18n( "Overwrite File?" ), i18n("Overwrite") );
+ .tqarg( file_name ), i18n( "Overwrite File?" ), i18n("Overwrite") );
if ( ret != KMessageBox::Continue )
{
return false;
@@ -637,11 +635,7 @@ void KigPart::runMode( KigMode* m )
setMode( m );
-#if QT_VERSION >= 0x030100
(void) kapp->eventLoop()->enterLoop();
-#else
- (void) kapp->enter_loop();
-#endif
setMode( prev );
redrawScreen();
@@ -652,11 +646,7 @@ void KigPart::doneMode( KigMode* d )
assert( d == mMode );
// pretend to use this var..
(void)d;
-#if QT_VERSION >= 0x030100
kapp->eventLoop()->exitLoop();
-#else
- kapp->exit_loop();
-#endif
}
void KigPart::actionRemoved( GUIAction* a, GUIUpdateToken& t )
@@ -932,7 +922,7 @@ extern "C" int convertToNative( const KURL& url, const TQCString& outfile )
KMimeType::Ptr mimeType = KMimeType::findByPath ( file );
kdDebug() << k_funcinfo << "mimetype: " << mimeType->name() << endl;
- KigFilter* filter = KigFilters::instance()->find( mimeType->name() );
+ KigFilter* filter = KigFilters::instance()->tqfind( mimeType->name() );
if ( !filter )
{
kdError() << "The file \"" << file << "\" is of a filetype not currently supported by Kig." << endl;
@@ -952,7 +942,7 @@ extern "C" int convertToNative( const KURL& url, const TQCString& outfile )
for ( std::vector<ObjectCalcer*>::iterator i = tmp.begin(); i != tmp.end(); ++i )
( *i )->calc( *doc );
- TQString out = ( outfile == "-" ) ? TQString::null : outfile;
+ TQString out = ( outfile == "-" ) ? TQString() : outfile;
bool success = KigFilters::instance()->save( *doc, out );
if ( !success )
{
diff --git a/kig/kig/kig_part.h b/kig/kig/kig_part.h
index 3245f38b..187f559e 100644
--- a/kig/kig/kig_part.h
+++ b/kig/kig/kig_part.h
@@ -61,12 +61,13 @@ class ScreenInfo;
class KigPart : public KParts::ReadWritePart
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Default constructor
*/
- KigPart( TQWidget* parentWidget, const char* widgetName,
- TQObject* parent = 0, const char* name = 0,
+ KigPart( TQWidget* tqparentWidget, const char* widgetName,
+ TQObject* tqparent = 0, const char* name = 0,
const TQStringList& = TQStringList()
);
diff --git a/kig/kig/kig_view.cpp b/kig/kig/kig_view.cpp
index fbf16517..9eda893b 100644
--- a/kig/kig/kig_view.cpp
+++ b/kig/kig/kig_view.cpp
@@ -55,10 +55,10 @@ kdbgstream& operator<< ( kdbgstream& s, const TQPoint& t )
KigWidget::KigWidget( KigPart* part,
KigView* view,
- TQWidget* parent,
+ TQWidget* tqparent,
const char* name,
bool fullscreen )
- : TQWidget( parent, name,
+ : TQWidget( tqparent, name,
fullscreen ? WStyle_Customize | WStyle_NoBorder : 0 ),
mpart( part ),
mview( view ),
@@ -69,8 +69,8 @@ KigWidget::KigWidget( KigPart* part,
{
part->addWidget(this);
- setFocusPolicy(ClickFocus);
- setBackgroundMode( Qt::NoBackground );
+ setFocusPolicy(TQ_ClickFocus);
+ setBackgroundMode( TQt::NoBackground );
setMouseTracking(true);
curPix.resize( size() );
@@ -123,7 +123,7 @@ void KigWidget::updateWidget( const std::vector<TQRect>& overlay )
#undef SHOW_OVERLAY_RECTS
#ifdef SHOW_OVERLAY_RECTS
TQPainter debug (this, this);
- debug.setPen(Qt::yellow);
+ debug.setPen(TQt::yellow);
#endif // SHOW_OVERLAY_RECTS
// we undo our old changes...
for ( std::vector<TQRect>::const_iterator i = oldOverlay.begin(); i != oldOverlay.end(); ++i )
@@ -193,7 +193,7 @@ void KigWidget::recenterScreen()
Rect KigWidget::matchScreenShape( const Rect& r ) const
{
- return r.matchShape( Rect::fromQRect( rect() ) );
+ return r.matchShape( Rect::fromTQRect( rect() ) );
}
void KigWidget::slotZoomIn()
@@ -231,7 +231,7 @@ void KigWidget::slotZoomOut()
void KigWidget::clearStillPix()
{
- stillPix.fill(Qt::white);
+ stillPix.fill(TQt::white);
oldOverlay.clear();
oldOverlay.push_back ( TQRect( TQPoint(0,0), size() ) );
}
@@ -245,7 +245,7 @@ void KigWidget::redrawScreen( const std::vector<ObjectHolder*>& selection, bool
// update the screen...
clearStillPix();
- KigPainter p( msi, &stillPix, mpart->document() );
+ KigPainter p( msi, TQT_TQPAINTDEVICE(&stillPix), mpart->document() );
p.drawGrid( mpart->document().coordinateSystem(), mpart->document().grid(),
mpart->document().axes() );
p.drawObjects( selection, true );
@@ -287,34 +287,34 @@ void KigWidget::updateScrollBars()
KigView::KigView( KigPart* part,
bool fullscreen,
- TQWidget* parent,
+ TQWidget* tqparent,
const char* name )
- : TQWidget( parent, name ),
- mlayout( 0 ), mrightscroll( 0 ), mbottomscroll( 0 ),
+ : TQWidget( tqparent, name ),
+ mtqlayout( 0 ), mrightscroll( 0 ), mbottomscroll( 0 ),
mupdatingscrollbars( false ),
mrealwidget( 0 ), mpart( part )
{
connect( part, TQT_SIGNAL( recenterScreen() ), this, TQT_SLOT( slotInternalRecenterScreen() ) );
- mlayout = new TQGridLayout( this, 2, 2 );
- mrightscroll = new TQScrollBar( Vertical, this, "Right Scrollbar" );
+ mtqlayout = new TQGridLayout( this, 2, 2 );
+ mrightscroll = new TQScrollBar(Qt::Vertical, this, "Right Scrollbar" );
// TODO: make this configurable...
mrightscroll->setTracking( true );
connect( mrightscroll, TQT_SIGNAL( valueChanged( int ) ),
this, TQT_SLOT( slotRightScrollValueChanged( int ) ) );
connect( mrightscroll, TQT_SIGNAL( sliderReleased() ),
this, TQT_SLOT( updateScrollBars() ) );
- mbottomscroll = new TQScrollBar( Horizontal, this, "Bottom Scrollbar" );
+ mbottomscroll = new TQScrollBar(Qt::Horizontal, this, "Bottom Scrollbar" );
connect( mbottomscroll, TQT_SIGNAL( valueChanged( int ) ),
this, TQT_SLOT( slotBottomScrollValueChanged( int ) ) );
connect( mbottomscroll, TQT_SIGNAL( sliderReleased() ),
this, TQT_SLOT( updateScrollBars() ) );
mrealwidget = new KigWidget( part, this, this, "Kig Widget", fullscreen );
- mlayout->addWidget( mbottomscroll, 1, 0 );
- mlayout->addWidget( mrealwidget, 0, 0 );
- mlayout->addWidget( mrightscroll, 0, 1 );
+ mtqlayout->addWidget( mbottomscroll, 1, 0 );
+ mtqlayout->addWidget( mrealwidget, 0, 0 );
+ mtqlayout->addWidget( mrightscroll, 0, 1 );
- resize( sizeHint() );
+ resize( tqsizeHint() );
mrealwidget->recenterScreen();
part->redrawScreen( mrealwidget );
updateScrollBars();
@@ -336,7 +336,7 @@ void KigView::updateScrollBars()
Rect er = mrealwidget->entireDocumentRect();
Rect sr = mrealwidget->screenInfo().shownRect();
- // we define the total rect to be the smallest rect that contains
+ // we define the total rect to be the smallest rect that tqcontains
// both er and sr...
er |= sr;
@@ -360,7 +360,7 @@ void KigView::updateScrollBars()
mrightscroll->setLineStep( (int)( sr.height() / pw / 10 ) );
mrightscroll->setPageStep( (int)( sr.height() / pw / 1.2 ) );
- // note that since Qt has a coordinate system with the lowest y
+ // note that since TQt has a coordinate system with the lowest y
// values at the top, and we have it the other way around ( i know i
// shouldn't have done this.. :( ), we invert the value that the
// scrollbar shows. This is inverted again in
@@ -443,7 +443,7 @@ const KigDocument& KigWidget::document() const
return mpart->document();
}
-TQSize KigWidget::sizeHint() const
+TQSize KigWidget::tqsizeHint() const
{
return TQSize( 630, 450 );
}
@@ -508,9 +508,9 @@ void KigView::toggleFullScreen()
{
mrealwidget->setFullScreen( ! mrealwidget->isFullScreen() );
if ( mrealwidget->isFullScreen() )
- topLevelWidget()->showFullScreen();
+ tqtopLevelWidget()->showFullScreen();
else
- topLevelWidget()->showNormal();
+ tqtopLevelWidget()->showNormal();
}
void KigWidget::setFullScreen( bool f )
@@ -545,7 +545,7 @@ void KigView::zoomRect()
void KigWidget::setShowingRect( const Rect& r )
{
- msi.setShownRect( r.matchShape( Rect::fromQRect( rect() ) ) );
+ msi.setShownRect( r.matchShape( Rect::fromTQRect( rect() ) ) );
}
void KigView::slotRecenterScreen()
@@ -568,7 +568,7 @@ void KigWidget::zoomArea()
KigInputDialog::getTwoCoordinates( i18n( "Select Zoom Area" ),
i18n( "Select the zoom area by entering the coordinates of "
"the upper left corner and the lower right corner." ) +
- TQString::fromLatin1("<br>") +
+ TQString::tqfromLatin1("<br>") +
mpart->document().coordinateSystem().coordinateFormatNoticeMarkup(),
this, &ok, mpart->document(), &tl, &br );
if ( ok )
diff --git a/kig/kig/kig_view.h b/kig/kig/kig_view.h
index a60e3ee5..4c167d7a 100644
--- a/kig/kig/kig_view.h
+++ b/kig/kig/kig_view.h
@@ -41,15 +41,16 @@ class KigView;
/**
* This class is the real widget showing the document. The other is a
- * wrapper, that has the scrollbars... I'm not using QScrollView
+ * wrapper, that has the scrollbars... I'm not using TQScrollView
* cause i've been having problems with that, and it's easier to do
* the work myself...
* Internally, this is basically a dumb class, which is manipulated by
* KigMode's. All events are forwarded to them.
*/
-class KigWidget : public QWidget
+class KigWidget : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
KigPart* mpart;
KigView* mview;
@@ -61,7 +62,7 @@ class KigWidget : public QWidget
void paintEvent( TQPaintEvent* e );
void wheelEvent( TQWheelEvent* e );
void resizeEvent( TQResizeEvent* );
- TQSize sizeHint() const;
+ TQSize tqsizeHint() const;
/**
* this is called to match a rect's dimensions to the dimensions of
@@ -104,7 +105,7 @@ public:
*/
KigWidget( KigPart* doc,
KigView* view,
- TQWidget* parent = 0,
+ TQWidget* tqparent = 0,
const char* name = 0,
bool fullscreen = false
);
@@ -224,16 +225,17 @@ public:
* most of its functionality to KigWidget...
*/
class KigView
- : public QWidget
+ : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
- TQGridLayout* mlayout;
+ TQGridLayout* mtqlayout;
TQScrollBar* mrightscroll;
TQScrollBar* mbottomscroll;
/**
- * apparently, TQScrollBar also emits its signals when you update it
+ * aptqparently, TQScrollBar also emits its signals when you update it
* manually, so we ignore them while we're in \ref updateScrollBars()...
*/
bool mupdatingscrollbars;
@@ -244,7 +246,7 @@ class KigView
public:
KigView( KigPart* part,
bool fullscreen = false,
- TQWidget* parent = 0,
+ TQWidget* tqparent = 0,
const char* name = 0
);
~KigView();
diff --git a/kig/misc/argsparser.cpp b/kig/misc/argsparser.cpp
index c2387970..9d722752 100644
--- a/kig/misc/argsparser.cpp
+++ b/kig/misc/argsparser.cpp
@@ -152,15 +152,15 @@ ArgsParser ArgsParser::without( const ObjectImpType* type ) const
return ArgsParser( ret );
}
-ArgsParser::spec ArgsParser::findSpec( const ObjectImp* obj, const Args& parents ) const
+ArgsParser::spec ArgsParser::findSpec( const ObjectImp* obj, const Args& tqparents ) const
{
spec ret;
ret.type = 0;
std::vector<bool> found( margs.size(), false );
- for ( Args::const_iterator o = parents.begin();
- o != parents.end(); ++o )
+ for ( Args::const_iterator o = tqparents.begin();
+ o != tqparents.end(); ++o )
{
for ( uint i = 0; i < margs.size(); ++i )
{
@@ -183,9 +183,9 @@ ArgsParser::spec ArgsParser::findSpec( const ObjectImp* obj, const Args& parents
}
const ObjectImpType* ArgsParser::impRequirement(
- const ObjectImp* o, const Args& parents ) const
+ const ObjectImp* o, const Args& tqparents ) const
{
- spec s = findSpec( o, parents );
+ spec s = findSpec( o, tqparents );
return s.type;
}
@@ -233,9 +233,9 @@ ArgsParser::~ArgsParser()
{
}
-bool ArgsParser::isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const
+bool ArgsParser::isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const
{
- spec s = findSpec( o, parents );
+ spec s = findSpec( o, tqparents );
return s.onOrThrough;
}
diff --git a/kig/misc/argsparser.h b/kig/misc/argsparser.h
index 001d9359..a3aff562 100644
--- a/kig/misc/argsparser.h
+++ b/kig/misc/argsparser.h
@@ -26,7 +26,7 @@ class ObjectImpType;
/**
* This class is meant to take care of checking the types of the
- * parents to ObjectCalcer's, and to put them in the correct order.
+ * tqparents to ObjectCalcer's, and to put them in the correct order.
* An ObjectType should construct an ArgsParser with a specification
* of the arguments it wants. This specification is given as an array
* of ArgsParser::spec structs. This struct contains a pointer to an
@@ -117,7 +117,7 @@ private:
*/
std::vector<spec> margs;
- spec findSpec( const ObjectImp* o, const Args& parents ) const;
+ spec findSpec( const ObjectImp* o, const Args& tqparents ) const;
public:
ArgsParser( const struct spec* args, int n );
ArgsParser( const std::vector<spec>& args );
@@ -137,7 +137,7 @@ public:
int check( const std::vector<ObjectCalcer*>& os ) const;
/**
* returns the usetext for the argument that o would be used for,
- * if sel were used as parents..
+ * if sel were used as tqparents..
* \p o should be in \p sel ...
*/
std::string usetext( const ObjectImp* o, const Args& sel ) const;
@@ -155,16 +155,16 @@ public:
/**
* returns the minimal ObjectImp ID that \p o needs to inherit in order
- * to be useful.. \p o should be part of \p parents .
+ * to be useful.. \p o should be part of \p tqparents .
*/
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
/**
- * Supposing that \p parents would be given as parents, this function
+ * Supposing that \p tqparents would be given as tqparents, this function
* returns whether the returned ObjectImp will be, by construction,
* on \p o ( if \p o is a curve ), or through \p o ( if \p o is a point ).
*/
- bool isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const;
+ bool isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const;
// Checks the args according to this args specification. If the
// objects should never have occurred, then an assertion failure
diff --git a/kig/misc/builtin_stuff.cc b/kig/misc/builtin_stuff.cc
index e162e7ac..432721cf 100644
--- a/kig/misc/builtin_stuff.cc
+++ b/kig/misc/builtin_stuff.cc
@@ -59,14 +59,14 @@ void setupBuiltinStuff()
I18N_NOOP( "A segment constructed from its start and end point" ),
"segment" );
ctors->add( c );
- actions->add( new ConstructibleAction( c, "objects_new_segment", Qt::Key_S ) );
+ actions->add( new ConstructibleAction( c, "objects_new_segment", TQt::Key_S ) );
// line by two points..
c = new SimpleObjectTypeConstructor(
LineABType::instance(), I18N_NOOP( "Line by Two Points" ),
I18N_NOOP( "A line constructed through two points"), "line" );
ctors->add( c );
- actions->add( new ConstructibleAction( c, "objects_new_linettp", Qt::Key_L ) );
+ actions->add( new ConstructibleAction( c, "objects_new_linettp", TQt::Key_L ) );
// ray by two points..
c = new SimpleObjectTypeConstructor(
@@ -74,7 +74,7 @@ void setupBuiltinStuff()
I18N_NOOP( "A half-line by its start point, and another point somewhere on it." ),
"ray" );
ctors->add( c );
- actions->add( new ConstructibleAction( c, "objects_new_ray", Qt::Key_R ) );
+ actions->add( new ConstructibleAction( c, "objects_new_ray", TQt::Key_R ) );
// perpendicular line
c = new SimpleObjectTypeConstructor(
@@ -98,7 +98,7 @@ void setupBuiltinStuff()
I18N_NOOP( "A circle constructed by its center and a point that pertains to it" ),
"circlebcp" );
ctors->add( c );
- actions->add( new ConstructibleAction( c, "objects_new_circlebcp", Qt::Key_C ) );
+ actions->add( new ConstructibleAction( c, "objects_new_circlebcp", TQt::Key_C ) );
c = new SimpleObjectTypeConstructor(
CircleBTPType::instance(), I18N_NOOP( "Circle by Three Points" ),
@@ -227,7 +227,7 @@ void setupBuiltinStuff()
I18N_NOOP( "An angle defined by three points" ),
"angle" );
ctors->add( c );
- actions->add( new ConstructibleAction( c, "objects_new_angle", Qt::Key_A ) );
+ actions->add( new ConstructibleAction( c, "objects_new_angle", TQt::Key_A ) );
c = new SimpleObjectTypeConstructor(
EquilateralHyperbolaB4PType::instance(),
@@ -260,7 +260,7 @@ void setupBuiltinStuff()
"bisection" );
m.merge( mpotp );
m.merge( mpos );
- actions->add( new ConstructibleAction( &m, "objects_new_midpoint", Qt::Key_M ) );
+ actions->add( new ConstructibleAction( &m, "objects_new_midpoint", TQt::Key_M ) );
};
c = new SimpleObjectTypeConstructor(
@@ -269,7 +269,7 @@ void setupBuiltinStuff()
I18N_NOOP( "Construct a vector from two given points." ),
"vector" );
ctors->add( c );
- actions->add( new ConstructibleAction( c, "objects_new_vector", Qt::Key_V ) );
+ actions->add( new ConstructibleAction( c, "objects_new_vector", TQt::Key_V ) );
c = new SimpleObjectTypeConstructor(
VectorSumType::instance(),
@@ -509,7 +509,7 @@ void setupBuiltinStuff()
ContainsTestType::instance(),
I18N_NOOP( "Contains Test" ),
I18N_NOOP( "Test whether a given curve contains a given point" ),
- "testcontains" );
+ "testtqcontains" );
ctors->add( c );
actions->add( new ConstructibleAction( c, "objects_new_containstest" ) );
@@ -562,12 +562,12 @@ void setupBuiltinStuff()
// the generic intersection constructor..
c = new GenericIntersectionConstructor();
ctors->add( c );
- actions->add( new ConstructibleAction( c, "objects_new_intersection", Qt::Key_I ) );
+ actions->add( new ConstructibleAction( c, "objects_new_intersection", TQt::Key_I ) );
// the generic tangent constructor
c = new TangentConstructor();
ctors->add( c );
- actions->add( new ConstructibleAction( c, "objects_new_tangent", Qt::Key_T ) );
+ actions->add( new ConstructibleAction( c, "objects_new_tangent", TQt::Key_T ) );
// the generic center of curvature constructor
c = new CocConstructor();
diff --git a/kig/misc/calcpaths.cc b/kig/misc/calcpaths.cc
index 1532715b..55787518 100644
--- a/kig/misc/calcpaths.cc
+++ b/kig/misc/calcpaths.cc
@@ -33,7 +33,7 @@
// I previously misunderstood the semantics of this function
// and thought that the os vector had to be completed with all
// the subtree generated by it. On the contrary, the os vector
-// contains *all* the objects that we want, we only have to
+// tqcontains *all* the objects that we want, we only have to
// reorder them. Now it *should* work, however we postpone
// activating this to a more proper moment
@@ -75,7 +75,7 @@ void localdfs( ObjectCalcer* obj,
std::vector<ObjectCalcer*>& all)
{
visited.push_back( obj );
- const std::vector<ObjectCalcer*> o = obj->children();
+ const std::vector<ObjectCalcer*> o = obj->tqchildren();
for ( std::vector<ObjectCalcer*>::const_iterator i = o.begin(); i != o.end(); ++i )
{
if ( std::find( visited.begin(), visited.end(), *i ) == visited.end() )
@@ -98,7 +98,7 @@ std::vector<ObjectCalcer*> calcPath( const std::vector<ObjectCalcer*>& os )
// the general idea here:
// first we build a new Objects variable. For every object in os,
- // we put all of its children at the end of it, and we do the same
+ // we put all of its tqchildren at the end of it, and we do the same
// for the ones we add..
// "all" is the Objects var we're building...
@@ -115,7 +115,7 @@ std::vector<ObjectCalcer*> calcPath( const std::vector<ObjectCalcer*>& os )
{
for ( std::vector<ObjectCalcer*>::const_iterator i = tmp.begin(); i != tmp.end(); ++i )
{
- const std::vector<ObjectCalcer*> o = (*i)->children();
+ const std::vector<ObjectCalcer*> o = (*i)->tqchildren();
std::copy( o.begin(), o.end(), std::back_inserter( all ) );
std::copy( o.begin(), o.end(), std::back_inserter( tmp2 ) );
};
@@ -124,7 +124,7 @@ std::vector<ObjectCalcer*> calcPath( const std::vector<ObjectCalcer*>& os )
};
// now we know that if all objects appear at least once after all of
- // their parents. So, we take all, and of every object, we remove
+ // their tqparents. So, we take all, and of every object, we remove
// every reference except the last one...
std::vector<ObjectCalcer*> ret;
ret.reserve( os.size() );
@@ -148,7 +148,7 @@ bool addBranch( const std::vector<ObjectCalcer*>& o, const ObjectCalcer* to, std
if ( *i == to )
rb = true;
else
- if ( addBranch( (*i)->children(), to, ret ) )
+ if ( addBranch( (*i)->tqchildren(), to, ret ) )
{
rb = true;
ret.push_back( *i );
@@ -163,7 +163,7 @@ std::vector<ObjectCalcer*> calcPath( const std::vector<ObjectCalcer*>& from, con
for ( std::vector<ObjectCalcer*>::const_iterator i = from.begin(); i != from.end(); ++i )
{
- (void) addBranch( (*i)->children(), to, all );
+ (void) addBranch( (*i)->tqchildren(), to, all );
};
std::vector<ObjectCalcer*> ret;
@@ -182,9 +182,9 @@ static void addNonCache( ObjectCalcer* o, std::vector<ObjectCalcer*>& ret )
ret.push_back( o );
else
{
- std::vector<ObjectCalcer*> parents = o->parents();
- for ( uint i = 0; i < parents.size(); ++i )
- addNonCache( parents[i], ret );
+ std::vector<ObjectCalcer*> tqparents = o->tqparents();
+ for ( uint i = 0; i < tqparents.size(); ++i )
+ addNonCache( tqparents[i], ret );
};
}
@@ -193,16 +193,16 @@ static bool visit( const ObjectCalcer* o, const std::vector<ObjectCalcer*>& from
// this function returns true if the visited object depends on one
// of the objects in from. If we encounter objects that are on the
// side of the tree path ( they do not depend on from themselves,
- // but their direct children do ), then we add them to ret.
+ // but their direct tqchildren do ), then we add them to ret.
if ( std::find( from.begin(), from.end(), o ) != from.end() ) return true;
- std::vector<bool> deps( o->parents().size(), false );
+ std::vector<bool> deps( o->tqparents().size(), false );
bool somedepend = false;
bool alldepend = true;
- std::vector<ObjectCalcer*> parents = o->parents();
- for ( uint i = 0; i < parents.size(); ++i )
+ std::vector<ObjectCalcer*> tqparents = o->tqparents();
+ for ( uint i = 0; i < tqparents.size(); ++i )
{
- bool v = visit( parents[i], from, ret );
+ bool v = visit( tqparents[i], from, ret );
somedepend |= v;
alldepend &= v;
deps[i] = v;
@@ -211,7 +211,7 @@ static bool visit( const ObjectCalcer* o, const std::vector<ObjectCalcer*>& from
{
for ( uint i = 0; i < deps.size(); ++i )
if ( ! deps[i] )
- addNonCache( parents[i], ret );
+ addNonCache( tqparents[i], ret );
};
return somedepend;
@@ -234,8 +234,8 @@ std::vector<ObjectCalcer*> getAllParents( const std::vector<ObjectCalcer*>& objs
std::set<ObjectCalcer*> next;
for ( std::set<ObjectCalcer*>::const_iterator i = cur.begin(); i != cur.end(); ++i )
{
- std::vector<ObjectCalcer*> parents = (*i)->parents();
- next.insert( parents.begin(), parents.end() );
+ std::vector<ObjectCalcer*> tqparents = (*i)->tqparents();
+ next.insert( tqparents.begin(), tqparents.end() );
};
ret.insert( next.begin(), next.end() );
@@ -253,16 +253,16 @@ std::vector<ObjectCalcer*> getAllParents( ObjectCalcer* obj )
bool isChild( const ObjectCalcer* o, const std::vector<ObjectCalcer*>& os )
{
- std::vector<ObjectCalcer*> parents = o->parents();
- std::set<ObjectCalcer*> cur( parents.begin(), parents.end() );
+ std::vector<ObjectCalcer*> tqparents = o->tqparents();
+ std::set<ObjectCalcer*> cur( tqparents.begin(), tqparents.end() );
while ( ! cur.empty() )
{
std::set<ObjectCalcer*> next;
for ( std::set<ObjectCalcer*>::const_iterator i = cur.begin(); i != cur.end(); ++i )
{
if ( std::find( os.begin(), os.end(), *i ) != os.end() ) return true;
- std::vector<ObjectCalcer*> parents = (*i)->parents();
- next.insert( parents.begin(), parents.end() );
+ std::vector<ObjectCalcer*> tqparents = (*i)->tqparents();
+ next.insert( tqparents.begin(), tqparents.end() );
};
cur = next;
};
@@ -289,8 +289,8 @@ std::set<ObjectCalcer*> getAllChildren( const std::vector<ObjectCalcer*> objs )
i != cur.end(); ++i )
{
ret.insert( *i );
- std::vector<ObjectCalcer*> children = (*i)->children();
- next.insert( children.begin(), children.end() );
+ std::vector<ObjectCalcer*> tqchildren = (*i)->tqchildren();
+ next.insert( tqchildren.begin(), tqchildren.end() );
};
cur = next;
};
diff --git a/kig/misc/calcpaths.h b/kig/misc/calcpaths.h
index 620558a3..3abf19a6 100644
--- a/kig/misc/calcpaths.h
+++ b/kig/misc/calcpaths.h
@@ -23,14 +23,14 @@
/**
* This function sorts \p os such that they're in the right order for
* calc()-ing. This means that child objects must appear after their
- * parents ( for you graph people, this is just a topological sort.. )
+ * tqparents ( for you graph people, this is just a topological sort.. )
*/
std::vector<ObjectCalcer*> calcPath( const std::vector<ObjectCalcer*>& os );
/**
* This is a different function for more or less the same purpose. It
* takes a few Objects, which are considered to have been calced
- * already. Then, it puts the necessary part of their children in the
+ * already. Then, it puts the necessary part of their tqchildren in the
* right order, so that calc()-ing correctly updates all of their data
* ( they're calc'ed in the right order, i mean... ). The objects in
* from are normally not included in the output, unless they appear
@@ -42,7 +42,7 @@ std::vector<ObjectCalcer*> calcPath( const std::vector<ObjectCalcer*>& from, con
* This function returns all objects on the side of the path through
* the dependency tree from from down to to. This means that we look
* for any objects that don't depend on any of the objects in from
- * themselves, but of which one of the direct children does. We need
+ * themselves, but of which one of the direct tqchildren does. We need
* this function for Locus stuff...
*/
std::vector<ObjectCalcer*> sideOfTreePath( const std::vector<ObjectCalcer*>& from, const ObjectCalcer* to );
diff --git a/kig/misc/common.cpp b/kig/misc/common.cpp
index b41b9284..83fdd077 100644
--- a/kig/misc/common.cpp
+++ b/kig/misc/common.cpp
@@ -347,7 +347,7 @@ Coordinate calcCircleRadicalStartPoint( const Coordinate& ca, const Coordinate&
}
double getDoubleFromUser( const TQString& caption, const TQString& label, double value,
- TQWidget* parent, bool* ok, double min, double max, int decimals )
+ TQWidget* tqparent, bool* ok, double min, double max, int decimals )
{
#ifdef KIG_USE_KDOUBLEVALIDATOR
KDoubleValidator vtor( min, max, decimals, 0, 0 );
@@ -357,12 +357,12 @@ double getDoubleFromUser( const TQString& caption, const TQString& label, double
#if KDE_IS_VERSION( 3, 1, 90 )
TQString input = KInputDialog::getText(
caption, label, KGlobal::locale()->formatNumber( value, decimals ),
- ok, parent, "getDoubleFromUserDialog", &vtor );
+ ok, tqparent, "getDoubleFromUserDialog", &vtor );
#else
TQString input =
KLineEditDlg::getText( caption, label,
KGlobal::locale()->formatNumber( value, decimals ),
- ok, parent, &vtor );
+ ok, tqparent, &vtor );
#endif
bool myok = true;
@@ -422,7 +422,7 @@ bool lineInRect( const Rect& r, const Coordinate& a, const Coordinate& b,
// if ( fabs( a.x - b.x ) <= 1e-7 )
// {
// // too small to be useful..
-// return r.contains( Coordinate( a.x, r.center().y ), miss );
+// return r.tqcontains( Coordinate( a.x, r.center().y ), miss );
// }
// in case we have a segment we need also to check for the case when
@@ -433,7 +433,7 @@ bool lineInRect( const Rect& r, const Coordinate& a, const Coordinate& b,
// - if the midpoint is in the rect than returning true is safe (also
// in the cases where we have a ray or a line)
- if ( r.contains( 0.5*( a + b ), miss ) ) return true;
+ if ( r.tqcontains( 0.5*( a + b ), miss ) ) return true;
Coordinate dir = b - a;
double m = dir.y / dir.x;
@@ -455,10 +455,10 @@ bool lineInRect( const Rect& r, const Coordinate& a, const Coordinate& b,
// intersection is not between the begin and end point.. ) and if
// the rect contains the intersection.. If it does, we have a winner..
return
- ( imp->contains( leftint, width, w ) && r.contains( leftint, miss ) ) ||
- ( imp->contains( rightint, width, w ) && r.contains( rightint, miss ) ) ||
- ( imp->contains( bottomint, width, w ) && r.contains( bottomint, miss ) ) ||
- ( imp->contains( topint, width, w ) && r.contains( topint, miss ) );
+ ( imp->tqcontains( leftint, width, w ) && r.tqcontains( leftint, miss ) ) ||
+ ( imp->tqcontains( rightint, width, w ) && r.tqcontains( rightint, miss ) ) ||
+ ( imp->tqcontains( bottomint, width, w ) && r.tqcontains( bottomint, miss ) ) ||
+ ( imp->tqcontains( topint, width, w ) && r.tqcontains( topint, miss ) );
}
bool operator==( const LineData& l, const LineData& r )
diff --git a/kig/misc/common.h b/kig/misc/common.h
index d1969df3..d4f388fb 100644
--- a/kig/misc/common.h
+++ b/kig/misc/common.h
@@ -52,7 +52,7 @@ extern const double double_inf;
*/
double getDoubleFromUser( const TQString& caption, const TQString& label, double value,
- TQWidget* parent, bool* ok, double min, double max, int decimals );
+ TQWidget* tqparent, bool* ok, double min, double max, int decimals );
/**
* Simple class representing a line. Used by various functions in Kig.
diff --git a/kig/misc/coordinate.cpp b/kig/misc/coordinate.cpp
index f2c272f2..86cf8eab 100644
--- a/kig/misc/coordinate.cpp
+++ b/kig/misc/coordinate.cpp
@@ -25,7 +25,7 @@
using namespace std;
-Coordinate Coordinate::fromQPoint( const TQPoint& p )
+Coordinate Coordinate::fromTQPoint( const TQPoint& p )
{
return Coordinate( p.x(), p.y() );
}
@@ -159,10 +159,10 @@ const Coordinate Coordinate::normalize( double l ) const
const Coordinate Coordinate::round() const
{
- return Coordinate( qRound( x ), qRound( y ) );
+ return Coordinate( tqRound( x ), tqRound( y ) );
}
-TQPoint Coordinate::toQPoint() const
+TQPoint Coordinate::toTQPoint() const
{
Coordinate t = round();
return TQPoint( (int) t.x, (int) t.y );
diff --git a/kig/misc/coordinate.h b/kig/misc/coordinate.h
index 8e19eb5e..745d64a7 100644
--- a/kig/misc/coordinate.h
+++ b/kig/misc/coordinate.h
@@ -33,7 +33,7 @@ class kdbgstream;
class Coordinate
{
public:
- static Coordinate fromQPoint( const TQPoint& p );
+ static Coordinate fromTQPoint( const TQPoint& p );
/** Constructor. Construct a new Coordinate, with a given x and y
* value.
@@ -102,7 +102,7 @@ public:
* x/y ratio untouched...
*/
const Coordinate normalize( double length = 1 ) const;
- TQPoint toQPoint() const;
+ TQPoint toTQPoint() const;
Coordinate& operator= ( const Coordinate& c );
/** Add. Add c to this Coordinate
diff --git a/kig/misc/coordinate_system.cpp b/kig/misc/coordinate_system.cpp
index 859ed81d..deefe954 100644
--- a/kig/misc/coordinate_system.cpp
+++ b/kig/misc/coordinate_system.cpp
@@ -40,7 +40,7 @@
#include <math.h>
class CoordinateValidator
- : public QValidator
+ : public TQValidator
{
bool mpolar;
#ifdef KIG_USE_KDOUBLEVALIDATOR
@@ -80,7 +80,7 @@ TQValidator::State CoordinateValidator::validate( TQString & input, int & pos )
if( tinput[tinput.length() - 1 ] == ' ' ) tinput.truncate( tinput.length() - 1 );
if ( tinput[0] == '(' ) tinput = tinput.mid( 1 );
if( tinput[0] == ' ' ) tinput = tinput.mid( 1 );
- int scp = tinput.find( ';' );
+ int scp = tinput.tqfind( ';' );
if ( scp == -1 ) return mdv.validate( tinput, pos ) == Invalid ? Invalid : Valid;
else
{
@@ -101,34 +101,34 @@ TQValidator::State CoordinateValidator::validate( TQString & input, int & pos )
void CoordinateValidator::fixup( TQString & input ) const
{
- int nsc = input.contains( ';' );
+ int nsc = input.tqcontains( ';' );
if ( nsc > 1 )
{
// where is the second ';'
- int i = input.find( ';' );
- i = input.find( ';', i );
+ int i = input.tqfind( ';' );
+ i = input.tqfind( ';', i );
input = input.left( i );
};
// now the string has at most one semicolon left..
- int sc = input.find( ';' );
+ int sc = input.tqfind( ';' );
if ( sc == -1 )
{
sc = input.length();
KLocale* l = KGlobal::locale();
if ( mpolar )
- input.append( TQString::fromLatin1( ";" ) + l->positiveSign() +
- TQString::fromLatin1( "0°" ) );
+ input.append( TQString::tqfromLatin1( ";" ) + l->positiveSign() +
+ TQString::tqfromLatin1( "0°" ) );
else
- input.append( TQString::fromLatin1( ";" ) + l->positiveSign() +
- TQString::fromLatin1( "0" ) + l->decimalSymbol() +
- TQString::fromLatin1( "0" ) );
+ input.append( TQString::tqfromLatin1( ";" ) + l->positiveSign() +
+ TQString::tqfromLatin1( "0" ) + l->decimalSymbol() +
+ TQString::tqfromLatin1( "0" ) );
};
mre.exactMatch( input );
TQString ds1 = mre.cap( 1 );
mdv.fixup( ds1 );
TQString ds2 = mre.cap( 2 );
mdv.fixup( ds2 );
- input = ds1 + TQString::fromLatin1( "; " ) + ds2;
+ input = ds1 + TQString::tqfromLatin1( "; " ) + ds2;
}
EuclideanCoords::EuclideanCoords()
@@ -146,7 +146,7 @@ TQString EuclideanCoords::fromScreen( const Coordinate& p, const KigDocument& d
int l = kigMax( 0, (int) ( 3 - log10( m ) ) );
TQString xs = KGlobal::locale()->formatNumber( p.x, l );
TQString ys = KGlobal::locale()->formatNumber( p.y, l );
- return TQString::fromLatin1( "( %1; %2 )" ).arg( xs ).arg( ys );
+ return TQString::tqfromLatin1( "( %1; %2 )" ).tqarg( xs ).tqarg( ys );
}
Coordinate EuclideanCoords::toScreen(const TQString& s, bool& ok) const
@@ -255,7 +255,7 @@ void EuclideanCoords::drawGrid( KigPainter& p, bool showgrid, bool showaxes ) co
/****** the axes ******/
if ( showaxes )
{
- p.setPen( TQPen( Qt::gray, 1, Qt::SolidLine ) );
+ p.setPen( TQPen( TQt::gray, 1, TQt::SolidLine ) );
// x axis
p.drawSegment( Coordinate( hmin, 0 ), Coordinate( hmax, 0 ) );
// y axis
@@ -286,8 +286,8 @@ void EuclideanCoords::drawGrid( KigPainter& p, bool showgrid, bool showaxes ) co
);
};
// arrows on the ends of the axes...
- p.setPen( TQPen( Qt::gray, 1, Qt::SolidLine ) );
- p.setBrush( TQBrush( Qt::gray ) );
+ p.setPen( TQPen( TQt::gray, 1, TQt::SolidLine ) );
+ p.setBrush( TQBrush( TQt::gray ) );
std::vector<Coordinate> a;
// the arrow on the right end of the X axis...
@@ -354,7 +354,7 @@ TQString PolarCoords::fromScreen( const Coordinate& pt, const KigDocument& d ) c
TQString rs = KGlobal::locale()->formatNumber( r, l );
TQString ts = KGlobal::locale()->formatNumber( theta, 0 );
- return TQString::fromLatin1("( %1; %2° )").arg( rs ).arg( ts );
+ return TQString::tqfromLatin1("( %1; %2° )").tqarg( rs ).tqarg( ts );
}
TQString PolarCoords::coordinateFormatNotice() const
@@ -450,7 +450,7 @@ void PolarCoords::drawGrid( KigPainter& p, bool showgrid, bool showaxes ) const
/****** the axes ******/
if ( showaxes )
{
- p.setPen( TQPen( Qt::gray, 1, Qt::SolidLine ) );
+ p.setPen( TQPen( TQt::gray, 1, TQt::SolidLine ) );
// x axis
p.drawSegment( Coordinate( hmin, 0 ), Coordinate( hmax, 0 ) );
// y axis
@@ -482,8 +482,8 @@ void PolarCoords::drawGrid( KigPainter& p, bool showgrid, bool showaxes ) const
);
};
// arrows on the ends of the axes...
- p.setPen( TQPen( Qt::gray, 1, Qt::SolidLine ) );
- p.setBrush( TQBrush( Qt::gray ) );
+ p.setPen( TQPen( TQt::gray, 1, TQt::SolidLine ) );
+ p.setBrush( TQBrush( TQt::gray ) );
std::vector<Coordinate> a;
// the arrow on the right end of the X axis...
@@ -575,7 +575,7 @@ TQString CoordinateSystemFactory::setCoordinateSystemStatement( int id )
return i18n( "Set Polar Coordinate System" );
default:
assert( false );
- return TQString::null;
+ return TQString();
}
}
@@ -608,15 +608,15 @@ Coordinate EuclideanCoords::snapToGrid( const Coordinate& c,
const double hgraphmin = ceil( hmin / hd) * hd;
const double vgraphmin = ceil( vmin / vd ) * vd;
- const double nx = qRound( ( c.x - hgraphmin ) / hd ) * hd + hgraphmin;
- const double ny = qRound( ( c.y - vgraphmin ) / vd ) * vd + vgraphmin;
+ const double nx = tqRound( ( c.x - hgraphmin ) / hd ) * hd + hgraphmin;
+ const double ny = tqRound( ( c.y - vgraphmin ) / vd ) * vd + vgraphmin;
return Coordinate( nx, ny );
}
Coordinate PolarCoords::snapToGrid( const Coordinate& c,
const KigWidget& w ) const
{
- // we reuse the drawGrid code to find
+ // we reuse the drawGrid code to tqfind
// we multiply by sqrt( 2 ) cause we don't want to miss circles in
// the corners, that intersect with the axes outside of the
@@ -643,7 +643,7 @@ Coordinate PolarCoords::snapToGrid( const Coordinate& c,
double d = kigMin( hd, vd );
double dist = c.length();
- double ndist = qRound( dist / d ) * d;
+ double ndist = tqRound( dist / d ) * d;
return c.normalize( ndist );
}
diff --git a/kig/misc/coordinate_system.h b/kig/misc/coordinate_system.h
index 44eaf6d6..f6c8cc7d 100644
--- a/kig/misc/coordinate_system.h
+++ b/kig/misc/coordinate_system.h
@@ -59,7 +59,7 @@ public:
* KigWidget... )
*/
class CoordinateSystem
- : public Qt
+ : public TQt
{
public:
CoordinateSystem();
diff --git a/kig/misc/cubic-common.cc b/kig/misc/cubic-common.cc
index 029f1194..6bdf3aca 100644
--- a/kig/misc/cubic-common.cc
+++ b/kig/misc/cubic-common.cc
@@ -486,7 +486,7 @@ const CubicCartesianData calcCubicTransformation (
// assert (fabs(b[0][1][2] - b[1][2][0]) < 1e-8); // test a couple of cases
// assert (fabs(b[0][1][1] - b[1][1][0]) < 1e-8);
- // apparently, the above assertions are wrong ( due to rounding
+ // aptqparently, the above assertions are wrong ( due to rounding
// errors, Maurizio and I hope :) ), so since the symmetry is not
// present, we just take the sum of the parts of the matrix elements
// that should be symmetric, instead of taking one of them, and
diff --git a/kig/misc/guiaction.cc b/kig/misc/guiaction.cc
index c9435d2b..d17501c2 100644
--- a/kig/misc/guiaction.cc
+++ b/kig/misc/guiaction.cc
@@ -81,19 +81,19 @@ void ConstructibleAction::act( KigPart& d )
KigGUIAction::KigGUIAction( GUIAction* act,
KigPart& doc,
- TQObject* parent )
+ TQObject* tqparent )
: KAction( act->descriptiveName(),
doc.instance()->iconLoader()->loadIcon(
act->iconFileName(), KIcon::Toolbar, 0, KIcon::DefaultState, 0L, true ),
act->shortcut(),
0, 0, // no slot connection
- parent, act->actionName() ),
+ tqparent, act->actionName() ),
mact( act ),
mdoc( doc )
{
setWhatsThis( act->description() );
TQString tooltip = act->descriptiveName();
- tooltip.replace( TQRegExp( "&&" ), "&" );
+ tooltip.tqreplace( TQRegExp( "&&" ), "&" );
setToolTip( tooltip );
}
@@ -136,7 +136,7 @@ const char* ConstructPointAction::actionName() const
int ConstructPointAction::shortcut() const
{
- return Qt::Key_P;
+ return TQt::Key_P;
}
void ConstructPointAction::act( KigPart& d )
@@ -223,7 +223,7 @@ void AddFixedPointAction::act( KigPart& doc )
KigInputDialog::getCoordinate(
i18n( "Fixed Point" ),
i18n( "Enter the coordinates for the new point." ) +
- TQString::fromLatin1( "<br>" ) +
+ TQString::tqfromLatin1( "<br>" ) +
doc.document().coordinateSystem().coordinateFormatNoticeMarkup(),
doc.widget(), &ok, doc.document(), &c );
if ( ! ok ) return;
@@ -252,12 +252,12 @@ int ConstructibleAction::shortcut() const
int ConstructTextLabelAction::shortcut() const
{
- return Qt::Key_B;
+ return TQt::Key_B;
}
int AddFixedPointAction::shortcut() const
{
- return Qt::Key_F;
+ return TQt::Key_F;
}
#if 0
@@ -272,7 +272,7 @@ TestAction::~TestAction()
TQString TestAction::description() const
{
- return TQString::fromLatin1( "Test stuff !!!" );
+ return TQString::tqfromLatin1( "Test stuff !!!" );
}
TQCString TestAction::iconFileName() const
@@ -282,7 +282,7 @@ TQCString TestAction::iconFileName() const
TQString TestAction::descriptiveName() const
{
- return TQString::fromLatin1( "Test stuff !!!" );
+ return TQString::tqfromLatin1( "Test stuff !!!" );
}
const char* TestAction::actionName() const
@@ -297,7 +297,7 @@ void TestAction::act( KigPart& doc )
Object* constantpoint = ObjectFactory::instance()->fixedPoint( Coordinate( -1, -1 ) );
constantpoint->calc( doc );
- Object* codeobject = new DataObject( new StringImp( TQString::fromLatin1( script ) ) );
+ Object* codeobject = new DataObject( new StringImp( TQString::tqfromLatin1( script ) ) );
Object* compiledcode = new RealObject( PythonCompileType::instance(), Objects( codeobject ) );
compiledcode->calc( doc );
diff --git a/kig/misc/guiaction.h b/kig/misc/guiaction.h
index e2e3de54..e9595605 100644
--- a/kig/misc/guiaction.h
+++ b/kig/misc/guiaction.h
@@ -35,12 +35,13 @@ class KigGUIAction
: public KAction
{
Q_OBJECT
+ TQ_OBJECT
GUIAction* mact;
KigPart& mdoc;
public:
KigGUIAction( GUIAction* act,
KigPart& doc,
- TQObject* parent );
+ TQObject* tqparent );
void slotActivated();
GUIAction* guiAction();
diff --git a/kig/misc/kigfiledialog.cc b/kig/misc/kigfiledialog.cc
index 2d7ea08f..cdfe2196 100644
--- a/kig/misc/kigfiledialog.cc
+++ b/kig/misc/kigfiledialog.cc
@@ -25,8 +25,8 @@
#include <kmessagebox.h>
KigFileDialog::KigFileDialog( const TQString& startDir, const TQString& filter,
- const TQString& caption, TQWidget* parent )
- : KFileDialog( startDir, filter, parent, "kigfiledialog", true ),
+ const TQString& caption, TQWidget* tqparent )
+ : KFileDialog( startDir, filter, tqparent, "kigfiledialog", true ),
mow( 0L )
{
setCaption( caption );
@@ -53,7 +53,7 @@ void KigFileDialog::accept()
{
int ret = KMessageBox::warningContinueCancel( this,
i18n( "The file \"%1\" already exists. Do you wish to overwrite it?" )
- .arg( sFile ), i18n( "Overwrite File?" ), i18n("Overwrite") );
+ .tqarg( sFile ), i18n( "Overwrite File?" ), i18n("Overwrite") );
if ( ret != KMessageBox::Continue )
{
KFileDialog::reject();
diff --git a/kig/misc/kigfiledialog.h b/kig/misc/kigfiledialog.h
index 8c243131..5fb65949 100644
--- a/kig/misc/kigfiledialog.h
+++ b/kig/misc/kigfiledialog.h
@@ -28,6 +28,7 @@ class KigFileDialog
: public KFileDialog
{
Q_OBJECT
+ TQ_OBJECT
private:
/**
@@ -45,17 +46,17 @@ public:
* documentation of KFileDialog for more help about this
* \param filter the filter for the file dialog
* \param caption the caption of this file dialog
- * \param parent the parent for this file dialog
+ * \param tqparent the tqparent for this file dialog
*/
KigFileDialog( const TQString& startDir, const TQString& filter,
- const TQString& caption, TQWidget *parent );
+ const TQString& caption, TQWidget *tqparent );
/**
* Use this to set the widget containing the options of eg an export filter.
* The option widget will be popped up in a dialog right after the user
* presses OK and before the dialog is closed.
*
- * You can construct the option widget with no parent, as it will be
+ * You can construct the option widget with no tqparent, as it will be
* reparented.
*
* \param w the option widget
diff --git a/kig/misc/kiginputdialog.cc b/kig/misc/kiginputdialog.cc
index ea0aeb66..de8f691d 100644
--- a/kig/misc/kiginputdialog.cc
+++ b/kig/misc/kiginputdialog.cc
@@ -65,8 +65,8 @@ KigInputDialogPrivate::KigInputDialogPrivate()
}
KigInputDialog::KigInputDialog( const TQString& caption, const TQString& label,
- TQWidget* parent, const KigDocument& doc, Coordinate* c1, Coordinate* c2 )
- : KDialogBase( parent, "kigdialog", true, caption, Ok|Cancel, Cancel, true ),
+ TQWidget* tqparent, const KigDocument& doc, Coordinate* c1, Coordinate* c2 )
+ : KDialogBase( tqparent, "kigdialog", true, caption, Ok|Cancel, Cancel, true ),
d( new KigInputDialogPrivate() )
{
d->m_coord1 = c1 ? Coordinate( *c1 ) : Coordinate::invalidCoord();
@@ -84,8 +84,8 @@ KigInputDialog::KigInputDialog( const TQString& caption, const TQString& label,
d->m_textEdit = new KTextEdit( frame );
d->m_textEdit->setText( label );
d->m_textEdit->setReadOnly( true );
- d->m_textEdit->setFocusPolicy( NoFocus );
-// d->m_textEdit->setAlignment( d->m_textEdit->alignment() | Qt::WordBreak );
+ d->m_textEdit->setFocusPolicy( TQ_NoFocus );
+// d->m_textEdit->tqsetAlignment( d->m_textEdit->tqalignment() | TQt::WordBreak );
d->m_textEdit->setFrameStyle( TQFrame::NoFrame );
mainlay->addWidget( d->m_textEdit );
@@ -121,8 +121,8 @@ KigInputDialog::KigInputDialog( const TQString& caption, const TQString& label,
enableButtonOK( ok );
}
-KigInputDialog::KigInputDialog( TQWidget* parent, const Goniometry& g )
- : KDialogBase( parent, "kigdialog", true, i18n( "Set Angle Size" ), Ok|Cancel, Cancel, true ),
+KigInputDialog::KigInputDialog( TQWidget* tqparent, const Goniometry& g )
+ : KDialogBase( tqparent, "kigdialog", true, i18n( "Set Angle Size" ), Ok|Cancel, Cancel, true ),
d( new KigInputDialogPrivate() )
{
d->m_gonio = g;
@@ -171,7 +171,7 @@ KigInputDialog::KigInputDialog( TQWidget* parent, const Goniometry& g )
void KigInputDialog::keyPressEvent( TQKeyEvent* e )
{
- if ( ( e->key() == Qt::Key_Return ) && ( e->state() == 0 ) )
+ if ( ( e->key() == TQt::Key_Return ) && ( e->state() == 0 ) )
{
if ( actionButton( Ok )->isEnabled() )
{
@@ -180,7 +180,7 @@ void KigInputDialog::keyPressEvent( TQKeyEvent* e )
return;
}
}
- else if ( ( e->key() == Qt::Key_Escape ) && ( e->state() == 0 ) )
+ else if ( ( e->key() == TQt::Key_Escape ) && ( e->state() == 0 ) )
{
actionButton( Cancel )->animateClick();
e->accept();
@@ -247,16 +247,16 @@ Goniometry KigInputDialog::goniometry() const
}
void KigInputDialog::getCoordinate( const TQString& caption, const TQString& label,
- TQWidget* parent, bool* ok, const KigDocument& doc, Coordinate* cvalue )
+ TQWidget* tqparent, bool* ok, const KigDocument& doc, Coordinate* cvalue )
{
- getTwoCoordinates( caption, label, parent, ok, doc, cvalue, 0 );
+ getTwoCoordinates( caption, label, tqparent, ok, doc, cvalue, 0 );
}
void KigInputDialog::getTwoCoordinates( const TQString& caption, const TQString& label,
- TQWidget* parent, bool* ok, const KigDocument& doc, Coordinate* cvalue,
+ TQWidget* tqparent, bool* ok, const KigDocument& doc, Coordinate* cvalue,
Coordinate* cvalue2 )
{
- KigInputDialog dlg( caption, label, parent, doc, cvalue, cvalue2 );
+ KigInputDialog dlg( caption, label, tqparent, doc, cvalue, cvalue2 );
*ok = ( dlg.exec() == Accepted );
@@ -273,9 +273,9 @@ void KigInputDialog::getTwoCoordinates( const TQString& caption, const TQString&
}
-Goniometry KigInputDialog::getAngle( TQWidget* parent, bool* ok, const Goniometry& g )
+Goniometry KigInputDialog::getAngle( TQWidget* tqparent, bool* ok, const Goniometry& g )
{
- KigInputDialog dlg( parent, g );
+ KigInputDialog dlg( tqparent, g );
*ok = ( dlg.exec() == Accepted );
diff --git a/kig/misc/kiginputdialog.h b/kig/misc/kiginputdialog.h
index c7b29e73..60f2ba54 100644
--- a/kig/misc/kiginputdialog.h
+++ b/kig/misc/kiginputdialog.h
@@ -41,13 +41,14 @@ class KigInputDialog
: KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
private:
- KigInputDialog( const TQString& caption, const TQString& label, TQWidget* parent,
+ KigInputDialog( const TQString& caption, const TQString& label, TQWidget* tqparent,
const KigDocument& doc, Coordinate* c1, Coordinate* c2 );
- KigInputDialog( TQWidget* parent, const Goniometry& g );
+ KigInputDialog( TQWidget* tqparent, const Goniometry& g );
virtual void keyPressEvent( TQKeyEvent* e );
@@ -69,7 +70,7 @@ public:
*
* \param caption caption of the dialog
* \param label text of the label of the dialog
- * \param parent parent of the dialog widget
+ * \param tqparent tqparent of the dialog widget
* \param ok it will be set to true if the user pressed Ok after inserting a
* well-formatted Coordinate
* \param doc the actual Kig document
@@ -79,14 +80,14 @@ public:
* displayed as initial value of the correspondenting text edit
*/
static void getCoordinate( const TQString& caption, const TQString& label,
- TQWidget* parent, bool* ok, const KigDocument& doc, Coordinate* cvalue );
+ TQWidget* tqparent, bool* ok, const KigDocument& doc, Coordinate* cvalue );
/**
* Static convenience function to get two Coordinates at once from the user.
*
* \param caption caption of the dialog
* \param label text of the label of the dialog
- * \param parent parent of the dialog widget
+ * \param tqparent tqparent of the dialog widget
* \param ok it will be set to true if the user pressed Ok after inserting
* well-formatted Coordinates
* \param doc the actual Kig document
@@ -102,14 +103,14 @@ public:
* the text edit representing the second Coordinate.
*/
static void getTwoCoordinates( const TQString& caption, const TQString& label,
- TQWidget* parent, bool* ok, const KigDocument& doc, Coordinate* cvalue,
+ TQWidget* tqparent, bool* ok, const KigDocument& doc, Coordinate* cvalue,
Coordinate* cvalue2 );
/**
* Static convenience function to get an angle incapsulated in a Goniometry
* class.
*
- * \param parent parent of the dialog widget
+ * \param tqparent tqparent of the dialog widget
* \param ok it will be set to true if the user pressed Ok after inserting a
* well-formatted angle
* \param g the Goniometry class containing the original angle we are going
@@ -117,7 +118,7 @@ public:
*
* \return a Goniometry class containing the new angle
*/
- static Goniometry getAngle( TQWidget* parent, bool* ok, const Goniometry& g );
+ static Goniometry getAngle( TQWidget* tqparent, bool* ok, const Goniometry& g );
};
#endif
diff --git a/kig/misc/kigpainter.cpp b/kig/misc/kigpainter.cpp
index 98594ecb..95be1837 100644
--- a/kig/misc/kigpainter.cpp
+++ b/kig/misc/kigpainter.cpp
@@ -42,18 +42,18 @@
KigPainter::KigPainter( const ScreenInfo& si, TQPaintDevice* device,
const KigDocument& doc, bool no )
: mP ( device ),
- color( Qt::blue ),
+ color( TQt::blue ),
style( Qt::SolidLine ),
pointstyle( 0 ),
width( -1 ),
brushStyle( Qt::NoBrush ),
- brushColor( Qt::blue ),
+ brushColor( TQt::blue ),
mdoc( doc ),
msi( si ),
mNeedOverlay( no ),
overlayenlarge( 0 )
{
- mP.setBackgroundColor( Qt::white );
+ mP.setBackgroundColor( TQt::white );
}
KigPainter::~KigPainter()
@@ -136,7 +136,7 @@ void KigPainter::drawFatPoint( const Coordinate& p )
Rect r( tl, br );
TQRect qr = toScreen( r );
mP.drawRect( qr );
- mP.fillRect( qr, TQBrush( color, Qt::SolidPattern ) );
+ mP.fillRect( qr, TQBrush( color, TQt::SolidPattern ) );
if( mNeedOverlay ) mOverlay.push_back( qr );
break;
}
@@ -196,7 +196,7 @@ void KigPainter::drawText( const Rect p, const TQString s, int textFlags, int le
void KigPainter::textOverlay( const TQRect& r, const TQString s, int textFlags, int len )
{
- // kdDebug() << Rect::fromQRect( mP.boundingRect( r, textFlags, s, len ) ) << endl;
+ // kdDebug() << Rect::fromTQRect( mP.boundingRect( r, textFlags, s, len ) ) << endl;
TQRect newr( mP.boundingRect( r, textFlags, s, len ) );
newr.setWidth( newr.width() + 4 );
newr.setHeight( newr.height() + 4 );
@@ -218,7 +218,7 @@ void KigPainter::setColor( const TQColor& c )
mP.setPen( TQPen( color, width == -1 ? 1 : width, style ) );
}
-void KigPainter::setStyle( const PenStyle c )
+void KigPainter::setStyle( const Qt::PenStyle c )
{
style = c;
mP.setPen( TQPen( color, width == -1 ? 1 : width, style ) );
@@ -251,7 +251,7 @@ void KigPainter::setBrush( const TQBrush& b )
mP.setBrush( b );
}
-void KigPainter::setBrushStyle( const BrushStyle c )
+void KigPainter::setBrushStyle( const Qt::BrushStyle c )
{
brushStyle = c;
mP.setBrush( TQBrush( brushColor, brushStyle ) );
@@ -292,7 +292,7 @@ void KigPainter::drawPolygon( const std::vector<TQPoint>& pts,
TQBrush oldbrush = mP.brush();
setBrush( TQBrush( color, Dense4Pattern ) );
setPen( Qt::NoPen );
- // i know this isn't really fast, but i blame it all on Qt with its
+ // i know this isn't really fast, but i blame it all on TQt with its
// stupid container classes... what's wrong with the STL ?
TQPointArray t( pts.size() );
int c = 0;
@@ -300,7 +300,7 @@ void KigPainter::drawPolygon( const std::vector<TQPoint>& pts,
{
t.putPoints( c++, 1, i->x(), i->y() );
};
- mP.drawPolygon( t, winding, index, npoints );
+ mP.tqdrawPolygon( t, winding, index, npoints );
setPen( oldpen );
setBrush( oldbrush );
if( mNeedOverlay ) mOverlay.push_back( t.boundingRect() );
@@ -499,9 +499,9 @@ void KigPainter::drawObjects( const std::vector<ObjectHolder*>& os, bool sel )
void KigPainter::drawFilledRect( const TQRect& r )
{
- TQPen pen( Qt::black, 1, Qt::DotLine );
+ TQPen pen( TQt::black, 1, TQt::DotLine );
setPen( pen );
- setBrush( TQBrush( Qt::cyan, Dense6Pattern ) );
+ setBrush( TQBrush( TQt::cyan, Dense6Pattern ) );
drawRect( r.normalize() );
}
@@ -511,7 +511,7 @@ void KigPainter::drawTextStd( const TQPoint& p, const TQString& s )
// tf = text formatting flags
int tf = AlignLeft | AlignTop | DontClip | WordBreak;
// we need the rect where we're going to paint text
- setPen(TQPen(Qt::blue, 1, SolidLine));
+ setPen(TQPen(TQt::blue, 1, SolidLine));
setBrush(Qt::NoBrush);
drawText( Rect(
msi.fromScreen(p), window().bottomRight()
@@ -645,7 +645,7 @@ void KigPainter::drawAngle( const Coordinate& cpoint, const double dstartangle,
setBrushStyle( Qt::SolidPattern );
// drawPolygon( arrow );
- mP.drawPolygon( arrow, false, 0, -1 );
+ mP.tqdrawPolygon( arrow, false, 0, -1 );
// if ( mNeedOverlay ) mOverlay.push_back( toScreen( r ) );
setWholeWinOverlay(); //mp: ugly! why not compute a correct overlay?
@@ -679,7 +679,7 @@ void KigPainter::drawVector( const Coordinate& a, const Coordinate& b )
Coordinate c = b - dir + perp;
Coordinate d = b - dir - perp;
// draw the arrow lines with a normal style
- mP.setPen( TQPen( color, width == -1 ? 1 : width, Qt::SolidLine ) );
+ mP.setPen( TQPen( color, width == -1 ? 1 : width, TQt::SolidLine ) );
drawSegment( b, c );
drawSegment( b, d );
// setting again the original style
@@ -835,7 +835,7 @@ void KigPainter::drawCurve( const CurveImp* curve )
bool dooverlay = ! overlaypt && h < hmaxoverlay && valid0 && valid1
&& fabs( p0.x - p1.x ) <= overlayRectSize()
&& fabs( p0.y - p1.y ) <= overlayRectSize();
- bool addn = sr.contains( p2 ) || h >= hmax;
+ bool addn = sr.tqcontains( p2 ) || h >= hmax;
// estimated error between the curve and the segments
double errsq = 1e21;
if ( allvalid ) errsq = (0.5*p0 + 0.5*p1 - p2).squareLength();
@@ -859,7 +859,7 @@ void KigPainter::drawCurve( const CurveImp* curve )
if ( curpolylinenextfree > 0 && curpolyline[curpolylinenextfree - 1] != tp1 )
{
// flush the current part of the curve
- mP.drawPolyline( curpolyline, 0, curpolylinenextfree );
+ mP.tqdrawPolyline( curpolyline, 0, curpolylinenextfree );
curpolylinenextfree = 0;
}
if ( curpolylinenextfree == 0 )
@@ -870,10 +870,10 @@ void KigPainter::drawCurve( const CurveImp* curve )
else if ( h >= hmin ) // we do not continue to subdivide indefinitely!
{
// push into stack in order to process both subintervals
- if ( addn || ( valid0 && sr.contains( p0 ) ) )
+ if ( addn || ( valid0 && sr.tqcontains( p0 ) ) )
workstack.push( workitem( curitem.first, coordparampair( t2, p2 ),
overlaypt ) );
- if ( addn || ( valid1 && sr.contains( p1 ) ) )
+ if ( addn || ( valid1 && sr.tqcontains( p1 ) ) )
{
curitem = workitem( coordparampair( t2, p2 ), curitem.second ,
overlaypt );
@@ -883,7 +883,7 @@ void KigPainter::drawCurve( const CurveImp* curve )
}
}
// flush the rest of the curve
- mP.drawPolyline( curpolyline, 0, curpolylinenextfree );
+ mP.tqdrawPolyline( curpolyline, 0, curpolylinenextfree );
curpolylinenextfree = 0;
if ( ! workstack.empty () )
@@ -912,10 +912,10 @@ void KigPainter::drawTextFrame( const Rect& frame,
{
// inspired upon kgeo, thanks to Marc Bartsch, i've taken some of
// his code too..
- setPen( TQPen( Qt::black, 1 ) );
+ setPen( TQPen( TQt::black, 1 ) );
setBrush( TQBrush( TQColor( 255, 255, 222 ) ) );
drawRect( frame );
- setPen( TQPen( TQColor( 197, 194, 197 ), 1, Qt::SolidLine ) );
+ setPen( TQPen( TQColor( 197, 194, 197 ), 1, TQt::SolidLine ) );
TQRect qr = toScreen( frame );
@@ -924,7 +924,7 @@ void KigPainter::drawTextFrame( const Rect& frame,
};
setPen( oldpen );
setBrush( oldbrush );
- drawText( frame, s, Qt::AlignVCenter | Qt::AlignLeft );
+ drawText( frame, s, TQt::AlignVCenter | TQt::AlignLeft );
}
void KigPainter::drawArc( const Coordinate& center, const double radius,
diff --git a/kig/misc/kigpainter.h b/kig/misc/kigpainter.h
index 70b4cd9a..ee3b14c1 100644
--- a/kig/misc/kigpainter.h
+++ b/kig/misc/kigpainter.h
@@ -51,7 +51,7 @@ class ObjectHolder;
* It calls KigWidget::appendOverlay() for all of the places it draws in...
*/
class KigPainter
- : public Qt
+ : public TQt
{
protected:
// don't blaim me for this mutable hack. It's TT that hasn't got
@@ -59,10 +59,10 @@ protected:
mutable TQPainter mP;
TQColor color;
- PenStyle style;
+ Qt::PenStyle style;
int pointstyle;
int width;
- BrushStyle brushStyle;
+ Qt::BrushStyle brushStyle;
TQColor brushColor;
const KigDocument& mdoc;
@@ -94,7 +94,7 @@ public:
Rect fromScreen( const TQRect& r ) const;
// colors and stuff...
- void setStyle( const PenStyle c );
+ void setStyle( const Qt::PenStyle c );
void setColor( const TQColor& c );
/**
* setting this to -1 means to use the default width for the object
@@ -103,7 +103,7 @@ public:
void setWidth( const int c );
void setPointStyle( const int p );
void setPen( const TQPen& p );
- void setBrushStyle( const BrushStyle c );
+ void setBrushStyle( const Qt::BrushStyle c );
void setBrush( const TQBrush& b );
void setBrushColor( const TQColor& c );
diff --git a/kig/misc/lists.cc b/kig/misc/lists.cc
index d3a4fb4d..7d2bee62 100644
--- a/kig/misc/lists.cc
+++ b/kig/misc/lists.cc
@@ -301,13 +301,13 @@ bool MacroList::load( const TQString& f, std::vector<Macro*>& ret, const KigPart
TQFile file( f );
if ( ! file.open( IO_ReadOnly ) )
{
- KMessageBox::sorry( 0, i18n( "Could not open macro file '%1'" ).arg( f ) );
+ KMessageBox::sorry( 0, i18n( "Could not open macro file '%1'" ).tqarg( f ) );
return false;
}
TQDomDocument doc( "KigMacroFile" );
if ( !doc.setContent( &file ) )
{
- KMessageBox::sorry( 0, i18n( "Could not open macro file '%1'" ).arg( f ) );
+ KMessageBox::sorry( 0, i18n( "Could not open macro file '%1'" ).tqarg( f ) );
return false;
}
file.close();
@@ -318,7 +318,7 @@ bool MacroList::load( const TQString& f, std::vector<Macro*>& ret, const KigPart
else
{
KMessageBox::detailedSorry(
- 0, i18n( "Kig cannot open the macro file \"%1\"." ).arg( f ),
+ 0, i18n( "Kig cannot open the macro file \"%1\"." ).tqarg( f ),
i18n( "This file was created by a very old Kig version (pre-0.4). "
"Support for this format has been removed from recent Kig versions. "
"You can try to import this macro using a previous Kig version "
@@ -372,7 +372,7 @@ bool MacroList::loadNew( const TQDomElement& docelem, std::vector<Macro*>& ret,
assert( hierarchy );
// if the macro has no name, we give it a bogus name...
if ( name.isEmpty() )
- name = i18n( "Unnamed Macro #%1" ).arg( unnamedindex++ );
+ name = i18n( "Unnamed Macro #%1" ).tqarg( unnamedindex++ );
MacroConstructor* ctor =
new MacroConstructor( *hierarchy, i18n( name.latin1() ), i18n( description.latin1() ), iconfile );
delete hierarchy;
diff --git a/kig/misc/object_constructor.cc b/kig/misc/object_constructor.cc
index ce48a636..a5802d45 100644
--- a/kig/misc/object_constructor.cc
+++ b/kig/misc/object_constructor.cc
@@ -102,12 +102,12 @@ void StandardConstructorBase::handlePrelim(
assert ( margsparser.check( os ) != ArgsParser::Invalid );
std::vector<ObjectCalcer*> args = margsparser.parse( os );
p.setBrushStyle( Qt::NoBrush );
- p.setBrushColor( Qt::red );
- p.setPen( TQPen ( Qt::red, 1) );
+ p.setBrushColor( TQt::red );
+ p.setPen( TQPen ( TQt::red, 1) );
p.setWidth( -1 ); // -1 means the default width for the object being
// drawn..
- ObjectDrawer drawer( Qt::red );
+ ObjectDrawer drawer( TQt::red );
drawprelim( drawer, p, args, d );
}
@@ -124,12 +124,12 @@ SimpleObjectTypeConstructor::~SimpleObjectTypeConstructor()
{
}
-void SimpleObjectTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+void SimpleObjectTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& doc ) const
{
Args args;
using namespace std;
- transform( parents.begin(), parents.end(),
+ transform( tqparents.begin(), tqparents.end(),
back_inserter( args ), mem_fun( &ObjectCalcer::imp ) );
ObjectImp* data = mtype->calc( args, doc );
drawer.draw( *data, p, true );
@@ -178,12 +178,12 @@ MultiObjectTypeConstructor::~MultiObjectTypeConstructor()
{
}
-void MultiObjectTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+void MultiObjectTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& doc ) const
{
Args args;
using namespace std;
- transform( parents.begin(), parents.end(),
+ transform( tqparents.begin(), tqparents.end(),
back_inserter( args ), mem_fun( &ObjectCalcer::imp ) );
for ( vector<int>::const_iterator i = mparams.begin(); i != mparams.end(); ++i )
@@ -305,7 +305,7 @@ TQString StandardConstructorBase::useText( const ObjectCalcer& o, const std::vec
transform( sel.begin(), sel.end(), back_inserter( args ), mem_fun( &ObjectCalcer::imp ) );
std::string ret = margsparser.usetext( o.imp(), args );
- if ( ret.empty() ) return TQString::null;
+ if ( ret.empty() ) return TQString();
return i18n( ret.c_str() );
}
@@ -318,7 +318,7 @@ TQString StandardConstructorBase::selectStatement(
transform( sel.begin(), sel.end(), back_inserter( args ), mem_fun( &ObjectCalcer::imp ) );
std::string ret = margsparser.selectStatement( args );
- if ( ret.empty() ) return TQString::null;
+ if ( ret.empty() ) return TQString();
return i18n( ret.c_str() );
}
@@ -331,7 +331,7 @@ TQString MergeObjectConstructor::useText( const ObjectCalcer& o, const std::vect
int w = (*i)->wantArgs( args, d, v );
if ( w != ArgsParser::Invalid ) return (*i)->useText( o, sel, d, v );
};
- return TQString::null;
+ return TQString();
}
TQString MergeObjectConstructor::selectStatement(
@@ -344,7 +344,7 @@ TQString MergeObjectConstructor::selectStatement(
int wa = (*i)->wantArgs( args, d, w );
if ( wa != ArgsParser::Invalid ) return (*i)->selectStatement( sel, d, w );
};
- return TQString::null;
+ return TQString();
}
MacroConstructor::MacroConstructor( const ObjectHierarchy& hier, const TQString& name,
@@ -421,7 +421,7 @@ TQString MacroConstructor::selectStatement(
transform( sel.begin(), sel.end(), back_inserter( args ),
mem_fun( &ObjectCalcer::imp ) );
std::string ret = mparser.selectStatement( args );
- if ( ret.empty() ) return TQString::null;
+ if ( ret.empty() ) return TQString();
else return i18n( ret.c_str() );
}
@@ -434,7 +434,7 @@ TQString MacroConstructor::useText( const ObjectCalcer& o, const std::vector<Obj
transform( sel.begin(), sel.end(), back_inserter( args ),
mem_fun( &ObjectCalcer::imp ) );
std::string ret = mparser.usetext( o.imp(), args );
- if ( ret.empty() ) return TQString::null;
+ if ( ret.empty() ) return TQString();
else return i18n( ret.c_str() );
}
@@ -551,26 +551,26 @@ PropertyObjectConstructor::~PropertyObjectConstructor()
}
void PropertyObjectConstructor::drawprelim(
- const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+ const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& d ) const
{
- int index = parents[0]->imp()->propertiesInternalNames().findIndex( mpropinternalname );
+ int index = tqparents[0]->imp()->propertiesInternalNames().tqfindIndex( mpropinternalname );
assert ( index != -1 );
- ObjectImp* imp = parents[0]->imp()->property( index, d );
+ ObjectImp* imp = tqparents[0]->imp()->property( index, d );
drawer.draw( *imp, p, true );
delete imp;
}
std::vector<ObjectHolder*> PropertyObjectConstructor::build(
- const std::vector<ObjectCalcer*>& parents, KigDocument&,
+ const std::vector<ObjectCalcer*>& tqparents, KigDocument&,
KigWidget& ) const
{
- int index = parents[0]->imp()->propertiesInternalNames().findIndex( mpropinternalname );
+ int index = tqparents[0]->imp()->propertiesInternalNames().tqfindIndex( mpropinternalname );
assert( index != -1 );
std::vector<ObjectHolder*> ret;
ret.push_back(
new ObjectHolder(
- new ObjectPropertyCalcer( parents[0], index ) ) );
+ new ObjectPropertyCalcer( tqparents[0], index ) ) );
return ret;
}
diff --git a/kig/misc/object_constructor.h b/kig/misc/object_constructor.h
index 9b03ece0..9233426f 100644
--- a/kig/misc/object_constructor.h
+++ b/kig/misc/object_constructor.h
@@ -165,7 +165,7 @@ public:
const KigDocument& d, const KigWidget& v
) const;
- virtual void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+ virtual void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const = 0;
TQString useText( const ObjectCalcer& o, const std::vector<ObjectCalcer*>& sel,
@@ -196,7 +196,7 @@ public:
~SimpleObjectTypeConstructor();
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const;
std::vector<ObjectHolder*> build( const std::vector<ObjectCalcer*>& os,
@@ -225,7 +225,7 @@ public:
~PropertyObjectConstructor();
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const;
std::vector<ObjectHolder*> build( const std::vector<ObjectCalcer*>& os,
@@ -265,7 +265,7 @@ public:
int a, int b, int c = -999, int d = -999 );
~MultiObjectTypeConstructor();
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const;
std::vector<ObjectHolder*> build(
diff --git a/kig/misc/object_hierarchy.cc b/kig/misc/object_hierarchy.cc
index c2365aaa..7a977e63 100644
--- a/kig/misc/object_hierarchy.cc
+++ b/kig/misc/object_hierarchy.cc
@@ -47,14 +47,14 @@ public:
// on the given objects. The dependsstack contains a set of
// booleans telling which parts of the hierarchy certainly depend on
// the given objects. In this function, the node should check
- // whether any of its parents have true set, and if so, set its own
+ // whether any of its tqparents have true set, and if so, set its own
// value to true.
virtual void checkDependsOnGiven( std::vector<bool>& dependsstack, int loc ) const = 0;
// this function is used to check whether the given objects are all
- // used by one or more of the final objects. The usedstack contains
+ // used by one or more of the final objects. The usedstack tqcontains
// a set of booleans telling which parts of the hierarchy are
// certainly ancestors of the final objects. In this function, the
- // node should set all of its parents' booleans to true.
+ // node should set all of its tqparents' booleans to true.
virtual void checkArgumentsUsed( std::vector<bool>& usedstack ) const = 0;
};
@@ -118,15 +118,15 @@ class ApplyTypeNode
: public ObjectHierarchy::Node
{
const ObjectType* mtype;
- std::vector<int> mparents;
+ std::vector<int> mtqparents;
public:
- ApplyTypeNode( const ObjectType* type, const std::vector<int>& parents )
- : mtype( type ), mparents( parents ) {}
+ ApplyTypeNode( const ObjectType* type, const std::vector<int>& tqparents )
+ : mtype( type ), mtqparents( tqparents ) {}
~ApplyTypeNode();
Node* copy() const;
const ObjectType* type() const { return mtype; }
- const std::vector<int>& parents() const { return mparents; }
+ const std::vector<int>& tqparents() const { return mtqparents; }
int id() const;
void apply( std::vector<const ObjectImp*>& stack,
@@ -141,17 +141,17 @@ int ApplyTypeNode::id() const { return ID_ApplyType; }
void ApplyTypeNode::checkArgumentsUsed( std::vector<bool>& usedstack ) const
{
- for ( uint i = 0; i < mparents.size(); ++i )
+ for ( uint i = 0; i < mtqparents.size(); ++i )
{
- usedstack[mparents[i]] = true;
+ usedstack[mtqparents[i]] = true;
}
}
void ApplyTypeNode::checkDependsOnGiven( std::vector<bool>& dependsstack, int loc ) const
{
bool result = false;
- for ( uint i = 0; i < mparents.size(); ++i )
- if ( dependsstack[mparents[i]] == true ) result = true;
+ for ( uint i = 0; i < mtqparents.size(); ++i )
+ if ( dependsstack[mtqparents[i]] == true ) result = true;
dependsstack[loc] = result;
}
@@ -161,23 +161,23 @@ ApplyTypeNode::~ApplyTypeNode()
ObjectHierarchy::Node* ApplyTypeNode::copy() const
{
- return new ApplyTypeNode( mtype, mparents );
+ return new ApplyTypeNode( mtype, mtqparents );
}
void ApplyTypeNode::apply( std::vector<ObjectCalcer*>& stack, int loc ) const
{
- std::vector<ObjectCalcer*> parents;
- for ( uint i = 0; i < mparents.size(); ++i )
- parents.push_back( stack[ mparents[i] ] );
- stack[loc] = new ObjectTypeCalcer( mtype, parents );
+ std::vector<ObjectCalcer*> tqparents;
+ for ( uint i = 0; i < mtqparents.size(); ++i )
+ tqparents.push_back( stack[ mtqparents[i] ] );
+ stack[loc] = new ObjectTypeCalcer( mtype, tqparents );
}
void ApplyTypeNode::apply( std::vector<const ObjectImp*>& stack,
int loc, const KigDocument& doc ) const
{
Args args;
- for ( uint i = 0; i < mparents.size(); ++i )
- args.push_back( stack[mparents[i]] );
+ for ( uint i = 0; i < mtqparents.size(); ++i )
+ args.push_back( stack[mtqparents[i]] );
args = mtype->sortArgs( args );
stack[loc] = mtype->calc( args, doc );
}
@@ -186,21 +186,21 @@ class FetchPropertyNode
: public ObjectHierarchy::Node
{
mutable int mpropid;
- int mparent;
+ int mtqparent;
const TQCString mname;
public:
- // propid is a cache of the location of name in the parent's
+ // propid is a cache of the location of name in the tqparent's
// propertiesInternalNames(), just as it is in PropertyObject. We
// don't want to ever save this value, since we cannot guarantee it
// remains consistent if we add properties some place..
- FetchPropertyNode( const int parent, const TQCString& name, const int propid = -1 )
- : mpropid( propid ), mparent( parent ), mname( name ) {}
+ FetchPropertyNode( const int tqparent, const TQCString& name, const int propid = -1 )
+ : mpropid( propid ), mtqparent( tqparent ), mname( name ) {}
~FetchPropertyNode();
Node* copy() const;
void checkDependsOnGiven( std::vector<bool>& dependsstack, int loc ) const;
void checkArgumentsUsed( std::vector<bool>& usedstack ) const;
- int parent() const { return mparent; }
+ int tqparent() const { return mtqparent; }
const TQCString& propinternalname() const { return mname; }
int id() const;
@@ -215,17 +215,17 @@ FetchPropertyNode::~FetchPropertyNode()
void FetchPropertyNode::checkArgumentsUsed( std::vector<bool>& usedstack ) const
{
- usedstack[mparent] = true;
+ usedstack[mtqparent] = true;
}
void FetchPropertyNode::checkDependsOnGiven( std::vector<bool>& dependsstack, int loc ) const
{
- dependsstack[loc] = dependsstack[mparent];
+ dependsstack[loc] = dependsstack[mtqparent];
}
ObjectHierarchy::Node* FetchPropertyNode::copy() const
{
- return new FetchPropertyNode( mparent, mname, mpropid );
+ return new FetchPropertyNode( mtqparent, mname, mpropid );
}
int FetchPropertyNode::id() const
@@ -236,10 +236,10 @@ int FetchPropertyNode::id() const
void FetchPropertyNode::apply( std::vector<const ObjectImp*>& stack,
int loc, const KigDocument& d ) const
{
- assert( stack[mparent] );
- if ( mpropid == -1 ) mpropid = stack[mparent]->propertiesInternalNames().findIndex( mname );
+ assert( stack[mtqparent] );
+ if ( mpropid == -1 ) mpropid = stack[mtqparent]->propertiesInternalNames().tqfindIndex( mname );
if ( mpropid != -1 )
- stack[loc] = stack[mparent]->property( mpropid, d );
+ stack[loc] = stack[mtqparent]->property( mpropid, d );
else
stack[loc] = new InvalidImp();
}
@@ -247,9 +247,9 @@ void FetchPropertyNode::apply( std::vector<const ObjectImp*>& stack,
void FetchPropertyNode::apply( std::vector<ObjectCalcer*>& stack, int loc ) const
{
if ( mpropid == -1 )
- mpropid = stack[mparent]->imp()->propertiesInternalNames().findIndex( mname );
+ mpropid = stack[mtqparent]->imp()->propertiesInternalNames().tqfindIndex( mname );
assert( mpropid != -1 );
- stack[loc] = new ObjectPropertyCalcer( stack[mparent], mpropid );
+ stack[loc] = new ObjectPropertyCalcer( stack[mtqparent], mpropid );
}
std::vector<ObjectImp*> ObjectHierarchy::calc( const Args& a, const KigDocument& doc ) const
@@ -297,23 +297,23 @@ int ObjectHierarchy::visit( const ObjectCalcer* o, std::map<const ObjectCalcer*,
// because that's where we expect it.. We therefore copy it
// there using CopyObjectType..
int ret = mnumberofargs + mnodes.size();
- std::vector<int> parents;
- parents.push_back( smi->second );
- mnodes.push_back( new ApplyTypeNode( CopyObjectType::instance(), parents ) );
+ std::vector<int> tqparents;
+ tqparents.push_back( smi->second );
+ mnodes.push_back( new ApplyTypeNode( CopyObjectType::instance(), tqparents ) );
return ret;
}
else return smi->second;
}
- std::vector<ObjectCalcer*> p( o->parents() );
+ std::vector<ObjectCalcer*> p( o->tqparents() );
// we check if o descends from the given objects..
bool descendsfromgiven = false;
- std::vector<int> parents;
- parents.resize( p.size(), -1 );
+ std::vector<int> tqparents;
+ tqparents.resize( p.size(), -1 );
for ( uint i = 0; i < p.size(); ++i )
{
int v = visit( p[i], seenmap, false );
- parents[i] = v;
+ tqparents[i] = v;
descendsfromgiven |= (v != -1);
};
@@ -335,7 +335,7 @@ int ObjectHierarchy::visit( const ObjectCalcer* o, std::map<const ObjectCalcer*,
return -1;
};
- return storeObject( o, p, parents, seenmap );
+ return storeObject( o, p, tqparents, seenmap );
}
ObjectHierarchy::~ObjectHierarchy()
@@ -385,9 +385,9 @@ void ObjectHierarchy::init( const std::vector<ObjectCalcer*>& from, const std::v
seenmap[from[i]] = i;
for ( std::vector<ObjectCalcer*>::const_iterator i = to.begin(); i != to.end(); ++i )
{
- std::vector<ObjectCalcer*> parents = (*i)->parents();
- for ( std::vector<ObjectCalcer*>::const_iterator j = parents.begin();
- j != parents.end(); ++j )
+ std::vector<ObjectCalcer*> tqparents = (*i)->tqparents();
+ for ( std::vector<ObjectCalcer*>::const_iterator j = tqparents.begin();
+ j != tqparents.end(); ++j )
visit( *j, seenmap, true );
}
for ( std::vector<ObjectCalcer*>::const_iterator i = to.begin(); i != to.end(); ++i )
@@ -408,7 +408,7 @@ ObjectHierarchy::ObjectHierarchy( const std::vector<ObjectCalcer*>& from, const
init( from, to );
}
-void ObjectHierarchy::serialize( TQDomElement& parent, TQDomDocument& doc ) const
+void ObjectHierarchy::serialize( TQDomElement& tqparent, TQDomDocument& doc ) const
{
int id = 1;
for ( uint i = 0; i < mnumberofargs; ++i )
@@ -419,12 +419,12 @@ void ObjectHierarchy::serialize( TQDomElement& parent, TQDomDocument& doc ) cons
// we don't save these atm, since the user can't define them.
// we only load them from builtin macro's.
// TQDomElement ut = doc.createElement( "UseText" );
-// ut.appendChild( doc.createTextNode( TQString::fromLatin1(musetexts[i].c_str() ) ) );
+// ut.appendChild( doc.createTextNode( TQString::tqfromLatin1(musetexts[i].c_str() ) ) );
// e.appendChild( ut );
// TQDomElement ss = doc.createElement( "SelectStatement" );
-// ss.appendChild( doc.createTextNode( TQString::fromLatin1(mselectstatements[i].c_str() ) ) );
+// ss.appendChild( doc.createTextNode( TQString::tqfromLatin1(mselectstatements[i].c_str() ) ) );
// e.appendChild( ss );
- parent.appendChild( e );
+ tqparent.appendChild( e );
}
for ( uint i = 0; i < mnodes.size(); ++i )
@@ -437,12 +437,12 @@ void ObjectHierarchy::serialize( TQDomElement& parent, TQDomDocument& doc ) cons
{
const ApplyTypeNode* node = static_cast<const ApplyTypeNode*>( mnodes[i] );
e.setAttribute( "action", "calc" );
- e.setAttribute( "type", TQString::fromLatin1( node->type()->fullName() ) );
- for ( uint i = 0; i < node->parents().size(); ++i )
+ e.setAttribute( "type", TQString::tqfromLatin1( node->type()->fullName() ) );
+ for ( uint i = 0; i < node->tqparents().size(); ++i )
{
- int parent = node->parents()[i] + 1;
+ int tqparent = node->tqparents()[i] + 1;
TQDomElement arge = doc.createElement( "arg" );
- arge.appendChild( doc.createTextNode( TQString::number( parent ) ) );
+ arge.appendChild( doc.createTextNode( TQString::number( tqparent ) ) );
e.appendChild( arge );
};
}
@@ -450,9 +450,9 @@ void ObjectHierarchy::serialize( TQDomElement& parent, TQDomDocument& doc ) cons
{
const FetchPropertyNode* node = static_cast<const FetchPropertyNode*>( mnodes[i] );
e.setAttribute( "action", "fetch-property" );
- e.setAttribute( "property", node->propinternalname() );
+ e.setAttribute( TQString("property"), TQString(node->propinternalname()) );
TQDomElement arge = doc.createElement( "arg" );
- arge.appendChild( doc.createTextNode( TQString::number( node->parent() + 1 ) ) );
+ arge.appendChild( doc.createTextNode( TQString::number( node->tqparent() + 1 ) ) );
e.appendChild( arge );
}
else
@@ -464,7 +464,7 @@ void ObjectHierarchy::serialize( TQDomElement& parent, TQDomDocument& doc ) cons
e.setAttribute( "type", type );
};
- parent.appendChild( e );
+ tqparent.appendChild( e );
};
}
@@ -473,12 +473,12 @@ ObjectHierarchy::ObjectHierarchy()
{
}
-ObjectHierarchy* ObjectHierarchy::buildSafeObjectHierarchy( const TQDomElement& parent, TQString& error )
+ObjectHierarchy* ObjectHierarchy::buildSafeObjectHierarchy( const TQDomElement& tqparent, TQString& error )
{
#define KIG_GENERIC_PARSE_ERROR \
{ \
error = i18n( "An error was encountered at line %1 in file %2." ) \
- .arg( __LINE__ ).arg( __FILE__ ); \
+ .tqarg( __LINE__ ).tqarg( __FILE__ ); \
return 0; \
}
@@ -486,7 +486,7 @@ ObjectHierarchy* ObjectHierarchy::buildSafeObjectHierarchy( const TQDomElement&
bool ok = true;
TQString tmp;
- TQDomElement e = parent.firstChild().toElement();
+ TQDomElement e = tqparent.firstChild().toElement();
for (; !e.isNull(); e = e.nextSibling().toElement() )
{
if ( e.tagName() != "input" ) break;
@@ -537,18 +537,18 @@ ObjectHierarchy* ObjectHierarchy::buildSafeObjectHierarchy( const TQDomElement&
{
// ApplyTypeNode
TQCString typen = e.attribute( "type" ).latin1();
- const ObjectType* type = ObjectTypeFactory::instance()->find( typen );
+ const ObjectType* type = ObjectTypeFactory::instance()->tqfind( typen );
if ( ! type )
{
error = i18n( "This Kig file uses an object of type \"%1\", "
"which this Kig version does not support."
"Perhaps you have compiled Kig without support "
"for this object type,"
- "or perhaps you are using an older Kig version." ).arg( typen );
+ "or perhaps you are using an older Kig version." ).tqarg( TQString(typen) );
return 0;
}
- std::vector<int> parents;
+ std::vector<int> tqparents;
for ( TQDomNode p = e.firstChild(); !p.isNull(); p = p.nextSibling() )
{
TQDomElement q = p.toElement();
@@ -556,18 +556,18 @@ ObjectHierarchy* ObjectHierarchy::buildSafeObjectHierarchy( const TQDomElement&
if ( q.tagName() != "arg" ) KIG_GENERIC_PARSE_ERROR;
int pid = q.text().toInt(&ok );
if ( !ok ) KIG_GENERIC_PARSE_ERROR;
- parents.push_back( pid - 1 );
+ tqparents.push_back( pid - 1 );
};
- newnode = new ApplyTypeNode( type, parents );
+ newnode = new ApplyTypeNode( type, tqparents );
}
else if ( tmp == "fetch-property" )
{
// FetchPropertyNode
TQCString propname = e.attribute( "property" ).latin1();
TQDomElement arge = e.firstChild().toElement();
- int parent = arge.text().toInt( &ok );
+ int tqparent = arge.text().toInt( &ok );
if ( !ok ) KIG_GENERIC_PARSE_ERROR;
- newnode = new FetchPropertyNode( parent - 1, propname );
+ newnode = new FetchPropertyNode( tqparent - 1, propname );
}
else
{
@@ -640,11 +640,11 @@ ObjectHierarchy ObjectHierarchy::transformFinalObject( const Transformation& t )
ObjectHierarchy ret( *this );
ret.mnodes.push_back( new PushStackNode( new TransformationImp( t ) ) );
- std::vector<int> parents;
- parents.push_back( ret.mnodes.size() - 1);
- parents.push_back( ret.mnodes.size() );
+ std::vector<int> tqparents;
+ tqparents.push_back( ret.mnodes.size() - 1);
+ tqparents.push_back( ret.mnodes.size() );
const ObjectType* type = ApplyTransformationObjectType::instance();
- ret.mnodes.push_back( new ApplyTypeNode( type, parents ) );
+ ret.mnodes.push_back( new ApplyTypeNode( type, tqparents ) );
return ret;
}
@@ -696,7 +696,7 @@ const ObjectImpType* lowermost( const ObjectImpType* a, const ObjectImpType* b )
// this function is part of the visit procedure really. It is
// factored out, because it recurses for cache ObjectImp's. What this
// does is, it makes sure that object o is calcable, by putting
-// appropriate Node's in mnodes.. po is o->parents() and pl contains
+// appropriate Node's in mnodes.. po is o->tqparents() and pl tqcontains
// the location of objects that are already in mnodes and -1
// otherwise.. -1 means we have to store their ObjectImp, unless
// they're cache ObjectImp's etc.
@@ -723,12 +723,12 @@ int ObjectHierarchy::storeObject( const ObjectCalcer* o, const std::vector<Objec
}
else if ( (uint) pl[i] < mnumberofargs )
{
- ObjectCalcer* parent = o->parents()[i];
- std::vector<ObjectCalcer*> opl = o->parents();
+ ObjectCalcer* tqparent = o->tqparents()[i];
+ std::vector<ObjectCalcer*> opl = o->tqparents();
margrequirements[pl[i]] =
lowermost( margrequirements[pl[i]],
- o->impRequirement( parent, opl ) );
+ o->impRequirement( tqparent, opl ) );
musetexts[pl[i]] = margrequirements[pl[i]]->selectStatement();
};
};
@@ -737,12 +737,12 @@ int ObjectHierarchy::storeObject( const ObjectCalcer* o, const std::vector<Objec
else if ( dynamic_cast<const ObjectPropertyCalcer*>( o ) )
{
assert( pl.size() == 1 );
- int parent = pl.front();
+ int tqparent = pl.front();
ObjectCalcer* op = po.front();
assert( op );
uint propid = static_cast<const ObjectPropertyCalcer*>( o )->propId();
assert( propid < op->imp()->propertiesInternalNames().size() );
- mnodes.push_back( new FetchPropertyNode( parent, op->imp()->propertiesInternalNames()[propid], propid ) );
+ mnodes.push_back( new FetchPropertyNode( tqparent, op->imp()->propertiesInternalNames()[propid], propid ) );
}
else
assert( false );
diff --git a/kig/misc/object_hierarchy.h b/kig/misc/object_hierarchy.h
index 60df8a59..cda2615f 100644
--- a/kig/misc/object_hierarchy.h
+++ b/kig/misc/object_hierarchy.h
@@ -73,22 +73,22 @@ public:
std::vector<ObjectImp*> calc( const Args& a, const KigDocument& doc ) const;
/**
- * saves the ObjectHierarchy data in children xml tags of \p parent ..
+ * saves the ObjectHierarchy data in tqchildren xml tags of \p tqparent ..
*/
- void serialize( TQDomElement& parent, TQDomDocument& doc ) const;
+ void serialize( TQDomElement& tqparent, TQDomDocument& doc ) const;
/**
- * Deserialize the ObjectHierarchy data from the xml element \p parent ..
+ * Deserialize the ObjectHierarchy data from the xml element \p tqparent ..
* Since this operation can fail for some reasons, we provide it as a
* static to return 0 in case of error.
*/
- static ObjectHierarchy* buildSafeObjectHierarchy( const TQDomElement& parent, TQString& error );
-// ObjectHierarchy( const TQDomElement& parent );
+ static ObjectHierarchy* buildSafeObjectHierarchy( const TQDomElement& tqparent, TQString& error );
+// ObjectHierarchy( const TQDomElement& tqparent );
/**
* build a set of objects that interdepend according to this
* ObjectHierarchy.. Only the result objects are returned. Helper
* objects that connect the given objects with the returned objects,
- * can only be found by following the returned objects' parents()
+ * can only be found by following the returned objects' tqparents()
* methods..
*/
std::vector<ObjectCalcer*> buildObjects( const std::vector<ObjectCalcer*>& os, const KigDocument& ) const;
diff --git a/kig/misc/rect.cc b/kig/misc/rect.cc
index 183f50f8..652fae2d 100644
--- a/kig/misc/rect.cc
+++ b/kig/misc/rect.cc
@@ -153,9 +153,9 @@ void Rect::scale( const double r )
}
-TQRect Rect::toQRect() const
+TQRect Rect::toTQRect() const
{
- return TQRect(mBottomLeft.toQPoint(), topRight().toQPoint());
+ return TQRect(mBottomLeft.toTQPoint(), topRight().toTQPoint());
}
Coordinate Rect::bottomLeft() const
@@ -211,7 +211,7 @@ double Rect::height() const
return mheight;
}
-bool Rect::contains( const Coordinate& p, double allowed_miss ) const
+bool Rect::tqcontains( const Coordinate& p, double allowed_miss ) const
{
return p.x - left() >= - allowed_miss &&
p.y - bottom() >= - allowed_miss &&
@@ -219,7 +219,7 @@ bool Rect::contains( const Coordinate& p, double allowed_miss ) const
p.y - bottom() - height() <= allowed_miss;
}
-bool Rect::contains( const Coordinate& p ) const
+bool Rect::tqcontains( const Coordinate& p ) const
{
return p.x >= left() &&
p.y >= bottom() &&
@@ -253,7 +253,7 @@ Rect Rect::normalized() const
return t;
}
-Rect Rect::fromQRect( const TQRect& r )
+Rect Rect::fromTQRect( const TQRect& r )
{
return Rect( r.left(), r.top(), r.right(), r.bottom() );
}
diff --git a/kig/misc/rect.h b/kig/misc/rect.h
index 1fe0b071..52958dd8 100644
--- a/kig/misc/rect.h
+++ b/kig/misc/rect.h
@@ -103,7 +103,7 @@ public:
*/
Rect matchShape( const Rect& rhs, bool shrink = false ) const;
- TQRect toQRect() const;
+ TQRect toTQRect() const;
Coordinate bottomLeft() const;
Coordinate bottomRight() const;
Coordinate topLeft() const;
@@ -115,13 +115,13 @@ public:
double top() const;
double width() const;
double height() const;
- bool contains( const Coordinate& p ) const;
- bool contains( const Coordinate& p, double allowed_miss ) const;
+ bool tqcontains( const Coordinate& p ) const;
+ bool tqcontains( const Coordinate& p, double allowed_miss ) const;
bool intersects( const Rect& p ) const;
Rect normalized() const;
friend kdbgstream& operator<<( kdbgstream& s, const Rect& t );
- static Rect fromQRect( const TQRect& );
+ static Rect fromTQRect( const TQRect& );
protected:
Coordinate mBottomLeft;
double mwidth;
diff --git a/kig/misc/special_constructors.cc b/kig/misc/special_constructors.cc
index d419a546..ccb92ac6 100644
--- a/kig/misc/special_constructors.cc
+++ b/kig/misc/special_constructors.cc
@@ -68,7 +68,7 @@ public:
ConicConicIntersectionConstructor();
~ConicConicIntersectionConstructor();
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const;
std::vector<ObjectHolder*> build( const std::vector<ObjectCalcer*>& os, KigDocument& d, KigWidget& w ) const;
void plug( KigPart* doc, KigGUIAction* kact );
@@ -109,13 +109,13 @@ ConicRadicalConstructor::~ConicRadicalConstructor()
}
void ConicRadicalConstructor::drawprelim(
- const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents, const KigDocument& doc ) const
+ const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents, const KigDocument& doc ) const
{
- if ( parents.size() == 2 && parents[0]->imp()->inherits( ConicImp::stype() ) &&
- parents[1]->imp()->inherits( ConicImp::stype() ) )
+ if ( tqparents.size() == 2 && tqparents[0]->imp()->inherits( ConicImp::stype() ) &&
+ tqparents[1]->imp()->inherits( ConicImp::stype() ) )
{
Args args;
- std::transform( parents.begin(), parents.end(),
+ std::transform( tqparents.begin(), tqparents.end(),
std::back_inserter( args ), std::mem_fun( &ObjectCalcer::imp ) );
for ( int i = -1; i < 2; i += 2 )
{
@@ -170,27 +170,27 @@ LocusConstructor::~LocusConstructor()
{
}
-void LocusConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+void LocusConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const
{
// this function is rather ugly, but it is necessary to do it this
// way in order to play nice with Kig's design..
- if ( parents.size() != 2 ) return;
- const ObjectTypeCalcer* constrained = dynamic_cast<ObjectTypeCalcer*>( parents.front() );
- const ObjectCalcer* moving = parents.back();
+ if ( tqparents.size() != 2 ) return;
+ const ObjectTypeCalcer* constrained = dynamic_cast<ObjectTypeCalcer*>( tqparents.front() );
+ const ObjectCalcer* moving = tqparents.back();
if ( ! constrained || ! constrained->type()->inherits( ObjectType::ID_ConstrainedPointType ) )
{
// moving is in fact the constrained point.. swap them..
- moving = parents.front();
- constrained = dynamic_cast<const ObjectTypeCalcer*>( parents.back() );
+ moving = tqparents.front();
+ constrained = dynamic_cast<const ObjectTypeCalcer*>( tqparents.back() );
assert( constrained );
};
assert( constrained->type()->inherits( ObjectType::ID_ConstrainedPointType ) );
- const ObjectImp* oimp = constrained->parents().back()->imp();
+ const ObjectImp* oimp = constrained->tqparents().back()->imp();
if( !oimp->inherits( CurveImp::stype() ) )
- oimp = constrained->parents().front()->imp();
+ oimp = constrained->tqparents().front()->imp();
assert( oimp->inherits( CurveImp::stype() ) );
const CurveImp* cimp = static_cast<const CurveImp*>( oimp );
@@ -210,30 +210,30 @@ const int LocusConstructor::wantArgs(
if ( dynamic_cast<ObjectTypeCalcer*>( os.front() ) &&
static_cast<ObjectTypeCalcer*>( os.front() )->type()->inherits( ObjectType::ID_ConstrainedPointType ) )
{
- std::set<ObjectCalcer*> children = getAllChildren( os.front() );
- return children.find( os.back() ) != children.end() ? ret : ArgsParser::Invalid;
+ std::set<ObjectCalcer*> tqchildren = getAllChildren( os.front() );
+ return tqchildren.find( os.back() ) != tqchildren.end() ? ret : ArgsParser::Invalid;
}
if ( dynamic_cast<ObjectTypeCalcer*>( os.back() ) &&
static_cast<ObjectTypeCalcer*>( os.back() )->type()->inherits( ObjectType::ID_ConstrainedPointType ) )
{
- std::set<ObjectCalcer*> children = getAllChildren( os.back() );
- return children.find( os.front() ) != children.end() ? ret : ArgsParser::Invalid;
+ std::set<ObjectCalcer*> tqchildren = getAllChildren( os.back() );
+ return tqchildren.find( os.front() ) != tqchildren.end() ? ret : ArgsParser::Invalid;
}
return ArgsParser::Invalid;
}
-std::vector<ObjectHolder*> LocusConstructor::build( const std::vector<ObjectCalcer*>& parents, KigDocument&, KigWidget& ) const
+std::vector<ObjectHolder*> LocusConstructor::build( const std::vector<ObjectCalcer*>& tqparents, KigDocument&, KigWidget& ) const
{
std::vector<ObjectHolder*> ret;
- assert( parents.size() == 2 );
+ assert( tqparents.size() == 2 );
- ObjectTypeCalcer* constrained = dynamic_cast<ObjectTypeCalcer*>( parents.front() );
- ObjectCalcer* moving = parents.back();
+ ObjectTypeCalcer* constrained = dynamic_cast<ObjectTypeCalcer*>( tqparents.front() );
+ ObjectCalcer* moving = tqparents.back();
if ( ! constrained || ! constrained->type()->inherits( ObjectType::ID_ConstrainedPointType ) )
{
// moving is in fact the constrained point.. swap them..
- moving = parents.front();
- constrained = dynamic_cast<ObjectTypeCalcer*>( parents.back() );
+ moving = tqparents.front();
+ constrained = dynamic_cast<ObjectTypeCalcer*>( tqparents.back() );
assert( constrained );
};
assert( constrained->type()->inherits( ObjectType::ID_ConstrainedPointType ) );
@@ -350,12 +350,12 @@ void PolygonBNPTypeConstructor::handlePrelim(
std::vector<ObjectCalcer*> args = os;
p.setBrushStyle( Qt::NoBrush );
- p.setBrushColor( Qt::red );
- p.setPen( TQPen ( Qt::red, 1) );
+ p.setBrushColor( TQt::red );
+ p.setPen( TQPen ( TQt::red, 1) );
p.setWidth( -1 ); // -1 means the default width for the object being
// drawn..
- ObjectDrawer drawer( Qt::red );
+ ObjectDrawer drawer( TQt::red );
drawprelim( drawer, p, args, d );
}
@@ -374,21 +374,21 @@ TQString PolygonBNPTypeConstructor::selectStatement(
return i18n("Select a point to be a vertex of the new polygon...");
}
-void PolygonBNPTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+void PolygonBNPTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const
{
- if ( parents.size() < 2 ) return;
+ if ( tqparents.size() < 2 ) return;
std::vector<Coordinate> points;
- for ( uint i = 0; i < parents.size(); ++i )
+ for ( uint i = 0; i < tqparents.size(); ++i )
{
const Coordinate vertex =
- static_cast<const PointImp*>( parents[i]->imp() )->coordinate();
+ static_cast<const PointImp*>( tqparents[i]->imp() )->coordinate();
points.push_back( vertex );
}
- if ( parents.size() == 2 )
+ if ( tqparents.size() == 2 )
{
SegmentImp segment = SegmentImp( points[0], points[1] );
drawer.draw( segment, p, true );
@@ -398,12 +398,12 @@ void PolygonBNPTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPaint
}
}
-std::vector<ObjectHolder*> PolygonBNPTypeConstructor::build( const std::vector<ObjectCalcer*>& parents, KigDocument&, KigWidget& ) const
+std::vector<ObjectHolder*> PolygonBNPTypeConstructor::build( const std::vector<ObjectCalcer*>& tqparents, KigDocument&, KigWidget& ) const
{
- uint count = parents.size() - 1;
+ uint count = tqparents.size() - 1;
assert ( count >= 3 );
std::vector<ObjectCalcer*> args;
- for ( uint i = 0; i < count; ++i ) args.push_back( parents[i] );
+ for ( uint i = 0; i < count; ++i ) args.push_back( tqparents[i] );
ObjectTypeCalcer* calcer = new ObjectTypeCalcer( mtype, args );
ObjectHolder* h = new ObjectHolder( calcer );
std::vector<ObjectHolder*> ret;
@@ -443,12 +443,12 @@ PolygonVertexTypeConstructor::~PolygonVertexTypeConstructor()
{
}
-void PolygonVertexTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+void PolygonVertexTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const
{
- if ( parents.size() != 1 ) return;
+ if ( tqparents.size() != 1 ) return;
- const PolygonImp* polygon = dynamic_cast<const PolygonImp*>( parents.front()->imp() );
+ const PolygonImp* polygon = dynamic_cast<const PolygonImp*>( tqparents.front()->imp() );
const std::vector<Coordinate> points = polygon->points();
int sides = points.size();
@@ -459,11 +459,11 @@ void PolygonVertexTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPa
}
}
-std::vector<ObjectHolder*> PolygonVertexTypeConstructor::build( const std::vector<ObjectCalcer*>& parents, KigDocument&, KigWidget& ) const
+std::vector<ObjectHolder*> PolygonVertexTypeConstructor::build( const std::vector<ObjectCalcer*>& tqparents, KigDocument&, KigWidget& ) const
{
std::vector<ObjectHolder*> ret;
- assert( parents.size() == 1 );
- const PolygonImp* polygon = dynamic_cast<const PolygonImp*>( parents.front()->imp() );
+ assert( tqparents.size() == 1 );
+ const PolygonImp* polygon = dynamic_cast<const PolygonImp*>( tqparents.front()->imp() );
const std::vector<Coordinate> points = polygon->points();
int sides = points.size();
@@ -471,7 +471,7 @@ std::vector<ObjectHolder*> PolygonVertexTypeConstructor::build( const std::vecto
for ( int i = 0; i < sides; ++i )
{
ObjectConstCalcer* d = new ObjectConstCalcer( new IntImp( i ) );
- std::vector<ObjectCalcer*> args( parents );
+ std::vector<ObjectCalcer*> args( tqparents );
args.push_back( d );
ret.push_back( new ObjectHolder( new ObjectTypeCalcer( mtype, args ) ) );
}
@@ -510,12 +510,12 @@ PolygonSideTypeConstructor::~PolygonSideTypeConstructor()
{
}
-void PolygonSideTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+void PolygonSideTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const
{
- if ( parents.size() != 1 ) return;
+ if ( tqparents.size() != 1 ) return;
- const PolygonImp* polygon = dynamic_cast<const PolygonImp*>( parents.front()->imp() );
+ const PolygonImp* polygon = dynamic_cast<const PolygonImp*>( tqparents.front()->imp() );
const std::vector<Coordinate> points = polygon->points();
uint sides = points.size();
@@ -527,11 +527,11 @@ void PolygonSideTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPain
}
}
-std::vector<ObjectHolder*> PolygonSideTypeConstructor::build( const std::vector<ObjectCalcer*>& parents, KigDocument&, KigWidget& ) const
+std::vector<ObjectHolder*> PolygonSideTypeConstructor::build( const std::vector<ObjectCalcer*>& tqparents, KigDocument&, KigWidget& ) const
{
std::vector<ObjectHolder*> ret;
- assert( parents.size() == 1 );
- const PolygonImp* polygon = dynamic_cast<const PolygonImp*>( parents.front()->imp() );
+ assert( tqparents.size() == 1 );
+ const PolygonImp* polygon = dynamic_cast<const PolygonImp*>( tqparents.front()->imp() );
const std::vector<Coordinate> points = polygon->points();
uint sides = points.size();
@@ -539,7 +539,7 @@ std::vector<ObjectHolder*> PolygonSideTypeConstructor::build( const std::vector<
for ( uint i = 0; i < sides; ++i )
{
ObjectConstCalcer* d = new ObjectConstCalcer( new IntImp( i ) );
- std::vector<ObjectCalcer*> args( parents );
+ std::vector<ObjectCalcer*> args( tqparents );
args.push_back( d );
ret.push_back( new ObjectHolder( new ObjectTypeCalcer( mtype, args ) ) );
}
@@ -659,12 +659,12 @@ void PolygonBCVConstructor::handlePrelim(
}
p.setBrushStyle( Qt::NoBrush );
- p.setBrushColor( Qt::red );
- p.setPen( TQPen ( Qt::red, 1) );
+ p.setBrushColor( TQt::red );
+ p.setPen( TQPen ( TQt::red, 1) );
p.setWidth( -1 ); // -1 means the default width for the object being
// drawn..
- ObjectDrawer drawer( Qt::red );
+ ObjectDrawer drawer( TQt::red );
drawprelim( drawer, p, args, d );
if ( moreinfo )
{
@@ -682,7 +682,7 @@ void PolygonBCVConstructor::handlePrelim(
ptn = PointImp( where );
ptn.draw( p );
if ( i > 5 ) continue;
- text = TextImp( TQString( "(%1)" ).arg(i), where, false );
+ text = TextImp( TQString( "(%1)" ).tqarg(i), where, false );
text.draw( p );
}
p.setStyle( Qt::DotLine );
@@ -700,17 +700,17 @@ void PolygonBCVConstructor::handlePrelim(
delete_all( args.begin() + 2, args.end() );
}
-std::vector<ObjectHolder*> PolygonBCVConstructor::build( const std::vector<ObjectCalcer*>& parents, KigDocument&, KigWidget& ) const
+std::vector<ObjectHolder*> PolygonBCVConstructor::build( const std::vector<ObjectCalcer*>& tqparents, KigDocument&, KigWidget& ) const
{
- assert ( parents.size() == 3 );
+ assert ( tqparents.size() == 3 );
std::vector<ObjectCalcer*> args;
- Coordinate c = static_cast<const PointImp*>( parents[0]->imp() )->coordinate();
- Coordinate v = static_cast<const PointImp*>( parents[1]->imp() )->coordinate();
- Coordinate cntrl = static_cast<const PointImp*>( parents[2]->imp() )->coordinate();
+ Coordinate c = static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate();
+ Coordinate v = static_cast<const PointImp*>( tqparents[1]->imp() )->coordinate();
+ Coordinate cntrl = static_cast<const PointImp*>( tqparents[2]->imp() )->coordinate();
- args.push_back( parents[0] );
- args.push_back( parents[1] );
+ args.push_back( tqparents[0] );
+ args.push_back( tqparents[1] );
int winding = 0;
int nsides = computeNsides( c, v, cntrl, winding );
ObjectConstCalcer* d = new ObjectConstCalcer( new IntImp( nsides ) );
@@ -752,13 +752,13 @@ TQString PolygonBCVConstructor::useText( const ObjectCalcer&, const std::vector<
{
TQString result = TQString(
i18n( "Adjust the number of sides (%1/%2)" )
- ).arg( nsides ).arg( winding );
+ ).tqarg( nsides ).tqarg( winding );
return result;
} else
{
TQString result = TQString(
i18n( "Adjust the number of sides (%1)" )
- ).arg( nsides );
+ ).tqarg( nsides );
return result;
}
break;
@@ -789,20 +789,20 @@ TQString PolygonBCVConstructor::selectStatement(
return "";
}
-void PolygonBCVConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+void PolygonBCVConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& doc ) const
{
- if ( parents.size() < 3 || parents.size() > 4 ) return;
+ if ( tqparents.size() < 3 || tqparents.size() > 4 ) return;
- assert ( parents[0]->imp()->inherits( PointImp::stype() ) &&
- parents[1]->imp()->inherits( PointImp::stype() ) &&
- parents[2]->imp()->inherits( IntImp::stype() ) );
+ assert ( tqparents[0]->imp()->inherits( PointImp::stype() ) &&
+ tqparents[1]->imp()->inherits( PointImp::stype() ) &&
+ tqparents[2]->imp()->inherits( IntImp::stype() ) );
- if ( parents.size() == 4 )
- assert ( parents[3]->imp()->inherits( IntImp::stype() ) );
+ if ( tqparents.size() == 4 )
+ assert ( tqparents[3]->imp()->inherits( IntImp::stype() ) );
Args args;
- std::transform( parents.begin(), parents.end(),
+ std::transform( tqparents.begin(), tqparents.end(),
std::back_inserter( args ), std::mem_fun( &ObjectCalcer::imp ) );
ObjectImp* data = mtype->calc( args, doc );
@@ -878,16 +878,16 @@ ConicConicIntersectionConstructor::~ConicConicIntersectionConstructor()
{
}
-void ConicConicIntersectionConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+void ConicConicIntersectionConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const
{
- if ( parents.size() != 2 ) return;
- assert ( parents[0]->imp()->inherits( ConicImp::stype() ) &&
- parents[1]->imp()->inherits( ConicImp::stype() ) );
+ if ( tqparents.size() != 2 ) return;
+ assert ( tqparents[0]->imp()->inherits( ConicImp::stype() ) &&
+ tqparents[1]->imp()->inherits( ConicImp::stype() ) );
const ConicCartesianData conica =
- static_cast<const ConicImp*>( parents[0]->imp() )->cartesianData();
+ static_cast<const ConicImp*>( tqparents[0]->imp() )->cartesianData();
const ConicCartesianData conicb =
- static_cast<const ConicImp*>( parents[1]->imp() )->cartesianData();
+ static_cast<const ConicImp*>( tqparents[1]->imp() )->cartesianData();
bool ok = true;
for ( int wr = -1; wr < 2; wr += 2 )
{
@@ -1179,23 +1179,23 @@ void MeasureTransportConstructor::handlePrelim(
) const
{
p.setBrushStyle( Qt::NoBrush );
- p.setBrushColor( Qt::red );
- p.setPen( TQPen ( Qt::red, 1) );
+ p.setBrushColor( TQt::red );
+ p.setPen( TQPen ( TQt::red, 1) );
p.setWidth( -1 ); // -1 means the default width for the object being
// drawn..
- ObjectDrawer drawer( Qt::red );
+ ObjectDrawer drawer( TQt::red );
drawprelim( drawer, p, os, d );
}
void MeasureTransportConstructor::drawprelim( const ObjectDrawer& drawer,
KigPainter& p,
- const std::vector<ObjectCalcer*>& parents,
+ const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& doc ) const
{
Args args;
using namespace std;
- transform( parents.begin(), parents.end(),
+ transform( tqparents.begin(), tqparents.end(),
back_inserter( args ), mem_fun( &ObjectCalcer::imp ) );
ObjectImp* data = mtype->calc( args, doc );
drawer.draw( *data, p, true );
@@ -1236,13 +1236,13 @@ TQString MeasureTransportConstructor::selectStatement(
}
std::vector<ObjectHolder*> MeasureTransportConstructor::build(
- const std::vector<ObjectCalcer*>& parents,
+ const std::vector<ObjectCalcer*>& tqparents,
KigDocument&, KigWidget& ) const
{
- assert ( parents.size() == 3 );
+ assert ( tqparents.size() == 3 );
// std::vector<ObjectCalcer*> args;
-// for ( uint i = 0; i < count; ++i ) args.push_back( parents[i] );
- ObjectTypeCalcer* calcer = new ObjectTypeCalcer( mtype, parents );
+// for ( uint i = 0; i < count; ++i ) args.push_back( tqparents[i] );
+ ObjectTypeCalcer* calcer = new ObjectTypeCalcer( mtype, tqparents );
ObjectHolder* h = new ObjectHolder( calcer );
std::vector<ObjectHolder*> ret;
ret.push_back( h );
@@ -1362,7 +1362,7 @@ TQString GenericIntersectionConstructor::useText(
break;
}
- return TQString::null;
+ return TQString();
}
static const ArgsParser::spec argsspecMidPointOfTwoPoints[] =
@@ -1386,15 +1386,15 @@ MidPointOfTwoPointsConstructor::~MidPointOfTwoPointsConstructor()
}
void MidPointOfTwoPointsConstructor::drawprelim(
- const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+ const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const
{
- if ( parents.size() != 2 ) return;
- assert( parents[0]->imp()->inherits( PointImp::stype() ) );
- assert( parents[1]->imp()->inherits( PointImp::stype() ) );
+ if ( tqparents.size() != 2 ) return;
+ assert( tqparents[0]->imp()->inherits( PointImp::stype() ) );
+ assert( tqparents[1]->imp()->inherits( PointImp::stype() ) );
const Coordinate m =
- ( static_cast<const PointImp*>( parents[0]->imp() )->coordinate() +
- static_cast<const PointImp*>( parents[1]->imp() )->coordinate() ) / 2;
+ ( static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate() +
+ static_cast<const PointImp*>( tqparents[1]->imp() )->coordinate() ) / 2;
drawer.draw( PointImp( m ), p, true );
}
@@ -1403,7 +1403,7 @@ std::vector<ObjectHolder*> MidPointOfTwoPointsConstructor::build(
{
ObjectTypeCalcer* seg = new ObjectTypeCalcer( SegmentABType::instance(), os );
seg->calc( d );
- int index = seg->imp()->propertiesInternalNames().findIndex( "mid-point" );
+ int index = seg->imp()->propertiesInternalNames().tqfindIndex( "mid-point" );
assert( index != -1 );
ObjectPropertyCalcer* prop = new ObjectPropertyCalcer( seg, index );
prop->calc( d );
@@ -1542,7 +1542,7 @@ TQString TangentConstructor::useText(
else if ( o.imp()->inherits( PointImp::stype() ) )
return i18n( "Tangent at This Point" );
// else assert( false );
- return TQString::null;
+ return TQString();
}
//TQString TangentConstructor::selectStatement(
@@ -1604,7 +1604,7 @@ TQString CocConstructor::useText(
return i18n( "Center of Curvature of This Curve" );
else if ( o.imp()->inherits( PointImp::stype() ) )
return i18n( "Center of Curvature at This Point" );
- return TQString::null;
+ return TQString();
}
bool relativePrimes( int n, int p )
diff --git a/kig/misc/special_constructors.h b/kig/misc/special_constructors.h
index 5b80693c..796c8cd0 100644
--- a/kig/misc/special_constructors.h
+++ b/kig/misc/special_constructors.h
@@ -29,7 +29,7 @@ public:
PolygonVertexTypeConstructor();
~PolygonVertexTypeConstructor();
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents, const KigDocument& ) const;
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents, const KigDocument& ) const;
std::vector<ObjectHolder*> build( const std::vector<ObjectCalcer*>& os, KigDocument& d, KigWidget& w ) const;
void plug( KigPart* doc, KigGUIAction* kact );
bool isTransform() const;
@@ -44,7 +44,7 @@ public:
PolygonSideTypeConstructor();
~PolygonSideTypeConstructor();
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents, const KigDocument& ) const;
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents, const KigDocument& ) const;
std::vector<ObjectHolder*> build( const std::vector<ObjectCalcer*>& os, KigDocument& d, KigWidget& w ) const;
void plug( KigPart* doc, KigGUIAction* kact );
bool isTransform() const;
@@ -83,7 +83,7 @@ public:
const KigWidget& v
) const;
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents, const KigDocument& ) const;
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents, const KigDocument& ) const;
std::vector<ObjectHolder*> build( const std::vector<ObjectCalcer*>& os, KigDocument& d, KigWidget& w ) const;
void plug( KigPart* doc, KigGUIAction* kact );
bool isTransform() const;
@@ -121,7 +121,7 @@ public:
const KigDocument& d,
const KigWidget& v
) const;
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents, const KigDocument& ) const;
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents, const KigDocument& ) const;
std::vector<ObjectHolder*> build( const std::vector<ObjectCalcer*>& os, KigDocument& d, KigWidget& w ) const;
void plug( KigPart* doc, KigGUIAction* kact );
bool isTransform() const;
@@ -163,7 +163,7 @@ public:
const KigWidget& v
) const;
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents, const KigDocument& ) const;
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents, const KigDocument& ) const;
std::vector<ObjectHolder*> build( const std::vector<ObjectCalcer*>& os, KigDocument& d, KigWidget& w ) const;
void plug( KigPart* doc, KigGUIAction* kact );
bool isTransform() const;
@@ -179,7 +179,7 @@ public:
~ConicRadicalConstructor();
TQString useText( const ObjectCalcer& o, const std::vector<ObjectCalcer*>& sel, const KigDocument& d,
const KigWidget& v ) const;
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents, const KigDocument& ) const;
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents, const KigDocument& ) const;
std::vector<ObjectHolder*> build( const std::vector<ObjectCalcer*>& os, KigDocument& d, KigWidget& w ) const;
void plug( KigPart* doc, KigGUIAction* kact );
@@ -205,7 +205,7 @@ public:
TQString useText( const ObjectCalcer& o, const std::vector<ObjectCalcer*>& sel, const KigDocument& d,
const KigWidget& v ) const;
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents, const KigDocument& ) const;
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents, const KigDocument& ) const;
std::vector<ObjectHolder*> build( const std::vector<ObjectCalcer*>& os, KigDocument& d, KigWidget& w ) const;
void plug( KigPart* doc, KigGUIAction* kact );
@@ -259,7 +259,7 @@ class MidPointOfTwoPointsConstructor
public:
MidPointOfTwoPointsConstructor();
~MidPointOfTwoPointsConstructor();
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const;
std::vector<ObjectHolder*> build( const std::vector<ObjectCalcer*>& os, KigDocument& d,
KigWidget& w ) const;
@@ -275,7 +275,7 @@ public:
TestConstructor( const ArgsParserObjectType* type, const char* descname,
const char* desc, const char* iconfile );
~TestConstructor();
- void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& parents,
+ void drawprelim( const ObjectDrawer& drawer, KigPainter& p, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& ) const;
std::vector<ObjectHolder*> build( const std::vector<ObjectCalcer*>& os, KigDocument& d,
KigWidget& w ) const;
diff --git a/kig/modes/base_mode.cc b/kig/modes/base_mode.cc
index d968566b..e470f938 100644
--- a/kig/modes/base_mode.cc
+++ b/kig/modes/base_mode.cc
@@ -38,7 +38,7 @@ BaseMode::~BaseMode()
void BaseMode::leftClicked( TQMouseEvent* e, KigWidget* v )
{
// touch screens don't send a mouseMoved event before a click event,
- // apparently, so we simulate it.
+ // aptqparently, so we simulate it.
mouseMoved( e, v );
// get rid of text still showing...
@@ -46,9 +46,9 @@ void BaseMode::leftClicked( TQMouseEvent* e, KigWidget* v )
v->updateWidget();
mplc = e->pos();
- moco = mdoc.document().whatAmIOn( v->fromScreen( mplc ), *v );
+ tqmoco = mdoc.document().whatAmIOn( v->fromScreen( mplc ), *v );
- if( moco.empty() )
+ if( tqmoco.empty() )
{
// clicked on an empty spot --> we show the rectangle for
// selecting stuff...
@@ -66,8 +66,8 @@ void BaseMode::leftClicked( TQMouseEvent* e, KigWidget* v )
void BaseMode::leftMouseMoved( TQMouseEvent* e, KigWidget* w )
{
- if( !moco.empty() && ( mplc - e->pos() ).manhattanLength() > 3 )
- dragObject( moco, mplc, *w,
+ if( !tqmoco.empty() && ( mplc - e->pos() ).manhattanLength() > 3 )
+ dragObject( tqmoco, mplc, *w,
( e->state() & (ShiftButton | ControlButton ) ) != 0
);
}
@@ -79,16 +79,16 @@ void BaseMode::leftReleased( TQMouseEvent* e, KigWidget* v )
ObjectHolder* o = 0;
bool keyCtrl = ( e->state() & ControlButton ) != 0;
bool keyShift = ( e->state() & ShiftButton ) != 0;
- if ( ! moco.empty() )
+ if ( ! tqmoco.empty() )
{
if ( keyShift )
{
- int id = ObjectChooserPopup::getObjectFromList( e->pos(), v, moco );
+ int id = ObjectChooserPopup::getObjectFromList( e->pos(), v, tqmoco );
if ( id >= 0 )
- o = moco[id];
+ o = tqmoco[id];
}
else
- o = moco.front();
+ o = tqmoco.front();
}
leftClickedObject( o, e->pos(), *v, keyCtrl );
}
@@ -100,7 +100,7 @@ void BaseMode::midClicked( TQMouseEvent* e, KigWidget* v )
v->updateWidget();
mplc = e->pos();
- moco = mdoc.document().whatAmIOn( v->fromScreen( e->pos() ), *v );
+ tqmoco = mdoc.document().whatAmIOn( v->fromScreen( e->pos() ), *v );
}
void BaseMode::midReleased( TQMouseEvent* e, KigWidget* v )
@@ -119,15 +119,15 @@ void BaseMode::rightClicked( TQMouseEvent* e, KigWidget* w )
w->setCursor( KCursor::arrowCursor() );
mplc = e->pos();
- moco = mdoc.document().whatAmIOn( w->fromScreen( mplc ), *w );
+ tqmoco = mdoc.document().whatAmIOn( w->fromScreen( mplc ), *w );
- rightClicked( moco, mplc, *w );
+ rightClicked( tqmoco, mplc, *w );
}
void BaseMode::mouseMoved( TQMouseEvent* e, KigWidget* w )
{
std::vector<ObjectHolder*> os = mdoc.document().whatAmIOn( w->fromScreen( e->pos() ), *w );
- mouseMoved( os, e->pos(), *w, e->state() & Qt::ShiftButton );
+ mouseMoved( os, e->pos(), *w, e->state() & TQt::ShiftButton );
}
void BaseMode::dragRect( const TQPoint&, KigWidget& )
@@ -151,7 +151,7 @@ void BaseMode::enableActions()
std::vector<ObjectHolder*> BaseMode::oco()
{
- return moco;
+ return tqmoco;
}
TQPoint BaseMode::pointLocation()
diff --git a/kig/modes/base_mode.h b/kig/modes/base_mode.h
index cb029abf..044b8b65 100644
--- a/kig/modes/base_mode.h
+++ b/kig/modes/base_mode.h
@@ -31,7 +31,7 @@ class BaseMode
: public KigMode
{
TQPoint mplc;
- std::vector<ObjectHolder*> moco;
+ std::vector<ObjectHolder*> tqmoco;
void leftClicked( TQMouseEvent* e, KigWidget* v );
void leftMouseMoved( TQMouseEvent*, KigWidget* );
diff --git a/kig/modes/construct_mode.cc b/kig/modes/construct_mode.cc
index b535ee5c..67f83632 100644
--- a/kig/modes/construct_mode.cc
+++ b/kig/modes/construct_mode.cc
@@ -69,20 +69,20 @@ void BaseConstructMode::leftReleased( TQMouseEvent* e, KigWidget* v )
ObjectHolder* o = 0;
bool keyCtrlOrShift = ( e->state() & ( ControlButton | ShiftButton) ) != 0;
- std::vector<ObjectHolder*> moco = oco();
- if ( ! moco.empty() )
+ std::vector<ObjectHolder*> tqmoco = oco();
+ if ( ! tqmoco.empty() )
{
std::vector<ObjectHolder*> goodargs;
- if ( !moco.empty() )
+ if ( !tqmoco.empty() )
{
std::vector<ObjectHolder*>::const_iterator it;
- std::vector<ObjectCalcer*> testargs = getCalcers( mparents );
- for ( std::vector<ObjectHolder*>::const_iterator i = moco.begin(); i != moco.end(); ++i )
+ std::vector<ObjectCalcer*> testargs = getCalcers( mtqparents );
+ for ( std::vector<ObjectHolder*>::const_iterator i = tqmoco.begin(); i != tqmoco.end(); ++i )
{
- it = std::find( mparents.begin(), mparents.end(), *i );
+ it = std::find( mtqparents.begin(), mtqparents.end(), *i );
bool newdup =
- ( it == mparents.end() ) ||
- isAlreadySelectedOK( testargs, it - mparents.begin() );
+ ( it == mtqparents.end() ) ||
+ isAlreadySelectedOK( testargs, it - mtqparents.begin() );
if ( newdup )
{
testargs.push_back( ( *i )->calcer() );
@@ -103,16 +103,16 @@ void BaseConstructMode::leftReleased( TQMouseEvent* e, KigWidget* v )
void BaseConstructMode::leftClickedObject(
ObjectHolder* o, const TQPoint& p, KigWidget& w, bool )
{
- std::vector<ObjectHolder*>::iterator it = std::find( mparents.begin(), mparents.end(), o );
- std::vector<ObjectCalcer*> nargs = getCalcers( mparents );
+ std::vector<ObjectHolder*>::iterator it = std::find( mtqparents.begin(), mtqparents.end(), o );
+ std::vector<ObjectCalcer*> nargs = getCalcers( mtqparents );
//
// mp: duplicationchecked controls whether the arguments list is
// free of duplications or if a duplication is safe (asking this to
// the Constructor class through the "isAlreadySelectedOK" method).
//
bool duplicationchecked =
- ( it == mparents.end() ) ||
- isAlreadySelectedOK( nargs, it - mparents.begin() );
+ ( it == mtqparents.end() ) ||
+ isAlreadySelectedOK( nargs, it - mtqparents.begin() );
if ( o && duplicationchecked )
{
nargs.push_back( o->calcer() );
@@ -123,7 +123,7 @@ void BaseConstructMode::leftClickedObject(
}
}
- nargs = getCalcers( mparents );
+ nargs = getCalcers( mtqparents );
nargs.push_back( mpt.get() );
if ( wantArgs( nargs, mdoc.document(), w ) )
{
@@ -137,7 +137,7 @@ void BaseConstructMode::leftClickedObject(
return;
}
- nargs = getCalcers( mparents );
+ nargs = getCalcers( mtqparents );
nargs.push_back( mcursor );
if ( wantArgs( nargs, mdoc.document(), w ) )
@@ -157,7 +157,7 @@ void BaseConstructMode::leftClickedObject(
void BaseConstructMode::midClicked( const TQPoint& p, KigWidget& w )
{
- std::vector<ObjectCalcer*> args = getCalcers( mparents );
+ std::vector<ObjectCalcer*> args = getCalcers( mtqparents );
args.push_back( mpt.get() );
if ( wantArgs( args, mdoc.document(), w ) )
{
@@ -179,10 +179,10 @@ void BaseConstructMode::rightClicked( const std::vector<ObjectHolder*>&, const T
void BaseConstructMode::mouseMoved( const std::vector<ObjectHolder*>& os, const TQPoint& p,
KigWidget& w, bool shiftpressed )
{
- mdoc.emitStatusBarText( selectStatement( getCalcers( mparents ), w ) );
+ mdoc.emitStatusBarText( selectStatement( getCalcers( mtqparents ), w ) );
w.updateCurPix();
- KigPainter pter( w.screenInfo(), &w.curPix, mdoc.document() );
+ KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
Coordinate ncoord = w.fromScreen( p );
if ( shiftpressed )
@@ -192,19 +192,19 @@ void BaseConstructMode::mouseMoved( const std::vector<ObjectHolder*>& os, const
mcursor->move( ncoord, mdoc.document() );
mcursor->calc( mdoc.document() );
- std::vector<ObjectCalcer*> args = getCalcers( mparents );
+ std::vector<ObjectCalcer*> args = getCalcers( mtqparents );
bool duplicationchecked = false;
std::vector<ObjectHolder*> goodargs;
if ( ! os.empty() )
{
std::vector<ObjectHolder*>::const_iterator it;
- std::vector<ObjectCalcer*> testargs = getCalcers( mparents );
+ std::vector<ObjectCalcer*> testargs = getCalcers( mtqparents );
for ( std::vector<ObjectHolder*>::const_iterator i = os.begin(); i != os.end(); ++i )
{
- it = std::find( mparents.begin(), mparents.end(), *i );
+ it = std::find( mtqparents.begin(), mtqparents.end(), *i );
bool newdup =
- ( it == mparents.end() ) ||
- isAlreadySelectedOK( args, it - mparents.begin() );
+ ( it == mtqparents.end() ) ||
+ isAlreadySelectedOK( args, it - mtqparents.begin() );
if ( newdup )
{
testargs.push_back( ( *i )->calcer() );
@@ -229,9 +229,9 @@ void BaseConstructMode::mouseMoved( const std::vector<ObjectHolder*>& os, const
}
else
{
- std::vector<ObjectCalcer*> args = getCalcers( mparents );
+ std::vector<ObjectCalcer*> args = getCalcers( mtqparents );
args.push_back( mpt.get() );
- std::vector<ObjectCalcer*> argscursor = getCalcers( mparents );
+ std::vector<ObjectCalcer*> argscursor = getCalcers( mtqparents );
argscursor.push_back( mcursor );
bool text = true;
if ( wantArgs( args, mdoc.document(), w ) )
@@ -274,15 +274,15 @@ void BaseConstructMode::mouseMoved( const std::vector<ObjectHolder*>& os, const
void BaseConstructMode::selectObject( ObjectHolder* o, KigWidget& w )
{
- mparents.push_back( o );
- std::vector<ObjectCalcer*> args = getCalcers( mparents );
+ mtqparents.push_back( o );
+ std::vector<ObjectCalcer*> args = getCalcers( mtqparents );
if ( wantArgs( args, mdoc.document(), w ) == ArgsParser::Complete )
{
handleArgs( args, w );
};
- w.redrawScreen( mparents );
+ w.redrawScreen( mtqparents );
}
PointConstructMode::PointConstructMode( KigPart& d )
@@ -308,7 +308,7 @@ void PointConstructMode::leftClickedObject(
mdoc.addObject( new ObjectHolder( mpt.get() ) );
w.redrawScreen( std::vector<ObjectHolder*>() );
- mdoc.emitStatusBarText( TQString::null );
+ mdoc.emitStatusBarText( TQString() );
mdoc.doneMode( this );
}
@@ -330,7 +330,7 @@ void PointConstructMode::mouseMoved(
bool shiftpressed )
{
w.updateCurPix();
- KigPainter pter( w.screenInfo(), &w.curPix, mdoc.document() );
+ KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
Coordinate ncoord = w.fromScreen( p );
if ( shiftpressed )
@@ -373,7 +373,7 @@ void BaseConstructMode::selectObjects( const std::vector<ObjectHolder*>& os, Kig
{
for ( std::vector<ObjectHolder*>::const_iterator i = os.begin(); i != os.end(); ++i )
{
- std::vector<ObjectCalcer*> args = getCalcers( mparents );
+ std::vector<ObjectCalcer*> args = getCalcers( mtqparents );
assert( wantArgs( args, mdoc.document(), w ) != ArgsParser::Complete );
selectObject( *i, w );
};
@@ -482,22 +482,22 @@ void TestConstructMode::leftClickedObject( ObjectHolder* o, const TQPoint& p,
TQPoint qloc = p + TQPoint( -40, 0 );
Coordinate loc = w.fromScreen( qloc );
- std::vector<ObjectCalcer*> parents;
- parents.push_back( new ObjectConstCalcer( new IntImp( test_has_frame_dflt ) ) );
- parents.push_back( new ObjectConstCalcer( new PointImp( loc ) ) );
- parents.push_back( new ObjectConstCalcer( new StringImp( TQString::fromLatin1( "%1" ) ) ) );
+ std::vector<ObjectCalcer*> tqparents;
+ tqparents.push_back( new ObjectConstCalcer( new IntImp( test_has_frame_dflt ) ) );
+ tqparents.push_back( new ObjectConstCalcer( new PointImp( loc ) ) );
+ tqparents.push_back( new ObjectConstCalcer( new StringImp( TQString::tqfromLatin1( "%1" ) ) ) );
assert( mresult->imp()->inherits( TestResultImp::stype() ) );
- parents.push_back(
+ tqparents.push_back(
new ObjectPropertyCalcer(
- mresult.get(), mresult->imp()->propertiesInternalNames().findIndex( "test-result" ) ) );
- parents.back()->calc( mdoc.document() );
+ mresult.get(), mresult->imp()->propertiesInternalNames().tqfindIndex( "test-result" ) ) );
+ tqparents.back()->calc( mdoc.document() );
- ObjectCalcer* ret = new ObjectTypeCalcer( TextType::instance(), parents );
+ ObjectCalcer* ret = new ObjectTypeCalcer( TextType::instance(), tqparents );
ret->calc( mdoc.document() );
mdoc.addObject( new ObjectHolder( ret ) );
w.unsetCursor();
- mdoc.emitStatusBarText( TQString::null );
+ mdoc.emitStatusBarText( TQString() );
finish();
}
@@ -529,7 +529,7 @@ void TestConstructMode::mouseMoved( const std::vector<ObjectHolder*>& os, const
w.setCursor( KCursor::blankCursor() );
w.updateCurPix();
- KigPainter pter( w.screenInfo(), &w.curPix, mdoc.document() );
+ KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
TQPoint qloc = p + TQPoint( -40, 0 );
Coordinate loc = w.fromScreen( qloc );
@@ -557,7 +557,7 @@ TQString TestConstructMode::selectStatement( const std::vector<ObjectCalcer*>& s
transform( sel.begin(), sel.end(), back_inserter( args ), mem_fun( &ObjectCalcer::imp ) );
std::string ret = mtype->argsParser().selectStatement( args );
- if ( ret.empty() ) return TQString::null;
+ if ( ret.empty() ) return TQString();
return i18n( ret.c_str() );
}
diff --git a/kig/modes/construct_mode.h b/kig/modes/construct_mode.h
index be937723..67fe5e28 100644
--- a/kig/modes/construct_mode.h
+++ b/kig/modes/construct_mode.h
@@ -71,7 +71,7 @@ class BaseConstructMode
// only sensible place where to deallocate it is in the destructor
// of this class
// ObjectHolder* mcursorholder;
- std::vector<ObjectHolder*> mparents;
+ std::vector<ObjectHolder*> mtqparents;
void leftReleased( TQMouseEvent* e, KigWidget* v );
diff --git a/kig/modes/dragrectmode.cc b/kig/modes/dragrectmode.cc
index 3a827009..8091f8cb 100644
--- a/kig/modes/dragrectmode.cc
+++ b/kig/modes/dragrectmode.cc
@@ -48,7 +48,7 @@ void DragRectMode::moved( const TQPoint& p, KigWidget& w )
std::vector<TQRect> overlay;
if ( mstartselected )
{
- KigPainter pt( w.screenInfo(), &w.curPix, mdoc.document() );
+ KigPainter pt( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
pt.drawFilledRect( TQRect( p, mstart ) );
overlay = pt.overlay();
};
diff --git a/kig/modes/edittype.cc b/kig/modes/edittype.cc
index f4ed323e..e9776204 100644
--- a/kig/modes/edittype.cc
+++ b/kig/modes/edittype.cc
@@ -31,8 +31,8 @@
#include <kpushbutton.h>
#include <kstdguiitem.h>
-EditType::EditType( TQWidget* parent, TQString name, TQString desc, TQString icon )
- : EditTypeBase( parent, "edittype", true ), mname( name ), mdesc( desc ), micon( icon )
+EditType::EditType( TQWidget* tqparent, TQString name, TQString desc, TQString icon )
+ : EditTypeBase( tqparent, "edittype", true ), mname( name ), mdesc( desc ), micon( icon )
{
// improving GUI look'n'feel...
buttonHelp->setGuiItem( KStdGuiItem::help() );
@@ -50,8 +50,8 @@ EditType::~EditType()
void EditType::helpSlot()
{
- kapp->invokeHelp( TQString::fromLatin1( "working-with-types" ),
- TQString::fromLatin1( "kig" ) );
+ kapp->invokeHelp( TQString::tqfromLatin1( "working-with-types" ),
+ TQString::tqfromLatin1( "kig" ) );
}
void EditType::okSlot()
diff --git a/kig/modes/edittype.h b/kig/modes/edittype.h
index c6f40783..ac578808 100644
--- a/kig/modes/edittype.h
+++ b/kig/modes/edittype.h
@@ -28,12 +28,13 @@
class EditType : public EditTypeBase
{
Q_OBJECT
+ TQ_OBJECT
TQString mname;
TQString mdesc;
TQString micon;
public:
- EditType( TQWidget* parent, TQString name = TQString::null, TQString desc = TQString::null, TQString icon = TQString::null );
+ EditType( TQWidget* tqparent, TQString name = TQString(), TQString desc = TQString(), TQString icon = TQString() );
~EditType();
const TQString name() const;
const TQString description() const;
diff --git a/kig/modes/edittypebase.ui b/kig/modes/edittypebase.ui
index 0dc8129d..705bc92d 100644
--- a/kig/modes/edittypebase.ui
+++ b/kig/modes/edittypebase.ui
@@ -1,10 +1,10 @@
<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
<class>EditTypeBase</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>EditTypeBase</cstring>
</property>
- <property name="geometry">
+ <property name="tqgeometry">
<rect>
<x>0</x>
<y>0</y>
@@ -33,7 +33,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>label15</cstring>
</property>
@@ -41,23 +41,23 @@
<string>Here you can modify the name, the description and the icon of this macro type.</string>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout8</cstring>
+ <cstring>tqlayout8</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout8</cstring>
+ <cstring>tqlayout8</cstring>
</property>
<vbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -71,7 +71,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>label16</cstring>
</property>
@@ -89,7 +89,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -103,7 +103,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>label17</cstring>
</property>
@@ -123,9 +123,9 @@
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout23</cstring>
+ <cstring>tqlayout23</cstring>
</property>
<vbox>
<property name="name">
@@ -152,7 +152,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -177,9 +177,9 @@
<enum>Horizontal</enum>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout24</cstring>
+ <cstring>tqlayout24</cstring>
</property>
<hbox>
<property name="name">
@@ -212,7 +212,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -270,12 +270,12 @@
<slot>cancelSlot()</slot>
</connection>
</connections>
-<slots>
+<Q_SLOTS>
<slot>helpSlot()</slot>
<slot>okSlot()</slot>
<slot>cancelSlot()</slot>
-</slots>
-<layoutdefaults spacing="6" margin="11"/>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>klineedit.h</includehint>
<includehint>klineedit.h</includehint>
diff --git a/kig/modes/label.cc b/kig/modes/label.cc
index 578e15dd..3471d6dc 100644
--- a/kig/modes/label.cc
+++ b/kig/modes/label.cc
@@ -55,8 +55,8 @@ public:
TQPoint plc;
// the currently selected coordinate
Coordinate mcoord;
- // the possible parent object that defines the location of the label..
- ObjectCalcer* locationparent;
+ // the possible tqparent object that defines the location of the label..
+ ObjectCalcer* locationtqparent;
// the text is only kept in the text input widget, not here
// TQString mtext;
@@ -64,8 +64,8 @@ public:
// the property objects we'll be using as args, we keep a reference
// to them in the args object, and keep a pointer to them ( or 0 )
// in the correct order in args ( separately, because we can't use
- // the order of the parents of a ReferenceObject, and certainly
- // can't give 0 as a parent..
+ // the order of the tqparents of a ReferenceObject, and certainly
+ // can't give 0 as a tqparent..
argvect args;
// if we're ReallySelectingArgs, then this var points to the arg
@@ -90,7 +90,7 @@ TextLabelModeBase::~TextLabelModeBase()
TextLabelModeBase::TextLabelModeBase( KigPart& doc )
: KigMode( doc ), d( new Private )
{
- d->locationparent = 0;
+ d->locationtqparent = 0;
d->lpc = 0;
d->mwawd = SelectingLocation;
d->wiz = new TextLabelWizard( doc.widget(), this );
@@ -212,7 +212,7 @@ void TextLabelModeBase::mouseMoved( TQMouseEvent* e, KigWidget* w )
{
std::vector<ObjectHolder*> os = mdoc.document().whatAmIOn( w->fromScreen( e->pos() ), *w );
bool attachable = false;
- d->locationparent = 0;
+ d->locationtqparent = 0;
for ( std::vector<ObjectHolder*>::iterator i = os.begin(); i != os.end(); ++i )
{
if( (*i)->imp()->attachPoint().valid() ||
@@ -220,7 +220,7 @@ void TextLabelModeBase::mouseMoved( TQMouseEvent* e, KigWidget* w )
(*i)->imp()->inherits( CurveImp::stype() ) )
{
attachable = true;
- d->locationparent = (*i)->calcer();
+ d->locationtqparent = (*i)->calcer();
break;
};
};
@@ -228,10 +228,10 @@ void TextLabelModeBase::mouseMoved( TQMouseEvent* e, KigWidget* w )
if ( attachable )
{
w->setCursor( KCursor::handCursor() );
- TQString s = d->locationparent->imp()->type()->attachToThisStatement();
+ TQString s = d->locationtqparent->imp()->type()->attachToThisStatement();
mdoc.emitStatusBarText( s );
- KigPainter p( w->screenInfo(), &w->curPix, mdoc.document() );
+ KigPainter p( w->screenInfo(), TQT_TQPAINTDEVICE(&w->curPix), mdoc.document() );
// set the text next to the arrow cursor
TQPoint point = e->pos();
@@ -296,7 +296,7 @@ void TextLabelModeBase::finishPressed()
"value for. Please remove them or select enough arguments." ) );
else
{
- finish( d->mcoord, s, d->args, needframe, d->locationparent );
+ finish( d->mcoord, s, d->args, needframe, d->locationtqparent );
killMode();
};
}
@@ -376,7 +376,7 @@ void TextLabelModeBase::updateLinksLabel()
}
else
// otherwise, we show a stub...
- linktext = i18n( "argument %1" ).arg( count + 1 );
+ linktext = i18n( "argument %1" ).tqarg( count + 1 );
d->wiz->myCustomWidget1->addLink( linktext, buf );
// set pos and prevpos to the next char after the last match, so
@@ -391,7 +391,7 @@ void TextLabelModeBase::updateLinksLabel()
d->wiz->myCustomWidget1->addText( s.mid( prevpos ), buf );
d->wiz->myCustomWidget1->applyEdit( buf );
- d->wiz->relayoutArgsPage();
+ d->wiz->retqlayoutArgsPage();
d->wiz->resize( d->wiz->size() );
}
@@ -406,7 +406,7 @@ void TextLabelModeBase::linkClicked( int i )
d->mwawd = ReallySelectingArgs;
d->mwaaws = i;
- mdoc.emitStatusBarText( i18n( "Selecting argument %1" ).arg( i + 1 ) );
+ mdoc.emitStatusBarText( i18n( "Selecting argument %1" ).tqarg( i + 1 ) );
}
void TextLabelModeBase::redrawScreen( KigWidget* w )
@@ -452,7 +452,7 @@ TextLabelConstructionMode::~TextLabelConstructionMode()
void TextLabelConstructionMode::finish(
const Coordinate& coord, const TQString& s,
const argvect& props, bool needframe,
- ObjectCalcer* locationparent )
+ ObjectCalcer* locationtqparent )
{
std::vector<ObjectCalcer*> args;
for ( argvect::const_iterator i = props.begin();
@@ -460,8 +460,8 @@ void TextLabelConstructionMode::finish(
args.push_back( i->get() );
ObjectHolder* label = 0;
- if ( locationparent )
- label = ObjectFactory::instance()->attachedLabel( s, locationparent, coord, needframe, args, mdoc.document() );
+ if ( locationtqparent )
+ label = ObjectFactory::instance()->attachedLabel( s, locationtqparent, coord, needframe, args, mdoc.document() );
else
label = ObjectFactory::instance()->label( s, coord, needframe, args, mdoc.document() );
mdoc.addObject( label );
@@ -471,10 +471,10 @@ TextLabelRedefineMode::TextLabelRedefineMode( KigPart& d, ObjectTypeCalcer* labe
: TextLabelModeBase( d ), mlabel( label )
{
assert( label->imp()->inherits( TextImp::stype() ) );
- std::vector<ObjectCalcer*> parents = label->parents();
- assert( parents.size() >= 3 );
- std::vector<ObjectCalcer*> firstthree( parents.begin(), parents.begin() + 3 );
- std::vector<ObjectCalcer*> rest( parents.begin() + 3, parents.end() );
+ std::vector<ObjectCalcer*> tqparents = label->tqparents();
+ assert( tqparents.size() >= 3 );
+ std::vector<ObjectCalcer*> firstthree( tqparents.begin(), tqparents.begin() + 3 );
+ std::vector<ObjectCalcer*> rest( tqparents.begin() + 3, tqparents.end() );
firstthree = TextType::instance()->argParser().parse( firstthree );
assert( firstthree[0]->imp()->inherits( IntImp::stype() ) );
@@ -507,12 +507,12 @@ TextLabelRedefineMode::~TextLabelRedefineMode()
void TextLabelRedefineMode::finish(
const Coordinate& coord, const TQString& s,
const argvect& props, bool needframe,
- ObjectCalcer* locationparent )
+ ObjectCalcer* locationtqparent )
{
- std::vector<ObjectCalcer*> parents = mlabel->parents();
- assert( parents.size() >= 3 );
- std::vector<ObjectCalcer*> firstthree( parents.begin(), parents.begin() + 3 );
- std::vector<ObjectCalcer*> rest( parents.begin() + 3, parents.end() );
+ std::vector<ObjectCalcer*> tqparents = mlabel->tqparents();
+ assert( tqparents.size() >= 3 );
+ std::vector<ObjectCalcer*> firstthree( tqparents.begin(), tqparents.begin() + 3 );
+ std::vector<ObjectCalcer*> rest( tqparents.begin() + 3, tqparents.end() );
firstthree = TextType::instance()->argParser().parse( firstthree );
KigCommand* kc = new KigCommand( mdoc, i18n( "Change Label" ) );
@@ -538,7 +538,7 @@ void TextLabelRedefineMode::finish(
static_cast<ObjectConstCalcer*>( firstthree[2] )->setImp( new StringImp( s ) );
mon.finish( kc );
- std::vector<ObjectCalcer*> oldparents = mlabel->parents();
+ std::vector<ObjectCalcer*> oldtqparents = mlabel->tqparents();
std::vector<ObjectCalcer*> p;
for ( argvect::const_iterator i = props.begin();
i != props.end(); ++i )
@@ -552,19 +552,19 @@ void TextLabelRedefineMode::finish(
* take advantage of the method "getAttachPoint" that should
* do all the work; it is also used when creating a new label
*/
- np[1] = ObjectFactory::instance()->getAttachPoint( locationparent, coord, mdoc.document() );
+ np[1] = ObjectFactory::instance()->getAttachPoint( locationtqparent, coord, mdoc.document() );
/* this is the old code, just in case... */
-// if ( locationparent && locationparent->imp()->inherits( CurveImp::stype() ) )
+// if ( locationtqparent && locationtqparent->imp()->inherits( CurveImp::stype() ) )
// {
-// double param = static_cast<const CurveImp*>( locationparent->imp() )->getParam( coord, mdoc.document() );
-// np[1] = ObjectFactory::instance()->constrainedPointCalcer( locationparent, param );
+// double param = static_cast<const CurveImp*>( locationtqparent->imp() )->getParam( coord, mdoc.document() );
+// np[1] = ObjectFactory::instance()->constrainedPointCalcer( locationtqparent, param );
// np[1]->calc( mdoc.document() );
// }
-// else if ( locationparent )
+// else if ( locationtqparent )
// {
-// assert( locationparent->imp()->inherits( PointImp::stype() ) );
-// np[1] = locationparent;
+// assert( locationtqparent->imp()->inherits( PointImp::stype() ) );
+// np[1] = locationtqparent;
// }
// else
// np[1] = new ObjectConstCalcer( new PointImp( coord ) );
@@ -585,5 +585,5 @@ void TextLabelModeBase::setFrame( bool f )
void TextLabelModeBase::setLocationParent( ObjectCalcer* o )
{
- d->locationparent = o;
+ d->locationtqparent = o;
}
diff --git a/kig/modes/label.h b/kig/modes/label.h
index 828c2e29..7d8f842a 100644
--- a/kig/modes/label.h
+++ b/kig/modes/label.h
@@ -35,7 +35,7 @@ class ObjectCalcer;
/**
* this is the base class for TextLabelConstructionMode and
* TextLabelRedefineMode.. most of the work is done in this class,
- * with some specific things delegated to the children.. Template
+ * with some specific things delegated to the tqchildren.. Template
* method pattern, right ? :)
*/
class TextLabelModeBase
@@ -65,14 +65,14 @@ protected:
void setLocationParent( ObjectCalcer* o );
/**
* objects you pass here, should be newly created property objects,
- * that have no children..
+ * that have no tqchildren..
*/
void setPropertyObjects( const argvect& props );
void setFrame( bool f );
virtual void finish( const Coordinate& c, const TQString& s,
const argvect& props, bool needframe,
- ObjectCalcer* locationparent ) = 0;
+ ObjectCalcer* locationtqparent ) = 0;
private:
// the KigMode interface..
@@ -111,7 +111,7 @@ public:
void finish( const Coordinate& coord, const TQString& s,
const argvect& props, bool needframe,
- ObjectCalcer* locationparent );
+ ObjectCalcer* locationtqparent );
};
class TextLabelRedefineMode
@@ -120,7 +120,7 @@ class TextLabelRedefineMode
ObjectTypeCalcer* mlabel;
void finish( const Coordinate& coord, const TQString& s,
const argvect& props, bool needframe,
- ObjectCalcer* locationparent );
+ ObjectCalcer* locationtqparent );
public:
TextLabelRedefineMode( KigPart& d, ObjectTypeCalcer* label );
~TextLabelRedefineMode();
diff --git a/kig/modes/linkslabel.cpp b/kig/modes/linkslabel.cpp
index 96a73a8f..8d711d65 100644
--- a/kig/modes/linkslabel.cpp
+++ b/kig/modes/linkslabel.cpp
@@ -33,31 +33,31 @@ using namespace std;
class LinksLabel::Private
{
public:
- TQHBoxLayout* layout;
+ TQHBoxLayout* tqlayout;
std::vector<TQLabel*> labels;
std::vector<KURLLabel*> urllabels;
};
-LinksLabel::LinksLabel( TQWidget* parent, const char* name )
- : TQWidget( parent, name )
+LinksLabel::LinksLabel( TQWidget* tqparent, const char* name )
+ : TQWidget( tqparent, name )
{
p = new Private;
- p->layout = new TQHBoxLayout( this );
+ p->tqlayout = new TQHBoxLayout( this );
TQLabel* l = new TQLabel( TQString::fromUtf8( "Dit is een " ), this );
p->labels.push_back( l );
- p->layout->addWidget( l );
+ p->tqlayout->addWidget( l );
KURLLabel* u = new KURLLabel( TQString::fromUtf8( "http://www.kde.org/" ),
TQString::fromUtf8( "url"), this );
p->urllabels.push_back( u );
- p->layout->addWidget( u );
+ p->tqlayout->addWidget( u );
l = new TQLabel( TQString::fromUtf8( " !" ), this );
p->labels.push_back( l );
- p->layout->addWidget(l );
+ p->tqlayout->addWidget(l );
- p->layout->activate();
+ p->tqlayout->activate();
}
LinksLabel::~LinksLabel()
@@ -67,8 +67,8 @@ LinksLabel::~LinksLabel()
void LinksLabel::urlClicked()
{
- const TQObject* o = sender();
- std::vector<KURLLabel*>::iterator i = std::find( p->urllabels.begin(), p->urllabels.end(), static_cast<const KURLLabel*>( o ) );
+ const TQObject* o = TQT_TQOBJECT_CONST(const_cast<const TQT_BASE_OBJECT_NAME*>(sender()));
+ std::vector<KURLLabel*>::iterator i = std::find( p->urllabels.begin(), p->urllabels.end(), static_cast<const KURLLabel*>(TQT_TQWIDGET_CONST( o )) );
assert( i != p->urllabels.end() );
emit linkClicked( i - p->urllabels.begin() );
}
@@ -89,7 +89,7 @@ void LinksLabel::addLink( const TQString& s, LinksLabelEditBuf& buf )
}
namespace {
- void deleteObj( TQObject* o ) { delete o; }
+ void deleteObj( TQWidget* o ) { delete o; }
}
void LinksLabel::applyEdit( LinksLabelEditBuf& buf )
@@ -99,8 +99,8 @@ void LinksLabel::applyEdit( LinksLabelEditBuf& buf )
p->urllabels.clear();
p->labels.clear();
- delete p->layout;
- p->layout = new TQHBoxLayout( this );
+ delete p->tqlayout;
+ p->tqlayout = new TQHBoxLayout( this );
for ( LinksLabelEditBuf::vec::iterator i = buf.data.begin(); i != buf.data.end(); ++i )
{
@@ -111,7 +111,7 @@ void LinksLabel::applyEdit( LinksLabelEditBuf& buf )
KURLLabel* l = new KURLLabel( TQString::fromUtf8( "http://edu.kde.org/kig" ),
i->second, this );
p->urllabels.push_back( l );
- p->layout->addWidget( l );
+ p->tqlayout->addWidget( l );
connect( l, TQT_SIGNAL( leftClickedURL() ), TQT_SLOT( urlClicked() ) );
}
else
@@ -119,15 +119,15 @@ void LinksLabel::applyEdit( LinksLabelEditBuf& buf )
// we need a normal label...
TQLabel* l = new TQLabel( i->second, this );
p->labels.push_back( l );
- p->layout->addWidget( l );
+ p->tqlayout->addWidget( l );
};
};
TQSpacerItem* spacer = new TQSpacerItem( 40, 20, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
- p->layout->addItem( spacer );
+ p->tqlayout->addItem( spacer );
- p->layout->activate();
+ p->tqlayout->activate();
std::for_each( p->urllabels.begin(), p->urllabels.end(), mem_fun( &TQWidget::show ) );
std::for_each( p->labels.begin(), p->labels.end(), mem_fun( &TQWidget::show ) );
diff --git a/kig/modes/linkslabel.h b/kig/modes/linkslabel.h
index 89d1c76e..8ed8b04a 100644
--- a/kig/modes/linkslabel.h
+++ b/kig/modes/linkslabel.h
@@ -27,12 +27,13 @@
* this widget shows a line of text, with some links underlined, and
* emits a signal if one of the links is clicked...
*/
-class LinksLabel : public QWidget
+class LinksLabel : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- LinksLabel( TQWidget* parent = 0, const char* name = 0 );
+ LinksLabel( TQWidget* tqparent = 0, const char* name = 0 );
~LinksLabel();
class LinksLabelEditBuf
diff --git a/kig/modes/macro.cc b/kig/modes/macro.cc
index bc6f5dc5..ba6f98ab 100644
--- a/kig/modes/macro.cc
+++ b/kig/modes/macro.cc
@@ -167,7 +167,7 @@ void DefineMacroMode::dragRect( const TQPoint& p, KigWidget& w )
std::vector<ObjectHolder*>* objs = mwizard->currentPage() == mwizard->mpgiven ? &mgiven : &mfinal;
DragRectMode dm( p, mdoc, w );
mdoc.runMode( &dm );
- KigPainter pter( w.screenInfo(), &w.stillPix, mdoc.document() );
+ KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
if ( ! dm.cancelled() )
{
std::vector<ObjectHolder*> ret = dm.ret();
@@ -196,7 +196,7 @@ void DefineMacroMode::leftClickedObject( ObjectHolder* o, const TQPoint&,
if ( isselected ) objs->erase( iter );
else objs->push_back( o );
- KigPainter p( w.screenInfo(), &w.stillPix, mdoc.document() );
+ KigPainter p( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
p.drawObject( o, !isselected );
w.updateCurPix( p.overlay() );
w.updateWidget();
@@ -224,7 +224,7 @@ void DefineMacroMode::mouseMoved( const std::vector<ObjectHolder*>& os, const TQ
// statusbar text
mdoc.emitStatusBarText( selectstat );
- KigPainter p( w.screenInfo(), &w.curPix, mdoc.document() );
+ KigPainter p( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
// set the text next to the arrow cursor
TQPoint point = pt;
diff --git a/kig/modes/macrowizard.cc b/kig/modes/macrowizard.cc
index 662e3a0d..4a240b74 100644
--- a/kig/modes/macrowizard.cc
+++ b/kig/modes/macrowizard.cc
@@ -24,8 +24,8 @@
#include <klineedit.h>
#include <kapplication.h>
-MacroWizard::MacroWizard( TQWidget* parent, DefineMacroMode* m )
- : MacroWizardBase( parent, "Define Macro Wizard", false ), mmode( m )
+MacroWizard::MacroWizard( TQWidget* tqparent, DefineMacroMode* m )
+ : MacroWizardBase( tqparent, "Define Macro Wizard", false ), mmode( m )
{
connect( KLineEdit2, TQT_SIGNAL( textChanged( const TQString& ) ),
this, TQT_SLOT( nameTextChanged( const TQString& ) ) );
@@ -85,6 +85,6 @@ void MacroWizard::accept()
void MacroWizard::slotHelpClicked()
{
- kapp->invokeHelp( TQString::fromLatin1( "defining-macros"),
- TQString::fromLatin1( "kig" ) );
+ kapp->invokeHelp( TQString::tqfromLatin1( "defining-macros"),
+ TQString::tqfromLatin1( "kig" ) );
}
diff --git a/kig/modes/macrowizard.h b/kig/modes/macrowizard.h
index 96318ec9..b3b59c66 100644
--- a/kig/modes/macrowizard.h
+++ b/kig/modes/macrowizard.h
@@ -25,8 +25,9 @@ class DefineMacroMode;
class MacroWizard : public MacroWizardBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- MacroWizard( TQWidget* parent, DefineMacroMode* m );
+ MacroWizard( TQWidget* tqparent, DefineMacroMode* m );
~MacroWizard();
void back();
diff --git a/kig/modes/macrowizardbase.ui b/kig/modes/macrowizardbase.ui
index d3929ad8..db62a8b1 100644
--- a/kig/modes/macrowizardbase.ui
+++ b/kig/modes/macrowizardbase.ui
@@ -1,10 +1,10 @@
<!DOCTYPE UI><UI version="3.1" stdsetdef="1">
<class>MacroWizardBase</class>
-<widget class="QWizard">
+<widget class="TQWizard">
<property name="name">
<cstring>MacroWizardBase</cstring>
</property>
- <property name="geometry">
+ <property name="tqgeometry">
<rect>
<x>4</x>
<y>0</y>
@@ -23,7 +23,7 @@
<property name="caption">
<string>Define New Macro</string>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>mpgiven</cstring>
</property>
@@ -40,7 +40,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -55,13 +55,13 @@
<property name="text">
<string>Select the "given" objects for your new macro and press "Next".</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>WordBreak|AlignVCenter</set>
</property>
</widget>
</vbox>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>mpfinal</cstring>
</property>
@@ -78,7 +78,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>TextLabel2</cstring>
</property>
@@ -88,7 +88,7 @@
</widget>
</vbox>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>mpname</cstring>
</property>
@@ -105,7 +105,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>TextLabel1_2</cstring>
</property>
@@ -113,7 +113,7 @@
<string>Enter a name and description for your new type.</string>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -127,7 +127,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>TextLabel2_2</cstring>
</property>
@@ -145,7 +145,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -159,7 +159,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>TextLabel2_2_2</cstring>
</property>
@@ -180,7 +180,7 @@
</vbox>
</widget>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>klineedit.h</includehint>
<includehint>klineedit.h</includehint>
diff --git a/kig/modes/mode.h b/kig/modes/mode.h
index 18425d2d..e9fdd9ea 100644
--- a/kig/modes/mode.h
+++ b/kig/modes/mode.h
@@ -34,7 +34,7 @@ class StdConstructionMode;
* document... It tells us how to respond to a certain event.
*/
class KigMode
- : public Qt
+ : public TQt
{
public:
virtual ~KigMode();
diff --git a/kig/modes/moving.cc b/kig/modes/moving.cc
index 533b15d4..980a5feb 100644
--- a/kig/modes/moving.cc
+++ b/kig/modes/moving.cc
@@ -55,13 +55,13 @@ void MovingModeBase::initScreen( const std::vector<ObjectCalcer*>& in )
std::inserter( notmovingobjs, notmovingobjs.begin() ) );
mview.clearStillPix();
- KigPainter p( mview.screenInfo(), &mview.stillPix, mdoc.document() );
+ KigPainter p( mview.screenInfo(), TQT_TQPAINTDEVICE(&mview.stillPix), mdoc.document() );
p.drawGrid( mdoc.document().coordinateSystem(), mdoc.document().grid(),
mdoc.document().axes() );
p.drawObjects( notmovingobjs.begin(), notmovingobjs.end(), false );
mview.updateCurPix();
- KigPainter p2( mview.screenInfo(), &mview.curPix, mdoc.document() );
+ KigPainter p2( mview.screenInfo(), TQT_TQPAINTDEVICE(&mview.curPix), mdoc.document() );
p2.drawObjects( drawableset.begin(), drawableset.end(), true );
}
@@ -86,12 +86,12 @@ void MovingModeBase::mouseMoved( TQMouseEvent* e, KigWidget* v )
v->updateCurPix();
Coordinate c = v->fromScreen( e->pos() );
- bool snaptogrid = e->state() & Qt::ShiftButton;
+ bool snaptogrid = e->state() & TQt::ShiftButton;
moveTo( c, snaptogrid );
for ( std::vector<ObjectCalcer*>::iterator i = mcalcable.begin();
i != mcalcable.end(); ++i )
( *i )->calc( mdoc.document() );
- KigPainter p( v->screenInfo(), &v->curPix, mdoc.document() );
+ KigPainter p( v->screenInfo(), TQT_TQPAINTDEVICE(&v->curPix), mdoc.document() );
// TODO: only draw the explicitly moving objects as selected, the
// other ones as deselected.. Needs some support from the
// subclasses..
@@ -129,8 +129,8 @@ MovingMode::MovingMode( const std::vector<ObjectHolder*>& os, const Coordinate&
emo.push_back( ( *i )->calcer() );
d->refmap[( *i )->calcer()] = (*i)->moveReferencePoint();
objs.insert( ( *i )->calcer() );
- std::vector<ObjectCalcer*> parents = ( *i )->calcer()->movableParents();
- objs.insert( parents.begin(), parents.end() );
+ std::vector<ObjectCalcer*> tqparents = ( *i )->calcer()->movableParents();
+ objs.insert( tqparents.begin(), tqparents.end() );
};
emo = calcPath( emo );
@@ -143,8 +143,8 @@ MovingMode::MovingMode( const std::vector<ObjectHolder*>& os, const Coordinate&
std::set<ObjectCalcer*> tmp = objs;
for ( std::set<ObjectCalcer*>::const_iterator i = tmp.begin(); i != tmp.end(); ++i )
{
- std::set<ObjectCalcer*> children = getAllChildren(*i);
- objs.insert( children.begin(), children.end() );
+ std::set<ObjectCalcer*> tqchildren = getAllChildren(*i);
+ objs.insert( tqchildren.begin(), tqchildren.end() );
}
initScreen( calcPath( std::vector<ObjectCalcer*>( objs.begin(), objs.end() ) ) );
@@ -154,7 +154,7 @@ void MovingMode::stopMove()
{
TQString text = d->emo.size() == 1 ?
d->emo[0]->imp()->type()->moveAStatement() :
- i18n( "Move %1 Objects" ).arg( d->emo.size() );
+ i18n( "Move %1 Objects" ).tqarg( d->emo.size() );
KigCommand* mc = new KigCommand( mdoc, text );
d->mon->finish( mc );
mdoc.history()->addCommand( mc );
@@ -164,7 +164,7 @@ void MovingMode::moveTo( const Coordinate& o, bool snaptogrid )
{
for( std::vector<ObjectCalcer*>::iterator i = d->emo.begin(); i != d->emo.end(); ++i )
{
- assert( d->refmap.find( *i ) != d->refmap.end() );
+ assert( d->refmap.tqfind( *i ) != d->refmap.end() );
Coordinate nc = d->refmap[*i] + ( o - d->pwwsm );
if ( snaptogrid ) nc = mdoc.document().coordinateSystem().snapToGrid( nc, mview );
(*i)->move( nc, mdoc.document() );
@@ -176,14 +176,14 @@ PointRedefineMode::PointRedefineMode( ObjectHolder* p, KigPart& d, KigWidget& v
{
assert( dynamic_cast<ObjectTypeCalcer*>( p->calcer() ) );
moldtype = static_cast<ObjectTypeCalcer*>( p->calcer() )->type();
- std::vector<ObjectCalcer*> oldparents = p->calcer()->parents();
- std::copy( oldparents.begin(), oldparents.end(), std::back_inserter( moldparents ) );
-
- std::vector<ObjectCalcer*> parents = getAllParents( mp->calcer() );
- mmon = new MonitorDataObjects( parents );
- std::vector<ObjectCalcer*> moving = parents;
- std::set<ObjectCalcer*> children = getAllChildren( mp->calcer() );
- std::copy( children.begin(), children.end(), std::back_inserter( moving ) );
+ std::vector<ObjectCalcer*> oldtqparents = p->calcer()->tqparents();
+ std::copy( oldtqparents.begin(), oldtqparents.end(), std::back_inserter( moldtqparents ) );
+
+ std::vector<ObjectCalcer*> tqparents = getAllParents( mp->calcer() );
+ mmon = new MonitorDataObjects( tqparents );
+ std::vector<ObjectCalcer*> moving = tqparents;
+ std::set<ObjectCalcer*> tqchildren = getAllChildren( mp->calcer() );
+ std::copy( tqchildren.begin(), tqchildren.end(), std::back_inserter( moving ) );
initScreen( moving );
}
@@ -224,22 +224,22 @@ void PointRedefineMode::stopMove()
assert( dynamic_cast<ObjectTypeCalcer*>( mp->calcer() ) );
ObjectTypeCalcer* mpcalc = static_cast<ObjectTypeCalcer*>( mp->calcer() );
- std::vector<ObjectCalcer*> newparents = mpcalc->parents();
- std::vector<ObjectCalcer::shared_ptr> newparentsref(
- newparents.begin(), newparents.end() );
+ std::vector<ObjectCalcer*> newtqparents = mpcalc->tqparents();
+ std::vector<ObjectCalcer::shared_ptr> newtqparentsref(
+ newtqparents.begin(), newtqparents.end() );
const ObjectType* newtype = mpcalc->type();
- std::vector<ObjectCalcer*> oldparents;
- for( std::vector<ObjectCalcer::shared_ptr>::iterator i = moldparents.begin();
- i != moldparents.end(); ++i )
- oldparents.push_back( i->get() );
+ std::vector<ObjectCalcer*> oldtqparents;
+ for( std::vector<ObjectCalcer::shared_ptr>::iterator i = moldtqparents.begin();
+ i != moldtqparents.end(); ++i )
+ oldtqparents.push_back( i->get() );
mpcalc->setType( moldtype );
- mpcalc->setParents( oldparents );
+ mpcalc->setParents( oldtqparents );
mp->calc( mdoc.document() );
KigCommand* command = new KigCommand( mdoc, i18n( "Redefine Point" ) );
command->addTask(
- new ChangeParentsAndTypeTask( mpcalc, newparents, newtype ) );
+ new ChangeParentsAndTypeTask( mpcalc, newtqparents, newtype ) );
mmon->finish( command );
mdoc.history()->addCommand( command );
}
diff --git a/kig/modes/moving.h b/kig/modes/moving.h
index 7c27aa4e..8a75e62a 100644
--- a/kig/modes/moving.h
+++ b/kig/modes/moving.h
@@ -88,7 +88,7 @@ class PointRedefineMode
: public MovingModeBase
{
ObjectHolder* mp;
- std::vector<ObjectCalcer::shared_ptr> moldparents;
+ std::vector<ObjectCalcer::shared_ptr> moldtqparents;
const ObjectType* moldtype;
MonitorDataObjects* mmon;
void stopMove();
diff --git a/kig/modes/normal.cc b/kig/modes/normal.cc
index 1fa45d00..c4dd7f4f 100644
--- a/kig/modes/normal.cc
+++ b/kig/modes/normal.cc
@@ -133,7 +133,7 @@ void NormalMode::dragRect( const TQPoint& p, KigWidget& w )
DragRectMode d( p, mdoc, w );
mdoc.runMode( &d );
- KigPainter pter( w.screenInfo(), &w.stillPix, mdoc.document() );
+ KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
if ( ! d.cancelled() )
{
@@ -174,7 +174,7 @@ void NormalMode::dragObject( const std::vector<ObjectHolder*>& oco, const TQPoin
void NormalMode::leftClickedObject( ObjectHolder* o, const TQPoint&,
KigWidget& w, bool ctrlOrShiftDown )
{
- KigPainter pter( w.screenInfo(), &w.stillPix, mdoc.document() );
+ KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
if ( ! o )
{
@@ -269,7 +269,7 @@ void NormalMode::mouseMoved( const std::vector<ObjectHolder*>& os,
// statusbar text
mdoc.emitStatusBarText( stat );
- KigPainter p( w.screenInfo(), &w.curPix, mdoc.document() );
+ KigPainter p( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
// set the text next to the arrow cursor
TQPoint point = plc;
diff --git a/kig/modes/popup.cc b/kig/modes/popup.cc
index 489b4985..8a3d05e1 100644
--- a/kig/modes/popup.cc
+++ b/kig/modes/popup.cc
@@ -198,12 +198,12 @@ NormalModePopupObjects::NormalModePopupObjects( KigPart& part,
else if ( single )
{
if ( !objs[0]->name().isNull() )
- title = TQString::fromLatin1( "%1 %2" ).arg( objs[0]->imp()->type()->translatedName() ).arg( objs[0]->name() );
+ title = TQString::tqfromLatin1( "%1 %2" ).tqarg( objs[0]->imp()->type()->translatedName() ).tqarg( objs[0]->name() );
else
title = objs[0]->imp()->type()->translatedName();
}
else
- title = i18n( "%1 Objects" ).arg( objs.size() );
+ title = i18n( "%1 Objects" ).tqarg( objs.size() );
insertTitle( title, 1 );
if ( !empty )
@@ -281,22 +281,22 @@ NormalModePopupObjects::NormalModePopupObjects( KigPart& part,
i18n( "Set Co&lor" ),
i18n( "Set &Pen Width" ),
i18n( "Set St&yle" ),
- TQString::null,
+ TQString(),
i18n( "Set Coordinate S&ystem" )
};
static const TQString menuicons[NumberOfMenus] =
{
"centralsymmetry",
"test",
- TQString::null,
+ TQString(),
"launch",
"kig_text",
"color_fill",
// "colorize",
"sizer",
"paintbrush",
- TQString::null,
- TQString::null
+ TQString(),
+ TQString()
};
int index = 1;
for ( int i = 0; i < NumberOfMenus; ++i )
@@ -360,14 +360,14 @@ NormalModePopupObjects::~NormalModePopupObjects()
static const TQColor* colors[] =
{
- &Qt::blue,
- &Qt::black,
- &Qt::gray,
- &Qt::red,
- &Qt::green,
- &Qt::cyan,
- &Qt::yellow,
- &Qt::darkRed
+ &TQt::blue,
+ &TQt::black,
+ &TQt::gray,
+ &TQt::red,
+ &TQt::green,
+ &TQt::cyan,
+ &TQt::yellow,
+ &TQt::darkRed
};
static const int numberofcolors = sizeof( colors ) / sizeof( TQColor* );
@@ -424,14 +424,14 @@ void BuiltinObjectActionsProvider::fillUpMenu( NormalModePopupObjects& popup, in
point = false;
if ( (*i)->drawer()->color() != color ) samecolor = false;
};
- if ( ! samecolor ) color = Qt::blue;
+ if ( ! samecolor ) color = TQt::blue;
TQPixmap p( point ? 20 : 50, 20 );
for ( int i = 1; i < 8; ++i )
{
p.fill( popup.eraseColor() );
TQPainter ptr( &p );
ptr.setPen( TQPen( color, 1 ) );
- ptr.setBrush( TQBrush( color, Qt::SolidPattern ) );
+ ptr.setBrush( TQBrush( color, TQt::SolidPattern ) );
if ( point )
{
int size = 2*i;
@@ -463,14 +463,14 @@ void BuiltinObjectActionsProvider::fillUpMenu( NormalModePopupObjects& popup, in
if ( (*i)->drawer()->color() != color ) samecolor = false;
};
bool point = ( npoints > nothers );
- if ( ! samecolor ) color = Qt::blue;
+ if ( ! samecolor ) color = TQt::blue;
if ( point )
for ( int i = 0; i < 5; ++i )
{
TQPixmap p( 20, 20 );
p.fill( popup.eraseColor() );
ScreenInfo si( Rect( -1, -1, 2, 2 ), p.rect() );
- KigPainter ptr( si, &p, popup.part().document(), false );
+ KigPainter ptr( si, TQT_TQPAINTDEVICE(&p), popup.part().document(), false );
PointImp pt( Coordinate( 0, 0 ) );
ObjectDrawer d( color, -1, true, Qt::SolidLine, i );
d.draw( pt, ptr, false );
@@ -484,7 +484,7 @@ void BuiltinObjectActionsProvider::fillUpMenu( NormalModePopupObjects& popup, in
TQPixmap p( 50, 20 );
p.fill( popup.eraseColor() );
ScreenInfo si( Rect( -2.5, -1, 5, 2 ), p.rect() );
- KigPainter ptr( si, &p, popup.part().document(), false );
+ KigPainter ptr( si, TQT_TQPAINTDEVICE(&p), popup.part().document(), false );
LineImp line( Coordinate( -1, 0 ), Coordinate( 1, 0 ) );
Qt::PenStyle ps = penstyles[i];
ObjectDrawer d( color, -1, true, ps, 1 );
@@ -518,7 +518,7 @@ static void addNameLabel( ObjectCalcer* object, ObjectCalcer* namecalcer, const
object->imp()->inherits( CurveImp::stype() ) )
attachto = object;
ObjectHolder* label = ObjectFactory::instance()->attachedLabel(
- TQString::fromLatin1( "%1" ), attachto, loc, namelabelneedsframe, args, doc.document() );
+ TQString::tqfromLatin1( "%1" ), attachto, loc, namelabelneedsframe, args, doc.document() );
doc.addObject( label );
}
@@ -871,7 +871,7 @@ void PropertiesActionsProvider::fillUpMenu( NormalModePopupObjects& popup,
add &= ! prop->inherits( BogusImp::stype() );
// we don't want to construct PointImp's coordinate property,
// since it would construct a point at the same place as its
- // parent..
+ // tqparent..
add &= ! ( o->imp()->inherits( PointImp::stype() ) &&
prop->inherits( PointImp::stype() ) );
}
@@ -909,11 +909,11 @@ bool PropertiesActionsProvider::executeAction(
}
int propid = mprops[menu-1][id];
assert( os.size() == 1 );
- ObjectHolder* parent = os[0];
+ ObjectHolder* tqparent = os[0];
if ( menu == NormalModePopupObjects::ShowMenu )
{
std::vector<ObjectCalcer*> args;
- args.push_back( new ObjectPropertyCalcer( parent->calcer(), propid ) );
+ args.push_back( new ObjectPropertyCalcer( tqparent->calcer(), propid ) );
args.back()->calc( doc.document() );
// TODO: recover the cursor position somehow... the following does not work
// in general...
@@ -924,14 +924,14 @@ bool PropertiesActionsProvider::executeAction(
// /////// Coordinate c = Coordinate::invalidCoord();
Coordinate c = w.fromScreen( popup.plc() );
ObjectHolder* label = ObjectFactory::instance()->attachedLabel(
- TQString::fromLatin1( "%1" ), parent->calcer(), c,
+ TQString::tqfromLatin1( "%1" ), tqparent->calcer(), c,
false, args, doc.document() );
doc.addObject( label );
}
else
{
ObjectHolder* h = new ObjectHolder(
- new ObjectPropertyCalcer( parent->calcer(), propid ) );
+ new ObjectPropertyCalcer( tqparent->calcer(), propid ) );
h->calc( doc.document() );
doc.addObject( h );
};
@@ -1182,7 +1182,7 @@ ObjectChooserPopup::ObjectChooserPopup( const TQPoint& p, KigWidget& view,
for ( uint i = 0; i < mobjs.size(); i++ )
{
insertItem( !mobjs[i]->name().isEmpty()
- ? TQString::fromLatin1( "%1 %2" ).arg( mobjs[i]->imp()->type()->translatedName() ).arg( mobjs[i]->name() )
+ ? TQString::tqfromLatin1( "%1 %2" ).tqarg( mobjs[i]->imp()->type()->translatedName() ).tqarg( mobjs[i]->name() )
: mobjs[i]->imp()->type()->translatedName(),
i );
}
diff --git a/kig/modes/popup.h b/kig/modes/popup.h
index 76574b74..4db6838f 100644
--- a/kig/modes/popup.h
+++ b/kig/modes/popup.h
@@ -47,6 +47,7 @@ class NormalModePopupObjects
: public KPopupMenu
{
Q_OBJECT
+ TQ_OBJECT
public:
NormalModePopupObjects( KigPart& part, KigWidget& view,
@@ -117,6 +118,7 @@ class ObjectChooserPopup
: public KPopupMenu
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
diff --git a/kig/modes/textlabelwizard.cc b/kig/modes/textlabelwizard.cc
index d562bbf3..70f484d8 100644
--- a/kig/modes/textlabelwizard.cc
+++ b/kig/modes/textlabelwizard.cc
@@ -26,8 +26,8 @@
#include <tqlayout.h>
-TextLabelWizard::TextLabelWizard( TQWidget* parent, TextLabelModeBase* mode )
- : TextLabelWizardBase( parent, "TextLabelWizard", false ), mmode( mode )
+TextLabelWizard::TextLabelWizard( TQWidget* tqparent, TextLabelModeBase* mode )
+ : TextLabelWizardBase( tqparent, "TextLabelWizard", false ), mmode( mode )
{
connect( labelTextInput, TQT_SIGNAL( textChanged() ),
TQT_SLOT( textChanged() ) );
@@ -81,15 +81,15 @@ void TextLabelWizard::linkClicked( int which )
mmode->linkClicked( which );
}
-void TextLabelWizard::relayoutArgsPage()
+void TextLabelWizard::retqlayoutArgsPage()
{
select_arguments_pageLayout->activate();
- repaint();
+ tqrepaint();
}
void TextLabelWizard::slotHelpClicked()
{
- kapp->invokeHelp( TQString::fromLatin1( "text-labels" ),
- TQString::fromLatin1( "kig" ) );
+ kapp->invokeHelp( TQString::tqfromLatin1( "text-labels" ),
+ TQString::tqfromLatin1( "kig" ) );
}
diff --git a/kig/modes/textlabelwizard.h b/kig/modes/textlabelwizard.h
index bd51c1e0..2d192e7c 100644
--- a/kig/modes/textlabelwizard.h
+++ b/kig/modes/textlabelwizard.h
@@ -25,8 +25,9 @@ class TextLabelModeBase;
class TextLabelWizard : public TextLabelWizardBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- TextLabelWizard( TQWidget* parent, TextLabelModeBase* mode );
+ TextLabelWizard( TQWidget* tqparent, TextLabelModeBase* mode );
~TextLabelWizard();
void back();
@@ -34,7 +35,7 @@ public:
void reject();
void accept();
- void relayoutArgsPage();
+ void retqlayoutArgsPage();
private slots:
void textChanged();
void linkClicked( int which );
diff --git a/kig/modes/textlabelwizardbase.ui b/kig/modes/textlabelwizardbase.ui
index 4e195b0d..5cbace2c 100644
--- a/kig/modes/textlabelwizardbase.ui
+++ b/kig/modes/textlabelwizardbase.ui
@@ -1,10 +1,10 @@
<!DOCTYPE UI><UI version="3.1.2" stdsetdef="1">
<class>TextLabelWizardBase</class>
-<widget class="QWizard">
+<widget class="TQWizard">
<property name="name">
<cstring>TextLabelWizardBase</cstring>
</property>
- <property name="geometry">
+ <property name="tqgeometry">
<rect>
<x>0</x>
<y>0</y>
@@ -15,7 +15,7 @@
<property name="caption">
<string>Construct Label</string>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>enter_text_page</cstring>
</property>
@@ -26,7 +26,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>enterTextLabel</cstring>
</property>
@@ -34,16 +34,16 @@
<string>Enter the text for your label here and press "Next".
If you want to show variable parts, then put %1, %2, ... at the appropriate places (e.g. "This segment is %1 units long.").</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>WordBreak|AlignVCenter</set>
</property>
</widget>
- <widget class="QTextEdit">
+ <widget class="TQTextEdit">
<property name="name">
<cstring>labelTextInput</cstring>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>needFrameCheckBox</cstring>
</property>
@@ -53,7 +53,7 @@ If you want to show variable parts, then put %1, %2, ... at the appropriate plac
</widget>
</vbox>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>select_arguments_page</cstring>
</property>
@@ -64,14 +64,14 @@ If you want to show variable parts, then put %1, %2, ... at the appropriate plac
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>selectArgsLabel</cstring>
</property>
<property name="text">
<string>Now select the argument(s) you need. For every argument, click on it, select an object and a property in the Kig window, and click finish when you are done...</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>WordBreak|AlignVCenter</set>
</property>
</widget>
@@ -106,7 +106,7 @@ If you want to show variable parts, then put %1, %2, ... at the appropriate plac
<data format="XPM.GZ" length="4462">789c9d97c76e24490e86effd1442f3d65870d2451a0ce6206f5adeb4cc620f8c34f2553225b5a4c1befb46927fe6a1d4c0ccac4287fa8a0c26834193f5dbb785b3fd9d856fbf7d799ec9ecba5ea8afe469e15bf3727ffffeeffffcf1e797af49b2d0ffc7d142f2f55f5fbe1ecc16ea85dde9a4ed81290045faa77ca49cf4ab67ba1e3953969173651ab9d4fdf1c8a27c3872ad7c3c72d3b32c2a67c3f3444636fbef23eb7e590267e68fcc4656395d8dacf6d938ef97eaef289781cddebdb2846fccff44b989ba58e3411f3dc75158e6df1d3889539517ca49bf54fe43398d1dec4f46567f685fd9c539f43fc025f80c1c3ce8d93f28e77185f8bf0c6cfae4c0b5f9c3c6e5c0542a4b5876fe13708df39d2bd7716372aa8c93c4e4723bb2f977aadc26ceec4bdb7310e6b0bfab9c2445ecd49f1370694cebca65d260ffa6711a41aef14d24e94cee6be3348e0ae5e9c8765f07ca3e8db17f0f9c825794eb3489351fe9bb7217e4969f29388bd51ee9fda5715a19730696b852fea95c6471647ca95cf64bcf43e0cef4657b647bfe6acf213d6bb32f9a9f5992b5a64f9a8f990b6cf9ecc15d6cf9acf6b2da55a8a75cb973dee4b2d1b38b5c05de02434e87e01aacfb351df5bebddea74b5c67f9c795711ea15e357e2ecde358fb87efc0a867df8cac728a074e62e527706afb59f3cf6583be5c28bb3c35f693812d1fbdc6dbe57966fec932d899ffa4f7e38adca17e34beaeca4b9c271a18f1d5fc739257b0d70d9c68be7bed7fcee7827ab91cd8e4740cf6b19d4ffb87ab07b9bf516e72d4a3ac821b9cef6e60d84f47367ded2fae1d9f7704f6163f79000ffde27660f387ed3c5dbf54dfeebb0bf6acbe6b706bfa5ef32f8f8b18f5bf0f463f20edb77956a4e68fbc80b3c4facd163847be6bfde72ec86dbeac82715fbc0286be683cf3bc081d44f7df80d344fb0b6b7de64581fb916765297263d6fccd9b7ee97e566e8b06cfdb1f59cf2bda2f8bbc2c11df0c5c41aefdb328ca22b1feb0012eedbce24736f91b18fb796d64eb87cb60817dcdafb07d906bfd14d22f659d8785ef97b2f6d7b2df6ef1d6fb2babaac6f92e8c25b27ecc1f239b7f3a5fca5a8678ea7c2d9bc0e6ef1238b3fca2c7814d5f4cbf9334b5f833384bed3c7a5f5514f4adbe2ec07962e7590457f06f6f649b977afe2a16f42f5e070bfc591e18f7a5f1a812a9e0df39d827da4fbd8c6ccfd7785569bf945f953371a9d5a3de67950bfa2d75c63eb2fb15bdcfaaf011e6c7263846bf8f4636f91618f3c7d3c0f047fb69550efab2074e12bd6fd27957553ec33c5b043bcc7f9d0795f818fdb501a3df8ae673e507ff69021eea37063bc45ffb73550736ff36c0a84f3e0317a86f8b5f139e6ffe1f821de6d9127898ff3be00a7c3ab2cd03e3d697560ff40016e47b3bb2e96bbd559d8f32bbff4b7065f193042c98873acf240af6adbf3c83c5f2954bb0c7bcd77c107d81d2fdebc63e33ff640aaecc9e1c8151df5c803dfaadc64b52dfa03ed64636ffb4ff4b2867f453ede7227586fcd3f9264ded91fffafe236d5da37fe83c91ceb7b9e5b7f6731ff92ed7f747d6fbf7e185cf58347e3e6932e47b3430fa893edf87d795c2fc3f003b67f5f902cec17abfde0dfa3c053b3c5ffb832fc2eb8fddcf233887fc195c801f46b6f3cdc02558fba72f7d2d1a7f7e321ee58fe0cad86bbff24dd3e2fe74fef836b0c6eb60d62fa6bf5e07b3419f853dd7dc70fb8bd5f1255fd90ed30f9f3c5ff30ddff21ddff384a7fcc08ffcc4cf61cdf8855ff9e79c7e1db4dff89d3f7891977899577895d7789d377893b7f83b6fcfe937bc13b477798ff7f9800ff928ac633ee11f7cca6761d7f99c7e1b3cb908da11c7413be1943376e153cc39175c72f549ff9e17c31744429e6a6aa8a58e2ee98aaee9866e7f617fc24b7417a4f734a1293dd0233dd133cd8285177aa5f9f3b63ca5377aa78f607b919668995682e62aadd17ab0b1419b9ff41f682b48bed336edd02eed05ed7d5ea3033a0cdf1ed1f127fd273ae123fa41a774a6b685cee982228a837e42e927fd47caf8985c38651eb40b2ac38e4a5842658a97fab33fd248cb87d2c9a55cc9b5dcc82d1fc99ddccb44a6f230af2f8ff224cf417f262ff22a3fe54ddee543166549966545567f617f4dd66523dc6b2c9bb225df655b7682f692ecca9eeccfe97772c09b722847722c27c1f3eb70f66bf9116c9fca999ccbc59cfe25bf4a143a5ef8992561324a78bd92522acf9ebc78efe7cf7b153276db37bef59dbff457fedadff85b7f27abfede4ffcd4cf9ff76faeff4fffefeff8c7f5fedfdfbffc0fa355c495</data>
</image>
</images>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>linkslabel.h</includehint>
</includehints>
diff --git a/kig/modes/typesdialog.cpp b/kig/modes/typesdialog.cpp
index e14ceee8..0371ca7f 100644
--- a/kig/modes/typesdialog.cpp
+++ b/kig/modes/typesdialog.cpp
@@ -44,7 +44,7 @@
#include <vector>
class MacroListElement
- : public QListViewItem
+ : public TQListViewItem
{
Macro* macro;
public:
@@ -53,13 +53,13 @@ public:
};
MacroListElement::MacroListElement( KListView* lv, Macro* m )
- : TQListViewItem( lv, TQString::null, m->action->descriptiveName(), m->action->description() ),
+ : TQListViewItem( lv, TQString(), m->action->descriptiveName(), m->action->description() ),
macro( m )
{
}
-TypesDialog::TypesDialog( TQWidget* parent, KigPart& part )
- : TypesDialogBase( parent, "types_dialog", true ), mpart( part )
+TypesDialog::TypesDialog( TQWidget* tqparent, KigPart& part )
+ : TypesDialogBase( tqparent, "types_dialog", true ), mpart( part )
{
// improving GUI look'n'feel...
buttonHelp->setGuiItem( KStdGuiItem::help() );
@@ -106,8 +106,8 @@ TypesDialog::~TypesDialog()
void TypesDialog::helpSlot()
{
- kapp->invokeHelp( TQString::fromLatin1( "working-with-types" ),
- TQString::fromLatin1( "kig" ) );
+ kapp->invokeHelp( TQString::tqfromLatin1( "working-with-types" ),
+ TQString::tqfromLatin1( "kig" ) );
}
void TypesDialog::okSlot()
@@ -171,7 +171,7 @@ void TypesDialog::exportType()
TQFile fi( file_name );
if ( fi.exists() )
if ( KMessageBox::warningContinueCancel( this, i18n( "The file \"%1\" already exists. "
- "Do you wish to overwrite it?" ).arg( fi.name() ),
+ "Do you wish to overwrite it?" ).tqarg( fi.name() ),
i18n( "Overwrite File?" ), i18n("Overwrite") ) == KMessageBox::Cancel )
return;
MacroList::instance()->save( types, file_name );
diff --git a/kig/modes/typesdialog.h b/kig/modes/typesdialog.h
index 2e914bcd..8275b653 100644
--- a/kig/modes/typesdialog.h
+++ b/kig/modes/typesdialog.h
@@ -39,13 +39,14 @@ class KigDocument;
class TypesDialog : public TypesDialogBase
{
Q_OBJECT
+ TQ_OBJECT
// necessary because some MacroList functions need it..
KigPart& mpart;
const KIconLoader* il;
TQPopupMenu* popup;
public:
- TypesDialog( TQWidget* parent, KigPart& );
+ TypesDialog( TQWidget* tqparent, KigPart& );
~TypesDialog();
public slots:
diff --git a/kig/modes/typesdialogbase.ui b/kig/modes/typesdialogbase.ui
index 7cc7effb..7d3e012f 100644
--- a/kig/modes/typesdialogbase.ui
+++ b/kig/modes/typesdialogbase.ui
@@ -1,10 +1,10 @@
<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
<class>TypesDialogBase</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>TypesDialogBase</cstring>
</property>
- <property name="geometry">
+ <property name="tqgeometry">
<rect>
<x>0</x>
<y>0</y>
@@ -28,9 +28,9 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout1</cstring>
+ <cstring>tqlayout1</cstring>
</property>
<hbox>
<property name="name">
@@ -88,17 +88,17 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout4</cstring>
+ <cstring>tqlayout4</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout3</cstring>
+ <cstring>tqlayout3</cstring>
</property>
<vbox>
<property name="name">
@@ -138,16 +138,16 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout4</cstring>
+ <cstring>tqlayout4</cstring>
</property>
<vbox>
<property name="name">
@@ -193,7 +193,7 @@
<enum>Horizontal</enum>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -228,7 +228,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -302,9 +302,9 @@
</connection>
<connection>
<sender>typeList</sender>
- <signal>contextMenuRequested(QListViewItem*,const QPoint&amp;,int)</signal>
+ <signal>contextMenuRequested(TQListViewItem*,const QPoint&amp;,int)</signal>
<receiver>TypesDialogBase</receiver>
- <slot>contextMenuRequested(QListViewItem*,const QPoint&amp;,int)</slot>
+ <slot>contextMenuRequested(TQListViewItem*,const QPoint&amp;,int)</slot>
</connection>
<connection>
<sender>buttonCancel</sender>
@@ -313,17 +313,17 @@
<slot>cancelSlot()</slot>
</connection>
</connections>
-<slots>
+<Q_SLOTS>
<slot access="protected">deleteType()</slot>
<slot access="protected">exportType()</slot>
<slot>helpSlot()</slot>
<slot access="protected">importTypes()</slot>
<slot>okSlot()</slot>
<slot access="protected">editType()</slot>
- <slot access="protected">contextMenuRequested( QListViewItem* i, const QPoint&amp; p, int c )</slot>
+ <slot access="protected">contextMenuRequested( TQListViewItem* i, const QPoint&amp; p, int c )</slot>
<slot>cancelSlot()</slot>
-</slots>
-<layoutdefaults spacing="6" margin="11"/>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>klistview.h</includehint>
<includehint>kpushbutton.h</includehint>
diff --git a/kig/objects/angle_type.cc b/kig/objects/angle_type.cc
index 7b86411b..b0dc09c1 100644
--- a/kig/objects/angle_type.cc
+++ b/kig/objects/angle_type.cc
@@ -65,14 +65,14 @@ const AngleType* AngleType::instance()
return &t;
}
-ObjectImp* AngleType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* AngleType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents, 2 ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents, 2 ) ) return new InvalidImp;
std::vector<Coordinate> points;
- for ( uint i = 0; i < parents.size(); ++i )
+ for ( uint i = 0; i < tqparents.size(); ++i )
points.push_back(
- static_cast<const PointImp*>( parents[i] )->coordinate() );
+ static_cast<const PointImp*>( tqparents[i] )->coordinate() );
Coordinate lvect = points[0] - points[1];
Coordinate rvect;
@@ -112,13 +112,13 @@ void AngleType::executeAction(
// pretend to use this var..
(void) i;
- std::vector<ObjectCalcer*> parents = t.parents();
+ std::vector<ObjectCalcer*> tqparents = t.tqparents();
- assert( margsparser.checkArgs( parents ) );
+ assert( margsparser.checkArgs( tqparents ) );
- Coordinate a = static_cast<const PointImp*>( parents[0]->imp() )->coordinate();
- Coordinate b = static_cast<const PointImp*>( parents[1]->imp() )->coordinate();
- Coordinate c = static_cast<const PointImp*>( parents[2]->imp() )->coordinate();
+ Coordinate a = static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate();
+ Coordinate b = static_cast<const PointImp*>( tqparents[1]->imp() )->coordinate();
+ Coordinate c = static_cast<const PointImp*>( tqparents[2]->imp() )->coordinate();
Coordinate lvect = a - b;
Coordinate rvect = c - b;
@@ -142,8 +142,8 @@ void AngleType::executeAction(
Coordinate cdir( cos( newcangle ), sin( newcangle ) );
Coordinate nc = b + cdir.normalize( rvect.length() );
- MonitorDataObjects mon( getAllParents( parents ) );
- parents[2]->move( nc, d.document() );
+ MonitorDataObjects mon( getAllParents( tqparents ) );
+ tqparents[2]->move( nc, d.document() );
KigCommand* kc = new KigCommand( d, i18n( "Resize Angle" ) );
mon.finish( kc );
d.history()->addCommand( kc );
@@ -166,14 +166,14 @@ const HalfAngleType* HalfAngleType::instance()
return &t;
}
-ObjectImp* HalfAngleType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* HalfAngleType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents, 2 ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents, 2 ) ) return new InvalidImp;
std::vector<Coordinate> points;
- for ( uint i = 0; i < parents.size(); ++i )
+ for ( uint i = 0; i < tqparents.size(); ++i )
points.push_back(
- static_cast<const PointImp*>( parents[i] )->coordinate() );
+ static_cast<const PointImp*>( tqparents[i] )->coordinate() );
Coordinate lvect = points[0] - points[1];
Coordinate rvect;
diff --git a/kig/objects/arc_type.h b/kig/objects/arc_type.h
index cdfe0294..cb0a4c5f 100644
--- a/kig/objects/arc_type.h
+++ b/kig/objects/arc_type.h
@@ -35,7 +35,7 @@ public:
ObjectImp* calc( const Args& args, const KigDocument& ) const;
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
bool inherits( int type ) const;
const ObjectImpType* resultId() const;
@@ -55,7 +55,7 @@ public:
ObjectImp* calc( const Args& args, const KigDocument& ) const;
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
bool inherits( int type ) const;
const ObjectImpType* resultId() const;
diff --git a/kig/objects/base_type.cc b/kig/objects/base_type.cc
index 0f8eecec..77b9dc6a 100644
--- a/kig/objects/base_type.cc
+++ b/kig/objects/base_type.cc
@@ -33,13 +33,13 @@ ObjectABType::~ObjectABType()
{
}
-ObjectImp* ObjectABType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ObjectABType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) )
+ if ( ! margsparser.checkArgs( tqparents ) )
return new InvalidImp;
- Coordinate a = static_cast<const PointImp*>( parents[0] )->coordinate();
- Coordinate b = static_cast<const PointImp*>( parents[1] )->coordinate();
+ Coordinate a = static_cast<const PointImp*>( tqparents[0] )->coordinate();
+ Coordinate b = static_cast<const PointImp*>( tqparents[1] )->coordinate();
return calc( a, b );
}
@@ -57,22 +57,22 @@ bool ObjectABType::canMove( const ObjectTypeCalcer& o ) const
bool ObjectABType::isFreelyTranslatable( const ObjectTypeCalcer& o ) const
{
- std::vector<ObjectCalcer*> parents = o.parents();
- return parents[0]->isFreelyTranslatable() && parents[1]->isFreelyTranslatable();
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ return tqparents[0]->isFreelyTranslatable() && tqparents[1]->isFreelyTranslatable();
}
void ObjectABType::move( ObjectTypeCalcer& o, const Coordinate& to,
const KigDocument& d ) const
{
- std::vector<ObjectCalcer*> parents = o.parents();
- assert( margsparser.checkArgs( parents ) );
- const Coordinate a = static_cast<const PointImp*>( parents[0]->imp() )->coordinate();
- const Coordinate b = static_cast<const PointImp*>( parents[1]->imp() )->coordinate();
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ assert( margsparser.checkArgs( tqparents ) );
+ const Coordinate a = static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate();
+ const Coordinate b = static_cast<const PointImp*>( tqparents[1]->imp() )->coordinate();
const Coordinate dist = b - a;
- if ( parents[0]->canMove() )
- parents[0]->move( to, d );
- if ( parents[1]->canMove() )
- parents[1]->move( to + dist, d );
+ if ( tqparents[0]->canMove() )
+ tqparents[0]->move( to, d );
+ if ( tqparents[1]->canMove() )
+ tqparents[1]->move( to + dist, d );
}
ObjectLPType::ObjectLPType( const char* fullname, const ArgsParser::spec* spec, int n )
@@ -94,19 +94,19 @@ ObjectImp* ObjectLPType::calc( const Args& args, const KigDocument& ) const
const Coordinate ObjectABType::moveReferencePoint( const ObjectTypeCalcer& o ) const
{
- std::vector<ObjectCalcer*> parents = o.parents();
- assert( margsparser.checkArgs( parents ) );
- return static_cast<const PointImp*>( parents[0]->imp() )->coordinate();
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ assert( margsparser.checkArgs( tqparents ) );
+ return static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate();
}
std::vector<ObjectCalcer*> ObjectABType::movableParents( const ObjectTypeCalcer& ourobj ) const
{
- std::vector<ObjectCalcer*> parents = ourobj.parents();
+ std::vector<ObjectCalcer*> tqparents = ourobj.tqparents();
std::set<ObjectCalcer*> ret;
- std::vector<ObjectCalcer*> tmp = parents[0]->movableParents();
+ std::vector<ObjectCalcer*> tmp = tqparents[0]->movableParents();
ret.insert( tmp.begin(), tmp.end() );
- tmp = parents[1]->movableParents();
+ tmp = tqparents[1]->movableParents();
ret.insert( tmp.begin(), tmp.end() );
- ret.insert( parents.begin(), parents.end() );
+ ret.insert( tqparents.begin(), tqparents.end() );
return std::vector<ObjectCalcer*>( ret.begin(), ret.end() );
}
diff --git a/kig/objects/bogus_imp.cc b/kig/objects/bogus_imp.cc
index b7b8f41e..6e688b1b 100644
--- a/kig/objects/bogus_imp.cc
+++ b/kig/objects/bogus_imp.cc
@@ -32,7 +32,7 @@ void BogusImp::draw( KigPainter& ) const
{
}
-bool BogusImp::contains( const Coordinate&, int, const KigWidget& ) const
+bool BogusImp::tqcontains( const Coordinate&, int, const KigWidget& ) const
{
return false;
}
@@ -88,22 +88,22 @@ InvalidImp::InvalidImp()
void InvalidImp::fillInNextEscape( TQString& s, const KigDocument& ) const
{
- s = s.arg( "[invalid]" );
+ s = s.tqarg( "[invalid]" );
}
void DoubleImp::fillInNextEscape( TQString& s, const KigDocument& ) const
{
- s = s.arg( mdata );
+ s = s.tqarg( mdata );
}
void IntImp::fillInNextEscape( TQString& s, const KigDocument& ) const
{
- s = s.arg( mdata );
+ s = s.tqarg( mdata );
}
void StringImp::fillInNextEscape( TQString& s, const KigDocument& ) const
{
- s = s.arg( mdata );
+ s = s.tqarg( mdata );
}
HierarchyImp::HierarchyImp( const ObjectHierarchy& h )
diff --git a/kig/objects/bogus_imp.h b/kig/objects/bogus_imp.h
index c8f3ee2b..3ab32809 100644
--- a/kig/objects/bogus_imp.h
+++ b/kig/objects/bogus_imp.h
@@ -46,7 +46,7 @@ public:
Coordinate attachPoint( ) const;
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& w ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& w ) const;
bool inRect( const Rect& r, int width, const KigWidget& w ) const;
Rect surroundingRect() const;
diff --git a/kig/objects/circle_imp.cc b/kig/objects/circle_imp.cc
index 38522c22..059ff592 100644
--- a/kig/objects/circle_imp.cc
+++ b/kig/objects/circle_imp.cc
@@ -63,7 +63,7 @@ void CircleImp::draw( KigPainter& p ) const
p.drawCircle( mcenter, mradius );
}
-bool CircleImp::contains( const Coordinate& p, int width, const KigWidget& w ) const
+bool CircleImp::tqcontains( const Coordinate& p, int width, const KigWidget& w ) const
{
return fabs((mcenter - p).length() - mradius) <= w.screenInfo().normalMiss( width );
}
@@ -72,10 +72,10 @@ bool CircleImp::inRect( const Rect& r, int width, const KigWidget& w ) const
{
// first we check if the rect contains at least one of the
// north/south/east/west points of the circle
- if ( r.contains( mcenter + Coordinate( 0, -mradius ) ) ) return true;
- if ( r.contains( mcenter + Coordinate( mradius, 0 ) ) ) return true;
- if ( r.contains( mcenter + Coordinate( 0, mradius ) ) ) return true;
- if ( r.contains( mcenter + Coordinate( -mradius, 0 ) ) ) return true;
+ if ( r.tqcontains( mcenter + Coordinate( 0, -mradius ) ) ) return true;
+ if ( r.tqcontains( mcenter + Coordinate( mradius, 0 ) ) ) return true;
+ if ( r.tqcontains( mcenter + Coordinate( 0, mradius ) ) ) return true;
+ if ( r.tqcontains( mcenter + Coordinate( -mradius, 0 ) ) ) return true;
// we allow a miss of some pixels ..
double miss = w.screenInfo().normalMiss( width );
@@ -235,8 +235,8 @@ TQString CircleImp::polarEquationString( const KigDocument& w ) const
{
TQString ret = i18n( "rho = %1 [centered at %2]" );
ConicPolarData data = polarData();
- ret = ret.arg( data.pdimen, 0, 'g', 3 );
- ret = ret.arg( w.coordinateSystem().fromScreen( data.focus1, w ) );
+ ret = ret.tqarg( data.pdimen, 0, 'g', 3 );
+ ret = ret.tqarg( w.coordinateSystem().fromScreen( data.focus1, w ) );
return ret;
}
@@ -244,18 +244,18 @@ TQString CircleImp::cartesianEquationString( const KigDocument& ) const
{
TQString ret = i18n( "x² + y² + %1 x + %2 y + %3 = 0" );
ConicCartesianData data = cartesianData();
- ret = ret.arg( data.coeffs[3], 0, 'g', 3 );
- ret = ret.arg( data.coeffs[4], 0, 'g', 3 );
- ret = ret.arg( data.coeffs[5], 0, 'g', 3 );
+ ret = ret.tqarg( data.coeffs[3], 0, 'g', 3 );
+ ret = ret.tqarg( data.coeffs[4], 0, 'g', 3 );
+ ret = ret.tqarg( data.coeffs[5], 0, 'g', 3 );
return ret;
}
TQString CircleImp::simplyCartesianEquationString( const KigDocument& ) const
{
TQString ret = i18n( "( x - %1 )² + ( y - %2 )² = %3" );
- ret = ret.arg( mcenter.x, 0, 'g', 3 );
- ret = ret.arg( mcenter.y, 0, 'g', 3 );
- ret = ret.arg( mradius * mradius, 0, 'g', 3 );
+ ret = ret.tqarg( mcenter.x, 0, 'g', 3 );
+ ret = ret.tqarg( mcenter.y, 0, 'g', 3 );
+ ret = ret.tqarg( mradius * mradius, 0, 'g', 3 );
return ret;
}
diff --git a/kig/objects/circle_imp.h b/kig/objects/circle_imp.h
index 1ccede6a..98fa391d 100644
--- a/kig/objects/circle_imp.h
+++ b/kig/objects/circle_imp.h
@@ -46,7 +46,7 @@ public:
ObjectImp* transform( const Transformation& ) const;
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& ) const;
bool inRect( const Rect& r, int width, const KigWidget& ) const;
bool valid() const;
Rect surroundingRect() const;
diff --git a/kig/objects/conic_imp.cc b/kig/objects/conic_imp.cc
index 81331522..11e01c28 100644
--- a/kig/objects/conic_imp.cc
+++ b/kig/objects/conic_imp.cc
@@ -47,7 +47,7 @@ bool ConicImp::valid() const
return true;
}
-bool ConicImp::contains( const Coordinate& o, int width, const KigWidget& w ) const
+bool ConicImp::tqcontains( const Coordinate& o, int width, const KigWidget& w ) const
{
return internalContainsPoint( o, w.screenInfo().normalMiss( width ) );
}
@@ -204,12 +204,12 @@ TQString ConicImp::cartesianEquationString( const KigDocument& ) const
{
TQString ret = i18n( "%1 x² + %2 y² + %3 xy + %4 x + %5 y + %6 = 0" );
ConicCartesianData data = cartesianData();
- ret = ret.arg( data.coeffs[0], 0, 'g', 3 );
- ret = ret.arg( data.coeffs[1], 0, 'g', 3 );
- ret = ret.arg( data.coeffs[2], 0, 'g', 3 );
- ret = ret.arg( data.coeffs[3], 0, 'g', 3 );
- ret = ret.arg( data.coeffs[4], 0, 'g', 3 );
- ret = ret.arg( data.coeffs[5], 0, 'g', 3 );
+ ret = ret.tqarg( data.coeffs[0], 0, 'g', 3 );
+ ret = ret.tqarg( data.coeffs[1], 0, 'g', 3 );
+ ret = ret.tqarg( data.coeffs[2], 0, 'g', 3 );
+ ret = ret.tqarg( data.coeffs[3], 0, 'g', 3 );
+ ret = ret.tqarg( data.coeffs[4], 0, 'g', 3 );
+ ret = ret.tqarg( data.coeffs[5], 0, 'g', 3 );
return ret;
}
@@ -218,11 +218,11 @@ TQString ConicImp::polarEquationString( const KigDocument& w ) const
TQString ret = i18n( "rho = %1/(1 + %2 cos theta + %3 sin theta)\n [centered at %4]" );
const ConicPolarData data = polarData();
- ret = ret.arg( data.pdimen, 0, 'g', 3 );
- ret = ret.arg( -data.ecostheta0, 0, 'g', 3 );
- ret = ret.arg( -data.esintheta0, 0, 'g', 3 );
+ ret = ret.tqarg( data.pdimen, 0, 'g', 3 );
+ ret = ret.tqarg( -data.ecostheta0, 0, 'g', 3 );
+ ret = ret.tqarg( -data.esintheta0, 0, 'g', 3 );
- ret = ret.arg( w.coordinateSystem().fromScreen( data.focus1, w ) );
+ ret = ret.tqarg( w.coordinateSystem().fromScreen( data.focus1, w ) );
return ret;
}
diff --git a/kig/objects/conic_imp.h b/kig/objects/conic_imp.h
index 29068a7b..d1cfa3f9 100644
--- a/kig/objects/conic_imp.h
+++ b/kig/objects/conic_imp.h
@@ -51,7 +51,7 @@ public:
ObjectImp* transform( const Transformation& ) const;
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& ) const;
bool inRect( const Rect& r, int width, const KigWidget& ) const;
bool valid() const;
Rect surroundingRect() const;
diff --git a/kig/objects/conic_types.cc b/kig/objects/conic_types.cc
index 34396369..58209011 100644
--- a/kig/objects/conic_types.cc
+++ b/kig/objects/conic_types.cc
@@ -57,12 +57,12 @@ ConicB5PType::~ConicB5PType()
{
}
-ObjectImp* ConicB5PType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConicB5PType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents, 1 ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents, 1 ) ) return new InvalidImp;
std::vector<Coordinate> points;
- for ( Args::const_iterator i = parents.begin(); i != parents.end(); ++i )
+ for ( Args::const_iterator i = tqparents.begin(); i != tqparents.end(); ++i )
points.push_back( static_cast<const PointImp*>( *i )->coordinate() );
ConicCartesianData d =
@@ -105,23 +105,23 @@ const ConicBAAPType* ConicBAAPType::instance()
return &t;
}
-ObjectImp* ConicBAAPType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConicBAAPType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) )
+ if ( ! margsparser.checkArgs( tqparents ) )
return new InvalidImp;
- const LineData la = static_cast<const AbstractLineImp*>( parents[0] )->data();
- const LineData lb = static_cast<const AbstractLineImp*>( parents[1] )->data();
- const Coordinate c = static_cast<const PointImp*>( parents[2] )->coordinate();
+ const LineData la = static_cast<const AbstractLineImp*>( tqparents[0] )->data();
+ const LineData lb = static_cast<const AbstractLineImp*>( tqparents[1] )->data();
+ const Coordinate c = static_cast<const PointImp*>( tqparents[2] )->coordinate();
return new ConicImpCart( calcConicByAsymptotes( la, lb, c ) );
}
-ObjectImp* ConicBFFPType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConicBFFPType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents, 2 ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents, 2 ) ) return new InvalidImp;
std::vector<Coordinate> cs;
- for ( Args::const_iterator i = parents.begin(); i != parents.end(); ++i )
+ for ( Args::const_iterator i = tqparents.begin(); i != tqparents.end(); ++i )
cs.push_back( static_cast<const PointImp*>( *i )->coordinate() );
return new ConicImpPolar( calcConicBFFP( cs, type() ) );
@@ -233,17 +233,17 @@ ConicBDFPType::~ConicBDFPType()
{
}
-ObjectImp* ConicBDFPType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConicBDFPType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents, 2 ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents, 2 ) ) return new InvalidImp;
- const LineData line = static_cast<const AbstractLineImp*>( parents[0] )->data();
+ const LineData line = static_cast<const AbstractLineImp*>( tqparents[0] )->data();
const Coordinate focus =
- static_cast<const PointImp*>( parents[1] )->coordinate();
+ static_cast<const PointImp*>( tqparents[1] )->coordinate();
Coordinate point;
- if ( parents.size() == 3 )
- point = static_cast<const PointImp*>( parents[2] )->coordinate();
+ if ( tqparents.size() == 3 )
+ point = static_cast<const PointImp*>( tqparents[2] )->coordinate();
else
{
/* !!!! costruisci point come punto medio dell'altezza tra fuoco e d. */
@@ -286,12 +286,12 @@ const ParabolaBTPType* ParabolaBTPType::instance()
return &t;
}
-ObjectImp* ParabolaBTPType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ParabolaBTPType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents, 2 ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents, 2 ) ) return new InvalidImp;
std::vector<Coordinate> points;
- for ( Args::const_iterator i = parents.begin(); i != parents.end(); ++i )
+ for ( Args::const_iterator i = tqparents.begin(); i != tqparents.end(); ++i )
points.push_back( static_cast<const PointImp*>( *i )->coordinate() );
ConicCartesianData d =
@@ -327,12 +327,12 @@ const ConicPolarPointType* ConicPolarPointType::instance()
return &t;
}
-ObjectImp* ConicPolarPointType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConicPolarPointType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- const ConicCartesianData c = static_cast<const ConicImp*>( parents[0] )->cartesianData();
- const LineData l = static_cast<const AbstractLineImp*>( parents[1] )->data();
+ const ConicCartesianData c = static_cast<const ConicImp*>( tqparents[0] )->cartesianData();
+ const LineData l = static_cast<const AbstractLineImp*>( tqparents[1] )->data();
const Coordinate p = calcConicPolarPoint( c, l );
if ( p.valid() ) return new PointImp( p );
else return new InvalidImp;
@@ -363,12 +363,12 @@ const ConicPolarLineType* ConicPolarLineType::instance()
return &t;
}
-ObjectImp* ConicPolarLineType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConicPolarLineType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- const ConicCartesianData c = static_cast<const ConicImp*>( parents[0] )->cartesianData();
- const Coordinate p = static_cast<const PointImp*>( parents[1] )->coordinate();
+ const ConicCartesianData c = static_cast<const ConicImp*>( tqparents[0] )->cartesianData();
+ const Coordinate p = static_cast<const PointImp*>( tqparents[1] )->coordinate();
bool valid = true;
const LineData l = calcConicPolarLine( c, p, valid );
if ( valid ) return new LineImp( l );
@@ -398,12 +398,12 @@ const ConicDirectrixType* ConicDirectrixType::instance()
return &t;
}
-ObjectImp* ConicDirectrixType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConicDirectrixType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
const ConicPolarData data =
- static_cast<const ConicImp*>( parents[0] )->polarData();
+ static_cast<const ConicImp*>( tqparents[0] )->polarData();
double ec = data.ecostheta0;
double es = data.esintheta0;
@@ -445,12 +445,12 @@ const EquilateralHyperbolaB4PType* EquilateralHyperbolaB4PType::instance()
return &t;
}
-ObjectImp* EquilateralHyperbolaB4PType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* EquilateralHyperbolaB4PType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents, 1 ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents, 1 ) ) return new InvalidImp;
std::vector<Coordinate> pts;
- for ( Args::const_iterator i = parents.begin(); i != parents.end(); ++i )
+ for ( Args::const_iterator i = tqparents.begin(); i != tqparents.end(); ++i )
pts.push_back( static_cast<const PointImp*>( *i )->coordinate() );
ConicCartesianData d = calcConicThroughPoints( pts, equilateral );
@@ -524,14 +524,14 @@ const ConicAsymptoteType* ConicAsymptoteType::instance()
return &t;
}
-ObjectImp* ConicAsymptoteType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConicAsymptoteType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
bool valid = true;
const LineData ret = calcConicAsymptote(
- static_cast<const ConicImp*>( parents[0] )->cartesianData(),
- static_cast<const IntImp*>( parents[1] )->data(),
+ static_cast<const ConicImp*>( tqparents[0] )->cartesianData(),
+ static_cast<const IntImp*>( tqparents[1] )->data(),
valid );
if ( valid )
@@ -565,18 +565,18 @@ const ConicRadicalType* ConicRadicalType::instance()
return &t;
}
-ObjectImp* ConicRadicalType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConicRadicalType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
- if ( parents[0]->inherits( CircleImp::stype() ) &&
- parents[1]->inherits( CircleImp::stype() ) )
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
+ if ( tqparents[0]->inherits( CircleImp::stype() ) &&
+ tqparents[1]->inherits( CircleImp::stype() ) )
{
- if( static_cast<const IntImp*>( parents[2] )->data() != 1 )
+ if( static_cast<const IntImp*>( tqparents[2] )->data() != 1 )
return new InvalidImp;
else
{
- const CircleImp* c1 = static_cast<const CircleImp*>( parents[0] );
- const CircleImp* c2 = static_cast<const CircleImp*>( parents[1] );
+ const CircleImp* c1 = static_cast<const CircleImp*>( tqparents[0] );
+ const CircleImp* c2 = static_cast<const CircleImp*>( tqparents[1] );
const Coordinate a = calcCircleRadicalStartPoint(
c1->center(), c2->center(), c1->squareRadius(), c2->squareRadius()
);
@@ -588,10 +588,10 @@ ObjectImp* ConicRadicalType::calc( const Args& parents, const KigDocument& ) con
{
bool valid = true;
const LineData l = calcConicRadical(
- static_cast<const ConicImp*>( parents[0] )->cartesianData(),
- static_cast<const ConicImp*>( parents[1] )->cartesianData(),
- static_cast<const IntImp*>( parents[2] )->data(),
- static_cast<const IntImp*>( parents[3] )->data(), valid );
+ static_cast<const ConicImp*>( tqparents[0] )->cartesianData(),
+ static_cast<const ConicImp*>( tqparents[1] )->cartesianData(),
+ static_cast<const IntImp*>( tqparents[2] )->data(),
+ static_cast<const IntImp*>( tqparents[3] )->data(), valid );
if ( valid )
return new LineImp( l );
else
@@ -674,9 +674,9 @@ void ConicRadicalType::executeAction( int i, ObjectHolder&, ObjectTypeCalcer& t,
KigPart& d, KigWidget&, NormalMode& ) const
{
assert( i == 0 );
- std::vector<ObjectCalcer*> parents = t.parents();
- assert( dynamic_cast<ObjectConstCalcer*>( parents[3] ) );
- ObjectConstCalcer* zeroindexo = static_cast<ObjectConstCalcer*>( parents[3] );
+ std::vector<ObjectCalcer*> tqparents = t.tqparents();
+ assert( dynamic_cast<ObjectConstCalcer*>( tqparents[3] ) );
+ ObjectConstCalcer* zeroindexo = static_cast<ObjectConstCalcer*>( tqparents[3] );
MonitorDataObjects mon( zeroindexo );
assert( zeroindexo->imp()->inherits( IntImp::stype() ) );
int oldzeroindex = static_cast<const IntImp*>( zeroindexo->imp() )->data();
diff --git a/kig/objects/conic_types.h b/kig/objects/conic_types.h
index 858ca057..e3c44c01 100644
--- a/kig/objects/conic_types.h
+++ b/kig/objects/conic_types.h
@@ -27,7 +27,7 @@ class ConicB5PType
~ConicB5PType();
public:
static const ConicB5PType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -38,7 +38,7 @@ class ConicBAAPType
~ConicBAAPType();
public:
static const ConicBAAPType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -49,7 +49,7 @@ protected:
ConicBFFPType( const char* fullname, const ArgsParser::spec*, int n );
~ConicBFFPType();
public:
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
/**
* -1 for hyperbola, 1 for ellipse..
@@ -85,7 +85,7 @@ class ConicBDFPType
~ConicBDFPType();
public:
static const ConicBDFPType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -96,7 +96,7 @@ class ParabolaBTPType
~ParabolaBTPType();
public:
static const ParabolaBTPType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -107,7 +107,7 @@ class EquilateralHyperbolaB4PType
~EquilateralHyperbolaB4PType();
public:
static const EquilateralHyperbolaB4PType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -118,7 +118,7 @@ class ConicPolarPointType
~ConicPolarPointType();
public:
static const ConicPolarPointType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -129,7 +129,7 @@ class ConicPolarLineType
~ConicPolarLineType();
public:
static const ConicPolarLineType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -140,7 +140,7 @@ class ConicDirectrixType
~ConicDirectrixType();
public:
static const ConicDirectrixType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -162,7 +162,7 @@ class ConicAsymptoteType
~ConicAsymptoteType();
public:
static const ConicAsymptoteType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -173,7 +173,7 @@ class ConicRadicalType
~ConicRadicalType();
public:
static const ConicRadicalType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
TQStringList specialActions() const;
void executeAction( int i, ObjectHolder& o, ObjectTypeCalcer& t,
diff --git a/kig/objects/cubic_imp.cc b/kig/objects/cubic_imp.cc
index 3879c5d9..f727f49a 100644
--- a/kig/objects/cubic_imp.cc
+++ b/kig/objects/cubic_imp.cc
@@ -50,7 +50,7 @@ void CubicImp::draw( KigPainter& p ) const
p.drawCurve( this );
}
-bool CubicImp::contains( const Coordinate& o, int width, const KigWidget& w ) const
+bool CubicImp::tqcontains( const Coordinate& o, int width, const KigWidget& w ) const
{
return internalContainsPoint( o, w.screenInfo().normalMiss( width ) );
}
@@ -409,7 +409,7 @@ Rect CubicImp::surroundingRect() const
TQString CubicImp::cartesianEquationString( const KigDocument& ) const
{
/*
- * unfortunately QStrings.arg method is limited to %1, %9, so we cannot
+ * unfortunately TQStrings.arg method is limited to %1, %9, so we cannot
* treat all 10 arguments! Let's split the equation in two parts...
* Now this ends up also in the translation machinery, is this really
* necessary? Otherwise we could do a little bit of tidy up on the
@@ -417,21 +417,21 @@ TQString CubicImp::cartesianEquationString( const KigDocument& ) const
*/
TQString ret = i18n( "%6 x³ + %9 y³ + %7 x²y + %8 xy² + %5 y² + %3 x² + %4 xy + %1 x + %2 y" );
- ret = ret.arg( mdata.coeffs[1], 0, 'g', 3 );
- ret = ret.arg( mdata.coeffs[2], 0, 'g', 3 );
- ret = ret.arg( mdata.coeffs[3], 0, 'g', 3 );
- ret = ret.arg( mdata.coeffs[4], 0, 'g', 3 );
- ret = ret.arg( mdata.coeffs[5], 0, 'g', 3 );
- ret = ret.arg( mdata.coeffs[6], 0, 'g', 3 );
- ret = ret.arg( mdata.coeffs[7], 0, 'g', 3 );
- ret = ret.arg( mdata.coeffs[8], 0, 'g', 3 );
- ret = ret.arg( mdata.coeffs[9], 0, 'g', 3 );
+ ret = ret.tqarg( mdata.coeffs[1], 0, 'g', 3 );
+ ret = ret.tqarg( mdata.coeffs[2], 0, 'g', 3 );
+ ret = ret.tqarg( mdata.coeffs[3], 0, 'g', 3 );
+ ret = ret.tqarg( mdata.coeffs[4], 0, 'g', 3 );
+ ret = ret.tqarg( mdata.coeffs[5], 0, 'g', 3 );
+ ret = ret.tqarg( mdata.coeffs[6], 0, 'g', 3 );
+ ret = ret.tqarg( mdata.coeffs[7], 0, 'g', 3 );
+ ret = ret.tqarg( mdata.coeffs[8], 0, 'g', 3 );
+ ret = ret.tqarg( mdata.coeffs[9], 0, 'g', 3 );
ret.append( i18n( " + %1 = 0" ) );
- ret = ret.arg( mdata.coeffs[0], 0, 'g', 3 );
+ ret = ret.tqarg( mdata.coeffs[0], 0, 'g', 3 );
// we should find a common place to do this...
- ret.replace( "+ -", "- " );
- ret.replace( "+-", "-" );
+ ret.tqreplace( "+ -", "- " );
+ ret.tqreplace( "+-", "-" );
return ret;
}
diff --git a/kig/objects/cubic_imp.h b/kig/objects/cubic_imp.h
index 5e9e6a2c..65dc25ad 100644
--- a/kig/objects/cubic_imp.h
+++ b/kig/objects/cubic_imp.h
@@ -40,7 +40,7 @@ public:
ObjectImp* transform( const Transformation& ) const;
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& ) const;
bool inRect( const Rect& r, int width, const KigWidget& ) const;
Rect surroundingRect() const;
TQString cartesianEquationString( const KigDocument& ) const;
diff --git a/kig/objects/cubic_type.cc b/kig/objects/cubic_type.cc
index c322b8c3..1878128a 100644
--- a/kig/objects/cubic_type.cc
+++ b/kig/objects/cubic_type.cc
@@ -112,12 +112,12 @@ const CubicNodeB6PType* CubicNodeB6PType::instance()
return &t;
}
-ObjectImp* CubicNodeB6PType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* CubicNodeB6PType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents, 2 ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents, 2 ) ) return new InvalidImp;
std::vector<Coordinate> points;
- for ( Args::const_iterator i = parents.begin(); i != parents.end(); ++i )
+ for ( Args::const_iterator i = tqparents.begin(); i != tqparents.end(); ++i )
points.push_back( static_cast<const PointImp*>( *i )->coordinate() );
CubicCartesianData d = calcCubicNodeThroughPoints( points );
@@ -156,12 +156,12 @@ const CubicCuspB4PType* CubicCuspB4PType::instance()
return &t;
}
-ObjectImp* CubicCuspB4PType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* CubicCuspB4PType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents, 2 ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents, 2 ) ) return new InvalidImp;
std::vector<Coordinate> points;
- for ( Args::const_iterator i = parents.begin(); i != parents.end(); ++i )
+ for ( Args::const_iterator i = tqparents.begin(); i != tqparents.end(); ++i )
points.push_back( static_cast<const PointImp*>( *i )->coordinate() );
CubicCartesianData d = calcCubicCuspThroughPoints( points );
diff --git a/kig/objects/cubic_type.h b/kig/objects/cubic_type.h
index 39be7387..439c7367 100644
--- a/kig/objects/cubic_type.h
+++ b/kig/objects/cubic_type.h
@@ -27,7 +27,7 @@ class CubicB9PType
~CubicB9PType();
public:
static const CubicB9PType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -38,7 +38,7 @@ class CubicNodeB6PType
~CubicNodeB6PType();
public:
static const CubicNodeB6PType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -49,7 +49,7 @@ class CubicCuspB4PType
~CubicCuspB4PType();
public:
static const CubicCuspB4PType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
diff --git a/kig/objects/intersection_types.cc b/kig/objects/intersection_types.cc
index 804d498d..92cbefff 100644
--- a/kig/objects/intersection_types.cc
+++ b/kig/objects/intersection_types.cc
@@ -55,19 +55,19 @@ const ConicLineIntersectionType* ConicLineIntersectionType::instance()
return &t;
}
-ObjectImp* ConicLineIntersectionType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConicLineIntersectionType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- int side = static_cast<const IntImp*>( parents[2] )->data();
+ int side = static_cast<const IntImp*>( tqparents[2] )->data();
assert( side == 1 || side == -1 );
- const LineData line = static_cast<const AbstractLineImp*>( parents[1] )->data();
+ const LineData line = static_cast<const AbstractLineImp*>( tqparents[1] )->data();
Coordinate ret;
- if ( parents[0]->inherits( CircleImp::stype() ) )
+ if ( tqparents[0]->inherits( CircleImp::stype() ) )
{
// easy case..
- const CircleImp* c = static_cast<const CircleImp*>( parents[0] );
+ const CircleImp* c = static_cast<const CircleImp*>( tqparents[0] );
ret = calcCircleLineIntersect(
c->center(), c->squareRadius(), line, side );
}
@@ -75,7 +75,7 @@ ObjectImp* ConicLineIntersectionType::calc( const Args& parents, const KigDocume
{
// harder case..
ret = calcConicLineIntersect(
- static_cast<const ConicImp*>( parents[0] )->cartesianData(),
+ static_cast<const ConicImp*>( tqparents[0] )->cartesianData(),
line, 0.0, side );
}
if ( ret.valid() ) return new PointImp( ret );
@@ -109,18 +109,18 @@ const ConicLineOtherIntersectionType* ConicLineOtherIntersectionType::instance()
return &t;
}
-ObjectImp* ConicLineOtherIntersectionType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConicLineOtherIntersectionType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- Coordinate p = static_cast<const PointImp*>( parents[2] )->coordinate();
- const LineData line = static_cast<const AbstractLineImp*>( parents[1] )->data();
+ Coordinate p = static_cast<const PointImp*>( tqparents[2] )->coordinate();
+ const LineData line = static_cast<const AbstractLineImp*>( tqparents[1] )->data();
Coordinate ret;
-// if ( parents[0]->inherits( CircleImp::stype() ) )
+// if ( tqparents[0]->inherits( CircleImp::stype() ) )
// {
// // easy case..
-// const CircleImp* c = static_cast<const CircleImp*>( parents[0] );
+// const CircleImp* c = static_cast<const CircleImp*>( tqparents[0] );
// ret = calcCircleLineIntersect(
// c->center(), c->squareRadius(), line, side, valid );
// }
@@ -133,7 +133,7 @@ ObjectImp* ConicLineOtherIntersectionType::calc( const Args& parents, const KigD
double bay = line.b.y - line.a.y;
double knownparam = (pax*bax + pay*bay)/(bax*bax + bay*bay);
ret = calcConicLineIntersect(
- static_cast<const ConicImp*>( parents[0] )->cartesianData(),
+ static_cast<const ConicImp*>( tqparents[0] )->cartesianData(),
line, knownparam, 0 );
// }
if ( ret.valid() ) return new PointImp( ret );
@@ -164,16 +164,16 @@ const LineLineIntersectionType* LineLineIntersectionType::instance()
return &t;
}
-ObjectImp* LineLineIntersectionType::calc( const Args& parents, const KigDocument& d ) const
+ObjectImp* LineLineIntersectionType::calc( const Args& tqparents, const KigDocument& d ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
Coordinate p =
calcIntersectionPoint(
- static_cast<const AbstractLineImp*>( parents[0] )->data(),
- static_cast<const AbstractLineImp*>( parents[1] )->data() );
- if ( static_cast<const AbstractLineImp*>( parents[0] )->containsPoint( p, d ) &&
- static_cast<const AbstractLineImp*>( parents[1] )->containsPoint( p, d ) )
+ static_cast<const AbstractLineImp*>( tqparents[0] )->data(),
+ static_cast<const AbstractLineImp*>( tqparents[1] )->data() );
+ if ( static_cast<const AbstractLineImp*>( tqparents[0] )->containsPoint( p, d ) &&
+ static_cast<const AbstractLineImp*>( tqparents[1] )->containsPoint( p, d ) )
return new PointImp( p );
else return new InvalidImp();
}
@@ -204,15 +204,15 @@ const LineCubicIntersectionType* LineCubicIntersectionType::instance()
return &t;
}
-ObjectImp* LineCubicIntersectionType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* LineCubicIntersectionType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- int which = static_cast<const IntImp*>( parents[2] )->data();
+ int which = static_cast<const IntImp*>( tqparents[2] )->data();
bool valid = true;
const Coordinate c = calcCubicLineIntersect(
- static_cast<const CubicImp*>( parents[0] )->data(),
- static_cast<const AbstractLineImp*>( parents[1] )->data(),
+ static_cast<const CubicImp*>( tqparents[0] )->data(),
+ static_cast<const AbstractLineImp*>( tqparents[1] )->data(),
which, valid );
if ( valid ) return new PointImp( c );
else return new InvalidImp;
@@ -265,14 +265,14 @@ const CircleCircleIntersectionType* CircleCircleIntersectionType::instance()
return &t;
}
-ObjectImp* CircleCircleIntersectionType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* CircleCircleIntersectionType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- int side = static_cast<const IntImp*>( parents[2] )->data();
+ int side = static_cast<const IntImp*>( tqparents[2] )->data();
assert( side == 1 || side == -1 );
- const CircleImp* c1 = static_cast<const CircleImp*>( parents[0] );
- const CircleImp* c2 = static_cast<const CircleImp*>( parents[1] );
+ const CircleImp* c1 = static_cast<const CircleImp*>( tqparents[0] );
+ const CircleImp* c2 = static_cast<const CircleImp*>( tqparents[1] );
const Coordinate o1 = c1->center();
const Coordinate o2 = c2->center();
const double r1sq = c1->squareRadius();
@@ -316,15 +316,15 @@ const ArcLineIntersectionType* ArcLineIntersectionType::instance()
return &t;
}
-ObjectImp* ArcLineIntersectionType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ArcLineIntersectionType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- int side = static_cast<const IntImp*>( parents[2] )->data();
+ int side = static_cast<const IntImp*>( tqparents[2] )->data();
assert( side == 1 || side == -1 );
- const LineData line = static_cast<const AbstractLineImp*>( parents[1] )->data();
+ const LineData line = static_cast<const AbstractLineImp*>( tqparents[1] )->data();
- const ArcImp* c = static_cast<const ArcImp*>( parents[0] );
+ const ArcImp* c = static_cast<const ArcImp*>( tqparents[0] );
const double r = c->radius();
Coordinate ret = calcArcLineIntersect( c->center(), r*r, c->startAngle(),
c->angle(), line, side );
diff --git a/kig/objects/intersection_types.h b/kig/objects/intersection_types.h
index 9e1df62e..46d60199 100644
--- a/kig/objects/intersection_types.h
+++ b/kig/objects/intersection_types.h
@@ -36,7 +36,7 @@ class ConicLineIntersectionType
~ConicLineIntersectionType();
public:
static const ConicLineIntersectionType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -51,7 +51,7 @@ class ConicLineOtherIntersectionType
~ConicLineOtherIntersectionType();
public:
static const ConicLineOtherIntersectionType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -62,7 +62,7 @@ class LineLineIntersectionType
~LineLineIntersectionType();
public:
static const LineLineIntersectionType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -73,7 +73,7 @@ class LineCubicIntersectionType
~LineCubicIntersectionType();
public:
static const LineCubicIntersectionType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -84,7 +84,7 @@ class CircleCircleIntersectionType
~CircleCircleIntersectionType();
public:
static const CircleCircleIntersectionType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -98,7 +98,7 @@ class ArcLineIntersectionType
~ArcLineIntersectionType();
public:
static const ArcLineIntersectionType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
diff --git a/kig/objects/line_imp.cc b/kig/objects/line_imp.cc
index a49078a1..0cb8a985 100644
--- a/kig/objects/line_imp.cc
+++ b/kig/objects/line_imp.cc
@@ -186,8 +186,8 @@ const TQString AbstractLineImp::equationString() const
TQString::fromUtf8( r > 0 ? "+" : "-" ) +
TQString::fromUtf8( " %2" );
- ret = ret.arg( m, 0, 'g', 3 );
- ret = ret.arg( abs( r ), 0, 'g', 3 );
+ ret = ret.tqarg( m, 0, 'g', 3 );
+ ret = ret.tqarg( abs( r ), 0, 'g', 3 );
return ret;
}
@@ -197,7 +197,7 @@ void SegmentImp::draw( KigPainter& p ) const
p.drawSegment( mdata );
}
-bool SegmentImp::contains( const Coordinate& p, int width, const KigWidget& w ) const
+bool SegmentImp::tqcontains( const Coordinate& p, int width, const KigWidget& w ) const
{
return internalContainsPoint( p, w.screenInfo().normalMiss( width ) );
}
@@ -207,7 +207,7 @@ void RayImp::draw( KigPainter& p ) const
p.drawRay( mdata );
}
-bool RayImp::contains( const Coordinate& p, int width, const KigWidget& w ) const
+bool RayImp::tqcontains( const Coordinate& p, int width, const KigWidget& w ) const
{
return internalContainsPoint( p, w.screenInfo().normalMiss( width ) );
}
@@ -217,7 +217,7 @@ void LineImp::draw( KigPainter& p ) const
p.drawLine( mdata );
}
-bool LineImp::contains( const Coordinate& p, int width, const KigWidget& w ) const
+bool LineImp::tqcontains( const Coordinate& p, int width, const KigWidget& w ) const
{
return internalContainsPoint( p, w.screenInfo().normalMiss( width ) );
}
diff --git a/kig/objects/line_imp.h b/kig/objects/line_imp.h
index b12c045d..c52d8afd 100644
--- a/kig/objects/line_imp.h
+++ b/kig/objects/line_imp.h
@@ -99,7 +99,7 @@ public:
SegmentImp( const LineData& d );
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& si ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& si ) const;
Rect surroundingRect() const;
ObjectImp* transform( const Transformation& ) const;
@@ -154,7 +154,7 @@ public:
RayImp( const LineData& d );
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& si ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& si ) const;
Rect surroundingRect() const;
ObjectImp* transform( const Transformation& ) const;
@@ -195,7 +195,7 @@ public:
*/
LineImp( const LineData& d );
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& si ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& si ) const;
Rect surroundingRect() const;
ObjectImp* transform( const Transformation& ) const;
diff --git a/kig/objects/line_type.cc b/kig/objects/line_type.cc
index a02cc80b..84deb46e 100644
--- a/kig/objects/line_type.cc
+++ b/kig/objects/line_type.cc
@@ -232,11 +232,11 @@ void SegmentABType::executeAction( int i, ObjectHolder&, ObjectTypeCalcer& c,
// pretend to use this var..
(void) i;
- std::vector<ObjectCalcer*> parents = c.parents();
- assert( margsparser.checkArgs( parents ) );
+ std::vector<ObjectCalcer*> tqparents = c.tqparents();
+ assert( margsparser.checkArgs( tqparents ) );
- Coordinate a = static_cast<const PointImp*>( parents[0]->imp() )->coordinate();
- Coordinate b = static_cast<const PointImp*>( parents[1]->imp() )->coordinate();
+ Coordinate a = static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate();
+ Coordinate b = static_cast<const PointImp*>( tqparents[1]->imp() )->coordinate();
bool ok = true;
double length = getDoubleFromUser(
@@ -246,8 +246,8 @@ void SegmentABType::executeAction( int i, ObjectHolder&, ObjectTypeCalcer& c,
Coordinate nb = a + ( b - a ).normalize( length );
- MonitorDataObjects mon( getAllParents( parents ) );
- parents[1]->move( nb, d.document() );
+ MonitorDataObjects mon( getAllParents( tqparents ) );
+ tqparents[1]->move( nb, d.document() );
KigCommand* cd = new KigCommand( d, i18n( "Resize Segment" ) );
mon.finish( cd );
d.history()->addCommand( cd );
diff --git a/kig/objects/locus_imp.cc b/kig/objects/locus_imp.cc
index edbdc88b..3bf85a9e 100644
--- a/kig/objects/locus_imp.cc
+++ b/kig/objects/locus_imp.cc
@@ -49,7 +49,7 @@ void LocusImp::draw( KigPainter& p ) const
p.drawCurve( this );
}
-bool LocusImp::contains( const Coordinate& p, int width, const KigWidget& w ) const
+bool LocusImp::tqcontains( const Coordinate& p, int width, const KigWidget& w ) const
{
return internalContainsPoint( p, w.screenInfo().normalMiss( width ), w.document() );
}
diff --git a/kig/objects/locus_imp.h b/kig/objects/locus_imp.h
index 568e0e7c..b2100634 100644
--- a/kig/objects/locus_imp.h
+++ b/kig/objects/locus_imp.h
@@ -24,7 +24,7 @@
/**
* LocusImp is an imp that consists of a copy of the curveimp that the
* moving point moves over, and an ObjectHierarchy that can calc (
- * given a point, and optionally some more parent objects the position
+ * given a point, and optionally some more tqparent objects the position
* of the moving point. The hierarchy should take the moving point as
* its *first* argument and all others after that. The others are
* used to make it possible for Locus to be updated when some of the
@@ -33,9 +33,9 @@
*
* This may seem rather complicated, but I think it is absolutely
* necessary to support locuses using Kig's object system. It would
- * be very bad for LocusImp to have to keep references to its parents
+ * be very bad for LocusImp to have to keep references to its tqparents
* as Objects ( since only the objects know how they are related to
- * their parents ). This is how we used to do it, but the current
+ * their tqparents ). This is how we used to do it, but the current
* method is far superior. First and foremost because the separation
* between ObjectImp and Object is something that Kig depends on very
* much, and because every ObjectImp should contain all the data it
@@ -66,7 +66,7 @@ public:
ObjectImp* transform( const Transformation& ) const;
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& ) const;
Rect surroundingRect() const;
bool inRect( const Rect& r, int width, const KigWidget& ) const;
double getParam( const Coordinate& point, const KigDocument& ) const;
diff --git a/kig/objects/object_calcer.cc b/kig/objects/object_calcer.cc
index 40545ed1..ae442aae 100644
--- a/kig/objects/object_calcer.cc
+++ b/kig/objects/object_calcer.cc
@@ -29,8 +29,8 @@
void ObjectTypeCalcer::calc( const KigDocument& doc )
{
Args a;
- a.reserve( mparents.size() );
- std::transform( mparents.begin(), mparents.end(),
+ a.reserve( mtqparents.size() );
+ std::transform( mtqparents.begin(), mtqparents.end(),
std::back_inserter( a ), std::mem_fun( &ObjectCalcer::imp ) );
ObjectImp* n = mtype->calc( a, doc );
delete mimp;
@@ -38,10 +38,10 @@ void ObjectTypeCalcer::calc( const KigDocument& doc )
}
ObjectTypeCalcer::ObjectTypeCalcer( const ObjectType* type,
- const std::vector<ObjectCalcer*>& parents, bool sort )
- : mparents( ( sort )?type->sortArgs( parents ):parents ), mtype( type ), mimp( 0 )
+ const std::vector<ObjectCalcer*>& tqparents, bool sort )
+ : mtqparents( ( sort )?type->sortArgs( tqparents ):tqparents ), mtype( type ), mimp( 0 )
{
- std::for_each( mparents.begin(), mparents.end(),
+ std::for_each( mtqparents.begin(), mtqparents.end(),
std::bind2nd( std::mem_fun( &ObjectCalcer::addChild ), this ) );
}
@@ -68,9 +68,9 @@ void ObjectConstCalcer::calc( const KigDocument& )
{
}
-std::vector<ObjectCalcer*> ObjectConstCalcer::parents() const
+std::vector<ObjectCalcer*> ObjectConstCalcer::tqparents() const
{
- // we have no parents..
+ // we have no tqparents..
return std::vector<ObjectCalcer*>();
}
@@ -99,29 +99,29 @@ const ObjectImp* ObjectTypeCalcer::imp() const
return mimp;
}
-std::vector<ObjectCalcer*> ObjectTypeCalcer::parents() const
+std::vector<ObjectCalcer*> ObjectTypeCalcer::tqparents() const
{
- return mparents;
+ return mtqparents;
}
void ObjectCalcer::addChild( ObjectCalcer* c )
{
- mchildren.push_back( c );
+ mtqchildren.push_back( c );
ref();
}
void ObjectCalcer::delChild( ObjectCalcer* c )
{
- std::vector<ObjectCalcer*>::iterator i = std::find( mchildren.begin(), mchildren.end(), c );
- assert( i != mchildren.end() );
+ std::vector<ObjectCalcer*>::iterator i = std::find( mtqchildren.begin(), mtqchildren.end(), c );
+ assert( i != mtqchildren.end() );
- mchildren.erase( i );
+ mtqchildren.erase( i );
deref();
}
ObjectTypeCalcer::~ObjectTypeCalcer()
{
- std::for_each( mparents.begin(), mparents.end(),
+ std::for_each( mtqparents.begin(), mtqparents.end(),
std::bind2nd( std::mem_fun( &ObjectCalcer::delChild ), this ) );
delete mimp;
}
@@ -131,21 +131,21 @@ const ObjectType* ObjectTypeCalcer::type() const
return mtype;
}
-ObjectPropertyCalcer::ObjectPropertyCalcer( ObjectCalcer* parent, int propid )
- : mimp( 0 ), mparent( parent ), mpropid( propid )
+ObjectPropertyCalcer::ObjectPropertyCalcer( ObjectCalcer* tqparent, int propid )
+ : mimp( 0 ), mtqparent( tqparent ), mpropid( propid )
{
// Some weird C++ thing prevents me from calling protected members
- // of ObjectCalcer on mparent.. This is an ugly workaround..
- ( mparent->*&ObjectCalcer::addChild )( this );
- //mparent->addChild( this );
+ // of ObjectCalcer on mtqparent.. This is an ugly workaround..
+ ( mtqparent->*&ObjectCalcer::addChild )( this );
+ //mtqparent->addChild( this );
}
ObjectPropertyCalcer::~ObjectPropertyCalcer()
{
// Some weird C++ thing prevents me from calling protected members
- // of ObjectCalcer on mparent.. This is an ugly workaround..
- ( mparent->*&ObjectCalcer::delChild )( this );
- //mparent->delChild( this );
+ // of ObjectCalcer on mtqparent.. This is an ugly workaround..
+ ( mtqparent->*&ObjectCalcer::delChild )( this );
+ //mtqparent->delChild( this );
delete mimp;
}
@@ -154,16 +154,16 @@ const ObjectImp* ObjectPropertyCalcer::imp() const
return mimp;
}
-std::vector<ObjectCalcer*> ObjectPropertyCalcer::parents() const
+std::vector<ObjectCalcer*> ObjectPropertyCalcer::tqparents() const
{
std::vector<ObjectCalcer*> ret;
- ret.push_back( mparent );
+ ret.push_back( mtqparent );
return ret;
}
void ObjectPropertyCalcer::calc( const KigDocument& doc )
{
- ObjectImp* n = mparent->imp()->property( mpropid, doc );
+ ObjectImp* n = mtqparent->imp()->property( mpropid, doc );
delete mimp;
mimp = n;
}
@@ -175,15 +175,15 @@ ObjectImp* ObjectConstCalcer::switchImp( ObjectImp* newimp )
return ret;
}
-std::vector<ObjectCalcer*> ObjectCalcer::children() const
+std::vector<ObjectCalcer*> ObjectCalcer::tqchildren() const
{
- return mchildren;
+ return mtqchildren;
}
const ObjectImpType* ObjectPropertyCalcer::impRequirement(
ObjectCalcer*, const std::vector<ObjectCalcer*>& ) const
{
- return mparent->imp()->impRequirementForProperty( mpropid );
+ return mtqparent->imp()->impRequirementForProperty( mpropid );
}
const ObjectImpType* ObjectConstCalcer::impRequirement(
@@ -197,12 +197,12 @@ const ObjectImpType* ObjectTypeCalcer::impRequirement(
ObjectCalcer* o, const std::vector<ObjectCalcer*>& os ) const
{
Args args;
- args.reserve( mparents.size() );
+ args.reserve( mtqparents.size() );
std::transform(
os.begin(), os.end(),
std::back_inserter( args ),
std::mem_fun( &ObjectCalcer::imp ) );
- assert( std::find( args.begin(), args.end(), o->imp() ) != args.end() );
+ assert( std::tqfind( args.begin(), args.end(), o->imp() ) != args.end() );
return mtype->impRequirement( o->imp(), args );
}
@@ -220,9 +220,9 @@ void ObjectTypeCalcer::setParents( const std::vector<ObjectCalcer*> np )
{
std::for_each( np.begin(), np.end(),
std::bind2nd( std::mem_fun( &ObjectCalcer::addChild ), this ) );
- std::for_each( mparents.begin(), mparents.end(),
+ std::for_each( mtqparents.begin(), mtqparents.end(),
std::bind2nd( std::mem_fun( &ObjectCalcer::delChild ), this ) );
- mparents = np;
+ mtqparents = np;
}
void ObjectTypeCalcer::setType( const ObjectType* t )
@@ -270,15 +270,15 @@ void ObjectTypeCalcer::move( const Coordinate& to, const KigDocument& doc )
{
// we need to check if type can in fact move, because this check is
// not done for us in all circumstances ( e.g. LineABType::move uses
- // move on its parents to move them ), and the ObjectType's depend
+ // move on its tqparents to move them ), and the ObjectType's depend
// on move only being called if canMove() returns true..
if ( mtype->canMove( *this ) )
mtype->move( *this, to, doc );
}
-ObjectCalcer* ObjectPropertyCalcer::parent() const
+ObjectCalcer* ObjectPropertyCalcer::tqparent() const
{
- return mparent;
+ return mtqparent;
}
ObjectCalcer::ObjectCalcer()
@@ -303,16 +303,16 @@ bool ObjectConstCalcer::isDefinedOnOrThrough( const ObjectCalcer* ) const
bool ObjectPropertyCalcer::isDefinedOnOrThrough( const ObjectCalcer* o ) const
{
- return o == mparent &&
- mparent->imp()->isPropertyDefinedOnOrThroughThisImp( propId() );
+ return o == mtqparent &&
+ mtqparent->imp()->isPropertyDefinedOnOrThroughThisImp( propId() );
}
bool ObjectTypeCalcer::isDefinedOnOrThrough( const ObjectCalcer* o ) const
{
Args args;
- args.reserve( mparents.size() );
+ args.reserve( mtqparents.size() );
std::transform(
- mparents.begin(), mparents.end(),
+ mtqparents.begin(), mtqparents.end(),
std::back_inserter( args ),
std::mem_fun( &ObjectCalcer::imp ) );
if ( std::find( args.begin(), args.end(), o->imp() ) == args.end() )
diff --git a/kig/objects/object_calcer.h b/kig/objects/object_calcer.h
index 6df94fe8..1aa83db4 100644
--- a/kig/objects/object_calcer.h
+++ b/kig/objects/object_calcer.h
@@ -33,12 +33,12 @@ void intrusive_ptr_release( ObjectCalcer* p );
* be calculated from the two PointImp's it has to go through; every
* time either of them moves, this calculation is redone. In this
* case, there would be an ObjectCalcer that keeps a reference to its
- * two parents ( the ObjectCalcer's representing the points ), and
+ * two tqparents ( the ObjectCalcer's representing the points ), and
* that will calculate its ObjectImp value every time it is asked to
- * do so ( i.e. every time one of its parents moves.. ).
+ * do so ( i.e. every time one of its tqparents moves.. ).
*
* Each ObjectHolder keeps its ObjectImp itself, and recalculates it
- * from its parents in its calc() method ( if necessary ).
+ * from its tqparents in its calc() method ( if necessary ).
*
* Because of the complex relations that ObjectCalcer's hold to other
* ObjectCalcer's and to other classes, they have been made
@@ -46,12 +46,12 @@ void intrusive_ptr_release( ObjectCalcer* p );
* how much times a pointer to them is held. If this count reaches 0,
* this means that nobody needs them anymore, and they delete
* themselves. E.g. an ObjectCalcer always keeps a reference to its
- * parents, to ensure that those aren't deleted before it is deleted.
+ * tqparents, to ensure that those aren't deleted before it is deleted.
*
* At runtime, there will be an entire graph of ObjectCalcer that
- * depend on their parents.. At the bottom, there are Calcer's that
+ * depend on their tqparents.. At the bottom, there are Calcer's that
* the user is aware of, and that are held by ObjectHolder's. At the
- * top, there are Calcer's without parents that serve only to hold
+ * top, there are Calcer's without tqparents that serve only to hold
* some data. Those are most likely ObjectConstCalcer's. There are
* some algorithms to work with the dependency graph in various ways
* in ../misc/calcpath.h
@@ -67,7 +67,7 @@ class ObjectCalcer
protected:
/**
* ObjectCalcer's are reference counted.. They all take a reference
- * to their parents, and some other classes like ObjectHolder take a
+ * to their tqparents, and some other classes like ObjectHolder take a
* reference to some ObjectCalcer's that they don't want to see
* deleted..
*/
@@ -77,10 +77,10 @@ protected:
void ref();
void deref();
- // we keep track of our children, so algorithms can easily walk over
+ // we keep track of our tqchildren, so algorithms can easily walk over
// the dependency graph..
- std::vector<ObjectCalcer*> mchildren;
+ std::vector<ObjectCalcer*> mtqchildren;
ObjectCalcer();
public:
@@ -90,7 +90,7 @@ public:
*/
void addChild( ObjectCalcer* c );
/**
- * a calcer should call this in its destructor, to inform its parent
+ * a calcer should call this in its destructor, to inform its tqparent
* that it is no longer a child of this calcer. This will release
* the reference taken in addChild..
*/
@@ -102,29 +102,29 @@ public:
/**
* Returns the child ObjectCalcer's of this ObjectCalcer.
*/
- std::vector<ObjectCalcer*> children() const;
+ std::vector<ObjectCalcer*> tqchildren() const;
virtual ~ObjectCalcer();
/**
- * Returns the parent ObjectCalcer's of this ObjectCalcer.
+ * Returns the tqparent ObjectCalcer's of this ObjectCalcer.
*/
- virtual std::vector<ObjectCalcer*> parents() const = 0;
+ virtual std::vector<ObjectCalcer*> tqparents() const = 0;
/**
* Returns the ObjectImp of this ObjectCalcer.
*/
virtual const ObjectImp* imp() const = 0;
/**
* Makes the ObjectCalcer recalculate its ObjectImp from its
- * parents.
+ * tqparents.
*/
virtual void calc( const KigDocument& ) = 0;
/**
- * An ObjectCalcer expects its parents to have an ObjectImp of a
+ * An ObjectCalcer expects its tqparents to have an ObjectImp of a
* certain type. This method returns the ObjectImpType that \p o
- * should have. \p os is a list of all the parents in order, and
+ * should have. \p os is a list of all the tqparents in order, and
* \p o is part of it. This method will return the ObjectImpType
- * that the parent should *at least* be. For example, a Translated
+ * that the tqparent should *at least* be. For example, a Translated
* object can translate any sort of object, so it will return
* ObjectImp::stype() here ( the topmost ObjectImpType, that all
* other ObjectImpType's inherit ).
@@ -144,7 +144,7 @@ public:
virtual bool isFreelyTranslatable() const;
/**
* Moving an object most of the time signifies invoking changes in
- * some of its parents. This method returns the set of parents that
+ * some of its tqparents. This method returns the set of tqparents that
* will be changed in the move() method. The object itself should
* not be included.
*/
@@ -182,30 +182,30 @@ public:
class ObjectTypeCalcer
: public ObjectCalcer
{
- std::vector<ObjectCalcer*> mparents;
+ std::vector<ObjectCalcer*> mtqparents;
const ObjectType* mtype;
ObjectImp* mimp;
public:
typedef myboost::intrusive_ptr<ObjectTypeCalcer> shared_ptr;
/**
- * Construct a new ObjectTypeCalcer with a given type and parents.
+ * Construct a new ObjectTypeCalcer with a given type and tqparents.
*/
-// ObjectTypeCalcer( const ObjectType* type, const std::vector<ObjectCalcer*>& parents );
+// ObjectTypeCalcer( const ObjectType* type, const std::vector<ObjectCalcer*>& tqparents );
/**
* the sort boolean tells whether the sortArgs method should be invoked or not;
* if not present
*/
- ObjectTypeCalcer( const ObjectType* type, const std::vector<ObjectCalcer*>& parents, bool sort=true );
+ ObjectTypeCalcer( const ObjectType* type, const std::vector<ObjectCalcer*>& tqparents, bool sort=true );
~ObjectTypeCalcer();
const ObjectImp* imp() const;
- std::vector<ObjectCalcer*> parents() const;
+ std::vector<ObjectCalcer*> tqparents() const;
void calc( const KigDocument& doc );
/**
- * Set the parents of this ObjectTypeCalcer to np. This object will
- * release the reference it had to its old parents, and take a new
- * one on the new parents.
+ * Set the tqparents of this ObjectTypeCalcer to np. This object will
+ * release the reference it had to its old tqparents, and take a new
+ * one on the new tqparents.
*/
void setParents( const std::vector<ObjectCalcer*> np );
void setType( const ObjectType* t );
@@ -248,7 +248,7 @@ public:
const ObjectImp* imp() const;
void calc( const KigDocument& doc );
- std::vector<ObjectCalcer*> parents() const;
+ std::vector<ObjectCalcer*> tqparents() const;
/**
* Set the ObjectImp of this ObjectConstCalcer to the given
@@ -267,7 +267,7 @@ public:
};
/**
- * This is an ObjectCalcer that has a single parent, and gets a
+ * This is an ObjectCalcer that has a single tqparent, and gets a
* certain property from it in its calc() method.
*
* \see ObjectImp::property
@@ -276,22 +276,22 @@ class ObjectPropertyCalcer
: public ObjectCalcer
{
ObjectImp* mimp;
- ObjectCalcer* mparent;
+ ObjectCalcer* mtqparent;
int mpropid;
public:
/**
* Construct a new ObjectPropertyCalcer, that will get the property
- * from parent with number propid.
+ * from tqparent with number propid.
*/
- ObjectPropertyCalcer( ObjectCalcer* parent, int propid );
+ ObjectPropertyCalcer( ObjectCalcer* tqparent, int propid );
~ObjectPropertyCalcer();
const ObjectImp* imp() const;
- std::vector<ObjectCalcer*> parents() const;
+ std::vector<ObjectCalcer*> tqparents() const;
void calc( const KigDocument& doc );
int propId() const;
- ObjectCalcer* parent() const;
+ ObjectCalcer* tqparent() const;
const ObjectImpType* impRequirement(
ObjectCalcer* o, const std::vector<ObjectCalcer*>& os ) const;
diff --git a/kig/objects/object_drawer.cc b/kig/objects/object_drawer.cc
index f92fabe7..1fc0f2e0 100644
--- a/kig/objects/object_drawer.cc
+++ b/kig/objects/object_drawer.cc
@@ -32,8 +32,8 @@ void ObjectDrawer::draw( const ObjectImp& imp, KigPainter& p, bool sel ) const
if ( mshown || nv )
{
p.setBrushStyle( Qt::NoBrush );
- p.setBrushColor( sel ? Qt::red : ( mshown?mcolor:Qt::gray ) );
- p.setPen( TQPen ( sel ? Qt::red : ( mshown?mcolor:Qt::gray ), 1) );
+ p.setBrushColor( sel ? TQt::red : ( mshown?mcolor:TQt::gray ) );
+ p.setPen( TQPen ( sel ? TQt::red : ( mshown?mcolor:TQt::gray ), 1) );
p.setWidth( mwidth );
p.setStyle( mstyle );
p.setPointStyle( mpointstyle );
@@ -41,10 +41,10 @@ void ObjectDrawer::draw( const ObjectImp& imp, KigPainter& p, bool sel ) const
}
}
-bool ObjectDrawer::contains( const ObjectImp& imp, const Coordinate& pt, const KigWidget& w, bool nv ) const
+bool ObjectDrawer::tqcontains( const ObjectImp& imp, const Coordinate& pt, const KigWidget& w, bool nv ) const
{
bool shownornv = mshown || nv;
- return shownornv && imp.contains( pt, mwidth, w );
+ return shownornv && imp.tqcontains( pt, mwidth, w );
}
bool ObjectDrawer::shown( ) const
@@ -133,7 +133,7 @@ ObjectDrawer::ObjectDrawer( const TQColor& color, int width, bool shown, Qt::Pen
}
ObjectDrawer::ObjectDrawer()
- : mcolor( Qt::blue ), mshown( true ), mwidth( -1 ), mstyle( Qt::SolidLine ), mpointstyle( 0 )
+ : mcolor( TQt::blue ), mshown( true ), mwidth( -1 ), mstyle( Qt::SolidLine ), mpointstyle( 0 )
{
}
@@ -170,7 +170,7 @@ TQString ObjectDrawer::pointStyleToString() const
else if ( mpointstyle == 4 )
return "Cross";
assert( false );
- return TQString::null;
+ return TQString();
}
Qt::PenStyle ObjectDrawer::styleFromString( const TQString& style )
@@ -190,15 +190,15 @@ Qt::PenStyle ObjectDrawer::styleFromString( const TQString& style )
TQString ObjectDrawer::styleToString() const
{
- if ( mstyle == Qt::SolidLine )
+ if ( mstyle == TQt::SolidLine )
return "SolidLine";
- else if ( mstyle == Qt::DashLine )
+ else if ( mstyle == TQt::DashLine )
return "DashLine";
- else if ( mstyle == Qt::DotLine )
+ else if ( mstyle == TQt::DotLine )
return "DotLine";
- else if ( mstyle == Qt::DashDotLine )
+ else if ( mstyle == TQt::DashDotLine )
return "DashDotLine";
- else if ( mstyle == Qt::DashDotDotLine )
+ else if ( mstyle == TQt::DashDotDotLine )
return "DashDotDotLine";
return "SolidLine";
}
diff --git a/kig/objects/object_drawer.h b/kig/objects/object_drawer.h
index 6206522e..7fca8d4e 100644
--- a/kig/objects/object_drawer.h
+++ b/kig/objects/object_drawer.h
@@ -52,8 +52,8 @@ class ObjectDrawer
int mpointstyle;
public:
/**
- * Construct a new ObjectDrawer with a default color ( Qt::blue ),
- * width ( -1 ), shown state ( true ), PenStyle ( Qt::SolidLine ),
+ * Construct a new ObjectDrawer with a default color ( TQt::blue ),
+ * width ( -1 ), shown state ( true ), PenStyle ( TQt::SolidLine ),
* and pointstyle ( 0 )
*/
ObjectDrawer();
@@ -68,7 +68,7 @@ public:
* dependent on whether it is shown ( when it will never contain
* anything ), and on its width..
*/
- bool contains( const ObjectImp& imp, const Coordinate& pt, const KigWidget& w, bool nv = false ) const;
+ bool tqcontains( const ObjectImp& imp, const Coordinate& pt, const KigWidget& w, bool nv = false ) const;
/**
* returns whether the object \p imp is in the rectangle \p r . This is
* dependent on whether it is shown and on its width..
diff --git a/kig/objects/object_factory.cc b/kig/objects/object_factory.cc
index f2957a7e..5b1a6add 100644
--- a/kig/objects/object_factory.cc
+++ b/kig/objects/object_factory.cc
@@ -109,21 +109,21 @@ ObjectTypeCalcer* ObjectFactory::relativePointCalcer(
x = loc.x - reference.x;
y = loc.y - reference.y;
}
- std::vector<ObjectCalcer*> parents;
- parents.push_back( new ObjectConstCalcer( new DoubleImp( x ) ) );
- parents.push_back( new ObjectConstCalcer( new DoubleImp( y ) ) );
- parents.push_back( o );
- return new ObjectTypeCalcer( RelativePointType::instance(), parents );
+ std::vector<ObjectCalcer*> tqparents;
+ tqparents.push_back( new ObjectConstCalcer( new DoubleImp( x ) ) );
+ tqparents.push_back( new ObjectConstCalcer( new DoubleImp( y ) ) );
+ tqparents.push_back( o );
+ return new ObjectTypeCalcer( RelativePointType::instance(), tqparents );
}
ObjectTypeCalcer* ObjectFactory::constrainedPointCalcer(
ObjectCalcer* curve, double param ) const
{
assert( curve->imp()->inherits( CurveImp::stype() ) );
- std::vector<ObjectCalcer*> parents;
- parents.push_back( new ObjectConstCalcer( new DoubleImp( param ) ) );
- parents.push_back( curve );
- return new ObjectTypeCalcer( ConstrainedPointType::instance(), parents );
+ std::vector<ObjectCalcer*> tqparents;
+ tqparents.push_back( new ObjectConstCalcer( new DoubleImp( param ) ) );
+ tqparents.push_back( curve );
+ return new ObjectTypeCalcer( ConstrainedPointType::instance(), tqparents );
}
ObjectHolder* ObjectFactory::constrainedPoint(
@@ -152,24 +152,24 @@ ObjectTypeCalcer* ObjectFactory::locusCalcer(
assert( dynamic_cast<const ObjectTypeCalcer*>( a ) );
ObjectTypeCalcer* constrained = static_cast<ObjectTypeCalcer*>( a );
assert( constrained->type()->inherits( ObjectType::ID_ConstrainedPointType ) );
- assert( constrained->parents().size() == 2 );
- ObjectCalcer* curve = a->parents().back();
+ assert( constrained->tqparents().size() == 2 );
+ ObjectCalcer* curve = a->tqparents().back();
const ObjectCalcer* moving = b;
- std::vector<ObjectCalcer*> hierparents;
- hierparents.push_back( constrained );
- std::vector<ObjectCalcer*> sideOfTree = sideOfTreePath( hierparents, moving );
- std::copy( sideOfTree.begin(), sideOfTree.end(), std::back_inserter( hierparents ) );
+ std::vector<ObjectCalcer*> hiertqparents;
+ hiertqparents.push_back( constrained );
+ std::vector<ObjectCalcer*> sideOfTree = sideOfTreePath( hiertqparents, moving );
+ std::copy( sideOfTree.begin(), sideOfTree.end(), std::back_inserter( hiertqparents ) );
- ObjectHierarchy hier( hierparents, moving );
+ ObjectHierarchy hier( hiertqparents, moving );
- std::vector<ObjectCalcer*> realparents( 2 + sideOfTree.size(), 0 );
- realparents[0] = new ObjectConstCalcer( new HierarchyImp( hier ) );
- realparents[1] = curve;
- copy( sideOfTree.begin(), sideOfTree.end(), realparents.begin() + 2 );
+ std::vector<ObjectCalcer*> realtqparents( 2 + sideOfTree.size(), 0 );
+ realtqparents[0] = new ObjectConstCalcer( new HierarchyImp( hier ) );
+ realtqparents[1] = curve;
+ copy( sideOfTree.begin(), sideOfTree.end(), realtqparents.begin() + 2 );
- return new ObjectTypeCalcer( LocusType::instance(), realparents );
+ return new ObjectTypeCalcer( LocusType::instance(), realtqparents );
}
ObjectHolder* ObjectFactory::locus( ObjectCalcer* a, ObjectCalcer* b ) const
@@ -179,35 +179,35 @@ ObjectHolder* ObjectFactory::locus( ObjectCalcer* a, ObjectCalcer* b ) const
ObjectHolder* ObjectFactory::label(
const TQString& s, const Coordinate& loc,
- bool needframe, const std::vector<ObjectCalcer*>& parents,
+ bool needframe, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& doc ) const
{
- return new ObjectHolder( labelCalcer( s, loc, needframe, parents, doc ) );
+ return new ObjectHolder( labelCalcer( s, loc, needframe, tqparents, doc ) );
}
ObjectTypeCalcer* ObjectFactory::labelCalcer(
const TQString& s, const Coordinate& loc,
- bool needframe, const std::vector<ObjectCalcer*>& parents,
+ bool needframe, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& doc ) const
{
- return attachedLabelCalcer( s, 0, loc, needframe, parents, doc );
+ return attachedLabelCalcer( s, 0, loc, needframe, tqparents, doc );
}
ObjectTypeCalcer* ObjectFactory::attachedLabelCalcer(
const TQString& s, ObjectCalcer* p,
const Coordinate& loc, bool needframe,
- const std::vector<ObjectCalcer*>& nparents,
+ const std::vector<ObjectCalcer*>& ntqparents,
const KigDocument& doc ) const
{
- std::vector<ObjectCalcer*> parents;
- parents.reserve( nparents.size() + 3 );
- parents.push_back( new ObjectConstCalcer( new IntImp( needframe ? 1 : 0 ) ) );
+ std::vector<ObjectCalcer*> tqparents;
+ tqparents.reserve( ntqparents.size() + 3 );
+ tqparents.push_back( new ObjectConstCalcer( new IntImp( needframe ? 1 : 0 ) ) );
- parents.push_back( getAttachPoint( p, loc, doc ) );
+ tqparents.push_back( getAttachPoint( p, loc, doc ) );
- parents.push_back( new ObjectConstCalcer( new StringImp( s ) ) );
- std::copy( nparents.begin(), nparents.end(), std::back_inserter( parents ) );
- ObjectTypeCalcer* ret = new ObjectTypeCalcer( TextType::instance(), parents );
+ tqparents.push_back( new ObjectConstCalcer( new StringImp( s ) ) );
+ std::copy( ntqparents.begin(), ntqparents.end(), std::back_inserter( tqparents ) );
+ ObjectTypeCalcer* ret = new ObjectTypeCalcer( TextType::instance(), tqparents );
ret->calc( doc );
return ret;
}
@@ -266,18 +266,18 @@ ObjectCalcer* ObjectFactory::getAttachPoint(
}
ObjectHolder* ObjectFactory::attachedLabel(
- const TQString& s, ObjectCalcer* locationparent,
+ const TQString& s, ObjectCalcer* locationtqparent,
const Coordinate& loc, bool needframe,
- const std::vector<ObjectCalcer*>& parents,
+ const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& doc ) const
{
- return new ObjectHolder( attachedLabelCalcer( s, locationparent, loc, needframe, parents, doc ) );
+ return new ObjectHolder( attachedLabelCalcer( s, locationtqparent, loc, needframe, tqparents, doc ) );
}
ObjectPropertyCalcer* ObjectFactory::propertyObjectCalcer(
ObjectCalcer* o, const char* p ) const
{
- int wp = o->imp()->propertiesInternalNames().findIndex( p );
+ int wp = o->imp()->propertiesInternalNames().tqfindIndex( p );
if ( wp == -1 ) return 0;
return new ObjectPropertyCalcer( o, wp );
}
@@ -299,12 +299,12 @@ void ObjectFactory::redefinePoint(
std::mem_fun( calcmeth ) );
ObjectCalcer* v = 0;
- // we don't want one of our children as a parent...
- std::set<ObjectCalcer*> children = getAllChildren( point );
+ // we don't want one of our tqchildren as a tqparent...
+ std::set<ObjectCalcer*> tqchildren = getAllChildren( point );
for ( std::vector<ObjectCalcer*>::iterator i = os.begin();
i != os.end(); ++i )
if ( (*i)->imp()->inherits( CurveImp::stype() ) &&
- children.find( *i ) == children.end() )
+ tqchildren.find( *i ) == tqchildren.end() )
{
v = *i;
break;
@@ -321,15 +321,15 @@ void ObjectFactory::redefinePoint(
// point already was constrained -> simply update the param
// DataObject and make sure point is on the right curve...
ObjectCalcer* dataobj = 0;
- std::vector<ObjectCalcer*> parents = point->parents();
- assert( parents.size() == 2 );
- assert ( parents[0]->imp()->inherits( DoubleImp::stype() ) );
- dataobj = parents[0];
-
- parents.clear();
- parents.push_back( dataobj );
- parents.push_back( v );
- point->setParents( parents );
+ std::vector<ObjectCalcer*> tqparents = point->tqparents();
+ assert( tqparents.size() == 2 );
+ assert ( tqparents[0]->imp()->inherits( DoubleImp::stype() ) );
+ dataobj = tqparents[0];
+
+ tqparents.clear();
+ tqparents.push_back( dataobj );
+ tqparents.push_back( v );
+ point->setParents( tqparents );
assert( dynamic_cast<ObjectConstCalcer*>( dataobj ) );
static_cast<ObjectConstCalcer*>( dataobj )->setImp(
diff --git a/kig/objects/object_factory.h b/kig/objects/object_factory.h
index 30f080d9..f3a28d66 100644
--- a/kig/objects/object_factory.h
+++ b/kig/objects/object_factory.h
@@ -94,26 +94,26 @@ public:
ObjectHolder* locus( ObjectCalcer* a, ObjectCalcer* b ) const;
/**
- * returns a label with text \p s at point \p c .. It ( and its parents )
+ * returns a label with text \p s at point \p c .. It ( and its tqparents )
* is calced already...
*/
ObjectHolder* label(
const TQString& s, const Coordinate& loc,
- bool needframe, const std::vector<ObjectCalcer*>& parents,
+ bool needframe, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& doc ) const;
ObjectTypeCalcer* labelCalcer(
const TQString& s, const Coordinate& loc,
- bool needframe, const std::vector<ObjectCalcer*>& parents,
+ bool needframe, const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& doc ) const;
/**
* this one does the same as the above, only that the new label is
- * attached to locationparent if it is non-null..
+ * attached to locationtqparent if it is non-null..
*/
ObjectTypeCalcer* attachedLabelCalcer(
- const TQString& s, ObjectCalcer* locationparent,
+ const TQString& s, ObjectCalcer* locationtqparent,
const Coordinate& loc, bool needframe,
- const std::vector<ObjectCalcer*>& parents,
+ const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& doc ) const;
/**
* this has been added because it comes handy when redefining
@@ -121,13 +121,13 @@ public:
* attach point from the method above
*/
ObjectCalcer* getAttachPoint(
- ObjectCalcer* locationparent,
+ ObjectCalcer* locationtqparent,
const Coordinate& loc,
const KigDocument& doc ) const;
ObjectHolder* attachedLabel(
- const TQString& s, ObjectCalcer* locationparent,
+ const TQString& s, ObjectCalcer* locationtqparent,
const Coordinate& loc, bool needframe,
- const std::vector<ObjectCalcer*>& parents,
+ const std::vector<ObjectCalcer*>& tqparents,
const KigDocument& doc ) const;
/**
diff --git a/kig/objects/object_holder.cc b/kig/objects/object_holder.cc
index 70e1100b..49e6da9d 100644
--- a/kig/objects/object_holder.cc
+++ b/kig/objects/object_holder.cc
@@ -80,9 +80,9 @@ void ObjectHolder::draw( KigPainter& p, bool selected ) const
mdrawer->draw( *imp(), p, selected );
}
-bool ObjectHolder::contains( const Coordinate& pt, const KigWidget& w, bool nv ) const
+bool ObjectHolder::tqcontains( const Coordinate& pt, const KigWidget& w, bool nv ) const
{
- return mdrawer->contains( *imp(), pt, w, nv );
+ return mdrawer->tqcontains( *imp(), pt, w, nv );
}
bool ObjectHolder::inRect( const Rect& r, const KigWidget& w ) const
@@ -145,7 +145,7 @@ const TQString ObjectHolder::name() const
return static_cast<const StringImp*>( mnamecalcer->imp() )->data();
}
else
- return TQString::null;
+ return TQString();
}
void ObjectHolder::setNameCalcer( ObjectConstCalcer* namecalcer )
@@ -160,5 +160,5 @@ TQString ObjectHolder::selectStatement() const
if ( n.isEmpty() )
return i18n( imp()->type()->selectStatement() );
else
- return i18n( imp()->type()->selectNameStatement() ).arg( n );
+ return i18n( imp()->type()->selectNameStatement() ).tqarg( n );
}
diff --git a/kig/objects/object_holder.h b/kig/objects/object_holder.h
index 0afd3892..0666fef1 100644
--- a/kig/objects/object_holder.h
+++ b/kig/objects/object_holder.h
@@ -77,7 +77,7 @@ public:
void setNameCalcer( ObjectConstCalcer* namecalcer );
/**
- * returns TQString::null if no name is set.
+ * returns TQString() if no name is set.
*/
const TQString name() const;
/**
@@ -103,7 +103,7 @@ public:
/**
* Returns whether this object contains the point \p p .
*/
- bool contains( const Coordinate& p, const KigWidget& w, bool nv = false ) const;
+ bool tqcontains( const Coordinate& p, const KigWidget& w, bool nv = false ) const;
/**
* Returns whether this object is in the rectangle \p r .
*/
diff --git a/kig/objects/object_imp.cc b/kig/objects/object_imp.cc
index 9a3ee679..7b2498a3 100644
--- a/kig/objects/object_imp.cc
+++ b/kig/objects/object_imp.cc
@@ -178,7 +178,7 @@ bool ObjectImp::canFillInNextEscape() const
return false;
}
-ObjectImpType::ObjectImpType( const ObjectImpType* parent,
+ObjectImpType::ObjectImpType( const ObjectImpType* tqparent,
const char* internalname,
const char* translatedname,
const char* selectstatement,
@@ -189,7 +189,7 @@ ObjectImpType::ObjectImpType( const ObjectImpType* parent,
const char* attachtothisstatement,
const char* showastatement,
const char* hideastatement )
- : mparent( parent ), minternalname( internalname ),
+ : mtqparent( tqparent ), minternalname( internalname ),
mtranslatedname( translatedname ), mselectstatement( selectstatement ),
mselectnamestatement( selectnamestatement ),
mremoveastatement( removeastatement ), maddastatement( addastatement ),
@@ -207,7 +207,7 @@ ObjectImpType::~ObjectImpType()
bool ObjectImpType::inherits( const ObjectImpType* t ) const
{
- return t == this || (mparent && mparent->inherits( t ) );
+ return t == this || (mtqparent && mtqparent->inherits( t ) );
}
const char* ObjectImpType::internalName() const
diff --git a/kig/objects/object_imp.h b/kig/objects/object_imp.h
index eaf29328..20484ecf 100644
--- a/kig/objects/object_imp.h
+++ b/kig/objects/object_imp.h
@@ -87,7 +87,7 @@ typedef unsigned int uint;
*/
class ObjectImpType
{
- const ObjectImpType* mparent;
+ const ObjectImpType* mtqparent;
const char* minternalname;
const char* mtranslatedname;
const char* mselectstatement;
@@ -126,12 +126,12 @@ public:
* hideastatement is a translatable string like "Hide a Segment"
*
* All translatable strings should have
- * I18N_NOOP around them ! @param parent is the ObjectImpType of
- * your parent ObjectImp type. Never give 0 as parent, except for
+ * I18N_NOOP around them ! @param tqparent is the ObjectImpType of
+ * your tqparent ObjectImp type. Never give 0 as tqparent, except for
* the top ObjectImp ObjectImpType..
*/
ObjectImpType(
- const ObjectImpType* parent, const char* internalname,
+ const ObjectImpType* tqparent, const char* internalname,
const char* translatedname,
const char* selectstatement,
const char* selectnamestatement,
@@ -170,7 +170,7 @@ public:
* Returns a translatable string of the form "Select point %1". %1
* will be filled in by whomever calls this function with the name
* of the object in question. This function should be used as
- * follows: i18n( x->selectNameStatement() ).arg( xname ).
+ * follows: i18n( x->selectNameStatement() ).tqarg( xname ).
*/
const char* selectNameStatement() const;
@@ -268,7 +268,7 @@ public:
virtual ObjectImp* transform( const Transformation& t ) const = 0;
virtual void draw( KigPainter& p ) const = 0;
- virtual bool contains( const Coordinate& p, int width,
+ virtual bool tqcontains( const Coordinate& p, int width,
const KigWidget& si ) const = 0;
virtual bool inRect( const Rect& r, int width,
const KigWidget& si ) const = 0;
diff --git a/kig/objects/object_imp_factory.cc b/kig/objects/object_imp_factory.cc
index 65cd9c94..116f0d0d 100644
--- a/kig/objects/object_imp_factory.cc
+++ b/kig/objects/object_imp_factory.cc
@@ -48,25 +48,25 @@ ObjectImpFactory::~ObjectImpFactory()
{
}
-static void addXYElements( const Coordinate& c, TQDomElement& parent, TQDomDocument& doc )
+static void addXYElements( const Coordinate& c, TQDomElement& tqparent, TQDomDocument& doc )
{
TQDomElement xe = doc.createElement( "x" );
xe.appendChild(
doc.createTextNode(
TQString::number( c.x ) ) );
- parent.appendChild( xe );
+ tqparent.appendChild( xe );
TQDomElement ye = doc.createElement( "y" );
ye.appendChild(
doc.createTextNode(
TQString::number( c.y ) ) );
- parent.appendChild( ye );
+ tqparent.appendChild( ye );
}
-static void addDoubleElement( const char* name, double d, TQDomElement& parent, TQDomDocument& doc )
+static void addDoubleElement( const char* name, double d, TQDomElement& tqparent, TQDomDocument& doc )
{
TQDomElement e = doc.createElement( name );
e.appendChild( doc.createTextNode( TQString::number( d ) ) );
- parent.appendChild( e );
+ tqparent.appendChild( e );
}
static void addCoordinateElement( const char* name, const Coordinate& d, TQDomElement& p, TQDomDocument& doc )
@@ -76,41 +76,41 @@ static void addCoordinateElement( const char* name, const Coordinate& d, TQDomEl
p.appendChild( e );
}
-TQString ObjectImpFactory::serialize( const ObjectImp& d, TQDomElement& parent,
+TQString ObjectImpFactory::serialize( const ObjectImp& d, TQDomElement& tqparent,
TQDomDocument& doc ) const
{
if( d.inherits( IntImp::stype() ) )
{
- parent.appendChild(
+ tqparent.appendChild(
doc.createTextNode(
TQString::number( static_cast<const IntImp&>( d ).data() ) ) );
- return TQString::fromLatin1( "int" );
+ return TQString::tqfromLatin1( "int" );
}
else if ( d.inherits( DoubleImp::stype() ) )
{
- parent.appendChild(
+ tqparent.appendChild(
doc.createTextNode(
TQString::number( static_cast<const DoubleImp&>( d ).data() ) ) );
- return TQString::fromLatin1( "double" );
+ return TQString::tqfromLatin1( "double" );
}
else if( d.inherits( StringImp::stype() ) )
{
- parent.appendChild(
+ tqparent.appendChild(
doc.createTextNode(
static_cast<const StringImp&>( d ).data() ) );
- return TQString::fromLatin1( "string" );
+ return TQString::tqfromLatin1( "string" );
}
else if ( d.inherits( TestResultImp::stype() ) )
{
- parent.appendChild(
+ tqparent.appendChild(
doc.createTextNode(
static_cast<const TestResultImp&>( d ).data() ) );
- return TQString::fromLatin1( "testresult" );
+ return TQString::tqfromLatin1( "testresult" );
}
else if( d.inherits( HierarchyImp::stype() ) )
{
- static_cast<const HierarchyImp&>( d ).data().serialize( parent, doc );
- return TQString::fromLatin1( "hierarchy" );
+ static_cast<const HierarchyImp&>( d ).data().serialize( tqparent, doc );
+ return TQString::tqfromLatin1( "hierarchy" );
}
else if ( d.inherits( TransformationImp::stype() ) )
{
@@ -128,58 +128,58 @@ TQString ObjectImpFactory::serialize( const ObjectImp& d, TQDomElement& parent,
matrixe.appendChild( elel );
};
}
- parent.appendChild( matrixe );
+ tqparent.appendChild( matrixe );
TQDomElement homothetye = doc.createElement( "homothetic" );
const char* ishomothety = trans.isHomothetic() ? "true" : "false";
homothetye.appendChild( doc.createTextNode( ishomothety ) );
- parent.appendChild( homothetye );
+ tqparent.appendChild( homothetye );
- return TQString::fromLatin1( "transformation" );
+ return TQString::tqfromLatin1( "transformation" );
}
else if( d.inherits( AbstractLineImp::stype() ) )
{
LineData l = static_cast<const AbstractLineImp&>( d ).data();
- addCoordinateElement( "a", l.a, parent, doc );
- addCoordinateElement( "b", l.b, parent, doc );
+ addCoordinateElement( "a", l.a, tqparent, doc );
+ addCoordinateElement( "b", l.b, tqparent, doc );
if( d.inherits( SegmentImp::stype() ) )
- return TQString::fromLatin1( "segment" );
+ return TQString::tqfromLatin1( "segment" );
else if( d.inherits( RayImp::stype() ) )
- return TQString::fromLatin1( "ray" );
- else return TQString::fromLatin1( "line" );
+ return TQString::tqfromLatin1( "ray" );
+ else return TQString::tqfromLatin1( "line" );
}
else if( d.inherits( PointImp::stype() ) )
{
addXYElements( static_cast<const PointImp&>( d ).coordinate(),
- parent, doc );
- return TQString::fromLatin1( "point" );
+ tqparent, doc );
+ return TQString::tqfromLatin1( "point" );
}
else if( d.inherits( TextImp::stype() ) )
{
TQString text = static_cast<const TextImp&>( d ).text();
- parent.appendChild(
+ tqparent.appendChild(
doc.createTextNode( text ) );
- return TQString::fromLatin1( "text" );
+ return TQString::tqfromLatin1( "text" );
}
else if( d.inherits( AngleImp::stype() ) )
{
- addDoubleElement( "size", static_cast<const AngleImp&>( d ).size(), parent, doc );
- return TQString::fromLatin1( "angle" );
+ addDoubleElement( "size", static_cast<const AngleImp&>( d ).size(), tqparent, doc );
+ return TQString::tqfromLatin1( "angle" );
}
else if ( d.inherits( ArcImp::stype() ) )
{
const ArcImp& a = static_cast<const ArcImp&>( d );
- addCoordinateElement( "center", a.center(), parent, doc );
- addDoubleElement( "radius", a.radius(), parent, doc );
- addDoubleElement( "startangle", a.startAngle(), parent, doc );
- addDoubleElement( "angle", a.angle(), parent, doc );
- return TQString::fromLatin1( "arc" );
+ addCoordinateElement( "center", a.center(), tqparent, doc );
+ addDoubleElement( "radius", a.radius(), tqparent, doc );
+ addDoubleElement( "startangle", a.startAngle(), tqparent, doc );
+ addDoubleElement( "angle", a.angle(), tqparent, doc );
+ return TQString::tqfromLatin1( "arc" );
}
else if( d.inherits( VectorImp::stype() ) )
{
Coordinate dir = static_cast<const VectorImp&>( d ).dir();
- addXYElements( dir, parent, doc );
- return TQString::fromLatin1( "vector" );
+ addXYElements( dir, tqparent, doc );
+ return TQString::tqfromLatin1( "vector" );
}
else if( d.inherits( LocusImp::stype() ) )
{
@@ -190,30 +190,30 @@ TQString ObjectImpFactory::serialize( const ObjectImp& d, TQDomElement& parent,
const CurveImp& curveimp = *locus.curve();
TQString type = serialize( curveimp, curve, doc );
curve.setAttribute( "type", type );
- parent.appendChild( curve );
+ tqparent.appendChild( curve );
// serialize the hierarchy..
TQDomElement hier = doc.createElement( "calculation" );
locus.hierarchy().serialize( hier, doc );
- parent.appendChild( hier );
+ tqparent.appendChild( hier );
- return TQString::fromLatin1( "locus" );
+ return TQString::tqfromLatin1( "locus" );
}
else if( d.inherits( CircleImp::stype() ) )
{
const CircleImp& c = static_cast<const CircleImp&>( d );
- addCoordinateElement( "center", c.center(), parent, doc );
- addDoubleElement( "radius", c.radius(), parent, doc );
- return TQString::fromLatin1( "circle" );
+ addCoordinateElement( "center", c.center(), tqparent, doc );
+ addDoubleElement( "radius", c.radius(), tqparent, doc );
+ return TQString::tqfromLatin1( "circle" );
}
else if( d.inherits( ConicImp::stype() ) )
{
const ConicPolarData data = static_cast<const ConicImp&>( d ).polarData();
- addCoordinateElement( "focus1", data.focus1, parent, doc );
- addDoubleElement( "pdimen", data.pdimen, parent, doc );
- addDoubleElement( "ecostheta0", data.ecostheta0, parent, doc );
- addDoubleElement( "esintheta0", data.esintheta0, parent, doc );
- return TQString::fromLatin1( "conic" );
+ addCoordinateElement( "focus1", data.focus1, tqparent, doc );
+ addDoubleElement( "pdimen", data.pdimen, tqparent, doc );
+ addDoubleElement( "ecostheta0", data.ecostheta0, tqparent, doc );
+ addDoubleElement( "esintheta0", data.esintheta0, tqparent, doc );
+ return TQString::tqfromLatin1( "conic" );
}
else if( d.inherits( CubicImp::stype() ) )
{
@@ -229,11 +229,11 @@ TQString ObjectImpFactory::serialize( const ObjectImp& d, TQDomElement& parent,
addDoubleElement( "a112", data.coeffs[7], coeffs, doc );
addDoubleElement( "a122", data.coeffs[8], coeffs, doc );
addDoubleElement( "a222", data.coeffs[9], coeffs, doc );
- parent.appendChild( coeffs );
- return TQString::fromLatin1( "cubic" );
+ tqparent.appendChild( coeffs );
+ return TQString::tqfromLatin1( "cubic" );
}
assert( false );
- return TQString::null;
+ return TQString();
}
static Coordinate readXYElements( const TQDomElement& e, bool& ok )
@@ -285,40 +285,40 @@ static double readDoubleElement( TQDomNode n, bool& ok,
}
ObjectImp* ObjectImpFactory::deserialize( const TQString& type,
- const TQDomElement& parent,
+ const TQDomElement& tqparent,
TQString& error ) const
{
#define KIG_GENERIC_PARSE_ERROR \
{ \
error = i18n( "An error was encountered at line %1 in file %2." ) \
- .arg( __LINE__ ).arg( __FILE__ ); \
+ .tqarg( __LINE__ ).tqarg( __FILE__ ); \
return 0; \
}
bool ok = true;
if ( type == "int" )
{
- int ret = parent.text().toInt( &ok );
+ int ret = tqparent.text().toInt( &ok );
if ( ! ok ) KIG_GENERIC_PARSE_ERROR;
return new IntImp( ret );
}
else if ( type == "double" )
{
- double ret = parent.text().toDouble( &ok );
+ double ret = tqparent.text().toDouble( &ok );
if ( ! ok ) KIG_GENERIC_PARSE_ERROR;
return new DoubleImp( ret );
}
else if ( type == "string" )
{
- return new StringImp( parent.text() );
+ return new StringImp( tqparent.text() );
}
else if ( type == "testresult" )
{
- return new TestResultImp( parent.text() );
+ return new TestResultImp( tqparent.text() );
}
else if ( type == "hierarchy" )
{
- ObjectHierarchy* hier = ObjectHierarchy::buildSafeObjectHierarchy( parent, error );
+ ObjectHierarchy* hier = ObjectHierarchy::buildSafeObjectHierarchy( tqparent, error );
if ( ! hier ) return 0;
HierarchyImp* imp = new HierarchyImp( *hier );
delete hier;
@@ -328,7 +328,7 @@ ObjectImp* ObjectImpFactory::deserialize( const TQString& type,
{
double data[3][3];
bool homothetic = false;
- for ( TQDomElement childe = parent.firstChild().toElement();
+ for ( TQDomElement childe = tqparent.firstChild().toElement();
! childe.isNull(); childe = childe.nextSibling().toElement() )
{
if ( childe.tagName() == "matrix" )
@@ -357,13 +357,13 @@ ObjectImp* ObjectImpFactory::deserialize( const TQString& type,
}
else if ( type == "point" )
{
- Coordinate ret = readXYElements( parent, ok );
+ Coordinate ret = readXYElements( tqparent, ok );
if ( ! ok ) KIG_GENERIC_PARSE_ERROR;
return new PointImp( ret );
}
else if ( type == "line" || type == "segment" || type == "ray" )
{
- TQDomNode n = parent.firstChild();
+ TQDomNode n = tqparent.firstChild();
Coordinate a = readCoordinateElement( n, ok, "a" );
if ( !ok ) KIG_GENERIC_PARSE_ERROR;
n = n.nextSibling();
@@ -375,13 +375,13 @@ ObjectImp* ObjectImpFactory::deserialize( const TQString& type,
}
else if( type == "angle" )
{
- double size = readDoubleElement( parent.firstChild(), ok, "size" );
+ double size = readDoubleElement( tqparent.firstChild(), ok, "size" );
if ( ! ok ) KIG_GENERIC_PARSE_ERROR;
return new AngleImp( Coordinate(), 0, size );
}
else if ( type == "arc" )
{
- TQDomNode n = parent.firstChild();
+ TQDomNode n = tqparent.firstChild();
Coordinate center = readCoordinateElement( n, ok, "center" );
if ( ! ok ) KIG_GENERIC_PARSE_ERROR;
n = n.nextSibling();
@@ -397,13 +397,13 @@ ObjectImp* ObjectImpFactory::deserialize( const TQString& type,
}
else if( type == "vector" )
{
- Coordinate dir = readXYElements( parent, ok );
+ Coordinate dir = readXYElements( tqparent, ok );
if ( ! ok ) KIG_GENERIC_PARSE_ERROR;
return new VectorImp( Coordinate(), dir );
}
else if( type == "locus" )
{
- TQDomElement curvee = parent.firstChild().toElement();
+ TQDomElement curvee = tqparent.firstChild().toElement();
if ( curvee.isNull() || curvee.tagName() != "curve" ) KIG_GENERIC_PARSE_ERROR;
TQString type = curvee.attribute( "type" );
ObjectImp* oi = deserialize( type, curvee, error );
@@ -417,7 +417,7 @@ ObjectImp* ObjectImpFactory::deserialize( const TQString& type,
}
else if( type == "circle" )
{
- TQDomNode n = parent.firstChild();
+ TQDomNode n = tqparent.firstChild();
Coordinate center = readCoordinateElement( n, ok, "center" );
if ( ! ok ) KIG_GENERIC_PARSE_ERROR;
@@ -429,7 +429,7 @@ ObjectImp* ObjectImpFactory::deserialize( const TQString& type,
}
else if( type == "conic" )
{
- TQDomNode n = parent.firstChild();
+ TQDomNode n = tqparent.firstChild();
Coordinate focus1 = readCoordinateElement( n, ok, "focus1" );
if ( ! ok ) KIG_GENERIC_PARSE_ERROR;
@@ -450,7 +450,7 @@ ObjectImp* ObjectImpFactory::deserialize( const TQString& type,
}
else if( type == "cubic" )
{
- TQDomElement coeffse = parent.firstChild().toElement();
+ TQDomElement coeffse = tqparent.firstChild().toElement();
if ( coeffse.isNull() || coeffse.tagName() != "coefficients" )
KIG_GENERIC_PARSE_ERROR;
@@ -504,7 +504,7 @@ ObjectImp* ObjectImpFactory::deserialize( const TQString& type,
"which this Kig version does not support."
"Perhaps you have compiled Kig without support "
"for this object type,"
- "or perhaps you are using an older Kig version." ).arg( type );
+ "or perhaps you are using an older Kig version." ).tqarg( type );
return 0;
}
diff --git a/kig/objects/object_imp_factory.h b/kig/objects/object_imp_factory.h
index 1ac08dde..6056f45d 100644
--- a/kig/objects/object_imp_factory.h
+++ b/kig/objects/object_imp_factory.h
@@ -27,14 +27,14 @@ class ObjectImpFactory
public:
static const ObjectImpFactory* instance();
/**
- * loads data from \p parent , and returns a new ObjectImp from the type
+ * loads data from \p tqparent , and returns a new ObjectImp from the type
* string \p type .
*/
- ObjectImp* deserialize( const TQString& type, const TQDomElement& parent, TQString& error ) const;
+ ObjectImp* deserialize( const TQString& type, const TQDomElement& tqparent, TQString& error ) const;
/**
- * adds data to \p parent , and returns a type string..
+ * adds data to \p tqparent , and returns a type string..
*/
- TQString serialize( const ObjectImp& d, TQDomElement& parent, TQDomDocument& doc ) const;
+ TQString serialize( const ObjectImp& d, TQDomElement& tqparent, TQDomDocument& doc ) const;
};
#endif
diff --git a/kig/objects/object_type.cc b/kig/objects/object_type.cc
index ea85e4f8..93634b63 100644
--- a/kig/objects/object_type.cc
+++ b/kig/objects/object_type.cc
@@ -71,9 +71,9 @@ ArgsParserObjectType::ArgsParserObjectType( const char fulltypename[],
{
}
-const ObjectImpType* ArgsParserObjectType::impRequirement( const ObjectImp* o, const Args& parents ) const
+const ObjectImpType* ArgsParserObjectType::impRequirement( const ObjectImp* o, const Args& tqparents ) const
{
- return margsparser.impRequirement( o, parents );
+ return margsparser.impRequirement( o, tqparents );
}
const ArgsParser& ArgsParserObjectType::argsParser() const
@@ -118,8 +118,8 @@ std::vector<ObjectCalcer*> ObjectType::movableParents( const ObjectTypeCalcer& )
return std::vector<ObjectCalcer*>();
}
-bool ArgsParserObjectType::isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const
+bool ArgsParserObjectType::isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const
{
- return margsparser.isDefinedOnOrThrough( o, parents );
+ return margsparser.isDefinedOnOrThrough( o, tqparents );
}
diff --git a/kig/objects/object_type.h b/kig/objects/object_type.h
index 54471e46..60b32026 100644
--- a/kig/objects/object_type.h
+++ b/kig/objects/object_type.h
@@ -45,7 +45,7 @@ public:
virtual bool inherits( int type ) const;
- virtual ObjectImp* calc( const Args& parents, const KigDocument& d ) const = 0;
+ virtual ObjectImp* calc( const Args& tqparents, const KigDocument& d ) const = 0;
virtual bool canMove( const ObjectTypeCalcer& ourobj ) const;
virtual bool isFreelyTranslatable( const ObjectTypeCalcer& ourobj ) const;
@@ -57,19 +57,19 @@ public:
const char* fullName() const;
/**
- * Supposing that \p parents would be given as parents to
+ * Supposing that \p tqparents would be given as tqparents to
* this type's calc function, this function returns the ObjectImp id
- * that \p o should at least have.. ( \p o should be part of \p parents )
+ * that \p o should at least have.. ( \p o should be part of \p tqparents )
*/
- virtual const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const = 0;
+ virtual const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const = 0;
/**
- * Supposing that \p parents would be given as parents to this type's
+ * Supposing that \p tqparents would be given as tqparents to this type's
* calc function, this function returns whether the returned
* ObjectImp will be, by construction, on \p o ( if \p o is a curve ), or
* through \p o ( if \p o is a point ).
*/
- virtual bool isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const = 0;
+ virtual bool isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const = 0;
/**
* returns the ObjectImp id of the ObjectImp's produced by this
@@ -108,7 +108,7 @@ public:
/**
* This is a convenience subclass of ObjectType that a type should
- * inherit from if its parents can be specified in an ArgsParser..
+ * inherit from if its tqparents can be specified in an ArgsParser..
*/
class ArgsParserObjectType
: public ObjectType
@@ -119,8 +119,8 @@ protected:
const struct ArgsParser::spec argsspec[],
int n );
public:
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
- bool isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
+ bool isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const;
const ArgsParser& argsParser() const;
std::vector<ObjectCalcer*> sortArgs( const std::vector<ObjectCalcer*>& args ) const;
diff --git a/kig/objects/object_type_factory.cc b/kig/objects/object_type_factory.cc
index a6d527ce..aa69f958 100644
--- a/kig/objects/object_type_factory.cc
+++ b/kig/objects/object_type_factory.cc
@@ -56,11 +56,11 @@ ObjectTypeFactory* ObjectTypeFactory::instance()
void ObjectTypeFactory::add( const ObjectType* type )
{
- assert( mmap.find( std::string( type->fullName() ) ) == mmap.end() );
+ assert( mmap.tqfind( std::string( type->fullName() ) ) == mmap.end() );
mmap[std::string( type->fullName() )] = type;
}
-const ObjectType* ObjectTypeFactory::find( const char* name ) const
+const ObjectType* ObjectTypeFactory::tqfind( const char* name ) const
{
maptype::const_iterator i = mmap.find( std::string( name ) );
if ( i == mmap.end() ) return 0;
diff --git a/kig/objects/object_type_factory.h b/kig/objects/object_type_factory.h
index c1371d67..97f4f0c3 100644
--- a/kig/objects/object_type_factory.h
+++ b/kig/objects/object_type_factory.h
@@ -34,7 +34,7 @@ class ObjectTypeFactory
public:
static ObjectTypeFactory* instance();
void add( const ObjectType* type );
- const ObjectType* find( const char* name ) const;
+ const ObjectType* tqfind( const char* name ) const;
};
#endif
diff --git a/kig/objects/other_imp.cc b/kig/objects/other_imp.cc
index 137a3e93..66da40a9 100644
--- a/kig/objects/other_imp.cc
+++ b/kig/objects/other_imp.cc
@@ -56,7 +56,7 @@ AngleImp::AngleImp( const Coordinate& pt, double start_angle_in_radials,
{
}
-bool AngleImp::contains( const Coordinate& p, int width, const KigWidget& w ) const
+bool AngleImp::tqcontains( const Coordinate& p, int width, const KigWidget& w ) const
{
double radius = 50*w.screenInfo().pixelWidth();
@@ -73,7 +73,7 @@ bool AngleImp::contains( const Coordinate& p, int width, const KigWidget& w ) co
bool AngleImp::inRect( const Rect& r, int width, const KigWidget& w ) const
{
// TODO ?
- return r.contains( mpoint, w.screenInfo().normalMiss( width ) );
+ return r.tqcontains( mpoint, w.screenInfo().normalMiss( width ) );
}
Coordinate AngleImp::attachPoint() const
@@ -179,7 +179,7 @@ void VectorImp::draw( KigPainter& p ) const
p.drawVector( mdata.a, mdata.b );
}
-bool VectorImp::contains( const Coordinate& o, int width, const KigWidget& w ) const
+bool VectorImp::tqcontains( const Coordinate& o, int width, const KigWidget& w ) const
{
return internalContainsPoint( o, w.screenInfo().normalMiss( width ) );
}
@@ -340,7 +340,7 @@ void ArcImp::draw( KigPainter& p ) const
p.drawArc( mcenter, mradius, msa, ma );
}
-bool ArcImp::contains( const Coordinate& p, int width, const KigWidget& w ) const
+bool ArcImp::tqcontains( const Coordinate& p, int width, const KigWidget& w ) const
{
return internalContainsPoint( p, w.screenInfo().normalMiss( width ) );
}
diff --git a/kig/objects/other_imp.h b/kig/objects/other_imp.h
index 8e716fa6..56e8c387 100644
--- a/kig/objects/other_imp.h
+++ b/kig/objects/other_imp.h
@@ -49,7 +49,7 @@ public:
ObjectImp* transform( const Transformation& ) const;
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& ) const;
bool inRect( const Rect& r, int width, const KigWidget& ) const;
Rect surroundingRect() const;
@@ -113,7 +113,7 @@ public:
double getParam( const Coordinate&, const KigDocument& ) const;
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& ) const;
bool inRect( const Rect& r, int width, const KigWidget& ) const;
Rect surroundingRect() const;
@@ -186,7 +186,7 @@ public:
ObjectImp* transform( const Transformation& t ) const;
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& w ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& w ) const;
bool inRect( const Rect& r, int width, const KigWidget& si ) const;
Rect surroundingRect() const;
bool valid() const;
diff --git a/kig/objects/other_type.cc b/kig/objects/other_type.cc
index 27787986..7d632524 100644
--- a/kig/objects/other_type.cc
+++ b/kig/objects/other_type.cc
@@ -103,10 +103,10 @@ bool CopyObjectType::inherits( int ) const
return false;
}
-ObjectImp* CopyObjectType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* CopyObjectType::calc( const Args& tqparents, const KigDocument& ) const
{
- assert( parents.size() == 1 );
- return parents[0]->copy();
+ assert( tqparents.size() == 1 );
+ return tqparents[0]->copy();
}
const ObjectImpType* CopyObjectType::impRequirement( const ObjectImp*, const Args& ) const
@@ -120,19 +120,19 @@ const ObjectImpType* CopyObjectType::resultId() const
return ObjectImp::stype();
}
-const ObjectImpType* LocusType::impRequirement( const ObjectImp* o, const Args& parents ) const
+const ObjectImpType* LocusType::impRequirement( const ObjectImp* o, const Args& tqparents ) const
{
- assert( parents.size() >= 2 );
- Args firsttwo( parents.begin(), parents.begin() + 2 );
- if ( o == parents[0] || o == parents[1] )
+ assert( tqparents.size() >= 2 );
+ Args firsttwo( tqparents.begin(), tqparents.begin() + 2 );
+ if ( o == tqparents[0] || o == tqparents[1] )
return margsparser.impRequirement( o, firsttwo );
else
{
- const HierarchyImp* h = dynamic_cast<const HierarchyImp*>( parents[0] );
+ const HierarchyImp* h = dynamic_cast<const HierarchyImp*>( tqparents[0] );
if ( h )
{
PointImp* p = new PointImp( Coordinate() );
- Args hargs( parents.begin()+ 2, parents.end() );
+ Args hargs( tqparents.begin()+ 2, tqparents.end() );
hargs.push_back( p );
ArgsParser hparser = h->data().argParser();
const ObjectImpType* ret = hparser.impRequirement( o, hargs );
@@ -182,7 +182,7 @@ Args CopyObjectType::sortArgs( const Args& args ) const
bool CopyObjectType::isDefinedOnOrThrough( const ObjectImp*, const Args& ) const
{
- // TODO: vragen aan parent ?
+ // TODO: vragen aan tqparent ?
// TODO: translate the above TODO ?
return false;
}
diff --git a/kig/objects/other_type.h b/kig/objects/other_type.h
index 6bbcead1..f8f24209 100644
--- a/kig/objects/other_type.h
+++ b/kig/objects/other_type.h
@@ -32,7 +32,7 @@ public:
ObjectImp* calc( const Args& args, const KigDocument& ) const;
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
bool inherits( int type ) const;
const ObjectImpType* resultId() const;
@@ -50,9 +50,9 @@ protected:
public:
static CopyObjectType* instance();
bool inherits( int type ) const;
- ObjectImp* calc( const Args& parents, const KigDocument& d ) const;
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
- bool isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& d ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
+ bool isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const;
const ObjectImpType* resultId() const;
std::vector<ObjectCalcer*> sortArgs( const std::vector<ObjectCalcer*>& os ) const;
Args sortArgs( const Args& args ) const;
diff --git a/kig/objects/point_imp.cc b/kig/objects/point_imp.cc
index 539f98b3..b2f9b1c1 100644
--- a/kig/objects/point_imp.cc
+++ b/kig/objects/point_imp.cc
@@ -42,7 +42,7 @@ void PointImp::draw( KigPainter& p ) const
p.drawFatPoint( mc );
}
-bool PointImp::contains( const Coordinate& p, int width, const KigWidget& w ) const
+bool PointImp::tqcontains( const Coordinate& p, int width, const KigWidget& w ) const
{
int twidth = width == -1 ? 5 : width;
return (p - mc).length() - twidth*w.screenInfo().pixelWidth() < 0;
@@ -51,7 +51,7 @@ bool PointImp::contains( const Coordinate& p, int width, const KigWidget& w ) co
bool PointImp::inRect( const Rect& r, int width, const KigWidget& w ) const
{
double am = w.screenInfo().normalMiss( width );
- return r.contains( mc, am );
+ return r.tqcontains( mc, am );
}
const uint PointImp::numberOfProperties() const
@@ -137,7 +137,7 @@ void PointImp::setCoordinate( const Coordinate& c )
void PointImp::fillInNextEscape( TQString& s, const KigDocument& doc ) const
{
- s = s.arg( doc.coordinateSystem().fromScreen( mc, doc ) );
+ s = s.tqarg( doc.coordinateSystem().fromScreen( mc, doc ) );
}
void PointImp::visit( ObjectImpVisitor* vtor ) const
diff --git a/kig/objects/point_imp.h b/kig/objects/point_imp.h
index dac0576c..6a2db06f 100644
--- a/kig/objects/point_imp.h
+++ b/kig/objects/point_imp.h
@@ -54,7 +54,7 @@ public:
void setCoordinate( const Coordinate& c );
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& ) const;
bool inRect( const Rect& r, int width, const KigWidget& ) const;
const uint numberOfProperties() const;
diff --git a/kig/objects/point_type.cc b/kig/objects/point_type.cc
index 2acd8479..74fc9d37 100644
--- a/kig/objects/point_type.cc
+++ b/kig/objects/point_type.cc
@@ -52,12 +52,12 @@ FixedPointType::~FixedPointType()
{
}
-ObjectImp* FixedPointType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* FixedPointType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- double a = static_cast<const DoubleImp*>( parents[0] )->data();
- double b = static_cast<const DoubleImp*>( parents[1] )->data();
+ double a = static_cast<const DoubleImp*>( tqparents[0] )->data();
+ double b = static_cast<const DoubleImp*>( tqparents[1] )->data();
return new PointImp( Coordinate( a, b ) );
}
@@ -80,14 +80,14 @@ RelativePointType::~RelativePointType()
{
}
-ObjectImp* RelativePointType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* RelativePointType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
- if ( ! parents[2]->attachPoint().valid() ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
+ if ( ! tqparents[2]->attachPoint().valid() ) return new InvalidImp;
- Coordinate reference = static_cast<const ObjectImp*>( parents[2] )->attachPoint();
- double a = static_cast<const DoubleImp*>( parents[0] )->data();
- double b = static_cast<const DoubleImp*>( parents[1] )->data();
+ Coordinate reference = static_cast<const ObjectImp*>( tqparents[2] )->attachPoint();
+ double a = static_cast<const DoubleImp*>( tqparents[0] )->data();
+ double b = static_cast<const DoubleImp*>( tqparents[1] )->data();
return new PointImp( reference + Coordinate( a, b ) );
}
@@ -109,12 +109,12 @@ const CursorPointType* CursorPointType::instance()
return &t;
}
-ObjectImp* CursorPointType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* CursorPointType::calc( const Args& tqparents, const KigDocument& ) const
{
- assert ( parents[0]->inherits( DoubleImp::stype() ) );
- assert ( parents[1]->inherits( DoubleImp::stype() ) );
- double a = static_cast<const DoubleImp*>( parents[0] )->data();
- double b = static_cast<const DoubleImp*>( parents[1] )->data();
+ assert ( tqparents[0]->inherits( DoubleImp::stype() ) );
+ assert ( tqparents[1]->inherits( DoubleImp::stype() ) );
+ double a = static_cast<const DoubleImp*>( tqparents[0] )->data();
+ double b = static_cast<const DoubleImp*>( tqparents[1] )->data();
return new BogusPointImp( Coordinate( a, b ) );
}
@@ -124,12 +124,12 @@ const ObjectImpType* CursorPointType::resultId() const
return BogusPointImp::stype();
}
-ObjectImp* ConstrainedPointType::calc( const Args& parents, const KigDocument& doc ) const
+ObjectImp* ConstrainedPointType::calc( const Args& tqparents, const KigDocument& doc ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- double param = static_cast<const DoubleImp*>( parents[0] )->data();
- const Coordinate nc = static_cast<const CurveImp*>( parents[1] )->getPoint( param, doc );
+ double param = static_cast<const DoubleImp*>( tqparents[0] )->data();
+ const Coordinate nc = static_cast<const CurveImp*>( tqparents[1] )->getPoint( param, doc );
if ( nc.valid() ) return new PointImp( nc );
else return new InvalidImp;
}
@@ -155,7 +155,7 @@ void FixedPointType::move( ObjectTypeCalcer& ourobj, const Coordinate& to,
const KigDocument& ) const
{
// fetch the old coord..;
- std::vector<ObjectCalcer*> pa = ourobj.parents();
+ std::vector<ObjectCalcer*> pa = ourobj.tqparents();
assert( margsparser.checkArgs( pa ) );
assert( dynamic_cast<ObjectConstCalcer*>( pa.front() ) );
assert( dynamic_cast<ObjectConstCalcer*>( pa.back() ) );
@@ -173,7 +173,7 @@ void RelativePointType::move( ObjectTypeCalcer& ourobj, const Coordinate& to,
// fetch the attach point..;
// this routine is tightly paired with what moveReferencePoint returns!
// right now moveReferencePoint always returns the origin
- std::vector<ObjectCalcer*> pa = ourobj.parents();
+ std::vector<ObjectCalcer*> pa = ourobj.tqparents();
assert( margsparser.checkArgs( pa ) );
assert( dynamic_cast<ObjectConstCalcer*>( pa[0] ) );
assert( dynamic_cast<ObjectConstCalcer*>( pa[1] ) );
@@ -192,7 +192,7 @@ void CursorPointType::move( ObjectTypeCalcer& ourobj, const Coordinate& to,
{
// fetch the old coord..;
- std::vector<ObjectCalcer*> pa = ourobj.parents();
+ std::vector<ObjectCalcer*> pa = ourobj.tqparents();
assert( pa.size() == 2 );
assert( dynamic_cast<ObjectConstCalcer*>( pa.front() ) );
assert( dynamic_cast<ObjectConstCalcer*>( pa.back() ) );
@@ -208,12 +208,12 @@ void ConstrainedPointType::move( ObjectTypeCalcer& ourobj, const Coordinate& to,
const KigDocument& d ) const
{
// fetch the CurveImp..
- std::vector<ObjectCalcer*> parents = ourobj.parents();
- assert( margsparser.checkArgs( parents ) );
+ std::vector<ObjectCalcer*> tqparents = ourobj.tqparents();
+ assert( margsparser.checkArgs( tqparents ) );
- assert( dynamic_cast<ObjectConstCalcer*>( parents[0] ) );
- ObjectConstCalcer* paramo = static_cast<ObjectConstCalcer*>( parents[0] );
- const CurveImp* ci = static_cast<const CurveImp*>( parents[1]->imp() );
+ assert( dynamic_cast<ObjectConstCalcer*>( tqparents[0] ) );
+ ObjectConstCalcer* paramo = static_cast<ObjectConstCalcer*>( tqparents[0] );
+ const CurveImp* ci = static_cast<const CurveImp*>( tqparents[1]->imp() );
// fetch the new param..
const double np = ci->getParam( to, d );
@@ -395,7 +395,7 @@ void FixedPointType::executeAction(
Coordinate oldc = static_cast<const PointImp*>( o.imp() )->coordinate();
KigInputDialog::getCoordinate(
i18n( "Set Coordinate" ),
- i18n( "Enter the new coordinate." ) + TQString::fromLatin1( "<br>" ) +
+ i18n( "Enter the new coordinate." ) + TQString::tqfromLatin1( "<br>" ) +
d.document().coordinateSystem().coordinateFormatNoticeMarkup(),
&w, &ok, d.document(), &oldc );
if ( ! ok ) break;
@@ -427,11 +427,11 @@ void ConstrainedPointType::executeAction(
break;
case 0:
{
- std::vector<ObjectCalcer*> parents = o.parents();
- assert( dynamic_cast<ObjectConstCalcer*>( parents[0] ) &&
- parents[0]->imp()->inherits( DoubleImp::stype() ) );
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ assert( dynamic_cast<ObjectConstCalcer*>( tqparents[0] ) &&
+ tqparents[0]->imp()->inherits( DoubleImp::stype() ) );
- ObjectConstCalcer* po = static_cast<ObjectConstCalcer*>( parents[0] );
+ ObjectConstCalcer* po = static_cast<ObjectConstCalcer*>( tqparents[0] );
double oldp = static_cast<const DoubleImp*>( po->imp() )->data();
bool ok = true;
@@ -440,7 +440,7 @@ void ConstrainedPointType::executeAction(
oldp, &w, &ok, 0, 1, 4 );
if ( ! ok ) return;
- MonitorDataObjects mon( parents );
+ MonitorDataObjects mon( tqparents );
po->setImp( new DoubleImp( newp ) );
KigCommand* kc = new KigCommand( d, i18n( "Change Parameter of Constrained Point" ) );
mon.finish( kc );
@@ -473,46 +473,46 @@ const Coordinate ConstrainedPointType::moveReferencePoint( const ObjectTypeCalce
std::vector<ObjectCalcer*> FixedPointType::movableParents( const ObjectTypeCalcer& ourobj ) const
{
- return ourobj.parents();
+ return ourobj.tqparents();
}
std::vector<ObjectCalcer*> RelativePointType::movableParents( const ObjectTypeCalcer& ourobj ) const
{
std::vector<ObjectCalcer*> ret;
- ret.push_back( ourobj.parents()[0] );
- ret.push_back( ourobj.parents()[1] );
+ ret.push_back( ourobj.tqparents()[0] );
+ ret.push_back( ourobj.tqparents()[1] );
return ret;
}
std::vector<ObjectCalcer*> ConstrainedPointType::movableParents( const ObjectTypeCalcer& ourobj ) const
{
std::vector<ObjectCalcer*> ret;
- ret.push_back( ourobj.parents()[0] );
+ ret.push_back( ourobj.tqparents()[0] );
return ret;
}
/* ----------------- Transport of measure ------------------------------ */
-ObjectImp* MeasureTransportType::calc( const Args& parents, const KigDocument& doc ) const
+ObjectImp* MeasureTransportType::calc( const Args& tqparents, const KigDocument& doc ) const
{
double measure;
- if ( parents.size() != 3 ) return new InvalidImp;
+ if ( tqparents.size() != 3 ) return new InvalidImp;
- if ( parents[0]->inherits (SegmentImp::stype()) )
+ if ( tqparents[0]->inherits (SegmentImp::stype()) )
{
- const SegmentImp* s = static_cast<const SegmentImp*>( parents[0] );
+ const SegmentImp* s = static_cast<const SegmentImp*>( tqparents[0] );
measure = s->length();
- } else if ( parents[0]->inherits (ArcImp::stype()) )
+ } else if ( tqparents[0]->inherits (ArcImp::stype()) )
{
- const ArcImp* s = static_cast<const ArcImp*>( parents[0] );
+ const ArcImp* s = static_cast<const ArcImp*>( tqparents[0] );
measure = s->radius()*s->angle();
} else return new InvalidImp;
- const Coordinate& p = static_cast<const PointImp*>( parents[2] )->coordinate();
- if ( parents[1]->inherits (LineImp::stype()) )
+ const Coordinate& p = static_cast<const PointImp*>( tqparents[2] )->coordinate();
+ if ( tqparents[1]->inherits (LineImp::stype()) )
{
- const LineImp* c = static_cast<const LineImp*>( parents[1] );
+ const LineImp* c = static_cast<const LineImp*>( tqparents[1] );
if ( !c->containsPoint( p, doc ) )
return new InvalidImp;
@@ -523,9 +523,9 @@ ObjectImp* MeasureTransportType::calc( const Args& parents, const KigDocument& d
if ( nc.valid() ) return new PointImp( nc );
else return new InvalidImp;
- } else if ( parents[1]->inherits (CircleImp::stype()) )
+ } else if ( tqparents[1]->inherits (CircleImp::stype()) )
{
- const CircleImp* c = static_cast<const CircleImp*>( parents[1] );
+ const CircleImp* c = static_cast<const CircleImp*>( tqparents[1] );
if ( !c->containsPoint( p, doc ) )
return new InvalidImp;
@@ -607,17 +607,17 @@ Args MeasureTransportType::sortArgs( const Args& args ) const
/* - transport of measure (old, for compatibility with prev. kig files) - */
-ObjectImp* MeasureTransportTypeOld::calc( const Args& parents, const KigDocument& doc ) const
+ObjectImp* MeasureTransportTypeOld::calc( const Args& tqparents, const KigDocument& doc ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- const CircleImp* c = static_cast<const CircleImp*>( parents[0] );
- const Coordinate& p = static_cast<const PointImp*>( parents[1] )->coordinate();
+ const CircleImp* c = static_cast<const CircleImp*>( tqparents[0] );
+ const Coordinate& p = static_cast<const PointImp*>( tqparents[1] )->coordinate();
if ( !c->containsPoint( p, doc ) )
return new InvalidImp;
- const SegmentImp* s = static_cast<const SegmentImp*>( parents[2] );
+ const SegmentImp* s = static_cast<const SegmentImp*>( tqparents[2] );
double param = c->getParam( p, doc );
double measure = s->length();
measure /= 2*c->radius()*M_PI;
diff --git a/kig/objects/point_type.h b/kig/objects/point_type.h
index 69a7e2e8..d1fb7674 100644
--- a/kig/objects/point_type.h
+++ b/kig/objects/point_type.h
@@ -34,7 +34,7 @@ public:
bool inherits( int type ) const;
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
bool canMove( const ObjectTypeCalcer& ourobj ) const;
bool isFreelyTranslatable( const ObjectTypeCalcer& ourobj ) const;
std::vector<ObjectCalcer*> movableParents( const ObjectTypeCalcer& ourobj ) const;
@@ -58,7 +58,7 @@ class RelativePointType
public:
static const RelativePointType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
bool canMove( const ObjectTypeCalcer& ourobj ) const;
bool isFreelyTranslatable( const ObjectTypeCalcer& ourobj ) const;
std::vector<ObjectCalcer*> movableParents( const ObjectTypeCalcer& ourobj ) const;
@@ -80,10 +80,10 @@ class CursorPointType
public:
static const CursorPointType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
- bool isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
+ bool isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const;
std::vector<ObjectCalcer*> sortArgs( const std::vector<ObjectCalcer*>& args ) const;
Args sortArgs( const Args& args ) const;
bool canMove( const ObjectTypeCalcer& ourobj ) const;
@@ -102,7 +102,7 @@ public:
bool inherits( int type ) const;
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
bool canMove( const ObjectTypeCalcer& ourobj ) const;
bool isFreelyTranslatable( const ObjectTypeCalcer& ourobj ) const;
@@ -136,10 +136,10 @@ class MeasureTransportType
public:
static const MeasureTransportType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
- bool isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
+ bool isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const;
std::vector<ObjectCalcer*> sortArgs( const std::vector<ObjectCalcer*>& args )const;
Args sortArgs( const Args& args ) const;
};
@@ -152,7 +152,7 @@ class MeasureTransportTypeOld
public:
static const MeasureTransportTypeOld* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
diff --git a/kig/objects/polygon_imp.cc b/kig/objects/polygon_imp.cc
index 08215bfb..c9c8fb11 100644
--- a/kig/objects/polygon_imp.cc
+++ b/kig/objects/polygon_imp.cc
@@ -159,12 +159,12 @@ bool PolygonImp::isInPolygon( const Coordinate& p ) const
}
#define selectpolygonwithinside 1
#ifdef selectpolygonwithinside
-bool PolygonImp::contains( const Coordinate& p, int, const KigWidget& ) const
+bool PolygonImp::tqcontains( const Coordinate& p, int, const KigWidget& ) const
{
return isInPolygon( p );
}
#else
-bool PolygonImp::contains( const Coordinate& p, int width, const KigWidget& w ) const
+bool PolygonImp::tqcontains( const Coordinate& p, int width, const KigWidget& w ) const
{
bool ret = false;
uint reduceddim = mpoints.size() - 1;
diff --git a/kig/objects/polygon_imp.h b/kig/objects/polygon_imp.h
index 9a25d516..506ca245 100644
--- a/kig/objects/polygon_imp.h
+++ b/kig/objects/polygon_imp.h
@@ -53,7 +53,7 @@ public:
ObjectImp* transform( const Transformation& ) const;
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& ) const;
bool inRect( const Rect& r, int width, const KigWidget& ) const;
bool valid() const;
Rect surroundingRect() const;
diff --git a/kig/objects/polygon_type.cc b/kig/objects/polygon_type.cc
index bca867da..55aa4cd8 100644
--- a/kig/objects/polygon_type.cc
+++ b/kig/objects/polygon_type.cc
@@ -60,13 +60,13 @@ const TriangleB3PType* TriangleB3PType::instance()
return &s;
}
-ObjectImp* TriangleB3PType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* TriangleB3PType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents, 1 ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents, 1 ) ) return new InvalidImp;
std::vector<Coordinate> points;
Coordinate centerofmass3 = Coordinate( 0, 0 );
- for ( Args::const_iterator i = parents.begin(); i != parents.end(); ++i )
+ for ( Args::const_iterator i = tqparents.begin(); i != tqparents.end(); ++i )
{
Coordinate point = static_cast<const PointImp*>( *i )->coordinate();
centerofmass3 += point;
@@ -87,46 +87,46 @@ bool TriangleB3PType::canMove( const ObjectTypeCalcer& o ) const
bool TriangleB3PType::isFreelyTranslatable( const ObjectTypeCalcer& o ) const
{
- std::vector<ObjectCalcer*> parents = o.parents();
- return parents[0]->isFreelyTranslatable() &&
- parents[1]->isFreelyTranslatable() &&
- parents[2]->isFreelyTranslatable();
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ return tqparents[0]->isFreelyTranslatable() &&
+ tqparents[1]->isFreelyTranslatable() &&
+ tqparents[2]->isFreelyTranslatable();
}
void TriangleB3PType::move( ObjectTypeCalcer& o, const Coordinate& to,
const KigDocument& d ) const
{
- std::vector<ObjectCalcer*> parents = o.parents();
- assert( margsparser.checkArgs( parents ) );
- const Coordinate a = static_cast<const PointImp*>( parents[0]->imp() )->coordinate();
- const Coordinate b = static_cast<const PointImp*>( parents[1]->imp() )->coordinate();
- const Coordinate c = static_cast<const PointImp*>( parents[2]->imp() )->coordinate();
- if ( parents[0]->canMove() )
- parents[0]->move( to, d );
- if ( parents[1]->canMove() )
- parents[1]->move( to + b - a, d );
- if ( parents[2]->canMove() )
- parents[2]->move( to + c - a, d );
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ assert( margsparser.checkArgs( tqparents ) );
+ const Coordinate a = static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate();
+ const Coordinate b = static_cast<const PointImp*>( tqparents[1]->imp() )->coordinate();
+ const Coordinate c = static_cast<const PointImp*>( tqparents[2]->imp() )->coordinate();
+ if ( tqparents[0]->canMove() )
+ tqparents[0]->move( to, d );
+ if ( tqparents[1]->canMove() )
+ tqparents[1]->move( to + b - a, d );
+ if ( tqparents[2]->canMove() )
+ tqparents[2]->move( to + c - a, d );
}
const Coordinate TriangleB3PType::moveReferencePoint( const ObjectTypeCalcer& o ) const
{
- std::vector<ObjectCalcer*> parents = o.parents();
- assert( margsparser.checkArgs( parents ) );
- return static_cast<const PointImp*>( parents[0]->imp() )->coordinate();
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ assert( margsparser.checkArgs( tqparents ) );
+ return static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate();
}
std::vector<ObjectCalcer*> TriangleB3PType::movableParents( const ObjectTypeCalcer& ourobj ) const
{
- std::vector<ObjectCalcer*> parents = ourobj.parents();
+ std::vector<ObjectCalcer*> tqparents = ourobj.tqparents();
std::set<ObjectCalcer*> ret;
- std::vector<ObjectCalcer*> tmp = parents[0]->movableParents();
+ std::vector<ObjectCalcer*> tmp = tqparents[0]->movableParents();
ret.insert( tmp.begin(), tmp.end() );
- tmp = parents[1]->movableParents();
+ tmp = tqparents[1]->movableParents();
ret.insert( tmp.begin(), tmp.end() );
- tmp = parents[2]->movableParents();
+ tmp = tqparents[2]->movableParents();
ret.insert( tmp.begin(), tmp.end() );
- ret.insert( parents.begin(), parents.end() );
+ ret.insert( tqparents.begin(), tqparents.end() );
return std::vector<ObjectCalcer*>( ret.begin(), ret.end() );
}
@@ -151,11 +151,11 @@ const PolygonBNPType* PolygonBNPType::instance()
return &s;
}
-ObjectImp* PolygonBNPType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* PolygonBNPType::calc( const Args& tqparents, const KigDocument& ) const
{
- uint count = parents.size();
+ uint count = tqparents.size();
assert (count >= 3); /* non sono ammessi poligoni con meno di tre lati */
-// if ( parents[0] != parents[count] ) return new InvalidImp;
+// if ( tqparents[0] != tqparents[count] ) return new InvalidImp;
std::vector<Coordinate> points;
uint npoints = 0;
@@ -164,8 +164,8 @@ ObjectImp* PolygonBNPType::calc( const Args& parents, const KigDocument& ) const
for ( uint i = 0; i < count; ++i )
{
npoints++;
- if ( ! parents[i]->inherits( PointImp::stype() ) ) return new InvalidImp;
- Coordinate point = static_cast<const PointImp*>( parents[i] )->coordinate();
+ if ( ! tqparents[i]->inherits( PointImp::stype() ) ) return new InvalidImp;
+ Coordinate point = static_cast<const PointImp*>( tqparents[i] )->coordinate();
centerofmassn += point;
points.push_back( point );
}
@@ -204,10 +204,10 @@ bool PolygonBNPType::canMove( const ObjectTypeCalcer& o ) const
bool PolygonBNPType::isFreelyTranslatable( const ObjectTypeCalcer& o ) const
{
- std::vector<ObjectCalcer*> parents = o.parents();
- for ( uint i = 0; i < parents.size(); ++i )
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ for ( uint i = 0; i < tqparents.size(); ++i )
{
- if ( !parents[i]->isFreelyTranslatable() ) return false;
+ if ( !tqparents[i]->isFreelyTranslatable() ) return false;
}
return true;
}
@@ -215,32 +215,32 @@ bool PolygonBNPType::isFreelyTranslatable( const ObjectTypeCalcer& o ) const
void PolygonBNPType::move( ObjectTypeCalcer& o, const Coordinate& to,
const KigDocument& d ) const
{
- std::vector<ObjectCalcer*> parents = o.parents();
- const Coordinate ref = static_cast<const PointImp*>( parents[0]->imp() )->coordinate();
- for ( uint i = 0; i < parents.size(); ++i )
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ const Coordinate ref = static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate();
+ for ( uint i = 0; i < tqparents.size(); ++i )
{
- const Coordinate a = static_cast<const PointImp*>( parents[i]->imp() )->coordinate();
- parents[i]->move( to + a - ref, d );
+ const Coordinate a = static_cast<const PointImp*>( tqparents[i]->imp() )->coordinate();
+ tqparents[i]->move( to + a - ref, d );
}
}
const Coordinate PolygonBNPType::moveReferencePoint( const ObjectTypeCalcer& o
) const
{
- std::vector<ObjectCalcer*> parents = o.parents();
- return static_cast<const PointImp*>( parents[0]->imp() )->coordinate();
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ return static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate();
}
std::vector<ObjectCalcer*> PolygonBNPType::movableParents( const ObjectTypeCalcer& ourobj ) const
{
- std::vector<ObjectCalcer*> parents = ourobj.parents();
+ std::vector<ObjectCalcer*> tqparents = ourobj.tqparents();
std::set<ObjectCalcer*> ret;
- for ( uint i = 0; i < parents.size(); ++i )
+ for ( uint i = 0; i < tqparents.size(); ++i )
{
- std::vector<ObjectCalcer*> tmp = parents[i]->movableParents();
+ std::vector<ObjectCalcer*> tmp = tqparents[i]->movableParents();
ret.insert( tmp.begin(), tmp.end() );
}
- ret.insert( parents.begin(), parents.end() );
+ ret.insert( tqparents.begin(), tqparents.end() );
return std::vector<ObjectCalcer*>( ret.begin(), ret.end() );
}
@@ -281,26 +281,26 @@ const PolygonBCVType* PolygonBCVType::instance()
return &s;
}
-ObjectImp* PolygonBCVType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* PolygonBCVType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( parents.size() < 3 || parents.size() > 4 ) return new InvalidImp;
+ if ( tqparents.size() < 3 || tqparents.size() > 4 ) return new InvalidImp;
- if ( ( ! parents[0]->inherits( PointImp::stype() ) ) ||
- ( ! parents[1]->inherits( PointImp::stype() ) ) ||
- ( ! parents[2]->inherits( IntImp::stype() ) ) )
+ if ( ( ! tqparents[0]->inherits( PointImp::stype() ) ) ||
+ ( ! tqparents[1]->inherits( PointImp::stype() ) ) ||
+ ( ! tqparents[2]->inherits( IntImp::stype() ) ) )
return new InvalidImp;
const Coordinate center =
- static_cast<const PointImp*>( parents[0] )->coordinate();
+ static_cast<const PointImp*>( tqparents[0] )->coordinate();
const Coordinate vertex =
- static_cast<const PointImp*>( parents[1] )->coordinate();
+ static_cast<const PointImp*>( tqparents[1] )->coordinate();
const int sides =
- static_cast<const IntImp*>( parents[2] )->data();
+ static_cast<const IntImp*>( tqparents[2] )->data();
int twist = 1;
- if ( parents.size() == 4 )
+ if ( tqparents.size() == 4 )
{
- if ( ! parents[3]->inherits( IntImp::stype() ) ) return new InvalidImp;
- twist = static_cast<const IntImp*>( parents[3] )->data();
+ if ( ! tqparents[3]->inherits( IntImp::stype() ) ) return new InvalidImp;
+ twist = static_cast<const IntImp*>( tqparents[3] )->data();
}
std::vector<Coordinate> vertexes;
@@ -359,43 +359,43 @@ bool PolygonBCVType::canMove( const ObjectTypeCalcer& o ) const
bool PolygonBCVType::isFreelyTranslatable( const ObjectTypeCalcer& o ) const
{
- std::vector<ObjectCalcer*> parents = o.parents();
- return parents[0]->isFreelyTranslatable() &&
- parents[1]->isFreelyTranslatable();
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ return tqparents[0]->isFreelyTranslatable() &&
+ tqparents[1]->isFreelyTranslatable();
}
void PolygonBCVType::move( ObjectTypeCalcer& o, const Coordinate& to,
const KigDocument& d ) const
{
- std::vector<ObjectCalcer*> parents = o.parents();
- // assert( margsparser.checkArgs( parents ) );
- if ( ! parents[0]->imp()->inherits( PointImp::stype() ) ||
- ! parents[1]->imp()->inherits( PointImp::stype() ) ) return;
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ // assert( margsparser.checkArgs( tqparents ) );
+ if ( ! tqparents[0]->imp()->inherits( PointImp::stype() ) ||
+ ! tqparents[1]->imp()->inherits( PointImp::stype() ) ) return;
- const Coordinate a = static_cast<const PointImp*>( parents[0]->imp() )->coordinate();
- const Coordinate b = static_cast<const PointImp*>( parents[1]->imp() )->coordinate();
- parents[0]->move( to, d );
- parents[1]->move( to + b - a, d );
+ const Coordinate a = static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate();
+ const Coordinate b = static_cast<const PointImp*>( tqparents[1]->imp() )->coordinate();
+ tqparents[0]->move( to, d );
+ tqparents[1]->move( to + b - a, d );
}
const Coordinate PolygonBCVType::moveReferencePoint( const ObjectTypeCalcer& o) const
{
- std::vector<ObjectCalcer*> parents = o.parents();
- // assert( margsparser.checkArgs( parents ) );
- if ( ! parents[0]->imp()->inherits( PointImp::stype() ) ) return Coordinate::invalidCoord();
+ std::vector<ObjectCalcer*> tqparents = o.tqparents();
+ // assert( margsparser.checkArgs( tqparents ) );
+ if ( ! tqparents[0]->imp()->inherits( PointImp::stype() ) ) return Coordinate::invalidCoord();
- return static_cast<const PointImp*>( parents[0]->imp() )->coordinate();
+ return static_cast<const PointImp*>( tqparents[0]->imp() )->coordinate();
}
std::vector<ObjectCalcer*> PolygonBCVType::movableParents( const ObjectTypeCalcer& ourobj ) const
{
- std::vector<ObjectCalcer*> parents = ourobj.parents();
+ std::vector<ObjectCalcer*> tqparents = ourobj.tqparents();
std::set<ObjectCalcer*> ret;
- std::vector<ObjectCalcer*> tmp = parents[0]->movableParents();
+ std::vector<ObjectCalcer*> tmp = tqparents[0]->movableParents();
ret.insert( tmp.begin(), tmp.end() );
- tmp = parents[1]->movableParents();
+ tmp = tqparents[1]->movableParents();
ret.insert( tmp.begin(), tmp.end() );
- ret.insert( &parents[0], &parents[1] );
+ ret.insert( &tqparents[0], &tqparents[1] );
return std::vector<ObjectCalcer*>( ret.begin(), ret.end() );
}
@@ -443,23 +443,23 @@ const PolygonLineIntersectionType* PolygonLineIntersectionType::instance()
* vertex of the polygon.
*/
-ObjectImp* PolygonLineIntersectionType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* PolygonLineIntersectionType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- const PolygonImp* polygon = static_cast<const PolygonImp*>( parents[0] );
+ const PolygonImp* polygon = static_cast<const PolygonImp*>( tqparents[0] );
const std::vector<Coordinate> ppoints = polygon->points();
- const LineData line = static_cast<const AbstractLineImp*>( parents[1] )->data();
+ const LineData line = static_cast<const AbstractLineImp*>( tqparents[1] )->data();
Coordinate intersections[2];
uint whichintersection = 0;
bool boundleft = false;
bool boundright = false;
- if ( parents[1]->inherits( SegmentImp::stype() ) )
+ if ( tqparents[1]->inherits( SegmentImp::stype() ) )
{
boundleft = boundright = true;
}
- if ( parents[1]->inherits( RayImp::stype() ) )
+ if ( tqparents[1]->inherits( RayImp::stype() ) )
{
boundleft = true;
}
@@ -562,12 +562,12 @@ const PolygonVertexType* PolygonVertexType::instance()
return &t;
}
-ObjectImp* PolygonVertexType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* PolygonVertexType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- const std::vector<Coordinate> ppoints = static_cast<const PolygonImp*>( parents[0] )->points();
- const uint i = static_cast<const IntImp*>( parents[1] )->data();
+ const std::vector<Coordinate> ppoints = static_cast<const PolygonImp*>( tqparents[0] )->points();
+ const uint i = static_cast<const IntImp*>( tqparents[1] )->data();
if ( i >= ppoints.size() ) return new InvalidImp;
@@ -605,12 +605,12 @@ const PolygonSideType* PolygonSideType::instance()
return &t;
}
-ObjectImp* PolygonSideType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* PolygonSideType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- const std::vector<Coordinate> ppoints = static_cast<const PolygonImp*>( parents[0] )->points();
- const uint i = static_cast<const IntImp*>( parents[1] )->data();
+ const std::vector<Coordinate> ppoints = static_cast<const PolygonImp*>( tqparents[0] )->points();
+ const uint i = static_cast<const IntImp*>( tqparents[1] )->data();
if ( i >= ppoints.size() ) return new InvalidImp;
@@ -650,11 +650,11 @@ const ConvexHullType* ConvexHullType::instance()
return &t;
}
-ObjectImp* ConvexHullType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConvexHullType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
- const std::vector<Coordinate> ppoints = static_cast<const PolygonImp*>( parents[0] )->points();
+ const std::vector<Coordinate> ppoints = static_cast<const PolygonImp*>( tqparents[0] )->points();
if ( ppoints.size() < 3 ) return new InvalidImp;
diff --git a/kig/objects/polygon_type.h b/kig/objects/polygon_type.h
index a49100bd..09a77da8 100644
--- a/kig/objects/polygon_type.h
+++ b/kig/objects/polygon_type.h
@@ -31,7 +31,7 @@ class TriangleB3PType
public:
static const TriangleB3PType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
bool canMove( const ObjectTypeCalcer& o ) const;
bool isFreelyTranslatable( const ObjectTypeCalcer& o ) const;
@@ -52,10 +52,10 @@ class PolygonBNPType
public:
static const PolygonBNPType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
- bool isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
+ bool isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const;
std::vector<ObjectCalcer*> sortArgs( const std::vector<ObjectCalcer*>& args ) const;
Args sortArgs( const Args& args ) const;
@@ -78,11 +78,11 @@ class PolygonBCVType
public:
static const PolygonBCVType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
- bool isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
+ bool isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const;
std::vector<ObjectCalcer*> sortArgs( const std::vector<ObjectCalcer*>& args ) const;
Args sortArgs( const Args& args ) const;
bool canMove( const ObjectTypeCalcer& o ) const;
@@ -100,7 +100,7 @@ class PolygonLineIntersectionType
~PolygonLineIntersectionType();
public:
static const PolygonLineIntersectionType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -111,7 +111,7 @@ class PolygonVertexType
~PolygonVertexType();
public:
static const PolygonVertexType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -122,7 +122,7 @@ class PolygonSideType
~PolygonSideType();
public:
static const PolygonSideType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -133,7 +133,7 @@ class ConvexHullType
~ConvexHullType();
public:
static const ConvexHullType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
#endif
diff --git a/kig/objects/special_calcers.cc b/kig/objects/special_calcers.cc
index e70bd4e9..281017b5 100644
--- a/kig/objects/special_calcers.cc
+++ b/kig/objects/special_calcers.cc
@@ -26,7 +26,7 @@ static const ArgsParser::spec argsspecMeasureTransport[] =
static ArgsParser measuretransportargsparser( argsspecMeasureTransport, 3 );
-std::vector<ObjectCalcer*> MeasureTransportCalcer::parents() const
+std::vector<ObjectCalcer*> MeasureTransportCalcer::tqparents() const
{
std::vector<ObjectCalcer*> ret;
ret.push_back( mcircle );
@@ -46,7 +46,7 @@ MeasureTransportCalcer::~MeasureTransportCalcer()
void MeasureTransportCalcer::calc( const KigDocument& )
{
- if ( ! measuretransportargsparser.checkArgs( parents() ) )
+ if ( ! measuretransportargsparser.checkArgs( tqparents() ) )
return new InvalidImp();
if ( ! isPointOnCurve( mpoint, mcircle ) )
diff --git a/kig/objects/special_calcers.h b/kig/objects/special_calcers.h
index 640587cc..812d7ee5 100644
--- a/kig/objects/special_calcers.h
+++ b/kig/objects/special_calcers.h
@@ -29,7 +29,7 @@ public:
MeasureTransportCalcer(ObjectCalcer* circle, ObjectCalcer* point, ObjectCalcer* segment );
~MeasureTransportCalcer();
- std::vector<ObjectCalcer*> parents() const;
+ std::vector<ObjectCalcer*> tqparents() const;
void calc( const KigDocument& );
const ObjectImpType* impRequirement(
ObjectCalcer* o, const std::vector<ObjectCalcer*>& os ) const;
diff --git a/kig/objects/tests_type.cc b/kig/objects/tests_type.cc
index e85c111e..a0a072bf 100644
--- a/kig/objects/tests_type.cc
+++ b/kig/objects/tests_type.cc
@@ -51,11 +51,11 @@ const AreParallelType* AreParallelType::instance()
return &t;
}
-ObjectImp* AreParallelType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* AreParallelType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
- const LineData& l1 = static_cast<const AbstractLineImp*>( parents[0] )->data();
- const LineData& l2 = static_cast<const AbstractLineImp*>( parents[1] )->data();
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
+ const LineData& l1 = static_cast<const AbstractLineImp*>( tqparents[0] )->data();
+ const LineData& l2 = static_cast<const AbstractLineImp*>( tqparents[1] )->data();
if ( l1.isParallelTo( l2 ) )
return new TestResultImp( i18n( "These lines are parallel." ) );
@@ -95,11 +95,11 @@ const AreOrthogonalType* AreOrthogonalType::instance()
return &t;
}
-ObjectImp* AreOrthogonalType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* AreOrthogonalType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
- const LineData& l1 = static_cast<const AbstractLineImp*>( parents[0] )->data();
- const LineData& l2 = static_cast<const AbstractLineImp*>( parents[1] )->data();
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
+ const LineData& l1 = static_cast<const AbstractLineImp*>( tqparents[0] )->data();
+ const LineData& l2 = static_cast<const AbstractLineImp*>( tqparents[1] )->data();
if ( l1.isOrthogonalTo( l2 ) )
return new TestResultImp( i18n( "These lines are orthogonal." ) );
@@ -141,12 +141,12 @@ const AreCollinearType* AreCollinearType::instance()
return &t;
}
-ObjectImp* AreCollinearType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* AreCollinearType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
- const Coordinate& p1 = static_cast<const PointImp*>( parents[0] )->coordinate();
- const Coordinate& p2 = static_cast<const PointImp*>( parents[1] )->coordinate();
- const Coordinate& p3 = static_cast<const PointImp*>( parents[2] )->coordinate();
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
+ const Coordinate& p1 = static_cast<const PointImp*>( tqparents[0] )->coordinate();
+ const Coordinate& p2 = static_cast<const PointImp*>( tqparents[1] )->coordinate();
+ const Coordinate& p3 = static_cast<const PointImp*>( tqparents[2] )->coordinate();
if ( areCollinear( p1, p2, p3 ) )
return new TestResultImp( i18n( "These points are collinear." ) );
@@ -184,11 +184,11 @@ const ContainsTestType* ContainsTestType::instance()
return &t;
}
-ObjectImp* ContainsTestType::calc( const Args& parents, const KigDocument& doc ) const
+ObjectImp* ContainsTestType::calc( const Args& tqparents, const KigDocument& doc ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
- const Coordinate& p = static_cast<const PointImp*>( parents[0] )->coordinate();
- const CurveImp* c = static_cast<const CurveImp*>( parents[1] );
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
+ const Coordinate& p = static_cast<const PointImp*>( tqparents[0] )->coordinate();
+ const CurveImp* c = static_cast<const CurveImp*>( tqparents[1] );
if ( c->containsPoint( p, doc ) )
return new TestResultImp( i18n( "This curve contains the point." ) );
@@ -230,11 +230,11 @@ const InPolygonTestType* InPolygonTestType::instance()
return &t;
}
-ObjectImp* InPolygonTestType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* InPolygonTestType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
- const Coordinate& p = static_cast<const PointImp*>( parents[0] )->coordinate();
- const PolygonImp* pol = static_cast<const PolygonImp*>( parents[1] );
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
+ const Coordinate& p = static_cast<const PointImp*>( tqparents[0] )->coordinate();
+ const PolygonImp* pol = static_cast<const PolygonImp*>( tqparents[1] );
if ( pol->isInPolygon( p ) )
return new TestResultImp( i18n( "This polygon contains the point." ) );
@@ -274,10 +274,10 @@ const ConvexPolygonTestType* ConvexPolygonTestType::instance()
return &t;
}
-ObjectImp* ConvexPolygonTestType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* ConvexPolygonTestType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
- const PolygonImp* pol = static_cast<const PolygonImp*>( parents[0] );
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
+ const PolygonImp* pol = static_cast<const PolygonImp*>( tqparents[0] );
if ( pol->isConvex() )
return new TestResultImp( i18n( "This polygon is convex." ) );
@@ -321,12 +321,12 @@ const SameDistanceType* SameDistanceType::instance()
return &t;
}
-ObjectImp* SameDistanceType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* SameDistanceType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
- const Coordinate& p1 = static_cast<const PointImp*>( parents[0] )->coordinate();
- const Coordinate& p2 = static_cast<const PointImp*>( parents[1] )->coordinate();
- const Coordinate& p3 = static_cast<const PointImp*>( parents[2] )->coordinate();
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
+ const Coordinate& p1 = static_cast<const PointImp*>( tqparents[0] )->coordinate();
+ const Coordinate& p2 = static_cast<const PointImp*>( tqparents[1] )->coordinate();
+ const Coordinate& p3 = static_cast<const PointImp*>( tqparents[2] )->coordinate();
if ( fabs( ( p1 - p2 ).length() - ( p1 - p3 ).length() ) < 10e-5 )
return new TestResultImp( i18n( "The two distances are the same." ) );
@@ -364,11 +364,11 @@ const VectorEqualityTestType* VectorEqualityTestType::instance()
return &t;
}
-ObjectImp* VectorEqualityTestType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* VectorEqualityTestType::calc( const Args& tqparents, const KigDocument& ) const
{
- if ( ! margsparser.checkArgs( parents ) ) return new InvalidImp;
- const Coordinate& v1 = static_cast<const VectorImp*>( parents[0] )->dir();
- const Coordinate& v2 = static_cast<const VectorImp*>( parents[1] )->dir();
+ if ( ! margsparser.checkArgs( tqparents ) ) return new InvalidImp;
+ const Coordinate& v1 = static_cast<const VectorImp*>( tqparents[0] )->dir();
+ const Coordinate& v2 = static_cast<const VectorImp*>( tqparents[1] )->dir();
if ( ( v1 - v2 ).length() < 10e-5 )
return new TestResultImp( i18n( "The two vectors are the same." ) );
diff --git a/kig/objects/tests_type.h b/kig/objects/tests_type.h
index 7498fc4f..4bc96f8c 100644
--- a/kig/objects/tests_type.h
+++ b/kig/objects/tests_type.h
@@ -27,7 +27,7 @@ class AreParallelType
~AreParallelType();
public:
static const AreParallelType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -38,7 +38,7 @@ class AreOrthogonalType
~AreOrthogonalType();
public:
static const AreOrthogonalType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -49,7 +49,7 @@ class AreCollinearType
~AreCollinearType();
public:
static const AreCollinearType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -60,7 +60,7 @@ class ContainsTestType
~ContainsTestType();
public:
static const ContainsTestType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -71,7 +71,7 @@ class InPolygonTestType
~InPolygonTestType();
public:
static const InPolygonTestType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -82,7 +82,7 @@ class ConvexPolygonTestType
~ConvexPolygonTestType();
public:
static const ConvexPolygonTestType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -93,7 +93,7 @@ class SameDistanceType
~SameDistanceType();
public:
static const SameDistanceType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
@@ -104,7 +104,7 @@ class VectorEqualityTestType
~VectorEqualityTestType();
public:
static const VectorEqualityTestType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& ) const;
const ObjectImpType* resultId() const;
};
diff --git a/kig/objects/text_imp.cc b/kig/objects/text_imp.cc
index 32591c16..e8feb7f0 100644
--- a/kig/objects/text_imp.cc
+++ b/kig/objects/text_imp.cc
@@ -51,9 +51,9 @@ void TextImp::draw( KigPainter& p ) const
p.drawTextFrame( mboundrect, mtext, mframe );
}
-bool TextImp::contains( const Coordinate& p, int, const KigWidget& ) const
+bool TextImp::tqcontains( const Coordinate& p, int, const KigWidget& ) const
{
- return mboundrect.contains( p );
+ return mboundrect.tqcontains( p );
}
bool TextImp::inRect( const Rect& r, int, const KigWidget& ) const
diff --git a/kig/objects/text_imp.h b/kig/objects/text_imp.h
index 54e33f79..54eb7647 100644
--- a/kig/objects/text_imp.h
+++ b/kig/objects/text_imp.h
@@ -30,7 +30,7 @@ class TextImp
Coordinate mloc;
bool mframe;
// with this var, we keep track of the place we drew in, for use in
- // the contains() function..
+ // the tqcontains() function..
mutable Rect mboundrect;
public:
typedef ObjectImp Parent;
@@ -44,7 +44,7 @@ public:
ObjectImp* transform( const Transformation& ) const;
void draw( KigPainter& p ) const;
- bool contains( const Coordinate& p, int width, const KigWidget& ) const;
+ bool tqcontains( const Coordinate& p, int width, const KigWidget& ) const;
bool inRect( const Rect& r, int width, const KigWidget& ) const;
bool valid() const;
Rect surroundingRect() const;
diff --git a/kig/objects/text_type.cc b/kig/objects/text_type.cc
index 214b35c2..5fc637bd 100644
--- a/kig/objects/text_type.cc
+++ b/kig/objects/text_type.cc
@@ -76,11 +76,11 @@ const ObjectImpType* TextType::impRequirement( const ObjectImp* o, const Args& a
return ObjectImp::stype();
}
-ObjectImp* TextType::calc( const Args& parents, const KigDocument& doc ) const
+ObjectImp* TextType::calc( const Args& tqparents, const KigDocument& doc ) const
{
- if( parents.size() < 3 ) return new InvalidImp;
- Args firstthree( parents.begin(), parents.begin() + 3 );
- Args varargs( parents.begin() + 3, parents.end() );
+ if( tqparents.size() < 3 ) return new InvalidImp;
+ Args firstthree( tqparents.begin(), tqparents.begin() + 3 );
+ Args varargs( tqparents.begin() + 3, tqparents.end() );
if ( ! mparser.checkArgs( firstthree ) ) return new InvalidImp;
@@ -108,9 +108,9 @@ bool TextType::isFreelyTranslatable( const ObjectTypeCalcer& ) const
void TextType::move( ObjectTypeCalcer& ourobj, const Coordinate& to,
const KigDocument& d ) const
{
- const std::vector<ObjectCalcer*> parents = ourobj.parents();
- assert( parents.size() >= 3 );
- const std::vector<ObjectCalcer*> firstthree( parents.begin(), parents.begin() + 3 );
+ const std::vector<ObjectCalcer*> tqparents = ourobj.tqparents();
+ assert( tqparents.size() >= 3 );
+ const std::vector<ObjectCalcer*> firstthree( tqparents.begin(), tqparents.begin() + 3 );
if( dynamic_cast<ObjectConstCalcer*>( firstthree[1] ) )
{
ObjectConstCalcer* c = static_cast<ObjectConstCalcer*>( firstthree[1] );
@@ -133,10 +133,10 @@ void TextType::executeAction( int i, ObjectHolder& o, ObjectTypeCalcer& c,
KigPart& doc, KigWidget&,
NormalMode& ) const
{
- std::vector<ObjectCalcer*> parents = c.parents();
- assert( parents.size() >= 3 );
+ std::vector<ObjectCalcer*> tqparents = c.tqparents();
+ assert( tqparents.size() >= 3 );
- std::vector<ObjectCalcer*> firstthree( parents.begin(), parents.begin() + 3 );
+ std::vector<ObjectCalcer*> firstthree( tqparents.begin(), tqparents.begin() + 3 );
assert( mparser.checkArgs( firstthree ) );
assert( dynamic_cast<ObjectConstCalcer*>( firstthree[0] ) );
@@ -144,11 +144,11 @@ void TextType::executeAction( int i, ObjectHolder& o, ObjectTypeCalcer& c,
if ( i == 0 )
{
- QClipboard* cb = kapp->clipboard();
+ TQClipboard* cb = kapp->tqclipboard();
// copy the text into the clipboard
const TextImp* ti = static_cast<const TextImp*>( c.imp() );
- cb->setText( ti->text(), QClipboard::Clipboard );
+ cb->setText( ti->text(), TQClipboard::Clipboard );
}
else if ( i == 1 )
{
@@ -201,10 +201,10 @@ Args TextType::sortArgs( const Args& args ) const
std::vector<ObjectCalcer*> TextType::movableParents( const ObjectTypeCalcer& ourobj ) const
{
- const std::vector<ObjectCalcer*> parents = ourobj.parents();
- assert( parents.size() >= 3 );
- std::vector<ObjectCalcer*> ret = parents[1]->movableParents();
- ret.push_back( parents[1] );
+ const std::vector<ObjectCalcer*> tqparents = ourobj.tqparents();
+ assert( tqparents.size() >= 3 );
+ std::vector<ObjectCalcer*> ret = tqparents[1]->movableParents();
+ ret.push_back( tqparents[1] );
return ret;
}
diff --git a/kig/objects/text_type.h b/kig/objects/text_type.h
index 8f97d4ea..5968e040 100644
--- a/kig/objects/text_type.h
+++ b/kig/objects/text_type.h
@@ -29,11 +29,11 @@ class TextType
public:
static const TextType* instance();
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
- bool isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
+ bool isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const;
const ObjectImpType* resultId() const;
- ObjectImp* calc( const Args& parents, const KigDocument& d ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& d ) const;
std::vector<ObjectCalcer*> sortArgs( const std::vector<ObjectCalcer*>& os ) const;
Args sortArgs( const Args& args ) const;
diff --git a/kig/pykig/pykig.py b/kig/pykig/pykig.py
index 106c8a0c..3e2a5cdf 100755
--- a/kig/pykig/pykig.py
+++ b/kig/pykig/pykig.py
@@ -457,9 +457,9 @@ class Property(PropObj):
genealogia:
Property <- PropObj <- KigDOP <- object
"""
- def __init__(self, type, parent, shown, name, internal,
+ def __init__(self, type, tqparent, shown, name, internal,
width, pointstyle, linestyle, color):
- PropObj.__init__(self, True, type, (parent,), shown, name, internal,
+ PropObj.__init__(self, True, type, (tqparent,), shown, name, internal,
width, pointstyle, linestyle, color)
# print shown
@@ -491,7 +491,7 @@ data=(\
def convstr(s):
for o, n in DICT:
- s=s.replace(o, n)
+ s=s.tqreplace(o, n)
return s
def databuild(nomeclasse, nomekig, v="val"):
diff --git a/kig/scripting/newscriptwizard.cc b/kig/scripting/newscriptwizard.cc
index de959ce2..cc3e1771 100644
--- a/kig/scripting/newscriptwizard.cc
+++ b/kig/scripting/newscriptwizard.cc
@@ -56,8 +56,8 @@ NewScriptWizard::~NewScriptWizard()
}
}
-NewScriptWizard::NewScriptWizard( TQWidget* parent, ScriptModeBase* mode )
- : NewScriptWizardBase( parent, "New Script Wizard" ),
+NewScriptWizard::NewScriptWizard( TQWidget* tqparent, ScriptModeBase* mode )
+ : NewScriptWizardBase( tqparent, "New Script Wizard" ),
mmode( mode )
{
document = KTextEditor::EditorChooser::createDocument( 0, "KTextEditor::Document" );
@@ -97,11 +97,11 @@ NewScriptWizard::NewScriptWizard( TQWidget* parent, ScriptModeBase* mode )
KPopupMenu* pm = new KPopupMenu( editor );
// creating the actions for the code editor...
KActionCollection* ac = new KActionCollection( editor );
- KAction* undoAction = KStdAction::undo( this, TQT_SLOT( slotUndo() ), ac );
- KAction* redoAction = KStdAction::redo( this, TQT_SLOT( slotRedo() ), ac );
- KAction* cutAction = KStdAction::cut( this, TQT_SLOT( slotCut() ), ac );
- KAction* copyAction = KStdAction::copy( this, TQT_SLOT( slotCopy() ), ac );
- KAction* pasteAction = KStdAction::paste( this, TQT_SLOT( slotPaste() ), ac );
+ KAction* undoAction = KStdAction::undo( TQT_TQOBJECT(this), TQT_SLOT( slotUndo() ), ac );
+ KAction* redoAction = KStdAction::redo( TQT_TQOBJECT(this), TQT_SLOT( slotRedo() ), ac );
+ KAction* cutAction = KStdAction::cut( TQT_TQOBJECT(this), TQT_SLOT( slotCut() ), ac );
+ KAction* copyAction = KStdAction::copy( TQT_TQOBJECT(this), TQT_SLOT( slotCopy() ), ac );
+ KAction* pasteAction = KStdAction::paste( TQT_TQOBJECT(this), TQT_SLOT( slotPaste() ), ac );
// ... and plugging them into the popup menu (to build it, of course :) )
undoAction->plug( pm );
redoAction->plug( pm );
@@ -159,8 +159,8 @@ void NewScriptWizard::accept()
void NewScriptWizard::slotHelpClicked()
{
- kapp->invokeHelp( TQString::fromLatin1( "scripting" ),
- TQString::fromLatin1( "kig" ) );
+ kapp->invokeHelp( TQString::tqfromLatin1( "scripting" ),
+ TQString::tqfromLatin1( "kig" ) );
}
void NewScriptWizard::setText( const TQString& text )
diff --git a/kig/scripting/newscriptwizard.h b/kig/scripting/newscriptwizard.h
index d1831b96..403236ee 100644
--- a/kig/scripting/newscriptwizard.h
+++ b/kig/scripting/newscriptwizard.h
@@ -35,9 +35,10 @@ class NewScriptWizard
: public NewScriptWizardBase
{
Q_OBJECT
+ TQ_OBJECT
ScriptModeBase* mmode;
public:
- NewScriptWizard( TQWidget* parent, ScriptModeBase* mode );
+ NewScriptWizard( TQWidget* tqparent, ScriptModeBase* mode );
~NewScriptWizard();
void back();
diff --git a/kig/scripting/newscriptwizardbase.ui b/kig/scripting/newscriptwizardbase.ui
index 30117961..b71565d0 100644
--- a/kig/scripting/newscriptwizardbase.ui
+++ b/kig/scripting/newscriptwizardbase.ui
@@ -1,10 +1,10 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>NewScriptWizardBase</class>
-<widget class="QWizard">
+<widget class="TQWizard">
<property name="name">
<cstring>NewScriptWizardBase</cstring>
</property>
- <property name="geometry">
+ <property name="tqgeometry">
<rect>
<x>0</x>
<y>0</y>
@@ -15,7 +15,7 @@
<property name="caption">
<string>New Script</string>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>mpargs</cstring>
</property>
@@ -26,7 +26,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@@ -34,13 +34,13 @@
<string>Select the argument objects ( if any )
in the Kig window and press "Next".</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>AlignCenter</set>
</property>
</widget>
</vbox>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>mpcode</cstring>
</property>
@@ -51,7 +51,7 @@ in the Kig window and press "Next".</string>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>gridLayout</cstring>
</property>
@@ -59,7 +59,7 @@ in the Kig window and press "Next".</string>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>labelFillCode</cstring>
</property>
@@ -74,7 +74,7 @@ in the Kig window and press "Next".</string>
</widget>
<customwidgets>
</customwidgets>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>ktextedit.h</includehint>
</includehints>
diff --git a/kig/scripting/python_type.cc b/kig/scripting/python_type.cc
index cc5a00ea..0b73cda4 100644
--- a/kig/scripting/python_type.cc
+++ b/kig/scripting/python_type.cc
@@ -108,12 +108,12 @@ const ObjectImpType* PythonCompileType::resultId() const
return PythonCompiledScriptImp::stype();
}
-ObjectImp* PythonCompileType::calc( const Args& parents, const KigDocument& ) const
+ObjectImp* PythonCompileType::calc( const Args& tqparents, const KigDocument& ) const
{
- assert( parents.size() == 1 );
- if ( !parents[0]->inherits( StringImp::stype() ) ) return new InvalidImp;
+ assert( tqparents.size() == 1 );
+ if ( !tqparents[0]->inherits( StringImp::stype() ) ) return new InvalidImp;
- const StringImp* si = static_cast<const StringImp*>( parents[0] );
+ const StringImp* si = static_cast<const StringImp*>( tqparents[0] );
TQString s = si->data();
CompiledPythonScript cs = PythonScripter::instance()->compile( s.latin1() );
@@ -141,20 +141,20 @@ const PythonExecuteType* PythonExecuteType::instance()
return &t;
}
-ObjectImp* PythonExecuteType::calc( const Args& parents, const KigDocument& d ) const
+ObjectImp* PythonExecuteType::calc( const Args& tqparents, const KigDocument& d ) const
{
- assert( parents.size() >= 1 );
- if( !parents[0]->inherits( PythonCompiledScriptImp::stype() ) ) return new InvalidImp;
+ assert( tqparents.size() >= 1 );
+ if( !tqparents[0]->inherits( PythonCompiledScriptImp::stype() ) ) return new InvalidImp;
- CompiledPythonScript& script = static_cast<const PythonCompiledScriptImp*>( parents[0] )->data();
+ CompiledPythonScript& script = static_cast<const PythonCompiledScriptImp*>( tqparents[0] )->data();
- Args args( parents.begin() + 1, parents.end() );
+ Args args( tqparents.begin() + 1, tqparents.end() );
return script.calc( args, d );
}
-const ObjectImpType* PythonExecuteType::impRequirement( const ObjectImp* o, const Args& parents ) const
+const ObjectImpType* PythonExecuteType::impRequirement( const ObjectImp* o, const Args& tqparents ) const
{
- if ( o == parents[0] ) return PythonCompiledScriptImp::stype();
+ if ( o == tqparents[0] ) return PythonCompiledScriptImp::stype();
else return ObjectImp::stype();
}
diff --git a/kig/scripting/python_type.h b/kig/scripting/python_type.h
index db623ab6..871cfc17 100644
--- a/kig/scripting/python_type.h
+++ b/kig/scripting/python_type.h
@@ -28,10 +28,10 @@ class PythonCompileType
public:
static const PythonCompileType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& d ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& d ) const;
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
- bool isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
+ bool isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const;
const ObjectImpType* resultId() const;
std::vector<ObjectCalcer*> sortArgs( const std::vector<ObjectCalcer*>& args ) const;
@@ -46,10 +46,10 @@ class PythonExecuteType
public:
static const PythonExecuteType* instance();
- ObjectImp* calc( const Args& parents, const KigDocument& d ) const;
+ ObjectImp* calc( const Args& tqparents, const KigDocument& d ) const;
- const ObjectImpType* impRequirement( const ObjectImp* o, const Args& parents ) const;
- bool isDefinedOnOrThrough( const ObjectImp* o, const Args& parents ) const;
+ const ObjectImpType* impRequirement( const ObjectImp* o, const Args& tqparents ) const;
+ bool isDefinedOnOrThrough( const ObjectImp* o, const Args& tqparents ) const;
const ObjectImpType* resultId() const;
std::vector<ObjectCalcer*> sortArgs( const std::vector<ObjectCalcer*>& args ) const;
diff --git a/kig/scripting/script-common.cc b/kig/scripting/script-common.cc
index 2eb2da81..1f5d8c4a 100644
--- a/kig/scripting/script-common.cc
+++ b/kig/scripting/script-common.cc
@@ -44,7 +44,7 @@ TQString ScriptType::templateCode( ScriptType::Type type, std::list<ObjectHolder
{
if ( type == Python )
{
- TQString tempcode = TQString::fromLatin1( "def calc( " );
+ TQString tempcode = TQString::tqfromLatin1( "def calc( " );
bool firstarg = true;
TQString temparg = i18n( "Note to translators: this should be a default "
"name for an argument in a Python function. The "
@@ -58,7 +58,7 @@ TQString ScriptType::templateCode( ScriptType::Type type, std::list<ObjectHolder
if ( !firstarg ) tempcode += ", ";
else firstarg = false;
TQString n = ( *i )->name();
- tempcode += n.isEmpty() ? temparg.arg( id ) : n;
+ tempcode += n.isEmpty() ? temparg.tqarg( id ) : n;
id++;
};
tempcode +=
diff --git a/kig/scripting/script_mode.cc b/kig/scripting/script_mode.cc
index adbcc857..2c6f4d80 100644
--- a/kig/scripting/script_mode.cc
+++ b/kig/scripting/script_mode.cc
@@ -45,7 +45,7 @@ void ScriptModeBase::dragRect( const TQPoint& p, KigWidget& w )
mdoc.runMode( &dm );
std::vector<ObjectHolder*> ret = dm.ret();
- KigPainter pter( w.screenInfo(), &w.stillPix, mdoc.document() );
+ KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
if ( dm.needClear() )
{
std::vector<ObjectHolder*> tmp( margs.begin(), margs.begin() );
@@ -67,7 +67,7 @@ void ScriptModeBase::leftClickedObject( ObjectHolder* o, const TQPoint&,
if ( mwawd != SelectingArgs ) return;
- KigPainter pter( w.screenInfo(), &w.stillPix, mdoc.document() );
+ KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
if ( (dup_o = std::find( margs.begin(), margs.end(), o )) != margs.end() )
{
@@ -105,7 +105,7 @@ void ScriptModeBase::mouseMoved( const std::vector<ObjectHolder*>& os,
// statusbar text
mdoc.emitStatusBarText( selectstat );
- KigPainter p( w.screenInfo(), &w.curPix, mdoc.document() );
+ KigPainter p( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
// set the text next to the arrow cursor
TQPoint point = pt;
@@ -204,7 +204,7 @@ bool ScriptCreationMode::queryFinish()
KMessageBox::detailedSorry(
mwizard, i18n( "The Python interpreter caught an error during the execution of your "
"script. Please fix the script and click the Finish button again." ),
- i18n( "The Python Interpreter generated the following error output:\n%1").arg( errtrace ) );
+ i18n( "The Python Interpreter generated the following error output:\n%1").tqarg( errtrace.data() ) );
}
else
{
@@ -246,7 +246,7 @@ void ScriptModeBase::setScriptType( ScriptType::Type type )
void ScriptModeBase::addArgs( const std::vector<ObjectHolder*>& obj, KigWidget& w )
{
- KigPainter pter( w.screenInfo(), &w.stillPix, mdoc.document() );
+ KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
std::copy( obj.begin(), obj.end(), std::inserter( margs, margs.begin() ) );
pter.drawObjects( obj, true );
@@ -275,10 +275,10 @@ ScriptEditMode::ScriptEditMode( ObjectTypeCalcer* exec_calc, KigPart& doc )
{
mwawd = EnteringCode;
- mexecargs = mexecuted->parents();
+ mexecargs = mexecuted->tqparents();
assert( mexecargs.size() >= 1 );
- mcompiledargs = mexecargs[0]->parents();
+ mcompiledargs = mexecargs[0]->tqparents();
assert( mcompiledargs.size() == 1 );
const ObjectImp* imp = static_cast<ObjectConstCalcer*>( mcompiledargs[0] )->imp();
@@ -322,7 +322,7 @@ bool ScriptEditMode::queryFinish()
KMessageBox::detailedSorry(
mpart.widget(), i18n( "The Python interpreter caught an error during the execution of your "
"script. Please fix the script." ),
- i18n( "The Python Interpreter generated the following error output:\n%1").arg( errtrace ) );
+ i18n( "The Python Interpreter generated the following error output:\n%1").tqarg( errtrace.data() ) );
}
else
{