Ardour  9.0-pre0-582-g084a23a80d
TimeAxisViewItem Class Reference

#include <time_axis_view_item.h>

Inheritance diagram for TimeAxisViewItem:
[legend]

Public Types

enum  Visibility {
  ShowFrame = 0x1 , ShowNameHighlight = 0x2 , ShowNameText = 0x4 , ShowHandles = 0x8 ,
  HideFrameLeft = 0x10 , HideFrameRight = 0x20 , HideFrameTB = 0x40 , FullWidthNameHighlight = 0x80
}
 

Public Member Functions

virtual ~TimeAxisViewItem ()
 
virtual bool set_position (Temporal::timepos_t const &, void *, double *delta=0)
 
Temporal::timepos_t get_position () const
 
virtual bool set_duration (Temporal::timecnt_t const &, void *)
 
Temporal::timecnt_t get_duration () const
 
virtual void set_max_duration (Temporal::timecnt_t const &, void *)
 
Temporal::timecnt_t get_max_duration () const
 
virtual void set_min_duration (Temporal::timecnt_t const &, void *)
 
Temporal::timecnt_t get_min_duration () const
 
virtual void set_position_locked (bool, void *)
 
bool get_position_locked () const
 
void set_max_duration_active (bool, void *)
 
bool get_max_duration_active () const
 
void set_min_duration_active (bool, void *)
 
bool get_min_duration_active () const
 
void set_item_name (std::string, void *)
 
virtual std::string get_item_name () const
 
virtual void set_selected (bool yn)
 
void set_sensitive (bool yn)
 
bool sensitive () const
 
TimeAxisViewget_time_axis_view () const
 
void set_name_text (const std::string &)
 
virtual void set_height (double h)
 
virtual double height () const
 
void set_y (double)
 
void set_color (uint32_t)
 
void set_name_text_color ()
 
virtual void set_frame_color ()
 
virtual uint32_t get_fill_color () const
 
ArdourCanvas::Itemget_canvas_frame ()
 
ArdourCanvas::Itemget_canvas_group () const
 
ArdourCanvas::Itemget_name_highlight ()
 
virtual void set_samples_per_pixel (double)
 
double get_samples_per_pixel () const
 
virtual void drag_start ()
 
virtual void drag_end ()
 
bool dragging () const
 
virtual void visual_layer_on_top ()
 
virtual void raise ()
 
virtual void raise_to_top ()
 
virtual void lower ()
 
virtual void lower_to_bottom ()
 
bool name_active () const
 
virtual void update_visibility ()
 
- Public Member Functions inherited from Selectable
 Selectable ()
 
virtual ~Selectable ()
 
virtual bool selected () const
 
- Public Member Functions inherited from PBD::ScopedConnectionList
 ScopedConnectionList ()
 
 ScopedConnectionList (const ScopedConnectionList &)=delete
 
ScopedConnectionListoperator= (const ScopedConnectionList &)=delete
 
virtual ~ScopedConnectionList ()
 
void add_connection (const UnscopedConnection &c)
 
void drop_connections ()
 

Static Public Member Functions

static void set_constant_heights ()
 

Public Attributes

sigc::signal< void, std::string, void * > ItemRemoved
 

Static Public Attributes

static Pango::FontDescription NAME_FONT
 
static const double NAME_X_OFFSET
 
static const double GRAB_HANDLE_TOP
 
static const double GRAB_HANDLE_WIDTH
 
static int NAME_HEIGHT
 
static double NAME_Y_OFFSET
 
static double NAME_HIGHLIGHT_SIZE
 
static double NAME_HIGHLIGHT_THRESH
 

Protected Member Functions

 TimeAxisViewItem (const std::string &, ArdourCanvas::Item &, TimeAxisView &, double, uint32_t fill_color, Temporal::timepos_t const &, Temporal::timecnt_t const &, bool recording=false, bool automation=false, Visibility v=Visibility(0))
 
 TimeAxisViewItem (const TimeAxisViewItem &)
 
void init (ArdourCanvas::Item *, double, uint32_t, Temporal::timepos_t const &, Temporal::timecnt_t const &, Visibility, bool, bool)
 
virtual bool canvas_group_event (GdkEvent *)
 
virtual void set_colors ()
 
virtual void set_frame_gradient ()
 
void set_trim_handle_colors ()
 
virtual void reset_width_dependent_items (double)
 
bool frame_handle_crossing (GdkEvent *, ArdourCanvas::Rectangle *)
 
void manage_name_text ()
 

Static Protected Member Functions

static gint idle_remove_this_item (TimeAxisViewItem *, void *)
 

Protected Attributes

TimeAxisViewtrackview
 
bool position_locked
 
Temporal::timepos_t time_position
 
Temporal::timecnt_t item_duration
 
Temporal::timecnt_t max_item_duration
 
Temporal::timecnt_t min_item_duration
 
bool max_duration_active
 
bool min_duration_active
 
double samples_per_pixel
 
bool _sensitive
 
std::string item_name
 
bool name_connected
 
uint32_t fill_color
 
uint32_t last_item_width
 
int name_text_width
 
bool wide_enough_for_name
 
bool high_enough_for_name
 
ArdourCanvas::Containergroup
 
ArdourCanvas::Rectangleframe
 
ArdourCanvas::Rectangleselection_frame
 
ArdourCanvas::Textname_text
 
ArdourCanvas::Rectanglename_highlight
 
ArdourCanvas::Rectangleframe_handle_start
 ‘frame’ (fade) handle for the start of the item, or 0 More...
 
ArdourCanvas::Rectangleframe_handle_end
 ‘frame’ (fade) handle for the end of the item, or 0 More...
 
double _height
 
Visibility visibility
 
std::string fill_color_name
 
bool _recregion
 
bool _automation
 true if this is an automation region view More...
 
bool _dragging
 
double _width
 
- Protected Attributes inherited from Selectable
bool _selected
 

Private Member Functions

void parameter_changed (std::string)
 
void manage_name_highlight ()
 

Detailed Description

Base class for items that may appear upon a TimeAxisView.

Definition at line 52 of file time_axis_view_item.h.

Member Enumeration Documentation

◆ Visibility

Enumerator
ShowFrame 
ShowNameHighlight 
ShowNameText 
ShowHandles 
HideFrameLeft 
HideFrameRight 
HideFrameTB 
FullWidthNameHighlight 

Definition at line 133 of file time_axis_view_item.h.

Constructor & Destructor Documentation

◆ ~TimeAxisViewItem()

virtual TimeAxisViewItem::~TimeAxisViewItem ( )
virtual

◆ TimeAxisViewItem() [1/2]

TimeAxisViewItem::TimeAxisViewItem ( const std::string &  ,
ArdourCanvas::Item ,
TimeAxisView ,
double  ,
uint32_t  fill_color,
Temporal::timepos_t const &  ,
Temporal::timecnt_t const &  ,
bool  recording = false,
bool  automation = false,
Visibility  v = Visibility(0) 
)
protected

◆ TimeAxisViewItem() [2/2]

TimeAxisViewItem::TimeAxisViewItem ( const TimeAxisViewItem )
protected

Member Function Documentation

◆ canvas_group_event()

virtual bool TimeAxisViewItem::canvas_group_event ( GdkEvent )
protectedvirtual

◆ drag_end()

virtual void TimeAxisViewItem::drag_end ( )
virtual

Reimplemented in AudioRegionView.

◆ drag_start()

virtual void TimeAxisViewItem::drag_start ( )
virtual

Reimplemented in AudioRegionView.

◆ dragging()

bool TimeAxisViewItem::dragging ( ) const
inline

Definition at line 97 of file time_axis_view_item.h.

◆ frame_handle_crossing()

bool TimeAxisViewItem::frame_handle_crossing ( GdkEvent ,
ArdourCanvas::Rectangle  
)
protected

◆ get_canvas_frame()

ArdourCanvas::Item* TimeAxisViewItem::get_canvas_frame ( )

◆ get_canvas_group()

ArdourCanvas::Item* TimeAxisViewItem::get_canvas_group ( ) const

◆ get_duration()

Temporal::timecnt_t TimeAxisViewItem::get_duration ( ) const

◆ get_fill_color()

virtual uint32_t TimeAxisViewItem::get_fill_color ( ) const
virtual

◆ get_item_name()

virtual std::string TimeAxisViewItem::get_item_name ( ) const
virtual

◆ get_max_duration()

Temporal::timecnt_t TimeAxisViewItem::get_max_duration ( ) const

◆ get_max_duration_active()

bool TimeAxisViewItem::get_max_duration_active ( ) const

◆ get_min_duration()

Temporal::timecnt_t TimeAxisViewItem::get_min_duration ( ) const

◆ get_min_duration_active()

bool TimeAxisViewItem::get_min_duration_active ( ) const

◆ get_name_highlight()

ArdourCanvas::Item* TimeAxisViewItem::get_name_highlight ( )

◆ get_position()

Temporal::timepos_t TimeAxisViewItem::get_position ( ) const

◆ get_position_locked()

bool TimeAxisViewItem::get_position_locked ( ) const

◆ get_samples_per_pixel()

double TimeAxisViewItem::get_samples_per_pixel ( ) const

◆ get_time_axis_view()

TimeAxisView& TimeAxisViewItem::get_time_axis_view ( ) const

◆ height()

virtual double TimeAxisViewItem::height ( ) const
inlinevirtual

Reimplemented in MidiRegionView.

Definition at line 79 of file time_axis_view_item.h.

◆ idle_remove_this_item()

static gint TimeAxisViewItem::idle_remove_this_item ( TimeAxisViewItem ,
void *   
)
staticprotected

◆ init()

void TimeAxisViewItem::init ( ArdourCanvas::Item ,
double  ,
uint32_t  ,
Temporal::timepos_t const &  ,
Temporal::timecnt_t const &  ,
Visibility  ,
bool  ,
bool   
)
protected

◆ lower()

virtual void TimeAxisViewItem::lower ( )
inlinevirtual

Definition at line 102 of file time_axis_view_item.h.

◆ lower_to_bottom()

virtual void TimeAxisViewItem::lower_to_bottom ( )
inlinevirtual

Reimplemented in RegionView.

Definition at line 103 of file time_axis_view_item.h.

◆ manage_name_highlight()

void TimeAxisViewItem::manage_name_highlight ( )
private

◆ manage_name_text()

void TimeAxisViewItem::manage_name_text ( )
protected

◆ name_active()

bool TimeAxisViewItem::name_active ( ) const
inline
Returns
true if the name area should respond to events

Definition at line 106 of file time_axis_view_item.h.

◆ parameter_changed()

void TimeAxisViewItem::parameter_changed ( std::string  )
private

◆ raise()

virtual void TimeAxisViewItem::raise ( )
inlinevirtual

Definition at line 100 of file time_axis_view_item.h.

◆ raise_to_top()

virtual void TimeAxisViewItem::raise_to_top ( )
inlinevirtual

Reimplemented in RegionView.

Definition at line 101 of file time_axis_view_item.h.

◆ reset_width_dependent_items()

virtual void TimeAxisViewItem::reset_width_dependent_items ( double  )
protectedvirtual

◆ sensitive()

bool TimeAxisViewItem::sensitive ( ) const
inline

Definition at line 75 of file time_axis_view_item.h.

◆ set_color()

void TimeAxisViewItem::set_color ( uint32_t  )

◆ set_colors()

virtual void TimeAxisViewItem::set_colors ( )
protectedvirtual

Reimplemented in RegionView, and AudioRegionView.

◆ set_constant_heights()

static void TimeAxisViewItem::set_constant_heights ( )
static

◆ set_duration()

virtual bool TimeAxisViewItem::set_duration ( Temporal::timecnt_t const &  ,
void *   
)
virtual

Reimplemented in RegionView.

◆ set_frame_color()

virtual void TimeAxisViewItem::set_frame_color ( )
virtual

Reimplemented in AudioRegionView.

◆ set_frame_gradient()

virtual void TimeAxisViewItem::set_frame_gradient ( )
protectedvirtual

◆ set_height()

virtual void TimeAxisViewItem::set_height ( double  h)
virtual

◆ set_item_name()

void TimeAxisViewItem::set_item_name ( std::string  ,
void *   
)

◆ set_max_duration()

virtual void TimeAxisViewItem::set_max_duration ( Temporal::timecnt_t const &  ,
void *   
)
virtual

◆ set_max_duration_active()

void TimeAxisViewItem::set_max_duration_active ( bool  ,
void *   
)

◆ set_min_duration()

virtual void TimeAxisViewItem::set_min_duration ( Temporal::timecnt_t const &  ,
void *   
)
virtual

◆ set_min_duration_active()

void TimeAxisViewItem::set_min_duration_active ( bool  ,
void *   
)

◆ set_name_text()

void TimeAxisViewItem::set_name_text ( const std::string &  )

◆ set_name_text_color()

void TimeAxisViewItem::set_name_text_color ( )

◆ set_position()

virtual bool TimeAxisViewItem::set_position ( Temporal::timepos_t const &  ,
void *  ,
double *  delta = 0 
)
virtual

Reimplemented in AutomationRegionView, and RegionView.

◆ set_position_locked()

virtual void TimeAxisViewItem::set_position_locked ( bool  ,
void *   
)
virtual

◆ set_samples_per_pixel()

virtual void TimeAxisViewItem::set_samples_per_pixel ( double  )
virtual

Reimplemented in RegionView, and AudioRegionView.

◆ set_selected()

virtual void TimeAxisViewItem::set_selected ( bool  yn)
virtual

Reimplemented from Selectable.

Reimplemented in RegionView, MidiRegionView, and AutomationRegionView.

◆ set_sensitive()

void TimeAxisViewItem::set_sensitive ( bool  yn)
inline

Definition at line 74 of file time_axis_view_item.h.

◆ set_trim_handle_colors()

void TimeAxisViewItem::set_trim_handle_colors ( )
protected

◆ set_y()

void TimeAxisViewItem::set_y ( double  )

◆ update_visibility()

virtual void TimeAxisViewItem::update_visibility ( )
inlinevirtual

Reimplemented in RegionView.

Definition at line 144 of file time_axis_view_item.h.

◆ visual_layer_on_top()

virtual void TimeAxisViewItem::visual_layer_on_top ( )
inlinevirtual

Reimplemented in RegionView.

Definition at line 99 of file time_axis_view_item.h.

Member Data Documentation

◆ _automation

bool TimeAxisViewItem::_automation
protected

true if this is an automation region view

Definition at line 228 of file time_axis_view_item.h.

◆ _dragging

bool TimeAxisViewItem::_dragging
protected

Definition at line 229 of file time_axis_view_item.h.

◆ _height

double TimeAxisViewItem::_height
protected

Definition at line 224 of file time_axis_view_item.h.

◆ _recregion

bool TimeAxisViewItem::_recregion
protected

Definition at line 227 of file time_axis_view_item.h.

◆ _sensitive

bool TimeAxisViewItem::_sensitive
protected

should the item respond to events

Definition at line 193 of file time_axis_view_item.h.

◆ _width

double TimeAxisViewItem::_width
protected

Definition at line 230 of file time_axis_view_item.h.

◆ fill_color

uint32_t TimeAxisViewItem::fill_color
protected

Definition at line 204 of file time_axis_view_item.h.

◆ fill_color_name

std::string TimeAxisViewItem::fill_color_name
protected

Definition at line 226 of file time_axis_view_item.h.

◆ frame

ArdourCanvas::Rectangle* TimeAxisViewItem::frame
protected

Definition at line 213 of file time_axis_view_item.h.

◆ frame_handle_end

ArdourCanvas::Rectangle* TimeAxisViewItem::frame_handle_end
protected

‘frame’ (fade) handle for the end of the item, or 0

Definition at line 220 of file time_axis_view_item.h.

◆ frame_handle_start

ArdourCanvas::Rectangle* TimeAxisViewItem::frame_handle_start
protected

‘frame’ (fade) handle for the start of the item, or 0

Definition at line 219 of file time_axis_view_item.h.

◆ GRAB_HANDLE_TOP

const double TimeAxisViewItem::GRAB_HANDLE_TOP
static

Definition at line 112 of file time_axis_view_item.h.

◆ GRAB_HANDLE_WIDTH

const double TimeAxisViewItem::GRAB_HANDLE_WIDTH
static

Definition at line 113 of file time_axis_view_item.h.

◆ group

ArdourCanvas::Container* TimeAxisViewItem::group
protected

Definition at line 211 of file time_axis_view_item.h.

◆ high_enough_for_name

bool TimeAxisViewItem::high_enough_for_name
protected

Definition at line 209 of file time_axis_view_item.h.

◆ item_duration

Temporal::timecnt_t TimeAxisViewItem::item_duration
protected

duration of this item upon the timeline

Definition at line 175 of file time_axis_view_item.h.

◆ item_name

std::string TimeAxisViewItem::item_name
protected

The unique item name of this Item. Each item upon a time axis must have a unique id.

Definition at line 199 of file time_axis_view_item.h.

◆ ItemRemoved

sigc::signal<void,std::string,void*> TimeAxisViewItem::ItemRemoved

Emitted when this Group has been removed. This is different to the CatchDeletion signal in that this signal is emitted during the deletion of this Time Axis, and not during the destructor, this allows us to capture the source of the deletion event

Definition at line 131 of file time_axis_view_item.h.

◆ last_item_width

uint32_t TimeAxisViewItem::last_item_width
protected

Definition at line 206 of file time_axis_view_item.h.

◆ max_duration_active

bool TimeAxisViewItem::max_duration_active
protected

indicates whether the max duration constraint is active

Definition at line 184 of file time_axis_view_item.h.

◆ max_item_duration

Temporal::timecnt_t TimeAxisViewItem::max_item_duration
protected

maximum duration that this item can have

Definition at line 178 of file time_axis_view_item.h.

◆ min_duration_active

bool TimeAxisViewItem::min_duration_active
protected

indicates whether the min duration constraint is active

Definition at line 187 of file time_axis_view_item.h.

◆ min_item_duration

Temporal::timecnt_t TimeAxisViewItem::min_item_duration
protected

minimum duration that this item can have

Definition at line 181 of file time_axis_view_item.h.

◆ name_connected

bool TimeAxisViewItem::name_connected
protected

true if the name should respond to events

Definition at line 202 of file time_axis_view_item.h.

◆ NAME_FONT

Pango::FontDescription TimeAxisViewItem::NAME_FONT
static

Definition at line 109 of file time_axis_view_item.h.

◆ NAME_HEIGHT

int TimeAxisViewItem::NAME_HEIGHT
static

Definition at line 118 of file time_axis_view_item.h.

◆ name_highlight

ArdourCanvas::Rectangle* TimeAxisViewItem::name_highlight
protected

Definition at line 216 of file time_axis_view_item.h.

◆ NAME_HIGHLIGHT_SIZE

double TimeAxisViewItem::NAME_HIGHLIGHT_SIZE
static

Definition at line 120 of file time_axis_view_item.h.

◆ NAME_HIGHLIGHT_THRESH

double TimeAxisViewItem::NAME_HIGHLIGHT_THRESH
static

Definition at line 121 of file time_axis_view_item.h.

◆ name_text

ArdourCanvas::Text* TimeAxisViewItem::name_text
protected

Definition at line 215 of file time_axis_view_item.h.

◆ name_text_width

int TimeAxisViewItem::name_text_width
protected

Definition at line 207 of file time_axis_view_item.h.

◆ NAME_X_OFFSET

const double TimeAxisViewItem::NAME_X_OFFSET
static

Definition at line 111 of file time_axis_view_item.h.

◆ NAME_Y_OFFSET

double TimeAxisViewItem::NAME_Y_OFFSET
static

Definition at line 119 of file time_axis_view_item.h.

◆ position_locked

bool TimeAxisViewItem::position_locked
protected

indicates whether this item is locked to its current position

Definition at line 169 of file time_axis_view_item.h.

◆ samples_per_pixel

double TimeAxisViewItem::samples_per_pixel
protected

samples per canvas pixel

Definition at line 190 of file time_axis_view_item.h.

◆ selection_frame

ArdourCanvas::Rectangle* TimeAxisViewItem::selection_frame
protected

Definition at line 214 of file time_axis_view_item.h.

◆ time_position

Temporal::timepos_t TimeAxisViewItem::time_position
protected

position of this item on the timeline

Definition at line 172 of file time_axis_view_item.h.

◆ trackview

TimeAxisView& TimeAxisViewItem::trackview
protected

time axis that this item is on

Definition at line 166 of file time_axis_view_item.h.

◆ visibility

Visibility TimeAxisViewItem::visibility
protected

Definition at line 225 of file time_axis_view_item.h.

◆ wide_enough_for_name

bool TimeAxisViewItem::wide_enough_for_name
protected

Definition at line 208 of file time_axis_view_item.h.


The documentation for this class was generated from the following file: