AsciiDoctor PDF: Setting PDF metadata Description field from the adoc file

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

AsciiDoctor PDF: Setting PDF metadata Description field from the adoc file

jamesh
Hello all,

Finding AD PDF very useful in our documentation efforts, but have a question on setting PDF metadata.

I can set author, keywords and the title is set to the title of the document which is fine, but I have been unable to find a way of setting the Description field directly from the adoc (I can post process with exiftool or similar but that is a PITA), and it would also be useful to be able to set the Producer etc.

I may have just missed this in the documentations, but my google foo hasn't found anything, so any pointers welcome

James
Reply | Threaded
Open this post in threaded view
|

Re: AsciiDoctor PDF: Setting PDF metadata Description field from the adoc file

mojavelinux
Administrator
James,

I'm glad to hear the PDF converter is useful in your documentation efforts!

Here's the metadata that Asciidoctor PDF adds to the PDF:


Notice that the Producer field is set to match the author specified on the document.

The description attribute is not currently mapped. In reading the PDF 1.7 specification, I do not see a field that could accept this information. If you know of one, please enlighten me and I'd be happy to consider adding it.

Best Regards,

-Dan

On Fri, Apr 23, 2021 at 11:11 AM jamesh [via Asciidoctor :: Discussion] <[hidden email]> wrote:
Hello all,

Finding AD PDF very useful in our documentation efforts, but have a question on setting PDF metadata.

I can set author, keywords and the title is set to the title of the document which is fine, but I have been unable to find a way of setting the Description field directly from the adoc (I can post process with exiftool or similar but that is a PITA), and it would also be useful to be able to set the Producer etc.

I may have just missed this in the documentations, but my google foo hasn't found anything, so any pointers welcome

James


If you reply to this email, your message will be added to the discussion below:
https://discuss.asciidoctor.org/AsciiDoctor-PDF-Setting-PDF-metadata-Description-field-from-the-adoc-file-tp8594.html
To start a new topic under Asciidoctor :: Discussion, email [hidden email]
To unsubscribe from Asciidoctor :: Discussion, click here.
NAML


--
Dan Allen (he, him, his) | @mojavelinux | https://twitter.com/mojavelinux
Reply | Threaded
Open this post in threaded view
|

Re: AsciiDoctor PDF: Setting PDF metadata Description field from the adoc file

jamesh
Thanks for the rapid response.

I was able to set a description field using EXIFTool (on Ubuntu) as follows:

 exiftool -Description="Testing description metadata" fred.pdf

This is then displayed if you:

exiftool fred.pdf

But I have just noticed its not part of the properties displayed when I use qpdfview, so that's started to make me wonder.

Hmmm

James

Reply | Threaded
Open this post in threaded view
|

Re: AsciiDoctor PDF: Setting PDF metadata Description field from the adoc file

jamesh
Ah, although exiftool allows you to set a field called Description, it doesn't appear to be a standard option. That threw me in the wrong direction.

There is however "Subject", as pointed to be the code link above, which does what I need so thanks for the pointer!

James