Repository navigation
Ariadne: autofocus, password fields, ImGui horizontal rows and grid ids, tvision refit, no scene chrome without a scene - #906
Merged
Conversation
…ImGui, tvision refit, no scene chrome without a scene
What nicotina M0 hit in the widgets and backends:
- An unnamed grid (no id:, no label:) gets an id from its place in the
tree ("~0_2_1"), so two in one window no longer share one ImGui table
("###grid.") or one tree.<id> key.
- ImGui: a layout {kind: horizontal} row with no col_widths puts its
cells side by side (a group per cell, SameLine) instead of a
one-column table. col_widths, borders and resizable keep the table.
- tvision host: a window the document did not size refits its content
on every walk, per axis, until the user resizes it (ARIADNE.md 5.8).
- autofocus: true on a widget gives it focus when it appears (first
drawn, or back after a frame without it): Backend::focus_next_widget,
FTXUI/tvision move their focus to the next focusable leaf, ImGui
calls SetKeyboardFocusHere.
- password: true on an input_text masks it: ImGui's Password flag, a
bullet per character in the terminal backends. Masking only; the
value is still the bound state key's.
- arigl: a document without scene: hides the view's diagnostic chrome
(grid, axes, bounds box); the next document's load restores the
host's setting (SceneAdapter::no_scene).
transfix
enabled auto-merge (squash)
October 30, 2026 08:33
transfix
disabled auto-merge
October 30, 2026 08:33
transfix
enabled auto-merge (squash)
October 30, 2026 08:34
The FTXUI test's "•" literal is encoded in MSVC's code page (the test target has no /utf-8), so it never matched the screen's UTF-8 and PasswordFieldShowsAMask failed on Windows. Spell U+2022 as its bytes, as the other tests do, in the test and in the backend.
…widget-gaps # Conflicts: # docs/ARIADNE.md # inc/cvc/ariadne/ftxui_backend.h # inc/cvc/gl/ariadne/ImGuiBackend.h # src/cvc/ariadne/ftxui_backend.cpp # src/cvcGL/ariadne/ImGuiBackend.cpp
transfix
added a commit
to cy-pca/nicotina
that referenced
this pull request
Oct 31, 2026
input_text's password: true (transfix/libcvc#906, merged) draws a bullet per character in both terminal backends and ImGui's password field in a window. The value still passes through login.password while it is typed, and the controller still clears it as soon as it is sent. An older host ignores the key and shows the text. Every suite now captures the screen with the password typed: it must show bullets, and the secret scan makes sure the text never appears. A probe in tests/lib.sh skips the check on an ari that doesn't mask.
transfix
added a commit
to cy-pca/nicotina
that referenced
this pull request
Oct 31, 2026
autofocus: true (transfix/libcvc#906) on the sign-in form's Username and the two-step Code field, each time the form opens, so a person types at once. The layout groups lose their ids and the button rows their col_widths, which #906 made unnecessary (unnamed grids get distinct ids; ImGui flows a horizontal row). The fixed 62-column width and the always-present status row stay, for the tvision host: it refits a window that opens, but a window that closes and opens again in the same run (the sign-in form after signing out) comes back at its first size, so a new status line would be cut off. The tmux key sequences drop the Tab that used to reach the first field; on a host without #906, form_focus in tests/lib.sh sends it. A focused field draws its cursor after the text, so the tests match a field by its start.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes six widget and backend gaps that nicotina M0 (cy-pca/nicotina) hit. Each was worked around in nicotina's documents. This PR is independent of #887 and #888.
The fixes
id:orlabel:went to the backend as"", so every unnamedtype: groupwith alayout:became ImGui's###grid.. The second one in a window shared the first one's table and drew itsautocolumn one character wide.~0_2_1). Backend state is keyed by that name, and so aretree.<id>.tracks/.columns. The name is a single state-path segment.col_widths.layout: {kind: horizontal}with nocol_widthswas a one-column table, so a button row stacked vertically in ImGui while FTXUI laid it out side by side.SameLine. Rows withcol_widths,bordersorresizablestay tables.size:fits its content every frame.autofocus: true(any widget).visible_whentrue again, a newrepeat:instance. It does not hold focus.Backend::focus_next_widget()has a no-op default. FTXUI (and so tvision) focuses the next focusable leaf. ImGui callsSetKeyboardFocusHere().password: true(oninput_text).ImGuiInputTextFlags_Password, which also blocks copy and cut. The terminal backends show one•per character.Backend::input_textgains amaskedargument.scene:.AppRuntime::loadnow calls a newSceneAdapter::no_scene()for such a document, and arigl's adapter hides the chrome. The next load restores the host's setting. A document with ascene:still controls the chrome itself (scene.chrome), and the Settings menu can still turn it on.The loader and the embedded schema accept
autofocusandpassword. docs/ARIADNE.md is updated in §4 and §5.8, the grid-sizes paragraph in §7.1, the golden-test gaps note, and a new §5.10 on forms.Tests
ariadne_runtime_test, new tests:UnnamedGridsInOneWindowGetDistinctIds: distinct ids, one path segment, stable from frame to frame, and a named grid keeps its id.AutofocusTakesFocusWhenTheWidgetAppears: one request when the field appears, none while it stays, another after it is hidden and shown again.PasswordFieldReachesTheBackendMasked.EachLoadClearsTheLastScenenow expectsno_scenefor a document without a scene.ariadne_ftxui_test, new tests:AutofocusFieldTakesTheFirstKeys: typing with no Tab edits the field.PasswordFieldShowsAMask: the text is not on screen, the bullets are, and the state holds the text.Ariadne|ari, 593 tests (the regex also takes in some state_exec lock tests), all pass. Under-j16the twoLocksStress.LK18_RandomOperationsKeepInvariantsstress tests ran past the 300 s timeout; alone they pass (337 s and about 350 s). This PR does not touch that code.arigl snapshotof a widget-only document shows no grid, axes or box.arigl snapshotcaptures the VTK view without the ImGui overlay. They compile, and the core side is covered by the runtime tests.Follow-up
capture_authdoes for tokens).