-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
P4
-
Affects Version/s: 21, 25, 27
-
Component/s: client-libs
When you mouse over a JButton and a tooltip appears: VoiceOver aborts what it was saying and says something uninformative, like "in system dialog, content is empty, java has new system dialog". (So not only is VoiceOver interrupted: the new text it reads is unhelpful.)
This came up in a recent VPAT review for a desktop application.
That tooltip message is automatically provided in myButton.getAccessibleContext().getAccessibleDescription() , so assistive technologies already have access to the information in the tooltip. (That is: it's important that sighted and non-sighted users get very similar information, and that's not a problem in this case.)
The expected behavior (IMO) is for VoiceOver to not read the tooltips.
This appears to be what I experience in Safari 26.3 when I mouse over the next/back buttons in the toolbar. (There the tooltips are also read as the description / help tag for those buttons.)
Ideally I'd like this ticket to be resolved in a way that allows developers to "turn off" VoiceOver for other windows at their discretion, but the primary complaint here is tooltips.
Sample code:
import javax.swing.*;
import java.awt.*;
/**
* Test instructions:
* 1. Open app
* 2. Turn on VoiceOver
* 3. Move mouse over each button. Wait for tooltip to appear.
*
* Observe every time the tooltip appears, VoiceOver aborts what it was saying
* and says, "in system dialog, content is empty, java has new system dialog"
*
* Expected behavior: VoiceOver should not say anything when tooltips appear. Or if it must speak: it should say something descriptive/helpful.
*/
public class VoiceOverTooltipTest {
public static void main(String[] args) {
JFrame f = new JFrame();
JButton b1 = new JButton("But");
b1.setToolTipText("But it wasn't my fault, I was given those beans");
JButton b2 = new JButton("You");
b2.setToolTipText("You persuaded me to trade away my cow for beans.");
f.getContentPane().setLayout(new BorderLayout());
f.getContentPane().add(b1, BorderLayout.NORTH);
f.getContentPane().add(b2, BorderLayout.SOUTH);
f.pack();
f.setVisible(true);
}
}
This came up in a recent VPAT review for a desktop application.
That tooltip message is automatically provided in myButton.getAccessibleContext().getAccessibleDescription() , so assistive technologies already have access to the information in the tooltip. (That is: it's important that sighted and non-sighted users get very similar information, and that's not a problem in this case.)
The expected behavior (IMO) is for VoiceOver to not read the tooltips.
This appears to be what I experience in Safari 26.3 when I mouse over the next/back buttons in the toolbar. (There the tooltips are also read as the description / help tag for those buttons.)
Ideally I'd like this ticket to be resolved in a way that allows developers to "turn off" VoiceOver for other windows at their discretion, but the primary complaint here is tooltips.
Sample code:
import javax.swing.*;
import java.awt.*;
/**
* Test instructions:
* 1. Open app
* 2. Turn on VoiceOver
* 3. Move mouse over each button. Wait for tooltip to appear.
*
* Observe every time the tooltip appears, VoiceOver aborts what it was saying
* and says, "in system dialog, content is empty, java has new system dialog"
*
* Expected behavior: VoiceOver should not say anything when tooltips appear. Or if it must speak: it should say something descriptive/helpful.
*/
public class VoiceOverTooltipTest {
public static void main(String[] args) {
JFrame f = new JFrame();
JButton b1 = new JButton("But");
b1.setToolTipText("But it wasn't my fault, I was given those beans");
JButton b2 = new JButton("You");
b2.setToolTipText("You persuaded me to trade away my cow for beans.");
f.getContentPane().setLayout(new BorderLayout());
f.getContentPane().add(b1, BorderLayout.NORTH);
f.getContentPane().add(b2, BorderLayout.SOUTH);
f.pack();
f.setVisible(true);
}
}