ztcl::pdf

ztcl::pdf subcommand ?arg ...?

Makes a PDF document: pages, text in embedded TrueType fonts, rectangles, lines, images, links, named places, the outline, and the document information.

Subcommands

Synopsis What it does
create ?-compress bool? Makes a document and gives its handle.
font doc bytes Adds a TrueType font and gives its number.
page doc ?width height? Adds a page and gives its number. The default is A4.
text doc page font size x y string ?-color rgb? ?-ligatures bool? Shows text and gives its width.
measure doc font size string Gives the width of a string in points.
rect doc page x y width height ?-fill rgb? Fills a rectangle.
line doc page x0 y0 x1 y1 ?-width w? ?-color rgb? Strokes a line.
image doc bytes Adds a PNG or JPEG image and gives {number width height}.
place doc page image x y width height Shows an image in a rectangle.
`link doc page x0 y0 x1 y1 -uri url -dest name`
dest doc name page x y Names a place for a link.
outline doc title level page y Adds an entry to the outline.
info doc key value Sets the Title, Author, Subject, or Keywords.
bytes doc Gives the bytes of the PDF file.
pages doc Gives the count of pages.
delete doc Frees the document.

Facts