Code

Split SPCanvasItem and SPCanvasGroup to individual .h files. Removed forward header.
[inkscape.git] / src / live_effects / lpe-copy_rotate.h
1 #ifndef INKSCAPE_LPE_COPY_ROTATE_H
2 #define INKSCAPE_LPE_COPY_ROTATE_H
4 /** \file
5  * LPE <copy_rotate> implementation, see lpe-copy_rotate.cpp.
6  */
8 /*
9  * Authors:
10  *   Johan Engelen
11  *
12  * Copyright (C) Johan Engelen 2007 <j.b.c.engelen@utwente.nl>
13  *
14  * Released under GNU GPL, read the file 'COPYING' for more information
15  */
17 #include "live_effects/effect.h"
18 #include "live_effects/parameter/point.h"
20 namespace Inkscape {
21 namespace LivePathEffect {
23 namespace CR {
24   // we need a separate namespace to avoid clashes with LPEPerpBisector
25   class KnotHolderEntityStartingAngle;
26   class KnotHolderEntityRotationAngle;
27 }
29 class LPECopyRotate : public Effect {
30 public:
31     LPECopyRotate(LivePathEffectObject *lpeobject);
32     virtual ~LPECopyRotate();
34     virtual void doOnApply (SPLPEItem *lpeitem);
36     virtual Geom::Piecewise<Geom::D2<Geom::SBasis> > doEffect_pwd2 (Geom::Piecewise<Geom::D2<Geom::SBasis> > const & pwd2_in);
38     /* the knotholder entity classes must be declared friends */
39     friend class CR::KnotHolderEntityStartingAngle;
40     friend class CR::KnotHolderEntityRotationAngle;
42 protected:
43     virtual void addCanvasIndicators(SPLPEItem *lpeitem, std::vector<Geom::PathVector> &hp_vec);
45 private:
46     ScalarParam starting_angle;
47     ScalarParam rotation_angle;
48     ScalarParam num_copies;
50     PointParam origin;
52     Geom::Point A;
53     Geom::Point B;
54     Geom::Point dir;
56     Geom::Point start_pos;
57     Geom::Point rot_pos;
58     double dist_angle_handle;
60     LPECopyRotate(const LPECopyRotate&);
61     LPECopyRotate& operator=(const LPECopyRotate&);
62 };
64 } //namespace LivePathEffect
65 } //namespace Inkscape
67 #endif
69 /*
70   Local Variables:
71   mode:c++
72   c-file-style:"stroustrup"
73   c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
74   indent-tabs-mode:nil
75   fill-column:99
76   End:
77 */
78 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4 :