Merge remote-tracking branch 'refs/remotes/origin/master'

This commit is contained in:
Martin Sukany
2026-02-26 11:58:23 +01:00

View File

@@ -5,14 +5,19 @@ Subject: [PATCH] ns: add macOS Zoom cursor tracking and VoiceOver accessibility
Dual accessibility: UAZoomChangeFocus for Zoom + virtual element tree for Dual accessibility: UAZoomChangeFocus for Zoom + virtual element tree for
VoiceOver. Notifications target the focused virtual element, not EmacsView. VoiceOver. Notifications target the focused virtual element, not EmacsView.
Full hierarchy plumbing (accessibilityWindow, accessibilityParent, etc.). Full hierarchy plumbing (accessibilityWindow, accessibilityParent, etc.).
MRC compatible. MRC compatible. Single notification path (post-redisplay only) with
glyph-consistent coordinate system throughout.
--- ---
--- a/src/nsterm.h 2026-02-26 08:46:18.118172281 +0100 diff --git a/src/nsterm.h b/src/nsterm.h
+++ b/src/nsterm.h 2026-02-26 09:08:57.204955708 +0100 index 7c1ee4c..1f9639c 100644
@@ -455,6 +455,34 @@ --- a/src/nsterm.h
+++ b/src/nsterm.h
@@ -453,6 +453,34 @@ enum ns_return_frame_mode
@end
/* ==========================================================================
+/* ==========================================================================
+
+ Accessibility virtual elements (macOS / Cocoa only) + Accessibility virtual elements (macOS / Cocoa only)
+ +
+ ========================================================================== */ + ========================================================================== */
@@ -39,12 +44,10 @@ MRC compatible.
+#endif /* NS_IMPL_COCOA */ +#endif /* NS_IMPL_COCOA */
+ +
+ +
+/* ========================================================================== /* ==========================================================================
+
The main Emacs view
========================================================================== */ The main Emacs view
@@ -471,6 +499,12 @@ @@ -471,6 +499,11 @@ enum ns_return_frame_mode
#ifdef NS_IMPL_COCOA #ifdef NS_IMPL_COCOA
char *old_title; char *old_title;
BOOL maximizing_resize; BOOL maximizing_resize;
@@ -56,7 +59,7 @@ MRC compatible.
#endif #endif
BOOL font_panel_active; BOOL font_panel_active;
NSFont *font_panel_result; NSFont *font_panel_result;
@@ -528,6 +562,12 @@ @@ -528,6 +561,12 @@ enum ns_return_frame_mode
- (void)windowWillExitFullScreen; - (void)windowWillExitFullScreen;
- (void)windowDidExitFullScreen; - (void)windowDidExitFullScreen;
- (void)windowDidBecomeKey; - (void)windowDidBecomeKey;
@@ -69,9 +72,11 @@ MRC compatible.
@end @end
--- a/src/nsterm.m 2026-02-26 08:46:18.124172384 +0100 diff --git a/src/nsterm.m b/src/nsterm.m
+++ b/src/nsterm.m 2026-02-26 10:46:54.607568839 +0100 index 932d209..077f092 100644
@@ -1104,6 +1104,11 @@ --- a/src/nsterm.m
+++ b/src/nsterm.m
@@ -1104,6 +1104,11 @@ static NSRect constrain_frame_rect(NSRect frameRect, bool isFullscreen)
unblock_input (); unblock_input ();
ns_updating_frame = NULL; ns_updating_frame = NULL;
@@ -83,7 +88,7 @@ MRC compatible.
} }
static void static void
@@ -3232,6 +3237,82 @@ @@ -3232,6 +3237,37 @@ Note that CURSOR_WIDTH is meaningful only for (h)bar cursors.
/* Prevent the cursor from being drawn outside the text area. */ /* Prevent the cursor from being drawn outside the text area. */
r = NSIntersectionRect (r, ns_row_rect (w, glyph_row, TEXT_AREA)); r = NSIntersectionRect (r, ns_row_rect (w, glyph_row, TEXT_AREA));
@@ -121,10 +126,12 @@ MRC compatible.
ns_focus (f, NULL, 0); ns_focus (f, NULL, 0);
NSGraphicsContext *ctx = [NSGraphicsContext currentContext]; NSGraphicsContext *ctx = [NSGraphicsContext currentContext];
@@ -6849,6 +6930,646 @@ @@ -6847,6 +6883,652 @@ - (BOOL)fulfillService: (NSString *)name withArg: (NSString *)arg
}
/* ========================================================================== #endif
+/* ==========================================================================
+
+ Accessibility virtual elements (macOS / Cocoa only) + Accessibility virtual elements (macOS / Cocoa only)
+ +
+ ========================================================================== */ + ========================================================================== */
@@ -769,12 +776,10 @@ MRC compatible.
+#endif /* NS_IMPL_COCOA */ +#endif /* NS_IMPL_COCOA */
+ +
+ +
+/* ========================================================================== /* ==========================================================================
+
EmacsView implementation
========================================================================== */ EmacsView implementation
@@ -6889,6 +7610,7 @@ @@ -6889,6 +7571,7 @@ - (void)dealloc
[layer release]; [layer release];
#endif #endif
@@ -782,7 +787,7 @@ MRC compatible.
[[self menu] release]; [[self menu] release];
[super dealloc]; [super dealloc];
} }
@@ -8237,6 +8959,18 @@ @@ -8237,6 +8920,18 @@ - (void)windowDidBecomeKey /* for direct calls */
XSETFRAME (event.frame_or_window, emacsframe); XSETFRAME (event.frame_or_window, emacsframe);
kbd_buffer_store_event (&event); kbd_buffer_store_event (&event);
ns_send_appdefined (-1); // Kick main loop ns_send_appdefined (-1); // Kick main loop
@@ -801,7 +806,7 @@ MRC compatible.
} }
@@ -9474,6 +10208,391 @@ @@ -9474,6 +10169,213 @@ - (int) fullscreenState
return fs_state; return fs_state;
} }
@@ -1015,7 +1020,7 @@ MRC compatible.
@end /* EmacsView */ @end /* EmacsView */
@@ -9941,6 +11060,14 @@ @@ -9941,6 +10843,14 @@ - (id)accessibilityAttributeValue:(NSString *)attribute
return [super accessibilityAttributeValue:attribute]; return [super accessibilityAttributeValue:attribute];
} }