Printing Basic Installation

From PartKeepr Wiki
Revision as of 21:31, 10 June 2013 by Boldie (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search


First steps to activate printing / renderer

Due to some despondencies to external libraries the renderer are deactivated by default, so no disturbance with the main application will happen. To activate a desired renderer you have to set a symlink to the renderer or you have to copy the directory over.

The available renderer are located in "backend/Plugins/PrintingRenderer/" directory of your PartKeepr installation. The active renderer are located in the "backend/PartKeppr/Printing/Renderer" directory. To activate a renderer you have to set a symlink to the directory which contains your desired renderer. Every renderer has its own directory. For e.g. to activate the PDFDefaultRenderer after you have installed tcpdf do the following:

cd src/backend/PartKeepr/Printing/Renderer
ln -s ../../../Plugins/PrintingRenderer/PDFDefaultRenderer PDFDefaultRenderer

Installing tcpdf

The PDFDefaultRenderer uses the tcpdf library to create a pdf file. First of all get tcpdf from the Homepage http://www.tcpdf.org/ or install it from your distribution. If you are installing it on your own, you have to ensure the include_path of your php installation is pointing to the directory where your tcpdf is installed to. to install it, just download the zipped package from http://www.tcpdf.org/download.php and unzip the archive.

Where to unzip, is rather dependent on your installation, on my Ubuntu 12.04 system, I unzipped it to "/usr/share/php". Using the standard installation package, you should consider disabling the K_TCPDF_CALLS_IN_HTML option by changing the following file: tcpdf/config/tcpdf_config.php ensure the following line

define('K_TCPDF_CALLS_IN_HTML', false);

is set (search for the K_TCPDF_CALLS_IN_HTML and replace the true by false).