DynaPDF Manual - Page 368

Previous Page 367   Index   Next Page 369

Function Reference
Page 368 of 821
The function returns the most important properties of an external CMap file. The search path of
external CMaps can be set with SetCMapDir(). The function returns the number of available CMap
files which can be accessed with GetCMap(). It is also possible to use the function GetCMapCount()
to determine the number of available CMap files.
The member StructSize of the structure TPDFCMap must be initialized with sizeof(TPDFCMap)
before calling the function (C/C++, Delphi only). The structure size is used to identify different
versions of the structure if extensions will be made in later releases.
The parameter Index represents an array index into the CMap cache. It can be in the range
0..NumCMaps -1.
The member CMapName of the structure TPDFCMap should be used to load a CMap into memory
with LoadCMap(). Note that the function LoadCMap() returns a CMap handle that cannot be used
with this function.
Values which are taken from the DSC comment section contain the prefix DSC. DSC comments are
optional and maybe not available when using CMap files from other vendors than Adobe.
Adobe provides for all character collections identity mappings; the member DSCResName is set to
Identity in this case so that such CMaps can be easily identified.
Return values:
If the function succeeds the return value is 1. If the function fails the return value is 0.
GetCMapCount
Syntax:
SI32 pdfGetCMapCount(
const PPDF* IPDF) // Instance pointer
The function returns the number of available CMap files. This value can be used to access the header
information of CMap files with GetCMap().
GetColorSpace
Syntax:
SI32 pdfGetColorSpace(
const PPDF* IPDF) // Instance pointer
typedef enum
{
esDeviceRGB
= 0,
// Device color space
esDeviceCMYK = 1,
// Device color space
esDeviceGray = 2,
// Device color space
esCalGray
= 3,
// CIE-based color space
esCalRGB
= 4,
// CIE-based color space
esLab
= 5,
// CIE-based color space
esICCBased
= 6,
// ICC-based color space -> contains an ICC profile
esPattern
= 7,
// Special color space
esIndexed
= 8,
// Special color space
esSeparation = 9,
// Special color space
 

Previous topic: GetCheckBoxCharEx, GetCheckBoxDefState, GetCMap

Next topic: GetColorSpaceCount, GetColorSpaceObj