THotPDF.RegisterMultiStopAxialGradient Method

Registers a reusable native PDF axial shading that interpolates two or more color stops along the axis from (X0, Y0) to (X1, Y1)

Declaration

function RegisterMultiStopAxialGradient(X0, Y0, X1, Y1: Single; const StopPositions: array of Single; const StopColors: array of Single; ComponentsPerStop: Integer): AnsiString;

Unit

HPDFDoc

Parameters

NamePurpose
X0, Y0Finite coordinates at color-line offset zero
X1, Y1Finite coordinates at color-line offset one
StopPositionsTwo or more nondecreasing finite offsets in [0, 1]; equal neighbors form a hard color stop
StopColorsFlat-packed finite color components in [0, 1], with one complete color per stop
ComponentsPerStop1 for DeviceGray, 3 for DeviceRGB or 4 for DeviceCMYK

Return value

Returns the generated Pattern resource name for THPDFPage.SetFillPattern or THPDFPage.SetStrokePattern

Usage notes

Related APIs