Zrythm v2.0.0-alpha.1
a highly automated and intuitive digital audio workstation
Loading...
Searching...
No Matches
zrythm::structure::project::ProjectUiState Class Reference

Serializable UI state for a project. More...

#include <src/structure/project/project_ui_state.h>

Inheritance diagram for zrythm::structure::project::ProjectUiState:
Collaboration diagram for zrythm::structure::project::ProjectUiState:

Signals

void audioInputSelectionChanged ()
void midiInputDeviceChanged ()

Public Member Functions

 ProjectUiState (Project &project, utils::AppSettings &app_settings)
 Constructs ProjectUiState with references from the given Project.
structure::project::ArrangerTooltool () const
structure::project::ClipEditorclipEditor () const
structure::arrangement::Timelinetimeline () const
dsp::SnapGridsnapGridTimeline () const
dsp::SnapGridsnapGridEditor () const
Q_INVOKABLE dsp::AudioInputSelectionaudioInputSelectionForTrack (const structure::tracks::Track *track)
Q_INVOKABLE dsp::MidiInputSelectionmidiInputSelectionForTrack (const structure::tracks::Track *track)
dsp::AudioInputSelectionfind_audio_input_selection (const structure::tracks::Track::Uuid &uuid) const
dsp::MidiInputSelectionfind_midi_input_selection (const structure::tracks::Track::Uuid &uuid) const

Static Public Attributes

static constexpr auto kAudioInputSelectionsKey = "audioInputSelections"sv
static constexpr auto kMidiInputSelectionsKey = "midiInputSelections"sv

Properties

zrythm::structure::arrangement::Timelinetimeline
zrythm::structure::project::ArrangerTooltool
zrythm::structure::project::ClipEditorclipEditor
zrythm::dsp::SnapGridsnapGridTimeline
zrythm::dsp::SnapGridsnapGridEditor

Friends

void to_json (nlohmann::json &j, const ProjectUiState &p)
void from_json (const nlohmann::json &j, ProjectUiState &p)

Detailed Description

Serializable UI state for a project.

Contains UI-related state that should be persisted between sessions:

  • Currently selected arranger tool
  • Clip editor state (selected region, etc.)
  • Timeline state
  • Snap/grid settings for timeline and editor

This class does NOT own the Project; it receives a reference to access necessary components (tempo map, registries) during construction.

Definition at line 38 of file project_ui_state.h.

Constructor & Destructor Documentation

◆ ProjectUiState()

zrythm::structure::project::ProjectUiState::ProjectUiState ( Project & project,
utils::AppSettings & app_settings )

Constructs ProjectUiState with references from the given Project.

Parameters
projectThe Project to extract tempo map and registries from.
app_settingsApplication settings for snap grid defaults.

Field Documentation

◆ kAudioInputSelectionsKey

auto zrythm::structure::project::ProjectUiState::kAudioInputSelectionsKey = "audioInputSelections"sv
staticconstexpr

Definition at line 76 of file project_ui_state.h.

◆ kMidiInputSelectionsKey

auto zrythm::structure::project::ProjectUiState::kMidiInputSelectionsKey = "midiInputSelections"sv
staticconstexpr

Definition at line 77 of file project_ui_state.h.

Property Documentation

◆ clipEditor

zrythm::structure::project::ClipEditor * zrythm::structure::project::ProjectUiState::clipEditor
read

Definition at line 43 of file project_ui_state.h.

◆ snapGridEditor

zrythm::dsp::SnapGrid * zrythm::structure::project::ProjectUiState::snapGridEditor
read

Definition at line 45 of file project_ui_state.h.

◆ snapGridTimeline

zrythm::dsp::SnapGrid * zrythm::structure::project::ProjectUiState::snapGridTimeline
read

Definition at line 44 of file project_ui_state.h.

◆ timeline

zrythm::structure::arrangement::Timeline * zrythm::structure::project::ProjectUiState::timeline
read

Definition at line 41 of file project_ui_state.h.

◆ tool

zrythm::structure::project::ArrangerTool * zrythm::structure::project::ProjectUiState::tool
read

Definition at line 42 of file project_ui_state.h.


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