Interface IColorSpaceContext
Methods for manipulating and retrieving the current color state for a PDF content stream.
public interface IColorSpaceContext : IDeepCloneable<IColorSpaceContext>
- Inherited Members
Properties
CurrentNonStrokingColorSpace
The ColorSpaceDetails used for non-stroking operations.
ColorSpaceDetails CurrentNonStrokingColorSpace { get; }
Property Value
CurrentStrokingColorSpace
The ColorSpaceDetails used for stroking operations.
ColorSpaceDetails CurrentStrokingColorSpace { get; }
Property Value
Methods
SetNonStrokingColor(IReadOnlyList<decimal>, NameToken)
Set the color to use for nonstroking operations using the current color space.
void SetNonStrokingColor(IReadOnlyList<decimal> operands, NameToken patternName = null)
Parameters
operands
IReadOnlyList<decimal>patternName
NameToken
SetNonStrokingColorCmyk(decimal, decimal, decimal, decimal)
Set the nonstroking color space to DeviceCMYK and set the color to use for nonstroking operations.
void SetNonStrokingColorCmyk(decimal c, decimal m, decimal y, decimal k)
Parameters
c
decimalCyan - A number between 0 (minimum concentration) and 1 (maximum concentration).
m
decimalMagenta - A number between 0 (minimum concentration) and 1 (maximum concentration).
y
decimalYellow - A number between 0 (minimum concentration) and 1 (maximum concentration).
k
decimalBlack - A number between 0 (minimum concentration) and 1 (maximum concentration).
SetNonStrokingColorGray(decimal)
Set the nonstroking color space to DeviceGray and set the gray level to use for nonstroking operations.
void SetNonStrokingColorGray(decimal gray)
Parameters
gray
decimalA number between 0.0 (black) and 1.0 (white).
SetNonStrokingColorRgb(decimal, decimal, decimal)
Set the nonstroking color space to DeviceRGB and set the color to use for nonstroking operations.
void SetNonStrokingColorRgb(decimal r, decimal g, decimal b)
Parameters
r
decimalRed - A number between 0 (minimum intensity) and 1 (maximum intensity).
g
decimalGreen - A number between 0 (minimum intensity) and 1 (maximum intensity).
b
decimalBlue - A number between 0 (minimum intensity) and 1 (maximum intensity).
SetNonStrokingColorspace(NameToken, DictionaryToken)
Set the current color space to use for nonstroking operations and initialize the nonstroking color.
void SetNonStrokingColorspace(NameToken colorspace, DictionaryToken dictionary = null)
Parameters
colorspace
NameTokenThe color space name.
dictionary
DictionaryTokenThe color space dictionary. Default value is null.
SetStrokingColor(IReadOnlyList<decimal>, NameToken)
Set the color to use for stroking operations using the current color space.
void SetStrokingColor(IReadOnlyList<decimal> operands, NameToken patternName = null)
Parameters
operands
IReadOnlyList<decimal>patternName
NameToken
SetStrokingColorCmyk(decimal, decimal, decimal, decimal)
Set the stroking color space to DeviceCMYK and set the color to use for stroking operations.
void SetStrokingColorCmyk(decimal c, decimal m, decimal y, decimal k)
Parameters
c
decimalCyan - A number between 0 (minimum concentration) and 1 (maximum concentration).
m
decimalMagenta - A number between 0 (minimum concentration) and 1 (maximum concentration).
y
decimalYellow - A number between 0 (minimum concentration) and 1 (maximum concentration).
k
decimalBlack - A number between 0 (minimum concentration) and 1 (maximum concentration).
SetStrokingColorGray(decimal)
Set the stroking color space to DeviceGray and set the gray level to use for stroking operations.
void SetStrokingColorGray(decimal gray)
Parameters
gray
decimalA number between 0.0 (black) and 1.0 (white).
SetStrokingColorRgb(decimal, decimal, decimal)
Set the stroking color space to DeviceRGB and set the color to use for stroking operations.
void SetStrokingColorRgb(decimal r, decimal g, decimal b)
Parameters
r
decimalRed - A number between 0 (minimum intensity) and 1 (maximum intensity).
g
decimalGreen - A number between 0 (minimum intensity) and 1 (maximum intensity).
b
decimalBlue - A number between 0 (minimum intensity) and 1 (maximum intensity).
SetStrokingColorspace(NameToken, DictionaryToken)
Set the current color space to use for stroking operations and initialize the stroking color.
void SetStrokingColorspace(NameToken colorspace, DictionaryToken dictionary = null)
Parameters
colorspace
NameTokenThe color space name.
dictionary
DictionaryTokenThe color space dictionary. Default value is null.