Print Page-Break Avoid Rules

Conditional print-fragmentation fit screen for explicit break-inside avoidance; oversized content may require breaking, not guarantee printer pagination. Explicit supplied computed/layout context only; not a browser cascade/layout engine or cross-browser guarantee.

Description

Avoiding an internal page break depends on whether content can fit on a page.

Avoiding an internal page break depends on whether content can fit on a page.1

A size screen cannot resolve a complete browser pagination algorithm. Use Print Page-Break Avoid Rules to evaluate the supplied inputs under the specific model below.

When to use Print Page-Break Avoid Rules

Use Print Page-Break Avoid Rules to evaluate the supplied inputs under the specific model below. Define the supplied layout, token or rendering scenario and establish the relevant units and browser context independently.

How to use Print Page-Break Avoid Rules and understand its results

  1. Define the supplied layout, token or rendering scenario and establish the relevant units and browser context independently.
  2. Enter Observed block height px, Remaining page height px, Full page height px, Avoid inside requested using the field table and validation rules below, then run the tool.
  3. Read Avoid can fit on fresh page, Conditional move to next page and interpret units, signs, ordering and placeholders as explained below.
  4. If the tool reports an input error, correct that field and rerun. A successful false result, empty match list or unknown-evidence placeholder has the specific meaning described here; check the limitations before applying the result.
Input fieldMeaningValue typeRequirement
observedBlockHeightPxObserved block height pxnumberRequired; constraints below
remainingPageHeightPxRemaining page height pxnumberRequired; constraints below
fullPageHeightPxFull page height pxnumberRequired; constraints below
avoidInsideRequestedAvoid inside requestedbooleanRequired; constraints below

Enter positive full-page height, nonnegative remaining-page height no larger than a page, nonnegative block height and an avoid-break boolean. A block fits a fresh page when its height is at most page height. Move it only when avoidance is requested, it fits a fresh page and it is larger than the remaining space. Equality stays on the current page; fragmentation rules beyond this local decision are not simulated.

fitsFresh = block≤page; move = avoid and fitsFresh and block>remaining

Field order, units and branch conditions follow the implementation explanation above.

Output fieldMeaningValue type
avoidCanFitOnFreshPageAvoid can fit on fresh pageboolean
conditionalMoveToNextPageConditional move to next pageboolean
json
{
  "input": {
    "observedBlockHeightPx": 120,
    "remainingPageHeightPx": 100,
    "fullPageHeightPx": 200,
    "avoidInsideRequested": true
  },
  "output": {
    "avoidCanFitOnFreshPage": true,
    "conditionalMoveToNextPage": true
  }
}

Limitations and assumptions

A size screen cannot resolve a complete browser pagination algorithm. Apply the exact scope and assumptions described above.

All listed fields require explicit values. Unexpected fields, incorrect types, nonfinite numbers and sparse arrays fail validation. Domain-specific bounds, alignments and supported tokens are stated above; extremely large inputs or outputs can also be rejected. These errors differ from successful results such as false, no matches or unknown evidence.

Alternative or Complementary methods

Use forced-colors Adjustments Lookup for a related task: Forced-color mode can substitute a user agent's selected colors.

Use all:unset Reset Behavior Lookup for a related task: All unset applies inheritance or initial-value behavior with defined exclusions.

References

  1. Print Page-Break Avoid Rules — tool.io

Similar or alternative tools

Don't forget to set a bookmark for tool.io!
Privacy | Imprint | Cookies