Closed Bug 1838732 Opened 2 years ago Closed 2 years ago

Chrome seems to ignore small @page size rules, while Firefox does not, leading to webcompat issues

Categories

(Core :: Printing: Output, defect)

defect

Tracking

()

RESOLVED DUPLICATE of bug 1807985

People

(Reporter: twisniewski, Unassigned)

References

()

Details

Attachments

(1 file)

Attached file testcase.html

See the attached test-case. Chrome seemingly ignores the 10px page size of the second rule in the CSS, but Firefox does not. If I change the 10px to 100px, then Chrome will honor the rule, leading me to wonder if they are just ignoring sizes that they deem "too small".

This is causing webcompat issues, as this was discovered while diagnosing why the print preview of www.theaa.com's route planner shows nothing in Firefox's print preview.

Note that Safari seems to also ignore small values like Chrome does.

The key thing here is that size:10px is smaller than the default margins. So we end up with a negative page content area (after subtracting away the default margins from our 10px of page space), and Chrome disallows pages with <=0 content area, so it falls back to the default page size.

If you print-preview this in Chrome and choose "Margins: None", then they do honor the small page size (because now they have some greater-than-zero space for content).

This seems to be bug 1807985.

(In reply to Thomas Wisniewski [:twisniewski] from comment #0)

This is causing webcompat issues, as this was discovered while diagnosing why the print preview of www.theaa.com's route planner shows nothing in Firefox's print preview.

Yikes. Why would they be doing that. :-/ Anyway, good to know there's webcompat impact; until now, bug 1807985 was purely edge-case-handling.

Status: NEW → RESOLVED
Closed: 2 years ago
Duplicate of bug: 1807985
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: