W3C home > Mailing lists > Public > www-svg@w3.org > May 2012

Re: should we remove the kerning property in favour of font-kerning?

From: Rik Cabanier <cabanier@gmail.com>
Date: Thu, 31 May 2012 14:26:54 +0200
Message-ID: <CAGN7qDCtbhFOO55nn1vVmj0zGwcQCGSJN8O52SOnQs-JG0YgHQ@mail.gmail.com>
To: David Dailey <ddailey@zoominternet.net>
Cc: Erik Dahlstrom <ed@opera.com>, Cameron McCormack <cam@mcc.id.au>, John Daggett <jdaggett@mozilla.com>, Dirk Schulze <dschulze@adobe.com>, Nikolas Zimmermann <zimmermann@kde.org>, SVG public list <www-svg@w3.org>
I think the proposal is to have kerning always on by default. Deprecating
the keyword just means that you can't turn it off any more.

It's correct that solely relying on CSS to do text rendering will remove
the ability to do fixed layout. That's way we should add new functionality
to allow this at the same time.
Current SVG text tries to do both automatic layout and fixed layout which
does not work very well.
Automatic layout should go the CSS route. It is a very hard problem and
requires a lot of work so it doesn't make sense to have a separate spec.
For fixed layout I believe we should look how this is currently done for
PDF and try to mimic what's there. This new feature should allow exact
glyph selection and character positioning.


On Thu, May 31, 2012 at 1:52 PM, David Dailey <ddailey@zoominternet.net>wrote:

> In addition to the cases that Cameron found on the web, we also have
> various instructional materials that were written relying on the spec
> including books and other materials such as
> http://www.w3.org/Graphics/SVG/IG/resources/svgprimer.html#text . Future
> authors will be using kerning since that is what the spec said and hence
> what the instructional materials say.
> Losing the ability to do character by character kerning, which apparently
> is included in the proposal to deprecate would represent a step backward
> for authors abilities to mimic effects used in advertising and logos and,
> accordingly, for accessibility, by forcing authors to use bitmaps instead
> of fonts to convey stylistic effects such as in
> http://cs.sru.edu/~ddailey/svg/GeometricAccessibility.html -- the world
> is replete with such examples, I believe. Allowing CSS to dictate the terms
> for SVG graphics harms accessibility, art and sensibility.
> Regards
> David
> -----Original Message-----
> From: Erik Dahlstrom [mailto:ed@opera.com]
> Sent: Thursday, May 31, 2012 4:21 AM
> To: Cameron McCormack; John Daggett
> Cc: Dirk Schulze; Nikolas Zimmermann; SVG public list
> Subject: Re: should we remove the kerning property in favour of
> font-kerning?
> On Thu, 31 May 2012 08:34:11 +0200, John Daggett <jdaggett@mozilla.com>
> wrote:
> > Cameron McCormack wrote:
> >
> >> > Not sure what you're kvetching about here.  The CSS 'font-kerning'
> >> > property enables or disables metrics-based kerning based on kerning
> >> > data in the font.  It does not take a length value.  So the two
> >> > properties are not equivalent.
> >> >
> >> > The SVG 'kerning' feature seems designed to allow
> >> > character-by-character tweaking.  One sets the 'letter-spacing' for
> >> > an entire text span and tweaks individual pairs of letters by
> >> > wrapping a span around each pair of characters and applying the
> >> > appropriate
> >> relative
> >> > adjustment via 'kerning'.  My guess is that this was designed to
> >> > allow PDF-like layout where an app spits out a set of characters
> >> > with positions.
> >> >
> >> > The CSS property is only designed to enable/disable font-based
> >> > kerning.  It's not designed to support character-by-character
> >> > tweaking nor do I think it should.
> >>
> >> Do you think it is reasonable to use "letter-spacing: 3px; font-kerning:
> >> none" in place of "kerning: 3px" for SVG content?  If we are in the
> >> situation where we could drop "kerning" in favour of authors using a
> >> combination of font-kerning and letter-spacing, should we do that?
> >> Or is letter-spacing something different enough from kerning
> >> adjustment that it should be kept separate?
> > Right, most of the time that's all that would be needed. The only
> > thing you wouldn't be able to do without the 'kerning' property around
> > is to be able to use the combined effect of letter-spacing + kerning
> > with a fixed length. So the question is whether there's content that
> > relies on that use case.
> >
> > The SVG kerning property is just an odd thing to me.  Kerning
> > adjustments are typically made to pairs of letters (e.g. Ta, To, AV,
> > etc.) and that's what font kerning data has, adjustments based on
> > glyph combinations.  Generic span-wide adjustments to spacing are
> > never called "kerning".
> >
> > I would suggest dropping the 'kerning' property.
> >
> > John Daggett
> Dropping 'kerning' is fine with me.
> --
> Erik Dahlstrom, Core Technology Developer, Opera Software Co-Chair, W3C
> SVG Working Group Personal blog: http://my.opera.com/macdev_ed
Received on Thursday, 31 May 2012 12:27:29 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:54:35 UTC