[Bug 16185] Serialization of <family-name> don't match browsers


Simon Pieters <simonp@opera.com> changed:

           What    |Removed                     |Added
             Status|NEW                         |RESOLVED
         Resolution|---                         |WONTFIX

--- Comment #5 from Simon Pieters <simonp@opera.com> ---
(In reply to comment #0)
> Spec seems to say like Opera, except it says to string-escape the unquoted
> "serif" too (which is definitely not right).

No, that's not a <font-family>, that's a <generic-family> which is a keyword
and gets serialized as "The keyword converted to ASCII lowercase." per spec.

> I suggest instead that the
> family name be string-escaped if it has to be, i.e., if it contains special
> characters or matches one of the built-in keywords like serif.  Multiword
> font names that contain no special characters should not be quoted, see
> <https://bugs.webkit.org/show_bug.cgi?id=79448>.  Double quotes should be
> used for consistency.

Since this bug is really about <font face>, I don't see much point in changing
CSSOM serialization. You need to convert the value before sticking it in <font
face> anyway in case it does have quotes. Maybe you argue that you would just
HTML-escape the quotes and let it break in Outlook 2007 in such cases, but
really, changing the serialization from quotes to unquoted seems like a trivial
problem in the editing space. In the case of contenteditable/designMode, you
don't even have to use CSSOM's serialization rules, you can define your own.

(In reply to comment #1)
> We (Gecko) really need to rewrite our font-family data storage, at which
> point we'd probably end up with a serialization more like Opera's.  I prefer
> specifying Opera's behavior here.


(In reply to comment #2)
> Why should every family name be quoted?  Just for simplicity?

Yes. Simpler also means less likely to have bugs.

> I don't have
> any big objection, but it's somewhat less readable IMO, and not how authors
> usually input the family names.  In the common case, nothing would be
> quoted, which looks cleaner.

I think looking cleaner isn't very compelling.

I've not changed the spec.

You are receiving this mail because:
You are the QA Contact for the bug.

Received on Monday, 26 August 2013 14:52:37 UTC