Struct D2D1GradientStop
Contains the position and color of a gradient stop.
Implements
Inherited Members
Namespace: JeremyAnsel.DirectX.D2D1
Assembly: JeremyAnsel.DirectX.D2D1.dll
Syntax
public struct D2D1GradientStop : IEquatable<D2D1GradientStop>
Constructors
| Edit this page View SourceD2D1GradientStop(float, D2D1ColorF)
Initializes a new instance of the D2D1GradientStop struct.
Declaration
public D2D1GradientStop(float position, D2D1ColorF color)
Parameters
Type | Name | Description |
---|---|---|
float | position | A value that indicates the relative position of the gradient stop in the brush. This value must be in the [0.0f, 1.0f] range if the gradient stop is to be seen explicitly. |
D2D1ColorF | color | The color of the gradient stop. |
Properties
| Edit this page View SourceColor
Gets or sets the color of the gradient stop.
Declaration
public D2D1ColorF Color { get; set; }
Property Value
Type | Description |
---|---|
D2D1ColorF |
Position
Gets or sets a value that indicates the relative position of the gradient stop in the brush. This value must be in the [0.0f, 1.0f] range if the gradient stop is to be seen explicitly.
Declaration
public float Position { get; set; }
Property Value
Type | Description |
---|---|
float |
Methods
| Edit this page View SourceEquals(D2D1GradientStop)
Determines whether the specified object is equal to the current object.
Declaration
public bool Equals(D2D1GradientStop other)
Parameters
Type | Name | Description |
---|---|---|
D2D1GradientStop | other | The object to compare with the current object. |
Returns
Type | Description |
---|---|
bool |
Equals(object)
Determines whether the specified object is equal to the current object.
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
object | obj | The object to compare with the current object. |
Returns
Type | Description |
---|---|
bool |
Overrides
| Edit this page View SourceGetHashCode()
Returns the hash code for this instance.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
int | A 32-bit signed integer that is the hash code for this instance. |
Overrides
Operators
| Edit this page View Sourceoperator ==(D2D1GradientStop, D2D1GradientStop)
Compares two D2D1GradientStop objects. The result specifies whether the values of the two objects are equal.
Declaration
public static bool operator ==(D2D1GradientStop left, D2D1GradientStop right)
Parameters
Type | Name | Description |
---|---|---|
D2D1GradientStop | left | The left D2D1GradientStop to compare. |
D2D1GradientStop | right | The right D2D1GradientStop to compare. |
Returns
Type | Description |
---|---|
bool |
operator !=(D2D1GradientStop, D2D1GradientStop)
Compares two D2D1GradientStop objects. The result specifies whether the values of the two objects are unequal.
Declaration
public static bool operator !=(D2D1GradientStop left, D2D1GradientStop right)
Parameters
Type | Name | Description |
---|---|---|
D2D1GradientStop | left | The left D2D1GradientStop to compare. |
D2D1GradientStop | right | The right D2D1GradientStop to compare. |
Returns
Type | Description |
---|---|
bool |