DynaPDF Manual - Page 279
Previous Page 278 Index Next Page 280
Page 279 of 821
The parameter Visibility specifies when the associated objects should become visible. The parameter
OCGs must be an array of valid OCG handles. A viewer application inspects the array of OCGs and
the visibility parameter to determine whether the associated content should be visible or invisible.
Unused OCMDs will not be written to the PDF file.
If the function succeeds the return value is the OCMD handle, a value greater or equal zero. If the
function fails the return value is a negative error code.
const PPDF* IPDF, // Instance pointer
// X-Coordinate of the inner circle
// Y-Coordinate of the inner circle
// Radius of the inner circle
// X-Coordinate of the outer circle
// Y-Coordinate of the outer circle
// Radius of the outer circle
// Shading center
// Start color
// End color
// Extend the inner circle
// Extend the outer circle
Radial shadings define a color blend or gradient that varies between two circles. The shading may
optionally be extended beyond the starting or ending circles by continuing the boundary colors
indefinitely. Shadings of this type are commonly used to depict three-dimensional spheres and
The shading center defines the point from where the first color will blend into the other. A value of 1
determines the exact center between the start and end point of the shading. Smaller values shift the
shading center in direction to the start circle, greater values to the end circle.
Radial shadings can be drawn into a clipping path to restrict painting into this path. If the shading is
drawn outside of a clipping path it is applied to the entire page. Not that extended shadings are
opaque, objects behind the shading become invisible if they are overprinted by the shading.
Shadings are drawn by using the current coordinate system. It is recommended to understand that
shadings have its own dimension like a normal shape. The parameters Extend1 and Extend2 extend
the shading beyond its dimension. If the shading is extended it must normally be drawn into a
clipping path to avoid overprinting of other objects.
Previous topic: CreateOCMD
Next topic: CreateRadioButton