From 731a203a18d1028cefeea2bb19aa727149e0a4c4 Mon Sep 17 00:00:00 2001 From: Maximilian Albert Date: Sat, 1 Sep 2007 23:36:14 +0000 Subject: Decent support for setting the direction of infinite VPs via the toolbar and partial fix for wrong undo behaviour (?) (bzr r3659) --- src/vanishing-point.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/vanishing-point.h') diff --git a/src/vanishing-point.h b/src/vanishing-point.h index 428bb49ad..3dde39385 100644 --- a/src/vanishing-point.h +++ b/src/vanishing-point.h @@ -55,6 +55,7 @@ public: bool operator== (VanishingPoint const &other); inline NR::Point get_pos() const { return NR::Point ((*this)[NR::X], (*this)[NR::Y]); } + inline double get_angle() const { return NR::atan2 (this->v_dir) * 180/M_PI; } // return angle of infinite direction is in degrees inline void set_pos(NR::Point const &pt) { (*this)[NR::X] = pt[NR::X]; (*this)[NR::Y] = pt[NR::Y]; } inline void set_pos(const double pt_x, const double pt_y) { (*this)[NR::X] = pt_x; @@ -120,6 +121,7 @@ public: //void grabKnot (VanishingPoint const &vp, gint x, gint y, guint32 etime); bool local_change; + bool dragging; SPDocument *document; GList *draggers; -- cgit v1.2.3