diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-01-04 02:22:38 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-01-04 02:22:38 +0000 |
commit | 98a12d05a48814bec3870b9a6d5865475cfa1c95 (patch) | |
tree | a711801e47696fb0cf162abd7330e0b5b480ba39 /kig/objects | |
parent | 421a1845137c7c396b5d03bce53237fcb149d602 (diff) | |
download | tdeedu-98a12d05a48814bec3870b9a6d5865475cfa1c95.tar.gz tdeedu-98a12d05a48814bec3870b9a6d5865475cfa1c95.zip |
Automated conversion for enhanced compatibility with TQt for Qt4 3.4.0 TP1
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeedu@1211429 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kig/objects')
32 files changed, 105 insertions, 105 deletions
diff --git a/kig/objects/bogus_imp.cc b/kig/objects/bogus_imp.cc index b7b8f41e..8cedc89f 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; } 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/centerofcurvature_type.cc b/kig/objects/centerofcurvature_type.cc index 8111410f..628ed571 100644 --- a/kig/objects/centerofcurvature_type.cc +++ b/kig/objects/centerofcurvature_type.cc @@ -66,7 +66,7 @@ ObjectImp* CocConicType::calc( const Args& args, const KigDocument& doc ) const const ConicImp* conic = static_cast<const ConicImp*>( args[0] ); const Coordinate& p = static_cast<const PointImp*>( args[1] )->coordinate(); - if ( !conic->containsPoint( p, doc ) ) + if ( !conic->tqcontainsPoint( p, doc ) ) return new InvalidImp; double x = p.x; @@ -152,7 +152,7 @@ ObjectImp* CocCubicType::calc( const Args& args, const KigDocument& doc ) const const CubicImp* cubic = static_cast<const CubicImp*>( args[0] ); const Coordinate& p = static_cast<const PointImp*>( args[1] )->coordinate(); - if ( !cubic->containsPoint( p, doc ) ) + if ( !cubic->tqcontainsPoint( p, doc ) ) return new InvalidImp; double x = p.x; @@ -234,7 +234,7 @@ ObjectImp* CocCurveType::calc( const Args& args, const KigDocument& doc ) const const CurveImp* curve = static_cast<const CurveImp*>( args[0] ); const Coordinate& p = static_cast<const PointImp*>( args[1] )->coordinate(); - if ( !curve->containsPoint( p, doc ) ) + if ( !curve->tqcontainsPoint( p, doc ) ) return new InvalidImp; diff --git a/kig/objects/circle_imp.cc b/kig/objects/circle_imp.cc index 38522c22..86e6f978 100644 --- a/kig/objects/circle_imp.cc +++ b/kig/objects/circle_imp.cc @@ -63,19 +63,19 @@ 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 ); } bool CircleImp::inRect( const Rect& r, int width, const KigWidget& w ) const { - // first we check if the rect contains at least one of the + // first we check if the rect tqcontains 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 ); 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..c06f05f8 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 ) ); } @@ -332,7 +332,7 @@ const ObjectImpType* ConicImp::type() const return ConicImp::stype(); } -bool ConicImp::containsPoint( const Coordinate& p, const KigDocument& ) const +bool ConicImp::tqcontainsPoint( const Coordinate& p, const KigDocument& ) const { const ConicPolarData d = polarData(); diff --git a/kig/objects/conic_imp.h b/kig/objects/conic_imp.h index 29068a7b..3562422f 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; @@ -116,7 +116,7 @@ public: bool equals( const ObjectImp& rhs ) const; - bool containsPoint( const Coordinate& p, const KigDocument& doc ) const; + bool tqcontainsPoint( const Coordinate& p, const KigDocument& doc ) const; bool internalContainsPoint( const Coordinate& p, double threshold ) const; }; diff --git a/kig/objects/cubic_imp.cc b/kig/objects/cubic_imp.cc index 3879c5d9..f5a86ef8 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 ) ); } @@ -363,7 +363,7 @@ const ObjectImpType* CubicImp::stype() return &t; } -bool CubicImp::containsPoint( const Coordinate& p, const KigDocument& ) const +bool CubicImp::tqcontainsPoint( const Coordinate& p, const KigDocument& ) const { return internalContainsPoint( p, test_threshold ); } @@ -431,7 +431,7 @@ TQString CubicImp::cartesianEquationString( const KigDocument& ) const ret = ret.arg( 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..ab7434a2 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; @@ -74,7 +74,7 @@ public: bool equals( const ObjectImp& rhs ) const; - bool containsPoint( const Coordinate& p, const KigDocument& doc ) const; + bool tqcontainsPoint( const Coordinate& p, const KigDocument& doc ) const; bool internalContainsPoint( const Coordinate& p, double threshold ) const; }; diff --git a/kig/objects/curve_imp.h b/kig/objects/curve_imp.h index 3a33a722..a0b130cc 100644 --- a/kig/objects/curve_imp.h +++ b/kig/objects/curve_imp.h @@ -51,12 +51,12 @@ public: virtual CurveImp* copy() const = 0; /** - * Return whether this Curve contains the given point. This is + * Return whether this Curve tqcontains the given point. This is * implemented as a numerical approximation. Implementations * can/should use the value test_threshold in common.h as a * threshold value. */ - virtual bool containsPoint( const Coordinate& p, const KigDocument& ) const = 0; + virtual bool tqcontainsPoint( const Coordinate& p, const KigDocument& ) const = 0; }; #endif diff --git a/kig/objects/intersection_types.cc b/kig/objects/intersection_types.cc index 804d498d..7305ba3d 100644 --- a/kig/objects/intersection_types.cc +++ b/kig/objects/intersection_types.cc @@ -172,8 +172,8 @@ ObjectImp* LineLineIntersectionType::calc( const Args& parents, const KigDocumen 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 ) ) + if ( static_cast<const AbstractLineImp*>( parents[0] )->tqcontainsPoint( p, d ) && + static_cast<const AbstractLineImp*>( parents[1] )->tqcontainsPoint( p, d ) ) return new PointImp( p ); else return new InvalidImp(); } diff --git a/kig/objects/line_imp.cc b/kig/objects/line_imp.cc index a49078a1..6f5b176f 100644 --- a/kig/objects/line_imp.cc +++ b/kig/objects/line_imp.cc @@ -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 ) ); } @@ -507,7 +507,7 @@ const ObjectImpType* LineImp::type() const return LineImp::stype(); } -bool SegmentImp::containsPoint( const Coordinate& p, const KigDocument& ) const +bool SegmentImp::tqcontainsPoint( const Coordinate& p, const KigDocument& ) const { return internalContainsPoint( p, test_threshold ); } @@ -517,7 +517,7 @@ bool SegmentImp::internalContainsPoint( const Coordinate& p, double threshold ) return isOnSegment( p, mdata.a, mdata.b, threshold ); } -bool RayImp::containsPoint( const Coordinate& p, const KigDocument& ) const +bool RayImp::tqcontainsPoint( const Coordinate& p, const KigDocument& ) const { return internalContainsPoint( p, test_threshold ); } @@ -527,7 +527,7 @@ bool RayImp::internalContainsPoint( const Coordinate& p, double threshold ) cons return isOnRay( p, mdata.a, mdata.b, threshold ); } -bool LineImp::containsPoint( const Coordinate& p, const KigDocument& ) const +bool LineImp::tqcontainsPoint( const Coordinate& p, const KigDocument& ) const { return internalContainsPoint( p, test_threshold ); } diff --git a/kig/objects/line_imp.h b/kig/objects/line_imp.h index b12c045d..4d2319e5 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; @@ -124,7 +124,7 @@ public: const ObjectImpType* type() const; void visit( ObjectImpVisitor* vtor ) const; - bool containsPoint( const Coordinate& p, const KigDocument& doc ) const; + bool tqcontainsPoint( const Coordinate& p, const KigDocument& doc ) const; bool internalContainsPoint( const Coordinate& p, double threshold ) 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; @@ -167,7 +167,7 @@ public: const ObjectImpType* type() const; void visit( ObjectImpVisitor* vtor ) const; - bool containsPoint( const Coordinate& p, const KigDocument& doc ) const; + bool tqcontainsPoint( const Coordinate& p, const KigDocument& doc ) const; bool internalContainsPoint( const Coordinate& p, double threshold ) 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; @@ -208,7 +208,7 @@ public: const ObjectImpType* type() const; void visit( ObjectImpVisitor* vtor ) const; - bool containsPoint( const Coordinate& p, const KigDocument& doc ) const; + bool tqcontainsPoint( const Coordinate& p, const KigDocument& doc ) const; bool internalContainsPoint( const Coordinate& p, double threshold ) const; }; diff --git a/kig/objects/locus_imp.cc b/kig/objects/locus_imp.cc index edbdc88b..a45159a7 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() ); } @@ -372,7 +372,7 @@ const ObjectImpType* LocusImp::type() const return LocusImp::stype(); } -bool LocusImp::containsPoint( const Coordinate& p, const KigDocument& doc ) const +bool LocusImp::tqcontainsPoint( const Coordinate& p, const KigDocument& doc ) const { return internalContainsPoint( p, test_threshold, doc ); } diff --git a/kig/objects/locus_imp.h b/kig/objects/locus_imp.h index 568e0e7c..19bd690f 100644 --- a/kig/objects/locus_imp.h +++ b/kig/objects/locus_imp.h @@ -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; @@ -89,7 +89,7 @@ public: bool equals( const ObjectImp& rhs ) const; - bool containsPoint( const Coordinate& p, const KigDocument& d ) const; + bool tqcontainsPoint( const Coordinate& p, const KigDocument& d ) const; bool internalContainsPoint( const Coordinate& p, double threshold, const KigDocument& doc ) const; }; diff --git a/kig/objects/object_drawer.cc b/kig/objects/object_drawer.cc index f92fabe7..89c2c976 100644 --- a/kig/objects/object_drawer.cc +++ b/kig/objects/object_drawer.cc @@ -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 diff --git a/kig/objects/object_drawer.h b/kig/objects/object_drawer.h index 6206522e..c9c962dd 100644 --- a/kig/objects/object_drawer.h +++ b/kig/objects/object_drawer.h @@ -64,11 +64,11 @@ public: */ void draw( const ObjectImp& imp, KigPainter& p, bool selected ) const; /** - * returns whether the object \p imp contains coordinate \p p . This is + * returns whether the object \p imp tqcontains coordinate \p p . This is * 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_holder.cc b/kig/objects/object_holder.cc index 70e1100b..f3516eea 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 diff --git a/kig/objects/object_holder.h b/kig/objects/object_holder.h index 0afd3892..1d96e007 100644 --- a/kig/objects/object_holder.h +++ b/kig/objects/object_holder.h @@ -101,9 +101,9 @@ public: */ void draw( KigPainter& p, bool selected ) const; /** - * Returns whether this object contains the point \p p . + * Returns whether this object tqcontains 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.h b/kig/objects/object_imp.h index eaf29328..8e12de26 100644 --- a/kig/objects/object_imp.h +++ b/kig/objects/object_imp.h @@ -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; @@ -327,7 +327,7 @@ public: virtual ObjectImp* copy() const = 0; // s is a string with at least one escape ( "%N" where N is a - // number ) somewhere. This function replaces the first escape it + // number ) somewhere. This function tqreplaces the first escape it // sees with the "value" of this imp ( using the TQString::arg // functions ). This is e.g. used by TextType to turn its variable // args into strings.. @@ -341,7 +341,7 @@ public: /** * Returns true if this ObjectImp is equal to rhs. * This function checks whether rhs is of the same ObjectImp type, - * and whether it contains the same data as this ObjectImp. + * and whether it tqcontains the same data as this ObjectImp. * \internal It is used e.g. by the KigCommand stuff to see what the * user has changed during a move.. */ diff --git a/kig/objects/object_imp_factory.cc b/kig/objects/object_imp_factory.cc index 65cd9c94..b422ccf1 100644 --- a/kig/objects/object_imp_factory.cc +++ b/kig/objects/object_imp_factory.cc @@ -84,33 +84,33 @@ TQString ObjectImpFactory::serialize( const ObjectImp& d, TQDomElement& parent, parent.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( 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( doc.createTextNode( static_cast<const StringImp&>( d ).data() ) ); - return TQString::fromLatin1( "string" ); + return TQString::tqfromLatin1( "string" ); } else if ( d.inherits( TestResultImp::stype() ) ) { parent.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" ); + return TQString::tqfromLatin1( "hierarchy" ); } else if ( d.inherits( TransformationImp::stype() ) ) { @@ -135,7 +135,7 @@ TQString ObjectImpFactory::serialize( const ObjectImp& d, TQDomElement& parent, homothetye.appendChild( doc.createTextNode( ishomothety ) ); parent.appendChild( homothetye ); - return TQString::fromLatin1( "transformation" ); + return TQString::tqfromLatin1( "transformation" ); } else if( d.inherits( AbstractLineImp::stype() ) ) { @@ -143,28 +143,28 @@ TQString ObjectImpFactory::serialize( const ObjectImp& d, TQDomElement& parent, addCoordinateElement( "a", l.a, parent, doc ); addCoordinateElement( "b", l.b, parent, 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" ); + return TQString::tqfromLatin1( "point" ); } else if( d.inherits( TextImp::stype() ) ) { TQString text = static_cast<const TextImp&>( d ).text(); parent.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" ); + return TQString::tqfromLatin1( "angle" ); } else if ( d.inherits( ArcImp::stype() ) ) { @@ -173,13 +173,13 @@ TQString ObjectImpFactory::serialize( const ObjectImp& d, TQDomElement& parent, addDoubleElement( "radius", a.radius(), parent, doc ); addDoubleElement( "startangle", a.startAngle(), parent, doc ); addDoubleElement( "angle", a.angle(), parent, doc ); - return TQString::fromLatin1( "arc" ); + 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" ); + return TQString::tqfromLatin1( "vector" ); } else if( d.inherits( LocusImp::stype() ) ) { @@ -197,14 +197,14 @@ TQString ObjectImpFactory::serialize( const ObjectImp& d, TQDomElement& parent, locus.hierarchy().serialize( hier, doc ); parent.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" ); + return TQString::tqfromLatin1( "circle" ); } else if( d.inherits( ConicImp::stype() ) ) { @@ -213,7 +213,7 @@ TQString ObjectImpFactory::serialize( const ObjectImp& d, TQDomElement& parent, addDoubleElement( "pdimen", data.pdimen, parent, doc ); addDoubleElement( "ecostheta0", data.ecostheta0, parent, doc ); addDoubleElement( "esintheta0", data.esintheta0, parent, doc ); - return TQString::fromLatin1( "conic" ); + return TQString::tqfromLatin1( "conic" ); } else if( d.inherits( CubicImp::stype() ) ) { @@ -230,7 +230,7 @@ TQString ObjectImpFactory::serialize( const ObjectImp& d, TQDomElement& parent, addDoubleElement( "a122", data.coeffs[8], coeffs, doc ); addDoubleElement( "a222", data.coeffs[9], coeffs, doc ); parent.appendChild( coeffs ); - return TQString::fromLatin1( "cubic" ); + return TQString::tqfromLatin1( "cubic" ); } assert( false ); return TQString::null; diff --git a/kig/objects/other_imp.cc b/kig/objects/other_imp.cc index 137a3e93..f094b487 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 ) ); } @@ -614,7 +614,7 @@ const ObjectImpType* ArcImp::type() const return ArcImp::stype(); } -bool ArcImp::containsPoint( const Coordinate& p, const KigDocument& ) const +bool ArcImp::tqcontainsPoint( const Coordinate& p, const KigDocument& ) const { return internalContainsPoint( p, test_threshold ); } @@ -694,7 +694,7 @@ double VectorImp::getParam( const Coordinate& p, const KigDocument& ) const return ( ( pt - mdata.a ).length() ) / ( dir().length() ); } -bool VectorImp::containsPoint( const Coordinate& p, const KigDocument& ) const +bool VectorImp::tqcontainsPoint( const Coordinate& p, const KigDocument& ) const { return internalContainsPoint( p, test_threshold ); } diff --git a/kig/objects/other_imp.h b/kig/objects/other_imp.h index 8e716fa6..204d63a1 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; @@ -153,7 +153,7 @@ public: bool equals( const ObjectImp& rhs ) const; - bool containsPoint( const Coordinate& p, const KigDocument& doc ) const; + bool tqcontainsPoint( const Coordinate& p, const KigDocument& doc ) const; bool internalContainsPoint( const Coordinate& p, double threshold ) 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; @@ -236,7 +236,7 @@ public: bool equals( const ObjectImp& rhs ) const; - bool containsPoint( const Coordinate& p, const KigDocument& doc ) const; + bool tqcontainsPoint( const Coordinate& p, const KigDocument& doc ) const; bool internalContainsPoint( const Coordinate& p, double threshold ) const; }; diff --git a/kig/objects/point_imp.cc b/kig/objects/point_imp.cc index 539f98b3..57f8fe4a 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 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..c443f099 100644 --- a/kig/objects/point_type.cc +++ b/kig/objects/point_type.cc @@ -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; @@ -514,7 +514,7 @@ ObjectImp* MeasureTransportType::calc( const Args& parents, const KigDocument& d { const LineImp* c = static_cast<const LineImp*>( parents[1] ); - if ( !c->containsPoint( p, doc ) ) + if ( !c->tqcontainsPoint( p, doc ) ) return new InvalidImp; const LineData line = c->data(); @@ -526,7 +526,7 @@ ObjectImp* MeasureTransportType::calc( const Args& parents, const KigDocument& d } else if ( parents[1]->inherits (CircleImp::stype()) ) { const CircleImp* c = static_cast<const CircleImp*>( parents[1] ); - if ( !c->containsPoint( p, doc ) ) + if ( !c->tqcontainsPoint( p, doc ) ) return new InvalidImp; double param = c->getParam( p, doc ); @@ -614,7 +614,7 @@ ObjectImp* MeasureTransportTypeOld::calc( const Args& parents, const KigDocument const CircleImp* c = static_cast<const CircleImp*>( parents[0] ); const Coordinate& p = static_cast<const PointImp*>( parents[1] )->coordinate(); - if ( !c->containsPoint( p, doc ) ) + if ( !c->tqcontainsPoint( p, doc ) ) return new InvalidImp; const SegmentImp* s = static_cast<const SegmentImp*>( parents[2] ); 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/tangent_type.cc b/kig/objects/tangent_type.cc index 12ebda23..15b78458 100644 --- a/kig/objects/tangent_type.cc +++ b/kig/objects/tangent_type.cc @@ -68,7 +68,7 @@ ObjectImp* TangentConicType::calc( const Args& args, const KigDocument& doc ) co const ConicImp* c = static_cast<const ConicImp*>( args[0] ); const Coordinate& p = static_cast<const PointImp*>( args[1] )->coordinate(); - if ( !c->containsPoint( p, doc ) ) + if ( !c->tqcontainsPoint( p, doc ) ) return new InvalidImp; bool ok; @@ -118,7 +118,7 @@ ObjectImp* TangentArcType::calc( const Args& args, const KigDocument& doc ) cons const ArcImp* arc = static_cast<const ArcImp*>( args[0] ); const Coordinate& p = static_cast<const PointImp*>( args[1] )->coordinate(); - if ( !arc->containsPoint( p, doc ) ) + if ( !arc->tqcontainsPoint( p, doc ) ) return new InvalidImp; Coordinate c = arc->center(); @@ -173,7 +173,7 @@ ObjectImp* TangentCubicType::calc( const Args& args, const KigDocument& doc ) co const CubicImp* cubic = static_cast<const CubicImp*>( args[0] ); const Coordinate& p = static_cast<const PointImp*>( args[1] )->coordinate(); - if ( !cubic->containsPoint( p, doc ) ) + if ( !cubic->tqcontainsPoint( p, doc ) ) return new InvalidImp; double x = p.x; @@ -243,7 +243,7 @@ ObjectImp* TangentCurveType::calc( const Args& args, const KigDocument& doc ) co const CurveImp* curve = static_cast<const CurveImp*>( args[0] ); const Coordinate& p = static_cast<const PointImp*>( args[1] )->coordinate(); - if ( !curve->containsPoint( p, doc ) ) + if ( !curve->tqcontainsPoint( p, doc ) ) return new InvalidImp; const double t = curve->getParam( p, doc ); diff --git a/kig/objects/tests_type.cc b/kig/objects/tests_type.cc index e85c111e..a2c65808 100644 --- a/kig/objects/tests_type.cc +++ b/kig/objects/tests_type.cc @@ -159,7 +159,7 @@ const ObjectImpType* AreCollinearType::resultId() const return TestResultImp::stype(); } -static const ArgsParser::spec containsTestArgsSpec[] = +static const ArgsParser::spec tqcontainsTestArgsSpec[] = { { PointImp::stype(), I18N_NOOP( "Check whether this point is on a curve" ), I18N_NOOP( "Select the point you want to test..." ), false }, @@ -170,7 +170,7 @@ static const ArgsParser::spec containsTestArgsSpec[] = KIG_INSTANTIATE_OBJECT_TYPE_INSTANCE( ContainsTestType ) ContainsTestType::ContainsTestType() - : ArgsParserObjectType( "ContainsTest", containsTestArgsSpec, 2 ) + : ArgsParserObjectType( "ContainsTest", tqcontainsTestArgsSpec, 2 ) { } @@ -190,8 +190,8 @@ ObjectImp* ContainsTestType::calc( const Args& parents, const KigDocument& doc ) const Coordinate& p = static_cast<const PointImp*>( parents[0] )->coordinate(); const CurveImp* c = static_cast<const CurveImp*>( parents[1] ); - if ( c->containsPoint( p, doc ) ) - return new TestResultImp( i18n( "This curve contains the point." ) ); + if ( c->tqcontainsPoint( p, doc ) ) + return new TestResultImp( i18n( "This curve tqcontains the point." ) ); else return new TestResultImp( i18n( "This curve does not contain the point." ) ); } @@ -237,7 +237,7 @@ ObjectImp* InPolygonTestType::calc( const Args& parents, const KigDocument& ) co const PolygonImp* pol = static_cast<const PolygonImp*>( parents[1] ); if ( pol->isInPolygon( p ) ) - return new TestResultImp( i18n( "This polygon contains the point." ) ); + return new TestResultImp( i18n( "This polygon tqcontains the point." ) ); else return new TestResultImp( i18n( "This polygon does not contain the point." ) ); } 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; |