Bug 142231 - Appearance page color buttons not accessible
Summary: Appearance page color buttons not accessible
Status: RESOLVED FIXED
Alias: None
Product: GMF-Runtime
Classification: Modeling
Component: General (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 normal
Target Milestone: 1.0.1   Edit
Assignee: Syed Atif CLA
QA Contact:
URL:
Whiteboard:
Keywords: accessibility
Depends on:
Blocks:
 
Reported: 2006-05-17 10:54 EDT by Syed Atif CLA
Modified: 2010-07-19 12:30 EDT (History)
3 users (show)

See Also:


Attachments
Patch that adds accessibility listeners to color selector buttons (3.18 KB, patch)
2006-05-18 12:29 EDT, Syed Atif CLA
no flags Details | Diff
Appearance page which shows the problem (43.58 KB, image/jpeg)
2006-05-19 14:22 EDT, Syed Atif CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Syed Atif CLA 2006-05-17 10:54:33 EDT
(We are currently undergoing an accessibility checklist for our plugin which uses ColorFieldEditor in its preferences page.)

It seems that the ColorFieldEditor is not accessible, i.e., the label associated with the button in the ColorFieldEditor cannot be narrated by any narrator (including the default Narrator tool in Windows XP as well as JAWS). This may be because the field associated with the label is a button and is not an input field and narrators only associate input fields with labels on the left so that they can read the labels for those fields.

A couple of possible solutions: 
(1) combine the label field into the button so that the selected color becomes into an 'icon' for the button, along with the label as the text of the button;
(2) use a combo box color selector instead of the button, as combo boxes are taken as input fields by narrators. That way the narrator can associate the label field with the combo box and thus read it.
Comment 1 Susan McCourt CLA 2006-05-17 14:58:10 EDT
I don't see us changing the implementation of the color selector, but I think we could solve this inside the field editor by installing an accessibility listener on the button that returns the field editor label value.  Karice, does this sound right to you?

If you need an immediate solution in the client code, you could do this yourself.  Something like...

Button colorButton = myColorFieldEditor.getColorSelector().getButton();
colorButton.getAccessible.addAccessibilityListener(new AccessibleAdapter() {
      public void getName(AccessibleEvent e) {
          return myColorFieldEditor.getLabelText();
		}};

Marking this for investigation for 3.2.1
Comment 2 Tod Creasey CLA 2006-05-17 15:48:54 EDT
The ColorSelector has an accessible listener that gives the information. If you run a tool that reads the windows accessibility API (like inspect 32) you will see that the name is "Color Selector".

You can see this by hovering over it and checking the name in inspect32. I have just checked with JAWS 6.0 and it is not reading the accessible listener so I suspect this is a bug in JAWS.
Comment 3 Susan McCourt CLA 2006-05-17 16:15:13 EDT
Once we understand why it's not being read...

...I wonder if we should consider using the field editor's label for accessibility info if one is provided, and using "Color Selector" if there is no label provided.  This way apps would have more control over the accessibility info and the label would be read as expected.

Comment 4 Carolyn MacLeod CLA 2006-05-17 16:16:57 EDT
See bug 21771. The "JAWS doesn't speak the name of image buttons" bug has been reported to JAWS, fixed by JAWS, and subsequently broken by JAWS - multiple times. I'll report it again.

FYI, Window-Eyes correctly speaks "Color Selector" when the button gets focus.
There is nothing else we can do. I think you can close this bug.
Comment 5 Susan McCourt CLA 2006-05-17 16:29:16 EDT
Syed,
For those systems such as Windows Eyes that properly read the info...
Is it sufficient that "Color Selector" is read as the accessibility info vs. the assigned label text of the field editor?

I will close this bug if "Color Selector" is sufficient.
Comment 6 Syed Atif CLA 2006-05-18 12:24:19 EDT
Reassigning this from Platform (JFace) to GMF. Going to use the workaround suggested above by Susan Franklin.
Comment 7 Syed Atif CLA 2006-05-18 12:29:02 EDT
Created attachment 41904 [details]
Patch that adds accessibility listeners to color selector buttons

This patch adds accessiblity listeners and provides accessible descriptions. This enables narrators to correctly read the labels associated with each color button.
Comment 8 Steven R. Shaw CLA 2006-05-19 11:06:08 EDT
reassigning to Syed to apply the workaround to GMF
Comment 9 Susan McCourt CLA 2006-05-19 12:45:03 EDT
I thought there were two issues going on here:
1) Even though JFace hooks an accessibility listener to use the string "Color Selector," it seemed that some screen readers such as JAWS were ignoring it anyway.  Was this your observation?

2) Your patch adds an accessibility listener with the field editor label.  This is more flexible/nicer than JFace's use of "Color Selector," but if the original label was never being read, I wouldn't expect the new label to be read.

Please open a bug on JFace if your intention is that the field editor label should be used instead of "Color Selector."  The workaround is good for 3.2 timeframe, but we should fix this in JFace proper for 3.3.
Comment 10 Syed Atif CLA 2006-05-19 14:22:03 EDT
Created attachment 42058 [details]
Appearance page which shows the problem

In reply to Susan Franklin,

1. Screen readers are not ignoring anything, and are narrating 'Color Selector' by default on each button (unless my patch is applied, ofcourse).

2. You can see from the screenshot here that we have multiple color selectors...thus the default text narrated is 'Color Selector' for each of the buttons. This is not very useful in terms of actual accessibility. By default, I believe it should associate the accessibility name of the control to the label text, and the 'Color Selector' part can, perhaps, be provided as the description of the control (for example, instead of the default 'Push button -to press, use Space bar', the button's accessibility listener method can be overridden to provide 'Color selector - to select, use space bar').

If there's any specific reason why this should not/cannot be done, I will not raise a bugzilla.
Comment 11 Susan McCourt CLA 2006-05-19 14:34:52 EDT
It should be possible for us to install the listener with the field editor label as the text.  Your workaround is a good one for now since 3.2 is frozen, but please move this bug back to JFace or open a new one so that we fix it correctly for 3.3.
Comment 12 Frank DiPalermo CLA 2006-05-30 09:56:47 EDT
I will report this problem to Freedom Scientific, the manufacturer of JAWS.
Comment 13 Syed Atif CLA 2006-05-30 14:42:02 EDT
(In reply to comment #12)
> I will report this problem to Freedom Scientific, the manufacturer of JAWS.
> 

The problem is not with JAWS but rather that the screen readers are narrating "Color Selector" instead of the label associated with the color selector button. Please see Bug 142826 for more info.
Comment 14 Syed Atif CLA 2006-07-18 11:15:33 EDT
workaround patch committed for 1.0.100
Comment 15 Eclipse Webmaster CLA 2010-07-19 12:30:10 EDT
[GMF Restructure] Bug 319140 : product GMF and component
Runtime Diagram was the original product and component for this bug