q element produces incorrect quotation marks when language changes #22
Labels
doc:ca
doc:cyrl
Cyrillic
doc:de
doc:fr
doc:geor
doc:grek
doc:hu
doc:latn
Latin script
doc:nl
gap
i:quotations
Quotations & citations
l:az-cyrl
Azeri with Cyrillic script
l:bg
Bulgarian
l:ca
Catalan
l:de
German
l:el
Greek
l:fr
French
l:hu
Hungarian
l:ka
Georgian
l:nl
Dutch
l:no
Norwegian
l:ru
Russian
l:sr
Serbian
l:uk
Ukrainian
l:uz
Uzbek
p:advanced
s:cyrl
Cyrillic script
s:geor
Georgian (script)
s:grek
Greek (script)
s:latn
Latin (script)
x:alreq
x:blink
x:cans-iu-cr
x:cher
x:clreq
x:css
x:css-content
x:gecko
x:geor
x:grek
x:jpan
x:latn-ca
x:latn-de
x:latn-fr
x:latn-hu
x:latn-nl
x:osge-osa
x:webkit
This issue is common across all languages that use the
q
element.When an English page contains a quotation in another language, the quotation marks used around that quotation (and inside it for embedded quotes) should be the English ones – not those of the language of the quotation. The same applies for other languages.
The GAP
Currently, if the language of the quotation is declared on the
q
tag in HTML and that tag has alang
attribute, browsers instead set the quotation marks based on the language of the quote.Quotations work fine in a sentence that is all in the same language. For example, the markup for this Georgian text:
<span lang="ka">ერთი <q>ორი <q>სამი</q></q></span>
will result in:
ერთი „ორი «სამი»“
However, if the quote is in English and
lang="en"
is added to the firstq
tag, the result becomes:ერთი “two ‘three’”
whereas it should be:
ერთი „two «three»“
This is the case for Gecko, Blink, and WebKit.
Tests & results
Interactive test, When an embedded quote is in a different language, the quotation marks should be those of the main body, even if the language of the quote is declared using a lang attribute.
i18n test suite, Multilingual nesting.
Action taken
This incorrect behaviour was initially dictated by the HTML specification. issue 3636 was raised to change the spec. In the end the entire section was removed from the HTML spec, and HTML now relies on CSS for this behaviour.
css-content says that , however it is non-normative text.
Issue 5478 Open, requests that this be made normative, and has been agreed by the CSS WG.
Browser bug reports:
Gecko • Blink • Webkit
Outcomes
tbd
Priority
Marking this as advanced because it's possible, though not always as convenient, to use Unicode characters instead of the
q
element.The text was updated successfully, but these errors were encountered: