New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 636721 link

Starred by 2 users

Issue metadata

Status: Duplicate
Merged: issue 640763
Owner:
Last visit > 30 days ago
Closed: Jun 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Mac
Pri: 2
Type: Bug



Sign in to add a comment

Cannot set multiple regional sub-language variants before non-regional language

Reported by alvinhoc...@gmail.com, Aug 11 2016

Issue description

UserAgent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.103 Safari/537.36

Steps to reproduce the problem:
1. Add more than one regional language variants, e.g. "English (United States)" and "English (United Kingdom)", to the language list.
2. Arrange the order such that the non-regional language, e.g. "English", comes after all the regional ones.
3. Confirm the language settings, close the settings tab and re-open the language settings.

What is the expected behavior?
The ordering should be kept as-is.

What went wrong?
The ordering of the languages are automatically rearranged such that the non-regional language, e.g. "English", always comes immediately after the first regional variant, e.g. "English (xxx)", causing other regional variants to come after the non-regional one, and essentially becoming useless.

Did this work before? N/A 

Chrome version: 51.0.2704.103  Channel: stable
OS Version: 6.1 (Windows 7, Windows Server 2008 R2)
Flash Version: Shockwave Flash 22.0 r0

I've attached several images reflecting the problem. The first image is the user-intended setting, while the second imags is the result after confirming and then reloading the setting page.

The language settings affects the "Accept-Language" HTTP header sent by Chrome. For example, in the case of the second image, the header becomes `Accept-Language: zh-HK,zh;q=0.8,zh-TW;q=0.6,en-GB;q=0.4,en;q=0.2,en-US;q=0.2`.

If a user wants to prefer the Chinese (Hong Kong) variant but fall back to Chinese (Traditional) when not supported, i.e. having `zh-TW` to come before `zh` but after `zh-HK`, it is impossible to do so in Chrome.

Consider the following: Both of `zh-HK` and `zh-TW` use Traditional Chinese texts, but `zh-HK` is often ignored because localizing for only `zh-TW` is often enough for some sites. Other sites, however, may have content localized specifically for `zh-HK`. As a result, it makes perfect sense to place `zh-HK` before `zh-TW` to prefer HK-specific localization before generic/Taiwanese Traditional Chinese, and then put `zh` to fall back to Simplified Chinese if available.

However, given how Chrome puts `zh` after `zh-HK` and before `zh-TW`, it may cause sites not supporting `zh-HK` to fall back to using Simplified Chinese immediately without considering using Traditional Chinese for `zh-TW`, which isn't what the user originally intended.

(This situation is specific to Chinese. Ideally, `zh` should not imply Simplified Chinese, and `zh-HK` should automatically imply Traditional Chinese fallback. But a lot of stuff use Simplified Chinese for `zh`, and use Traditional Chinese only for `zh-TW`. Even Android didn't do this well in versions before Nougat.)

Related:  Issue 625543 ,  Issue 626153  and  Issue 192309 .
 
2016-08-11 15_41_34-Settings - Languages.png
23.7 KB View Download
2016-08-11 15_42_09-Settings - Languages.png
24.1 KB View Download

Comment 1 by js...@chromium.org, Aug 26 2016

Cc: js...@chromium.org
Components: -UI UI>Internationalization
Labels: OS-Linux OS-Mac
Hmm... something is not quite right. Thank you for reporting. 

Status: Untriaged (was: Unconfirmed)
It seems that it might have been *partially* fixed on or before 59.0.3071.82 beta? I seem to be able to set the language order as wanted now.

But nowhe Accept-Language header gives `en-HK,zh-HK;q=0.8,zh-TW;q=0.6,zh;q=0.4,en-GB;q=0.2,en-US;q=0.2,en;q=0.2`. There is an unintended "en-HK" prepended at the beginning for some reason.
Components: UI>Browser>Language
Owner: claudiomagni@chromium.org
Status: Assigned (was: Untriaged)
Claudio, let's make sure that the language expansion correction in 640763 is working as intended. Duping it into 640763.
Mergedinto: 640763
Status: Duplicate (was: Assigned)

Sign in to add a comment