patches: fix 3 blockers — duplicate functions, idx typo, doc cap

BLOCKER fixes:
1. Remove duplicate ns_ax_face_is_selected, ns_ax_selected_overlay_text,
   ns_ax_selected_child_frame_text definitions from patch 0002
   (now defined only in 0007/0008 where they belong)
2. Fix idx → point_idx in accessibilityInsertionPointLineNumber (0002)
3. Remove stale 100K cap reference from documentation (0006)

Architecture fix:
- ns_ax_selected_child_frame_text moved from 0007 to 0008
  (where it logically belongs)

Verified: all 8 patches apply cleanly on fresh emacs HEAD.
This commit is contained in:
2026-02-28 22:00:10 +01:00
parent 30089e9413
commit bbe683e752
8 changed files with 84 additions and 342 deletions

View File

@@ -1,4 +1,4 @@
From 3bbe8ba29725a4708595befa6b73e5873a2aab43 Mon Sep 17 00:00:00 2001
From e8472811cf1d730e10b01d2e10d6a158f0cf441a Mon Sep 17 00:00:00 2001
From: Martin Sukany <martin@sukany.cz>
Date: Sat, 28 Feb 2026 12:58:11 +0100
Subject: [PATCH 5/8] ns: integrate accessibility with EmacsView and redisplay
@@ -29,10 +29,10 @@ Known limitations documented in patch 6 Texinfo node.
2 files changed, 408 insertions(+), 3 deletions(-)
diff --git a/etc/NEWS b/etc/NEWS
index 7367e3c..608650e 100644
index 04bf92a..bd94b66 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -4374,6 +4374,19 @@ allowing Emacs users access to speech recognition utilities.
@@ -4382,6 +4382,19 @@ allowing Emacs users access to speech recognition utilities.
Note: Accepting this permission allows the use of system APIs, which may
send user data to Apple's speech recognition servers.
@@ -53,10 +53,10 @@ index 7367e3c..608650e 100644
** Re-introduced dictation, lost in Emacs v30 (macOS).
We lost macOS dictation in v30 when migrating to NSTextInputClient.
diff --git a/src/nsterm.m b/src/nsterm.m
index 91d0241..125e52c 100644
index c852929..b3bef4b 100644
--- a/src/nsterm.m
+++ b/src/nsterm.m
@@ -1105,6 +1105,11 @@ ns_update_end (struct frame *f)
@@ -1105,6 +1105,11 @@ static NSRect constrain_frame_rect(NSRect frameRect, bool isFullscreen)
unblock_input ();
ns_updating_frame = NULL;
@@ -68,7 +68,7 @@ index 91d0241..125e52c 100644
}
static void
@@ -3233,6 +3238,43 @@ ns_draw_window_cursor (struct window *w, struct glyph_row *glyph_row,
@@ -3233,6 +3238,43 @@ Note that CURSOR_WIDTH is meaningful only for (h)bar cursors.
/* Prevent the cursor from being drawn outside the text area. */
r = NSIntersectionRect (r, ns_row_rect (w, glyph_row, TEXT_AREA));
@@ -112,7 +112,7 @@ index 91d0241..125e52c 100644
ns_focus (f, NULL, 0);
NSGraphicsContext *ctx = [NSGraphicsContext currentContext];
@@ -7531,7 +7573,6 @@ ns_ax_post_notification_with_info (id element,
@@ -7281,7 +7323,6 @@ - (id)accessibilityTopLevelUIElement
@@ -120,7 +120,7 @@ index 91d0241..125e52c 100644
static BOOL
ns_ax_find_completion_overlay_range (struct buffer *b, ptrdiff_t point,
ptrdiff_t *out_start,
@@ -8625,7 +8666,6 @@ ns_ax_completion_text_for_span (EmacsAccessibilityBuffer *elem,
@@ -8375,7 +8416,6 @@ - (NSRect)accessibilityFrame
@end
@@ -128,7 +128,7 @@ index 91d0241..125e52c 100644
/* ===================================================================
EmacsAccessibilityBuffer (Notifications) — AX event dispatch
@@ -9170,7 +9210,6 @@ ns_ax_completion_text_for_span (EmacsAccessibilityBuffer *elem,
@@ -8920,7 +8960,6 @@ - (NSRect)accessibilityFrame
@end
@@ -136,7 +136,7 @@ index 91d0241..125e52c 100644
/* ===================================================================
EmacsAccessibilityInteractiveSpan — helpers and implementation
=================================================================== */
@@ -9500,6 +9539,7 @@ ns_ax_scan_interactive_spans (struct window *w,
@@ -9250,6 +9289,7 @@ - (void)dealloc
[layer release];
#endif
@@ -144,7 +144,7 @@ index 91d0241..125e52c 100644
[[self menu] release];
[super dealloc];
}
@@ -10848,6 +10888,32 @@ ns_in_echo_area (void)
@@ -10598,6 +10638,32 @@ - (void)windowDidBecomeKey /* for direct calls */
XSETFRAME (event.frame_or_window, emacsframe);
kbd_buffer_store_event (&event);
ns_send_appdefined (-1); // Kick main loop
@@ -177,7 +177,7 @@ index 91d0241..125e52c 100644
}
@@ -12085,6 +12151,332 @@ ns_in_echo_area (void)
@@ -11835,6 +11901,332 @@ - (int) fullscreenState
return fs_state;
}