W3C home > Mailing lists > Public > www-style@w3.org > August 2008

Re: [css3-gcpm] Spacing and alignment of leaders

From: Håkon Wium Lie <howcome@opera.com>
Date: Sat, 9 Aug 2008 22:19:13 +0200
Message-ID: <18589.64449.559023.148023@opera.com>
To: marbux <marbux@gmail.com>
Cc: www-style@w3c.org

Also sprach marbux:

 > Forgive me if I am missing something (just getting started with CSS
 > 3), but <http://www.w3.org/TR/2007/WD-css3-gcpm-20070504/#leaders>
 > does not seem to specify a method for horizontal spacing and alignment
 > of leaders. The section as now drafted seems to contemplate leaders
 > without horizontal spacing and alignment.

The draft contains this statement:

  UAs should attempt to align leader patterns on a page.

The editor's current version (which I hope to publish soon) has this

  User Agents should attempt to align corresponding glyphs from the
  leader pattern between consecutive lines.

I don't think we should *require* UAs to align leaders as this could
impact progressive rendering, but it should be encouraged. Indeed,
Prince -- which has the only implementation of leaders that I know of
-- aligns leaders.

 > In the hot type days, leader characters were normally separated using
 > em and/or en spaces, and aligned horizontally. Numerals correspond in
 > width to an en space, so if one has a variable page number length,
 > e.g., pages 101, 89, and 5, the leader ending can be uniform; e.g.,
 > assuming that variable justification is applied between Text and the
 > leaders, that dot leaders are separated by one em space, and that one
 > en space is desired between the last leader character and the longest
 > page number:
 > Text .[em].[em].[em][en]5
 > Text .[em].[em].[em]89
 > Text .[em].[em].[en]101
 > produces right-aligned page numbers, a uniform gutter between the page
 > numbers and the leaders, and horizontally aligned
 > leaders. See Space Characters in Unicode,
 > <http://www.cs.tut.fi/~jkorpela/chars/spaces.html>.

Right. These characters can be included in the leader stings. For example:

  leader('.\2002')  /* en */
  leader('.\2003')  /* em */

Start and endings cannot be controlled separately, but one can specify
additional strigs, e.g.:

 a { content: leader('.\2003') '\2002' target-counter(attr(href), page) }


              Håkon Wium Lie                          CTO °þe®ª
howcome@opera.com                  http://people.opera.com/howcome
Received on Saturday, 9 August 2008 20:20:03 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:39 UTC