moonetui — a terminal UI toolkit for MoonBit (after Textual): cell buffer, differential ANSI renderer, incremental key parser, layout, widgets, and pluggable terminal drivers.
0.1.0 is under construction. This README states what is in the repository today, not what is planned.
| Package | What it does | Status |
|---|---|---|
| @geom | Integer rectangle algebra: Offset, Size, Region, Spacing, with intersection, union, splitting and clamping | done |
| @style | Colours (named, indexed, true colour), text attributes, palette quantisation, and differential SGR rendering | done |
| @strip | One rendered line: styled segments measured in terminal columns, with cropping, division, padding and merging, over a generated Unicode width table | done |
| @event | Keys, mouse reports, paste, resize and focus as plain values | done |
| @input | The terminal byte stream turned into events: CSI and SS3 sequences, modifiers, SGR mouse, bracketed paste, in-band resize, UTF-8 split across reads | done |
| @comp | The compositor: placements to composed rows, consecutive screens to the spans that changed, spans to escape sequences | done |
| @driver | The seam to a terminal — write, poll, size, raw mode, clock — plus the capability sequences and a headless terminal for tests | done |
| @layout | Placing boxes along an axis: fixed cells, percentages, automatic sizes and fractional shares, with integer division that loses no column | done |
| @widget | The widget contract and eight widgets: static text, label, button, input, list, progress bar, header, footer | done |
| @app | The widget tree, the focus ring, and the frame loop: poll, parse, dispatch, lay out, compose, diff, write | done |
| @driver/node | Node's terminal: raw mode, a queue the data handler fills, and a frame pump | done |
| @driver/web | A terminal drawn on a canvas: the grid, the escape sequences it understands, key encoding, and in-band resize | done |
| @driver/native | A real terminal through the C library: termios on Unix, virtual terminal mode on Windows | done |
moon add moonbitstack/moonetuilet screen = @geom.Size::new(80, 24)
let panel = @geom.Region::new(2, 1, 40, 10)
let visible = panel.clip(screen.width, screen.height)moon check --target all --deny-warn
moon test --target allInstall
Download zipmoonetui — a terminal UI toolkit for MoonBit (after Textual): cell buffer, differential ANSI renderer, incremental key parser, layout, widgets, and pluggable terminal drivers.