- From: Julian Viereck <julian.viereck@googlemail.com>
- Date: Sun, 17 Mar 2013 22:03:23 +0100
- To: Simon Sapin <simon.sapin@exyr.org>, spec:w3c:style <www-style@w3.org>, Daniel Glazman <daniel.glazman@disruptive-innovations.com>, Robert O'Callahan <robert@ocallahan.org>
On 3/4/13 5:01 PM, Simon Sapin wrote: > Le 03/03/2013 00:54, Julian Viereck a écrit : >> - Does adding a flag like "nomarginboxes" makes sense? > > What’s a flag in this context? Is it something that can be switched > from JavaScript? From CSS? In the current implementation, it's something on the HTML structure and therefore can be toggled by JS. However, I think this flags makes more sense to be set from within CSS. E.g. how about: ``` CSS html { default-margin-boxes: no; } ``` ... yes, I know this is not the way it should end up but I cannot think of a better naming ATM. Better ideas welcome :) On 3/5/13 10:38 PM, Simon Sapin wrote: > Le 05/03/2013 21:44, Daniel Glazman a écrit : >> On 04/03/13 17:01, Simon Sapin wrote: >> >>> So another option could be, as you say, to completely disable the >>> default headers and footers in some situation: >>> >>> a. If at least one page-margin box is generated [1] on the current >>> page. >>> (I don’t like the inconsistency between pages of the document) >>> >>> b. … on any page of the same document (costly to implement, you need to >>> look for "propagated" values of the 'page' property in the box tree.) >>> >>> c. If any margin at-rule is used in author stylesheets (simpler) >>> >>> d. With an explicit switch, maybe a new property in the @page context. >>> (Not very elegant.) >>> >>> e. Some other condition? >>> >>> [1] http://dev.w3.org/csswg/css3-page/#generated >>> >>> >>> What do you think? >> >> I think we're on a dangerous path here, where author's settings >> could override user defined settings... In our case, have a document >> tell the UA to override the header/footer settings specified in the >> print dialog. Careful, careful. >> >> In fact, the best option would be to >> >> 0. implement @page and the margin boxes rules >> 1. have browsers implement the print dialog's current 6 margin boxes >> through a UA @page and page margin boxes >> 2. a radio in the print dialog "let the document specify headers >> and footers" and another radio "override document headers/footers" >> >> That way all is based on the cascade and the user can always have >> all the various settings applied. > > How about this? The user still ultimately has control on what headers > and footers are printed, but <some condition, see above> only changes > the default. How about this (only slightly different to previous raised approach): Assume there is at least one margin-box defined in the document. The margin-box might have `content: none`. Then: - the UA should disable it's default header/footer but let the user enable them if wanted - the UA should provide a way to disable all the margin-boxes defined on the page. This might be done by using a checkbox "Ignore document specify headers and footers". With this, there is no need for an extra "disable the margin-boxes by default" flag like 'nomarginboxes'. Problem: What is a "document". E.g. the user might select only a range of pages to be printed - is a "document" then only the selected pages OR all the possible pages that can be printed? > In both cases, I don’t think the spec should have normative > requirements for UAs, only suggestions. Having only suggestions in the spec sounds good to me. - Julian
Received on Sunday, 17 March 2013 21:03:53 UTC