WPF/CAB Layer General Use Samples
The samples discussed in this document are all available in the Samples/WPFCAB/WPFCAB.sln
solution. To run a specific example, right-click the project and choose
Set as StartUp Project
and then build and run the application.
The shell samples show the various out-of-the-box application classes provided with the WPF/CAB layer. Your choice of application class dictates what your shell type.
This sample demonstrates using the SCSFContrib.CompositeUI.WPF.ApplicationShellApplication
class as the bootstrapper for your WPF/CAB application. Doing so means that your CAB application's life time is tied directly to
the life time of the current System.Windows.Application
instance (your shell). This shell type gives you the most flexibility and control over your application life cycle.
This samples demonstrates using the SCSFContrib.CompositeUI.WPF.WindowShellApplication
class as the bootstrapper for your WPF/CAB application. This means that your CAB application's life time is tied directly to the life
time of a System.Windows.Window
instance (your shell). This shell type is less flexible than an application shell, but may be suitable for simpler applications.
The workspace samples demonstrate using the various IWorkspace
implementations that come with the WPF/CAB layer. As you'll see, these workspaces can be used to show smart parts in various different ways.
This sample demonstrates using the SCSFContrib.CompositeUI.WPF.Workspaces.WindowWorkspace
type to display smart parts within a
instance. It also shows how you can use an instance of
to customize the appearance of the
used to display the smart part.
This sample demonstrates using the SCSFContrib.CompositeUI.WPF.Workspaces.DeckWorkspace
type to display smart parts in a deck. It allows you to show, hide and close smart parts within the deck so you can see how each of these
actions affects which smart part is currently visible.
This sample demonstrates using the SCSFContrib.CompositeUI.WPF.Workspaces.TabWorkspace
type to display smart parts in a
. It allows you to show, hide and close smart parts within the
so you can see how each of these actions affects which smart part is currently visible.
This sample demonstrates using the SCSFContrib.CompositeUI.WPF.Workspaces.ZoneWorkspace
type to display smart parts in a specific zone. It allows you to show, hide and close smart parts within a chosen zone. It also shows how
a given smart part instance can appear in only one zone at any one time, and how each zone acts like a deck workspace.
The samples in this section don't really fall under any specific category, but are important nonetheless.
This sample demonstrates various extensibility functionality in CAB, including how to register UI extension points, how to add UI elements to those extension points, and how to use commands to centralize the logic behind user actions. The sample itself walks
you through the details.
This sample shows a custom visualizer implementation that displays debug output in CAB's visualizer window. It can serve as a reference for implementing your own (probably more complex) visualizers.