私のShell.xamlでは、2つのモジュールがそれぞれ高さの半分を占めて拡張可能であることを望みます。なぜ最初のモジュールが切断されていますか?私のモジュールが私のShell.xaml内の完全なDockPanelを満たさないのはなぜですか?
alt text http://i30.tinypic.com/2cr5zx0.png
シェル:
<Window x:Class="HelloWorld.Desktop.Shell"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:cal="http://www.codeplex.com/CompositeWPF"
Height="300"
Width="300"
Title="Hello World" >
<DockPanel LastChildFill="True">
<ContentControl Name="MainRegion"
DockPanel.Dock="Top"
cal:RegionManager.RegionName="MainRegion"/>
<ContentControl
Name="SecondRegion"
DockPanel.Dock="Top"
cal:RegionManager.RegionName="SecondRegion"/>
</DockPanel>
</Window>
HelloWorldView:
<UserControl x:Class="HelloWorldModule.Views.HelloWorldView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<StackPanel
Background="Tan">
<TextBlock Text="Hello World View"
Foreground="Brown"
Margin="10 10 10 0"
FontSize="14"/>
<TextBlock Name="DisplayArea"
Margin="10 10 10 0" Text="(default text)" TextWrapping="Wrap"/>
</StackPanel>
</UserControl>
SecondView:
<UserControl x:Class="SecondModule.Views.SecondView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<StackPanel
Background="Orange">
<TextBlock Text="Second View"
Foreground="Brown"
Margin="10 10 10 0"
FontSize="14"/>
<TextBox Name="Message"
Margin="10 10 10 0" Text="skfddsf" TextChanged="TextBox_TextChanged"/>
</StackPanel>
</UserControl>
実際には5インチの高さ= "5 *"は必要ありません。両方の行に*を使用するだけです。 – Carlo