DynaPDF Manual - Page 22

Previous Page 21   Index   Next Page 23

Language Bindings
Page 22 of 839
Custom Library Changes
This section is only of interest if you have a copy of the source codes. If you use a version
without source codes you can skip this chapter.
Compiler Switches
DynaPDF supports several compiler switches to disable unnecessary features. The following
macros disable or enable one of the image libraries used by DynaPDF as well as other features.
The macros are defined in the header file /main/drv_type.h.
#define DRV_SUPPORT_AES
1 // AES encryption and decryption
#define DRV_SUPPORT_BCDE 1 // about 400 KB -> Barcode engine
#define DRV_SUPPORT_CJK
1 // about 150 KB (CJK to Unicode conversion)
#define DRV_SUPPORT_EMF
1 // EMF Converter
#define DRV_SUPPORT_GIF
1 // about 1 KB
#define DRV_SUPPORT_IMP
1 // about 50 KB (PDF import)
#define DRV_SUPPORT_JP2K 1 // about 180 KB
#define DRV_SUPPORT_JPEG 1 // about 90 KB (no effect if TIFF is enabled)
#define DRV_SUPPORT_PGM
1 // PBM, PGM, PNM, PPM Image formats, ~1 KB
#define DRV_SUPPORT_PNG
1 // about 100 KB
#define DRV_SUPPORT_PSD
1 // about 1 KB
#define DRV_SUPPORT_RAS
1 // about 700 KB -> Rendering engine
#define DRV_SUPPORT_RC4
1 // RC4 encryption and decryption
#define DRV_SUPPORT_SIGN 1 // Self sign signatures -> AiCrypto Library
#define DRV_SUPPORT_TIFF 1 // about 310 KB
To disable a specific feature set the constant to zero or comment it out. Note that the TIFF
library uses also the JPEG library. Because of this, disabling the JPEG library only does not
reduce the library size.
The following constants are used by WriteFText() (defined in dynapdf.h).
#define PDF_MAX_LIST_COUNT 6
// Maximum count of nested list levels
#define PDF_LIST_SEP_WIDTH 10.0 // Default list separator with
#define DEFAULT_LIST_CHAR
159
// Default list character
#define PDF_LIST_FONT "Wingdings-Regular" // Default list font
The list font must be the PostScript name of the font (see SetFont() for further information).
When changing the list font you may also change the default list character. When using
DynaPDF under Linux or UNIX you may define a font that is available in one of your font
search directories.
Note that the list font can be overridden at runtime with the function SetListFont(). So, it is
usually better to load the font at runtime with SetListFont() since you can properly handle cases
in which the font cannot be found.
Main object types
In PDF, two basic object types can be created, resource objects such as fonts, images and so on
which are used by content streams and global objects such as annotations, bookmarks, form
fields and so on. Global objects can use resource objects but not vice versa.
 

Previous topic: Customized Exception handling

Next topic: General design requirements