public void HostControl(Control c, string name) { DocumentForm frm = new DocumentForm(c) { ShowHint = DockState.Document }; frm.Show(m_dockPanel); if (!string.IsNullOrWhiteSpace(name)) { frm.TabText = name; } }
public void CreatePropertyGrid(bool autohide) { if (m_property_grid == null || m_property_grid.IsDisposed) { m_property_grid = new PropertyGrid(); m_property_grid.ToolbarVisible = false; m_property_grid.PropertySort = PropertySort.Alphabetical; DocumentForm frm = new DocumentForm(m_property_grid); frm.TabText = "Object Properties"; frm.ShowHint = autohide ? DockState.DockRightAutoHide : DockState.DockRight; frm.Show(m_dockPanel); } }