correctly (?) indicate muted status of audio regions
[ardour.git] / gtk2_ardour / time_axis_view_item.h
index dd6ebe01209134a0a4e5c309f9676ce5df807aa6..60ff519216224e9732414871af4908a8b971d4eb 100644 (file)
@@ -21,6 +21,7 @@
 #define __gtk_ardour_time_axis_view_item_h__
 
 #include <string>
+#include <gdk/gdk.h>
 #include <gdkmm/color.h>
 #include <pangomm/fontdescription.h>
 #include "pbd/signals.h"
@@ -73,6 +74,8 @@ class TimeAxisViewItem : public Selectable, public PBD::ScopedConnectionList
        void set_y (double);
        void set_color (Gdk::Color const &);
 
+        uint32_t get_fill_color () const;
+
        ArdourCanvas::Item* get_canvas_frame();
        ArdourCanvas::Group* get_canvas_group();
        ArdourCanvas::Item* get_name_highlight();
@@ -156,16 +159,17 @@ class TimeAxisViewItem : public Selectable, public PBD::ScopedConnectionList
 
        TimeAxisViewItem (const TimeAxisViewItem&);
 
-       void init (const std::string&, double, Gdk::Color const &, framepos_t, framepos_t, Visibility, bool, bool);
+        void init (ArdourCanvas::Group*, double, Gdk::Color const &, framepos_t, framepos_t, Visibility, bool, bool);
+
+        virtual bool canvas_group_event (GdkEvent*);
 
        virtual void compute_colors (Gdk::Color const &);
        virtual void set_colors();
        virtual void set_frame_color();
+       virtual void set_frame_gradient ();
        void set_trim_handle_colors();
 
        virtual void reset_width_dependent_items (double);
-       void reset_name_width (double);
-       void update_name_text_visibility ();
 
        static gint idle_remove_this_item(TimeAxisViewItem*, void*);
 
@@ -243,6 +247,8 @@ class TimeAxisViewItem : public Selectable, public PBD::ScopedConnectionList
        ArdourCanvas::Rectangle* frame_handle_start; ///< `frame' (fade) handle for the start of the item, or 0
        ArdourCanvas::Rectangle* frame_handle_end; ///< `frame' (fade) handle for the end of the item, or 0
 
+        bool frame_handle_crossing (GdkEvent*, ArdourCanvas::Rectangle*);
+
        double _height;
        Visibility visibility;
        bool _recregion;
@@ -250,8 +256,11 @@ class TimeAxisViewItem : public Selectable, public PBD::ScopedConnectionList
        bool _dragging;
 
 private:
+        double _width;
 
        void parameter_changed (std::string);
+        void manage_name_highlight ();
+        void manage_name_text ();
 
 }; /* class TimeAxisViewItem */