Skip to content

ariadne: tabs: and list: widgets, a tab bar bound to a key and an editable list (P7) - #1254

Merged
transfix merged 6 commits into
masterfrom
p7/widgets
Nov 17, 2026
Merged

transfix merged 6 commits into
masterfrom
p7/widgets

Conversation

@transfix

Copy link
Copy Markdown
Owner

The third piece of P7 (docs/roadmap/VOLROVER-LIBRARY-PORTS-ROADMAP.md §6 item 5): the side-panel widgets VolumeGridRover's component needs that were missing. I checked the backend first: color: (an r,g,b key) and radio: / radio_row: already existed, and repeat: existed with no way to add or remove rows. This PR is independent of #1249 and #1251 (based on master).

What lands

  • tabs:, a tab bar bound to a key.
    • Over its children: it is a tab container. Each child is one tab, titled by its tab:, else its label:, else its place, and only the selected tab's subtree is walked.
    • Over options: alone (with values:, as a radio takes them) it is a switch, e.g. the XY / XZ / ZY view switch.
    • A write to the key from anywhere selects that tab, and on: runs after a pick.
    • Without bind: the selection is kept at tree.<id>.tab.
  • list:, the rows of a state array as repeat: counts it: the count at bind:, rows at <bind>.<i>, each row showing its field: (default name).
    • A click writes the row's index to current: (default <bind>.current).
    • add: true appends a row from new_item: ({n} is its number from 1) and selects it.
    • remove: true deletes the selected row, moving the rows after it up (whole subtrees).
    • on_add: / on_remove: run after an edit; rows: sets the visible height.
  • Backends: Backend::tab_bar and Backend::list. Their defaults draw radios and buttons, so the FTXUI and tvision hosts show both with no code of their own. ImGuiBackend draws a real tab bar, which follows writes from outside, and a list box with Add and Remove (Remove disabled with nothing selected).
  • C++ and repeats: widget.h gains tabs(), tab_bar() and list() builders, and {i} reaches the new fields inside a repeat:.
  • Docs: ARIADNE.md §5.3, the roadmap's §6 item 5.

Tests (Windows Release)

  • New tabs_list_test, a port test, so it also runs in the ports (wasm-mt, node) lane:
    • the selected subtree, pick to key, outside write, per-widget selection;
    • the switch with values;
    • list select / add ({n}) / remove with nested fields shifted, clamping, on_add / on_remove;
    • the radio-and-buttons fallback;
    • the loader's keys, titles and warnings.
    • 6/6 natively. As wasm-mt under node, 5 pass and the loader case skips, because that lane's libcvc has no yaml-cpp.
  • New cvcgl_imgui_tabs_list: clicks through ImGui's own input on a tab, a row, Add, Remove, and disabled Remove. Passes.
  • Still passing: ariadne_loader_test (229), ariadne_runtime_test (278), cvcgl_imgui_radio.

No new or renamed CI jobs. clang-format is clean on the changed lines.

…table list (P7)

The side-panel widgets of docs/roadmap/VOLROVER-LIBRARY-PORTS-ROADMAP.md §6 item 5 that were
missing (color: and radio: / radio_row: were already there).

- tabs: a tab bar bound to a key. Over its children it is a tab container (each child one tab,
  titled by its tab:, else its label:, else its place; only the selected tab's subtree is
  walked); over options: alone, with values:, a switch. A write to the key from anywhere selects
  that tab; on: runs after a pick. Without bind: the selection is kept at tree.<id>.tab.
- list: rows of a state array as repeat: counts it (count at bind, rows at bind.<i>), each row
  showing its field: (name). A click writes the row's index to current: (default
  bind.current); add: appends a row from new_item: ("{n}" its number) and selects it; remove:
  deletes the selected row, moving the rows after it up (whole subtrees); on_add / on_remove.
- Backend::tab_bar and Backend::list, whose defaults draw radios and buttons, so FTXUI and
  tvision show both; ImGuiBackend draws a real tab bar (following outside writes) and a list box
  with Add and Remove. widget.h gains tabs(), tab_bar() and list() builders; {i} reaches the new
  fields in a repeat:.
- Tests: tabs_list_test (a port test: native, and wasm-mt under node with the loader case
  skipped there for want of yaml-cpp), cvcgl_imgui_tabs_list (clicks through ImGui's own input).
- Docs: ARIADNE.md §5.3, the roadmap's §6 item 5.
Master's #1249 added volume_slice_test where this branch adds tabs_list_test, at the end of CVC_PORT_TESTS in src/cvc/tests/port_tests.cmake; both are kept.
@transfix
transfix merged commit 7e6290e into master Nov 17, 2026
51 of 52 checks passed
@transfix
transfix deleted the p7/widgets branch November 17, 2026 01:48
transfix added a commit that referenced this pull request Nov 17, 2026
One conflict, in ci.yml's SAN_CXX_TESTS: this branch added stream_test, net_ws_client_test and
ariadne_host_test to the sanitizer legs' list, and #1292 added gradient_vector_diffusion_test,
critical_points_test and seed_generators_test (reflowing the lines). Kept both.

ci.yml's line 1271 (the arigl-web path filter's files.h/files.cpp line) also goes back to master's
bytes: master stores ci.yml with CRLF but that one line LF-only, and an earlier merge here had
given it a CR, a whitespace-only change in this PR's diff.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant