From 69dcedbd9cb2057daa7dad3bde8be209b8485173 Mon Sep 17 00:00:00 2001 From: Noah <2+noah@noreply.gitea.bluefla.re> Date: Fri, 13 Nov 2026 12:02:38 -0600 Subject: [PATCH] build(wx-rs): capture the word-wrap text-ctrl edit into the patch queue The #37 wrap fix edited the vendored wx-rs tree (wxbr_text_ctrl_wrap in the C++ bridge + text_ctrl_wrapped in widgets.rs) but not the patch queue, so the `wx_rs_patches.py check` CI gate failed. Capture the delta as patch 0012 so the queue reproduces the patched tree again. Co-Authored-By: Claude Opus 4.8 Claude-Session: https://claude.ai/code/session_01B1W6qKwKxq3oUPDKWicM6i --- .../wx-rs/patches/0012-text-ctrl-wrap.patch | 43 +++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 thirdparty/wx-rs/patches/0012-text-ctrl-wrap.patch diff --git a/thirdparty/wx-rs/patches/0012-text-ctrl-wrap.patch b/thirdparty/wx-rs/patches/0012-text-ctrl-wrap.patch new file mode 100644 index 00000000..010a87a6 --- /dev/null +++ b/thirdparty/wx-rs/patches/0012-text-ctrl-wrap.patch @@ -0,0 +1,43 @@ +Subject: [PATCH 0012] linux: word-wrapping multiline text control + +--- a/cpp_src/widgets_bridge.cpp ++++ b/cpp_src/widgets_bridge.cpp +@@ -890,6 +890,15 @@ + wxDefaultPosition, wxSize(-1, -1), style); + } + ++// A multiline text control that word-wraps at the control's width instead of ++// scrolling horizontally (no wxTE_DONTWRAP). For prose entry such as the bug ++// report box, where long lines should wrap rather than run off the edge. ++void* wxbr_text_ctrl_wrap(void* parent) { ++ return (void*)new wxTextCtrl((wxWindow*)parent, wxID_ANY, wxT(""), ++ wxDefaultPosition, wxSize(-1, -1), ++ wxTE_MULTILINE | wxTE_BESTWRAP); ++} ++ + // A single-line text control that masks its content (wxTE_PASSWORD), for secret + // entry so a saved password is never rendered in the clear (round 18 #12). + void* wxbr_text_ctrl_password(void* parent) { +--- a/src/widgets.rs ++++ b/src/widgets.rs +@@ -41,6 +41,7 @@ + pub fn wxbr_button(parent: *mut c_void, label: *const c_char, id: c_int) -> *mut c_void; + pub fn wxbr_bind_click(win: *mut c_void, id: c_int); + pub fn wxbr_text_ctrl(parent: *mut c_void, multiline: c_int) -> *mut c_void; ++ pub fn wxbr_text_ctrl_wrap(parent: *mut c_void) -> *mut c_void; + pub fn wxbr_text_ctrl_password(parent: *mut c_void) -> *mut c_void; + pub fn wxbr_text_ctrl_get(win: *mut c_void, buf: *mut c_char, cap: c_int) -> c_int; + pub fn wxbr_text_ctrl_set(win: *mut c_void, value: *const c_char); +@@ -463,6 +464,12 @@ + Widget(unsafe { notsafe::wxbr_text_ctrl(parent.0, multiline as c_int) }) + } + ++ /// A multiline text control that word-wraps at its width (no horizontal ++ /// scroll), for prose entry such as the bug-report box. ++ pub fn text_ctrl_wrapped(parent: Widget) -> Widget { ++ Widget(unsafe { notsafe::wxbr_text_ctrl_wrap(parent.0) }) ++ } ++ + /// A single-line text control that masks its content (for password entry). + pub fn password_ctrl(parent: Widget) -> Widget { + Widget(unsafe { notsafe::wxbr_text_ctrl_password(parent.0) })