On Thu, 25 Nov 2021 12:57:20 GMT, Artem Semenov <aseme...@openjdk.org> wrote:
>> src/java.desktop/share/classes/javax/swing/JLabel.java line 1091: >> >>> 1089: (JLabel.this.getIcon() != null)) { >>> 1090: name = >>> ResourceBundle.getBundle("com.sun.accessibility.internal.resources.accessibility", >>> Locale.getDefault()).getString("image"); >>> 1091: } >> >> Probably it should somehow ask the icon itself about possible description? I >> guess the JLabel should work similar to >> Icon/ImageIcon/AccessibleImageIcon/etc when the text is empty but the icon >> is set. But I am not sure that the iicons are supported by the a11y in >> Swing, for example how the reader will cover the simple Icon? Will it say >> something? > > Done. thank you very much. I few questions to thinking about: - If the label and icon is not accessible then should we say something? Or we should ignore it like we do for any other non-accessible components? - Why the image text is used, don't we need to use the "javax.accessibility.AccessibleRole#ICON" role for such label/icon and allow the reader to say something standard for the icon. Does the voiceover has some default text for the icon/image when the alt text is not set? ------------- PR: https://git.openjdk.java.net/jdk/pull/6538