Skip to main content

geometry

Function geometry 

pub fn geometry(
    canvas: Rect,
    max_width: f64,
    top_gap: f64,
    content_margin: f64,
) -> PageGeometry
Expand description

Lay out a centered page within canvas: max_width caps the page width, top_gap is the margin above it (and the side gap when the canvas is wide), and content_margin is the inner text margin on each side.