Nota — a free DAW for macOS, Windows and Linux. No subscription, no account — just open it and make music.
C# audioaudio-unitavaloniacpp20cross-platformdawdigital-audio-workstationdspjucelinux-audiomcp-servermidimusicmusic-productionpiano-rollplugin-hostsequencersynthesizervstvst3
Redesign of transport view
Egor Khindikaynenb6552ab4225f
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 69df6cb6..098a7c3f 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -19,6 +19,12 @@ Entry categories: `Added`, `Changed`, `Fixed`, `Removed`.## [Unreleased]### Added+- **A Snap latch in the transport.** Separate from the grid denomination, which only says+ *how far apart*: switch Snap off to position clips freely for a while, instead of holding+ ⌥ for every drag. The grid keeps its spacing, so switching back resumes where you were.+- **A MIDI input light** on the MIDI Learn button, lit by incoming control events — a+ controller that is plugged in but on the wrong port or channel is now visible without+ opening the mappings tab.- **A Pattern tab for the Drum Rack.** Select a MIDI clip on a Drum Rack track and thedetail panel offers **Pattern** between Devices and Clip: a drum-machine step grid withone row per loaded pad. Click a step to place a hit, shift-click it for an accent, drag@@ -54,6 +60,19 @@ Entry categories: `Added`, `Changed`, `Fixed`, `Removed`.restart — and the choice is remembered.### Changed+- **The top chrome is one row instead of two.** The transport bar and the toolbar under it+ were a 48px row and a 34px row mixing four unrelated jobs; they are now a single 60px+ bar, handing 22px back to the arrangement. It reads left to right: which view you are+ in · what plays · the numbers you set · the switches you flip · then, pinned right, what+ the machine is doing. Transport, position and loop share one recessed console so+ playback reads as a single object, and tempo, signature, grid and launch quantize use+ one value-over-label cell so the row scans as a strip of readouts. The position readout+ is now large enough to read across the room and says underneath which clock it is+ showing. Nothing was dropped: the three add-track buttons collapse into a **+ Track**+ menu, launch quantize appears in Session where it applies, and **Follow playhead** moved+ to the View menu.+- **Master shows the gain it is applying,** in dB, next to its fader and meter — the+ handle position is no longer the only readout.- **The arrangement and the modular canvas are islands, and groups stop weighing as much astheir tracks.** Both now float on the app ground as rounded panels, matching the browser —the modular view keeps its toolbar, track rail and status line inside those corners. A groupdiff --git a/DESIGN.html b/DESIGN.htmlindex 8b394e00..6b7acabe 100644--- a/DESIGN.html+++ b/DESIGN.html@@ -16,6 +16,7 @@:root {/* Surfaces */+ --surface-abyss: #0A0908;--bg-sunken: #100F0D;--bg-app: #171613;--lane-b: #191814;@@ -71,6 +72,7 @@/* Ember Paper — the same roles on a warm paper ground. Only the colour tokensmove; geometry and type are variant-independent. */:root[data-variant="paper"] {+ --surface-abyss: #DCD6C5;--bg-sunken: #E4DFD1;--bg-app: #EFEADE;--lane-b: #E9E4D6;@@ -738,6 +740,7 @@ footer {<h3>Surfaces</h3><div class="swatches">+ <button class="sw" data-hex="#0A0908" data-paper="#DCD6C5"><span class="sw__chip" style="background:var(--surface-abyss)"></span><span class="sw__meta"><span class="sw__key">Brush.SurfaceAbyss</span><span class="sw__hex">#0A0908</span> <span class="sw__role">· deepest recess — meter troughs, transport console</span></span></button><button class="sw" data-hex="#100F0D" data-paper="#E4DFD1"><span class="sw__chip" style="background:var(--bg-sunken)"></span><span class="sw__meta"><span class="sw__key">Brush.BgSunken</span><span class="sw__hex">#100F0D</span> <span class="sw__role">· wells, lanes, chrome</span></span></button><button class="sw" data-hex="#171613" data-paper="#EFEADE"><span class="sw__chip" style="background:var(--bg-app)"></span><span class="sw__meta"><span class="sw__key">Brush.BgApp</span><span class="sw__hex">#171613</span> <span class="sw__role">· app ground</span></span></button><button class="sw" data-hex="#191814" data-paper="#E9E4D6"><span class="sw__chip" style="background:var(--lane-b)"></span><span class="sw__meta"><span class="sw__key">Brush.LaneB</span><span class="sw__hex">#191814</span> <span class="sw__role">· lane alternation</span></span></button>@@ -865,7 +868,7 @@ footer {<h3>Transport</h3><div class="specimen">- <span class="specimen__label">Transport bar — 28px chrome on surface-raised</span>+ <span class="specimen__label">Transport chrome — 28px controls on surface-raised, inside the 60px row</span><button class="tp tp--play" type="button" aria-label="Play">▶</button><button class="tp" type="button" aria-label="Stop">■</button><button class="tp tp--rec-on" type="button" aria-label="Record" aria-pressed="true">●</button>@@ -1266,7 +1269,7 @@ footer {<div class="rules"><div class="rule rule--do"><h4><span class="rule__glyph">+</span> Layout skeleton</h4>- <p>Transport bar → toolbar → body (on <code>Brush.BgApp</code>) → 26px status bar. Panels are <code>Brush.SurfaceCard</code> with a 1px bottom border. The body holds <strong>islands</strong>: the browser, the arrangement and the modular canvas are <code>Radius.Md</code> cards with a 1px <code>Brush.BorderDefault</code> edge, clipped to their bounds, floating on the app ground with an 8px gutter; the splitter between two islands is a 2px transparent grab strip inside that gutter and carries no line of its own.</p>+ <p>36px title bar → a single 60px transport row → body (on <code>Brush.BgApp</code>) → 22px status bar. The transport is one row, not the transport + toolbar pair it used to be: which view · what plays · the numbers you set · the switches you flip · then, pinned right, what the machine is doing. Transport, position and loop share a <code>Border.console</code> recess on <code>Brush.SurfaceAbyss</code>; tempo, signature, grid and launch quantize use one <code>.cell</code> shape — mono value over an 8px <code>.CellLabel</code>. Panels are <code>Brush.SurfaceCard</code> with a 1px bottom border. The body holds <strong>islands</strong>: the browser, the arrangement and the modular canvas are <code>Radius.Md</code> cards with a 1px <code>Brush.BorderDefault</code> edge, clipped to their bounds, floating on the app ground with an 8px gutter; the splitter between two islands is a 2px transparent grab strip inside that gutter and carries no line of its own.</p><p>Arrangement rows are not one pitch. A <strong>track</strong> row is 64px and its header carries every control (name + kind · mute/solo/arm + input · fader + dB + pan, with a level rail on the right edge). A <strong>group</strong> row is a 26px titled bar — disclosure, name, mute/solo, a 4px level rail, kind tag — and opens to a full 64px row only while it is the selected track. Header column 228px. A <strong>clip</strong> is a tinted body (<code>Radius.Clip</code>) under a 2px band in the track colour, with the waveform or notes across its full height; the name is drawn over the body, only where a run of clips begins.</p></div><div class="rule rule--do">@@ -1285,7 +1288,7 @@ footer {<thead><tr><th>Item</th><th>Status</th></tr></thead><tbody><tr><td class="d">The <code>nota-design</code> agent skill</td><td class="d">Rewritten to point at the theme files rather than restate values — the earlier copy had drifted to a cool-slate palette with a cyan accent. Now current for both variants.</td></tr>- <tr><td class="d">Custom title bar</td><td class="d">Not built. The OS title bar is still in use; the status bar carries the chrome identity until a frameless 40px bar lands.</td></tr>+ <tr><td class="d">Custom title bar</td><td class="d">Built: a 36px frameless bar on <code>Brush.ChromeBg</code>, macOS traffic lights in a left inset, document name centred; Windows reserves 180px for the native caption buttons.</td></tr><tr><td class="d">Display face</td><td class="d">Inter is bundled as a stand-in for Geist. Swap <code>Font.UI</code> once Geist ships with the app.</td></tr><tr><td class="d"><code>Space.*</code> tokens</td><td class="d">Do not exist. The 4px grid is honoured by convention only.</td></tr><tr><td class="d">Two palette files</td><td class="d"><code>NotaTheme.axaml</code> and <code>NotaPalette.cs</code> must be edited together — nothing enforces it. Each token now carries two values, so one colour change is four edits: the Dark and Light dictionaries, the palette slot, and this page.</td></tr>diff --git a/DESIGN.md b/DESIGN.mdindex 4c21a79b..92ec31dc 100644--- a/DESIGN.md+++ b/DESIGN.md@@ -97,6 +97,7 @@ be dropped on `NotaPalette.Changed`.| Key | Graphite | Paper | Use ||---|---|---|---|+| `Brush.SurfaceAbyss` | `#0A0908` | `#DCD6C5` | Deepest recess — meter troughs, transport console || `Brush.BgSunken` | `#100F0D` | `#E4DFD1` | Wells, lanes, graph grounds, chrome || `Brush.BgApp` | `#171613` | `#EFEADE` | App ground || `Brush.LaneB` | `#191814` | `#E9E4D6` | Lane alternation |@@ -274,9 +275,22 @@ takes — not a drawing that resembles one.## Layout skeleton-`Transport bar → toolbar → body (on Brush.BgApp) → 26px status bar.`+`36px title bar → 60px transport → body (on Brush.BgApp) → 22px status bar.`Panels are `Brush.SurfaceCard` with a 1px bottom border.+The transport is **one row**, not the transport + toolbar pair it used to be. It reads+left to right as which view · what plays · the numbers you set · the switches you flip ·+then, pinned right, what the machine is doing. Transport, position and loop share a+single `Border.console` recess on `Brush.SurfaceAbyss` so playback reads as one object;+tempo, signature, grid and launch quantize use one `.cell` shape — mono value over an 8px+`.CellLabel` — so the row scans as a strip of readouts rather than a queue of pills.+The three switches — metronome, snap, automation — are icon-only 28px `tp-icon` toggles+that draw the thing they do (a metronome, a horseshoe magnet, a breakpoint envelope) and+carry their name in a tooltip; none sets a Foreground, so the engaged state turns the+glyph brass through the base `ToggleButton:checked`. Controls that belong to one context+appear only there: launch quantize in Session, "Re-enable" only while a lane is+overridden.+The body holds **islands**: the browser, the arrangement and the modular canvas are`Radius.Md` cards with a 1px `Brush.BorderDefault` edge, clipped to their bounds, floatingon `Brush.BgApp` with an 8px gutter. The splitter between two islands carries no line of@@ -310,8 +324,9 @@ Things that are true today and should not surprise you:`NotaPalette.InkOverrides` rather than reaching for a literal.- **Black stays black.** Drop shadows and the black-key row tint are alpha-over-black inboth variants — that is correct, not drift.-- **No custom title bar.** The OS title bar is still in use; the status bar carries the- chrome identity.+- **The title bar is custom.** A 36px frameless bar (`Brush.ChromeBg`) with the macOS+ traffic lights in a left inset and the document name centred; Windows reserves 180px on+ the right for the native caption buttons.- **Font substitution.** Mockups specify Geist / Geist Mono; the app ships Inter and theCascadia → Menlo → Consolas stack, so weights sit slightly differently.- **No `Space.*` tokens.** The 4px grid is honoured by convention only.diff --git a/src/managed/Nota.App/ArrangementView.cs b/src/managed/Nota.App/ArrangementView.csindex b6ea4080..e161b4a9 100644--- a/src/managed/Nota.App/ArrangementView.cs+++ b/src/managed/Nota.App/ArrangementView.cs@@ -36,6 +36,7 @@ public sealed partial class ArrangementView : UserControlprivate double _totalBeats = 64;private int _beatsPerBar = 4;private double _snapBeats = 1.0; // snap grid (1 beat) — M4-2+ private bool _snapEnabled = true; // transport magnet toggle (off = free positioning)internal int SelTrackId = -1, SelClipIndex = -1; // "primary" selection (Clip tab, effect target, trim)// Multi-selection of clips across tracks (marquee / group move + delete). The// primary (SelTrackId/SelClipIndex) is always one of these when non-empty.@@ -393,9 +394,14 @@ public sealed partial class ArrangementView : UserControlpublic double ScrollBeats => _scrollBeats;public double PlayheadBeats => _playheadBeats;public int BeatsPerBar { get => _beatsPerBar; set { _beatsPerBar = value; Redraw(); } }- /// <summary>Clip-drag snap grid in beats (toolbar Snap chip, 1b).</summary>+ /// <summary>Clip-drag snap grid in beats (transport GRID cell, 1b).</summary>public double SnapBeats { get => _snapBeats; set { _snapBeats = Math.Max(1.0 / 32, value); Redraw(); } }+ /// <summary>Master snap on/off (the transport magnet). Off positions freely — the+ /// same effect as holding Alt, but latched. The grid itself keeps its spacing, so+ /// switching back resumes on the denomination the GRID cell shows.</summary>+ public bool SnapEnabled { get => _snapEnabled; set { _snapEnabled = value; Redraw(); } }+/// <summary>How many clips print their name on the lane (View ▸ Clip names). The default/// names only the head of each run, so a repeating pattern reads as one block.</summary>public ClipLabelMode ClipLabels@@ -937,7 +943,8 @@ public sealed partial class ArrangementView : UserControl/// <summary>Clipboard clip kind: -1 empty, else 0 (block clipboard has content).</summary>public int ClipboardClipKind() => HasClipClipboard ? 0 : -1;- internal double Snap(double beat) => _snapBeats > 0 ? Math.Round(beat / _snapBeats) * _snapBeats : beat;+ internal double Snap(double beat)+ => _snapEnabled && _snapBeats > 0 ? Math.Round(beat / _snapBeats) * _snapBeats : beat;/// <summary>Snap unless Alt is held (Alt = free/fine positioning). Reads the live/// modifier state so it can be toggled mid-drag (req 1.2.1/2.4/3.1/8.2.1, 7.10).</summary>diff --git a/src/managed/Nota.App/MainWindow.Menu.cs b/src/managed/Nota.App/MainWindow.Menu.csindex a7559383..02207230 100644--- a/src/managed/Nota.App/MainWindow.Menu.cs+++ b/src/managed/Nota.App/MainWindow.Menu.cs@@ -157,6 +157,17 @@ public partial class MainWindow_vm.Settings.Save();_vm.StatusText = Timeline.ShowSections ? "Sections lane shown" : "Sections lane hidden";}+ // Follow: keep the arrangement scrolling with the playhead during playback. Lives in+ // the View menu since the single-row transport (1b) has no room for a toolbar toggle.+ private void OnMenuToggleFollow(object? sender, EventArgs e)+ {+ bool on = !Timeline.FollowPlayhead;+ Timeline.FollowPlayhead = on;+ if (sender is NativeMenuItem mi) mi.IsChecked = on;+ if (on) Timeline.RecenterOnPlayhead(); // jump to the cursor now+ if (_vm is not null) _vm.StatusText = on ? "Following the playhead" : "Follow playhead off";+ }+// Cycles how much of the arrangement prints clip names: every clip → the head of each run// (the default, so a repeated pattern reads as one block) → none.private void OnMenuCycleClipNames(object? sender, EventArgs e)diff --git a/src/managed/Nota.App/MainWindow.axaml b/src/managed/Nota.App/MainWindow.axamlindex 3af8ccbb..bc7f6d28 100644--- a/src/managed/Nota.App/MainWindow.axaml+++ b/src/managed/Nota.App/MainWindow.axaml@@ -62,6 +62,8 @@<NativeMenuItem Header="Toggle overview" Click="OnMenuToggleOverview"/><NativeMenuItem Header="Toggle sections" Click="OnMenuToggleSections"/><NativeMenuItemSeparator/>+ <NativeMenuItem Header="Follow playhead" Click="OnMenuToggleFollow" ToggleType="CheckBox"/>+ <NativeMenuItemSeparator/><NativeMenuItem Header="Clip names" Click="OnMenuCycleClipNames"/></NativeMenu></NativeMenuItem.Menu>@@ -108,153 +110,208 @@<!-- In-window menu bar for Windows/Linux (empty on macOS: menus go to the system bar) --><NativeMenuBar DockPanel.Dock="Top"/>- <!-- Transport (48): controls pinned left | CPU + master pinned right (1b) -->- <Border DockPanel.Dock="Top" Classes="Panel" Height="48" Padding="12,0">- <Grid ColumnDefinitions="*,Auto,*">- <!-- Left (pinned): position · BPM · time signature · quantize -->- <StackPanel Grid.Column="0" Orientation="Horizontal" Spacing="8" VerticalAlignment="Center" HorizontalAlignment="Left">- <!-- Position (click to toggle bars.beats ↔ minutes:seconds) -->- <Border Classes="well" Cursor="Hand" PointerPressed="OnTogglePositionDisplay"- ToolTip.Tip="Click to switch between bars and time">- <TextBlock Classes="Mono" Text="{Binding Transport.PositionText}" FontSize="12" MinWidth="52"- TextAlignment="Center" Foreground="{DynamicResource Brush.AccentBright}" VerticalAlignment="Center"/>- </Border>- <!-- BPM (drag vertically or double-click to type) -->- <Border Classes="well" Padding="8,0" ToolTip.Tip="Drag ↕ or double-click to set tempo">- <StackPanel Orientation="Horizontal" Spacing="5" VerticalAlignment="Center">- <Panel x:Name="BpmHost" Width="40" VerticalAlignment="Stretch"/>- <TextBlock Classes="SectionLabel" Text="BPM" VerticalAlignment="Center"/>+ <!-- Transport (60) — mockup 1b: one row instead of the old transport+toolbar pair,+ handing 22px back to the arrangement. Reads left to right as: which view ·+ what plays (a recessed console fusing transport, position and loop) · the+ numbers you set · the switches you flip · then, pinned right, what the machine+ is doing. Everything the two old rows carried is still here; Follow playhead+ moved to View ▸ Follow playhead and launch quantize shows only in Session,+ where it applies. -->+ <Border DockPanel.Dock="Top" Classes="Panel" Height="60" Padding="14,0">+ <Grid ColumnDefinitions="Auto,Auto,Auto,Auto,*,Auto,Auto,Auto,Auto,Auto">++ <!-- View switch -->+ <Border Grid.Column="0" Classes="segmented" Margin="0,0,12,0">+ <StackPanel Orientation="Horizontal" Spacing="2">+ <ToggleButton x:Name="ArrangeBtn" Classes="seg" Content="Arrangement" IsChecked="True" Click="OnShowArrangement"/>+ <ToggleButton x:Name="SessionBtn" Classes="seg" Content="Session" Click="OnShowSession"/>+ <ToggleButton x:Name="ModularBtn" Classes="seg" Content="Modular" Click="OnShowModular"/>+ </StackPanel>+ </Border>++ <!-- The console: transport · position · loop in one recess -->+ <Border Grid.Column="1" Classes="console">+ <StackPanel Orientation="Horizontal" Spacing="11" VerticalAlignment="Center">+ <StackPanel Orientation="Horizontal" Spacing="4" VerticalAlignment="Center">+ <Button x:Name="StopBtn" Classes="tp-icon" Content="■" ToolTip.Tip="Stop"+ Foreground="{DynamicResource Brush.TextSecondary}" Command="{Binding Transport.StopCommand}"/>+ <Button x:Name="PlayBtn" Classes="tp-play" Content="▶" ToolTip.Tip="Play"+ Foreground="{DynamicResource Brush.TextOnAccent}" Command="{Binding Transport.PlayCommand}"/>+ <ToggleButton x:Name="RecordBtn" Classes="tp-icon rec" Content="●" ToolTip.Tip="Record"+ Foreground="{DynamicResource Brush.Danger}" IsChecked="{Binding Transport.RecordOn}"/></StackPanel>- </Border>- <!-- Time signature (drag ↕ each field to change) -->- <Border Classes="well" Padding="8,0" ToolTip.Tip="Drag ↕ to set time signature">- <StackPanel Orientation="Horizontal" Spacing="2" VerticalAlignment="Center">- <Panel x:Name="TimeSigNumHost" Width="16" VerticalAlignment="Stretch"/>- <TextBlock Classes="Mono" Text="/" FontSize="12"- Foreground="{DynamicResource Brush.TextTertiary}" VerticalAlignment="Center"/>- <Panel x:Name="TimeSigDenHost" Width="16" VerticalAlignment="Stretch"/>++ <Border Width="1" Height="24" Background="{DynamicResource Brush.BorderDefault}"/>++ <!-- Position — click to flip bars.beats ↔ minutes:seconds; the unit below says which -->+ <StackPanel Spacing="1" VerticalAlignment="Center" Cursor="Hand" Background="Transparent"+ PointerPressed="OnTogglePositionDisplay"+ ToolTip.Tip="Click to switch between bars and time">+ <TextBlock Classes="Mono" Text="{Binding Transport.PositionText}" FontSize="19" LineHeight="20"+ MinWidth="98" Foreground="{DynamicResource Brush.AccentBright}"/>+ <TextBlock Classes="Mono CellLabel" Text="{Binding Transport.PositionUnitText}"/></StackPanel>- </Border>- <!-- Launch quantize: click to cycle (None … 1/16 … 8 Bars). Applied to Session slot/scene launches. -->- <Button x:Name="LaunchQChip" Classes="chip" Click="OnCycleLaunchQ" ToolTip.Tip="Launch quantize (Session)">- <StackPanel Orientation="Horizontal" Spacing="6" VerticalAlignment="Center">- <TextBlock Classes="SectionLabel" Text="Q" VerticalAlignment="Center"/>- <TextBlock x:Name="LaunchQLabel" Classes="Mono" Text="1 Bar" FontSize="10"- Foreground="{DynamicResource Brush.AccentBright}" VerticalAlignment="Center"/>++ <Border Width="1" Height="24" Background="{DynamicResource Brush.BorderDefault}"/>++ <!-- Loop: the range is the button -->+ <ToggleButton Classes="cell" IsChecked="{Binding Transport.LoopOn}" ToolTip.Tip="Loop the range set on the ruler">+ <StackPanel Spacing="2">+ <TextBlock Classes="CellLabel" Text="LOOP" Foreground="{Binding $parent[ToggleButton].Foreground}"/>+ <TextBlock Classes="Mono" FontSize="11" LineHeight="12" MinWidth="58"+ Text="{Binding Transport.LoopRangeText}"+ Foreground="{Binding $parent[ToggleButton].Foreground}"/>+ </StackPanel>+ </ToggleButton>+ </StackPanel>+ </Border>++ <!-- Readouts: value over label, one shape for all of them -->+ <StackPanel Grid.Column="2" Orientation="Horizontal" Spacing="2" VerticalAlignment="Center" Margin="12,0,0,0">+ <!-- Tempo (drag ↕ or double-click to type) -->+ <StackPanel Spacing="2" VerticalAlignment="Center" Margin="7,0" ToolTip.Tip="Drag ↕ or double-click to set tempo">+ <Panel x:Name="BpmHost" Width="34" Height="18"/>+ <TextBlock Classes="CellLabel" Text="BPM" HorizontalAlignment="Center"/>+ </StackPanel>+ <!-- Time signature (drag ↕ each field) -->+ <StackPanel Spacing="2" VerticalAlignment="Center" Margin="7,0" ToolTip.Tip="Drag ↕ to set the time signature">+ <StackPanel Orientation="Horizontal" Spacing="1" Height="18">+ <Panel x:Name="TimeSigNumHost" Width="16"/>+ <TextBlock Classes="Mono" Text="/" FontSize="14" VerticalAlignment="Center"+ Foreground="{DynamicResource Brush.TextTertiary}"/>+ <Panel x:Name="TimeSigDenHost" Width="16"/>+ </StackPanel>+ <TextBlock Classes="CellLabel" Text="SIG" HorizontalAlignment="Center"/>+ </StackPanel>+ <!-- Clip snap grid: click to cycle -->+ <Button x:Name="SnapChip" Classes="cell" Click="OnCycleSnap" ToolTip.Tip="Clip snap grid — click to cycle">+ <StackPanel Spacing="2">+ <TextBlock x:Name="SnapLabel" Classes="Mono" Text="1/4" FontSize="14" LineHeight="16"+ MinWidth="36" TextAlignment="Center" HorizontalAlignment="Center" Foreground="{DynamicResource Brush.TextPrimary}"/>+ <TextBlock Classes="CellLabel" Text="GRID" HorizontalAlignment="Center"/>+ </StackPanel>+ </Button>+ <!-- Launch quantize — a Session concept, so it only appears there -->+ <Button x:Name="LaunchQChip" Classes="cell" Click="OnCycleLaunchQ" IsVisible="False"+ ToolTip.Tip="Launch quantize — when Session slots and scenes fire">+ <StackPanel Spacing="2">+ <TextBlock x:Name="LaunchQLabel" Classes="Mono" Text="1 Bar" FontSize="14" LineHeight="16"+ MinWidth="44" TextAlignment="Center" HorizontalAlignment="Center" Foreground="{DynamicResource Brush.TextPrimary}"/>+ <TextBlock Classes="CellLabel" Text="LAUNCH" HorizontalAlignment="Center"/></StackPanel></Button></StackPanel>- <!-- Center: transport (play · stop · rec) | metronome · follow · loop -->- <StackPanel Grid.Column="1" Orientation="Horizontal" Spacing="8" VerticalAlignment="Center" HorizontalAlignment="Center">- <StackPanel Orientation="Horizontal" Spacing="4" VerticalAlignment="Center">- <Button x:Name="PlayBtn" Classes="tp-play" Content="▶" ToolTip.Tip="Play"- Foreground="{DynamicResource Brush.TextOnAccent}" Command="{Binding Transport.PlayCommand}"/>- <Button x:Name="StopBtn" Classes="tp-icon" Content="■" ToolTip.Tip="Stop"- Foreground="{DynamicResource Brush.TextSecondary}" Command="{Binding Transport.StopCommand}"/>- <ToggleButton x:Name="RecordBtn" Classes="tp-icon" Content="●" ToolTip.Tip="Record"- Foreground="{DynamicResource Brush.Danger}" IsChecked="{Binding Transport.RecordOn}"/>- </StackPanel>- <Border Width="1" Height="22" Background="{DynamicResource Brush.BorderDefault}" Margin="4,0"/>- <!-- Metronome (icon) -->- <ToggleButton Classes="tp-icon" IsChecked="{Binding Transport.MetronomeOn}" ToolTip.Tip="Metronome">+ <!-- Switches. Each draws the thing it does, so the row carries no prose: a+ metronome, a magnet, a breakpoint envelope. None sets Foreground, so the+ engaged state turns the glyph brass through the base ToggleButton:checked. -->+ <StackPanel Grid.Column="3" Orientation="Horizontal" Spacing="5" VerticalAlignment="Center" Margin="12,0,0,0">+ <!-- Metronome: body, pendulum rod, weight -->+ <ToggleButton Classes="tp-icon" IsChecked="{Binding Transport.MetronomeOn}" ToolTip.Tip="Metronome (M)"><Viewbox Width="15" Height="15"><Canvas Width="24" Height="24"><Path Stroke="{Binding $parent[ToggleButton].Foreground}" StrokeThickness="1.7"- StrokeJoin="Round" Data="M12 3 L18.5 20 L5.5 20 Z"/>+ StrokeJoin="Round" Data="M9.8 5.5 H14.2 L19 20 H5 Z"/><Path Stroke="{Binding $parent[ToggleButton].Foreground}" StrokeThickness="1.7"- StrokeLineCap="Round" Data="M12 20 L14.5 8"/>- <Ellipse Canvas.Left="13" Canvas.Top="6.5" Width="3" Height="3"+ StrokeLineCap="Round" Data="M12 19 L13.9 3.2"/>+ <Ellipse Canvas.Left="11.33" Canvas.Top="9.4" Width="3.2" Height="3.2"Fill="{Binding $parent[ToggleButton].Foreground}"/></Canvas></Viewbox></ToggleButton>- <!-- Follow playhead: keep the arrangement scrolling with the cursor -->- <ToggleButton x:Name="FollowBtn" Classes="tp-icon" Click="OnToggleFollow" ToolTip.Tip="Follow playhead">+ <!-- Snapping on/off, independent of which grid the GRID cell shows. Off is the+ same as holding Alt, but latched. A horseshoe magnet: the poles are banded+ off the body by a transparent gap, so the shape reads on any button state. -->+ <ToggleButton x:Name="SnapToggle" Classes="tp-icon" IsChecked="True" Click="OnToggleSnapEnabled"+ ToolTip.Tip="Snap to grid — off positions freely (hold Alt for one drag)"><Viewbox Width="15" Height="15"><Canvas Width="24" Height="24">- <Path Stroke="{Binding $parent[ToggleButton].Foreground}" StrokeThickness="1.8"- StrokeLineCap="Round" Data="M3 18 H21"/>- <Path Fill="{Binding $parent[ToggleButton].Foreground}" Data="M8 6 H16 L12 12 Z"/>- <Path Stroke="{Binding $parent[ToggleButton].Foreground}" StrokeThickness="1.8"- StrokeLineCap="Round" Data="M12 12 V18"/>+ <Path Fill="{Binding $parent[ToggleButton].Foreground}"+ Data="M4 17 V12.5 A8 8 0 0 1 20 12.5 V17 H15.5 V12.5 A3.5 3.5 0 0 0 8.5 12.5 V17 Z"/>+ <Rectangle Canvas.Left="4" Canvas.Top="19" Width="4.5" Height="2.5"+ Fill="{Binding $parent[ToggleButton].Foreground}"/>+ <Rectangle Canvas.Left="15.5" Canvas.Top="19" Width="4.5" Height="2.5"+ Fill="{Binding $parent[ToggleButton].Foreground}"/></Canvas></Viewbox></ToggleButton>- <!-- Loop (icon) + range readout -->- <ToggleButton Classes="chip" IsChecked="{Binding Transport.LoopOn}" ToolTip.Tip="Loop">- <StackPanel Orientation="Horizontal" Spacing="7" VerticalAlignment="Center">- <Viewbox Width="15" Height="15">- <Canvas Width="24" Height="24">- <Path Fill="{Binding $parent[ToggleButton].Foreground}"- Data="M7 7h10v3l4-4-4-4v3H5v6h2V7zm10 10H7v-3l-4 4 4 4v-3h12v-6h-2v4z"/>- </Canvas>- </Viewbox>- <TextBlock Classes="Mono" Text="{Binding Transport.LoopRangeText}" FontSize="11" VerticalAlignment="Center"/>- </StackPanel>+ <!-- Automation: a breakpoint envelope — the ramp and handles the lanes draw -->+ <ToggleButton x:Name="AutomationToggle" Classes="tp-icon" Click="OnToggleAutomation"+ ToolTip.Tip="Show parameter-automation lanes (⌘A)">+ <Viewbox Width="15" Height="15">+ <Canvas Width="24" Height="24">+ <Path Stroke="{Binding $parent[ToggleButton].Foreground}" StrokeThickness="1.8"+ StrokeLineCap="Round" StrokeJoin="Round" Data="M3 17.5 H9 L14.5 7.5 H21"/>+ <Ellipse Canvas.Left="7.1" Canvas.Top="15.6" Width="3.8" Height="3.8"+ Fill="{Binding $parent[ToggleButton].Foreground}"/>+ <Ellipse Canvas.Left="12.6" Canvas.Top="5.6" Width="3.8" Height="3.8"+ Fill="{Binding $parent[ToggleButton].Foreground}"/>+ </Canvas>+ </Viewbox></ToggleButton>+ <!-- Shown only while a hand-moved control has taken a lane over from+ playback (M9-C); one click hands every overridden lane back. -->+ <Button x:Name="ReenableAutoBtn" Classes="chip" Content="Re-enable"+ IsVisible="False" Click="OnReenableAutomation"+ Foreground="{DynamicResource Brush.AccentBright}"+ ToolTip.Tip="A control you moved is overriding its automation — click to hand it back"/></StackPanel>- <!-- Right (pinned): MIDI-learn toggle + CPU (live DSP load) + master volume + stereo meter -->- <StackPanel Grid.Column="2" Orientation="Horizontal" Spacing="14" VerticalAlignment="Center" HorizontalAlignment="Right">- <ToggleButton x:Name="MidiLearnBtn" Classes="seg" Content="MIDI" VerticalAlignment="Center"- Click="OnToggleMidiLearn"- ToolTip.Tip="MIDI Learn — highlight mappable controls, click one, then move a knob on your controller"/>- <StackPanel Orientation="Horizontal" Spacing="6" VerticalAlignment="Center">- <TextBlock Classes="SectionLabel" Text="CPU" VerticalAlignment="Center"/>- <Border Width="56" Height="5" Background="{DynamicResource Brush.BgSunken}" CornerRadius="3" VerticalAlignment="Center" ClipToBounds="True">- <Border x:Name="CpuFill" Width="0" HorizontalAlignment="Left" CornerRadius="3"- Background="{DynamicResource Brush.Success}"/>- </Border>- <TextBlock x:Name="CpuText" Classes="Mono" Text="0%" FontSize="10"- Foreground="{DynamicResource Brush.TextSecondary}" VerticalAlignment="Center" MinWidth="26"/>+ <!-- Add track: one menu instead of three chips -->+ <Button Grid.Column="5" Classes="chip" Margin="12,0,0,0" ToolTip.Tip="Add a track">+ <StackPanel Orientation="Horizontal" Spacing="7" VerticalAlignment="Center">+ <TextBlock Text="+ Track" VerticalAlignment="Center"/>+ <Path Data="M0,0 L3.5,4 L7,0 Z" Fill="{DynamicResource Brush.TextTertiary}" VerticalAlignment="Center"/></StackPanel>- <StackPanel Orientation="Horizontal" Spacing="8" VerticalAlignment="Center">- <TextBlock Classes="SectionLabel" Text="MASTER" VerticalAlignment="Center"/>- <StackPanel Spacing="4" VerticalAlignment="Center">- <Panel x:Name="MasterVolHost" Width="120" Height="12"/>- <Panel x:Name="MasterMeterHost" Width="120" Height="6"/>- </StackPanel>+ <Button.Flyout>+ <MenuFlyout Placement="BottomEdgeAlignedLeft">+ <MenuItem Header="Instrument" Click="OnAddInstrumentClicked"/>+ <MenuItem Header="Audio" Click="OnAddAudioClicked"/>+ <MenuItem Header="Return" Click="OnAddReturnClicked"/>+ </MenuFlyout>+ </Button.Flyout>+ </Button>++ <!-- MIDI learn + an input-activity dot, so a silent controller is diagnosable -->+ <ToggleButton Grid.Column="6" x:Name="MidiLearnBtn" Classes="chip" Margin="8,0,0,0"+ Click="OnToggleMidiLearn"+ ToolTip.Tip="MIDI Learn — highlight mappable controls, click one, then move a knob on your controller">+ <StackPanel Orientation="Horizontal" Spacing="6" VerticalAlignment="Center">+ <TextBlock Text="MIDI" VerticalAlignment="Center"+ Foreground="{Binding $parent[ToggleButton].Foreground}"/>+ <Ellipse x:Name="MidiDot" Width="5" Height="5" VerticalAlignment="Center"+ Fill="{DynamicResource Brush.BorderStrong}"/></StackPanel>- </StackPanel>- </Grid>- </Border>+ </ToggleButton>- <!-- Toolbar (34): view switch + track adds | right: snap / automation / follow -->- <Border DockPanel.Dock="Top" Classes="Panel" Height="34" Padding="12,0">- <Grid ColumnDefinitions="*,Auto">- <StackPanel Orientation="Horizontal" Spacing="8" VerticalAlignment="Center">- <Border Classes="segmented">- <StackPanel Orientation="Horizontal" Spacing="2">- <ToggleButton x:Name="ArrangeBtn" Classes="seg" Content="Arrangement" IsChecked="True" Click="OnShowArrangement"/>- <ToggleButton x:Name="SessionBtn" Classes="seg" Content="Session" Click="OnShowSession"/>- <ToggleButton x:Name="ModularBtn" Classes="seg" Content="Modular" Click="OnShowModular"/>- </StackPanel>+ <Border Grid.Column="7" Width="1" Height="26" Margin="14,0"+ Background="{DynamicResource Brush.BorderDefault}"/>++ <!-- CPU: live DSP load -->+ <StackPanel Grid.Column="8" Spacing="3" VerticalAlignment="Center">+ <Border Width="52" Height="4" Background="{DynamicResource Brush.SurfaceAbyss}"+ CornerRadius="2" ClipToBounds="True">+ <Border x:Name="CpuFill" Width="0" HorizontalAlignment="Left" CornerRadius="2"+ Background="{DynamicResource Brush.Success}"/></Border>- <Border Width="1" Height="18" Background="{DynamicResource Brush.BorderDefault}"/>- <Button Classes="chip" Content="+ Instrument" Click="OnAddInstrumentClicked"/>- <Button Classes="chip" Content="+ Audio" Click="OnAddAudioClicked"/>- <Button Classes="chip" Content="+ Return" Click="OnAddReturnClicked"/>+ <TextBlock x:Name="CpuText" Classes="Mono CellLabel" Text="CPU 0%" FontWeight="Normal"/></StackPanel>- <StackPanel Grid.Column="1" Orientation="Horizontal" Spacing="8" VerticalAlignment="Center">- <Button x:Name="SnapChip" Classes="chip" Click="OnCycleSnap" ToolTip.Tip="Clip snap grid">- <StackPanel Orientation="Horizontal" Spacing="6" VerticalAlignment="Center">- <TextBlock Text="Snap" VerticalAlignment="Center"/>- <TextBlock x:Name="SnapLabel" Classes="Mono" Text="1/4" FontSize="10"- Foreground="{DynamicResource Brush.AccentBright}" VerticalAlignment="Center"/>++ <!-- Master: fader over its meter, with the gain in dB -->+ <Border Grid.Column="9" Height="42" Margin="12,0,0,0" Padding="10,0"+ Background="{DynamicResource Brush.BgApp}" CornerRadius="{StaticResource Radius.Sm}"+ VerticalAlignment="Center">+ <StackPanel Orientation="Horizontal" Spacing="9" VerticalAlignment="Center">+ <TextBlock Classes="CellLabel" Text="MST" VerticalAlignment="Center"/>+ <StackPanel Spacing="3" VerticalAlignment="Center">+ <Panel x:Name="MasterVolHost" Width="88" Height="12"/>+ <Panel x:Name="MasterMeterHost" Width="88" Height="5"/></StackPanel>- </Button>- <Border Classes="segmented">- <ToggleButton x:Name="AutomationToggle" Classes="seg" Content="Automation"- Click="OnToggleAutomation" ToolTip.Tip="Show parameter-automation lanes"/>- </Border>- <!-- Shown only while a hand-moved control has taken a lane over from- playback (M9-C); one click hands every overridden lane back. -->- <Button x:Name="ReenableAutoBtn" Classes="chip" Content="Re-enable Automation"- IsVisible="False" Click="OnReenableAutomation"- Foreground="{DynamicResource Brush.AccentBright}"- ToolTip.Tip="A control you moved is overriding its automation — click to hand it back"/>- </StackPanel>+ <TextBlock Classes="Mono" FontSize="10" MinWidth="46" TextAlignment="Right"+ VerticalAlignment="Center" Text="{Binding Transport.MasterDbText}"+ Foreground="{DynamicResource Brush.TextSecondary}"/>+ </StackPanel>+ </Border></Grid></Border>diff --git a/src/managed/Nota.App/MainWindow.axaml.cs b/src/managed/Nota.App/MainWindow.axaml.csindex ca7e0b54..67144561 100644--- a/src/managed/Nota.App/MainWindow.axaml.cs+++ b/src/managed/Nota.App/MainWindow.axaml.cs@@ -168,22 +168,23 @@ public partial class MainWindow : Window_masterMeter = new MeterBar(horizontal: true);MasterMeterHost.Children.Add(_masterMeter);- // Thin master volume fader (mockup 1b) — MiniFader instead of a stock Slider.+ // Thin master volume fader (mockup 1b) — MiniFader instead of a stock Slider. It+ // sits over the master meter inside the MST module, with the gain printed in dB.var masterVol = new MiniFader((double)vm.Transport.MasterVolume, 1.5);masterVol.ValueChanged += v => vm.Transport.MasterVolume = v;MasterVolHost.Children.Add(masterVol);MidiLearn.Bind(masterVol, MidiTarget.MasterVolume, "Master Volume");// BPM as a drag/type field (HANDOFF §4).- var bpmField = new DragNumber((double)vm.Transport.Bpm, 20, 300, 0.5, "0");+ var bpmField = new DragNumber((double)vm.Transport.Bpm, 20, 300, 0.5, "0", fontSize: 14);bpmField.ValueChanged += v => vm.Transport.Bpm = (decimal)Math.Round(v);BpmHost.Children.Add(bpmField);// Time signature: numerator drags 1–16; denominator snaps to a power of two.- var tsNum = new DragNumber(vm.Transport.TimeSigNumerator, 1, 16, 0.5, "0");+ var tsNum = new DragNumber(vm.Transport.TimeSigNumerator, 1, 16, 0.5, "0", fontSize: 14);tsNum.ValueChanged += v => vm.Transport.TimeSigNumerator = (int)Math.Round(v);TimeSigNumHost.Children.Add(tsNum);- var tsDen = new DragNumber(vm.Transport.TimeSigDenominator, 1, 16, 0.5, "0");+ var tsDen = new DragNumber(vm.Transport.TimeSigDenominator, 1, 16, 0.5, "0", fontSize: 14);tsDen.ValueChanged += v =>{int d = NearestPow2(v);@@ -195,6 +196,11 @@ public partial class MainWindow : Windowvm.Transport.PropertyChanged += (_, e) =>{if (e.PropertyName == nameof(vm.Transport.Bpm)) bpmField.Value = (double)vm.Transport.Bpm;+ // Opening a project restores the master gain on the view model; move the fader+ // with it so the handle and the dB readout beside it never disagree. Skipped+ // mid-drag, where the fader is the one driving.+ else if (e.PropertyName == nameof(vm.Transport.MasterVolume) && !masterVol.Dragging)+ masterVol.Value = vm.Transport.MasterVolume;else if (e.PropertyName == nameof(vm.Transport.TimeSigNumerator)) tsNum.Value = vm.Transport.TimeSigNumerator;else if (e.PropertyName == nameof(vm.Transport.TimeSigDenominator)) tsDen.Value = vm.Transport.TimeSigDenominator;};@@ -231,9 +237,10 @@ public partial class MainWindow : Window_patternView.SetPlayhead(beats - ppi.StartBeat, vm.Engine.IsPlaying);double load = Math.Clamp(vm.Engine.CpuLoad, 0, 1); // live DSP load (Phase 11)- CpuFill.Width = load * 56;+ CpuFill.Width = load * 52;CpuFill.Background = load > 0.9 ? cpuRed : load > 0.7 ? cpuAmber : cpuGreen;- CpuText.Text = ((int)Math.Round(load * 100)) + "%";+ CpuText.Text = "CPU " + (int)Math.Round(load * 100) + "%";+ SyncMidiDot();};// Recording tick fires ~60 Hz: refresh clip data + lane drawing only, WITHOUT// rebuilding the header cards — otherwise the input combobox and any open track/@@ -452,6 +459,7 @@ public partial class MainWindow : WindowSessionBtn.IsChecked = session;ModularBtn.IsChecked = modular;PlayBtn.Classes.Set("session", session); // play button turns green in Session (1c)+ LaunchQChip.IsVisible = session; // launch quantize only applies to Session launchesif (session) _session.Refresh();if (modular){@@ -506,11 +514,13 @@ public partial class MainWindow : Windowe.Handled = true;}- // Follow: keep the arrangement scrolling with the playhead during playback.- private void OnToggleFollow(object? sender, RoutedEventArgs e)+ // Snap on/off. Separate from the GRID cell, which only picks the denomination:+ // the latch is what you reach for to nudge something off-grid for a while.+ private void OnToggleSnapEnabled(object? sender, RoutedEventArgs e){- Timeline.FollowPlayhead = (sender as ToggleButton)?.IsChecked == true;- if (Timeline.FollowPlayhead) Timeline.RecenterOnPlayhead(); // jump to the cursor now+ bool on = SnapToggle.IsChecked == true;+ Timeline.SnapEnabled = on;+ if (_vm is not null) _vm.StatusText = on ? "Snap on" : "Snap off — clips position freely";}// MIDI Learn: arm/disarm the overlay and reveal the mappings tab so the user@@ -536,6 +546,22 @@ public partial class MainWindow : WindowSyncReenableAutomation();}+ // MIDI input activity: the dot on the MIDI button lights for ~250ms whenever the+ // learn service drains a control event, so a controller that is connected but silent+ // (wrong port, wrong channel) is visible without opening the mappings tab.+ private long _midiSeenCount;+ private DateTime _midiLastSeen = DateTime.MinValue;++ private void SyncMidiDot()+ {+ if (_learn is null) return;+ long n = _learn.EventCount;+ if (n != _midiSeenCount) { _midiSeenCount = n; _midiLastSeen = DateTime.UtcNow; }+ bool lit = (DateTime.UtcNow - _midiLastSeen).TotalMilliseconds < 250;+ var want = lit ? NotaPalette.Success : NotaPalette.BorderStrong;+ if (!ReferenceEquals(MidiDot.Fill, want)) MidiDot.Fill = want;+ }+/// <summary>Show the "Re-enable Automation" chip while any lane is overridden. Called/// from the ~30 Hz tick; the engine query is a cheap flag read.</summary>internal void SyncReenableAutomation()diff --git a/src/managed/Nota.App/MidiLearnService.cs b/src/managed/Nota.App/MidiLearnService.csindex 0eb3b1c9..09bd019d 100644--- a/src/managed/Nota.App/MidiLearnService.cs+++ b/src/managed/Nota.App/MidiLearnService.cs@@ -186,6 +186,11 @@ public sealed class MidiLearnServicereturn list;}+ /// <summary>Monotonic count of control events drained since start. The transport+ /// bar's activity dot lights while this keeps moving, so a connected-but-silent+ /// controller is diagnosable without opening the mappings tab.</summary>+ public long EventCount { get; private set; }+/// <summary>Forget the recorded controller activity (start a fresh discovery window).</summary>public void ClearRecentControls() => _seen.Clear();@@ -194,6 +199,7 @@ public sealed class MidiLearnServicepublic void Tick(){int n = _engine.PollMidiControlEvents(_buf);+ EventCount += n;for (int i = 0; i < n; i++){var kind = _buf[i * 4] == 0 ? MidiSourceKind.Cc : MidiSourceKind.Note;diff --git a/src/managed/Nota.App/PreferencesWindow.cs b/src/managed/Nota.App/PreferencesWindow.csindex 4e5eff1d..7ced2cda 100644--- a/src/managed/Nota.App/PreferencesWindow.cs+++ b/src/managed/Nota.App/PreferencesWindow.cs@@ -622,6 +622,7 @@ public sealed class PreferencesWindow : NotaWindow("Drag overview edge", "Zoom by resizing the viewport window"),("Double-click overview", "Fit the whole project on screen"),("Drag ⠿", "Reorder devices (◀ ▶)"),+ ("Drag clip + ⌥", "Position freely, ignoring the grid for this drag (the magnet in the transport latches the same thing)"),("Drag knob", "Change a device value · hold ⌘ or ⇧ for fine steps"),("Double-click knob", "Reset the value to its default"),("Drag jack → jack", "Patch a cable in Nota Consort · ⌥-click a jack to pull its cables"),diff --git a/src/managed/Nota.App/Theme/NotaPalette.cs b/src/managed/Nota.App/Theme/NotaPalette.csindex b57df3e8..c0e69a5b 100644--- a/src/managed/Nota.App/Theme/NotaPalette.cs+++ b/src/managed/Nota.App/Theme/NotaPalette.cs@@ -180,7 +180,7 @@ internal static class NotaPalette// =======================================================================// ---- Surfaces (both themes: the further forward, the lighter) ---------- public static readonly SolidColorBrush SurfaceAbyss = T("#0A0908", "#DCD6C5"); // deepest well (meter troughs)+ public static readonly SolidColorBrush SurfaceAbyss = T("#0A0908", "#DCD6C5"); // Brush.SurfaceAbyss — deepest well (meter troughs, transport console)public static readonly SolidColorBrush BgSunken = T("#100F0D", "#E4DFD1"); // Brush.BgSunken / ChromeBgpublic static readonly SolidColorBrush SurfaceDeep = T("#131210", "#E7E2D4"); // step-sequencer groundpublic static readonly SolidColorBrush CanvasBg = T("#121110", "#E9E5D8"); // modular canvas@@ -295,6 +295,7 @@ internal static class NotaPalette// are already live and should keep using the resource observable.)private static readonly Dictionary<string, SolidColorBrush> KeyMap = new(StringComparer.OrdinalIgnoreCase){+ ["Brush.SurfaceAbyss"] = SurfaceAbyss,["Brush.BgSunken"] = BgSunken, ["Brush.ChromeBg"] = BgSunken,["Brush.BgApp"] = BgApp, ["Brush.LaneB"] = LaneB,["Brush.SurfaceCard"] = SurfaceCard, ["Brush.SurfaceRaised"] = SurfaceRaised,diff --git a/src/managed/Nota.App/Theme/NotaTheme.axaml b/src/managed/Nota.App/Theme/NotaTheme.axamlindex 5a65a5f1..4d1d84f8 100644--- a/src/managed/Nota.App/Theme/NotaTheme.axaml+++ b/src/managed/Nota.App/Theme/NotaTheme.axaml@@ -42,6 +42,10 @@<ResourceDictionary x:Key="Dark"><!-- Surfaces -->+ <!-- The deepest surface: a recess cut into the chrome, used by the transport+ console so playback reads as one inset object (mockup 1b). Mirrors the+ NotaPalette.SurfaceAbyss slot the custom-drawn meters already use. -->+ <SolidColorBrush x:Key="Brush.SurfaceAbyss">#0A0908</SolidColorBrush><SolidColorBrush x:Key="Brush.BgSunken">#100F0D</SolidColorBrush><SolidColorBrush x:Key="Brush.BgApp">#171613</SolidColorBrush><SolidColorBrush x:Key="Brush.LaneB">#191814</SolidColorBrush>@@ -104,6 +108,7 @@<ResourceDictionary x:Key="Light"><!-- Surfaces (warm paper; forward still means lighter, wells go darker) -->+ <SolidColorBrush x:Key="Brush.SurfaceAbyss">#DCD6C5</SolidColorBrush><SolidColorBrush x:Key="Brush.BgSunken">#E4DFD1</SolidColorBrush><SolidColorBrush x:Key="Brush.BgApp">#EFEADE</SolidColorBrush><SolidColorBrush x:Key="Brush.LaneB">#E9E4D6</SolidColorBrush>@@ -272,7 +277,7 @@<Setter Property="BorderThickness" Value="1"/></Style><!-- Record engaged: translucent danger box, red glyph stays visible -->- <Style Selector="ToggleButton.tp-icon:checked /template/ ContentPresenter#PART_ContentPresenter">+ <Style Selector="ToggleButton.tp-icon.rec:checked /template/ ContentPresenter#PART_ContentPresenter"><Setter Property="Background" Value="{DynamicResource Brush.DangerSubtle}"/><Setter Property="BorderBrush" Value="{DynamicResource Brush.Danger}"/></Style>@@ -304,6 +309,20 @@<Setter Property="BorderThickness" Value="1"/></Style>+ <!-- Engaged chip (Click / Snap / Auto). The .chip Foreground above is a class+ selector declared after the generic ToggleButton:checked rule, so it wins on+ a checked chip and the brass ink never lands — most visible on Ember Paper,+ where secondary text on a brass wash is barely readable. State it here. -->+ <Style Selector="ToggleButton.chip:checked">+ <Setter Property="Foreground" Value="{DynamicResource Brush.AccentBright}"/>+ <Setter Property="FontWeight" Value="SemiBold"/>+ </Style>+ <Style Selector="ToggleButton.chip:checked /template/ ContentPresenter#PART_ContentPresenter">+ <!-- Same reason as the seg switch below: Fluent's checked template paints the+ presenter itself, which beats the control-level Foreground above. -->+ <Setter Property="TextElement.Foreground" Value="{DynamicResource Brush.AccentBright}"/>+ </Style>+<!-- bg-sunken well (position / BPM / time-sig) --><Style Selector="Border.well"><Setter Property="Height" Value="28"/>@@ -338,6 +357,45 @@<Setter Property="BorderThickness" Value="0"/></Style>+ <!-- Transport console (mockup 1b): a recess cut into the chrome holding the+ transport buttons, the position readout and the loop range, so playback reads+ as one object instead of three neighbours. -->+ <Style Selector="Border.console">+ <Setter Property="Height" Value="42"/>+ <Setter Property="Background" Value="{DynamicResource Brush.SurfaceAbyss}"/>+ <Setter Property="BorderBrush" Value="{DynamicResource Brush.BorderDefault}"/>+ <Setter Property="BorderThickness" Value="1"/>+ <Setter Property="CornerRadius" Value="{StaticResource Radius.Md}"/>+ <Setter Property="Padding" Value="11,0,13,0"/>+ <Setter Property="VerticalAlignment" Value="Center"/>+ </Style>++ <!-- Value-over-label readout cell (tempo / signature / grid / loop). No chrome of+ its own: the text carries the state, so the row scans as a strip of readouts+ rather than a queue of pills. -->+ <Style Selector="Button.cell, ToggleButton.cell">+ <Setter Property="Height" Value="34"/>+ <Setter Property="Padding" Value="7,0"/>+ <Setter Property="CornerRadius" Value="{StaticResource Radius.Sm}"/>+ <Setter Property="Background" Value="Transparent"/>+ <Setter Property="BorderThickness" Value="0"/>+ <Setter Property="Foreground" Value="{DynamicResource Brush.TextTertiary}"/>+ <Setter Property="VerticalAlignment" Value="Center"/>+ </Style>+ <Style Selector="Button.cell:pointerover /template/ ContentPresenter#PART_ContentPresenter,+ ToggleButton.cell:pointerover /template/ ContentPresenter#PART_ContentPresenter">+ <Setter Property="Background" Value="{DynamicResource Brush.SurfaceHover}"/>+ <Setter Property="BorderBrush" Value="Transparent"/>+ </Style>+ <!-- Checked keeps the flat ground; only the ink changes. -->+ <Style Selector="ToggleButton.cell:checked /template/ ContentPresenter#PART_ContentPresenter">+ <Setter Property="Background" Value="Transparent"/>+ <Setter Property="BorderBrush" Value="Transparent"/>+ </Style>+ <Style Selector="ToggleButton.cell:checked">+ <Setter Property="Foreground" Value="{DynamicResource Brush.AccentBright}"/>+ </Style>+<!-- Segmented control (Arrangement / Session view switch) --><Style Selector="Border.segmented"><Setter Property="Background" Value="{DynamicResource Brush.BgSunken}"/>@@ -529,6 +587,15 @@<Setter Property="FontWeight" Value="Bold"/><Setter Property="Foreground" Value="{DynamicResource Brush.TextTertiary}"/></Style>+ <!-- The tracked caption under a transport readout cell (BPM / SIG / GRID / LOOP).+ Smaller and dimmer than SectionLabel so the value above it leads. -->+ <Style Selector="TextBlock.CellLabel">+ <Setter Property="FontSize" Value="8"/>+ <Setter Property="FontWeight" Value="Bold"/>+ <Setter Property="LetterSpacing" Value="0.8"/>+ <Setter Property="LineHeight" Value="10"/>+ <Setter Property="Foreground" Value="{DynamicResource Brush.TextTertiary}"/>+ </Style><Style Selector="TextBlock.Mono"><Setter Property="FontFamily" Value="{StaticResource Font.Mono}"/></Style>diff --git a/src/managed/Nota.Presentation/ViewModels/TransportViewModel.cs b/src/managed/Nota.Presentation/ViewModels/TransportViewModel.csindex 4c4b9b94..eaba41fd 100644--- a/src/managed/Nota.Presentation/ViewModels/TransportViewModel.cs+++ b/src/managed/Nota.Presentation/ViewModels/TransportViewModel.cs@@ -4,6 +4,8 @@// M4.1-A: transport as the first MVVM slice. Wraps the engine's transport +// master behind observable properties and commands; the clock calls Tick().+using System;+using System.Globalization;using CommunityToolkit.Mvvm.ComponentModel;using CommunityToolkit.Mvvm.Input;using Nota.Application;@@ -23,10 +25,14 @@ public partial class TransportViewModel(IAudioEngine engine) : ObservableObject[ObservableProperty] private int _timeSigNumerator = 4;[ObservableProperty] private int _timeSigDenominator = 4;[ObservableProperty] private double _masterVolume = 1.0;+ [ObservableProperty] private string _masterDbText = "0.0 dB";[ObservableProperty] private bool _metronomeOn;[ObservableProperty] private bool _loopOn;[ObservableProperty] private string _loopRangeText = "1.1 – 5.1";[ObservableProperty] private bool _recordOn;+ /// <summary>Which clock the position readout is showing, printed under it so the+ /// number is never ambiguous (transport console, mockup 1b).</summary>+ [ObservableProperty] private string _positionUnitText = "bars";private bool _revertingRec;@@ -45,7 +51,15 @@ public partial class TransportViewModel(IAudioEngine engine) : ObservableObjectpartial void OnBpmChanged(decimal value) => _engine.SetBpm((double)value);partial void OnTimeSigNumeratorChanged(int value) => _engine.SetTimeSignature(value, TimeSigDenominator);partial void OnTimeSigDenominatorChanged(int value) => _engine.SetTimeSignature(TimeSigNumerator, value);- partial void OnMasterVolumeChanged(double value) => _engine.SetMasterVolume((float)value);+ partial void OnMasterVolumeChanged(double value)+ {+ _engine.SetMasterVolume((float)value);+ // Show the gain the fader is actually applying. Silence has no dB value, so it+ // gets the symbol rather than a very large negative number.+ MasterDbText = value <= 1e-4+ ? "-\u221e dB"+ : (20.0 * Math.Log10(value)).ToString("0.0", CultureInfo.InvariantCulture) + " dB";+ }partial void OnMetronomeOnChanged(bool value) => _engine.SetMetronome(value);partial void OnLoopOnChanged(bool value)@@ -144,6 +158,7 @@ public partial class TransportViewModel(IAudioEngine engine) : ObservableObjectpublic void ToggleTimeDisplay(){ShowTimeDisplay = !ShowTimeDisplay;+ PositionUnitText = ShowTimeDisplay ? "time" : "bars";UpdatePositionText(_lastBeats); // reflect immediately, don't wait for the next tick}