Table of Contents

Class PdfSeparationColor

Namespace
Syncfusion.Pdf.ColorSpace
Assembly
Syncfusion.Pdf.Portable.dll

Represents a separation color, based on a separation colorspace.

public class PdfSeparationColor : PdfExtendedColor
Inheritance
PdfSeparationColor
Inherited Members

Examples

// Creates a new document
PdfDocument doc = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = doc.Pages.Add();
// Creates ExponentialInterpolationFunction function
PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true);
float[] numArray = new float[4];
numArray[0] = 0.38f;
numArray[1] = 0.88f;
function.C1 = numArray;
// Creates SeparationColorSpace
PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace();
colorspace.TintTransform = function;
colorspace.Colorant = "PANTONE Orange 021 C";
PdfSeparationColor color = new PdfSeparationColor(colorspace);
color.Tint = 0.7;
RectangleF rect = new RectangleF(20, 70, 200, 100);
PdfPen pen = new PdfPen(color);
page.Graphics.DrawRectangle(pen, rect);    
doc.Save("SeparationColor.pdf");
' Creates a new document
Dim doc As PdfDocument = New PdfDocument()
' Create a page
Dim page As PdfPage = doc.Pages.Add()
' Creates ExponentialInterpolationFunction function
Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True)
Dim numArray() As Single = New Single(3){}
numArray(0) = 0.38f
numArray(1) = 0.88f
[function].C1 = numArray
' Creates SeparationColorSpace
Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace()
colorspace.TintTransform = [function]
colorspace.Colorant = "PANTONE Orange 021 C"
Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace)
color.Tint = 0.7
Dim rect As RectangleF = New RectangleF(20, 70, 200, 100)
Dim pen As PdfPen = New PdfPen(color)
page.Graphics.DrawRectangle(pen, rect)
doc.Save("SeparationColor.pdf")

Constructors

PdfSeparationColor(PdfColorSpaces)

Initializes a new instance of the PdfSeparationColor class.

public PdfSeparationColor(PdfColorSpaces colorspace)

Parameters

colorspace PdfColorSpaces

The colorspace.

Examples

// Creates a new document
PdfDocument doc = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = doc.Pages.Add();
// Creates ExponentialInterpolationFunction function
PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true);
float[] numArray = new float[4];
numArray[0] = 0.38f;
numArray[1] = 0.88f;
function.C1 = numArray;
// Creates SeparationColorSpace
PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace();
colorspace.TintTransform = function;
colorspace.Colorant = "PANTONE Orange 021 C";
PdfSeparationColor color = new PdfSeparationColor(colorspace);
color.Tint = 0.7;
RectangleF rect = new RectangleF(20, 70, 200, 100);
PdfPen pen = new PdfPen(color);
page.Graphics.DrawRectangle(pen, rect);    
doc.Save("SeparationColor.pdf");
' Creates a new document
Dim doc As PdfDocument = New PdfDocument()
' Create a page
Dim page As PdfPage = doc.Pages.Add()
' Creates ExponentialInterpolationFunction function
Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True)
Dim numArray() As Single = New Single(3){}
numArray(0) = 0.38f
numArray(1) = 0.88f
[function].C1 = numArray
' Creates SeparationColorSpace
Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace()
colorspace.TintTransform = [function]
colorspace.Colorant = "PANTONE Orange 021 C"
Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace)
color.Tint = 0.7
Dim rect As RectangleF = New RectangleF(20, 70, 200, 100)
Dim pen As PdfPen = New PdfPen(color)
page.Graphics.DrawRectangle(pen, rect)
doc.Save("SeparationColor.pdf")
See Also

Properties

Tint

Gets or sets the Tint Value.

public double Tint { get; set; }

Property Value

double

A float value specifying the tint of this color.

Examples

// Creates a new document
PdfDocument doc = new PdfDocument();
//Creates a new page and adds it as the last page of the document
PdfPage page = doc.Pages.Add();
// Creates ExponentialInterpolationFunction function
PdfExponentialInterpolationFunction function = new PdfExponentialInterpolationFunction(true);
float[] numArray = new float[4];
numArray[0] = 0.38f;
numArray[1] = 0.88f;
function.C1 = numArray;
// Creates SeparationColorSpace
PdfSeparationColorSpace colorspace = new PdfSeparationColorSpace();
colorspace.TintTransform = function;
colorspace.Colorant = "PANTONE Orange 021 C";
PdfSeparationColor color = new PdfSeparationColor(colorspace);
color.Tint = 0.7;
RectangleF rect = new RectangleF(20, 70, 200, 100);
PdfPen pen = new PdfPen(color);
page.Graphics.DrawRectangle(pen, rect);    
doc.Save("SeparationColor.pdf");
' Creates a new document
Dim doc As PdfDocument = New PdfDocument()
' Create a page
Dim page As PdfPage = doc.Pages.Add()
' Creates ExponentialInterpolationFunction function
Dim [function] As PdfExponentialInterpolationFunction = New PdfExponentialInterpolationFunction(True)
Dim numArray() As Single = New Single(3){}
numArray(0) = 0.38f
numArray(1) = 0.88f
[function].C1 = numArray
' Creates SeparationColorSpace
Dim colorspace As PdfSeparationColorSpace = New PdfSeparationColorSpace()
colorspace.TintTransform = [function]
colorspace.Colorant = "PANTONE Orange 021 C"
Dim color As PdfSeparationColor = New PdfSeparationColor(colorspace)
color.Tint = 0.7
Dim rect As RectangleF = New RectangleF(20, 70, 200, 100)
Dim pen As PdfPen = New PdfPen(color)
page.Graphics.DrawRectangle(pen, rect)
doc.Save("SeparationColor.pdf")

Remarks

The acceptable range for this value is [0.0 1.0]. 0.0 means the lightest color that can be achieved, and 1.0 means the darkest color.

See Also

See Also