Class FillFormat (PowerPoint VBA)

The class FillFormat represents fill formatting for a shape. A shape can have a solid, gradient, texture, pattern, picture, or semi-transparent fill.

The classes ChartFormat, Shape and TableBackground. give access to class FillFormat

To use a FillFormat class variable it first needs to be instantiated, for example

Dim fft as FillFormat
Set fft = ActiveWindow.RangeFromPoint.Fill

The following procedures can be used to set variables of type FillFormat: ChartFormat.Fill, Shape.Fill, ShapeRange.Fill and TableBackground.Fill.

Methods

Background - Specifies that the shape's fill should match the slide background. If you change the slide background after applying this method to a fill, the fill will also change.

OneColorGradient - Sets the specified fill to a one-color gradient.

Patterned - Sets the specified fill to a pattern.

PresetGradient - Sets the specified fill to a preset gradient.

PresetTextured - Sets the specified fill to a preset texture.

Solid - Sets the specified fill to a uniform color. Use this method to convert a gradient, textured, patterned, or background fill back to a solid fill.

TwoColorGradient - Sets the specified fill to a two-color gradient.

UserPicture - Fills the specified shape with one large image.

UserTextured - Fills the specified shape with small tiles of an image.

Properties

BackColor returns or sets a ColorFormat object that represents the background color for the specified fill or patterned line.

ForeColor returns or sets a ColorFormat object that represents the foreground color for the fill, line, or shadow.

GradientAngle returns or sets the angle of the gradient fill for the specified fill format.

GradientColorType returns the gradient color type for the specified fill.

GradientDegree returns a value that indicates how dark or light a one-color gradient fill is.

GradientStops returns the GradientStops collection associated with the specified fill format.

GradientStyle returns the gradient style for the specified fill.

GradientVariant returns the gradient variant for the specified fill as an integer value from 1 to 4 for most gradient fills.

Pattern sets or returns a value that represents the pattern applied to the specified fill.

PictureEffects returns an object that represents the picture or texture fill for the specified fill format.

PresetGradientType returns the preset gradient type for the specified fill.

PresetTexture returns the preset texture for the specified fill.

RotateWithObject returns or sets whether the fill rotates with the specified shape.

TextureAlignment returns or sets the alignment (the origin of the coordinate grid) for the tiling of the texture fill.

TextureHorizontalScale returns or sets the horizontal scaling factor for the texture fill.

TextureName returns the name of the custom texture file for the specified fill.

TextureOffsetX returns or sets the horizontal offset of the texture from the origin in points.

TextureOffsetY returns or sets the vertical offset of the texture from the origin in points.

TextureTile returns or sets whether the texture fill is tiled or centered.

TextureType returns the texture type for the specified fill.

TextureVerticalScale returns or sets the vertical scaling factor for the texture fill.

Transparency returns or sets the degree of transparency of the specified fill, shadow, or line as a value between 0.0 (opaque) and 1.0 (clear).

Type represent the type of fill.

Visible returns or sets the visibility of the specified object or the formatting applied to the specified object.

ColorFormat - Represents the color of a one-color object, the foreground or background color of an object with a gradient or patterned fill, or the pointer color. You can set colors to an explicit red-green-blue value (by using the RGB property) or to a color in the color scheme (by using the SchemeColor property).