IXRRadialGradientBrush (Compact 2013)

3/28/2014

This class represents a brush that paints an area with a radial gradient. A focal point defines the beginning of the gradient, and an ellipse defines the endpoints of the gradient.

Syntax

class IXRRadialGradientBrush : public IXRGradientBrush

Inheritance Hierarchy

IXRDependencyObject

    IXRBrush

        IXRGradientBrush

            IXRRadialGradientBrush

Methods

Method

Description

IXRRadialGradientBrush::GetCenter

Retrieves the center of the outer ellipse of this radial gradient.

IXRRadialGradientBrush::GetGradientOrigin

Retrieves the location of the focal point where the radial gradient begins.

IXRRadialGradientBrush::GetRadiusX

Retrieves the horizontal radius of the outer ellipse of this radial gradient.

IXRRadialGradientBrush::GetRadiusY

Retrieves the vertical radius of the outer ellipse of this radial gradient.

IXRRadialGradientBrush::SetCenter

Sets the center of the outer ellipse of this radial gradient.

IXRRadialGradientBrush::SetGradientOrigin

Sets the location of the focal point where the radial gradient begins.

IXRRadialGradientBrush::SetRadiusX

Sets the horizontal radius of the outer ellipse of this radial gradient.

IXRRadialGradientBrush::SetRadiusY

Sets the vertical radius of the outer ellipse of this radial gradient.

Thread Safety

Members of this class are thread-safe if you previously called IXRApplication::CreateHostFromXaml and supplied it with an XRWindowCreateParams structure that has AllowsMultipleThreadAccess set to true.

Remarks

The IXRRadialGradientBrush object resembles the IXRLinearGradientBrush object. However, the linear gradient has a starting point and an endpoint that define the gradient vector, whereas the radial gradient has a focal point that defines the starting point and an ellipse that defines the endpoints. In other words, a gradient stop at 1 defines the color at the ellipse circumference. A gradient stop at 0 defines the color at the focal point.

When you set identical RadiusX and RadiusY values, the shape of the outer ellipse of this radial gradient is a circle.

When you create a class instance, use an IXRRadialGradientBrushPtr smart pointer instead of a raw interface pointer. For more information, see XRPtr<Interface>.

You can also define a radial gradient brush in Microsoft Silverlight 3 XAML. For information about the differences between XAML in XAML for Windows Embedded and Silverlight 3, see Differences Between Microsoft Silverlight 3 and XAML for Windows Embedded. For more information about how to define this element in the source XAML for your application, see the RadialGradientBrush Class on MSDN.

.NET Framework Equivalent

System.Windows.Media.RadialGradientBrush

Requirements

Header

XamlRuntime.h

sysgen

SYSGEN_XAML_RUNTIME

See Also

Reference

Classes for Visual Appearance