Skip to content
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

HTML-AAM: UIA mapping for @lang #19

Closed
jasonkiss opened this issue Oct 12, 2016 · 3 comments
Closed

HTML-AAM: UIA mapping for @lang #19

jasonkiss opened this issue Oct 12, 2016 · 3 comments
Assignees
Labels

Comments

@jasonkiss
Copy link
Contributor

From @cyns on January 12, 2016 23:36

open question.
There is a culture text attribute in UIA, but TTS engines aren't using it. They're using heuristics instead to determine language. Not convinced that mapping this is valuable. Would like input...

https://msdn.microsoft.com/en-us/library/windows/desktop/ee872119(v=vs.85).aspx

Copied from original issue: w3c/aria#191

@jasonkiss
Copy link
Contributor Author

Assuming an author specifies lang for the page or a passage, and that there's a mapping from the value of lang to a Microsoft Locale ID, wouldn't mapping it via UIA_CultureAttributeId at least make it easier for TTS engines or other AT to consume, as opposed to relying on heuristics? Does mapping it like that have a cost?

I guess the same question goes for mapping dir via UIA_TextFlowDirectionsAttributeId?

@boggydigital, any perspective?

@boggydigital
Copy link
Contributor

Few things changed since asking the question - at the very least Narrator is considering supporting mixed-language texts and I'm sure other ATs would be interested as well to support full Microsoft Office document fidelity. For the Edge web platform this would be exposed in two ways (identical values, only difference is how you get them):

Both values are LCIDs (https://msdn.microsoft.com/en-us/library/cc233965.aspx).

While mapping those value we've realized one complication - HTML attributes are not inherited and to implement this in a way that makes sense we walk the tree to find the nearest ancestor with lang attribute. I don't think we've tried Firefox, but in Chrome on Windows at least I believe Blink maps lang attribute to (non-standard) CSS -webkit-locale property and gets cascade for free. We didn't check but I won't be surprised if Blink actually maps -webkit-locale and not lang itself.

As for UIA_TextFlowDirectionsAttributeId as a mapping for dir attribute - that does make sense, no objection.

Jason, let me know if I should capture both attributes in the mapping specification for UIA - I'm happy to.

@jasonkiss
Copy link
Contributor Author

Thanks @boggydigital. I've updated those mappings in the above commit. Closing, but if the language needs tweaking, we can do that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants