Northwoods.GoSilverlight 1.2.2 Assembly
GroupPanel Class
Members  See Also  Send Feedback
Northwoods.GoXam Namespace : GroupPanel Class

An auto-resizing SpotPanel that always surrounds its Group's Group.MemberNodes plus some Padding.

Syntax

Visual Basic (Declaration) 
Public Class GroupPanel 
   Inherits SpotPanel
C# 
public class GroupPanel : SpotPanel 

Remarks

Note that the member nodes of a group are NOT children of this panel. Typically only decorative elements and ports are part of a GroupPanel.

A node template representing a group, if it contains a GroupPanel, must name that GroupPanel as the node's Node.LocationElementName, resulting in Node.LocationElement referring to that panel.

For example, the following DataTemplate for Groups results in a thick border around the group's member nodes with some text above the top-left corner of the border and a port on each side in the middle of the border.

              <DataTemplate x:Key="ExampleGroupTemplate">
                <StackPanel go:Node.LocationElementName="GroupPanel">
                  <TextBlock Text="{Binding Path=Data.Name}" />
                  <Border BorderBrush="Gray" BorderThickness="6" CornerRadius="5" Margin="0">
                    <go:GroupPanel x:Name="GroupPanel" Padding="10" >
                      <Path go:SpotPanel.Spot="0 0.5 -3 0" Data="M0 0 L6 3 L 0 6 Z" Fill="Blue"
                            Width="6" Height="6" go:Node.PortId="input" go:Node.LinkableTo="True" />
                      <Path go:SpotPanel.Spot="1 0.5 3 0" Data="M0 0 L6 3 L 0 6 Z" Fill="Green"
                            Width="6" Height="6" go:Node.PortId="output" go:Node.LinkableFrom="True" />
                    </go:GroupPanel>
                  </Border>
                </StackPanel>
              </DataTemplate>
            

Inheritance Hierarchy

System.Object
   System.Windows.DependencyObject
      System.Windows.UIElement
         System.Windows.FrameworkElement
            System.Windows.Controls.Panel
               Northwoods.GoXam.SpotPanel
                  Northwoods.GoXam.GroupPanel

Requirements

See Also

© 2010 All Rights Reserved.