X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=src%2Flive_effects%2Flpe-tangent_to_curve.h;h=8d9622c672cf95d888c8685fddf14ec6f081491a;hb=e9c4a66f3db12ac811f42b73493c1c88460f0de3;hp=d8049c176d7ae193770cd1edca90746fabcd37d3;hpb=bce2f84f17e5ee51d8222dc076ad013a68e58a7a;p=inkscape.git diff --git a/src/live_effects/lpe-tangent_to_curve.h b/src/live_effects/lpe-tangent_to_curve.h index d8049c176..8d9622c67 100644 --- a/src/live_effects/lpe-tangent_to_curve.h +++ b/src/live_effects/lpe-tangent_to_curve.h @@ -23,6 +23,13 @@ namespace Inkscape { namespace LivePathEffect { +namespace TtC { + // we need a separate namespace to avoid clashes with LPEPerpBisector + class KnotHolderEntityLeftEnd; + class KnotHolderEntityRightEnd; + class KnotHolderEntityAttachPt; +} + class LPETangentToCurve : public Effect { public: LPETangentToCurve(LivePathEffectObject *lpeobject); @@ -31,16 +38,26 @@ public: virtual Geom::Piecewise > doEffect_pwd2 (Geom::Piecewise > const & pwd2_in); - /* the knotholder functions must be declared friends */ - friend NR::Point attach_pt_get(SPItem *item); - friend void attach_pt_set(SPItem *item, NR::Point const &p, NR::Point const &origin, guint state); + virtual LPEPathFlashType pathFlashType() { return PERMANENT_FLASH; } + + /* the knotholder entity classes must be declared friends */ + friend class TtC::KnotHolderEntityLeftEnd; + friend class TtC::KnotHolderEntityRightEnd; + friend class TtC::KnotHolderEntityAttachPt; private: + ScalarParam angle; + ScalarParam t_attach; + ScalarParam length_left; + ScalarParam length_right; - Geom::Point ptA; + Geom::Point ptA; // point of attachment to the curve Geom::Point derivA; + Geom::Point C; // left end of tangent + Geom::Point D; // right end of tangent + LPETangentToCurve(const LPETangentToCurve&); LPETangentToCurve& operator=(const LPETangentToCurve&); };