Recursive AI

Changelog

All oneplatform docs

All notable changes to this project are documented in this file. The format follows Keep a Changelog.

[Unreleased]

[1.0.0] - 2026-12-01

Added

  • Global shortcuts and other portal calls for a program that was started directly (no installed launcher entry): DBusConnection.PortalAppId declares the application id to the desktop portal (org.freedesktop.host.portal.Registry.Register) before the first portal call on the connection; PortalCreateDesktopEntry and PortalAppName write the hidden launcher entry the portal needs to recognise the id when none is installed; PortalRegistration reports the outcome (PortalRegistrationState, PortalRegistrationResult). Without an id the portal's "An app id is required" refusal is now PortalAppIdRequiredException, whose message says what is missing. See docs/linux-shell.md; tests/OnePlatform.ShortcutProof is a small program for trying it.
  • IconImage and application icons without an installed launcher entry: Window.SetIcon(images, name) sets a window's icon on Wayland (xdg_toplevel_icon_manager_v1, bound when the compositor offers it) and X11 (_NET_WM_ICON) and returns false where the window system cannot; TrayIcon.CreateAsync(..., images) and TrayIcon.SetIcon(images, name) publish the pictures as the StatusNotifierItem IconPixmap at several sizes. Before, a tray icon had only a themed name, which a desktop could not resolve for an app that was not installed, so Plasma drew an empty clickable item and a placeholder in the taskbar. See docs/desktop-windows.md.
  • NativeEnvironment.Set(name, value) sets or removes an environment variable where native libraries in the process read it (getenv) as well as for managed code; Environment.SetEnvironmentVariable alone does not reach them on Linux and macOS.
  • tests/OnePlatform.IconProof, a small program that opens a window and a tray icon with or without pictures, for looking at a desktop's taskbar and tray.
  • The browser backend's page script, oneplatform.js, ships in the package as a static web asset: a browser-wasm app that references RecursiveAI.OnePlatform publishes it at _content/RecursiveAI.OnePlatform/oneplatform.js and registers it as the module oneplatform. See docs/browser.md.

Changed

  • Names renamed before 1.0: ActionMap.Harness is now ActionMap.Injected (the source for actions injected by scenarios, tests and live control; its label in reports is now "injected" instead of "harness"), and BrowserPage.Control is now BrowserPage.ControlAsync since it returns a Task. A page script that calls the exported method uses exports.OnePlatform.BrowserPage.ControlAsync.
  • OnePlatform.Shell.MenuBarMenu is now OnePlatform.Shell.NativeMenu, the menu type MacDesktop.SetMenuBar and WindowsDesktop.SetMenuBar take, so it no longer shares a name with menu types in apps built on the library.
  • PlatformModule, an unused placeholder, is removed.
  • Documentation and README are written for application authors: the support table, a getting-started example, and XML docs that no longer refer to types outside this package.

Fixed

  • Linux tray: when a StatusNotifierWatcher starts, its owner-changed signal can arrive before it answers calls; the icon's registration is now retried (up to 10 times, 200 ms apart) instead of being lost until the watcher restarts again.
  • Win32: a key message that carries no scan code (input sent with virtual-key codes only, as some automation tools do) is named from its virtual-key code instead of arriving as an unknown key, so Escape, Tab, Enter, the arrows and the letters work for such input. Text sent as Unicode packets (VK_PACKET) no longer produces key events with a bogus key; its text arrives as before.
  • Win32: windows now honour WindowOptions for desktop use, as on Cocoa: size limits, dialogs (Parent, owned windows), overlays (topmost tool windows placed from anchors and margins), borderless windows with resize edges, popups with a grab that ends when the application loses the foreground, StartMove/StartResize, Window.FillSolid, mouse capture, WM_IME_* composition and the rectangle Windows suggests on a DPI change. LocalSingleInstance now works on Windows, and the second launch grants the running copy the foreground before the hand-over. See docs/windows-shell.md.
  • Cocoa: windows now honour WindowOptions for desktop use: size limits (MinWidth..MaxHeight, SetSizeLimits), dialogs (Parent), overlays (Overlay, a borderless window at a window level, placed from its anchors and margins), borderless windows (Decorations = None) and popups (PlatformApp.CreatePopup, with a grab that ends on a press outside the application). Before, these options were ignored and CreatePopup threw. Window.Role, Parent and Decoration are set. Window.Activate on a popup throws ActivationUnavailableException. Window.FillSolid sets the layer's background colour on Cocoa. See docs/desktop-windows.md.

Added

  • WindowsDesktop.ShowAsync reports a notification Windows will not show instead of completing as if it had: for a packaged app it asks the toast notifier for its NotificationSetting first and fails with the new NotificationsDisabledException (Setting: the new WindowsNotificationSetting enum, DisabledForApplication, DisabledForUser, DisabledByGroupPolicy or DisabledByManifest). It derives from ShellUnavailableException, which is no longer sealed. An unpackaged app has no notifier to ask, so its balloon is sent as before. See docs/windows-shell.md.
  • Window.CanPresentPixels and Window.PresentPixels(bgra, width, height): show a CPU-drawn image in a window that has no graphics device. Win32 copies it with SetDIBitsToDevice and keeps it to draw again on WM_PAINT; Wayland toplevel, layer-shell and popup windows copy it into reusable wl_shm buffers that respect wl_buffer.release, resize with the window and draw only when a picture is presented (see docs/desktop-windows.md); other backends report CanPresentPixels false and throw NotSupportedException.
  • OnePlatform.Shell.WindowsDesktop: the Windows desktop services, the counterpart of MacDesktop. A notification-area icon with a context menu (ShowTrayIcon, SetTrayMenu, TrayActivated, GetTrayBounds), balloon/toast notifications with click-to-activate (ShowAsync, CloseAsync, ActionInvoked; no buttons, which a balloon cannot have), the Common Item Dialog through source-generated COM (OpenFileAsync, OpenFolderAsync, SaveFileAsync, owner as win32:<hex handle> in FileChooserOptions.ParentWindow), RegisterHotKey hotkeys with press and polled release (BindAsync, Activated, Deactivated), a menu bar with accelerators on a window (SetMenuBar, ClearMenuBar; reuses NativeMenu) and screenshots of the app's own window or a region the user drags (CaptureWindow, CaptureRegionAsync, returning the new ScreenshotImage with ToPng()). Anything Windows cannot do throws ShellUnavailableException. See docs/windows-shell.md.
  • Windows UI Automation for Window.Accessibility: a Win32 window now answers WM_GETOBJECT with a provider tree built from the window's IAccessibilityProvider (fragment navigation, bounding rectangles, hit testing, focus, control types per Core-AAM, the properties screen readers read, Invoke, Toggle, Value, RangeValue, ExpandCollapse and SelectionItem patterns) and raises focus, property, structure, selection and notification events from Flush(). It costs nothing until a client asks, uses source-generated COM, and runs provider calls on the window's thread. WindowAccessibility.IsSupported is now true on Windows. See docs/accessibility.md. tests/OnePlatform.UiaProof and tools/uia check it from outside the process.
  • Window.SetKeepAbove(bool), Window.KeepAbove, Window.CanKeepAbove and KeepAboveUnavailableException: a "keep on top" toggle for an ordinary window. X11 sends EWMH _NET_WM_STATE_ABOVE (and KeepAbove follows the window manager's property), Win32 uses HWND_TOPMOST/HWND_NOTOPMOST, Cocoa the floating window level, the headless backend holds the state. On Wayland xdg-toplevel has no such request, so under KWin only, a short KWin script sets or clears keepAbove on the windows with the app's own app id and is unloaded before the call returns; other compositors throw the typed error. See docs/desktop-windows.md.
  • OnePlatform.Accessibility: window accessibility. Window.Accessibility (WindowAccessibility) takes an IAccessibilityProvider, a pulled tree of AccessibleNodes (role, name, description, value and range, states, actions, bounds, children, text with selection) with focus, hit testing and actions, and queues change notifications (NotifyFocusChanged, NotifyStructureChanged, NotifyNameChanged, NotifyValueChanged, NotifyStatesChanged, NotifySelectionChanged, Announce) that Flush merges and sends. On macOS it is exposed through NSAccessibility on the content view and long-lived elements, built only when an assistive technology asks. See docs/accessibility.md.
  • OnePlatform.Shell.MacDesktop: the macOS desktop services, on Apple silicon: the menu bar (SetMenuBar with NativeMenu, the application menu named from CFBundleName), an NSStatusItem with a menu, open, folder and save panels (NSOpenPanel/NSSavePanel, taking FileChooserOptions and returning FileChooserResult), notifications through UNUserNotificationCenter with actions (DesktopNotification, ActionInvoked) and global hotkeys through Carbon RegisterEventHotKey (GlobalShortcut, Activated). LocalSingleInstance hands a second launch to the first over a private per-user Unix socket, shaped like SingleInstance. ShellUnavailableException (a PlatformException, with Service and Requirement) names what a missing permission or app bundle needs. TrayMenuItem.Shortcut carries a menu item's key equivalent. See docs/macos-shell.md.
  • Window.Activate(string? activationToken = null): brings a window to the front, un-minimizes it and gives it the keyboard focus, on Wayland (xdg_activation_v1, with the token a launcher passed in or one requested from the latest input), X11 (_NET_ACTIVE_WINDOW with source and input time, _NET_STARTUP_ID, map to un-iconify), Win32 (ShowWindow(SW_RESTORE), SetForegroundWindow with an input-queue attach fallback) and Cocoa (deminiaturize:, activateIgnoringOtherApps:, makeKeyAndOrderFront:). ActivationUnavailableException (with Requirement) names the missing protocol. WindowActivation.AllowForeground(processId) is the Windows launcher's half. ActivationRequest.ActivationToken returns the token or startup id a second launch forwarded, and SingleInstance.Acquire has an overload taking the token to forward (it also forwards DESKTOP_STARTUP_ID now). See docs/desktop-windows.md.
  • OnePlatform.DBus: a BCL-only D-Bus client (marshalling, authentication, calls, signals, exported objects, name ownership) and OnePlatform.Shell: single-instance activation, the FileChooser, Screenshot, GlobalShortcuts and Notification portals (with the org.freedesktop.Notifications fallback) and a StatusNotifierItem tray icon with a dbusmenu menu. See docs/linux-shell.md.
  • The platform layer: windows, input, IME, clipboard, displays, gamepads and haptics, the headless backend and InputInjector, and the Win32, Cocoa, X11, Wayland, Android, iOS and browser backends, in namespace OnePlatform.
  • Desktop windows on Wayland and X11: decorated, movable and resizable by default (xdg-decoration server-side frames, a client-side frame where the compositor has none, WM_CLASS/_NET_WM_NAME on X11), application id, size limits, dialogs with a parent, StartMove/StartResize/ShowWindowMenu, keep-on-top overlays (wlr-layer-shell; dock-type _NET_WM_STATE_ABOVE windows on X11) through WindowOptions.Overlay, and popups with an anchor, gravity, constraint adjustment and grab through PlatformApp.CreatePopup. See docs/desktop-windows.md.
  • tools/WaylandGen and its protocol XML, which produce the Wayland protocol tables.