public override void Disconnect()
 {
     base.Disconnect();
     if (ow != null)
     {
         ow.CanClose = true;
         ow.Close();
         ow.waterfallSpectrum = null;
         ow = null;
     }
 }
 private void BnDisplayWin_buttonStateChanged(object sender, EventArgs e)
 {
     if (ow == null)
     {
         ow = new WaterfallSpectrumWin();
         ow.initWaterfallSpectrum(this);
         ow.Show();
     }
     else
     {
         ow.Show();
     }
 }
        private void init()
        {
            InitializeComponent();

            /*size.set(200, 25 + 50);
             *
             * io.Add(new ProcessingIO(owner, this, ProcessingIO.ProcessingIOType.Input, false,
             *  "I", false, ProcessingIO.ProcessingIOAlign.LeftFromTop, Vector.V(25 + 25, 0)));
             *
             * ctrl.Add(new Controls.Button(owner, this, Vector.V(40, 40), "Open Window", 10, 5));*/

            bnDisplayWin.buttonStateChanged += BnDisplayWin_buttonStateChanged;

            ow = null;

            processingType = ProcessingType.Sink;
        }
Beispiel #4
0
        public void initWaterfallSpectrumScreen(WaterfallSpectrumWin _root)
        {
            root = _root;

            sizeXLable   = GraphicsUtil.sizeText(Vector.Zero, _axesFont, 1.0, "100k", -1, 2, -1, 0, Vector.X).boundingDim();
            sizeYLable   = GraphicsUtil.sizeText(Vector.Zero, _axesFont, 1.0, "60.0", -1, 2, -1, 0, Vector.X).boundingDim();
            sizeColLable = GraphicsUtil.sizeText(Vector.Zero, _axesFont, 1.0, "-120.0", -1, 2, -1, 0, Vector.X).boundingDim();

            // Horizontal Grid
            gridF = new GridCalculator(0, 1e6, 10, 0.1, 2, 100, 20000, false,
                                       sizeXLable.x + 10, Width - 10, sizeXLable.x + 10);

            // Vertical Grid
            gridY = new GridCalculator(0, 100, 1, 1e-10, 1.1, 0, 30, false,
                                       Height - sizeXLable.y - 10, sizeColLable.y + colbarHeight + 10 + 10, sizeYLable.y + 10);

            // Color Grid
            gridCol = new GridCalculator(-200, 200, 1, 1e-10, 1.1, -120, 0, false,
                                         sizeColLable.x / 2 + 10, Width - sizeColLable.x / 2 - 10, sizeColLable.x + 10);

            ready = true;
        }