下面的代码运行良好,但ScrollBar
即使TextBlock
. 我该如何启用它?
<UserControl.DataContext>
<viewModels:CommentsViewModel/>
</UserControl.DataContext>
<Grid>
<DockPanel >
<TreeView DockPanel.Dock="Top"/>
<Expander Header="Yo" DockPanel.Dock="Bottom" VerticalAlignment="Bottom">
<ScrollViewer HorizontalScrollBarVisibility="Disabled">
<TextBlock TextWrapping="Wrap" MaxHeight="250"
Text="{Binding Article.Article.Content}"/>
</ScrollViewer>
</Expander>
</DockPanel>
</Grid>