public Histogram() { InitializeComponent(); System.Windows.Forms.Application.EnableVisualStyles(); // Create a Windows Forms checkbox control and assign // it as the WindowsFormsHost element's child. var measSys = new MeasurementSystem(); measSys.SetPreambula(SiPreambuledUnitType.Hz, SiPreambula.Giga); _integralPlotControl = new IntegralGraphControl(); _integralPlotControl.Data = MakeData(); var graphPlotControl = (GraphPlotControl)_integralPlotControl.Graphs[0]; graphPlotControl.BorderStyle = BorderStyle.None; graphPlotControl.MeasurementSystem = measSys; graphPlotControl.Plot.CoordinateSystem.SweepValueQuantityType = PhysicalQuantityType.Frequencies; graphPlotControl.GraphTitle = "Histogram"; var ftMeas = new FtMeasurement { Foundry = 0, Process = 0, Wafer = "C2", ElementType = "Transistor", ElementSubTypes = new List<string> { "T240" }, }; var megaMeas = new MegaMeasurement(); megaMeas.Add(ftMeas); graphPlotControl.Tag = megaMeas; graphicsHost.Child = _integralPlotControl; // Cause the OnFlowDirectionChange delegate to be called. graphicsHost.FlowDirection = System.Windows.FlowDirection.LeftToRight; // Cause the OnClipChange delegate to be called. graphicsHost.Clip = new RectangleGeometry(); }
public Page2() { InitializeComponent(); System.Windows.Forms.Application.EnableVisualStyles(); // Create a Windows Forms checkbox control and assign // it as the WindowsFormsHost element's child. var measSys = new MeasurementSystem(); measSys.SetPreambula(SiPreambuledUnitType.Hz, SiPreambula.Giga); _integralPlotControl = new IntegralGraphControl(); _integralPlotControl.Data = MakeData(); var graphPlotControl = (GraphPlotControl)_integralPlotControl.Graphs[0]; graphPlotControl.Plot.CoordinateSystem = new WaferDiagram(); graphPlotControl.Plot.Legend.Visible = false; graphPlotControl.BorderStyle = BorderStyle.None; graphPlotControl.MeasurementSystem = measSys; graphPlotControl.Plot.CoordinateSystem.SweepValueQuantityType = PhysicalQuantityType.Frequencies; graphPlotControl.GraphTitle = "Wafer"; var sMeas = new SMeasurement { Foundry = 0, Process = 0, Wafer = "C2", ElementType = "Transistor", ElementSubTypes = new List<string> {"T240"}, Frequency = 10000000000, TransformMode = ComplexToComplexTransformMode.Magnitude, IsDB = true }; var ftMeas = new FtMeasurement { Foundry = 0, Process = 0, Wafer = "C2", ElementType = "Transistor", ElementSubTypes = new List<string> { "T240" }, }; var megaMeas = new MegaMeasurement(); megaMeas.Add(ftMeas); megaMeas.Add(sMeas); graphPlotControl.Tag = megaMeas; graphicsHost.Child = _integralPlotControl; // Cause the OnFlowDirectionChange delegate to be called. graphicsHost.FlowDirection = System.Windows.FlowDirection.LeftToRight; // Cause the OnClipChange delegate to be called. graphicsHost.Clip = new RectangleGeometry(); _filterPage = new GraphicFilterPage(); var wafer = graphPlotControl.Plot.CoordinateSystem as WaferDiagram; var data = new GraphicFilterPage.Data { GraphPlot = graphPlotControl, FilterCriteria = wafer.FilterCriteria }; _filterPage.MeasurementSystem = graphPlotControl.MeasurementSystem; _filterPage.SetData(data); // Передаем данные в диалог настроек. filterPageHost.Child = _filterPage; UpdateRadioButtons(); }