docs: the manual and the user guide describe the badge bar, the dock and the slide-over pages

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Martino FerrariandClaude Sonnet 4.6 committed 2026-11-03 07:28:16 +01:00
1 parent 86ea0bac38
commit 328588a8b9
16 files changed
+180 -113

No files matched your search

+27 -17
View File
@@ -18,9 +18,9 @@
# * `xdotool search --name udpscope` finds nothing: GTK4 sets no WM_NAME on the X window it
# creates, so windows are found by their geometry, not their name.
#
# Box provenance: the sidebar width is read from the app's own probe dump (`side=NNNx`), so the
# side-panel box tracks the real widget; the header and status bands are the table in
# `window_boxes` below, each named where it is used, because the dump reports neither.
# Box provenance: the dock's width is read from the app's own probe dump (`side=NNNx`), so the
# dock box tracks the real widget; the header, badge-bar and status bands are the table below,
# each named where it is used, because the dump reports none of them.
#
# Usage: tools/make-help-shots.sh [OUTPUT_DIR] (default help/C/<id>/figures)
set -euo pipefail
@@ -41,23 +41,29 @@ done
mkdir -p "$out"
# --- the window's own geometry, and the boxes it is annotated with -------------
# main-window.ui asks for 1280x800, and the sidebar is a fixed 320 px
# (sidebar-width-unit=px, min=max=320). The header bar is the window's titlebar and the status
# row sits at the foot of the plot column; neither reports a pixel height, so their bands are
# the third measurement -- a pixel scan of a grab, 51 px and 43 px on the current theme -- and
# are refreshed by re-measuring if the styling changes.
# main-window.ui asks for 1280x800, and the dock is a fixed 280 px (the split view's sidebar,
# min=max=280), leaving a 1000 px plot column. The header bar is the window's titlebar, and the
# badge bar and the status row sit at the foot of the plot column, the badge bar over the status
# row; none of them reports a pixel height, so their bands are a pixel scan of a grab -- 51 px,
# 36 px and 43 px on the current theme -- and are refreshed by re-measuring if the styling
# changes. The plot is what is left between the header and the badge bar.
WIN_W=1280
WIN_H=800
HEADER_H=51
BADGES_H=36
STATUS_H=43
PLOT_W=952
PLOT_W=1000
PLOT_H=$((WIN_H - HEADER_H - BADGES_H - STATUS_H))
BADGES_Y=$((HEADER_H + PLOT_H))
STATUS_Y=$((BADGES_Y + BADGES_H))
boxes_main="header bar:0:0:$WIN_W:$HEADER_H
side panel:SIDE_X:$HEADER_H:SIDE_W:706
plot:0:$HEADER_H:$PLOT_W:706
status bar:0:757:$PLOT_W:$STATUS_H"
boxes_trigger="event held, axis pinned to the event:0:757:$PLOT_W:$STATUS_H
the trigger marker at x = 0:0:$HEADER_H:$PLOT_W:706"
plot:0:$HEADER_H:$PLOT_W:$PLOT_H
badge bar:0:$BADGES_Y:$PLOT_W:$BADGES_H
dock:SIDE_X:$HEADER_H:SIDE_W:$((WIN_H - HEADER_H))
status bar:0:$STATUS_Y:$PLOT_W:$STATUS_H"
boxes_trigger="event held, axis pinned to the event:0:$STATUS_Y:$PLOT_W:$STATUS_H
the trigger marker at x = 0:0:$HEADER_H:$PLOT_W:$PLOT_H"
boxes_math="the graph editor:8:8:EW-24:EH-24"
display=
@@ -88,6 +94,10 @@ export GDK_BACKEND=x11 GSK_RENDERER=cairo LIBGL_ALWAYS_SOFTWARE=1
tmp=$(mktemp -d)
trap 'cleanup; rm -rf "$tmp"' EXIT
export XDG_CONFIG_HOME="$tmp/config" XDG_CACHE_HOME="$tmp/cache" XDG_DATA_HOME="$tmp/data"
# A first run starts the guided tour 1.5 s in, and a tour card over the plot is not what the figures
# show: say the tour has been offered, the way a second run of the app would find it.
mkdir -p "$XDG_CONFIG_HOME/udpscope"
printf 'tour_seen = true\n' >"$XDG_CONFIG_HOME/udpscope/settings.toml"
python3 "$mock" --port "$port" --rate 10000 --batch 100 >"$tmp/mock.log" 2>&1 &
mock_pid=$!
@@ -136,14 +146,14 @@ stop_app() {
app_pid=
}
side_of_dump() { # LOGFILE -> the sidebar width the app reports, else the table's 320
side_of_dump() { # LOGFILE -> the dock width the app reports, else the table's 280
local s
s=$(grep -o 'side=[0-9]*x' "$1" 2>/dev/null | head -1 | grep -o '[0-9]*' || true)
echo "${s:-320}"
echo "${s:-280}"
}
# annotate NAME RAW LOG BOXES W H -> the figure, with a numbered box per line of BOXES.
# A box is `label:x:y:w:h`; `SIDE_X`/`SIDE_W` are the sidebar's own numbers, `EW`/`EH` the
# A box is `label:x:y:w:h`; `SIDE_X`/`SIDE_W` are the dock's own numbers, `EW`/`EH` the
# grabbed window's width and height.
annotate() {
local name=$1 raw=$2 log=$3 boxes=$4 win_w=$5 win_h=$6