docs: the badge bar, the slide-over and the dock (step 1 of the redesign)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
a1672acc70
commit
0c94caf866
7 files changed
+203
-70
No files matched your search
@@ -1,6 +1,6 @@
|
||||
# Invariants: the plot, the figure and the layout
|
||||
|
||||
How `plot::Figure`/`plot::Plot` may and may not be driven, what a row's state belongs to, the layout editor's overlay, and the rule that layout must not depend on content.
|
||||
How `plot::Figure`/`plot::Plot` may and may not be driven, what a row's state belongs to, the layout editor's and the slide-over's overlay children, and the rule that layout must not depend on content.
|
||||
|
||||
Part of [CLAUDE.md](../../CLAUDE.md). These are rules that cost a defect to learn; read the ones touching the area you are editing before you edit it.
|
||||
|
||||
@@ -97,6 +97,31 @@ Part of [CLAUDE.md](../../CLAUDE.md). These are rules that cost a defect to lear
|
||||
an equal division. `sync_layout_editor()` runs every frame on purpose:
|
||||
`gtk_widget_set_margin_*()` returns early on an unchanged value, so a settled layout costs
|
||||
the comparisons and nothing else, and a resize needs no notification.
|
||||
- **The slide-over is the second thing placed over the plot, and it is one opaque widget, not a
|
||||
transparent area.** The same pick rule as the editor's buttons applies, harder: the panel is a
|
||||
`GtkRevealer` aligned to the end edge (`halign=END`, `valign=FILL`) at `kSlideOverWidth` = 360 px, so
|
||||
its allocation *is* the part of the plot it covers and everything to its left is still the plot's --
|
||||
pan, zoom, drop and hover are untouched. A full-area child with a panel drawn in it would swallow all
|
||||
of them. Closed, the revealer is `can_target(FALSE)` (and `gtk_overlay_set_clip_overlay()` keeps its
|
||||
slide-out inside the plot), so the frames of a slide-out do not eat input either. `[slideover]` reads
|
||||
it back: `outside_hits_plot=1 inside_hits_panel=1`. Three consequences:
|
||||
the panel **never resizes the plot** (it is an overlay child; `plot_unchanged=1`), its height is the
|
||||
plot's and never the page's (each page has a `GtkScrolledWindow` with a `NEVER` horizontal policy that
|
||||
does not propagate its child's height), and content that is taller than the plot -- the trigger form
|
||||
on a 470 px window -- scrolls inside the panel instead of growing it. The widgets that go in a page
|
||||
are reparented into it; their widths must fit 360 minus the border (the trigger form measures 267
|
||||
minimum, the E-1608's panels 197).
|
||||
- **The badge bar has a fixed height and sits outside the overlay.** `badge_bar` is 36 px
|
||||
(`height-request`) between `plot_overlay` and the status line, so the plot above it never moves when a
|
||||
badge's text changes (`bar_h` = `bar_h_after` in `[badges]`). This is "layout must not depend on
|
||||
content" for the new row: a badge's state is a word from a short fixed set and the Source badge's name
|
||||
is a kind's display name, so what changes with the stream is the row's *width* (the bar has room to
|
||||
spare on the right) and never its height. The badge labels are not ellipsized: a name long enough to
|
||||
need it would be a defect of the kind's `display_name()`. Rows that appear by trigger condition appear
|
||||
inside the slide-over's scroller, never in the bar.
|
||||
- **The dock's width is fixed too** (`side_column` `width-request` 300, the split view's 320 px floor
|
||||
and cap), and it holds one scroller with the signal list, the cursors and the measurements. A
|
||||
section's visibility is never what makes the dock taller; the scroller is what absorbs the extra.
|
||||
- **Trace slots are identified by signal name, not channel index.** Enabling a signal
|
||||
or a new CONFIG renumbers the channel list, so an index would silently re-point a
|
||||
trace at another signal.
|
||||
|
||||
Reference in new issue
Block a user