From 98ca6a378ddb7ed75ccf20200442a9f324394041 Mon Sep 17 00:00:00 2001 From: Daneel Date: Sat, 28 Feb 2026 22:55:31 +0100 Subject: [PATCH] patches: move lastCursorRect ivar from patch 1 to patch 5 The ivar was declared in patch 0001 but first used in patch 0005, creating dead code in intermediate commits 0001-0004. Now each commit only introduces declarations that are immediately used. --- ...ssibility-base-classes-and-text-extractio.patch | 14 ++++++-------- ...t-buffer-accessibility-element-core-proto.patch | 2 +- ...er-notification-dispatch-and-mode-line-el.patch | 2 +- ...eractive-span-elements-for-Tab-navigation.patch | 2 +- ...e-accessibility-with-EmacsView-and-redisp.patch | 14 +++++++------- ...ceOver-accessibility-section-to-macOS-app.patch | 2 +- ...-overlay-completion-candidates-for-VoiceO.patch | 2 +- ...-child-frame-completion-candidates-for-Vo.patch | 2 +- 8 files changed, 19 insertions(+), 21 deletions(-) diff --git a/patches/0001-ns-add-accessibility-base-classes-and-text-extractio.patch b/patches/0001-ns-add-accessibility-base-classes-and-text-extractio.patch index 4208e15..8d2227e 100644 --- a/patches/0001-ns-add-accessibility-base-classes-and-text-extractio.patch +++ b/patches/0001-ns-add-accessibility-base-classes-and-text-extractio.patch @@ -1,4 +1,4 @@ -From cd6ad89e786fc79f68bc0843b8122e088e8766ba Mon Sep 17 00:00:00 2001 +From 1834e38e60c9e9f898a7e67894c1c9b717db339b Mon Sep 17 00:00:00 2001 From: Martin Sukany Date: Sat, 28 Feb 2026 12:58:11 +0100 Subject: [PATCH 1/8] ns: add accessibility base classes and text extraction @@ -29,12 +29,12 @@ ns-accessibility-enabled. Tested on macOS 14 Sonoma with VoiceOver 10. Builds cleanly; no functional change (dead code until patch 5/6 wires it in). --- - src/nsterm.h | 131 +++++++++++++++ + src/nsterm.h | 129 +++++++++++++++ src/nsterm.m | 456 +++++++++++++++++++++++++++++++++++++++++++++++++++ - 2 files changed, 587 insertions(+) + 2 files changed, 585 insertions(+) diff --git a/src/nsterm.h b/src/nsterm.h -index 7c1ee4c..5298386 100644 +index 7c1ee4c..ca67bd9 100644 --- a/src/nsterm.h +++ b/src/nsterm.h @@ -453,6 +453,122 @@ enum ns_return_frame_mode @@ -160,7 +160,7 @@ index 7c1ee4c..5298386 100644 /* ========================================================================== The main Emacs view -@@ -471,6 +587,14 @@ enum ns_return_frame_mode +@@ -471,6 +587,12 @@ enum ns_return_frame_mode #ifdef NS_IMPL_COCOA char *old_title; BOOL maximizing_resize; @@ -170,12 +170,10 @@ index 7c1ee4c..5298386 100644 + Lisp_Object lastRootWindow; + BOOL accessibilityTreeValid; + BOOL accessibilityUpdating; -+ @public /* Accessed by ns_draw_phys_cursor (C function). */ -+ NSRect lastAccessibilityCursorRect; #endif BOOL font_panel_active; NSFont *font_panel_result; -@@ -528,6 +652,13 @@ enum ns_return_frame_mode +@@ -528,6 +650,13 @@ enum ns_return_frame_mode - (void)windowWillExitFullScreen; - (void)windowDidExitFullScreen; - (void)windowDidBecomeKey; diff --git a/patches/0002-ns-implement-buffer-accessibility-element-core-proto.patch b/patches/0002-ns-implement-buffer-accessibility-element-core-proto.patch index f40bf66..cc6fef1 100644 --- a/patches/0002-ns-implement-buffer-accessibility-element-core-proto.patch +++ b/patches/0002-ns-implement-buffer-accessibility-element-core-proto.patch @@ -1,4 +1,4 @@ -From 68ce438269f04570f21e92bd2c49f2ff83244cb8 Mon Sep 17 00:00:00 2001 +From 9233586621907a44b6a6a1257d6965bf1c2fcee8 Mon Sep 17 00:00:00 2001 From: Martin Sukany Date: Sat, 28 Feb 2026 12:58:11 +0100 Subject: [PATCH 2/8] ns: implement buffer accessibility element (core diff --git a/patches/0003-ns-add-buffer-notification-dispatch-and-mode-line-el.patch b/patches/0003-ns-add-buffer-notification-dispatch-and-mode-line-el.patch index 222dcd5..70a83c2 100644 --- a/patches/0003-ns-add-buffer-notification-dispatch-and-mode-line-el.patch +++ b/patches/0003-ns-add-buffer-notification-dispatch-and-mode-line-el.patch @@ -1,4 +1,4 @@ -From f5ce42e931a3ed1668e6fb8260ef736442d8d2c9 Mon Sep 17 00:00:00 2001 +From d3bcf0db4dd16b70dc816fe3e6463b9f5ca7a9c2 Mon Sep 17 00:00:00 2001 From: Martin Sukany Date: Sat, 28 Feb 2026 12:58:11 +0100 Subject: [PATCH 3/8] ns: add buffer notification dispatch and mode-line diff --git a/patches/0004-ns-add-interactive-span-elements-for-Tab-navigation.patch b/patches/0004-ns-add-interactive-span-elements-for-Tab-navigation.patch index 8dd1e81..67d029b 100644 --- a/patches/0004-ns-add-interactive-span-elements-for-Tab-navigation.patch +++ b/patches/0004-ns-add-interactive-span-elements-for-Tab-navigation.patch @@ -1,4 +1,4 @@ -From 8675f0f75a33e4a3621e0b1e15aab7eff2c81369 Mon Sep 17 00:00:00 2001 +From 30fc5f90489e8802ed950317076ce39cdab66d25 Mon Sep 17 00:00:00 2001 From: Martin Sukany Date: Sat, 28 Feb 2026 12:58:11 +0100 Subject: [PATCH 4/8] ns: add interactive span elements for Tab navigation diff --git a/patches/0005-ns-integrate-accessibility-with-EmacsView-and-redisp.patch b/patches/0005-ns-integrate-accessibility-with-EmacsView-and-redisp.patch index 439fd5a..de089d4 100644 --- a/patches/0005-ns-integrate-accessibility-with-EmacsView-and-redisp.patch +++ b/patches/0005-ns-integrate-accessibility-with-EmacsView-and-redisp.patch @@ -1,4 +1,4 @@ -From 9e7fa018ef779610b2fb54c1ff951d0bf6bf7652 Mon Sep 17 00:00:00 2001 +From f1e29f1ec0695a7c97bfc5587274995a4b1052f1 Mon Sep 17 00:00:00 2001 From: Martin Sukany Date: Sat, 28 Feb 2026 12:58:11 +0100 Subject: [PATCH 5/8] ns: integrate accessibility with EmacsView and redisplay @@ -23,9 +23,9 @@ block cursor, org-mode folded headings, indirect buffers. Known limitations documented in patch 6 Texinfo node. --- etc/NEWS | 13 ++ - src/nsterm.h | 2 +- + src/nsterm.h | 2 + src/nsterm.m | 373 ++++++++++++++++++++++++++++++++++++++++++++++++++- - 3 files changed, 384 insertions(+), 4 deletions(-) + 3 files changed, 385 insertions(+), 3 deletions(-) diff --git a/etc/NEWS b/etc/NEWS index ef36df5..e76ee93 100644 @@ -52,14 +52,14 @@ index ef36df5..e76ee93 100644 ** Re-introduced dictation, lost in Emacs v30 (macOS). We lost macOS dictation in v30 when migrating to NSTextInputClient. diff --git a/src/nsterm.h b/src/nsterm.h -index 5298386..ec7b587 100644 +index ca67bd9..ec7b587 100644 --- a/src/nsterm.h +++ b/src/nsterm.h -@@ -594,7 +594,7 @@ typedef NS_ENUM (NSInteger, EmacsAXSpanType) +@@ -593,6 +593,8 @@ typedef NS_ENUM (NSInteger, EmacsAXSpanType) + Lisp_Object lastRootWindow; BOOL accessibilityTreeValid; BOOL accessibilityUpdating; - @public /* Accessed by ns_draw_phys_cursor (C function). */ -- NSRect lastAccessibilityCursorRect; ++ @public /* Accessed by ns_draw_phys_cursor (C function). */ + NSRect lastCursorRect; #endif BOOL font_panel_active; diff --git a/patches/0006-doc-add-VoiceOver-accessibility-section-to-macOS-app.patch b/patches/0006-doc-add-VoiceOver-accessibility-section-to-macOS-app.patch index 54c4492..a101064 100644 --- a/patches/0006-doc-add-VoiceOver-accessibility-section-to-macOS-app.patch +++ b/patches/0006-doc-add-VoiceOver-accessibility-section-to-macOS-app.patch @@ -1,4 +1,4 @@ -From 683d7497cc3414a231b44363dd28d2748780c38a Mon Sep 17 00:00:00 2001 +From 4957ac5c94e8266688ed8479b21f2322e2aa4c86 Mon Sep 17 00:00:00 2001 From: Martin Sukany Date: Sat, 28 Feb 2026 12:58:11 +0100 Subject: [PATCH 6/8] doc: add VoiceOver accessibility section to macOS diff --git a/patches/0007-ns-announce-overlay-completion-candidates-for-VoiceO.patch b/patches/0007-ns-announce-overlay-completion-candidates-for-VoiceO.patch index dc2d850..982e7e0 100644 --- a/patches/0007-ns-announce-overlay-completion-candidates-for-VoiceO.patch +++ b/patches/0007-ns-announce-overlay-completion-candidates-for-VoiceO.patch @@ -1,4 +1,4 @@ -From 8561d7b8a00b9a7772c718f86fdde770e1c73d41 Mon Sep 17 00:00:00 2001 +From 479cfe85e8efc97c184ca68bbe4373d762e5841f Mon Sep 17 00:00:00 2001 From: Martin Sukany Date: Sat, 28 Feb 2026 14:46:25 +0100 Subject: [PATCH 7/8] ns: announce overlay completion candidates for VoiceOver diff --git a/patches/0008-ns-announce-child-frame-completion-candidates-for-Vo.patch b/patches/0008-ns-announce-child-frame-completion-candidates-for-Vo.patch index df54b3e..2ebd346 100644 --- a/patches/0008-ns-announce-child-frame-completion-candidates-for-Vo.patch +++ b/patches/0008-ns-announce-child-frame-completion-candidates-for-Vo.patch @@ -1,4 +1,4 @@ -From 058cc9aad5c34796206749844df28acc9e09f0eb Mon Sep 17 00:00:00 2001 +From c76af5456ed23045749a221bd42896e8f8e8601a Mon Sep 17 00:00:00 2001 From: Martin Sukany Date: Sat, 28 Feb 2026 16:01:29 +0100 Subject: [PATCH 8/8] ns: announce child frame completion candidates for