pub struct App {Show 42 fields
pub grid: Grid,
pub cursor_row: u32,
pub cursor_col: u32,
pub mode: Mode,
pub editor: Editor,
pub help_open: bool,
pub bpm: f64,
pub playing: bool,
pub beat_position: f64,
pub current_play_row: Option<u32>,
pub scale: Scale,
pub scale_name: String,
pub octave: i32,
pub bridge: Bridge,
pub scope_master: Vec<f32>,
pub scope_graph_in: Vec<f32>,
pub host_stats: HostStatsSnapshot,
pub spectrum_fall_ms: f64,
pub peak_l: f32,
pub peak_r: f32,
pub should_quit: bool,
pub instrument_names: Vec<String>,
pub voice_ids: Vec<u32>,
pub graph_nodes: Vec<(u32, String)>,
pub graph_node_descriptions: Vec<String>,
pub graph_edges: Vec<Edge>,
pub graph_cursor: usize,
pub graph_depths: Vec<usize>,
pub graph_layers: Vec<Vec<usize>>,
pub graph_params: Vec<Vec<ParamDescriptor>>,
pub graph_param_values: Vec<Vec<f64>>,
pub graph_param_groups: Vec<Vec<ParamGroup>>,
pub param_cursor: usize,
pub swing: f64,
pub euclidean_k: u32,
pub undo_stack: Vec<Vec<Option<NoteEvent>>>,
pub redo_stack: Vec<Vec<Option<NoteEvent>>>,
pub bottom_pane: BottomPane,
pub graph_path: Vec<u32>,
pub graph_stack: Vec<GraphFrame>,
pub graph_has_children: Vec<bool>,
pub graph_breadcrumb: Vec<String>,
/* private fields */
}Expand description
Mutable state for the full terminal UI: pattern/graph views, audio bridge, and layout data.
Fields§
§grid: Grid§cursor_row: u32§cursor_col: u32§mode: Mode§editor: Editor§help_open: boolFull keymap overlay (? / Esc).
bpm: f64§playing: bool§beat_position: f64§current_play_row: Option<u32>§scale: Scale§scale_name: String§octave: i32§bridge: Bridge§scope_master: Vec<f32>Master output (post–FX), interleaved stereo — waveform / spectrum.
scope_graph_in: Vec<f32>Instrument submix (pre–master bus), same layout — graph view IN preview.
host_stats: HostStatsSnapshotThis-process CPU / RSS refreshed ~2× per second for the info panel.
spectrum_fall_ms: f64Peak-decay time constant for spectrum bars (ms); lower = snappier, higher = longer “tail”.
peak_l: f32§peak_r: f32§should_quit: bool§instrument_names: Vec<String>§voice_ids: Vec<u32>§graph_nodes: Vec<(u32, String)>§graph_node_descriptions: Vec<String>§graph_edges: Vec<Edge>§graph_cursor: usize§graph_depths: Vec<usize>§graph_layers: Vec<Vec<usize>>§graph_params: Vec<Vec<ParamDescriptor>>§graph_param_values: Vec<Vec<f64>>§graph_param_groups: Vec<Vec<ParamGroup>>§param_cursor: usize§swing: f64§euclidean_k: u32§undo_stack: Vec<Vec<Option<NoteEvent>>>§redo_stack: Vec<Vec<Option<NoteEvent>>>§bottom_pane: BottomPane§graph_path: Vec<u32>Path into nested graphs for the graph editor (empty = root).
graph_stack: Vec<GraphFrame>Stack of saved cursor positions when diving into nested graphs.
graph_has_children: Vec<bool>Tracks which nodes have inner graphs for visual indicators.
Breadcrumb labels for the navigation path.
Implementations§
Source§impl App
impl App
Sourcepub fn new(
grid: Grid,
scale: Scale,
scale_name: String,
bridge: Bridge,
instrument_names: Vec<String>,
voice_ids: Vec<u32>,
) -> Self
pub fn new( grid: Grid, scale: Scale, scale_name: String, bridge: Bridge, instrument_names: Vec<String>, voice_ids: Vec<u32>, ) -> Self
Initial pattern view, scale metadata, and per-column voice IDs for trem_cpal::Command::NoteOn.
Sourcepub fn with_graph_info(
self,
nodes: Vec<(u32, String)>,
edges: Vec<Edge>,
params: Vec<(Vec<ParamDescriptor>, Vec<f64>, Vec<ParamGroup>)>,
) -> Self
pub fn with_graph_info( self, nodes: Vec<(u32, String)>, edges: Vec<Edge>, params: Vec<(Vec<ParamDescriptor>, Vec<f64>, Vec<ParamGroup>)>, ) -> Self
Attaches node/edge/param snapshots for the graph editor (from the host graph).
Sourcepub fn set_node_descriptions(&mut self, descriptions: Vec<String>)
pub fn set_node_descriptions(&mut self, descriptions: Vec<String>)
Sets processor descriptions for each node (shown in info help).
Sourcepub fn set_node_children(&mut self, has_children: Vec<bool>)
pub fn set_node_children(&mut self, has_children: Vec<bool>)
Marks which nodes have inner (nested) graphs for the graph view indicator.
Sourcepub fn with_nested_graph_snapshots(
self,
snapshots: HashMap<Vec<u32>, GraphSnapshot>,
) -> Self
pub fn with_nested_graph_snapshots( self, snapshots: HashMap<Vec<u32>, GraphSnapshot>, ) -> Self
Supplies snapshots for nested graph levels so Graph › Enter shows nodes and parameters.
Sourcepub fn sync_scope_focus(&mut self)
pub fn sync_scope_focus(&mut self)
Tells the audio thread which signal to show in the bottom IN | OUT previews.
Sourcepub fn handle_action(&mut self, action: Action)
pub fn handle_action(&mut self, action: Action)
Sourcepub fn poll_audio(&mut self)
pub fn poll_audio(&mut self)
Drains pending Notifications and timed preview note-off; call each frame from the UI loop.
Auto Trait Implementations§
impl !Freeze for App
impl !RefUnwindSafe for App
impl Send for App
impl !Sync for App
impl Unpin for App
impl UnsafeUnpin for App
impl !UnwindSafe for App
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<S> FromSample<S> for S
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more