summaryrefslogtreecommitdiffstats
path: root/src/snapped-line.h
diff options
context:
space:
mode:
authorDiederik van Lierop <mail@diedenrezi.nl>2008-08-11 04:53:15 +0000
committerdvlierop2 <dvlierop2@users.sourceforge.net>2008-08-11 04:53:15 +0000
commitb1597d6f47f64eef7d17b7b614056edd64692130 (patch)
treeb0f4bbc9d67f2afe50125afe915ec1062c0d6b98 /src/snapped-line.h
parentpatch from bug 169004 (diff)
downloadinkscape-b1597d6f47f64eef7d17b7b614056edd64692130.tar.gz
inkscape-b1597d6f47f64eef7d17b7b614056edd64692130.zip
Move all of the snapper code to 2geom
(bzr r6606)
Diffstat (limited to 'src/snapped-line.h')
-rw-r--r--src/snapped-line.h18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/snapped-line.h b/src/snapped-line.h
index 4713d9626..ea18baefc 100644
--- a/src/snapped-line.h
+++ b/src/snapped-line.h
@@ -26,13 +26,13 @@ class SnappedLineSegment : public SnappedPoint
{
public:
SnappedLineSegment();
- SnappedLineSegment(NR::Point const &snapped_point, NR::Coord const &snapped_distance, NR::Coord const &snapped_tolerance, bool const &always_snap, NR::Point const &start_point_of_line, NR::Point const &end_point_of_line);
+ SnappedLineSegment(Geom::Point const &snapped_point, Geom::Coord const &snapped_distance, Geom::Coord const &snapped_tolerance, bool const &always_snap, Geom::Point const &start_point_of_line, Geom::Point const &end_point_of_line);
~SnappedLineSegment();
Inkscape::SnappedPoint intersect(SnappedLineSegment const &line) const; //intersect with another SnappedLineSegment
private:
- NR::Point _start_point_of_line;
- NR::Point _end_point_of_line;
+ Geom::Point _start_point_of_line;
+ Geom::Point _end_point_of_line;
};
@@ -41,18 +41,18 @@ class SnappedLine : public SnappedPoint
{
public:
SnappedLine();
- SnappedLine(NR::Point const &snapped_point, NR::Coord const &snapped_distance, NR::Coord const &snapped_tolerance, bool const &always_snap, NR::Point const &normal_to_line, NR::Point const &point_on_line);
+ SnappedLine(Geom::Point const &snapped_point, Geom::Coord const &snapped_distance, Geom::Coord const &snapped_tolerance, bool const &always_snap, Geom::Point const &normal_to_line, Geom::Point const &point_on_line);
~SnappedLine();
Inkscape::SnappedPoint intersect(SnappedLine const &line) const; //intersect with another SnappedLine
// This line is described by this equation:
// a*x + b*y = c <-> nx*px + ny+py = c <-> n.p = c
- NR::Point getNormal() const {return _normal_to_line;} // n = (nx, ny)
- NR::Point getPointOnLine() const {return _point_on_line;} // p = (px, py)
- NR::Coord getConstTerm() const {return dot(_normal_to_line, _point_on_line);} // c = n.p = nx*px + ny*py;
+ Geom::Point getNormal() const {return _normal_to_line;} // n = (nx, ny)
+ Geom::Point getPointOnLine() const {return _point_on_line;} // p = (px, py)
+ Geom::Coord getConstTerm() const {return dot(_normal_to_line, _point_on_line);} // c = n.p = nx*px + ny*py;
private:
- NR::Point _normal_to_line;
- NR::Point _point_on_line;
+ Geom::Point _normal_to_line;
+ Geom::Point _point_on_line;
};
}