Previous Document Next Document
ShapeRange.ApplyFountainFill

Sub ApplyFountainFill([StartColor As Color], [EndColor As Color], [Type As cdrFountainFillType = cdrLinearFountainFill], [Angle As Double], [Steps As Long], [EdgePad As Long], [MidPoint As Long = 50], [BlendType As cdrFountainFillBlendType = cdrDirectFountainFillBlend], [CenterOffsetX As Double], [CenterOffsetY As Double])

Member of ShapeRange

The ApplyFountainFill method applies the specified fountain fill to all objects in the range.

Parameters
Description
StartColor
Specifes the color that appears at the beginning of a fountain fill
This parameter is optional, and its default value is Nothing.
EndColor
Specifies the color that appears at the end of a fountain fill
This parameter is optional, and its default value is Nothing.
Type
Specifies the type of fountain fill. The Type parameter returns cdrFountainFillType.
This parameter is optional, and its default value is cdrLinearFountainFill (1).
Angle
Specifies the degree of the angle in a linear, conical, or square fountain fill. Changing the angle of gradation affects the slant of the fountain fill. Positive values rotate the fill counterclockwise; negative values rotate it clockwise.
This parameter is optional, and its default value is 0.
Steps
Specifies the number of bands (steps) used to display a fountain fill
This parameter is optional, and its default value is 0.
EdgePad
Specifies the length of solid colors at the beginning and end of the fountain fill before they start blending with the next color in the fountain fill. You can change the edge pad of linear, radial, and square fountain fills. Higher values let the colors remain solid longer before blending, causing the colors to spread more quickly. Lower values result in a smooth transformation between the two colors.
This parameter is optional, and its default value is 0.
MidPoint
Represents an imaginary line between two colors in a fountain fill. By changing this value, you can set the point at which two colors in a fountain fill converge.
This parameter is optional, and its default value is 50.
BlendType
Specifies the type of blend for the fountain fill
This parameter is optional, and its default value is cdrDirectFountainFillBlend (0).
CenterOffsetX
This parameter is optional, and its default value is 0.
CenterOffsetY
This parameter is optional, and its default value is 0.

The following code example applies a conical fountain fill to each text shape on the page:

Sub Test() 
 Dim sr As ShapeRange 
 Set sr = ActivePage.FindShapes(Type:=cdrTextShape) 
 sr.ApplyFountainFill CreateRGBColor(255, 0, 0), 
CreateRGBColor(255, 255, 0), cdrConicalFountainFill, 45 
End Sub 

Previous Document Next Document Back to Top

Copyright 2007 Corel Corporation. All rights reserved.