Printers usually have a small area at each of the four edges of a sheet of paper that they are not capable of marking reliably, usually due to the printer’s paper handling mechanism. The default page margins are expected to be bigger than these areas, but if authors set margins on their own, and even want to add @page margin boxes (e.g. for custom headers and footers), they need a way of telling where it's safe to print and not. The CSS environment variable env(safe-printable-inset) can be used to obtain this information. It will be the inset of the largest unprintable area. Although some printers don't have the same unprintable area inset along each of the four paper edges, printers may rotate the print output at their own discretion. The user agent cannot make assumptions about which edge (will it be the long or short edge?) is going to be fed first into the printer. Therefore, only one value can be reliably provided here: The larger of these four values.
The browser itself has access to information about unprintable areas, so that it can place UA-generated headers and footers within the printable area, and also make the default page margins large enough to prevent loss of content. But once authors want to set their own page margins, or add page margin boxes (for e.g. custom headers and footers), the problem becomes clear, since this information isn't exposed via CSS. When developers want to place content near the paper sheet edges, be it due to small @page margins or page margin boxes (for custom headers and footers, for instance), without this change, the author would either have to hope for the best, or add some "reasonably large" margin to steer clear of potentially unprintable regions on the sheet.
None
Does this intent deprecate or change behavior of existing APIs, such that it has potentially high risk for Android WebView-based applications?
None
None
Need to add WPT support for this. For example: A: Define a default printable inset and/or B: Add a META tag for it
No milestones specified