juce::HyperlinkButton Accessibility Handler

Currently, juce::HyperlinkButton is read as being a “button” by screen readers. There already exists an AccessibilityRole for hyperlink, so can HyperlinkButton create its own AccessibilityHandler and report as being a hyperlink, in the same way that ToggleButton reports as being a toggleButton?

So in juce_HyperlinkButton.cpp, something like…

std::unique_ptr<AccessibilityHandler> HyperlinkButton::createAccessibilityHandler()
{
    return std::make_unique<ButtonAccessibilityHandler> (*this, AccessibilityRole::hyperlink);
}

We’ve heard from screen reader users that this would improve the experience as it would make it more obvious that it is a link which (likely) opens in a web browser, rather than performing some kind of in-app action.

Thanks for reporting, this is added here:

2 Likes

Amazing - thanks!