W3C home > Mailing lists > Public > www-style@w3.org > November 2012

[css3-values] viewport units (vw/vh/vmin/vmax) and @page rules

From: L. David Baron <dbaron@dbaron.org>
Date: Sun, 11 Nov 2012 13:14:17 -0800
To: www-style@w3.org
Message-ID: <20121111211417.GA11812@crum.dbaron.org>
defines the viewport-relative units 'vw', 'vh', 'vmin', and 'vmax'
as relative to the size of the initial containing block.

in turn says:
  # The containing block in which the root element lives is a
  # rectangle called the initial containing block. For continuous
  # media, it has the dimensions of the viewport and is anchored at
  # the canvas origin; it is the page area for paged media.

in turn describes the page area as the area inside the page margins.
In particular:
  # The page box is a rectangular region that contains two areas:
  # * The page area. The page area includes the boxes laid out on
  #   that page. The edges of the first page area establish the
  #   rectangle that is the initial containing block of the
  #   document. The canvas background is painted within and covers
  #   the page area.
  # * The margin area, which surrounds the page area. The page
  #   margin area is transparent. 
(While I'm here, shouldn't the first quote above also mention that
it's the first page?)

So, if we have:

  @page {
    margin-left: 10vw;

  (1) the user-agent try to solve the relevant equations to find a
  valid size for the page box given the margins?  (This seems like
  it might be doable in a few of the simple cases, but certainly
  isn't solvable in general.)

  (2) the declaration be ignored?

  (3) the declaration be treated as some other particular value
  (e.g., '0', 'auto')?

With css3-page, this problem becomes worse as the presence of the
'size' property defined in
means that we also have to describe how to handle either of:

  @page { size: 50vw 50vh; }
  @page { size: 50vh 50vw; }

which I think means that option (1) isn't realistic.


𝄞   L. David Baron                         http://dbaron.org/   𝄂
𝄢   Mozilla                           http://www.mozilla.org/   𝄂
Received on Sunday, 11 November 2012 22:58:27 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 11 February 2015 12:35:18 UTC