ferrokit
A native macOS GUI framework for Rust. Every view is a real AppKit control
(an actual NSTableView, NSOutlineView, NSTextView), built once and
updated in place by fine-grained signals. No virtual DOM, no diffing, no web
view, no custom drawing. So VoiceOver, spell check, input methods and Mac
text editing come with it.
use *;
It's for data-heavy desktop apps where the Mac's own widgets matter:
- Deep widgets: a virtualised table (200,000 rows load in about 5 ms and scroll at display rate; sorting, editing, drag and drop, copy and paste), outlines and source-list sidebars, and a text editor with spell checking, input methods, Find and undo.
- The app shell: menus with shortcuts and state, commands that act on
the focused view, toolbars, split views with collapsible sidebars and
inspectors, popovers, sheets, alerts, open and save panels, document
apps, a Settings window, window restoration, per-window undo, and links
into the app (
myapp://URL schemes). - State and data:
Copysignals owned by the views that made them,Resourcefor loading off the main thread (a newer load cancels the stale one), and async tasks on the main thread (spawn_local) that stop when their window closes. - Text, drawing, transfer: syntax highlighting in the editor, a canvas with bar and line charts (a million points draw quickly), the clipboard, drag and drop (files written where they're dropped).
- Languages:
t("…")with.stringstables and plural rules; the framework's own strings come in German, French and Japanese. - Live data:
on_frameapplies incoming data once per display frame; the log viewer example follows a growing 1,000,000-line file at 60 Hz. - Accessibility: VoiceOver reads AppKit's own accessibility tree;
.accessibility_labelnames controls, andtesting::ax_auditfinds the ones without a name. - Testing and shipping: self-check helpers, crash reports, updates
through Sparkle, and
cargo ferrokitto make, check, bundle and notarise apps (or package them for the Mac App Store).
Read the guide; every
example in it is compiled as a doc test. API.md lists every
public item on one page.
AI coding agents: read AGENTS.md first (in this crate's
folder, beside API.md): how a Ferrokit app is written, where the docs
are, recipes that compile, and the known limits. cargo ferrokit new puts
it in every new app, and cargo ferrokit agents in an existing one. The examples are complete apps; the flagship is a SQLite browser
(schema sidebar, highlighted SQL, a million-row results table, charts, CSV
export):
&&
&&
macOS 15 or later. Main thread only. Built on
ferrokit-core and objc2.
Status: 0.9.0 (formerly appkit-ui), an alpha: the API will change. Part of Ferrokit; its crates share one version number.
License: MIT OR Apache-2.0.