On macOS (Cocoa port), a wxDataViewCustomRenderer-backed cell exposes no usable text to VoiceOver/the native accessibility tree. Instead of the value the renderer actually draws, VoiceOver reads the debug description of the internal wrapper object, e.g.:
File Name <wxCustomRendererObject: 0x878f82490>
Progress <wxCustomRendererObject: 0x878f81b20>
This was reported by a blind aMule user testing a wxDataViewCtrl-based rewrite of several list controls (amule-org/amule#180) — every plain-text column in the same list reads correctly, only the custom-rendered ones are affected.
In src/osx/cocoa/dataview.mm, the wxCustomRendererObject class that backs a custom-rendered cell's objectValue on Cocoa (set in wxCocoaDataViewControl::... around line 2950, [GetNativeData()->GetItemCell() setObjectValue:[[[wxCustomRendererObject alloc] initWithRenderer:this] autorelease]]) implements no accessibility protocol and no -description override — there are zero accessibility-related lines anywhere in that file (grep -c ccessib src/osx/cocoa/dataview.mm → 0). AppKit's default NSTableView/NSOutlineView accessibility bridging falls back to NSObject's default -description for the cell's object value, producing <ClassName: 0xpointer>.
This is unrelated to wxUSE_ACCESSIBILITY — that flag gates the generic/MSW wxAccessible layer (wx/generic/dataview.h, 13 references), which isn't used on Cocoa (wx/osx/dataview.h has none); Cocoa relies entirely on native NSAccessibility, which this code path never populates for custom renderers.
A wxDataViewCustomRenderer cell should expose a meaningful accessible value/label — presumably by consulting wxDataViewCustomRenderer::GetAccessibleDescription() (or a similar hook the renderer can override) and surfacing it via NSAccessibility (e.g. accessibilityValue/accessibilityLabel) on the wrapper object or the owning cell, instead of leaking the wrapper's default description.
wxDataViewCtrl on macOS with at least one column using a wxDataViewCustomRenderer subclass that draws text (or anything) directly rather than via the built-in text/bitmap renderers.<ClassName: 0xpointer> instead of the rendered content.AXUIElementCopyAttributeValue queries against the running control (same API Xcode's Accessibility Inspector uses), not just VoiceOver observationwxDataViewCtrl/macOS), but a distinct gap (missing accessible value, not missing accessible action)—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()
Unfortunately accessibility support is not implemented in any ports except for wxMSW. Any contributions to it would be welcome.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()