1 #ifndef LIBR2C2_TRACKATTACHMENT_H_
2 #define LIBR2C2_TRACKATTACHMENT_H_
6 #include "trackoffsetiter.h"
10 class TrackAttachment: public Object, public sigc::trackable
13 TrackOffsetIter track;
15 TrackAttachment(Layout &);
17 virtual ~TrackAttachment();
19 const TrackOffsetIter &get_track_iter() const { return track; }
20 Track *get_track() const { return track.track(); }
21 unsigned get_entry() const { return track.entry(); }
22 float get_offset() const { return track.offset(); }
23 float get_offset_from_endpoint(unsigned) const;
25 void attach_to(const TrackOffsetIter &);
26 void attach_to_closest(float);
27 float find_offset(const TrackIter &, const Vector &);
30 virtual Track *get_parent() const { return track.track(); }
33 void object_removed(Object &);