Code

Filters. Custom predefined filters update and new ABC filters.
[inkscape.git] / src / snapped-curve.h
index 28908c42ffddd103b344bcd6db666a588e8d2303..595f844110f16404758ce4bd67836f31d086d874 100644 (file)
@@ -1,55 +1,54 @@
-#ifndef SEEN_SNAPPEDCURVE_H\r
-#define SEEN_SNAPPEDCURVE_H\r
-\r
-/**\r
- *    \file src/snapped-curve.h\r
- *    \brief SnappedCurve class.\r
- *\r
- *    Authors:\r
- *      Diederik van Lierop <mail@diedenrezi.nl>\r
- *\r
- *    Released under GNU GPL, read the file 'COPYING' for more information.\r
- */\r
-\r
-#include <vector>\r
-#include <list>\r
-#include "libnr/nr-coord.h"\r
-#include "libnr/nr-point.h"\r
-#include <libnr/nr-point-fns.h>\r
-#include "snapped-point.h"\r
-#include <2geom/forward.h>\r
-\r
-namespace Inkscape\r
-{\r
-\r
-/// Class describing the result of an attempt to snap to a curve.\r
-class SnappedCurve : public SnappedPoint\r
-{\r
-public:\r
-    SnappedCurve();\r
-    SnappedCurve(NR::Point const &snapped_point, NR::Coord const &snapped_distance, NR::Coord const &snapped_tolerance, bool const &always_snap, Geom::Curve const *curve);\r
-    ~SnappedCurve();\r
-    Inkscape::SnappedPoint intersect(SnappedCurve const &curve, NR::Point const &p) const; //intersect with another SnappedCurve\r
-    \r
-private:\r
-    Geom::Curve const *_curve;\r
-};\r
-\r
-}\r
-\r
-bool getClosestCurve(std::list<Inkscape::SnappedCurve> const &list, Inkscape::SnappedCurve &result);\r
-bool getClosestIntersectionCS(std::list<Inkscape::SnappedCurve> const &list, NR::Point const &p, Inkscape::SnappedPoint &result);\r
-\r
-\r
-#endif /* !SEEN_SNAPPEDCURVE_H */\r
-\r
-/*\r
-  Local Variables:\r
-  mode:c++\r
-  c-file-style:"stroustrup"\r
-  c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))\r
-  indent-tabs-mode:nil\r
-  fill-column:99\r
-  End:\r
-*/\r
-// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4 :\r
+#ifndef SEEN_SNAPPEDCURVE_H
+#define SEEN_SNAPPEDCURVE_H
+
+/**
+ *    \file src/snapped-curve.h
+ *    \brief SnappedCurve class.
+ *
+ *    Authors:
+ *      Diederik van Lierop <mail@diedenrezi.nl>
+ *
+ *    Released under GNU GPL, read the file 'COPYING' for more information.
+ */
+
+#include <vector>
+#include <list>
+#include "snapped-point.h"
+#include <2geom/forward.h>
+
+namespace Inkscape
+{
+
+/// Class describing the result of an attempt to snap to a curve.
+class SnappedCurve : public SnappedPoint
+{
+public:
+    SnappedCurve();
+    SnappedCurve(Geom::Point const &snapped_point, int num_path, int num_segm, Geom::Coord const &snapped_distance, Geom::Coord const &snapped_tolerance, bool const &always_snap, bool const &fully_constrained, Geom::Curve const *curve, SnapSourceType source, long source_num, SnapTargetType target, Geom::OptRect target_bbox);
+    ~SnappedCurve();
+    Inkscape::SnappedPoint intersect(SnappedCurve const &curve, Geom::Point const &p, Geom::Matrix dt2doc) const; //intersect with another SnappedCurve
+
+private:
+    Geom::Curve const *_curve;
+    int _num_path;  // Unique id of the path to which this segment belongs too
+    int _num_segm;  // Sequence number of this segment in the path
+};
+
+}
+
+bool getClosestCurve(std::list<Inkscape::SnappedCurve> const &list, Inkscape::SnappedCurve &result);
+bool getClosestIntersectionCS(std::list<Inkscape::SnappedCurve> const &list, Geom::Point const &p, Inkscape::SnappedPoint &result, Geom::Matrix dt2doc);
+
+
+#endif /* !SEEN_SNAPPEDCURVE_H */
+
+/*
+  Local Variables:
+  mode:c++
+  c-file-style:"stroustrup"
+  c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
+  indent-tabs-mode:nil
+  fill-column:99
+  End:
+*/
+// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4 :