Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > <q> and language-specific quotation marks

Reply
Thread Tools

<q> and language-specific quotation marks

 
 
Tristan Miller
Guest
Posts: n/a
 
      10-11-2003
Greetings.

Do any popular browsers correctly support <q>, at least for Western
languages? I've noticed that Mozilla uses the standard English
double-quote character, ", regardless of the lang attribute of the HTML
document. Will any browsers render German-style quotes or French-style
guillemots for lang="de" and lang="fr", respectively?

Regards,
Tristan

--
_
_V.-o Tristan Miller [en,(fr,de,ia)] >< Space is limited
/ |`-' -=-=-=-=-=-=-=-=-=-=-=-=-=-=-= <> In a haiku, so it's hard
(7_\\ http://www.nothingisreal.com/ >< To finish what you
 
Reply With Quote
 
 
 
 
kayodeok
Guest
Posts: n/a
 
      10-11-2003
Tristan Miller <(E-Mail Removed)> wrote in
news:(E-Mail Removed):

> Greetings.
>
> Do any popular browsers correctly support <q>, at least for
> Western languages? I've noticed that Mozilla uses the standard
> English double-quote character, ", regardless of the lang
> attribute of the HTML document. Will any browsers render
> German-style quotes or French-style guillemots for lang="de" and
> lang="fr", respectively?


IE doesn't support <q>

Getting quote marks around <q> tags in IE
http://groups.google.com/groups?thre...6.ph.gla.ac.uk

--
Kayode Okeyode
http://www.kayodeok.co.uk/weblog/
 
Reply With Quote
 
 
 
 
Darth Ferret
Guest
Posts: n/a
 
      10-11-2003
H.F. ?

"Tristan Miller" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Greetings.
>
> Do any popular browsers correctly support <q>, at least for Western
> languages? I've noticed that Mozilla uses the standard English
> double-quote character, ", regardless of the lang attribute of the HTML
> document. Will any browsers render German-style quotes or French-style
> guillemots for lang="de" and lang="fr", respectively?
>
> Regards,
> Tristan
>
> --
> _
> _V.-o Tristan Miller [en,(fr,de,ia)] >< Space is limited
> / |`-' -=-=-=-=-=-=-=-=-=-=-=-=-=-=-= <> In a haiku, so it's hard
> (7_\\ http://www.nothingisreal.com/ >< To finish what you
>



 
Reply With Quote
 
Brian
Guest
Posts: n/a
 
      10-11-2003
Tristan Miller wrote:
>
> Do any popular browsers correctly support <q>, at least for Western
> languages? I've noticed that Mozilla uses the standard English
> double-quote character, ", regardless of the lang attribute of the HTML
> document. Will any browsers render German-style quotes or French-style
> guillemots for lang="de" and lang="fr", respectively?


Mozilla displays French language quote delimiters with the following
in css:

[lang="fr"] {
quotes: ' ' ' '
}

German could be handled in a similar fashion.

[lang="de"] {
quotes: '' '"'
}

I don't know German nearly well enough to write in it, so I've never
actually used the second example.

--
Brian
follow the directions in my address to email me

 
Reply With Quote
 
Jukka K. Korpela
Guest
Posts: n/a
 
      10-11-2003
Tristan Miller <(E-Mail Removed)> wrote:

> Do any popular browsers correctly support <q>


No.

> I've noticed that Mozilla uses the standard English
> double-quote character, ", regardless of the lang attribute of the
> HTML document.


If you mean what you wrote, the Ascii quotation mark, then it's
definitely not _standard_ for English, or any language (except computer
"languages"). It's just the worldwide common surrogate.

> Will any browsers render German-style quotes or
> French-style guillemots for lang="de" and lang="fr", respectively?


Only if you write them as actual characters (and then the lang
attribute is immaterial in this issue). Why wouldn't you do that? We
can use language-specific punctuation characters for other things (such
as inverted question mark at the start of a question in languages that
require it), and seldom do we see requests to dispense with that by
using markup (like <question>) instead. What's so special about
quotations, then?

Beware that attempts to make browsers implement <q> by using CSS are
generally not successful and that _correct_ use of quotation marks is
trickier than people think.

Anyway, <q> was good idea as described (as an example) in the SGML
standard, but HTML did not adopt the idea early enough (and well
enough), and now it's too late. Just forget <q>.

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html

 
Reply With Quote
 
Micah Cowan
Guest
Posts: n/a
 
      10-12-2003
Tristan Miller <(E-Mail Removed)> writes:

> Greetings.
>
> Do any popular browsers correctly support <q>, at least for Western
> languages? I've noticed that Mozilla uses the standard English
> double-quote character, ", regardless of the lang attribute of the HTML
> document. Will any browsers render German-style quotes or French-style
> guillemots for lang="de" and lang="fr", respectively?


AIUI, a browser is not required to make allowances for the
declared language; if you want these changes, you are supposed to
use CSS to specify them (shameless snippet from CSS2 spec

Q:lang(en) { quotes: '"' '"' "'" "'" }
Q:lang(no) { quotes: "" "" "<" ">" }

....however, to my knowledge, neither Mozilla nor MSIE support
this. Mozilla uses " " ' ' regardless of what you specify using
CSS; and MSIE (last I checked) doesn't support the <q> element
properly at all. I think Opera might, but since that's not very
mainstream, it probably won't help you much.

-Micah
 
Reply With Quote
 
Jukka K. Korpela
Guest
Posts: n/a
 
      10-12-2003
Micah Cowan <(E-Mail Removed)> wrote:

> AIUI, a browser is not required to make allowances for the
> declared language;


The HTML specification says: "User agents should render quotation marks
in a language-sensitive manner (see the lang attribute)." In that
sense, it's not a requirement for conformance to recommendation, just a
recommendation in the recommendation. On the other hand, it is a
bit unrealistic to say that user agents should behave that way, since
it is rather hard to support all the thousands of languages, even in a
detail like this, since official information on punctuation rules is
not easy to find.

> if you want these changes, you are supposed to
> use CSS to specify them


No, you're not. The HTML specification says that browsers should do
such things automatically. And in practical terms, <q> markup is
useless.

> (shameless snippet from CSS2 spec
>
> Q:lang(en) { quotes: '"' '"' "'" "'" }
> Q:lang(no) { quotes: "" "" "<" ">" }


How typical. Both rules are completely wrong, by the rules of those
languages. Correct English orthography uses none of the characters
listed, and Norwegian surely does not use less than sign and greater
than sign as inner quotes.

To repeat myself: Forget <q>. Use plain Ascii quotation marks, unless
you _know_ the correct use of punctuation characters in the language of
the context where the quotation appears and you can be reasonably sure
that browsers support those characters well enough. And when estimating
whether you _know_ such issues, it is useful to remember that the
authors of the CSS specification didn't have a clue.

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html

 
Reply With Quote
 
Micah Cowan
Guest
Posts: n/a
 
      10-12-2003
"Jukka K. Korpela" <(E-Mail Removed)> writes:

> Micah Cowan <(E-Mail Removed)> wrote:
>
> > AIUI, a browser is not required to make allowances for the
> > declared language;

>
> The HTML specification says: "User agents should render quotation marks
> in a language-sensitive manner (see the lang attribute)." In that
> sense, it's not a requirement for conformance to recommendation, just a
> recommendation in the recommendation. On the other hand, it is a
> bit unrealistic to say that user agents should behave that way, since
> it is rather hard to support all the thousands of languages, even in a
> detail like this, since official information on punctuation rules is
> not easy to find.
>
> > if you want these changes, you are supposed to
> > use CSS to specify them

>
> No, you're not. The HTML specification says that browsers should do
> such things automatically.


SHOULD and MUST are very different--formally. You *are* supposed
to use CSS if you want to force a conforming user-agent to Do The
Right Thing(TM). However, since there don't seem to be any
conforming user-agents... <grin>.

> And in practical terms, <q> markup is useless.


Yeah, which sucks.

> > (shameless snippet from CSS2 spec
> >
> > Q:lang(en) { quotes: '"' '"' "'" "'" }
> > Q:lang(no) { quotes: "" "" "<" ">" }

>
> How typical. Both rules are completely wrong, by the rules of those
> languages. Correct English orthography uses none of the characters
> listed, and Norwegian surely does not use less than sign and greater
> than sign as inner quotes.


Agreed about (en); although even if it had been correct, I didn't
post using an encoding that would have allowed more appropriate
ones.

As to (no); you're right, that's stupid. That's how they were in
the CSS2 standard, though (should've been &#x2039; and &#x203a; I
believe)

> To repeat myself: Forget <q>.


But only until the stupid mainstream browsers (IOW, MSIE) get it
right. However, someone pointed out elsethread that apparently newer
versions Mozilla *can* get it right. Yay!

> Use plain Ascii quotation marks


Why? Every browser I've seen supports &ldquo;, &rdquo;,
etc. Currently, the articles I've written in DocBook which use
DocBook's <quote> element are translated using these (and the
single-quote equivalents).

>, unless
> you _know_ the correct use of punctuation characters in the language of
> the context where the quotation appears and you can be reasonably sure
> that browsers support those characters well enough.


But when you *don't* know this, are you sure that the Ascii
quotation marks are appropriate?

-Micah

 
Reply With Quote
 
Tina Holmboe
Guest
Posts: n/a
 
      10-12-2003
"Jukka K. Korpela" <(E-Mail Removed)> exclaimed in <Xns94126199E8EE3jkorpelacstutfi@193.229.0.31>:

> such things automatically. And in practical terms, <q> markup is
> useless.


So. In practical terms, marking up an inline quotation as an inline
quotation is useless.

This is good to know.

--
- Tina Holmboe Greytower Technologies
http://www.velocityreviews.com/forums/(E-Mail Removed) http://www.greytower.net/
[+46] 0708 557 905
 
Reply With Quote
 
Jukka K. Korpela
Guest
Posts: n/a
 
      10-12-2003
Micah Cowan <(E-Mail Removed)> wrote:

> SHOULD and MUST are very different--formally.


Theoretically HTML 4 specifications use RFC language here, but in
practice their wording is not that formal. Anyway, by the RFC language,
the statement that browsers SHOULD "render quotation marks in a
language-sensitive manner" means that "there may exist valid reasons in
particular circumstances to ignore [that statement] particular item,
but the full implications must be understood and carefully weighed
before choosing a different course". So if an implementator has
understood the full implications etc. and decided not to make a user
agent behave that way, what makes us think that an author knows better?

> You *are* supposed
> to use CSS if you want to force a conforming user-agent to Do The
> Right Thing(TM).


No, of course not. First, HTML specifications do not postulate any use
of CSS. They are meant to be used without a style sheet, with CSS style
sheets, or with other style sheet. Second, author style sheets (by
design and by implementation) certainly cannot force anything. Third, a
duplicate implementation of quotation mark rendering would be a shot in
the dark. A browser programmer can be in a position to _know_ that e.g.
curly quotes are not available in a rendering situation and use Ascii
quotation marks instead, and if an author style sheet tries to force
curly quotes, it could end up with having no quotes rendered.

> Agreed about (en); although even if it had been correct, I didn't
> post using an encoding that would have allowed more appropriate
> ones.


Surely you could write a style sheet in Ascii only and yet use any
Unicode character in generated content.

> As to (no); you're right, that's stupid. That's how they were in
> the CSS2 standard, though (should've been &#x2039; and &#x203a; I
> believe)


No, notations like &#x2039; have no meaning in CSS.

>> To repeat myself: Forget <q>.

>
> But only until the stupid mainstream browsers (IOW, MSIE) get it
> right.


They'll never get it right. It'll take several years before the next
version of MSIE exists and has over 50 % share of MSIE installations.
And that's virtual eternity. Especially since by that time <q> will
have been officially deprecated or obsolete for years.

>> Use plain Ascii quotation marks

>
> Why? Every browser I've seen supports &ldquo;, &rdquo;,
> etc.


Then you haven't seen enough. Ascii quotation marks are _safe_, as I
wrote. If you consider using real quotation marks, then you should at
least refrain from using those quasi-mnemonic entity references and use
character references instead.

>>, unless
>> you _know_ the correct use of punctuation characters in the
>> language of the context where the quotation appears and you can be
>> reasonably sure that browsers support those characters well
>> enough.

>
> But when you *don't* know this, are you sure that the Ascii
> quotation marks are appropriate?


Ascii quotation marks are still the safest way. It's true that these
days, the number of browsers that fail to render the character
references for curly quotes properly is rather small - but yet not
zero, and users are accustomed to seeing Ascii quotation marks, so this
is not a big issue. I'm personally moving towards using "smart"
quotation marks on new pages, especially since it's awkward to change
such things later - I cannot just do a simple editing operation to
change Ascii quotation marks to any smart characters, since Ascii
quotation marks are used for HTML markup (attribute value delimiters).

Besides, there are other problems with correct quotation marks, even
the guillemets. The guillemets are technically rather safe, being
ISO 8859-1 characters, but the clueless line breaking rules in browsers
cause quite some trouble (see
http://www.cs.tut.fi/~jkorpela/html/nobr.html ).

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Searching for a Firefox extension involving quotation marks Teh Suck Firefox 0 01-17-2006 09:00 AM
Quotation marks when mixing jsp and html forms deepstar@gmail.com Java 0 11-15-2005 06:26 PM
Using quotation marks Radith Java 1 01-07-2005 12:59 AM
String and quotation marks M. Clift Python 2 10-22-2004 09:01 PM
Question about concatenating quotation marks Peng Yu C Programming 3 10-02-2004 08:08 PM



Advertisments