IXRGradientStop (Compact 2013)

3/28/2014

This class describes the location and color of a transition point in a gradient pattern.

Syntax

class IXRGradientStop : public IXRDependencyObject

Inheritance Hierarchy

IXRDependencyObject

    IXRGradientStop

Methods

Method

Description

IXRGradientStop::GetColor

Retrieves the color of this gradient stop.

IXRGradientStop::GetOffset

Retrieves the location of this gradient stop within the gradient vector.

IXRGradientStop::SetColor

Stops the color of this gradient stop.

IXRGradientStop::SetOffset

Sets the location of this gradient stop within the gradient vector.

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

Use this class to describe the colors in an IXRLinearGradientBrush object or an IXRRadialGradientBrush object. Add the IXRGradientStop objects to an IXRGradientStopCollection, which is supplied to the IXRGradientBrush::SetGradientStops inherited method.

The following illustration shows the gradient stops of a linear gradient:

Gradient stops of a linear gradient

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

You can also define a gradient stop 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 GradientStop Class on MSDN.

Notice that this class does not provide an opacity property; to make an IXRGradientStop semi-transparent, call IXRGradientStop::SetColor and pass in a transparent color value.

.NET Framework Equivalent

System.Windows.Media.GradientStop

Requirements

Header

XamlRuntime.h

sysgen

SYSGEN_XAML_RUNTIME

See Also

Reference

Classes for Visual Appearance