public void Execute(PCBI.Automation.IPCBIWindow parent)
        {
            parent.MainForm.KeyPress += MainForm_KeyPress;
            parent.ZoomHome();
            //example work to highlight pins of gnd net
            IStep curStep = parent.GetCurrentStep();

            if (curStep == null)
            {
                return;
            }

            RectangleF rect = curStep.GetBounds();
            //do  work here
            int   loopX = 0;
            int   loopY = 0;
            float tileX = 300; // 300 / 25,4 entspicht 11 mm
            float tileY = 300; // 300 / 25,4 entspicht 11 mm

            while (true)
            {
                Thread.Sleep(500);

                if (isDisposed)
                {
                    break;
                }
                if (pause)
                {
                    continue;
                }
                RectangleF zoomrect = new RectangleF(rect.X + tileX * loopX, rect.Y + tileY * loopY, tileX, tileY);
                loopX++;
                parent.ZoomRect(zoomrect);

                if (tileX * loopX > rect.Width)
                {
                    loopY++;
                    loopX = 0;
                    if (tileY * loopY > rect.Height)
                    {
                        parent.ZoomHome();
                        break;
                    }
                }
            }
        }
        public void Execute(PCBI.Automation.IPCBIWindow parent)
        {
            parent.MainForm.KeyPress += MainForm_KeyPress;
            parent.ZoomHome();
            //example work to highlight pins of gnd net
            IStep curStep = parent.GetCurrentStep();

            if (curStep == null)
            {
                return;
            }
            IMatrix matrix = parent.GetMatrix();

            parent.UIAction.Execute(ID_ActionItem.ID_ALL_LAYER_OFF);
            List <string> layernames = matrix.GetAllLayerNames();
            int           count      = layernames.Count;
            int           loopLayer  = 0;

            loopLayer = layernames.IndexOf(matrix.GetTopSignalLayer());
            while (true)
            {
                Thread.Sleep(1000);

                if (isDisposed)
                {
                    break;
                }
                if (pause)
                {
                    continue;
                }

                if (loopLayer > 0)
                {
                    curStep.GetLayer(layernames[loopLayer - 1]).DisableLayer();
                }
                curStep.GetLayer(layernames[loopLayer]).EnableLayer(true);
                parent.UpdateView();

                loopLayer++;
                if (loopLayer > count)
                {
                    break;
                }
                if (loopLayer > layernames.IndexOf(matrix.GetBotSignalLayer()))
                {
                    break;
                }
            }
        }