Fix SVG systemLanguage conditional processing

The algorithm that performs the test between browser language preference
and the systemLanguage value has been modified
to implement a language-tag match based on the prefix,
making it consistent with BCP 47's basic filter operation and
as specified in the SVG 1.1 spec.

The previous behavior was:

- Tests whether the value of the attribute (e.g., "en-us") is a prefix
of the user preferred language (e.g., "en")
(which would evaluate to false)

The test was modified to compare in the opposite manner,
now user preferred language must be a prefix of the value.

- If the language tag length was not 2, the language tag
was not matched, (e.g. It did not match "en-us" to "en-us").
This check has been removed.

- The algorithm did not check for a trailing hyphen ("-").
We do not want langtag "it" matching langtag "ita",
but it is ok for "it" to match "it-it".
Now it does.

------------

The algorithm that performs the test between browser language preference
and the systemLanguage value has been modified
to implement a case insensitive language-tag match:

"en" matches "EN".

The previous behavior was case sensitive.

------------

Add Luca Di Domenico to AUTHORS

------------

Bug: 872378, 869440
Cq-Include-Trybots: luci.chromium.try:linux_layout_tests_slimming_paint_v2;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: Ibe767644b5a92e8d79ffe4b7777f5f51851b3883
Reviewed-on: https://chromium-review.googlesource.com/1188314
Commit-Queue: Fredrik Söderquist <fs@opera.com>
Reviewed-by: Fredrik Söderquist <fs@opera.com>
Cr-Commit-Position: refs/heads/master@{#587592}
10 files changed