What hqf-pdf renders

Whole documents — invoices, delivery notes, payslips, contracts — and a small example for every feature they are built from, each producing a real PDF. Below is what each one shows; open the rendered samples to see the files themselves.

View the rendered samples

A commercial invoice

A commercial invoice: letterhead, logo, a billed-lines table, totals, and a QR code that pays it by SEPA transfer.

Available for: Rust Python

A delivery note

The note that travels with the goods: a barcode against each article, a box the receiver ticks, and the consignment's own code.

Available for: Rust Python

A payslip

A payslip: eighteen contribution lines with employee and employer shares, the month against the year to date.

Available for: Rust Python

A two-page services contract

A services agreement over two pages, ending in signature, name and date fields a reader fills in.

Available for: Rust Python

A landscape certificate

A landscape certificate whose border and seal are drawn as paths, not placed as pictures.

Available for: Rust Python

A boarding pass

A boarding pass carrying the IATA BCBP string a gate scanner reads.

Available for: Rust Python

A sheet of shelf labels

A sheet of die-cut shelf labels, priced and barcoded, with cut marks in the margins.

Available for: Rust Python

A minimal PDF

The smallest complete file: a page, and shapes drawn on it.

Available for: Rust Python

Embedded, subset fonts

Text in an embedded font, subset to the glyphs it draws.

Available for: Rust Python

Paragraph flow and alignment

A paragraph broken into lines, set four ways: left, right, centred, justified.

Available for: Rust Python

Breaking an overlong word

A word too wide for its column: left whole, or cut to the edge.

Available for: Rust Python

Soft hyphens and no-break spaces

A justified column set twice: the long words breaking at their soft hyphens with a hyphen shown, or left whole, and a figure a no-break space keeps together.

Available for: Rust Python

Break points after a slash or a hyphen

A justified column set twice: file paths and compounds running past the edge with no break points, then wrapping where a break after a slash or a hyphen is allowed.

Available for: Rust Python

Clipping paths

A field of stripes shown through two clipping paths: a disc set by the nonzero rule, and a frame set by the even-odd rule over two nested rectangles.

Available for: Rust Python

Grey, screen and printing colours

Swatches in each of the three colour spaces — a grey as one number, a screen colour as three, a printing colour as four inks — each captioned with the operators it wrote, and one mid-grey said three ways.

Available for: Rust Python

Colour the document defines

The same six colours said as bare numbers and then through the sRGB profile the file carries, plus a lightness ramp and a hue sweep in CIE L*a*b*: colour that still means the same thing on another screen and on a press.

Available for: Rust Python

Inks on plates of their own

Two inks the press carries on plates of their own, each at ten tints, a piece of work set in both, and the crosshairs that line the plates up — set in the colorant every plate answers to.

Available for: Rust Python

Several plates at once, each with a tint of its own

Eight subsets of the process plates with the program each is shown through printed under it, and two inks of the press's own on one space, every tint of each against the other.

Available for: Rust Python

A chart of colours, and a drawing that names places in it

A chart of house colours the file carries, and a drawing whose sixteen numbers are places in it rather than colours. The same drawing is shown twice through two charts: repainting the house is one table, not one drawing.

Available for: Rust Python

One hatch, laid down in as many colours as the page asks for

One cell that states no colour of its own, laid down in five colours and in five strengths of one press ink: the fill says what colour to lay it down in. Beside them, the same hatch as cells that carry their own colours, which is one cell per colour.

Available for: Rust Python

A sheet as it goes to the press

One drawing on three pages: a press sheet stating where the ink runs, where the blade falls and what is worth keeping, with corner marks; the same sheet cropped to the finished page; and a landscape page that states a quarter turn clockwise on an upright sheet.

Available for: Rust Python

A slideshow that runs itself

Thirteen slides, each stating the effect it arrives by — all twelve the standard defines — how long that effect takes and how long the slide stands before the next one comes. The file opens full screen, which is the only place a reader reads any of it.

Available for: Rust Python

A sheet that measures what it says

Three rules — centimetres, inches and points — on a page that states it is to print at the size it was drawn and that the reader is not to offer anything else. That second entry arrived with PDF 2.0, so the file declares 2.0 rather than having it raised behind the caller's back.

Available for: Rust Python

A register whose every part says where it came from

Two sittings bound into one file. Each page carries a packet of its own — what it is, whose hand wrote it, when — the plate on the second page carries one too, and each transcription is tied to the page it transcribes rather than to the file at large. Tying a carried file to anything but the whole document arrived with PDF 2.0, so the file declares 2.0.

Available for: Rust Python

An archival sheet carrying fields of its own

A records office's reference, department, retention date and classification, in a PDF/A-3 file. No part of the standard knows what a retention date is, so each field arrives in the metadata packet with a description of itself — its type, who it is written for, what it means — which is what makes a validator accept metadata of one's own invention. The page prints the same list, so what a person reads and what a machine reads cannot drift apart.

Available for: Rust Python

A handbook that says how it wants to be read

Four pages that state what happens the moment the file is opened: the page a reader turns to and how much of it fills the window, the bookmarks beside it, the pages two at a time, a print dialogue already filled in, and the address its relative links are read against.

Available for: Rust Python

The same numbers, through spaces that say what they mean

Six colours and a grey ramp painted three times over with the very same numbers: left to the device, then through spaces stating the white, the exponent and the primaries they are measured against. The measurement travels in a handful of numbers, with no profile to embed.

Available for: Rust Python

The device a file's colours are meant for

The output intent a file carries, printed on the page it describes: the condition, its description and the profile behind them, with a ramp and one swatch per channel painted through that same profile. Hand a press profile on the command line and the page is drawn in that press's inks instead.

Available for: Rust Python

Transparency and blend modes

Half-opacity fills that overlap and mix, and one orange square laid over a blue bar in four blend modes, through an extended graphics state.

Available for: Rust Python

Axial and radial gradients

Axial and radial gradients painted into clipped boxes: a horizontal and a diagonal two-colour blend, a radial one whose outer colour is extended to the corners, and a three-stop blend from a stitched function.

Available for: Rust Python

Text and shapes filled with a gradient

A gradient as the colour something is filled with, through a shading pattern: a headline whose letters are windows onto a three-stop blend, and a panel filled with a radial one.

Available for: Rust Python

Functions, the shape a colour follows

What a function says a colour does, in each of its four kinds: a spectrum read off a table of samples, a ramp cut into bands by a stack program, an ink whose tint transform is a program printed under its swatches, and the table stitched to a pair of endpoints.

Available for: Rust Python

Content shown and hidden by layer

One floor plan on four layers a reader shows and hides: the furniture and the dimensions shown, the notes hidden until asked for, and a draft mark that is looked at but never printed.

Available for: Rust Python

One drawing, placed many times

One badge built as a drawing and placed eight times, plus once at half size: the file holds its operators once, whatever it costs to place.

Available for: Rust Python

One cell, tiled across whatever it fills

Six panels filled with tiling patterns — bars, dots, a slant from the pattern's matrix, brickwork, two patterns crossing, a wider step — and a wordmark whose letters are windows onto the brickwork.

Available for: Rust Python

One rectangle, four masks

The same flat rectangle four times over, each under a different soft mask — a gradient fade, a radial vignette, letters cut through it, a coverage read from opacity — and a band that runs out with a tag painted whole inside it.

Available for: Rust Python

Text poured into columns

One long passage poured into three columns, each fitting the lines its height allows and handing the rest to the next.

Available for: Rust Python

Paragraph indents and spacing

The same two paragraphs six ways: indents, the room around a paragraph, its last line, its first baseline.

Available for: Rust Python

A contents page with dot leaders

A contents page whose entries are led to their page numbers by dots the layout draws.

Available for: Rust Python

Styled runs inside a paragraph

A paragraph whose style changes inside it: size, underline, colour.

Available for: Rust Python

Tabulations and their stops

The same tabulated rows under each of the three tab methods, then a contents page whose dots run out to a right-hand stop: the pen stepped on relatively, landed on a typewriter's grid, or sent to a ruler stop that sets its run on itself, centred over it, or on its decimal point.

Available for: Rust Python

Lists made from a hanging indent

Bulleted, numbered and nested lists, each built out of a hanging indent and one tab stop rather than out of a list engine: the marker hangs in the room the indent opens, and every line below the first begins where the tabulation put the body.

Available for: Rust Python

Stamps fitted to a box

What a document says about itself — DRAFT, COPY, PAID — laid across boxes of four different shapes and scaled to each.

Available for: Rust Python

Shrunk headings and a turned label

Headings of different lengths shrunk to share one column, and a label turned a quarter turn up the page's spine.

Available for: Rust Python

A multi-page invoice table

An invoice table, laid out across as many pages as its lines need.

Available for: Rust Python

Cell margin, border, padding and fill

What a cell can do with its own box: margin, border, padding, fill.

Available for: Rust Python

Coloured cell borders and fills

A cell's four sides in four different colours, and coloured fills told apart from coloured borders.

Available for: Rust Python

A self-paginating table

A long table handed over whole, deciding its own pagination, its heading on top of every page, its footnote under every page, its shading said once for the whole table, and a note the caller draws under each page from the geometry the placement gives it.

Available for: Rust Python

Cells merged down the rows

A specification sheet whose cells are merged down the rows: each group named once beside all of its rows, one note beside them, the hairlines stopping at their edges, and a note too long for the rows it covers growing the last of them.

Available for: Rust Python

Columns measured from their cells

One parts list twice: four columns sharing the width equally, then the reference, the quantity and the price each as wide as their own widest cell and the description given everything they leave.

Available for: Rust Python

Pictures inside table cells

A catalogue whose first column is a picture rather than text: four pictures of wildly different pixel sizes and proportions, each fitted whole and undistorted into the cell the table gives it and standing against a different corner of it, asking its column for no width and its row for no height.

Available for: Rust Python

Overlong text in a narrow cell

Overlong text in a narrow table cell: left to overflow the column, or cut to it.

Available for: Rust Python

A gallery of picture formats

Every picture the tests ship with, on one page, each captioned with what its own file declares.

Available for: Rust Python

A picture fitted into a box

One picture fitted into a box of one size eight ways: sized four ways, anchored, turned by a quarter and by an angle of its own, and mirrored — every panel drawn from the matrix its policy gives.

Available for: Rust Python

Code 128 and retail barcodes

A page of barcodes, drawn as bars: Code 128 and the retail family, EAN-13, UPC-A, EAN-8.

Available for: Rust Python

Data Matrix codes

A page of Data Matrix codes, drawn as squares.

Available for: Rust Python

Internal and external links

Pages that link out of themselves and to each other.

Available for: Rust Python

Links and marks on placed text

Links and marks hung on text the engine has already placed: a band behind a line, an underline, a boxed cell — every rectangle taken from the boxes the flow and the table report, none of it measured by hand.

Available for: Rust Python

Custom page labels

Pages numbered by their labels rather than their position.

Available for: Rust Python

A tagged, accessible document

A document that says what each run of ink stands for, and which runs are furniture. Its prose and its table describe themselves, a paragraph and a cell at a time. Validates as PDF/A-3a and PDF/UA-1.

Available for: Rust Python

An overlay on a letterhead

An invoice laid on a letterhead somebody else made.

Available for: Rust Python

The evaluation watermark

What an unlicensed copy looks like: the evaluation watermark the library stamps on every page.

Available for: Rust Python

An interactive form

A form a reader fills in: text boxes, a check box, a drop-down, radio buttons.

Available for: Rust Python

A Factur-X electronic invoice

An electronic invoice: a PDF/A-3 file carrying its own XML.

Available for: Rust Python

An archivable PDF/A-3 form

A form that is also a PDF/A-3 file: every field baked in with a visible border, needing no reader.

Available for: Rust Python

The embedded ICC profile

The ICC profile the library embeds in a PDF/A file.

Available for: Rust Python

PDF server examples

The hosted render server has its own set of examples. They will appear here once their samples are rendered.