Share via


IXRBrush (Compact 2013)

3/28/2014

This class defines objects that are used to paint graphical objects. Classes that derive from IXRBrush describe how the area is painted.

Syntax

class IXRBrush : public IXRDependencyObject

Inheritance Hierarchy

IXRDependencyObject

    IXRBrush

        IXRGradientBrush

            IXRLinearGradientBrush

            IXRRadialGradientBrush

        IXRSolidColorBrush

        IXRTileBrush

            IXRImageBrush

Methods

Method

Description

IXRBrush::GetOpacity

Retrieves the degree of opacity of this brush object.

IXRBrush::GetRelativeTransform

Retrieves the transformation that is applied to this brush by using relative coordinates.

IXRBrush::GetTransform

Retrieves the transformation that is applied to this brush object.

IXRBrush::SetOpacity

Sets the degree of opacity of this brush object.

IXRBrush::SetRelativeTransform

Sets the transformation to apply to this brush by using relative coordinates.

IXRBrush::SetTransform

Sets the transformation to apply to this brush object.

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

IXRBrush provides the base class for brushes in XAML for Windows Embedded. Each brush paints an area differently. Brushes can paint an area with a solid color, a gradient, or an image. The following list describes the different kinds of brushes:

  • IXRSolidColorBrush: Paints an area with a solid color.
  • IXRLinearGradientBrush: Paints an area with a linear gradient.
  • IXRRadialGradientBrush: Paints an area with a radial gradient.
  • IXRImageBrush: Paints an area with an image.

You can paint an area on the graphical window by using an IXRSolidColorBrush that uses a predefined solid color. To do this in C++ code, set a color for the IXRSolidColorBrush. For more information, see IXRSolidColorBrush.

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

.NET Framework Equivalent

System.Windows.Media.Brush

Requirements

Header

XamlRuntime.h

sysgen

SYSGEN_XAML_RUNTIME

See Also

Reference

Classes for Visual Appearance