0
我在Microsoft的RibbonControlLibrary
中遇到了一個問題。我創建了一個簡單的WPF應用程序,我使用RibbonControlLibrary
在頂部創建一個功能區欄。問題如下圖所示。RibbonControlLibrary中的問題
問題是即項目1,項目2 ......如果我增加左側菜單中的項目,我得到的是在「東西」菜單上不僅擴大不亞於有在左邊的菜單項這個
但在Something下面的菜單中沒有窗臺項目。
下面的XAML我使用
<Ribbon:Ribbon ItemsSource="{Binding Path=CSIMRibbonTabs}">
<Ribbon:Ribbon.ApplicationMenu>
<Ribbon:RibbonApplicationMenu CanUserResizeVertically="True" ItemsSource="{Binding Path=MainItem}">
<Ribbon:RibbonApplicationMenu.AuxiliaryPaneContent>
<Grid>
<Grid.RowDefinitions>
<RowDefinition />
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Border >
<StackPanel Orientation="Vertical">
<Label Content="Something" />
</StackPanel>
</Border>
<ItemsControl Grid.Row="1" ItemsSource="{Binding Path=OtherItems}"/>
</Grid>
</Ribbon:RibbonApplicationMenu.AuxiliaryPaneContent>
</Ribbon:RibbonApplicationMenu>
</Ribbon:Ribbon.ApplicationMenu>
</Ribbon:Ribbon>
代碼
public List<string> MainItem
{
get
{
return new List<string>() { "Item1", "Item2", "Item3"};
}
}
public List<string> OtherItems
{
get
{
return new List<string>() { "val1", "val2", "val3", "val4", "val5", "val6", "val7", "val8" };
}
}
我應該怎麼做,以擴大在「東西」菜單不亞於有列表中的項目?