/// <summary>
 /// Removes specified object from the collection.
 /// </summary>
 /// <param name="value"></param>
 public void Remove(ColorStop value)
 {
     List.Remove(value);
 }
 /// <summary>
 /// Returns index of the object inside of the collection.
 /// </summary>
 /// <param name="value">Reference to the object.</param>
 /// <returns>Index of the object.</returns>
 public int IndexOf(ColorStop value)
 {
     return List.IndexOf(value);
 }
 /// <summary>
 /// Returns whether collection contains specified object.
 /// </summary>
 /// <param name="value">Object to look for.</param>
 /// <returns>true if object is part of the collection, otherwise false.</returns>
 public bool Contains(ColorStop value)
 {
     return List.Contains(value);
 }
 /// <summary>
 /// Adds array of new objects to the collection.
 /// </summary>
 /// <param name="items">Array of object to add.</param>
 public void AddRange(ColorStop[] items)
 {
     foreach (ColorStop item in items)
         this.Add(item);
 }
 /// <summary>
 /// Inserts new object into the collection.
 /// </summary>
 /// <param name="index">Position of the object.</param>
 /// <param name="value">Object to insert.</param>
 public void Insert(int index, ColorStop value)
 {
     List.Insert(index, value);
 }
 /// <summary>
 /// Adds new object to the collection.
 /// </summary>
 /// <param name="item">Object to add.</param>
 /// <returns>Index of newly added object.</returns>
 public int Add(ColorStop item)
 {
     return List.Add(item);
 }
 /// <summary>
 /// Copies contained items to the ColorStop array.
 /// </summary>
 /// <param name="array">Array to copy to.</param>
 internal void CopyTo(ColorStop[] array)
 {
     List.CopyTo(array, 0);
 }
        //protected override void OnRemoveComplete(int index,object value)
        //{
        //    base.OnRemoveComplete(index,value);
        //    ColorStop me=value as ColorStop;
        //}
        //protected override void OnInsertComplete(int index,object value)
        //{
        //    base.OnInsertComplete(index,value);
        //    ColorStop me=value as ColorStop;
        //}

        /// <summary>
        /// Copies collection into the specified array.
        /// </summary>
        /// <param name="array">Array to copy collection to.</param>
        /// <param name="index">Starting index.</param>
        public void CopyTo(ColorStop[] array, int index)
        {
            List.CopyTo(array, index);
        }
示例#9
0
 /// <summary>
 /// Initializes a new instance of the GradientFill class.
 /// </summary>
 /// <param name="interpolationColors"></param>
 public GradientFill(ColorStop[] interpolationColors, int angle)
 {
     _InterpolationColors.AddRange(interpolationColors);
     _Angle = angle;
 }
示例#10
0
 /// <summary>
 /// Initializes a new instance of the GradientFill class.
 /// </summary>
 /// <param name="interpolationColors"></param>
 public GradientFill(ColorStop[] interpolationColors)
 {
     _InterpolationColors.AddRange(interpolationColors);
 }