diff options
Diffstat (limited to 'lib/kofficecore/KoRect.cpp')
-rw-r--r-- | lib/kofficecore/KoRect.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/lib/kofficecore/KoRect.cpp b/lib/kofficecore/KoRect.cpp index b93a577d..78a63992 100644 --- a/lib/kofficecore/KoRect.cpp +++ b/lib/kofficecore/KoRect.cpp @@ -166,15 +166,15 @@ KoRect &KoRect::operator&=(const KoRect &rhs) { return *this; } -bool KoRect::contains(const KoPoint &p) const { +bool KoRect::tqcontains(const KoPoint &p) const { return (p.x() >= m_tl.x() && p.x() <= m_br.x() && p.y() >= m_tl.y() && p.y() <= m_br.y()); } -bool KoRect::contains(const double &x, const double &y) const { +bool KoRect::tqcontains(const double &x, const double &y) const { return (x >= m_tl.x() && x <= m_br.x() && y >= m_tl.y() && y <= m_br.y()); } -bool KoRect::contains(const KoRect &r) const { +bool KoRect::tqcontains(const KoRect &r) const { return (r.left() >= m_tl.x() && r.right() <= m_br.x() && r.top() >= m_tl.y() && r.bottom() <= m_br.y()); } @@ -188,8 +188,8 @@ KoRect KoRect::intersect(const KoRect &r) const { } bool KoRect::intersects(const KoRect &r) const { - return ( QMAX(m_tl.x(), r.left()) <= QMIN(m_br.x(), r.right()) && - QMAX(m_tl.y(), r.top()) <= QMIN(m_br.y(), r.bottom()) ); + return ( TQMAX(m_tl.x(), r.left()) <= TQMIN(m_br.x(), r.right()) && + TQMAX(m_tl.y(), r.top()) <= TQMIN(m_br.y(), r.bottom()) ); } KoRect operator|(const KoRect &lhs, const KoRect &rhs) { @@ -226,7 +226,7 @@ bool operator!=(const KoRect &lhs, const KoRect &rhs) { lhs.bottomRight()!=rhs.bottomRight() ); } -KoRect KoRect::transform(const QWMatrix &m) const +KoRect KoRect::transform(const TQWMatrix &m) const { KoRect result; if(m.m12() == 0.0F && m.m21() == 0.0F) @@ -248,10 +248,10 @@ KoRect KoRect::transform(const QWMatrix &m) const for(int i = 1; i < 4; i++) { - result.setLeft(QMIN(p[i].x(), result.left())); - result.setTop(QMIN(p[i].y(), result.top())); - result.setRight(QMAX(p[i].x(), result.right())); - result.setBottom(QMAX(p[i].y(), result.bottom())); + result.setLeft(TQMIN(p[i].x(), result.left())); + result.setTop(TQMIN(p[i].y(), result.top())); + result.setRight(TQMAX(p[i].x(), result.right())); + result.setBottom(TQMAX(p[i].y(), result.bottom())); } } return result; @@ -262,13 +262,13 @@ KoRect KoRect::translate(double dx, double dy) const return KoRect(left() + dx, top() + dy, width(), height()); } -QRect KoRect::toQRect() const +TQRect KoRect::toTQRect() const { - return QRect( qRound( left() ), qRound( top() ), qRound( width() ), qRound( height() ) ); + return TQRect( tqRound( left() ), tqRound( top() ), tqRound( width() ), tqRound( height() ) ); } //static -KoRect KoRect::fromQRect( const QRect &rect ) +KoRect KoRect::fromTQRect( const TQRect &rect ) { return KoRect( rect.left(), rect.top(), rect.width(), rect.height() ); } |