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
Implementation Plan: Two-column clip inspector and MIDI tools
Branch: cursor/clip-panels-two-columns-edc4 | Spec: spec.md | Issue: nota-daw/nota#276
Summary
UI only (src/managed/Nota.App); no engine, model or project-file change. The side panels keep
their sections as separate controls and a new host picks one or two columns at measure time from
the height it is given and the width it is offered.
Pieces
ClipEditor/PanelColumns.cs(no Avalonia, linked into the smoke test):Stack(sections plus gaps),BestSplit(the leading run that minimises the taller column, ties to the first column),Choose(one column if it fits / no width / a single section, else two).ClipPanelColumns.cs:SectionColumns: the sections in one or two equal columns, a 1 pxGraphBorderhairline centred in the gap between neighbours of a column (replaces theStackPanel+Rule()childrenClipEditorKit.Sectionsbuilt).ColumnFlow: a verticalScrollVieweraround the sections with an optional foot pinned below. Measure: foot at one-column width, each section at the column's inner width, thenPanelColumns.Choose; two columns are2 × ColumnWidth + borderwide (the panel, border included, doubles) and the column gap is the side padding plus the border, so a section has the same width in either layout and never reflows.Reserveis the width the editor canvas keeps.
ClipEditorKit:SectionsreturnsSectionColumns;Inspectorbuilds aColumnFlow(column 231 px + 1 px border = 232 px; two columns 464 px, padding 14/16/14/8, hint as the foot) and hands it back;Headertakes the inspector and keeps the clip cell at its width (SizeChanged); it also gives the inspector'sColumnFlowaBesidewidth (the rest of the header) thatPanelColumns.RoomForTwoweighs against the canvas reserve;MinCanvasW = 480;Rule()goes (unused).MidiToolsView: sections = [Generate / Transform + tool list], parameters, Output, spacing 10; foot = result line, Apply, Revert / Defaults; column 271 px + 1 px border = 272 px (544 px in two columns).- Editors: the body
Grid(Auto,*,Auto/Auto,*) becomes aDockPanel(inspector left, tools right, canvas fill), so the panels are measured with the real width (a GridAutocolumn measures with infinite width) and in order: inspector first, tools from what is left.ClipEditorView.SetToolssets the inspector'sReservetoMinCanvasW + ToolsWwhile Tools is open. - Re-layout: a section growing or shrinking changes the scroller's desired size whenever the choice could flip, which re-measures the host; no extra hook.
Audio-thread impact and architecture rules
None. Every change is in the Avalonia layout pass on the UI thread (Nota.App); nothing
touches the engine, the C ABI, the graph or the transport.
- AR-6 (no allocation, locks or I/O on the audio thread): the audio thread runs no new code.
- AR-5 (graph snapshots): no structural edit; the graph is not touched.
- AR-7 (pure C ABI): no new or changed
nota_engine.hcall. - No JUCE outside
pluginhost/: no native code changes. - AR-9 (
Transportis the only source of musical time): nothing reads or keeps time. - No new dependency.
Testing
- Smoke test
--clipeditor:PanelColumnscases (fits → one, overflow → two with the expected split, narrow → one, still too tall → two and scroll, lone section, best split, tie rule). - Full
scripts/build-linux.shsmoke run. - Screenshots of a short editor before / after (MIDI with Tools, audio).