我正在尝试在StackPanel中插入按钮列表 但是我想隐藏包装内容而不是正确,因为它正在进行中
这是我的代码xaml
<StackPanel Orientation="Horizontal" >
<Button Width="50">1.5678</Button>
<Button Width="50">1.5678</Button>
<Button Width="50">1.5678</Button>
<Button Width="50">1.5678</Button>
<Button Width="50">1.5678</Button>
<Button Width="50">1.5678</Button>
<Button Width="50">1.5678</Button>
<TextBox x:Name="EDT_NUMERO_CFOP" Style="{StaticResource TextBoxNoBorder}" Height="30"></TextBox>
</StackPanel>
我认为有类似“hideToLeft”的东西
答案 0 :(得分:1)
使用 FlowDirection属性= RightToLeft
将 StackPanel 包裹在 ScrollViewer 中 <ScrollViewer CanContentScroll="True" FlowDirection="RightToLeft">
<StackPanel Orientation="Horizontal" Margin="0,0,6,6.5" >
<Button Width="50">1.5678</Button>
<Button Width="50">1.5678</Button>
<Button Width="50">1.5678</Button>
<Button Width="50">1.5678</Button>
<Button Width="50">1.5678</Button>
<Button Width="50">1.5678</Button>
<Button Width="50">1.5678</Button>
<TextBox x:Name="EDT_NUMERO_CFOP" Style="{StaticResource TextBoxNoBorder}" Height="30"></TextBox>
</StackPanel>
</ScrollViewer>