public void Add(StockStatSticker sticker)
 {
     _stickers.Add(sticker);
     sticker.Parent = _chart;
     sticker.BringToFront();
     RepositionStickers();
 }
 private void OnStatStickerDoubleClick(StockStatSticker sticker, StockStat stat)
 {
     if (!EditStat(stat))
     {
         return;
     }
     sticker.UpdateStatInfo();
     chartPV.UpdateStatSeriesDefinition(stat);
     CalculateStatAndRefreshChartData(stat);
 }
        public void AddStat(StockStat stat)
        {
            chartPV.AddStatSeries(stat);
            _currentData.Stats.Add(stat);
            StockStatSticker sticker = new StockStatSticker(stat, _currentStatsInfoGenerator);

            sticker.OnStickerDoubleClick += OnStatStickerDoubleClick;
            sticker.OnStickerMouseClick  += OnStatStickerClick;
            _stickerPositioner.Add(sticker);
        }
 private void OnStatStickerClick(StockStatSticker sticker, StockStat stat, MouseEventArgs e)
 {
     if (e.Button == MouseButtons.Middle)
     {
         if (stat.ChartArea != "areaPrices")
         {
             chartPV.RemoveArea(stat.ChartArea);
         }
         RemoveStat(sticker, stat);
         Refresh();
     }
 }
 public void RemoveStat(StockStatSticker sticker, StockStat stat)
 {
     chartPV.RemoveStatSeries(stat);
     _currentData.Stats.Remove(stat);
     _stickerPositioner.Remove(sticker);
 }
 public void Remove(StockStatSticker sticker)
 {
     sticker.Parent = null;
     _stickers.Remove(sticker);
     RepositionStickers();
 }