Code

optimized includes
[inkscape.git] / src / snapped-point.h
1 #ifndef SEEN_SNAPPEDPOINT_H
2 #define SEEN_SNAPPEDPOINT_H
4 /**
5  *    \file src/snapped-point.h
6  *    \brief SnappedPoint class.
7  *
8  *    Authors:
9  *      Mathieu Dimanche <mdimanche@free.fr>
10  *
11  *    Released under GNU GPL, read the file 'COPYING' for more information.
12  */
14 #include <vector>
15 #include "libnr/nr-coord.h"
16 #include "libnr/nr-point.h"
18 namespace Inkscape
19 {
21 class HighlightGroup;
23 /// Class describing the result of an attempt to snap.
24 class SnappedPoint
25 {
26 public:
27     SnappedPoint() {}
28     SnappedPoint(::NR::Point p, ::NR::Coord d);
29     ~SnappedPoint();
31     void addHighlightGroup(HighlightGroup *group);
32     void addHighlightGroups(std::vector<HighlightGroup*> *groups);
34     ::NR::Coord getDistance() const;
35     NR::Point getPoint() const;
36     std::vector<HighlightGroup*> getHighlightGroups() const;
38 private:
39     ::NR::Coord _distance;
40     ::NR::Point _point;
41     std::vector<HighlightGroup*> _hightlight_groups;
42 };
44 }
45 #endif /* !SEEN_SNAPPEDPOINT_H */
47 /*
48   Local Variables:
49   mode:c++
50   c-file-style:"stroustrup"
51   c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
52   indent-tabs-mode:nil
53   fill-column:99
54   End:
55 */
56 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4 :