New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Links containing only Unicode icon glyphs should fall back to the title attribute if it exists #2963
Comments
Comment 1 by jteh on 2013-02-04 12:46 |
Comment 2 by Q (in reply to comment 1) on 2013-02-04 18:02
Um, no there isn't. Do *you see any text inside those links? What is happening is the same as on my website, and the same as on a whole crapton of new websites, namely unicode font-based icons. It is completely invalid to call an icon glyph readable text. What is more useful here, being technically correct and reading garbage, or actually reading some text that could give a chance of correctly interacting with the link? I can understand if you had said, it would be heuristically difficult to detect what text to relate to the user in this situation, but to simply say it's impossible? Not to nitpick, but I am rather frustrated to be a monthly donator to the NVDA project and to be so cavalierly dismissed over an actual issue which is clear for anyone who is not intentionally blinding themselves to it. |
Comment 3 by ondrosik on 2013-02-04 18:19 |
Comment 4 by Q (in reply to comment 3) on 2013-02-04 18:21
You don't notice the icons on my site because I add text to the actual links and not to the title attribute. You might be able to hear the synthesizer pause slightly before it announces some links when it reads the unicode character though, the sort of questionmark pause before some links. |
Comment 5 by jteh on 2013-02-04 18:38 As for your inference that I'm intentionally blinding myself to a clear issue, your definition of text is pretty narrow if this issue is so amazingly clear. If you'd rather insult me than provide constructive arguments, I'll be quite happy to spend my time on something more deserving. |
Comment 6 by Q (in reply to comment 5) on 2013-02-04 18:59
Yes. Precisely this. This is the heuristic which I opened this ticket to discuss. This is the point where we talk about alternatives like, "longest wins", or, those characters don't exist in this locale's default encoding but those in the title attribute do or maybe we need a keystroke to read a link's title, if it has one or any of a hundred other things that aren't, simply, we're already doing the right thing, accept it and shut up.
Except, now, I am pointing out to you that it is an unreasonable assumption, and showing you a test case on an extremely popular website to prove it. What does whether or not another screen reader handles it correctly have to do with if NVDA should?
Of course they could. It would be silly to ignore Chinese symbols if, for instance, the user's language were set to Chinese. It may not even be possible to tell if a given symbol maps to a given language's character set, in which case we have to fall back to guessing. See my discussion of the heuristic to use above.
No. By my logic we should actually think about how we present things to the user. Not simply assume we have the ultimate way already figured out.
No. It isn't. My definition of useable text is narrow and constrained by the usefulness of the text. I am extremely aware of all the potential technical issues here. That said, in the state that you've left this, very important functionality on GitHub doesn't work. I was originally going to report this issue to GitHub, before examining their markup and noticing the very obvious title attributes of their links. They are giving us this information. Why are we ignoring it?
This sentence is extremely frustrating. I'm not sure what you consider insulting behavior, but I would class your rather rude dismissal of my cogent points as such. I, too, can take my toys and go home. I opened this ticket to improve NVDA's handling of web content for all of us, not to get into a philosophical discussion. That said, if you look back over the thread, I have been presenting constructive suggestions, you have been shooting them down. |
Comment 7 by Q on 2013-02-04 18:59 |
Comment 8 by Q on 2013-02-04 20:30
Note that the only thing visible to NVDA in Browse mode is the phrase "This is some text" |
Comment 9 by jteh (in reply to comment 6) on 2013-02-05 01:59
Nowhere in your ticket description did you mention alternatives or what you define as "text". That only came after I closed the ticket.
NVDA can't currently make assumptions about the locale because it's quite possible that a user might be reading multilingual text; i.e. the user's ocnfigured NVDA interface language may not match the text they're reading. Also, the code that renders virtual buffers is in-process and doesn't have access to any of this information. Of course, we could change this somehow, but that would be a huge architectural change.
If you press NVDA+tab, NVDA will report the focused object, which includes its description (which in this case is the title).
Just because it's popular doesn't make it right. While I want the best usability just as much as anyone else, I'm not willing to invest a huge amount of effort in hacks which compensate for authoring error and may actually introduce unwanted side effects. This is a very slippery slope. Accuracy has to be the primary objective.
We do think about how we present things to the user. We also try to interfere and "guess" as little as possible so as to avoid potential inaccuracy and bloat.
See above regarding the way to report the title. The title essentially becomes secondary information (the description) if the link contains content. (Btw, the browser does this, not us.) Note that if aria-label were used, it should override the content, which is what you want. NVDA probably doesn't support this in this case, which is a separate issue that needs to be fixed and is on my to-do list. Next step: please report whether NVDA+tab reports the required information. |
Comment 10 by jteh (in reply to comment 8) on 2013-02-05 02:02
Assuming trac didn't munge something you typed, this is a different issue. Your link has no content at all, so it's actually invisible even to sighted users, which is why NVDA doesn't render it. |
Comment 11 by ppatel on 2013-02-05 02:17 |
Comment 12 by ppatel on 2013-02-05 02:53 In IE9, all of these links are recognized as such when using the arrow keys to brows through the file. NVDA+tab also provides descriptions.
|
Comment 13 by jteh on 2013-02-05 23:53 |
Comment 14 by Q (in reply to comment 13) on 2013-02-06 06:53
I haven't been able to find a standard. Here's one person stating that there are some standard unicode points with meaning, and any others used in an icon font should go in a private range: |
Comment 15 by jteh (in reply to comment 14) on 2013-02-06 07:25
That isn't the entire solution. For IA2 browsers, we rely on the browser to make decisions about the name of the object; we don't have direct access to the DOM. If we ignore characters in content, NVDA will fall back to the name, but in this case, the name will just be the content (as decided by the browser), so this solves nothing. If it seems appropriate that private use Unicode characters shouldn't be used, we'd ideally try to get consensus on that from Mozilla so they can do the same. There are possibly other solutions, but that'd be my first approach. Did you confirm whether NVDA+tab reports the required information? |
Comment 16 by Q (in reply to comment 15) on 2013-02-06 08:00
I made a small test page where it seems to work. It does not work on GitHub (even though they have title in their markup.) Further analysis showed me that they were using something which renames title to original-title in the DOM. I wrote to them and asked that they use aria-label. The Javascript library that they're using which renames title to original-title is Tipsy, a tooltip library. Would it make sense for me to open a ticket against tipsy asking them to add an aria-label attribute if they rename title as well as simply contacting GitHub about their unlabeled links? Are title and aria-label semantically equivalent? |
Comment 17 by jteh (in reply to comment 16) on 2013-11-27 06:26
I think so, yes. Based on current browser behaviour, I guess they should use aria-label even if they don't rename title, as browsers will probably use the content as the label if the content isn't whitespace.
Not quite. Title will only be used as the label as a last resort. Otherwise, it becomes the description.
It's in NVDA's vbuf backends. We're going to investigate special handling for private use Unicode characters. |
Comment 18 by Michael Curran <mick@... on 2013-11-28 02:17
|
Comment 19 by Michael Curran <mick@... on 2013-11-28 02:17
Changes:
|
Comment 20 by Michael Curran <mick@... on 2013-12-12 04:19
Changes:
|
Comment 21 by mdcurran on 2013-12-12 04:20 |
Fixes #6460 1. Added two attributes to virtual buffer text nodes. - ia2TextOffset: holds the start offset for a TextFieldNode within the IAccessibleText of its associated object. This attribute is only added to text field nodes that originate from IAccessibleText. - strippedCharsFromStart: When characters are stripped from the start of a text node (#2963) this attribute holds the amount of stripped chars from the start, in order for us to correct the ia2TextOffset. 2. the Gecko virtual buffer text info now has its own _getPointFromOffset implementation that uses the new virtual buffer attributes. 3. VirtualBufferTextInfo.getTextWithFields is now split up into a helper function _getFieldsInRange, similar to DisplayModelTextInfo. This allows for easy retrieval of control/format fields in a particular range, regardless where the text info is positioned. 4. pointFromOffset in the adobe acrobat virtual buffer now uses the _indexINParent attribute. It seems Adobe Acrobat has separate dom nodes for every word, so pointFromOffset now gets the center point of the word, which is far better than it was before.
Reported by Q on 2013-02-04 11:22
On GitHub, for instance, NVDA reads the following (for a critical part of the site for a logged in user)
The markup reads:
The text was updated successfully, but these errors were encountered: