语言

GradientStopCollection.Item[Int32] 属性

定义

获取或设置 GradientStop 指定从零开始的索引处。

public:
 property System::Windows::Media::GradientStop ^ default[int] { System::Windows::Media::GradientStop ^ get(int index); void set(int index, System::Windows::Media::GradientStop ^ value); };
public System.Windows.Media.GradientStop this[int index] { get; set; }
member this.Item(int) : System.Windows.Media.GradientStop with get, set
Default Public Property Item(index As Integer) As GradientStop

参数

index
Int32

要获取或设置的 GradientStop 从零开始的索引。

属性值

位于 GradientStop 指定索引处。

实现

例外

value 是 null。

index 不是 . 中的 GradientStopCollection有效索引。

为 GradientStopCollection 只读。

-或-

具有 GradientStopCollection 固定大小。

注解

与典型的实现不同,如果尝试插入 IList<T>.Item[] (ArgumentException) 引用,则此实现将引发此实现。

适用于