<q> in IE8 (Was: Re: <q>)

Chris Wilson wrote:
> Ben Millard [mailto:cerbera@projectcerbera.com] wrote:
>> C. Generated quotes can be altered from CSS by at least Firefox and Opera (I
>> tested Firefox 2.0.0.17 and Opera 9.60) but the default characters they
>> generate are different:
>>    <http://meyerweb.com/eric/css/tests/css2/sec12-04-01.htm>
>>    <http://lists.w3.org/Archives/Public/public-html/2008Oct/0103.html>
> 
> Yes.  Generated quotes can be altered from CSS in IE8 as well.  We appear to match Firefox 3 behavior on Eric's tests, to be specific - that is, we use non-ASCII quotes by default.
> 
>> D. Firefox makes a token effort to support one non-Enlish language in one
>> localisation:
>>    <http://lists.w3.org/Archives/Public/public-html/2008Oct/0102.html>
> 
> We do better than that.  I'd have to look up precisely how broad it is, but we recognize a set of lang values.

(I can see 21 different language-dependent quote styles in IE8b2, which 
does seem much better than a token effort.)

What is IE meant to do by default when no language is specified?

If I write <!DOCTYPE html><q>Test</q> in IE8b2, then it outputs 
single-quotes. <q lang=en-gb> is the same. lang=en and en-us output 
double-quotes instead.

I'm running on an en-GB system, so I guess IE must be picking up the 
system language and using that as the default. (I could be wrong (in 
which case this whole post is irrelevant) since I can't find an easy way 
to test this, but I don't see any other reason it would default to 
something equivalent to en-GB.)

That seems bad because it will be unexpected and surprising to authors. 
A likely situation is:

An en-US speaking author writes a perfectly valid page in English, with 
a doctype that triggers IE8-compatibility mode in IE8, without setting 
lang. They read somewhere that <q> puts quotation marks around 
quotations by default, so they use it for their page's quotations (or 
for citations or for emphasis or whatever). They test it in every 
browser they have access to, and it creates double-quotes in all of 
them, so they're happy and they don't need to fiddle with CSS and they 
publish the page. Then a foreign (French, Japanese, etc) user (who can 
read English perfectly well) visits the page, and their browser defaults 
to their system language and draws funny quotes in the middle of the 
English page, which makes the page look strange and broken, and everyone 
is unhappy.

To avoid that problem, the quote style should be purely a function of 
the page, not of the user. When no lang is specified in the page (or in 
HTTP headers), the quotes should default to something consistent 
(probably en-US because that's what all other browsers do). Then authors 
will test their page, and non-en-US authors will see that it's not quite 
what they want and will fix it by specifying lang="..." or "q { quotes: 
... }" or by using inline punctuation instead of <q>, and then it will 
work exactly the same for all users.

This increases the chance that the default will not match what the 
author wants, so they will have to expend some minor effort to fix it; 
but it avoids the much larger pain of them thinking their page looks how 
they want it to, when actually many users will see something quite 
different.

Does something like this seem reasonable?

-- 
Philip Taylor
pjt47@cam.ac.uk

Received on Friday, 31 October 2008 17:09:28 UTC