The PathPanel and PathView classes display listbox items along a "path," allowing for the creation of unique, eye-catching applications. The settings available for configuring a path make it easy to draw attention to the most important item in the list in a striking fashion (see Configuring the Path below).
The PathView is used in the MultiViewPanel class to provide easy, animated switching between views (for details on PathView and MultiViewPanel, see The MultiViewPanel Class). It is otherwise identical to PathPanel in terms of functionality.
The following XAML illustrates how to set up a simple PathPanel.
The path in a PathPanel or a PathView is determined through their PathConfiguration properties. The PathConfiguration class provides several properties to configure the path.
The PathGeometry property defines the shape of the path and takes a Geometry-derived object. The following XAML shows how to set the path to an S-shape.
When the ContainerOrientation property is set to None, items are oriented so that they are always parallel to the horizontal edges of the application, window, or screen. When set to OrientOnPath, items will be rotated to be perpendicular to the axis of the path segment they are on. The ContainerPadding property specifies a device-independent units (1/96th inch per unit) measure representing the padding between items.
The ScalingStops and ZIndexStops properties contain collections of ScalingStop and ZIndexStop objects, respectively, which influence the scaling and z-order of items depending on their current position on the path. The ScalingStop instances in the collection determine the ScalingFactor at a given Offset on the path. The ZIndexStop instances in the collection determine the ZIndexFactor (depth) at a given Offset on the path. Together, they allow items to be displayed as if they are receding in the distance along the path. As a result, the end-user's attention can be directed to the current or most important item, for example.
The following XAML shows how to configure a path that will create an "oval" effect of the items.
The StartOffset property determines the offset on the path where the first item is initially displayed and where it falls when at the "top" of the list.
Finally, the PathPadding and PathStretch properties determine the padding between the path and the panel's bounds and how the path geometry is resized to fill its allocated space, respectively.