Add native wxHyperlinkCtrl implementation for macOS (PR #27059)

15 views
Skip to first unread message

Quin Gillespie

unread,
Sep 21, 2026, 10:25:59 PM (19 hours ago) Sep 21
to wx-...@googlegroups.com, Subscribed

Like the collapsible header (#27058), wxHyperlinkCtrl is custom drawn under macOS and so invisible to VoiceOver, which is the other part of the generic about dialog that its users couldn't use (see #27057).

There is no native hyperlink control under macOS, so this uses a borderless button showing an underlined label in the link colour, and reports it as a link to VoiceOver. Like the wxGTK and wxMSW native versions, it derives from wxGenericHyperlinkCtrl, which stores the URL and the colours, and it uses the normal and visited colours, but not the hover one. Clicking it, Space and the VoiceOver press action all mark it as visited and send wxEVT_HYPERLINK, opening the URL by default, and the context menu is still connected for wxHL_CONTEXTMENU.

Tested with VoiceOver on macOS 26 in the generic about dialog: the link is read as a link and pressing it opens the URL. I checked the appearance by rendering the dialog into an image, as I can't see the screen, and it looks the same as the generic version.

Tab navigation in this dialog is a bit strange under macOS: the first Tab press after opening the dialog skips the link and the first pane header, which can still be reached using Shift-Tab. I suspect that the keyboard focus is initially already on one of them and this is a general wxOSX keyboard navigation issue rather than a problem with this control.

build/upmake was run to update the file lists, but Makefile.in and the Xcode project are not updated, as I don't have Bakefile here. The file lists will conflict with #27058, as both add files at the same place, but running build/upmake again after merging the other one resolves this.


You can view, comment on, or merge this pull request online at:

  https://github.com/wxWidgets/wxWidgets/pull/27059

Commit Summary

  • 705b09d Add native wxHyperlinkCtrl implementation for macOS

File Changes

(6 files)

Patch Links:


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.Message ID: <wxWidgets/wxWidgets/pull/27059@github.com>

Quin Gillespie

unread,
Sep 21, 2026, 10:41:06 PM (19 hours ago) Sep 21
to wx-...@googlegroups.com, Push

@trypsynth pushed 1 commit.

  • 9ee9325 Add native wxHyperlinkCtrl to Makefile.in and Xcode project


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.Message ID: <wxWidgets/wxWidgets/pull/27059/before/705b09d79dd7a979b6af919fd7b8d4db4a9ca6ed/after/9ee9325094ba4cdb35b9ea978a05ed4cf1988681@github.com>

VZ

unread,
7:36 AM (10 hours ago) 7:36 AM
to wx-...@googlegroups.com, Subscribed

@vadz commented on this pull request.

Same comment as for the previous PR: looks good to me, but I didn't test it, so if any Mac people could do it, this would be very welcome.

@csomor @vslavik Sorry to keep tagging you, but please have a look at this one too if you can.


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.Message ID: <wxWidgets/wxWidgets/pull/27059/review/5277422866@github.com>

Steve Cornett

unread,
1:16 PM (4 hours ago) 1:16 PM
to wx-...@googlegroups.com, Subscribed
stevecor left a comment (wxWidgets/wxWidgets#27059)

When the mouse moves over the hyperlink, the pointer incorrectly does not change to the hand cursor. It remains the arrow cursor. Tested on macOS 26.6.2.


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.Message ID: <wxWidgets/wxWidgets/pull/27059/c5780813204@github.com>

Quin Gillespie

unread,
1:33 PM (4 hours ago) 1:33 PM
to wx-...@googlegroups.com, Push

@trypsynth pushed 1 commit.

  • 34753e1 fix missing hand cursor over native wxHyperlinkCtrl under macOS


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.Message ID: <wxWidgets/wxWidgets/pull/27059/before/9ee9325094ba4cdb35b9ea978a05ed4cf1988681/after/34753e1433df28fc8bcacc8cead1d8238f74c612@github.com>

Quin Gillespie

unread,
1:34 PM (4 hours ago) 1:34 PM
to wx-...@googlegroups.com, Subscribed
trypsynth left a comment (wxWidgets/wxWidgets#27059)

@stevecor Thanks a lot for testing! I've pushed a fix setting the hand cursor for the control, as the generic version does when the mouse is over the link. wxOSX already sets the window cursor when the mouse enters a native view, so this should be enough, but I can't check it myself as I can't see the screen. Could you please test it again?


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.Message ID: <wxWidgets/wxWidgets/pull/27059/c5781061090@github.com>

Steve Cornett

unread,
2:09 PM (3 hours ago) 2:09 PM
to wx-...@googlegroups.com, Subscribed
stevecor left a comment (wxWidgets/wxWidgets#27059)

The mouse pointer correctly changes to the hand icon now.


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.Message ID: <wxWidgets/wxWidgets/pull/27059/c5781544603@github.com>

Quin Gillespie

unread,
4:24 PM (1 hour ago) 4:24 PM
to wx-...@googlegroups.com, Subscribed
trypsynth left a comment (wxWidgets/wxWidgets#27059)

@stevecor Thanks a lot for testing it again!


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.Message ID: <wxWidgets/wxWidgets/pull/27059/c5783564799@github.com>

Reply all
Reply to author
Forward
0 new messages