在树视图上展开并折叠ExpandableContentControl不调整大小。以下是相同的代码:
HorizontalContentAlignment="Stretch"
HorizontalAlignment="Stretch"
MinWidth="225"
Height="Auto"
>
<layoutToolkit:AccordionItem Header="A" >
<controls:TreeView Margin="5" SizeChanged="TreeView_SizeChanged" Grid.Row="0" Grid.Column="0" UseLayoutRounding="True">
<controls:TreeViewItem Header="Controls">
<controls:TreeViewItem Header="AutoCompleteBox"/>
<controls:TreeViewItem Header="Expander"/>
<controls:TreeViewItem Header="NumericUpDown"/>
</controls:TreeViewItem>
<controls:TreeViewItem Header="Layout">
<controls:TreeViewItem Header="DockPanel"/>
<controls:TreeViewItem Header="WrapPanel"/>
<controls:TreeViewItem Header="Viewbox"/>
</controls:TreeViewItem>
<controls:TreeViewItem Header="Charting">
<controls:TreeViewItem Header="ColumnSeries"/>
<controls:TreeViewItem Header="LineSeries"/>
<controls:TreeViewItem Header="PieSeries"/>
</controls:TreeViewItem>
</controls:TreeView>
</layoutToolkit:AccordionItem>
<layoutToolkit:AccordionItem Content="item 2" Header="B - long header"/>
<system:String>regular string item 3</system:String>
</layoutToolkit:Accordion>
等待你宝贵的想法。 谢谢