Register  |  Login
 
 
Info Minimize

Version: 1.3

Release date: June, 16, 2008

License: free

Platform: .Net 3.5

VS: 2005, 2008

Source included: yes

Print  
 
 
You are here :- software >> ControlFramework
Intro Minimize

The JaStDev.ControlFramework is a WPF library that contains controls, panels and utilities that you are free to use in your own applications. You can get the source from the download section.

The following controls are currently included:

Print  
BreadcrumbsControl Minimize

The BreadcrumbsControl is an ItemsControl similar to the address bar in windows vista explorer.  It allows you to display and edit a selection path.  A common scenario for this control is to bind it to a TreeView so it can display and control the path to the currently selected item.  UIBrowser uses this control to display the currently selected user interface item.

There are also a couple of default converters available which facilitate the convertion between the SelectedItem property of TreeView and a selection path for a BreadcrumbsControl.

Print  
DockSplitter Minimize

This is a very useful control that wasn't included in the microsoft WPF library, but which really should have been. It works exactly as the GridSplitter control, but is used to resize items that are laid out on a DockPanel.

To use this control, simply drop 2 controls on a DockPanel and put a splitter in the middel, assign it a dock location, and voila.

Print  
Help Minimize

Another must have feature for any serious application: Help integration. This control provides HTML 1.0 context sensitive help for your WPF applications. It's interface is similar to the Help component for Windows Forms but has some extra attached properties (see the example) to add help info to controls.

<TextBox jf:Help.Topic="textbox.html">
   Text with help
</TextBox>
Print  
TabPanel Minimize

The standard template of the WPF TabControl uses a TabPanel object to display the list of tabs. When there are more tabs than fit in a row, it displays multiple rows. The ControlFramework contains an implementation for a TabPanel that, instead of using multiple rows, shrinks the size of each tab so that everything fits in a single row.
Demo 2 of the DockingControl uses this panel in a few TabControls.

Print  
FocusManager Minimize

This is a helper class for managing Keyboard focus from xaml.

  • It allows you to declare the object that has initial keyboard focus from within you xaml. Here's an example:
    <Button v:FocusManager.IsFocused="True">hello</Button>
  • It also allows you to assign the keyboard focus to the first selected item in a Selector (like ListBox or ListView) like so:
    <ListBox v:FocusManager.IsSelectedItemFocused="True"
     ItemsSource="{Binding}"/>
Print  
DockPanelEx Minimize

This is a reimplementation of the DockPanel. It displays the items in a similar way, except that the last 'visible' item is stretched to fill the remaining area. This is usefull if you want to collaps items on a DockPanel but need it to fill the intire area.

Print  
Extender Minimize

Some applications need to display xaml files dynamically. Unfortunatly, it's not possible to declare event handlers (code behind) in these files. This class provides a generic way to achieve this feature through attached properties. Here's an example:

<ListBox v:Extender.Functionality="ListBoxSelectOnFocus"
 ItemsSource="{Binding}"/>

This makes certain that, when a listbox item is focused, it is also selected, which allows for automatic selection of items during navigation with the keyboard.

Print  
Rotary Minimize

Rotary knobScrollbars and sliders use a Track object to display and change their value. Replace this Track object and you change the behavior of these controls. Rotary is such a reimplementation of Track. Use this in a template for ScrollBars or Sliders to turn them into knobs.

Print  
TreeItemObject Minimize

Have you ever had to make a TreeView that needed to be populated from an ItemsSource, but where some levels in the tree need to be static which in turn have a dynamic sub lists? It is possible, but not so easy. These are 2 helper classes tha make this task a lot easier. Here's a small example:

<Window.Resources>
      <DataTemplate DataType="{x:Type v:TreeItemObject}">
         <TextBlock Text="{Binding Path=ItemsSourcePath}"/>
      DataTemplate>
 
      <HierarchicalDataTemplate x:Key="PropertiesTreeItemObject" 
                                ItemsSource="{Binding Path=Properties}"/>
 
      <HierarchicalDataTemplate x:Key="FieldsItemObject" 
                                ItemsSource="{Binding Path=Fields}"/>
 
      <v:TreeItemObjectTemplateSelector x:Key="Selector"/>
      <col:ArrayList x:Key="StaticItems">
         <v:TreeItemObject ItemsSourcePath="Properties"/>
         <v:TreeItemObject ItemsSourcePath="Fields"/>
      col:ArrayList>
 
      <HierarchicalDataTemplate DataType="{x:Type Class}"
            ItemsSource="{Binding Source={StaticResource StaticItems}}"
            ItemTemplateSelector="{StaticResource Selector}">
         <TextBlock Text="{Binding Path=Name}"/>
      HierarchicalDataTemplate>
   Window.Resources>
   <TreeView ItemsSource="{Binding Path=Classes}"/>
Print  
DistributionPanl Minimize

DistributionPanl is a panel derived from Dr  WPF's ConceptualPanel.  You can read more about it here.

Print