From af9d8727e1984502cde553c1d722932ff1f15d94 Mon Sep 17 00:00:00 2001 From: Laurenz Date: Wed, 29 Nov 2023 11:49:14 +0100 Subject: [PATCH] Don't write multiple authors in XMP metadata Fixes #2556. --- crates/typst-pdf/src/lib.rs | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/crates/typst-pdf/src/lib.rs b/crates/typst-pdf/src/lib.rs index 005b5a9e0..0c82cd90e 100644 --- a/crates/typst-pdf/src/lib.rs +++ b/crates/typst-pdf/src/lib.rs @@ -183,8 +183,25 @@ fn write_catalog(ctx: &mut PdfContext, ident: Option<&str>, timestamp: Option` in the XMP metadata. This is, in fact, exactly what the + // PDF/A spec Part 1 section 6.7.3 has to say about the matter. It's a + // bit weird to not use the array (and it makes Acrobat show the author + // list in quotes), but there's not much we can do about that. + let joined = authors.join(", "); + info.author(TextStr(&joined)); + xmp.creator([joined.as_str()]); } let creator = eco_format!("Typst {}", env!("CARGO_PKG_VERSION"));