w3c / wcag

Web Content Accessibility Guidelines
https://w3c.github.io/wcag/guidelines/22/
Other
1.11k stars 252 forks source link

3.1.2 Language of Parts clarification #4113

Open EmptyEnd6893 opened 4 days ago

EmptyEnd6893 commented 4 days ago

Discussed in https://github.com/w3c/wcag/discussions/4111

Originally posted by **EmptyEnd6893** October 17, 2024 I have been wondering about the second example for the [Language of Parts understanding page](https://www.w3.org/WAI/WCAG22/Understanding/language-of-parts.html). I have repeated it below for convenience. 'An HTML Web page includes links to versions of the page in other languages (e.g., Deutsch, Français, Nederlands, Catalan, etc.). The text of each link is the name of the language, in that language. The language of each link is indicated via a lang attribute.' Are the names of the languages not considered proper names in this case? If so, it seems that the criterion would not apply. I realise that language names are slightly unusual in that languages frequently have their own word for other languages, but wouldn't they still count as proper names? Any help would be appreciated.
EmptyEnd6893 commented 4 days ago

Hi. I am opening an issue based on the above Q&A as it could be an opportunity to make the understanding page for 3.1.2 a little clearer. Please see the discussion on the Q&A page for more context.

EmptyEnd6893 commented 1 day ago

The gist of it is that the understanding document does not appear to provide any guidance on how to handle proper names that are different in different languages, such as Deutsch changing to German. From what I have read, there does not appear to be a requirement to set a lang attribute (or use another technical method to set language) on proper names in a foreign language. This seems odd to me. Can anyone confirm whether this is the intended interpretation of the criterion?

patrickhlauke commented 1 day ago

Can anyone confirm whether this is the intended interpretation of the criterion?

Yes

EmptyEnd6893 commented 1 day ago

Does that mean that it is not required to set a lang attribute (or use another method) on the alternative language links shown in the second example on the understanding page? The language names would count as proper names correct?

patrickhlauke commented 1 day ago

To me, the names of languages aren't "proper names", so the example looks correct to me, but this is likely where linguists can debate things at length.

EmptyEnd6893 commented 1 day ago

In my view they seem to fit fairly neatly into the definition of a proper noun/name as they are the name of a specific language. Language names are always capitalised which appears to support this. In your view, would the second example still pass if the lang attributes were removed?

patrickhlauke commented 1 day ago

in german, practically every single word that's not an adjective or verb is capitalised. doesn't mean that it makes every one of those words "proper names".

EmptyEnd6893 commented 1 day ago

I don't know anything about German grammar (even though my mother is German) but take this sentence from the first example of the understanding page: 'Depending on the markup language, English may either be marked as the language for the entire document except where specified, or marked at the paragraph level. When a screen reader encounters the German phrase, it changes pronunciation rules from English to German to pronounce the word correctly.' Note how the names of languages are capitalised. I can't think of a reason why they shouldn't be considered proper names.

stevefaulkner commented 1 day ago

Perhaps listen to it with a screen reader and ask some users. Is it better that the language names written in the language they are identifying is announced with the language specific pronunciation or not?

ronsmantpg commented 1 day ago

For pronunciation by screen readers, capitalisation (and therefore consideration as a proper noun) is not relevant. And the name of the language is not announced when a word is marked up as being pronounced in another language - the word or phrase is simply pronounced in its language. The point is that a word in a language other than the default is not mispronounced. A phrase like "fin de siècle" should not be pronounced "finn duh seekle" because the default language is English. Whether the lang attribute has a capital letter doesn't influence that. IMO, the examples are fine.

EmptyEnd6893 commented 23 hours ago

I understand that setting the lang attribute appears to be best practice and I am definitely not disputing the validity of the example. However, I am still not entirely clear on the issue of whether lang attributes are required for 'foreignly spelled' language names. At this stage, it appears to me that language names are conforming (although probably not ideal) when the 'lang' attribute is not set.