wpf 中不带项目符号的列表的 listitem
我是 wpf 的新手,我有一个列表,就像
<FlowDocumentScrollViewer Name="fdsvList" Grid.Column="0" Grid.Row="2"
xmlns='http://schemas.microsoft.com/winfx/2006/xaml/presentation'
HorizontalAlignment="Center" VerticalAlignment="Center" VerticalScrollBarVisibility='Auto'>
<FlowDocument>
<List Name="lstButton">
<ListItem Margin="0 0 0 10" Name="lstItmCheck">
<Paragraph>
<Button Content="{DynamicResource Visa}" Name="btnVisa" Click="btnVisa_Click">
<Button.Template>
<ControlTemplate TargetType="Button">
<TextBlock TextDecorations="None">
<ContentPresenter />
</TextBlock>
</ControlTemplate>
</Button.Template>
<Button.Style>
<Style TargetType="Button">
<Setter Property="Foreground" Value="Black" />
<Setter Property="FontFamily" Value="Arial"></Setter>
<Setter Property="FontSize" Value="20"></Setter>
<Setter Property="FontWeight" Value="Bold"></Setter>
<Style.Triggers>
<Trigger Property="IsMouseOver" Value="true">
<Setter Property="Foreground" Value="Red" />
</Trigger>
</Style.Triggers>
</Style>
</Button.Style>
</Button>
</Paragraph>
</ListItem>
</List>
</FlowDocument>
</FlowDocumentScrollViewer>
它与项目符号列表一样显示。
但我不想在列表中添加项目符号,我只想要没有项目符号的简单按钮。
我该怎么办。请帮我。
i am new in wpf and i have a list as like
<FlowDocumentScrollViewer Name="fdsvList" Grid.Column="0" Grid.Row="2"
xmlns='http://schemas.microsoft.com/winfx/2006/xaml/presentation'
HorizontalAlignment="Center" VerticalAlignment="Center" VerticalScrollBarVisibility='Auto'>
<FlowDocument>
<List Name="lstButton">
<ListItem Margin="0 0 0 10" Name="lstItmCheck">
<Paragraph>
<Button Content="{DynamicResource Visa}" Name="btnVisa" Click="btnVisa_Click">
<Button.Template>
<ControlTemplate TargetType="Button">
<TextBlock TextDecorations="None">
<ContentPresenter />
</TextBlock>
</ControlTemplate>
</Button.Template>
<Button.Style>
<Style TargetType="Button">
<Setter Property="Foreground" Value="Black" />
<Setter Property="FontFamily" Value="Arial"></Setter>
<Setter Property="FontSize" Value="20"></Setter>
<Setter Property="FontWeight" Value="Bold"></Setter>
<Style.Triggers>
<Trigger Property="IsMouseOver" Value="true">
<Setter Property="Foreground" Value="Red" />
</Trigger>
</Style.Triggers>
</Style>
</Button.Style>
</Button>
</Paragraph>
</ListItem>
</List>
</FlowDocument>
</FlowDocumentScrollViewer>
it display with the bullet list.
but i don't want bullet in list, i just want simple button without bullet.
How can i do. please help me.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
像这样:
您也可以在设计器中通过属性面板执行此操作。
Like this:
You can also do this in the designer, via the properties panel.