private void InitializeControls() { // Setup docking functionality KryptonDockingWorkspace w = kryptonDockingManager.ManageWorkspace(kryptonDockableWorkspace); kryptonDockingManager.ManageControl(kryptonPanel, w); kryptonDockingManager.ManageFloating(this); // Add initial docking pages databaseNavigationForm = new DatabaseNavigationForm { Text = "Database Navigation" }; databaseNavigationForm.TableSelected += DnfTableSelected; databaseNavigationForm.DatabaseSelected += DnfDatabaseSelected; databaseNavigationForm.ColumnSelected += DnfColumnSelected; snippetsForm = new SnippetsForm { Text = "Snippets" }; snippetsForm.SnippetSelected += SfSnippetSelected; documentForm = new DocumentForm { Text = "Template" }; resultForm = new ResultForm { Text = "Results" }; propertiesForm = new PropertiesForm { Text = "Properties" }; customValuesForm = new CustomValuesForm { Text = "Custom Values" }; templatePage = NewDocument("Template", documentForm, icon: IconToBitMap("itemplate.ico")); resultPage = NewDocument("Results", resultForm, icon: IconToBitMap("iresult.ico")); kryptonDockingManager.AddToWorkspace("Workspace", new KryptonPage[] { templatePage, resultPage }); kryptonDockingManager.AddAutoHiddenGroup("Control", DockingEdge.Left, new KryptonPage[] { NewPage("Snippets", snippetsForm, icon: IconToBitMap("isnippet.ico")) }); kryptonDockingManager.AddDockspace("Control", DockingEdge.Left, new KryptonPage[] { NewPage("Database Navigation", databaseNavigationForm, icon: IconToBitMap("idb.ico")) }); kryptonDockingManager.AddDockspace("Control", DockingEdge.Right, new KryptonPage[] { NewPage("Properties", propertiesForm, icon: IconToBitMap("igen.ico")), NewPage("Custom Values", customValuesForm, icon: IconToBitMap("icustom.ico")) }); }
private void InitializeControls() { _dnf = new DatabaseNavigationForm(); _dnf.Text = "Database Navigation"; _dnf.Show(dockPanel, DockState.DockLeft); _dnf.Icon = global::iCodeGenerator.iCodeGeneratorGui.Properties.Resources.idb; _dnf.TableSelected += DnfTableSelected; _dnf.DatabaseSelected += DnfDatabaseSelected; _dnf.ColumnSelected += DnfColumnSelected; _dnf.HideOnClose = true; _sf = new SnippetsForm(); _sf.Text = "Snippets"; _sf.SnippetSelected += SfSnippetSelected; _sf.Show(dockPanel, DockState.DockLeftAutoHide); _sf.Icon = global::iCodeGenerator.iCodeGeneratorGui.Properties.Resources.isnippet; _sf.HideOnClose = true; _df = new DocumentForm(); _df.Text = "Template"; _df.Show(dockPanel, DockState.Document); _df.Icon = global::iCodeGenerator.iCodeGeneratorGui.Properties.Resources.itemplate; _df.HideOnClose = true; _rf = new ResultForm(); _rf.Text = "Results"; _rf.Show(dockPanel, DockState.Document); _rf.Icon = global::iCodeGenerator.iCodeGeneratorGui.Properties.Resources.iresult; _rf.HideOnClose = true; _pf = new PropertiesForm(); _pf.Text = "Properties"; _pf.Show(dockPanel, DockState.DockRight); _pf.Icon = global::iCodeGenerator.iCodeGeneratorGui.Properties.Resources.igen; _pf.HideOnClose = true; _cvf = new CustomValuesForm(); _cvf.Text = "Custom Values"; _cvf.Show(dockPanel, DockState.DockRight); _cvf.Icon = global::iCodeGenerator.iCodeGeneratorGui.Properties.Resources.icustom; _cvf.HideOnClose = true; }
private void InitializeControls() { _dnf = new DatabaseNavigationForm(); _dnf.Text = "Database Navigation"; _dnf.Show(dockPanel, DockState.DockLeft); _dnf.Icon = Icon.ExtractAssociatedIcon(@"idb.ico"); _dnf.TableSelected += DnfTableSelected; _dnf.DatabaseSelected += DnfDatabaseSelected; _dnf.ColumnSelected += DnfColumnSelected; _dnf.HideOnClose = true; _sf = new SnippetsForm(); _sf.Text = "Snippets"; _sf.SnippetSelected += SfSnippetSelected; _sf.Show(dockPanel, DockState.DockLeftAutoHide); _sf.Icon = Icon.ExtractAssociatedIcon(@"isnippet.ico"); _sf.HideOnClose = true; _df = new DocumentForm(); _df.Text = "Template"; _df.Show(dockPanel, DockState.Document); _df.Icon = Icon.ExtractAssociatedIcon(@"itemplate.ico"); _df.HideOnClose = true; _rf = new ResultForm(); _rf.Text = "Results"; _rf.Show(dockPanel, DockState.Document); _rf.Icon = Icon.ExtractAssociatedIcon(@"iresult.ico"); _rf.HideOnClose = true; _pf = new PropertiesForm(); _pf.Text = "Properties"; _pf.Show(dockPanel, DockState.DockRight); _pf.Icon = Icon.ExtractAssociatedIcon(@"igen.ico"); _pf.HideOnClose = true; _cvf = new CustomValuesForm(); _cvf.Text = "Custom Values"; _cvf.Show(dockPanel, DockState.DockRight); _cvf.Icon = Icon.ExtractAssociatedIcon(@"icustom.ico"); _cvf.HideOnClose = true; }