Revert "patches: fix Corfu completion tracking in Zoom"

This reverts commit d15fe43bf0.
This commit is contained in:
2026-03-01 07:05:33 +01:00
parent d15fe43bf0
commit 19cc43dbbb
9 changed files with 76 additions and 82 deletions

View File

@@ -1,4 +1,4 @@
From 52bbb70e63cf384daa353394b2f5a1857f9912b7 Mon Sep 17 00:00:00 2001
From 61a0ae5344e6f52cb21ae299133b39b2ede010d0 Mon Sep 17 00:00:00 2001
From: Martin Sukany <martin@sukany.cz>
Date: Sat, 28 Feb 2026 12:58:11 +0100
Subject: [PATCH 6/9] ns: integrate accessibility with EmacsView and redisplay
@@ -51,10 +51,10 @@ index 80661a9..2b1f9e6 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 d8b18ae..ff03ee6 100644
index 5eaf480..4ad451f 100644
--- a/src/nsterm.m
+++ b/src/nsterm.m
@@ -1264,7 +1264,7 @@ If a completion candidate is selected (overlay or child frame),
@@ -1258,7 +1258,7 @@ If a completion candidate is selected (overlay or child frame),
static void
ns_zoom_track_completion (struct frame *f, EmacsView *view)
{
@@ -63,7 +63,7 @@ index d8b18ae..ff03ee6 100644
return;
if (!WINDOWP (f->selected_window))
return;
@@ -1384,7 +1384,8 @@ so the visual offset is (ov_line + 1) * line_h from
@@ -1378,7 +1378,8 @@ so the visual offset is (ov_line + 1) * line_h from
(zoomCursorUpdated is NO). */
#if defined (MAC_OS_X_VERSION_MIN_REQUIRED) \
&& MAC_OS_X_VERSION_MIN_REQUIRED >= 101000
@@ -73,7 +73,7 @@ index d8b18ae..ff03ee6 100644
&& !NSIsEmptyRect (view->lastCursorRect))
{
NSRect r = view->lastCursorRect;
@@ -1411,6 +1412,9 @@ so the visual offset is (ov_line + 1) * line_h from
@@ -1405,6 +1406,9 @@ so the visual offset is (ov_line + 1) * line_h from
if (view)
ns_zoom_track_completion (f, view);
#endif /* NS_IMPL_COCOA */
@@ -83,7 +83,7 @@ index d8b18ae..ff03ee6 100644
}
static void
@@ -3558,7 +3562,7 @@ EmacsView pixels (AppKit, flipped, top-left origin)
@@ -3552,7 +3556,7 @@ EmacsView pixels (AppKit, flipped, top-left origin)
#if defined (MAC_OS_X_VERSION_MIN_REQUIRED) \
&& MAC_OS_X_VERSION_MIN_REQUIRED >= 101000
@@ -92,7 +92,7 @@ index d8b18ae..ff03ee6 100644
{
NSRect windowRect = [view convertRect:r toView:nil];
NSRect screenRect
@@ -6723,9 +6727,56 @@ - (void)applicationDidFinishLaunching: (NSNotification *)notification
@@ -6717,9 +6721,56 @@ - (void)applicationDidFinishLaunching: (NSNotification *)notification
}
#endif
@@ -149,7 +149,7 @@ index d8b18ae..ff03ee6 100644
- (void)antialiasThresholdDidChange:(NSNotification *)notification
{
#ifdef NS_IMPL_COCOA
@@ -7626,7 +7677,6 @@ - (id)accessibilityTopLevelUIElement
@@ -7620,7 +7671,6 @@ - (id)accessibilityTopLevelUIElement
@@ -157,7 +157,7 @@ index d8b18ae..ff03ee6 100644
static BOOL
ns_ax_find_completion_overlay_range (struct buffer *b, ptrdiff_t point,
ptrdiff_t *out_start,
@@ -8728,7 +8778,6 @@ - (NSRect)accessibilityFrame
@@ -8722,7 +8772,6 @@ - (NSRect)accessibilityFrame
@end
@@ -165,7 +165,7 @@ index d8b18ae..ff03ee6 100644
/* ===================================================================
EmacsAccessibilityBuffer (Notifications) — AX event dispatch
@@ -9273,7 +9322,6 @@ - (NSRect)accessibilityFrame
@@ -9267,7 +9316,6 @@ - (NSRect)accessibilityFrame
@end
@@ -173,7 +173,7 @@ index d8b18ae..ff03ee6 100644
/* ===================================================================
EmacsAccessibilityInteractiveSpan — helpers and implementation
=================================================================== */
@@ -9603,6 +9651,7 @@ - (void)dealloc
@@ -9597,6 +9645,7 @@ - (void)dealloc
[layer release];
#endif
@@ -181,7 +181,7 @@ index d8b18ae..ff03ee6 100644
[[self menu] release];
[super dealloc];
}
@@ -10951,6 +11000,32 @@ - (void)windowDidBecomeKey /* for direct calls */
@@ -10945,6 +10994,32 @@ - (void)windowDidBecomeKey /* for direct calls */
XSETFRAME (event.frame_or_window, emacsframe);
kbd_buffer_store_event (&event);
ns_send_appdefined (-1); // Kick main loop
@@ -214,7 +214,7 @@ index d8b18ae..ff03ee6 100644
}
@@ -12188,6 +12263,332 @@ - (int) fullscreenState
@@ -12182,6 +12257,332 @@ - (int) fullscreenState
return fs_state;
}
@@ -547,7 +547,7 @@ index d8b18ae..ff03ee6 100644
@end /* EmacsView */
@@ -14188,12 +14589,17 @@ Nil means use fullscreen the old (< 10.7) way. The old way works better with
@@ -14182,12 +14583,17 @@ Nil means use fullscreen the old (< 10.7) way. The old way works better with
ns_use_srgb_colorspace = YES;
DEFVAR_BOOL ("ns-accessibility-enabled", ns_accessibility_enabled,