我想要一个WPF扩展器控件,其中标头与主内容区域重叠.
使用以下XAML
<Expander Header="Details" ExpandDirection="Left">
<Grid Background="Blue">
<TextBlock Text="Details content" VerticalAlignment="Center" HorizontalAlignment="Center" Margin="5" Foreground="White"></TextBlock>
</Grid>
</Expander>
<ScrollViewer Background="Red" HorizontalScrollBarVisibility="Visible" Grid.Column="1">
<Grid Background="Red">
<TextBlock Text="Main content" VerticalAlignment="Center" HorizontalAlignment="Center" Foreground="White" />
</Grid>
</ScrollViewer>
Run Code Online (Sandbox Code Playgroud)
我最终得到:
我想删除白色区域并在内容区域的左上角有箭头,与红色背景重叠.maps.bing.com就是一个类似的例子.