Esempio n. 1
0
        private void menuItemNew_Click(object sender, System.EventArgs e)
        {
            TextDocView dummyDoc = this.CreateNewDocument();

            if (dockPanel.DocumentStyle == DocumentStyle.SystemMdi)
            {
                dummyDoc.MdiParent = this;
                dummyDoc.Show();
            }
            else
            {
                dummyDoc.Show(dockPanel);
            }
        }
Esempio n. 2
0
        private void menuItemLayoutByCode_Click(object sender, System.EventArgs e)
        {
            dockPanel.SuspendLayout(true);

            this.CloseAllContents();

            this.CreateStandardControls();

            m_solutionExplorer.Show(dockPanel, DockState.DockRight);
            m_propertyWindow.Show(m_solutionExplorer.Pane, m_solutionExplorer);
            m_toolbox.Show(dockPanel, new Rectangle(98, 133, 200, 383));
            m_outputWindow.Show(m_solutionExplorer.Pane, DockAlignment.Bottom, 0.35);
            m_taskList.Show(m_toolbox.Pane, DockAlignment.Left, 0.4);

            TextDocView doc1 = this.CreateNewDocument("Document1");
            TextDocView doc2 = this.CreateNewDocument("Document2");
            TextDocView doc3 = this.CreateNewDocument("Document3");
            TextDocView doc4 = this.CreateNewDocument("Document4");

            doc1.Show(dockPanel, DockState.Document);
            doc2.Show(doc1.Pane, null);
            doc3.Show(doc1.Pane, DockAlignment.Bottom, 0.5);
            doc4.Show(doc3.Pane, DockAlignment.Right, 0.5);

            dockPanel.ResumeLayout(true, true);
        }