_TrackWidget struct

The TrackWidget is split into 3 parts.

Contents

  • 1. Top part contains the "main" view.
  • 2. Lane part contains each lane.
  • 3. Automation tracklist part contains each automation track.

Public variables

GtkBox* main_box
Main box containing the drawing area and the meters on the right.
GtkBox* group_colors_box
Group colors.
GtkGestureClick* right_click
Right-click gesture.
int dragged
If drag update was called at least once.
int n_press
Number of clicks, used when selecting/moving/ dragging channels.
bool bg_hovered
Set between enter-leave signals.
bool color_area_hovered
Whether color area is currently hoverred.
bool icon_hovered
Whether the icon in the color area is currently hoverred.
int resize
Set when the drag should resize instead of dnd.
int resizing
Set during the whole resizing action.
TrackWidgetResizeTarget resize_target_type
Resize target type (track/at/lane).
void* resize_target
The object to resize.
Track* track
Associated Track.
int ctrl_held_at_start
Control held down on drag begin.
GtkBox* highlight_top_box
Used for highlighting.
TrackWidgetHighlight highlight_loc
Highlight location.
int selected_in_dnd
The track selection processing was done in the dnd callbacks, so no need to do it in drag_end.
double start_x
For drag actions.
double last_x
Used during hovering to remember the last known cursor position.
int button_pressed
Used when mouse button is held down to mark buttons as clicked.
CustomButtonWidget* clicked_button
Currently clicked button.
AutomationModeWidget* clicked_am
Currently clicked automation mode button.
CustomButtonWidget* top_buttons
Signal handler IDs for tracks that have them.
char* tooltip_text
Current tooltip text.
gint64 last_midi_out_trigger_time
Last MIDI event trigger time, for MIDI ports.
int redraw
Set to 1 to redraw.
bool was_armed
Whether the track was armed for recording at the start of the current action.
cairo_t* cached_cr
Cairo caches.
GtkPopoverMenu* popover_menu
Popover to be reused for context menus.
GtkPopover* track_name_popover
Popover for changing the track name.

Variable documentation

bool _TrackWidget::bg_hovered

Set between enter-leave signals.

This is because hover can continue to send signals when hovering over other overlayed widgets (buttons, etc.).

bool _TrackWidget::color_area_hovered

Whether color area is currently hoverred.

This is not mutually exclusive with TrackWidget::bg_hovered. The color area is considered part of the BG.

bool _TrackWidget::icon_hovered

Whether the icon in the color area is currently hoverred.

This is not mutually exclusive with TrackWidget::color_area_hovered. The icon is considered part of the color area.

int _TrackWidget::resize

Set when the drag should resize instead of dnd.

This is used to determine if we should resize on drag begin.

TrackWidgetHighlight _TrackWidget::highlight_loc

Highlight location.

Eg, whether to highlight inside the track (eg, when dragging inside foldable tracks).

CustomButtonWidget* _TrackWidget::top_buttons

Signal handler IDs for tracks that have them.

This is more convenient instead of having them in each widget. Buttons to be drawin in order.