TachyonUI 1.1.0
High-performance UI for building tools.
Loading...
Searching...
No Matches
tachyon::TimelineViewState Struct Reference

How one TimelineEditor shows a TimelineData: the part in view, the selection, the track filter, and what the user is doing in it. More...

#include <gui_controls/gui_timeline_types.h>

Inheritance diagram for tachyon::TimelineViewState:

Classes

struct  LaneHover
 What's under the pointer on the lanes, for its hover look. More...
struct  DragScrollFrom
 Where a drag scroll started from: the view's start and the rows' scroll. More...

Public Attributes

float viewStart = 0.0f
 The part of the timeline in view: from viewStart, viewLength seconds wide.
float viewLength = 0.0f
ID selectedTrack = ID::Invalid()
 highlighted in the list and on its lane
std::unordered_set< ID > selectedKeys
 keys and events, by stableID
std::string filter
 the track list shows the tracks whose name has it (and their groups)
std::function< void()> onAddTrack
 The "+" over the track list: add a track.
std::function< void(int track)> onTrackContextMenu
 Builds the menu for a track's row (right click, or the Menu key on the selected one), with MenuItem and the like, as onCanvasContextMenu does in a node view.

Internal: kept between frames while the user works

enum class  ClipPart : uint8_t { None , Body , Start , End }
 A clip's parts: its body moves it, its ends trim it. More...
Gesture< std::vector< TimelineTrack > > keyDrag
 moving the selected keys; the tracks as they were (all of them)
float keyPressTime = 0.0f
 the time under the key drag's press
bool keyMoved = false
 A clip's parts: its body moves it, its ends trim it.
Gesture< std::vector< TimelineTrack > > clipDrag
 moving or trimming a clip; the tracks as they were
int clipTrack = -1
 the track whose clip is dragged ...
ClipPart clipPart = ClipPart::None
 ... and by which part
float clipPressTime = 0.0f
 the time under the clip drag's press
bool clipMoved = false
 A clip's parts: its body moves it, its ends trim it.
HoverPart< LaneHover > hover
 A clip's parts: its body moves it, its ends trim it.
Gesture< std::unordered_set< ID > > boxSelect
 the selection to go back to: before a Shift / Ctrl box, else none
float boxFrom = 0.0f
 the box's anchor: time and row
int boxFromRow = 0
 A clip's parts: its body moves it, its ends trim it.
float boxTo = 0.0f
 A clip's parts: its body moves it, its ends trim it.
int boxToRow = 0
 A clip's parts: its body moves it, its ends trim it.
Gesture< TimelineRange > loopDrag
 the loop range as it was
int loopEdge = 0
 0 a new range, 1 its start, 2 its end, 3 the whole of it
float loopPressTime = 0.0f
 A clip's parts: its body moves it, its ends trim it.
HoverPart< int > loopEdgeHover
 the loop edge under the pointer on the ruler: 0 none, 1 start, 2 end
Gesture< float > scrub
 on the ruler; the playhead as it was
Gesture< float > pan
 the scroll bar's thumb; the view's start as it was
Gesture< DragScrollFrom > dragScroll
 the middle button (or Alt + left) held over the ruler or lanes
int zoom = 0
 the zoom slider, 0 (all of it) to 100
int zoomShown = 0
 the slider as last drawn, to tell its moves
int lanesWidth = 0
 the lanes' width last frame, in pixels
std::vector< ID > menuKeys
 The lanes' menu: what was right-clicked, or from the keyboard the selection and the playhead.
int menuTrack = -1
 the row's track
float menuTime = 0.0f
 the time under the right click
bool menuByPointer = false
 a right press set the above since the menu last opened
uint32_t menuOpening = 0
 the context menu opening it was worked out for
uint32_t seenRevision = 0
 the tracks' revision this view last built
ID editorID = ID::Invalid()
 the editor's ID last frame: its rows' and lanes' IDs are scoped to it

Detailed Description

How one TimelineEditor shows a TimelineData: the part in view, the selection, the track filter, and what the user is doing in it.

Keep one per view, from frame to frame.

Member Enumeration Documentation

◆ ClipPart

enum class tachyon::TimelineViewState::ClipPart : uint8_t
strong

A clip's parts: its body moves it, its ends trim it.

Enumerator
None 
Body 
Start 
End 

Member Data Documentation

◆ viewStart

float tachyon::TimelineViewState::viewStart = 0.0f

The part of the timeline in view: from viewStart, viewLength seconds wide.

A viewLength of 0 or less shows the whole length.

◆ viewLength

float tachyon::TimelineViewState::viewLength = 0.0f

◆ selectedTrack

ID tachyon::TimelineViewState::selectedTrack = ID::Invalid()

highlighted in the list and on its lane

◆ selectedKeys

std::unordered_set<ID> tachyon::TimelineViewState::selectedKeys

keys and events, by stableID

◆ filter

std::string tachyon::TimelineViewState::filter

the track list shows the tracks whose name has it (and their groups)

◆ onAddTrack

std::function<void()> tachyon::TimelineViewState::onAddTrack

The "+" over the track list: add a track.

◆ onTrackContextMenu

std::function<void(int track)> tachyon::TimelineViewState::onTrackContextMenu

Builds the menu for a track's row (right click, or the Menu key on the selected one), with MenuItem and the like, as onCanvasContextMenu does in a node view.

◆ keyDrag

Gesture<std::vector<TimelineTrack> > tachyon::TimelineViewState::keyDrag

moving the selected keys; the tracks as they were (all of them)

◆ keyPressTime

float tachyon::TimelineViewState::keyPressTime = 0.0f

the time under the key drag's press

◆ keyMoved

bool tachyon::TimelineViewState::keyMoved = false

A clip's parts: its body moves it, its ends trim it.

◆ clipDrag

Gesture<std::vector<TimelineTrack> > tachyon::TimelineViewState::clipDrag

moving or trimming a clip; the tracks as they were

◆ clipTrack

int tachyon::TimelineViewState::clipTrack = -1

the track whose clip is dragged ...

◆ clipPart

ClipPart tachyon::TimelineViewState::clipPart = ClipPart::None

... and by which part

◆ clipPressTime

float tachyon::TimelineViewState::clipPressTime = 0.0f

the time under the clip drag's press

◆ clipMoved

bool tachyon::TimelineViewState::clipMoved = false

A clip's parts: its body moves it, its ends trim it.

◆ hover

HoverPart<LaneHover> tachyon::TimelineViewState::hover

A clip's parts: its body moves it, its ends trim it.

◆ boxSelect

Gesture<std::unordered_set<ID> > tachyon::TimelineViewState::boxSelect

the selection to go back to: before a Shift / Ctrl box, else none

◆ boxFrom

float tachyon::TimelineViewState::boxFrom = 0.0f

the box's anchor: time and row

◆ boxFromRow

int tachyon::TimelineViewState::boxFromRow = 0

A clip's parts: its body moves it, its ends trim it.

◆ boxTo

float tachyon::TimelineViewState::boxTo = 0.0f

A clip's parts: its body moves it, its ends trim it.

◆ boxToRow

int tachyon::TimelineViewState::boxToRow = 0

A clip's parts: its body moves it, its ends trim it.

◆ loopDrag

Gesture<TimelineRange> tachyon::TimelineViewState::loopDrag

the loop range as it was

◆ loopEdge

int tachyon::TimelineViewState::loopEdge = 0

0 a new range, 1 its start, 2 its end, 3 the whole of it

◆ loopPressTime

float tachyon::TimelineViewState::loopPressTime = 0.0f

A clip's parts: its body moves it, its ends trim it.

◆ loopEdgeHover

HoverPart<int> tachyon::TimelineViewState::loopEdgeHover

the loop edge under the pointer on the ruler: 0 none, 1 start, 2 end

◆ scrub

Gesture<float> tachyon::TimelineViewState::scrub

on the ruler; the playhead as it was

◆ pan

Gesture<float> tachyon::TimelineViewState::pan

the scroll bar's thumb; the view's start as it was

◆ dragScroll

Gesture<DragScrollFrom> tachyon::TimelineViewState::dragScroll

the middle button (or Alt + left) held over the ruler or lanes

◆ zoom

int tachyon::TimelineViewState::zoom = 0

the zoom slider, 0 (all of it) to 100

◆ zoomShown

int tachyon::TimelineViewState::zoomShown = 0

the slider as last drawn, to tell its moves

◆ lanesWidth

int tachyon::TimelineViewState::lanesWidth = 0

the lanes' width last frame, in pixels

◆ menuKeys

std::vector<ID> tachyon::TimelineViewState::menuKeys

The lanes' menu: what was right-clicked, or from the keyboard the selection and the playhead.

the keys and events it acts on; none: the lane's menu

◆ menuTrack

int tachyon::TimelineViewState::menuTrack = -1

the row's track

◆ menuTime

float tachyon::TimelineViewState::menuTime = 0.0f

the time under the right click

◆ menuByPointer

bool tachyon::TimelineViewState::menuByPointer = false

a right press set the above since the menu last opened

◆ menuOpening

uint32_t tachyon::TimelineViewState::menuOpening = 0

the context menu opening it was worked out for

◆ seenRevision

uint32_t tachyon::TimelineViewState::seenRevision = 0

the tracks' revision this view last built

◆ editorID

ID tachyon::TimelineViewState::editorID = ID::Invalid()

the editor's ID last frame: its rows' and lanes' IDs are scoped to it


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