jeremias    2003/06/23 01:36:13

  Modified:    src/documentation/content/xdocs pdfencryption.xml
  Log:
  Added instructions for embedding.
  
  Revision  Changes    Path
  1.6       +69 -1     xml-fop/src/documentation/content/xdocs/pdfencryption.xml
  
  Index: pdfencryption.xml
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/documentation/content/xdocs/pdfencryption.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- pdfencryption.xml 27 May 2003 00:02:42 -0000      1.5
  +++ pdfencryption.xml 23 Jun 2003 08:36:13 -0000      1.6
  @@ -7,6 +7,7 @@
       <title>PDF encryption.</title>
       <authors>
         <person name="J.Pietschmann" email="[EMAIL PROTECTED]"/>
  +      <person name="Jeremias Märki" email="[EMAIL PROTECTED]"/>
       </authors>
     </header>
     <body>
  @@ -30,7 +31,7 @@
         </p>
       </section>
       <section>
  -      <title>Usage</title>
  +      <title>Usage (command line)</title>
         <p>
           Encryption is enabled by supplying any of the encryption related
           options.
  @@ -58,6 +59,73 @@
           <code>-noannotations</code> options, which disable printing, copying
           text, editing in Adobe Acrobat and making annotations, respectively.
         </p>
  +    </section>
  +    <section>
  +      <title>Usage (embedded)</title>
  +      <p>
  +        When FOP is embedded in another Java application you need to set an 
  +        options map on the renderer. These are the supported options:
  +      </p>
  +      <table>
  +        <tr>
  +          <th>Option</th>
  +          <th>Description</th>
  +          <th>Values</th>
  +          <th>Default</th>
  +        </tr>
  +        <tr>
  +          <td>ownerPassword</td>
  +          <td>The owner password</td>
  +          <td>String</td>
  +          <td/>
  +        </tr>
  +        <tr>
  +          <td>userPassword</td>
  +          <td>The user password</td>
  +          <td>String</td>
  +          <td/>
  +        </tr>
  +        <tr>
  +          <td>allowPrint</td>
  +          <td>Allows/disallows printing of the PDF</td>
  +          <td>"TRUE" or "FALSE"</td>
  +          <td>"TRUE"</td>
  +        </tr>
  +        <tr>
  +          <td>allowCopyContent</td>
  +          <td>Allows/disallows copy/paste of content</td>
  +          <td>"TRUE" or "FALSE"</td>
  +          <td>"TRUE"</td>
  +        </tr>
  +        <tr>
  +          <td>allowEditContent</td>
  +          <td>Allows/disallows editing of content</td>
  +          <td>"TRUE" or "FALSE"</td>
  +          <td>"TRUE"</td>
  +        </tr>
  +        <tr>
  +          <td>allowEditAnnotations</td>
  +          <td>Allows/disallows editing of annotations</td>
  +          <td>"TRUE" or "FALSE"</td>
  +          <td>"TRUE"</td>
  +        </tr>
  +      </table>
  +      <note>
  +        Encryption is enabled as soon as one of these options is set.
  +      </note>
  +      <p>
  +        An example to enable PDF encryption in Java code:
  +      </p>
  +      <source><![CDATA[
  +Driver driver = new Driver();
  +driver.setRenderer(Driver.RENDER_PDF);
  +Map rendererOptions = new java.util.HashMap();
  +rendererOptions.put("ownerPassword", "mypassword");
  +rendererOptions.put("allowCopyContent", "FALSE");
  +rendererOptions.put("allowEditContent", "FALSE");
  +rendererOptions.put("allowPrint", "FALSE");
  +driver.getRenderer().setOptions(rendererOptions);
  +driver.setOutputStream(...]]></source>
       </section>
       <section>
         <title>Environment</title>
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to