Re: New work on fonts at W3C

On Wed, Jun 24, 2009 at 12:33 AM, Levantovsky,
Vladimir<Vladimir.Levantovsky@monotypeimaging.com> wrote:
> 3) However, the use of renamed fonts will affect normal @font-face
> workflow. When you use a real font name, the UA would usually look if a
> font is available, and only if not found, it would download a resource
> specified by @font-face-src. Renaming fonts will force UA to always
> download a font, even if identical font is installed.

The CSS3 @font-face spec contains the following example:

@font-face {
  font-family: Gentium;
  src: local(Gentium), url(/fonts/Gentium.ttf);
}
http://dev.w3.org/csswg/css3-fonts/#src

The standard says that this would use the locally-installed font if
available, otherwise the font from the URL.  So the rule in our case
might look like:

@font-face {
  font-family: "High-Quality Font";
  src: local(High-Quality Font),
url(/fonts/High-Quality_Font_COPYRIGHTED_ONLY_LICENSED_FOR_FOO.COM)
format("opentype");
}

In fact, the font filename and the name embedded in the font file
aren't used at all in CSS, AFAICT.  The standard gives examples like
this as well:

@font-face {
  font-family: Japanese;
  src: local(HiraKakuPro-W3), local(Meiryo), local(IPAPGothic);
}

> Typically, web authors use more than one font family for their content
> (where each font family may include multiple font files representing
> different styles and weights) - authors would have to manually keep
> track of all the original font files and those that are renamed.

The mangled font name could contain the original font's name, so that
authors can keep easy track, in addition to the license warning (as I
illustrated above).  It will still be impossible for users to use the
font without realizing they're violating the license terms.  The only
disadvantage to authors that I can see is that the names would be long
and look ugly, but I think that's really a very minor detail.  You
could even have your program auto-generate the @font-face rules, if
the author gives the URL to the folder he's putting the font files in.

> In
> addition, I suspect an author's ability to use other CSS properties like
> font-style, font-weight, etc. may be affected by font renaming.

Why do you suspect that?  From reading the standard, it seems like
you'd specify different font styles and weights just as for any
@font-face.  @font-face completely ignores the filename and any
embedded naming metadata, AFAICT, so to the author the only difference
should be what URL they have to put in the src() rule: that's the only
place it makes a difference to @font-face.  I don't think this would
be a noticeable additional burden to web page authors, as compared to
EOT.

Received on Wednesday, 24 June 2009 13:35:59 UTC