Skip to main content

PDFreactor integration for Plone

Project description

This Add-On package integrates the PDFreactor client API by RealObjects, as provided by the pdfreactor-api package, into Plone.

To effectively make use of it, you’ll need

  • a running PDFreactor server

  • the keys needed to access it; depending on the server configuration:

Features

  • a simple @@as.pdf browser view for contentish objects (providing a synchronous PDF export with standard options)

  • storage of connection settings in the Plone registry

  • a simple @@pdfreactor-config view to provide basic conversion settings.

    (For a package providing customizable conversion settings in the registry as well, see below.)

  • a simple CSS stylesheet which is used by the default configuration to suppress uninteresting page parts

Examples

Some generic sample scripts are contained in the docs/sample/ directory:

simple.py

A sample demonstrating the simple integration of PDFreactor into Python applications

async.py

A sample demonstrating an asynchronous integration which is recommended for medium to large documents

stream.py

A sample demonstrating how converted PDFs can be streamed, thus conserving memory

Installation

Plone environments are typically built using zc.buildout; so add to your buildout.cfg script:

[buildout]
...
eggs =
    pdfreactor.plone

and then run bin/buildout.

This will get you the pdfreactor-api package as well.

After restarting your Zope instance, you’ll find the package in the Quick-Installer or the Plone Add-Ons view.

After installing (or activating) the package there, go to the Plone registry to customize your PDFreactor connection settings (URL and license and / or API key); look for the interface (or prefix) “IPdfReactorConnectionSettings”.

For installation instructions regarding the PDFreactor service itself, please refer to PDFreactor Support.

Customization

Zope / Plone

You have several options:

  • You may subclass our .base.Exporter BrowserView class (which provides the @@as.pdf view) and override some of it’s methods, e.g.

    • converted_url

    • conversionSettings

  • You may connect our BrowserView class or subclasses of it to more specific interfaces than IContentish. (You might need a layer interface to avoid configuration conflicts).

  • You may override the @@pdfreactor-config view to modify the conversion options (generally, or by interface).

    One add-on package to get a global “TTW” customizable configuration is pdfreactor.parsecfg.

Please refer to the Zope / Plone documentation for instructions how to do this.

PDFreactor

For the details about the supported methods and configuration options of the PDFreactor itself, please refer to the documentation by RealObjects GmbH:

Support

If you are having issues concerning this Plone integration, please let us know; please use the issue tracker mentioned above.

For issues regarding the PDFreactor itself, please refer to RealObjects GmbH:

Contribute

(To this Plone integration package:)

License

The project is licensed under the MIT License.

Author

Changelog

1.0.0 (unreleased)

  • Initial release. [tobiasherp]

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pdfreactor.plone-1.0.0.dev3.tar.gz (23.4 kB view details)

Uploaded Source

File details

Details for the file pdfreactor.plone-1.0.0.dev3.tar.gz.

File metadata

  • Download URL: pdfreactor.plone-1.0.0.dev3.tar.gz
  • Upload date:
  • Size: 23.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.4.2 requests/2.19.0 setuptools/41.0.1 requests-toolbelt/0.8.0 tqdm/4.23.4 CPython/2.7.5

File hashes

Hashes for pdfreactor.plone-1.0.0.dev3.tar.gz
Algorithm Hash digest
SHA256 cbec7d89c4a2614a37ae8a47e0bfcb5be9e6a81d709bcff3763e91872fd717cd
MD5 23fb957416491c19e16021f799782043
BLAKE2b-256 e38cfdc4507b5ea5500c5811fc7446c34e91fda095325e13133c64c826b02559

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page