Obsolete Members for QLineF

The following members of class QLineF are obsolete. They are provided to keep old source code working. We strongly advise against using them in new code.

Public Types

(obsolete) enum IntersectType { NoIntersection, UnboundedIntersection, BoundedIntersection }

Public Functions

(obsolete) qreal angle(const QLineF &line) const
(obsolete) QLineF::IntersectType intersect(const QLineF &line, QPointF *intersectionPoint) const

Member Type Documentation

enum QLineF::IntersectType

This enum is obsolete. It is provided to keep old source code working. We strongly advise against using it in new code.

Use QLineF::IntersectionType instead.

ConstantValueDescription
QLineF::NoIntersection0Lines do not intersect.
QLineF::UnboundedIntersection2Lines intersect, but not within the range defined by their lengths.
QLineF::BoundedIntersection1Lnes intersect within the range defined by their lengths.

Member Function Documentation

qreal QLineF::angle(const QLineF &line) const

This function is obsolete. It is provided to keep old source code working. We strongly advise against using it in new code.

Returns the angle (in degrees) between this line and the given line, taking the direction of the lines into account. If the lines do not intersect within their range, it is the intersection point of the extended lines that serves as origin (see QLineF::UnboundedIntersection).

When the lines are parallel, this function returns 0 if they have the same direction; otherwise it returns 180.

See also intersect().

QLineF::IntersectType QLineF::intersect(const QLineF &line, QPointF *intersectionPoint) const

This function is obsolete. It is provided to keep old source code working. We strongly advise against using it in new code.

Use intersects() instead

Returns a value indicating whether or not this line intersects with the given line.

The actual intersection point is extracted to intersectionPoint (if the pointer is valid). If the lines are parallel, the intersection point is undefined.

© 2023 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.