コード例 #1
0
        public GerberPanelizerParent()
        {
            Console.SetOut(CW);

            InitializeComponent();
            TV = new Treeview();
            //TV.MdiParent = this;
            TV.Show();
            TV.TopLevel = false;
            TV.Dock     = DockStyle.Fill;
            panel3.Controls.Add(TV);
            ID      = new InstanceDialog();
            ID.Dock = DockStyle.Fill;
            ID.Show();
            ID.TopLevel = false;
            panel4.Controls.Add(ID);
            //ID.Dock = DockStyle.Left;
            //TV.Dock = DockStyle.Right;
            TV.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
            ID.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;

            RemovePanelizer();


            //   Explanation_And_Warning EAW = new Explanation_And_Warning();
            //   EAW.Show();
            //   EAW.TopMost = true;

            //RegistryKey key = Registry.LocalMachine.OpenSubKey("CurrentUser", true);

            //key.CreateSubKey("NotRocketSciencePanelizer");
            //key = key.OpenSubKey("NotRocketSciencePanelizer", true);


            //key.CreateSubKey("0.1");
            //key = key.OpenSubKey("0.1", true);
            //int tr = (int)key.GetValue("TimesRun", (int)0);
            //key.SetValue("TimesRun", (int)(timesrun+1), RegistryValueKind.DWord);

            //if (timesrun == 0)
            //{
            //    string curDir = Directory.GetCurrentDirectory();
            //    string Url = String.Format("file:///{0}/Help/welcome.html", curDir);
            //    Process.Start(Url);
            //}
        }
コード例 #2
0
        public GerberPanelize(GerberPanelizerParent Host, Treeview tv, InstanceDialog id)
        {
            ParentFrame = Host;
            Gerber.ArcQualityScaleFactor = 0.1;
            InitializeComponent();
            UpdateAutoProcessButton();
            UpdateSnapBox(SnapMode.MM1);
            //   AddGerberFolder(@"C:\Projects\Circuits\50pcs 5x5cm green 1.6mm - goaoma");
            //   TheSet.Tabs.Add(new BreakTab() { Radius = 5, Angle = 10, Center = new PointF(50,50) });
            TV = tv;
            ID = id;
            TV.BuildTree(this, ThePanel.TheSet);
            DrawingScale = Math.Min(glControl1.Width, glControl1.Height) / 110.0f;

            ZoomToFit();
            BuildTitle();
            //   LoadFile(@"C:\Projects\Circuits\panelsets\RackPanel-Frame\innerframetest.gerberset");
        }