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 667376 - Orca doesn't present Panel items names
Orca doesn't present Panel items names
Status: RESOLVED FIXED
Product: gnome-shell
Classification: Core
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: gnome-shell-maint
gnome-shell-maint
: 667369 (view as bug list)
Depends on:
Blocks: 634016
 
 
Reported: 2012-01-05 19:25 UTC by Alejandro Piñeiro Iglesias (IRC: infapi00)
Modified: 2012-01-27 11:37 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Sets a name for each item (6.11 KB, patch)
2012-01-05 19:45 UTC, Alejandro Piñeiro Iglesias (IRC: infapi00)
none Details | Review
Sets name for several items on the top panel (7.35 KB, patch)
2012-01-06 18:52 UTC, Alejandro Piñeiro Iglesias (IRC: infapi00)
needs-work Details | Review
Setting a name/label_actor for several items on the panel (7.50 KB, patch)
2012-01-26 19:19 UTC, Alejandro Piñeiro Iglesias (IRC: infapi00)
committed Details | Review
Notify accessible name change (1.17 KB, patch)
2012-01-26 19:20 UTC, Alejandro Piñeiro Iglesias (IRC: infapi00)
committed Details | Review

Description Alejandro Piñeiro Iglesias (IRC: infapi00) 2012-01-05 19:25:11 UTC
STEPS TO REPRODUCE

1. Activate Screen Reader (Universal Access Settings)
2. Give the focus to the panel (Ctrl+Alt+Tab)
3. Navigate on the items

EXPECTED OUTCOME

Orca present a name/role combination for each item

ACTUAL OUTCOME

Only Activities do that (and with a wrong role, but this is a different bug)
Comment 1 Alejandro Piñeiro Iglesias (IRC: infapi00) 2012-01-05 19:45:32 UTC
Created attachment 204706 [details] [review]
Sets a name for each item

This patchs sets a proper name, but in the case of the PanelMenu.Button, it creates a St.Label just to be used as the accessible label. This is because there isn't any St.Widget.set_accessible_name (text). 

Anyway, having a label_actor to expose the name is coherent with some items. In the case of the date, I use the internal date label as the label_actor.

Note that the role are still fuzzy, but this is a different bug.
Comment 2 Alejandro Piñeiro Iglesias (IRC: infapi00) 2012-01-06 18:48:41 UTC
(In reply to comment #0)
> STEPS TO REPRODUCE
> 
> 1. Activate Screen Reader (Universal Access Settings)
> 2. Give the focus to the panel (Ctrl+Alt+Tab)
> 3. Navigate on the items

In the end I decided that this and bug 667369 should be the same bug. So:

4. For each menu, open it and navigate on the subitems
Comment 3 Alejandro Piñeiro Iglesias (IRC: infapi00) 2012-01-06 18:49:05 UTC
*** Bug 667369 has been marked as a duplicate of this bug. ***
Comment 4 Alejandro Piñeiro Iglesias (IRC: infapi00) 2012-01-06 18:52:11 UTC
Created attachment 204769 [details] [review]
Sets name for several items on the top panel

This includes each icon on the panel, menu subitems, etc
Comment 5 Owen Taylor 2012-01-24 22:21:48 UTC
Review of attachment 204769 [details] [review]:

Generally looks good to me, just a few things

::: js/ui/panel.js
@@ +536,2 @@
         this._label.setText(targetApp.get_name());
+        this.setName(targetApp.get_name());

This seems to destroy and create labels on every focus change - not necessarily a big problem but maybe not necessary?

::: js/ui/panelMenu.js
@@ +97,3 @@
     Extends: ButtonBox,
 
+    _init: function(menuAlignment, textName, dontCreateMenu) {

you have textName here and nameText down below. (I like nameText better as a name)

@@ +119,3 @@
+            // purposes in the future.
+            this.label = new St.Label({ text: text });
+            this.actor.label_actor = this.label;

Couldn't you reuse the old this.label if it existed?
Comment 6 Alejandro Piñeiro Iglesias (IRC: infapi00) 2012-01-26 19:19:47 UTC
Created attachment 206209 [details] [review]
Setting a name/label_actor for several items on the panel

Updated patch. Using nameText always. Now the label is reused if existed. This should fix the first issue about creating label on every application focus change.
Comment 7 Alejandro Piñeiro Iglesias (IRC: infapi00) 2012-01-26 19:20:46 UTC
Created attachment 206210 [details] [review]
Notify accessible name change

While updating previous patch I realized that StLabelAccessible was not notifying a accessible-name change when the text of the label changed.
Comment 8 Owen Taylor 2012-01-26 19:59:00 UTC
Review of attachment 206209 [details] [review]:

Looks good
Comment 9 Owen Taylor 2012-01-26 20:08:23 UTC
Review of attachment 206210 [details] [review]:

One indentation problem, otherwise OK to commit

::: src/st/st-label.c
@@ +485,3 @@
+label_text_notify_cb (StLabel *label,
+                      GParamSpec *pspec,
+                      AtkObject *accessible)

parameter aligment