public CurveItem AddChromatogram(PaneKey paneKey, ChromGraphItem chromGraphItem) { var chromDisplayState = (ChromDisplayState)_displayState; chromDisplayState.ChromGraphItems.Add(new KeyValuePair <PaneKey, ChromGraphItem>(paneKey, chromGraphItem)); return(GraphControl.AddGraphItem(chromDisplayState.GetOrCreateGraphPane(GraphControl, paneKey), chromGraphItem, false)); }
public CurveItem AddSpectrum(AbstractSpectrumGraphItem item) { var pane = _displayState.GetOrCreateGraphPane(GraphControl, PaneKey.DEFAULT); pane.Title.Text = item.Title; var curveItem = GraphControl.AddGraphItem(pane, item); curveItem.Label.IsVisible = false; pane.Legend.IsVisible = false; GraphControl.Refresh(); return(curveItem); }
public IEnumerable <CurveItem> SetErrorGraphItems(IEnumerable <IMSGraphItemInfo> errorItems) { var curveItems = new List <CurveItem>(); SetDisplayState(new ErrorDisplayState()); var pane = _displayState.GetOrCreateGraphPane(GraphControl, PaneKey.DEFAULT); pane.Legend.IsVisible = false; foreach (var msGraphItem in errorItems) { var curveItem = GraphControl.AddGraphItem(pane, msGraphItem); curveItem.Label.IsVisible = false; curveItems.Add(curveItem); pane.Title.Text = msGraphItem.Title; } GraphControl.AxisChange(); GraphControl.Invalidate(); return(curveItems); }