Repository navigation
Ariadne windows: close and maximize buttons by default, restore glyph, manual resize ends a maximize - #1220
Merged
Conversation
…, manual resize ends a maximize Window chrome now behaves like a desktop window manager: - closable: defaults to true, like maximizable:. Every window's title bar ends with a maximize button and then the close X; `closable: false` / `maximizable: false` turn either off. A document with no menubar: gets the Windows menu bar so a closed window can come back (as it already did for a closable window). - ImGui: a maximized window can be moved and resized again. Dragged by its title bar past the drag threshold it leaves the maximized state and comes back at its own size under the pointer, held where along the title bar it was grabbed. Resized by an edge or a corner, it leaves it at the size it was given, which becomes its own: a later maximize then restore comes back to it. A double click on the title bar toggles maximize (ImGui's collapse on a double click stays on phones). The restore glyph draws only the visible edges of the square behind, so a hovered button stays lit; the buttons have Close / Maximize / Restore tooltips. - FTXUI: a maximized window dragged by its title bar is restored under the pointer. Tests: cvcgl_imgui_maximize covers the default buttons, the opt-outs, the glyph and tooltips, a double click, a corner resize then maximize and restore, a title drag and the close button; ariadne_ftxui_test the title drag. Placement tests whose windows were assumed to have no close button say closable: false. The goldens are remade under llvmpipe (every window has its buttons; documents with no menubar: show the Windows menu bar).
…front Picking a window in the Windows menu now shows it in front, as a window manager's Windows menu does: a closed one opens, and an open one stays open and is raised (its X closes it). Before, a ticked item closed the window, and only repeat: windows were raised when reopened. A window that becomes maximized (its button, a double click, or the document writing tree.<id>.maximized) comes to the front the frame it is first drawn maximized. FtxuiBackend implements focus_next_window (the top of its stack; hosted mode leaves stacking to the host).
A window's resizable: key (default true, like closable: and maximizable:) says whether the user may resize it by an edge or a corner. It is the window's own key; a resizable: inside its layout: stays the layout's. An include site may set it too. The core passes it to the backend before each begin_window (Backend::next_window_resizable): - ImGui: ImGuiWindowFlags_NoResize; a corner drag moves the window. - tvision: no wfGrow, so no resize corner and Ctrl-F5 only moves it. - FTXUI draws no resize handle, so nothing changes there. The tvision desktop now brings a window to the front when the core raises it (picked in the Windows menu, or tree.<id>.raise): hosted FtxuiBackend reports HostedWindow::raise for that walk, and the host selects the window. ARIADNE.md: section 5.9 is now "Window chrome" and covers resizable:, bringing a window to the front (tree.<id>.raise, documented for the first time), and the Windows menu. Section 4's FTXUI and tvision notes, section 5.8's resizing, and section 6's include-site window keys are brought up to date.
macOS CI's Apple Software Renderer (run 43581219990, all four lanes identical) draws widgets and scene with the Windows menu bar and the close and maximize glyphs, so widgets.macos.png and scene.macos.png are refreshed from its actual frames. grid now leaves 15 px beyond the tolerance there (13 allowed), so it gets grid.macos.png as well.
…ter's tests do Master's load_string takes the app; the test came from before that.
This was referenced Nov 15, 2026
transfix
added a commit
that referenced
this pull request
Nov 16, 2026
v4.0.0's publish-cvcpkg run (43754890264) failed all five release ari-media jobs on the player check. #1220 made windows closable by default, so media_player.ari now gets the built-in Windows menu bar. In a 60x14 snapshot that pushes the Player window down, and the window's own scrollbars hide its last line, the status the check greps for (video ready/playing, audio ready/playing). The clip and tone open; only the line is out of view. With 20 rows the status line shows (checked with a local ari snapshot at 14 and 20 rows). The Linux, macOS and Windows lanes change alike.
transfix
added a commit
that referenced
this pull request
Nov 16, 2026
…nubar (#1288) ari-media 4.0.0 did not publish on linux arm64 or macOS x86_64 (publish-cvcpkg run 43754890264). Its player smoke takes a 60x14 snapshot of src/ari/tests/media_player.ari and greps the window's last row, the status line. Since #1220 put a Windows menubar and a blank row above every document's windows, that row no longer fits in 14 rows. The snapshot still shows both players opened (0:02 and 0:01). The Linux, macOS and Windows lanes now snapshot at 60x18. The new AriMedia.TheLeanAriFitsThePlayerInThePublishSmoke takes the same snapshot with the lean ari, so CI, which builds no ari-media, catches the next change to the chrome above the window before a publish does.
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.
Window chrome in Ariadne now works like a desktop window manager (Windows, macOS).
What changes
closable:now defaults totrue, asmaximizable:already did. A window's title bar ends with the maximize button and then the close X.closable: falseandmaximizable: falseon a window turn either off (in a document, an include site, orWidget::closablein C++). A document with nomenubar:gets the built-in Windows menu bar so a closed window can come back. That rule is unchanged; it now applies to most documents.NoMove | NoResize.[↑]/[↕]beside[x]. tvision keeps its own zoom box.resizable:(default true). A window's own key, likeclosable:andmaximizable:(aresizable:insidelayout:stays the layout's), also settable at an include site. The core passes it before eachbegin_window(Backend::next_window_resizable). ImGui:NoResize, so a corner drag moves the window instead. tvision: nowfGrow, so no resize corner, and Ctrl-F5 only moves it. FTXUI draws no resize handle, so nothing changes there.closable: falsewindow can't be closed from the menu. A window that becomes maximized (its button, a double click, or the document writingtree.<id>.maximized) also comes to the front.FtxuiBackendnow implementsfocus_next_window. In hosted mode it reportsHostedWindow::raisefor that walk, and the tvision desktop selects the window.size:.resizable:, the maximize behaviour, bringing a window to the front (tree.<id>.raise, which had no docs before), and the Windows menu. §4's FTXUI and tvision notes, §5.8's resizing, and §6's include-site window keys are brought up to date.Tests
cvcgl_imgui_maximize(bare ImGui context, real mouse input) adds checks for:ariadne_ftxui_test:AMaximizedWindowDraggedByItsTitleIsRestoredandTheWindowsMenuAndMaximizeBringAWindowToTheFront; hosted:TheHostKnowsWhichWindowsResize,TheHostRaisesAWindowOnce.ResizableWindow(window key vs layout key, include site). Runtime:ANonResizableWindowTellsTheBackend.cvcgl_imgui_maximize: aresizable: falsewindow keeps its size when its corner is dragged, and a default one grows.cvcgl_imgui_windows_menu: a window opened from the menu is in front and has the keys; picking an open window raises it and leaves it open; a window the document maximizes comes in front.AWindowComesToTheFrontWhenItIsMaximized, andWindowsMenuReopensAClosedWindownow expects a pick to raise rather than close.closable: false, so their windows keep the full view:cvcgl_imgui_window_fit,_ui_size,_view_shrink, and a few FTXUI graphics tests.windows.ari's "Closable" window became "No buttons", to show the opt-out. The widgets pointer script moved 22 px down onto Reset, under the new bar.widgets.macos.pngandscene.macos.pngare refreshed, andgrid.macos.pngis new, from the macOS golden job's*.actual.pngartifacts (ci/full run 43581219990 on 0e43f98; all four macOS lanes drew the same frames, which match the llvmpipe goldens' layout). Apple's renderer now leaves 15 px beyond tolerance on grid (13 allowed), so grid has its own macOS golden. Master is merged in (34b3eb3, for itsload_string(app, ...); the new loader test now usesfresh_load, ad77f83), and the macOS re-check is ci/full run 43636956868 on ad77f83. tvision isn't built locally: its change (wfGrow,select()on raise) is checked by Linux CI only.Checked locally on Windows Release, with FTXUI from cvcpkg so the terminal tests ran:
ariadne_runtime_test267,ariadne_loader_test229,ariadne_ftxui_test95,cvcgl_imgui_maximize,cvcgl_imgui_windows_menu, the three placement tests andcvcgl_ari_golden34/34;AriMediatruecolour checks that fail the same way ascvcgl_terminal_scene: this non-terminal Windows shell yields no 24-bit colour from FTXUI. They don't involve this change.arigl snapshotof a test document shows both buttons by default, the opt-outs, and the restore glyph on a maximized window, in GL and with--terminal.Clang-format: changed lines only (git-clang-format, clang-format 18.1.8).