Implement native PDF links and vertical discard lists

This commit is contained in:
gloamxun committed 2026-11-18 23:39:45 +08:00
1 parent b6567f67e2
commit a53d9c9bf9
29 files changed
+980 -109

No files matched your search

@@ -533,6 +533,14 @@ impl Printer<'_> {
}
OutputOperation::PdfSave => self.command("pdfsave"),
OutputOperation::PdfRestore => self.command("pdfrestore"),
OutputOperation::PdfLink(node) => {
use crate::pdf_device::links::LinkNode;
self.command(match node {
LinkNode::Start(_) => "pdfstartlink",
LinkNode::End => "pdfendlink",
LinkNode::Destination { .. } => "pdfdest",
});
}
OutputOperation::PdfSetMatrix(tokens) => {
self.command("pdfsetmatrix");
self.tokens(tokens)?;