Three Statements in One File

A print shop receives one PDF of four pages. Nothing drawn on them says that it holds three customer statements rather than one long one, nor that the first customer is owed two copies and the third three. That usually arrives in a job ticket beside the file, and the day the ticket and the file stop agreeing, the wrong statement goes into the wrong envelope.

Here the file says it itself, where a press reads it and ordinary reading software ignores it. On a screen it is one document of four pages; on a press it is three jobs, each carrying its own instructions and its own attachment. The first statement runs to two pages, its terms of payment following it, and the other two are a page each. Nothing travels alongside the file any more, so there is nothing left to fall out of step with it.

What This Example Shows

  • Three statements in one file, each claiming the pages it runs to.
  • Who a statement is for, its town, and how many copies are owed.
  • An attachment per statement, belonging to it rather than to the file.

The Source Code, Complete

Nothing is left out and nothing is simplified: this is the program exactly as it runs, for the developer who uses this library. The third is the description itself: a plain list of what the page has to say, which is what the service is sent.

Read the Rust source Read the Python source Read the JSON source

The Document Itself

Open the document in English Open the document in French Open the document in German Open the document in Spanish Open the document in Italian Open the document in Portuguese

Examples Near This One

A Commercial Invoice

An invoice: each billed line follows the one before, the totals sit under the last, and the QR code holds the transfer. The customer points a telephone at it, and the banking app offers the exact sum into the exact account, with nothing retyped.

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.

A Payslip

A payslip: eighteen contribution lines, with the employee's share and the employer's, and for each the month's amount then the total since January. Each figure is tied to the line and the column it stands under, for software that reads the page aloud.

A Landscape Certificate

A certificate whose border, ribbon and seal are drawn as lines rather than photographed: sharp at any size, and a fraction of the weight.

A Boarding Pass

A boarding pass carrying, as a QR code, the one line the gates at an airport read — one character out of place and it is refused.

Every example, by subject