Progress bar component for PDF documents.
Renders a horizontal progress/percentage bar with track and fill, optional label, and rounded or square ends.
Inspired by Material UI's LinearProgress component.
Examples
# Simple progress bar
doc |> Pdf.Component.Progress.render({50, 400}, %{width: 200, value: 75})
# Styled progress bar with label
doc |> Pdf.Component.Progress.render({50, 400}, %{
width: 300,
value: 42,
color: {0.18, 0.72, 0.45},
show_label: true,
height: 16,
border_radius: :rounded
})
Summary
Functions
Render a progress bar at {x, y} (top-left corner).
Functions
Render a progress bar at {x, y} (top-left corner).
Style options
:width— total bar width (default200):height— bar height (default8):value— progress percentage 0-100 (default0):color— fill color (default blue):track_color— background track color (default light gray):border_radius—:rounded(default),:square, or number:show_label— show percentage text (defaultfalse):label_color— text color for label (default dark gray):font— font name (default"Helvetica")