Components All New MacOS Windows Linux iOS
Examples Mac & Win Server Client Guides Statistic FMM Blog Deprecated Old


Creates an ICC-based color space.

Component Version macOS Windows Linux Server iOS SDK
DynaPDF 13.0 ✅ Yes ✅ Yes ✅ Yes ✅ Yes ✅ Yes
MBS( "DynaPDF.CreateICCBasedColorSpace"; PDF; FilePath )   More


Parameter Description Example
PDF The PDF reference returned from DynaPDF.New. $pdf
FilePath The native file path for the ICC profile file. "/Users/cs/Desktop/profile.icc"


Returns number or error.


Creates an ICC-based color space.
ICC-based color spaces (PDF 1.3) are based on a cross-platform color profile as defined by the International Color Consortium (ICC). Unlike the CalGray, CalRGB, and Lab color spaces, which are characterized by entries in the color space dictionary, an ICC-based color space is characterized by a sequence of bytes in a standard format.
An ICC profile describes the color characteristics of a particular device and it provides necessary information to convert color data between native device color spaces and device independent color spaces. The ICC specification classifies color devices according to their use as input or output devices such as monitors, scanners, cameras or printers. Depending on the output PDF format different device classes are supported.
If the function succeeds the return value is the color space handle.

See also CreateICCBasedColorSpace function in DynaPDF manual.


Creates an ICC Profile:

Set Variable [ $cs ; Value: MBS("DynaPDF.CreateICCBasedColorSpace"; $pdf; "/Users/cs/Desktop/CMYK.icc") ]
Set Variable [ $r ; Value: MBS( "DynaPDF.SetExtColorSpace"; $PDF; $cs ) ]
Set Variable [ $r ; Value: MBS("DynaPDF.SetFillColor"; $pdf; 1; 0; 0) ]
Set Variable [ $r ; Value: MBS("DynaPDF.WriteText"; $pdf; 100; 100; "Some cyan text") ]

See also

Release notes

Blog Entries

This function checks for a license.

Created 1st December 2022, last changed 1st December 2022

DynaPDF.CreateGroupField - DynaPDF.CreateICCBasedColorSpaceContainer

💬 Ask a question or report a problem