Files
alkane-toolkit/thirdparty/wx-rs/patches
noahandClaude Opus 5.5 be5edfc2bf Port the toolkit GUI to Windows (wxMSW, cross-built with mingw-w64)
Build: the wx-rs build script chose the platform with cfg!(), which in a
build script describes the build host, so a Linux-to-Windows build took the
GTK path. It now reads CARGO_CFG_TARGET_*, and Windows/GNU builds through
wx-config exactly like GTK, against a static wxMSW from
scripts/build-wx-windows.sh. The C++ runtime is linked statically, so the
.exe imports only Windows system DLLs. crates/alkane-gui/build.rs embeds an
application manifest (Common Controls v6, per-monitor DPI v2, UTF-8 code
page, Windows 10/11), the icon and version info.

Bridge on wxMSW (patches 0007/0008):
- the upstream frame's invisible "OSX key events" child sat above the UI on
  MSW and swallowed every click and key; it is no longer created there
- light/dark is chosen before the first window (wxMSW ignores it later) and
  follows the Windows app mode, with dark grid rules for the data view
- the generic wxDataViewCtrl gets mouse input in its inner main window, so
  drag-select and the per-cell / per-icon tooltips bind there (GTK keeps
  its native GtkTreeView paths; the icon hit-test is shared)
- sizes cross the Rust/C++ boundary in DIPs (identity on GTK), so columns,
  icons, KPI cards and the status bar scale at 125-200 %
- vector shapes go through GDI+ (anti-aliased like Cairo on GTK); selected
  rows use the themed list-view text colour like the native renderer
- the frame never opens larger than the monitor work area; title-bar icon
  from the executable; upstream menu insert no longer reads UTF-8 as UTF-16

App: OS differences live in alkane_core::platform (settings in
%APPDATA%\alkane-toolkit, owner-only secret files, NUL, console-less helper
processes). SSH password logins use SSH_ASKPASS with the toolkit itself as
the helper on every platform, replacing sshpass, which Windows lacks.
Release builds are GUI-subsystem; headless modes attach to the parent
console.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 18:32:44 -06:00
..

wx-rs patch queue

../wx-rs-0.2.0-patched/ is the tree cargo builds. These patches, applied in order to the pristine crate in ../upstream/ (digest pinned in ../VERSION), must reproduce it byte for byte; CI checks this with scripts/wx_rs_patches.py check.

To change the bridge: edit the patched tree, build and test, then record the change as the next patch and commit both:

python3 scripts/wx_rs_patches.py capture short-name "One-line subject" [PATH ...]

capture limits the patch to the given paths (default: everything that differs) and re-runs the check. 0002 and 0003 create the widget bridge files outright, so they carry those files as of the queue's re-baselining; later changes go in new patches.

Patch What
0001 Linux/GTK3 build through wx-config
0002 Widget/event bridge, Rust side (src/widgets.rs)
0003 Widget/event bridge, C++ side (cpp_src/widgets_bridge.cpp)
0004 Upstream fixes for wx 3.3 (uninitialised callbacks)
0005 Packaging: build-only reqwest note; drop the case-duplicate readme.md
0006 Build: platform from the target, not the host; Windows/GNU via wx-config
0007 wxbridge.cpp on wxMSW: no input-swallowing overlay, appearance before the first window, work-area sizing, executable icon, UTF-8 menu fix
0008 Widget bridge on wxMSW: generic data-view input and tooltips, DIP boundary, anti-aliased shapes, themed selection colours

History: the round 19 health-tooltip fix (GTK tip area converted from bin-window to widget coordinates) used to be a separate patch on top of an older 0003; it is part of 0003 since the re-baselining.