Repository navigation
Add a headless gallery of the Schema editor - #269
Merged
Merged
Conversation
Ten pictures of the editor working on a small sample schema for a game: the File menu, a class's member grid, a member's metadata fold, the type and unit pickers, an enum, a code generator, the class graph, the diagnostics list and the theme browser. Each is an ordinary test in tests/Schema.Editor.UITests/Gallery that stages the editor through probe clicks and saves the rasterized frame, so every pull request proves each picture can still be staged. They write to a temporary directory unless SCHEMA_GALLERY_OUT names one, and a last test writes a captioned README.md beside them. Two runs produce byte-identical files. editor-gallery.yml runs them into docs/gallery after CI passes on main and commits the result back as github-actions[bot], following ImGuiApp's widget-gallery.yml: called from ci.yml rather than as a workflow_run, after the pipeline so the release commit is already on main, and refusing to commit a picture that is not an LFS pointer. No pictures are committed here; the first run on main writes them. Two seams in the editor, neither used outside a test. The right-hand tab bar comes from a widget library that records nothing, so MarkMainTabs records each tab as main-tab/<name> while a probe is listening, which is how the gallery reaches the class graph and diagnostics. And the class graph gains RequestFitToView, which the gallery calls so the picture shows the whole layout rather than whatever part of it lands on the canvas. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WWRBkw7bXdWGzuLpqnCvrB
Path.Combine discards everything before a rooted segment, which the code-quality check flags. None of these segments is rooted, so Join produces the same paths without the hazard. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WWRBkw7bXdWGzuLpqnCvrB
|
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.



Requested by Matt · project thread
Before: The repository had no pictures of the Schema editor. Seeing what it looks like meant building and running it.
After:
docs/gallery/will hold ten captioned pictures of the editor working on a small sample schema for a game. CI regenerates them frommainafter every passing build. The README links to the gallery. The pictures are:No pictures are committed here. LFS pushes are refused from the environment this was written in. The first run of the workflow on
mainwrites the PNGs anddocs/gallery/README.md. You can also get them earlier by dispatching Editor Gallery from the Actions tab.How: The gallery follows ImageGui's feature gallery.
tests/Schema.Editor.UITests/Gallery. It starts the real editor throughImGuiAppHarness, stages it with probe clicks, and saves the rasterized frame. Because they are ordinary tests, every pull request proves each picture can still be staged.SCHEMA_GALLERY_OUTnames one. A last test writes the captionedREADME.md..github/workflows/editor-gallery.ymlcopies the structure of ImGuiApp'swidget-gallery.yml. It is called from a neweditor-galleryjob inci.ymlafter the pipeline, for pushes tomainonly. It is not aworkflow_run. It commits as github-actions[bot] with[bot][skip ci], and refuses to commit any PNG that is not an LFS pointer.Refactor in the editor. Two small seams, neither of which changes what a user sees:
SchemaEditor.MarkMainTabs: the right-hand tab bar comes from a widget library that records nothing. This method records each tab asmain-tab/<name>, but only while a probe is listening. That is how the gallery reaches the class graph and the diagnostics list.ClassGraphView.RequestFitToView(): the gallery calls this so the class graph picture shows the whole layout. Nothing in the editor calls it yet. Whether users should get a "fit to view" control is a separate decision.SchemaEditor.ClassGraphis nowinternalso the gallery can reach it.CLAUDE.md now documents both seams and the gallery.
Verified locally:
🤖 Generated with Claude Code
https://claude.ai/code/session_01WWRBkw7bXdWGzuLpqnCvrB
Generated by Claude Code