QuickStart and DockSample

DevZest WPF Docking

QuickStart and DockSample

Select the installed Samples start menu item, copy the unzipped Samples folder to your local drive. Find the docking samples under Docking subfolder, in VB.Net or C#.

Note Note
Make sure to copy the Assemblies folder together with the samples, without changing the relative path. The samples reference the assembilies in this folder.

This topic contains the following sections:

QuickStart Sample

The QuickStart sample is a very simple application to demonstrate WPF Docking. To re-create the QuickStart sample in Visual Studio:

  1. Create a new WPF Application project in Visual Studio.
  2. Reference the two assemblies in the installation folder: DevZest.WpfDocking.dll and DevZest.Licensing.dll.
  3. Enter the following XAML code in Window1.xaml:

    XAML
    <Window
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:dz="http://schemas.devzest.com/presentation/docking"
        Title="DockControl Sample"
        WindowState="Maximized">
        <dz:DockControl>
            <dz:DockItem TabText="Welcome" Title="Welcome" ShowAction="{dz:ShowAsDockPositionAction DockPosition=Document}">
                <FlowDocumentScrollViewer>
                    <FlowDocumentScrollViewer.Document>
                        <FlowDocument FontFamily="Calibri" FontSize="14.5" TextAlignment="Left">
                            <Paragraph FontSize="22" FontWeight="Bold">Welcome to DevZest Docking</Paragraph>
                        </FlowDocument>
                    </FlowDocumentScrollViewer.Document>
                </FlowDocumentScrollViewer>
            </dz:DockItem>
            <dz:DockItem TabText="Saved State" Title="Saved State" ShowAction="{dz:ShowAsDockPositionAction DockPosition=Bottom}">
                <TextBox />
            </dz:DockItem>
            <dz:DockItem TabText="Output" Title="Output" ShowAction="{dz:ShowAsDockPositionAction DockPosition=Bottom}">
                <TextBox />
            </dz:DockItem>
            <dz:DockItem TabText="Solution Explorer" Title="Solution Explorer" ShowAction="{dz:ShowAsDockPositionAction DockPosition=Right}">
                <TextBox />
            </dz:DockItem>
            <dz:DockItem TabText="Properties" Title="Properties" ShowAction="{dz:ShowAsDockPositionAction DockPosition=Right}">
                <TextBox />
            </dz:DockItem>
        </dz:DockControl>
    </Window>
  4. Press F5 to run the application.
WindowDockSample and BrowserDockSample

The WindowDockSample demonstrates the full feature of WPF Docking. Run this applicaiton and read the Welcome page, then refer to the source code to get the idea how things work.

The BrowserDockSample has the same functionality, except it is a XBAP application hosted in a browser.