def bounds.intersection

gralha-svg-render@0.1.0.1 · svg.bend:4872

import gralha-svg-render@0.1.0.1/svg.bend as Svg
import Base
import gralha-text-scan@0.1.0.1/scan.bend as U

4872def bounds.intersection(a: Bounds, b: Bounds) -> Bounds:
4873  Bounds{x0, y0, x1, y1} = a
4874  Bounds{u0, v0, u1, v1} = b
4875  Bounds{U.max(x0, u0), U.max(y0, v0), U.min(x1, u1), U.min(y1, v1)}

Uses (3)

Used by (1)