Commit Graph
227 Commits
Author SHA1 Message Date
nandiandClaude Opus 5.5 cb81a973f8 Docs: the host is MoonBit; drop the plan's Rust host recommendation
ARCHITECTURE.md's host strategy and open questions still recommended a Rust + wasmtime host;
they now record the decision (MoonBit on the wasmtime C API, no Rust in the tree). TOOLCHAIN.md
names wasmhost as the embedder.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-30 12:24:24 -08:00
nandi 44bb77871d Panel: add a Show Desktop module at the panel's end
- Clicking it hides every window, as Super+D does; it stays lit while the desktop is shown.
- A second click brings the hidden windows back.
- New show-desktop capability (wit toggle and publish-desktop-shown) for the wasm module.
- Added to the default panel after session settings; existing panels are unchanged.
- Test covers hiding, the lit state, and restoring the windows.
2026-11-30 12:24:01 -08:00
nandi 51852f0dac Advertise zwp_linux_dmabuf_v1 so Mesa EGL clients stop using llvmpipe
- Add zwp_linux_dmabuf_v1 (v4 feedback names the render node). Only linear ARGB8888 and XRGB8888 are accepted, because the compositor reads a buffer by mapping its dma-buf.
- Bracket dma-buf reads with DMA_BUF_IOCTL_SYNC in the compositor and in the wasm host, so the CPU sees the GPU's finished writes.
- Keep every wl_surface.frame callback since the last commit instead of only the last one. Zed and Mesa's EGL queue several and wait on all of them.
- rs_capture maps a dma-buf afresh on each capture rather than using the pool cache, which could hand a later buffer an earlier buffer's pixels.
- Restart xdg-desktop-portal in the background once the compositor socket exists, so the restart no longer delays compositor startup by about 30 s.
2026-11-30 11:49:48 -08:00
nandiandClaude Opus 5.5 d81003f176 wm: refresh the generated interface
CI / test (push) Successful in 1m40s
Deploy to the handset / build-and-deploy (push) Successful in 1m2s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 23:45:33 -08:00
nandiandClaude Opus 5.5 5ca7242615 Tests: the native suite in seconds, every test on its own, all cores
CI / test (push) Canceled after 0s
Deploy to the handset / build-and-deploy (push) Successful in 3m11s
- scripts/test-native.py (just t WORD): builds once, runs each test in its own
  process in parallel, longest first, with a timeout; CI and just test use it.
- Tests no longer search this machine's apps and icon themes.
- Compiled wasm modules are cached between test processes (CHANDRA_WASM_CACHE).
- draw_circle fills its middle with spans (same pixels); encode_png writes into
  one buffer, with a CRC table.
- The ffprobe helper always waited out its 20 s: its done file was empty.
- The fake polkit helper no longer depends on which shell sh is.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 23:45:29 -08:00
nandiandClaude Opus 5.5 d1d1bb398c Fix CI: recordings keep to 60 fps, the battery has room for its time left
Deploy to the handset / build-and-deploy (push) Successful in 2m3s
CI / test (push) Successful in 3m5s
- Recorder: a 12 ms gap let through 83 frames a second. Frames now come due every 60th of a
  second, with room for a 60 Hz screen's jitter.
- Battery: the handset change shrank it to 76 px everywhere, too narrow for the time left. It is
  104 px again, and 76 only on a compact panel.
- Tests: recording is timed from its first frame, the failed launch doesn't depend on the apps
  installed, and the scene test waits for notices and clocks to settle.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 23:20:00 -08:00
nandiandClaude Opus 5.5 4e6a8005dd Launcher: long names and descriptions end in an ellipsis
Deploy to the handset / build-and-deploy (push) Successful in 2m21s
CI / test (push) Canceled after 2m38s
They ran under the scrollbar and off the popup's edge.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 23:17:26 -08:00
nandi 5c83cdaa22 Windows: on a handset, apps open maximized and dialogs float above
Deploy to the handset / build-and-deploy (push) Successful in 2m7s
CI / test (push) Failing after 2m42s
- Apps open maximized on a touchscreen whose short side is under 720px. Restore gives a floating window that fits the screen.
- Maximized windows can't be dragged or resized.
- Dialogs (xdg_toplevel.set_parent) open floating and centered, and stay above their app when it is activated.
- Under tiling, the last used app is drawn on top.
- Add transient_for to WmState and make inner_work_area and fit_rect public for the compositor.
- Tests cover maximized opening, dialog stacking, drag suppression and restore.
- Document the handset window behavior in docs/handset.md.
2026-11-29 23:11:34 -08:00
nandiandClaude Opus 5.5 7029c92e6e Launcher: a thumb scrolls the app list
Deploy to the handset / build-and-deploy (push) Successful in 2m21s
CI / test (push) Failing after 2m49s
On a touchscreen a drag over the launcher's list scrolls it by pixels, a flick
keeps it going, and a tap still launches (or stops a moving list).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 22:40:32 -08:00
nandi cb0ff0715e Launcher: list recently opened apps first, latest first
Deploy to the handset / build-and-deploy (push) Successful in 2m13s
CI / test (push) Failing after 2m43s
- Apps opened recently now lead the launcher and the desktop, newest first, ahead of the defaults.
- Remember up to 200 launches (was 8), so the recent order holds over time.
- Apps not recently opened follow the defaults, then the rest A-Z.
- Add a test for the launcher order and for recents moving apps in and out.
- Update the Desk::shown and default-group comments to match.
- Update the display interface with the touch seat events.
2026-11-29 22:27:40 -08:00
nandiandClaude Opus 5.5 e30d9cc71f Touch: fingers reach apps as wl_touch, so a thumb scrolls
Deploy to the handset / build-and-deploy (push) Successful in 2m20s
CI / test (push) Failing after 2m56s
Every touch was turned into a mouse drag in the seat code, which selects text
instead of scrolling. The seat now reports raw touches and the compositor
routes them: to the app as wl_touch on its own content, and to the pointer
(tap, drag, hold for right click, as before) everywhere else and for apps that
don't listen to touches. The cursor is hidden while fingers are in use.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 22:22:14 -08:00
nandiandClaude Opus 5.5 98a99aaa36 KMS: rotate the cursor with the display
Deploy to the handset / build-and-deploy (push) Successful in 2m5s
CI / test (push) Failing after 2m48s
Only the cursor's position was rotated; the hardware cursor image and its
hotspot stayed in the panel's own orientation.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 20:53:23 -08:00
nandiandClaude Opus 5.5 30086562bc Remote: right-click opens the desktop's menu, not the browser's
Deploy to the handset / build-and-deploy (push) Successful in 2m10s
CI / test (push) Failing after 2m45s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 18:04:40 -08:00
nandiandClaude Opus 5.5 2aa3de5741 Deploy to the handset from the cluster
Deploy to the handset / build-and-deploy (push) Successful in 2m14s
CI / test (push) Failing after 2m41s
CI builds an arm64 image (compositor, host, chandra-remote, modules) and deploys
the updater pod that installs it on the phone. chandra-remote updates go in live
(SIGUSR2 restarts it in place); the compositor waits for an idle, locked phone or
an approval, and a locked session restarts locked. Host tests: the launcher no
longer draws its label in a narrow panel.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 16:34:12 -08:00
nandi d2e00b4658 Remote: paste the phone clipboard, including images, on the desktop
CI / test (push) Failing after 1m2s
- Web UI: Ctrl+V, Ctrl+Shift+V, Shift+Insert (Cmd+V on Mac) and a Paste button send the phone clipboard (text or PNG, up to 16 MB) to the desktop over POST /api/clipboard
- chandra-remote passes clipboard data to the compositor in a sealed memfd (clipboard-set-fd), replacing the 4 KB hex clipboard-set line
- Compositor: new clipboard-status and input-paste commands; text is typed into the launcher, password dialog and shell popups, otherwise the paste chord is sent (Ctrl+Shift+V in terminals)
- Paste data is captured when a paste starts, so a clipboard change mid-transfer can't corrupt it
- VNC clipboard text limit raised from 4 KB to 1 MB
- Upload endpoints are authorized with the same token check as /ws; the no-header cross-site case is refused with 403
2026-11-29 15:42:46 -08:00
nandiandClaude Opus 5.5 8a6d19d16f Docs: remote over HTTPS on the tailnet
CI / test (push) Failing after 52s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 14:53:30 -08:00
nandiandClaude Opus 5.5 0356413bb2 Remote: forward the physical keyboard and hide the phone OSK while typing
CI / test (push) Failing after 1m7s
The web UI now sends key events without opening the KB bar, and releases
held keys on blur, hide or disconnect. The first remote keystroke (web or
VNC) turns the on-screen keyboard off; it comes back when the last typing
client disconnects, unless the user toggled it by hand.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 14:27:17 -08:00
nandi 5e62f1b8cb Input test: expect panel version 3 after the clock migration
CI / test (push) Failing after 52s
- The old 12-hour clock migration test now asserts the saved panel is version 3, not 2.
- The panel format version is bumped, so the test must match it.
2026-11-29 12:30:15 -08:00
nandi c790f96e58 Lock: add session lock from power button and chandra-ctl lock
CI / test (push) Failing after 52s
- Lock the session from the power button or `chandra-ctl lock`
- Unlock with a face or the password; the password always works
- Add compositor lock module with tests, and a polkit unlock policy (org.chandra.unlock)
- Document the lock flow in docs/lock.md and link it from the README
- Add generated interface bindings for the compositor and widget components
2026-11-29 03:24:46 -08:00
nandi 7501fc3ad9 Boot splash: cycle the moon through its phases
CI / test (push) Failing after 50s
- Replace the static moon with a 64-frame lunar phase spritesheet, generated by boot/plymouth/render-phases.py and advanced about every 0.3 s (~5 s per cycle)
- Add a glow sprite behind the moon whose opacity follows the illuminated fraction
- render.sh renders the glow SVG and the phase sheet (needs python3 with numpy and Pillow)
- install-plymouth.py removes theme files that are no longer in the source theme, and checks for the new PNGs
- Drop moon.svg and moon.png in favour of glow.svg, glow.png and moon-phases.png
2026-11-29 02:39:26 -08:00
nandiandClaude Opus 5.5 4fd2641c80 Clock: make monotonic_ms monotonic, so a clock jump can't freeze the session
CI / test (push) Failing after 52s
It read the wall clock. When NTP moved a phone from 1970 to now, the frame
loop's elapsed time overflowed and it slept for days.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 02:22:27 -08:00
nandiandClaude Opus 4.8 f51ce088ad Docs: OnePlus 6T fingerprint investigation
CI / test (push) Failing after 50s
Record the read-only investigation into the 6T's in-display fingerprint
reader: our unit is a Silead GSL7000 (sl7000 TA), not Goodix — GPIO 91
reads 0 and /persist carries fresh Silead calibration. Document the
extracted stock blobs (staged outside the repo), the TEE+REE software
stack and first-pass sl_fp_* command RE, the keymaster/gatekeeper HAT
path, a feasibility read, the ordered next steps, and the hardware
safety constraints. Not a shipped feature; face unlock remains the
working path.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-11-29 01:53:09 -08:00
nandiandClaude Opus 5.5 2209549755 Boot splash: Plymouth theme with a progress bar for the OnePlus 6T
CI / test (push) Failing after 51s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 01:47:52 -08:00
nandi 05cfa80a1b Boot: add install-plymouth.py and a 24pt boot message font
CI / test (push) Canceled after 0s
- Add boot/install-plymouth.py, which installs Plymouth with the Chandra theme on a Kupfer handset, rebuilds the initramfs, and flashes the boot partition
- Check the new initramfs and the flashed command line before flashing is considered done
- Save the boot partition and every changed file on first install; --rollback restores them
- --package FILE installs Plymouth from a downloaded package for phones without internet
- Render boot messages (fsck, emergency mode) in Sans 24 instead of the default font
2026-11-29 01:46:52 -08:00
nandi f910aa2a94 Boot: add a Plymouth splash with the moon and a progress bar
CI / test (push) Canceled after 0s
- Add a script-module Plymouth theme: the moon breathes over a progress bar
- The bar eases towards the last boot's duration (60 s before one is recorded)
- Art is SVG under boot/plymouth, rendered to PNG by render.sh (needs rsvg-convert)
2026-11-29 01:31:36 -08:00
nandiandClaude Opus 5.5 019c9ada6c Camera: cut viewfinder CPU use
CI / test (push) Failing after 49s
- Decode half-size frames at 24 fps (15 on the raw front camera) for the viewfinder; full frames only for photos, video, focusing and QR scans
- Swap channels with OpenCV instead of numpy; 2 OpenCV threads for live frames; OpenMP threads sleep when idle

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 01:14:29 -08:00
nandiandClaude Opus 5.5 f5a252e063 Camera: scan for QR codes twice a second
CI / test (push) Failing after 50s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 00:58:32 -08:00
nandiandClaude Opus 5.5 e2ba41acca Camera: QR code scanner
CI / test (push) Canceled after 0s
- Scan the photo viewfinder with OpenCV's QR detectors (aruco, then plain), off the preview thread, not while recording or in the gallery
- A card shows the code's text: Open for web links, Join for Wi-Fi codes (NetworkManager over D-Bus), Copy; nothing happens before a tap
- QR pill turns scanning off

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 00:38:40 -08:00
nandiandClaude Opus 5.5 2f404ced5c Launcher: draw the search field focused, with a caret
CI / test (push) Canceled after 0s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 00:28:57 -08:00
nandiandClaude Opus 5.5 68baf1a467 Launcher: pick up web apps as they are installed, categories, scrolling
CI / test (push) Failing after 49s
- Read the app catalog again when the Applications menu opens if .desktop files were added or removed (and on Reload); it was only read at login, so a PWA installed during the session was missing from the menu and its search
- List a Chromium browser's web apps in their own category ("Chrome Apps", "Chromium Apps", ...), as Plasma does; don't take one for the default browser
- Category column and a scrollable list (wheel, scrollbar) when the catalog doesn't fit the menu
- Show menu-spec main category names instead of the first Categories= entry; sort apps A-Z (they were sorted shortest name first)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-28 23:42:10 -08:00
nandi aa92aaac6f Text input: don't send leave for destroyed client surfaces
CI / test (push) Failing after 49s
- Drop text-input and keyboard focus references when a client destroys a wl_surface, without sending leave for it
- Skip wl_keyboard.leave and zwp_text_input_v3.leave/enter for surfaces the client no longer has
- Skip pointer enter/leave for missing subsurfaces or toplevels
- Add a regression test: closing a second toplevel (e.g. OAuth popup) must return focus to the main window without leaving stale events
2026-11-28 23:33:17 -08:00
nandiandClaude Opus 5.5 444d67ac79 OSK: sit on top of the panel instead of covering it
CI / test (push) Failing after 49s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-28 23:11:59 -08:00
nandi 68912f6d64 Audio: hardware volume keys, chandra-ctl volume, and an OSD pill
CI / test (push) Failing after 51s
- Map VolumeUp, VolumeDown, and Mute keys to wpctl (PipeWire) or pactl, run asynchronously so the compositor never blocks
- Hold a volume key to repeat it; volume keys also work while the screen is off, without waking it
- Keep volume keys as the shutter when chandra-camera has focus; Mute still toggles system audio
- Add `chandra-ctl volume [up|down|mute|unmute|toggle|PCT|status]` and a transient Volume OSD
- Add volume-up, volume-down, and volume-mute entries to the shortcut table
2026-11-28 20:01:58 -08:00
nandi ebdd330eb5 Camera: reuse ISP scratch buffers and fix video start frame
CI / test (push) Failing after 49s
- Reuse per-state scratch buffers in the Quad Bayer ISP path to cut per-frame allocations; never return an alias to the scratch output
- Release memoryviews and run gc before closing mmaps
- Seed recording from latest_frame() and emit it on stop if no fresh frame arrived, so short clips still produce a valid MP4
- Drop the initial push of the start frame
- Lower H.264 CRF from 20 to 23
- Compute ISP stats on a coarser subsample (//96 instead of //160)
2026-11-28 19:37:05 -08:00
nandi 6cb0562654 Camera: fix VFR video timestamps and close ffmpeg stderr
CI / test (push) Failing after 49s
- Pass -enc_time_base demux to ffmpeg so VFR video keeps the source timing
- Read the encoder's stderr only on failure, and always close the pipe
- Mirror the same ffmpeg flag and stderr close in test_camera.py
2026-11-28 19:28:05 -08:00
nandi 52b42890d6 Camera: C ISP pipeline, contrast autofocus, and VFR video
CI / test (push) Canceled after 0s
- Add chandra-camera-isp.c (C/OpenMP) for Quad-Bayer unpack, CCM, and tone mapping, with a NumPy fallback when it is not built
- Add non-blocking contrast-detection VCM autofocus, with lens subdev discovery on the sensor's I2C bus
- Tune Quad-Bayer AE: a video-mode vblank cap, damped steps, and full analog gain before extending blanking
- Record variable-frame-rate video through a streaming Matroska muxer, and count dropped frames
- Ship libcamera IPA tuning files for imx376, imx519, and uncalibrated sensors
- Map camera buffers by fd and sync them with dma-buf ioctls
2026-11-28 19:25:43 -08:00
nandi 851c39d827 Auth dialog: OSK auto-open, hex keysyms, and remote text input
CI / test (push) Failing after 52s
- Show the on-screen keyboard when the password dialog opens or reopens, and hide it on submit. Tapping the password field reopens it after a manual Hide.
- Route Chandra Remote text commits (including Enter, Tab, and Backspace) into the password dialog while it is up.
- Keymap: read hex keysyms (`0x31`, `0x20ac`, `0xffb7`) from libxkbcommon text-v1 keymaps, and accept `0x01000000`-range Unicode keysyms.
- Keymap: keypad keys produce digits when NumLock (Mod2) is active.
- Tests cover hex keysym parsing, NumLock keypad mapping, and the OSK/remote-text flow.
2026-11-28 18:51:15 -08:00
nandi 40c5d6722c Face unlock: screen fill-light for low light; fix Quad-Bayer AE ramp
CI / test (push) Failing after 51s
- Boost the backlight to 90% while enrolling with the light on or while sign-in is scanning, then restore the previous level when that ends or the window closes.
- Add a Light: On/Off toggle (L key) to the Face window; the backdrop turns soft white while the light is on.
- Quad-Bayer AE: compute the low-light gain once and cap it by the highlight limit, so ramp-up and highlight back-off agree.
- Tests: backlight round-trip through the Face window, Quad-Bayer debayer color/low-light/dark-frame cases, and the AE ramp, back-off and restore order.
2026-11-28 18:32:15 -08:00
nandi c5b96e2c70 Quad-Bayer camera: direct V4L2 auto-exposure; enhance dark frames
CI / test (push) Failing after 50s
- Camera: on imx371, configure a Raw-only stream and drive exposure, vblank, analogue gain and digital gain through the sensor subdev (QuadSensorAE). Falls back to the viewfinder+raw configuration if the subdev is not found or setup fails.
- Camera: debayer 2x2-binned high-quality Quad-Bayer frames with an auto black level, a tone LUT, and CLAHE on strongly boosted frames.
- Face: add detect_score (default 0.65) and lower the default dark threshold from 25 to 12.
- Face: retry detection and embedding on gamma-lifted, CLAHE-enhanced frames when the image is dark.
2026-11-28 18:12:31 -08:00
nandi bfc60ee0e5 Add chandra-remote: VNC and web control over Tailscale
CI / test (push) Failing after 50s
- remote/: shared-memory framebuffer mirror served as RFB 3.8 (VNC, port 5900) and an HTTP/WebSocket PWA (port 6080), bound to the Tailscale interface and loopback by default
- Compositor: remote pointer, button, scroll, modifier, key, key-tap, text and clipboard input, routed past OLED blanking
- chandra-ctl: add status, refresh and osk commands; add input-* and clipboard-set for remote control
- Camera: debayer 10-bit CSI-2 Quad-Bayer frames for imx371 and high-quality still capture
- Camera: rotate frames by the libcamera mounting angle (CCW for 90), fix the expected test values, and restyle the UI for a dark theme
2026-11-28 17:57:55 -08:00
nandi de39b74282 Camera: move the camera engine into a stdio worker process
CI / test (push) Failing after 49s
- Replace the in-process GTK3 run_gui() with run_worker(), which owns the camera engine.
- Worker streams downscaled Cairo BGRA frames to stdout, with a length header per frame.
- Worker reads UI commands from stdin (switch, snap, snap_full, rec_start, quit) and emits state lines (info, active, flash, toast, saved_photo, rec_state).
- SIGINT/SIGTERM set a stop flag so the worker shuts down cleanly.
2026-11-28 12:25:29 -08:00
nandi 1c954aa657 Add a camera app: photo and video on libcamera or V4L2
CI / test (push) Failing after 52s
- Discover libcamera cameras, falling back to V4L2; label them Back, Front or External and pick the rear sensor first
- Photo mode: JPEG saves to ~/Pictures/Camera, with an optional high-res still capture
- Video mode: H.264 MP4 recording through ffmpeg, saved to ~/Videos/Camera
- Rear torch LED toggle via sysfs, falling back to logind SetBrightness
- GTK3 + Cairo Wayland UI with a viewfinder, timer, grid, camera switch and gallery view
- Add the desktop entry, icon and camera tests
2026-11-28 12:22:36 -08:00
nandi 74235cb0ca Add backlight control to the shell and regenerate WIT bindings
CI / test (push) Canceled after 0s
- Add compositor/shell/backlight.mbt for backlight control in the shell
- Update wit/capabilities.wit and wit/host/plasmoids.wit, then regenerate the component and interface ffi.mbt bindings (mostly export reordering)
- Add world/launcher-widget/README.md
2026-11-28 02:16:07 -08:00
nandi 2e00009c79 Add display rotation: Rot pill, chandra-ctl rotate, sensor auto-rotate
CI / test (push) Failing after 51s
- Rotate the display 0/90/180/270 degrees in the KMS host, with scanout and libinput touch/pointer coordinates transformed to match
- Add a touch "Rot" pill beside "KB": tap turns 90 CW, long-press or right-click flips 180
- Add `chandra-ctl rotate [cw|ccw|flip|0|90|180|270|status]`; CHANDRA_ROTATE sets the initial orientation
- Add session/chandra-auto-rotate, which follows iio-sensor-proxy orientation (disable with CHANDRA_AUTO_ROTATE=0)
- Advertise window_menu, maximize, fullscreen and minimize via xdg_toplevel.wm_capabilities (xdg_wm_base v5+)
- Add docs/handset.md covering handset touch, scaling, OSK and rotation
2026-11-28 00:39:24 -08:00
nandi 905dab8725 Add a built-in on-screen keyboard for handset sessions
CI / test (push) Failing after 52s
- Opens for text-input-v3 fields, terminals, launcher search, Network password, emoji picker and the password dialog; a KB pill summons it manually.
- Enabled on CHASSIS=handset; CHANDRA_OSK=1|0 overrides, and it stays off under CHANDRA_TEST_CONFIG.
- Work area and panel popups shrink above the keyboard so focused content stays visible.
- Keys send evdev codes with Shift, Ctrl and Alt modifiers.
- chandra-ctl: `screenshot [PATH]` saves a PNG without opening the editor.
- Key names cover the full punctuation set and shifted symbols.
- Launcher plasmoid min width drops from 60 to 36.
2026-11-28 00:18:32 -08:00
nandi 1205329abd KMS: map touch to the left pointer button; toolchain: add aarch64
CI / test (push) Canceled after 0s
- kms: touch down, move and up drive the pointer and send BTN_LEFT, so touchscreens work without a mouse. Only the first finger (tracked by seat slot) controls the pointer.
- A held touch is released on VT switch and on close, so the button is never left stuck down.
- setup-toolchain.sh: fetch wasm-tools, wit-bindgen, wasmtime and the wasmer C API for aarch64 as well as x86_64. Other architectures still fail with an error.
2026-11-27 22:24:33 -08:00
nandi c1c4349584 Web host: give the page a moon favicon
CI / test (push) Failing after 2m59s
- Add favicon.svg: a crescent moon on a dark rounded tile
- Link it from host/web/index.html as the page icon
- serve.mjs: allow /favicon.svg through the path filter and serve it as image/svg+xml
2026-11-27 16:14:41 -08:00
nandi 1871d50a3e X11 dock bridge: show and control host EWMH windows under --x11
CI / test (push) Failing after 2m37s
Under --x11 with a host EWMH window manager (e.g. Openbox in Gamerig),
Chandra is one top-level X11 client while other apps run directly on Xorg,
so the dock only saw Chandra's Wayland windows.

- compositor/x11: intern EWMH/ICCCM atoms and track _NET_CLIENT_LIST,
  _NET_ACTIVE_WINDOW, titles, and window states via PropertyChangeMask,
  filtering non-taskbar/child windows and adding focus, close, minimize,
  and toggle-maximize EWMH/ICCCM actions.
- compositor/shell: add resolve_external_app_id (matching WM_CLASS and
  StartupWMClass against installed .desktop files) and publish_windows.
- compositor/host: bridge ExternalWindow entries with bit-30 tagged IDs
  into shell.windows/win_list while keeping Wayland wm.windows and session
  snapshots untouched, and route activate_task / window_command actions.
- compositor/app, compositor/bin, docs/x11.md: wire external window sync
  before X11 input handling and register ExternalWindowHandler.

Verified: moon test --target native compositor/x11 compositor/shell (38/38),
external_windows_test.mbt + dock_test.mbt (3/3), build-compositor-wasm.sh,
and moon build --target native compositor/bin.
2026-11-27 14:33:26 -08:00
nandiandClaude Sonnet 5.5 15b7c3f0e3 Merge origin/main into the memory leak fix
CI / test (push) Successful in 5m49s
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DPL5hj5m35Lj6Rt9vwwLGZ
2026-11-26 17:11:01 -08:00
nandiandClaude Sonnet 5.5 ada9850b8d Fix the memory leak that filled RAM and swap; launch monitor, memory log
wasmhost leaked the arguments of every host call. wt_stub.c handed them to
the MoonBit dispatcher expecting it to own them, but the compiler borrowed
the parameter, so nothing released them (about 600 kB/s in a test with one
busy terminal; a long session reached over 16 GB resident plus swap).
MoonBit now allocates the buffer and C copies into it.

Also:
- Unannotated pointer FFI parameters default to #owned, and none of these C
  functions released theirs, including the native KMS present (a whole frame
  each). Annotated #borrow; the wasmhost build now fails on that warning,
  which --warn-list -a had hidden.
- Watched launches forked the whole compositor, and each monitor kept a
  snapshot of its heap for the app's lifetime. It now posix_spawns a fresh
  copy of the binary that takes over before main.
- The host logs memory, window buffers and images once a minute.
- chandra-session keeps the previous log as session.log.1.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DPL5hj5m35Lj6Rt9vwwLGZ
2026-11-26 17:10:47 -08:00