> Neil Pharazyn wrote:
>> However, if you run this HTML page you'll see that it still doesn't
>> achieve
>> what I want, which is to limit the number of pages of content
>> printed out.
>> In this case there are two A4 pages of content. It prints both pages
>> despite my body.A4 saying not print anything past 29.7cm, which is
>> one A4
>> sheet length. Maybe overflow doesn't work for printing, or cm isn't
>> recognised, or who knows what????
>> [...]
>> <html>
>> <head>
>> <title>overflow_print_test.htm</title>
>> <meta http-equiv="Content-Type" content="text/html;
>> charset=iso-8859-1">
>> <meta name="generator" content="BBEdit 7.1.4">
>>
>> <style type="text/css">
>>
>> p
>> {
>> font-family: Times New Roman, Times, serif;
>> font-size: 12px;
>> line-height: 115%;
>> margin: 10px;
>> }
>>
>>
>> @media print {
>> body {
>> height:100px;
>> width:100px;
>> overflow:hidden;
>> }
>> }
>>
>> @media print {
>> body.A3 {
>> height:42cm;
>> overflow:hidden;
>> }
>> body.A4 {
>> height:29.7cm;
>> overflow:hidden;
>> }
>> }
>>
>> </style>
>> </head>
>>
>> <body class="A4">
>>
>> <table width="100%" border="0" cellspacing="0" cellpadding="0"
>> name="holdit">
>> <tr id="masterContainer" valign="top" align="left">
>> <td width="33%">
>>
>> <p>column 1<br><br>
>> I
>> From fairest creatures we desire increase,
>> That thereby beauty's rose might never die,
>> But as the riper should by time decease,
[...] (snipped long text content)
That worked nearly perfectly with Gecko 1.9. I get a 1-page pdf file.
Opera 9.5b and Safari didn't do that well:
Safari: multi-page output (ignores overflow:hidden)
Opera: 1 page filed, but a multi-page pdf file.
Notes:
1. you limit the body to height of 29.7 cm. That is too tall if what
you want to limit the print result to one sheet of paper; you need to
take the default print-margins into account (print-margins as set by
the printer, something you cannot control - the 'Non-printable area'
in CSS 3 paged media).
2. I'm not sure what should happen with overflowed content (hidden) in
paged media. Should the device reserve space for the hidden content as
Opera does - that doesn't seem to make sense ?
3. cm (centimetre) is perfectly valid. The are no media-specific
limits to the overflow property.
4. there is no 4.
Philippe
---
Philippe Wittenbergh
http://l-c-n.com/
______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/