From 3800fbcd385314883c58c7ca69ceea56ad39e538 Mon Sep 17 00:00:00 2001 From: Jeremias Maerki Date: Tue, 3 Aug 2010 13:44:54 +0000 Subject: Bugzilla #44460: Added support for PDF file attachments (embedded files) including basic-link support to reference them. Based on work submitted by: Andrejus Chaliapinas I've changed and improved his patch extensively and added some documentation. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@981875 13f79535-47bb-0310-9956-ffa450edef68 --- src/documentation/content/xdocs/trunk/output.xml | 94 +++++++++++++++++------- 1 file changed, 69 insertions(+), 25 deletions(-) (limited to 'src/documentation/content/xdocs') diff --git a/src/documentation/content/xdocs/trunk/output.xml b/src/documentation/content/xdocs/trunk/output.xml index d1ab9e19f..1766cd493 100644 --- a/src/documentation/content/xdocs/trunk/output.xml +++ b/src/documentation/content/xdocs/trunk/output.xml @@ -194,32 +194,76 @@ out = proc.getOutputStream();]]> e.printStackTrace(); } }]]> -

- Check the iText tutorial and documentation for setting access flags, password, - encryption strength and other parameters. -

- -
- Watermarks -

- In addition to the PDF Post-processing options, consider the following workarounds: -

-
    -
  • - Use a background image for the body region. -
  • -
  • - (submitted by Trevor Campbell) Place an image in a - region that overlaps the flowing text. For example, make - region-before large enough to contain your image. Then include a - block (if necessary, use an absolutely positioned block-container) - containing the watermark image in the static-content for the - region-before. Note that the image will be drawn on top of the - normal content. -
  • -
+

+ Check the iText tutorial and documentation for setting access flags, password, + encryption strength and other parameters. +

+
+
+ Watermarks +

+ In addition to the PDF Post-processing options, consider the following workarounds: +

+
    +
  • + Use a background image for the body region. +
  • +
  • + (submitted by Trevor Campbell) Place an image in a + region that overlaps the flowing text. For example, make + region-before large enough to contain your image. Then include a + block (if necessary, use an absolutely positioned block-container) + containing the watermark image in the static-content for the + region-before. Note that the image will be drawn on top of the + normal content. +
  • +
+
+
+ Extensions +

The PDF Renderer supports some PDF specific extensions which can be embedded + into the input FO document. To use the extensions the appropriate namespace must + be declared in the fo:root element like this:

+ + ]]> +
+ Embedded Files +

+ It is possible to attach/embed arbitrary files into a PDF file. You can give a name and + a description of the file. Example: +

+ + + + + ]]> +

+ pdf:embedded-file must be a child of fo:declarations. + The "src" property is used to reference the file that is to be embedded. This property + uses the "uri-specification" datatype from the XSL-FO specification. + The "filename" property is optional. If it is missing the filename is automatically set + from the URI/IRI of the "src" property. An optional description can also be added to + further describe the file attachment. +

+

+ It is also possible to reference an embedded file from an fo:basic-link. + Use the special "embedded-file:" URI scheme with the filename as single argument after + the URI scheme. Example: +

+ Attached Image +]]> +

+ Note: Not all PDF Viewers (including some Acrobat Versions) will open the embedded file + when clicking on the link. In that case, the user will have to open he attachment via + the separate list of file attachments. +

+
+
-
PostScript

-- cgit v1.2.3