RadDock for WinForms Q2 2009 Beta
It is our pleasure to present you the new RadDock for WinForms Q2 2009 Beta, as promised in the introductory RadDock Q2 2009 webinar. On this page you will find:
For the past couple of months we have actively been developing the new version by concentrating our efforts on addressing all shortcomings of the old RadDocking in order to bring it to the high quality levels you have been accustomed to see from Telerik. Since we expect you to test the control in your applications, we have tried to provide all features that the old docking version has, so that you do not lose any of the current functionality. We even went a little further and decided to include a couple of important improvements which have often been requested.

We have gone to great extends to ensure that one of the most used components in the Telerik WinForms suite will be easy to use for both the developer and the end-user. In addition to the vastly improved design-time support, developers will see new, simplified and completely transparent architecture based on a single interface - IDockWindow - which offers direct access to all logical objects.
End users will feel the difference right away, because the drag-and-drop behavior is now perfect (ToolWindows’ drag-and-drop functionality is now embedded directly in RadDock, rather than depending on window messages, as was the case). The new drag and drop mechanism solves the flickering and window-deactivation problems of the main form, that used to appear in some cases. The new version also features new redock support, updated UI and layouts, excellent drawing performance, new and improved theme management, and better positioning of items.
- A much requested feature was the ability to allow for objects different from IDockPane (such as TabPanels and TabStripPanel) to be added to the RadDock layout, i.e. to be hosted in RadDock, but with disabled docking operations, such as docking other objects in them. This is now possible;
- New CloseAction and AutoDispose properties have been introduced which allow control over the window’s Close behavior, as well as over memory management of the SplitPanel and DockWindow objects (currently the Dispose method has to be called explicitly);
- The new version collects and uses the information about the state of each DockWindow - FloatingSize, FloatingLocation, AutoHideSize, Previous position, AutoHidePostion, etc. dynamically. The old version offered partial support for this;
- The new version offers access to the active window - a feature that was never available in the previous version of the component;
- New VS2010-like docking guides have been added.
The new RadDock features a completely new, more advanced, but easy to use layout mechanism, which gives several distinct advantages over the old mechanism:
- Complex scenarios made simple - by providing many sizing modes (Auto, Relative, Absolute, Fill) virtually any layout scenario can be easily achieved. The user has complete control over sizing and layout behavior;
- Completely transparent and extensible model - each RadSplitContainer composes a RadSplitContainerLayoutStrategy, which handles any layout request for this container. If the available size modes are not enough to fit into a layout scenario, then the entire layout strategy may be easily replaced/extended with a custom one;
- Re-dock support is easier than ever before - storing all sizing information per panel in a separate object allows for easy transition from one state to another and vice-versa without loosing the sizing information for each state;
- “Load Layout” allows for restoring previous scene at 100% - a layout persistency operation should now only serialize/de-serialize the sizing info of each panel in order to completely store/restore its position on a split container.
A new and revamped drag-and-drop mechanism was devised for nimble and intuitive drag and drop behavior:
- The drag and drop behavior is times faster than before, and allows for pixel-perfect hit-testing.
- New Z-order support has been introduced: the docking guides are on top of all, the semi-transparent hint of the new dropping location for the form is next, and the floating forms themselves are last in the z-order.
- True layered window guides, allowing for per-pixel transparency and hot state support (e.g. the docking guide will be rendered differently when the mouse hovers it).
- Completely transparent API - a service-based semantic allows for plugging entirely custom drag-and-drop behavior, if the scenario requires it.
- New, simplified and completely transparent architecture based on a single interface - IDockWindow - which offers direct access to all logical objects;
- IDockWindow is backed up by an internal HostDockWindow which guarantees the correct behavior of hosted or hosting control(s);
- Automated way of hosting and treating Control and/or Form objects, including a simpler and unified API for handling each case;
- The new version provides real control over the active document (tool window, component, and/or panel) and will return correct information on which one is active. Implements ContainerControl of the Base Class Library
BCL) - The Load/Save layout will be based on Name for determining the content. Similar to XAML, the XML code will correspond to the logical objects in RadDock.
Redock support (transition to previous docked or floating state of Dock Windows) has been completely revisited for the new RadDock implementation. A service-based semantic is introduced, which saves a window’s state just before any dock operation is about to occur, and this state can easily be restored later on, upon user request (such as double-clicking a window’s caption area). This allows for exact transition to previous state - floating to docked and vice-versa. Even more, if an application requires completely custom redock semantic, it may be easily replaced by registering a custom service, which handles internal Save/Restore requests, made by the framework.
The beta is available for download from your Telerik accounts --> Downloads (or Free Trials for the trial version) --> RadControls for WinForms.

The new RadDock comes with an upgrade tool within Visual Studio which will help you move from the old DockingManger to the new RadDock. It converts DockingManger's XML layout serialization to the new XML structure of RadDock, so that you do not have to recreate the structure yourself.
NOTE: You may need to remove/redo any custom code related to the docking control, because it may not work with the new docking component. Also, remove any workarounds related to the old DockingManager.
- Download the beta version of RadDock and install the package. The package contains all the controls from RadControls for WinForms Q1 2009 SP1, and a new assembly for the new RadDock Beta (Telerik.WinControls.RadDock.dll). This means that both versions of RadDock (old and new) are fully functional and can be used in the same application.
- Once the installation completes, feel free to review the RadDock Examples (Start --> Programs --> Telerik --> RadControls for WinForms Beta --> Run Demos).
- Back up your project.
- Include/update the references of the following assemblies in your application:
- Telerik.WinControls.dll
- Telerik.WinControls.UI.dll
- Telerik.WinControls.RadDock.dll (new RadDock)
- Telerik.WinControls.Docking.dll (old DockingManager)
- TelerikCommon.dll
- Restart Visual Studio to ensure that all references are updated (sometimes VS.NET locks the assemblies and they are not updated properly).
- Open a form with the old docking and right-click on it in design time.
- From the context menu select the DockingManager control (it is necessary to select DockingManager, because the option to convert to RadDock is in its designer). The DockingManager will get selected, and the option to open the smart tag should appear.
- Open the smart tag - you will see a new option to convert to the new RadDock.
Use the WinForms Beta Forum to send us your comments. All active beta testers will recieve up to 10,000 Telerik Points. We are eager to get your feedback on the RadDock beta.
| DockingManager | RadDock Q2 Beta |
| using Telerik.WinControls.Docking; | using Telerik.WinControls.Dock; |
| class DockableWindowCollection | class DockWindowCollection |
| class DockPanel | class DockWindow
(or ToolWindow or DocumentWindow) |
| interface IDockable | interface IDockWindow
(generally DockWindow class can be used) |
| DdockingManager.SetDock(window, position) | radDock.DockWindow(window, position) |
| DdockingManager.Float(window) | RadDock .FloatWindow(window); |
| dockPane.DockTo(anotherWindow, state) | dockingManager1.DockWindow(window, DockPosition.Bottom);
dockWindow.DockState = DockState.Floating;
or
dockWindow.DockState = DockState.AutoHide; etc |
| radDock1.DockWindow(dockPane, anotherWindow , state) |
| dockingManager.DockingStateChanged | radDock.DockStateChanged |
| dockingManager.DockingStateChanging | radDock.DockStateChanging |
| dockingManager.Hide(dockWindow, true); | dockWindow.DockState = DockState.AutoHide; |
| dockingManager.LoadXML(fileName) | LoadFromXml(fileName)
+ overloads available |
| dockingManager.SaveXML(fileName) | SaveToXml(fileName)
+ overloads available |
| dockingManager1.Reset() | radDock.Clear() |
| dockingManager.GetManagedDockables | radDock.DockWindows |
| dockPane.TabStripVisible = false; | dockWindow.TabStrip.TabStripElement.Visibility = ElementVisibility.Collapsed; |
| DockWindow.Activated event | RadDock.ActiveWindowChanged/Changing |
Issues with Events
- Closing a Document by clicking the Close button will result in DockWindowRemoved to fire two times. The same can be observed when closing document windows by clicking a button;
- DockStateChanging and DockStateChanged do not fire when double-clicking on a Floating window (to return it in the dock);
- No events will fire when changing a dock window's state by drag and drop (for example when docking a floating window);
- DockWindowRemoved will fire two times if removed the following way:
radDock1.RemoveWindow(radDock1.DockWindows[0]); - DockWindowClosed and Closing will not fire when closing a Floating window.
Run-time Issues
- Floating Windows can be docked even when Enabled = false;
- Setting RightToLeft to true does not rotate the Windows and Documents appropriately;
- Docking a floating ToolWindow into another floating ToolWindow will result in all actions such as Dockable, AutoHide, etc to do nothing;
- Setting a window to be in AutoHide mode in design time, and showing the Context Menu at run time will restrict the AutoHide window from opening;
- Showing one of two AutoSize windows which are on the same side in the container, and resizing it will break the other one (mouse hover will not open it);
- Changing a ToolWindow to be Tabbed Document, closing it, then closing all other Document Windows, and drag and dropping a new ToolWindow to become a Tabbed Document will show the first, closed ToolWindow;
- When all ToolWindows are set to AutoHide, clicking on Hide will do nothing. Nothing will happen if Dock is clicked afterwards as well;
- Tool Windows added at design time, and set to AutoHide at run time will always hide them to the Left;
- The Document Window text shows behind the buttons;
- Adding one ToolWindow in two different ways through the API, and opening the ToolWindow's pop up at run time will result in an error;
- Moving to Next/Previous Tabbed Group is not available at the moment.
Design-time Issues
- In design time select a ToolWindow and change its DockState to Floating. Adding a new toolWindow after that through the Smart Tag will reset the changed DockState;
- The splitter is difficult to be selected to resize the panels in design time. Even when resized, the new sizes are not applied at run time.
Serialization Issues
- Load one layout two times. Clicking anywhere in a window will throw a Object Reference error;
- Adding AutoHide windows to Right, Top or Bottom and saving and loading the layout afterwards will not load the AutoHide windows at the correct positions.
- New API to:
- change the docking guide images;
- to change docking guides' appearance through theme;
- to enable theming.
- XML serialization enhancements - floating containers will be serialized to allow for complete (and correct) deserialization;
- Advanced layout designer (in VS designer);
- Visual Style Builder support;
- Splitter UI / theming support / API
- Localization (through localization provider)
- Better Right to Left support
- Enhanced splitter drag behavior in VS designer
- More demos
- Help