public void Attach(IWorkbench workbench)
		{
			wbForm = (DefaultWorkbench)workbench;
			wbForm.SuspendLayout();
			wbForm.Controls.Clear();
			toolStripContainer = new ToolStripContainer();
			toolStripContainer.SuspendLayout();
			toolStripContainer.Dock = DockStyle.Fill;
			
			mainMenuContainer = new AutoHideMenuStripContainer(((DefaultWorkbench)wbForm).TopMenu);
			mainMenuContainer.Dock = DockStyle.Top;
			
			statusStripContainer = new AutoHideStatusStripContainer((StatusStrip)StatusBarService.Control);
			statusStripContainer.Dock = DockStyle.Bottom;
			
			dockPanel = new WeifenLuo.WinFormsUI.DockPanel();
			dockPanel.DocumentStyle = DocumentStyles.DockingWindow;
			this.dockPanel.Dock = System.Windows.Forms.DockStyle.Fill;
			
			Panel helperPanel = new Panel();
			helperPanel.Dock = DockStyle.Fill;
			helperPanel.Controls.Add(dockPanel);
			toolStripContainer.ContentPanel.Controls.Add(helperPanel);
			
			toolStripContainer.ContentPanel.Controls.Add(mainMenuContainer);
			toolStripContainer.ContentPanel.Controls.Add(statusStripContainer);
			
			wbForm.Controls.Add(toolStripContainer);
			// dock panel has to be added to the form before LoadLayoutConfiguration is called to fix SD2-463
			
			LoadLayoutConfiguration();
			ShowPads();
			
			ShowViewContents();
			
			RedrawAllComponents();
			
			dockPanel.ActiveDocumentChanged += new EventHandler(ActiveMdiChanged);
			dockPanel.ActiveContentChanged += new EventHandler(ActiveContentChanged);
			ActiveMdiChanged(this, EventArgs.Empty);
			
			toolStripContainer.ResumeLayout(false);
			wbForm.ResumeLayout(false);
			
			Properties fullscreenProperties = PropertyService.Get("ICSharpCode.SharpDevelop.Gui.FullscreenOptions", new Properties());
			fullscreenProperties.PropertyChanged += TrackFullscreenPropertyChanges;
		}
		public void Attach(IWorkbench workbench)
		{
			wbForm = (DefaultWorkbench)workbench;
			wbForm.SuspendLayout();
			wbForm.Controls.Clear();
			
			mainMenuContainer = new AutoHideMenuStripContainer(wbForm.TopMenu);
			mainMenuContainer.Dock = DockStyle.Top;
			
			statusStripContainer = new AutoHideStatusStripContainer((StatusStrip)StatusBarService.Control);
			statusStripContainer.Dock = DockStyle.Bottom;
			
			toolBarPanel = new ToolStripPanel();
			if (wbForm.ToolBars != null) {
				toolBarPanel.Controls.AddRange(wbForm.ToolBars);
			}
			toolBarPanel.Dock = DockStyle.Top;
			
			dockPanel = new DockPanel();
			dockPanel.Dock = DockStyle.Fill;
			dockPanel.RightToLeftLayout = true;
			
			// Known issues with certain DocumentStyles:
			//   DockingMdi:
			//    - this is the default value
			//    - after switching between layouts, text editor tooltips sometimes do not show up anymore
			//   DockingSdi:
			//    - in this mode, the tab bar is not shown when there is only one open window
			//   DockingWindow:
			//    - SharpDevelop 2.x used this mode
			//    - it was also the only mode supported by the early DockPanelSuite versions used by SharpDevelop 1.x
			
			dockPanel.DocumentStyle = DocumentStyle.DockingWindow;
			
			wbForm.Controls.Add(dockPanel);
			wbForm.Controls.Add(toolBarPanel);
			wbForm.Controls.Add(mainMenuContainer);
			wbForm.Controls.Add(statusStripContainer);
			wbForm.MainMenuStrip = wbForm.TopMenu;
			// dock panel has to be added to the form before LoadLayoutConfiguration is called to fix SD2-463
			
			LoadLayoutConfiguration();
			ShowPads();
			
			ShowViewContents();
			
			RedrawAllComponents();
			
			dockPanel.ActiveDocumentChanged += new EventHandler(ActiveMdiChanged);
			dockPanel.ActiveContentChanged += new EventHandler(ActiveContentChanged);
			ActiveMdiChanged(this, EventArgs.Empty);
			
			wbForm.ResumeLayout(false);
			
			Properties fullscreenProperties = PropertyService.Get("ICSharpCode.SharpDevelop.Gui.FullscreenOptions", new Properties());
			fullscreenProperties.PropertyChanged += TrackFullscreenPropertyChanges;
		}