W3C home > Mailing lists > Public > www-style@w3.org > October 2011

Re: List cases for a cap height unit

From: Alan Stearns <stearns@adobe.com>
Date: Wed, 26 Oct 2011 09:49:17 -0700
To: "Tab Atkins Jr." <jackalmage@gmail.com>, www-style list <www-style@w3.org>
Message-ID: <CACD881D.889F%stearns@adobe.com>
On 10/26/11 9:37 AM, "Tab Atkins Jr." <jackalmage@gmail.com> wrote:

> Related tracker issue: http://www.w3.org/Style/CSS/Tracker/products/8
> David Baron suggested adding a "cap height" unit in
> <http://lists.w3.org/Archives/Public/www-style/2008Nov/0552.html>,
> which represents the height of a capital letter.  This is analogous to
> the "ex" unit, which is generally the height of a lowercase letter.
> 
> Some use-cases:
> 
> 1. Providing images for mathematical symbols that are not yet in
> Unicode, that should be the size of the text it's embedded into.
> 
> 2. Providing smiley images that should be the size of the text they're
> embedded into.
> 
> 3. Providing a sparkline (miniature, info-rich graph meant to be
> interleaved with text) that's baseline aligned and as tall as possible
> without disrupting the height of the line.
> 
> 
> Some objections noted on the recent telcon were that this may be
> somewhat less useful for non-Latin (or related) scripts.
> 
> For Japanese and other sinographic scripts, the 'em' unit already
> plays a similar role - the height of text is typically sized according
> to the em box in such scripts.
> 
> Elika said that it would play nicely with Arabic, better than the 'ex'
> unit, since Arabic has a useful notion of "capital letter height" that
> serves the same role as it does in Latin scripts.
> 
> Questions were brought up over Indic scripts and Thai.  Nobody on the
> call was certain whether these scripts had a useful notion of "capital
> letter height", and if they did, if this was useful when combined with
> vertical-align in the same way that it is for Latin scripts.
> 
> ~TJ

Even in Roman text, cap height is not any of these things:

  size of the text
  as tall as possible
  height of the text
  height of the line

So more precisely the use cases are:

1. Providing images for mathematical symbols that are not yet in
Unicode, that should be sized relative to the cap height of the text it's
embedded into.

2. Providing smiley images that should be sized relative to the cap height
of the text they're embedded into.

3. Providing a sparkline (miniature, info-rich graph meant to be
interleaved with text) that's baseline aligned and sized relative to cap
height in order to avoid disrupting the height of the line.

Thanks,

Alan
Received on Wednesday, 26 October 2011 16:49:51 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:45 GMT