Пример #1
0
 internal void SetContainingLegend(Legend legend, LegendItem legendItem)
 {
     this.legend     = legend;
     this.legendItem = legendItem;
     if (this.legend != null)
     {
         margins.Common = this.legend.Common;
     }
 }
        public void Insert(int index, string image, string text)
        {
            LegendItem legendItem = new LegendItem(text, Color.Empty, image);

            legendItem.Legend = legend;
            if (common != null)
            {
                legendItem.common = common;
            }
            Insert(index, legendItem);
            Invalidate(invalidateLegendOnly: false);
        }
        public int Add(string image, string text)
        {
            LegendItem legendItem = new LegendItem(text, Color.Empty, image);

            legendItem.Legend = legend;
            if (common != null)
            {
                legendItem.common = common;
            }
            Invalidate(invalidateLegendOnly: false);
            return(Add(legendItem));
        }
        public int Add(Color color, string text)
        {
            LegendItem legendItem = new LegendItem(text, color, "");

            legendItem.Legend = legend;
            if (common != null)
            {
                legendItem.common = common;
            }
            Invalidate(invalidateLegendOnly: false);
            return(Add(legendItem));
        }
 internal LegendCellCollection(LegendItem legendItem)
 {
     this.legendItem = legendItem;
 }
 public void Insert(int index, LegendItem value)
 {
     Insert(index, (object)value);
 }
 public void Remove(LegendItem value)
 {
     array.Remove(value);
     Invalidate(invalidateLegendOnly: false);
 }
 public int IndexOf(LegendItem value)
 {
     return(array.IndexOf(value));
 }
 public bool Contains(LegendItem value)
 {
     return(array.Contains(value));
 }