1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
// stet - A PostScript Interpreter
// Copyright (c) 2026 Scott Bowman
// SPDX-License-Identifier: Apache-2.0 OR MIT
//! PDF output device for stet — converts display lists into
//! print-production-quality PDF files.
//!
//! [`PdfDevice`] is an [`OutputDevice`](stet_core::device::OutputDevice)
//! implementation that walks a display list and emits the corresponding
//! PDF constructs. It preserves the full fidelity of the source, including
//! native CMYK and spot colours (without a lossy RGB round-trip),
//! transfer functions, halftone screens, black-generation / undercolour
//! removal, overprint settings, rendering intent, and trim boxes.
//!
//! Fonts are subsetted to the glyphs actually used on the page, with
//! per-font ToUnicode CMaps for text extraction and search.
//!
//! All seven PostScript shading types are translated to native PDF
//! shading objects (axial, radial, Gouraud mesh, Coons/tensor patch).
//!
//! Most users should use
//! [`stet::Interpreter::render_to_pdf`](https://docs.rs/stet) from the
//! [`stet`](https://crates.io/crates/stet) facade crate. Use
//! [`PdfDevice`] directly when you want to wire the PDF writer into a
//! custom rendering pipeline or capture the PDF bytes in-memory without
//! touching the filesystem.
pub use PdfDevice;