Skip to content
Live, in your browser

This is not a video. It is the toolkit.

The app.rs from two of the repository’s examples, compiled byte for byte to WebAssembly. The same widgets, the same software rasteriser, the same damage tracker that drives a Raspberry Pi’s display, drawing into a canvas instead of a scanout buffer. Pink outlines are the rectangles it repaints.

Loading the toolkit (about 860 KB)…
0 frames drawn —

Things to try

1 Click the Name field and type

The on-screen keyboard comes up, because that is what a panel with nothing plugged into it does; the key at its bottom right puts it away. Your real keyboard types too — and only the field and its caret repaint.

2 Tab into a field, then double-click a word

Focus offers the whole value for replacement; a press places the caret, a second takes the word under it, a third takes the field. Ctrl or Option and an arrow move by word, and ⌘C, ⌘X and ⌘V go through the application.

3 Drag the R, G or B slider

A seed colour changes, the theme is derived again, and everything repaints, because every widget names a role rather than a colour.

4 Turn off “Awake”

The spinner stops asking for frames. What is left is the wall clock, which asks to be woken exactly when the next second starts.

5 Open “Choose a mode”

A popup is a scene above the tree, and Escape or a click outside closes it. Tab and the arrow keys work everywhere.

6 Press F2

The built-in themes, cycled — the same key the example binds on a desktop. The Light, Dark and Contrast buttons above do it from the page instead.

7 Scroll the right-hand column

It is a viewport, and scrolling is the tree’s job: wheel, page keys, touch-drag, clipping and hit testing all agree because one reflow computes them.

How this runs

  • A third backend beside the window and the kiosk ones: site/wasm, about three hundred lines, pulls in gallery/app.rs and table-editor/app.rs by path.
  • Built for wasm32-wasip1, so the applications keep using std::time. The page supplies a clock and nothing else. No wasm-bindgen, no JavaScript UI.
  • Each frame, the page copies only the damaged rectangles onto the canvas, the way a DRM backend presents only what changed.
  • Between frames nothing runs. The page sleeps until the tree’s next deadline, or until you touch it, and stops entirely when the demo scrolls out of view.
  • Text is Noto Sans through the TrueType tier. Prefers reduced motion? The toolkit gets Motion::None.