summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Allen <dan.j.allen@gmail.com>2020-09-29 23:57:12 -0600
committerDan Allen <dan.j.allen@gmail.com>2020-09-30 01:21:25 -0600
commit45f2126531b3ed09e30c6b0f3c59ab2f0701e265 (patch)
treed15c833da57acf9ae112dd0d84f19357295cdabb
parent094cca4f4bbc4e1c82afe187d2483dff43b7a7ef (diff)
document limitation with PDF/X-1a output of optimizer and suggest workaround [skip ci]
-rw-r--r--README.adoc13
1 files changed, 11 insertions, 2 deletions
diff --git a/README.adoc b/README.adoc
index 88959320..9f6bd4fc 100644
--- a/README.adoc
+++ b/README.adoc
@@ -1152,8 +1152,17 @@ Here's an example usage that converts your document and optimizes it:
$ asciidoctor-pdf -a optimize basic-example.adoc
-The command will generate an optimized PDF file.
-You can also try reducing the quality of the output file by passing a quality keyword to the `optimize` attribute (e.g., `--optimize=screen`).
+The command will generate an optimized PDF 1.4 file.
+In addition to optimizing the PDF file, it also converts it from plain PDF to a PDF/X-1a.
+
+The one limitation of generating a PDF/X-1a file is that it does not allow non-ASCII characters in the document metadata fields (i.e., title, author, subject, etc).
+To workaround this limitation, you can force Ghostscript to generate a PDF 1.3 file using the `pdf-version` attribute:
+
+ $ asciidoctor-pdf -a optimize -a pdf-version=1.3 basic-example.adoc
+
+Downgrading the version works as long as the PDF does not include color blending or transparency.
+
+If you are looking for a smaller file size, you can try reducing the quality of the output file by passing a quality keyword to the `optimize` attribute (e.g., `--optimize=screen`).
The `optimize` attribute accepts the following keywords: `default` (default, same if value is empty), `screen`, `ebook`, `printer`, and `prepress`.
If you've already generated the PDF, and want to optimize it directly, you can use the bin script: