CompositionRadialGradientBrush.EllipseCenter Property

Definition

Gets or sets the two-dimensional coordinates of the center of the ellipse that contains the gradient.

public:
 property float2 EllipseCenter { float2 get(); void set(float2 value); };
float2 EllipseCenter();

void EllipseCenter(float2 value);
public Vector2 EllipseCenter { get; set; }
var vector2 = compositionRadialGradientBrush.ellipseCenter;
compositionRadialGradientBrush.ellipseCenter = vector2;
Public Property EllipseCenter As Vector2

Property Value

Vector2 Vector2

float2

The two-dimensional coordinates of the center of the ellipse the gradient is housed in. The default is a Vector2 with values (0.5, 0.5).

Remarks

This property describes coordinates of the center of the ellipse that the radial gradient is drawn in.

When MappingMode is set to Relative, the coordinates are relative to the object being painted and have values from 0.0 to 1.0. The upper left corner of the object's bounding rectangle has coordinates (0.0, 0.0) and the lower right corner has coordinates (1.0, 1.0).

When MappingMode is set to Absolute, the numbers change to be pixels rather than a ratio, and are relative to the size of the brush.

Applies to