Exemplo n.º 1
0
        public ToggleVisibility()
        {
            this.InitializeComponent();
#if DEBUG
            this.AttachDevTools();
#endif
            int      pointCount = 51;
            double[] dataXs     = DataGen.Consecutive(pointCount);
            double[] dataSin    = DataGen.Sin(pointCount);
            double[] dataCos    = DataGen.Cos(pointCount);

            avaPlot1 = this.Find <AvaPlot>("avaPlot1");

            sinPlot = avaPlot1.Plot.AddScatter(dataXs, dataSin);
            cosPlot = avaPlot1.Plot.AddScatter(dataXs, dataCos);
            vline1  = avaPlot1.Plot.AddVerticalLine(0);
            vline2  = avaPlot1.Plot.AddVerticalLine(50);

            avaPlot1.Refresh();

            this.Find <CheckBox>("sineCheckbox").Checked   += SinShow;
            this.Find <CheckBox>("sineCheckbox").Unchecked += SinHide;

            this.Find <CheckBox>("cosineCheckbox").Checked   += CosShow;
            this.Find <CheckBox>("cosineCheckbox").Unchecked += CosHide;

            this.Find <CheckBox>("linesCheckbox").Checked   += LinesShow;
            this.Find <CheckBox>("linesCheckbox").Unchecked += LinesHide;
        }
Exemplo n.º 2
0
        public MouseTracker()
        {
            this.InitializeComponent();
#if DEBUG
            this.AttachDevTools();
#endif

            avaPlot1 = this.Find <AvaPlot>("avaPlot1");

            avaPlot1.plt.PlotSignal(DataGen.RandomWalk(null, 100));
            vLine = avaPlot1.plt.PlotVLine(0, color: System.Drawing.Color.Red, lineStyle: LineStyle.Dash);
            hLine = avaPlot1.plt.PlotHLine(0, color: System.Drawing.Color.Red, lineStyle: LineStyle.Dash);
            avaPlot1.Render();

            avaPlot1.PointerMoved += OnMouseMove;
        }
Exemplo n.º 3
0
        public MouseTracker()
        {
            this.InitializeComponent();
#if DEBUG
            this.AttachDevTools();
#endif

            avaPlot1 = this.Find <AvaPlot>("avaPlot1");

            avaPlot1.Plot.AddSignal(DataGen.RandomWalk(null, 100));
            vLine = avaPlot1.Plot.AddVerticalLine(0, color: System.Drawing.Color.Red, style: LineStyle.Dash);
            hLine = avaPlot1.Plot.AddHorizontalLine(0, color: System.Drawing.Color.Red, style: LineStyle.Dash);
            avaPlot1.Render();

            avaPlot1.PointerMoved += OnMouseMove;
            avaPlot1.PointerLeave += OnMouseLeave;
            avaPlot1.PointerEnter += OnMouseEnter;
        }