March 2010
Intermediate to advanced
1216 pages
33h 44m
English
The StackPanel is one of the simplest layout containers. It simply stacks its children in a single row or column.
For example, consider this window, which contains a stack of four buttons:
<Window x:Class="Layout.SimpleStack"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="Layout" Height="223" Width="354"
>
<StackPanel>
<Label>A Button Stack</Label>
<Button>Button 1</Button>
<Button>Button 2</Button>
<Button>Button 3</Button>
<Button>Button 4</Button>
</StackPanel>
</Window>
Figure 3-2 shows the window that results.
Adding a Layout Container in Visual StudioIt's relatively easy to create ... |
Read now
Unlock full access