After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 630591 - Orca's _generateDisplayedText should return an empty list when there is no text.
Orca's _generateDisplayedText should return an empty list when there is no text.
Status: RESOLVED FIXED
Product: orca
Classification: Applications
Component: general
unspecified
Other All
: Normal normal
: 2.91.3
Assigned To: Joanmarie Diggs (IRC: joanie)
Orca Maintainers
Depends on:
Blocks:
 
 
Reported: 2010-09-25 20:05 UTC by Tom Masterson
Modified: 2010-11-29 13:29 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Debug file from eclipse session (117.46 KB, application/octet-stream)
2010-09-25 20:05 UTC, Tom Masterson
  Details
proposed fix (1.27 KB, patch)
2010-10-24 20:04 UTC, Joanmarie Diggs (IRC: joanie)
committed Details | Review

Description Tom Masterson 2010-09-25 20:05:04 UTC
Created attachment 171105 [details]
Debug file from eclipse session

When in eclipse if you tab through the toolbar all that shows in braille is the word "button".  With speech you get the proper button label.

To duplicate:
Open eclipse (3.6 or 3.7 though I recall this problem with other versions)
Highlight an item such as the project tree.
Tab through the options until you return to the tree.

As you go through the toolbar the braille display will show button several time while speech will tell you what those buttons actually are.
Comment 1 Joanmarie Diggs (IRC: joanie) 2010-10-24 19:45:54 UTC
The problem turns out not to be an Eclipse issue, but a quirk involving Orca's formatting strings. The change is simple enough, but it has the potential to impact all of Orca. Therefore, it will require thorough regression testing.

I'll take this one.
Comment 2 Joanmarie Diggs (IRC: joanie) 2010-10-24 20:04:15 UTC
Created attachment 173134 [details] [review]
proposed fix

For those curious, here's the fix. Basically, what is happening is the formatting strings, crazy beasts that they are, include this for generating braille for push buttons:

   asString(((label + displayedText) or description) + roleName)

meaning "go with the label plus the displayed text, and if that's None, go with the description instead." Well, in the reported bug, the label is None and there is no displayedText. But the fact that displayedText is a list containing an empty string is causing it to fail the 'None' test. Thus we are never bothering to get the description, which is where our wayward text/functional label happens to live. The solution is to return an empty list instead.

The potential problem/what requires regression testing is that *everything* at some point looks to _generateDisplayedText(). Everything *should* deal with the empty list gracefully, but I would not bet on it. Plus we might see unexpected differences in behavior as a result in this change.

I'll start the regression tests now.
Comment 3 Jose Vilmar Estacio de Souza 2010-11-01 19:16:58 UTC
I'm running with this patch applied a week ago. So far no problem.