do the right thing when TrackingText::offset is changed
authorPaul Davis <paul@linuxaudiosystems.com>
Tue, 25 Nov 2014 18:44:26 +0000 (20:44 +0200)
committerPaul Davis <paul@linuxaudiosystems.com>
Wed, 29 Apr 2015 11:26:18 +0000 (07:26 -0400)
libs/canvas/canvas/item.h
libs/canvas/tracking_text.cc

index 60fadabfbda00837d5dec4c42f3c3705a9f8a24c..228a03f6bfc05be5c4cef66ac94596a6b09c22e1 100644 (file)
@@ -86,6 +86,10 @@ public:
         */
        virtual void add_items_at_point (Duple /*point*/, std::vector<Item const *>& items) const;
 
+        /** Return true if the item covers @param point, false otherwise.
+         * 
+         * The point is in window coordinates 
+         */
         virtual bool covers (Duple const &) const;
 
        /** Update _bounding_box and _bounding_box_dirty */
index ea44102f8f2bf6f6d046a70d6897d0e47b20687f..c5f754068cb8fcfca36e75edee671ebadd933f57 100644 (file)
@@ -128,17 +128,23 @@ TrackingText::show_and_track (bool tx, bool ty)
 void
 TrackingText::set_x_offset (double o)
 {
+        begin_change ();
        offset.x = o;
+        end_change ();
 }
 
 void
 TrackingText::set_y_offset (double o)
 {
+        begin_change ();
        offset.y = o;
+        end_change ();
 }
 
 void
 TrackingText::set_offset (Duple const & d)
 {
+        begin_change ();
        offset = d;
+        end_change ();
 }