Skip to content

dvui: run-dvui on dvui.osWindow, plain dvui code - #5

Draft
foxnne wants to merge 1 commit into
mainfrom
dvui/os-window
Draft

foxnne wants to merge 1 commit into
mainfrom
dvui/os-window

Conversation

@foxnne

@foxnne foxnne commented Oct 10, 2026

Copy link
Copy Markdown
Contributor

Part of fizzyedit/fizzy#281. Draft: it pins fizzy at fizzyedit/fizzy#366's commit, and gets repinned to main once that merges.

run-dvui is now plain dvui code. It opens its windows with dvui's own dvui.osWindow(...): a title, a size, a min size, an open_flag. On fizzy's backend each becomes an OS window drawn from the one dvui.Window, with dvui's header and close button and no OS title bar (fizzyedit/fizzy#366). There's no viewports code in the app any more: about 270 lines of windowing became about 100 lines of ordinary dvui (−236 / +43).

dvui's demo stays a floating window in the main window, as it is in dvui's own example app. Only dvui.osWindow asks for an OS window.

-Ddvui-backend=sdl3: the same code on dvui's own SDL3 backend, where dvui.osWindow opens a dvui.Window of its own, as dvui does anywhere.

Verification, macOS, from the URL pin:

  • zig build dvui on both backends, the studio shape and replay build.
  • On fizzy's backend, two windows open as OS windows of their own, cascaded 24 pt apart over the main window. No warnings, and it quits cleanly on SIGTERM.

🤖 Generated with Claude Code

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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