WPF Button去除按钮边框,添加下划线

XML 复制代码
        <Button Width="45" Height="25" FontSize="20" Background="Transparent" BorderBrush="Transparent" Foreground="#FFC9A322" Click="Btn_Retry_Click" >
            <TextBlock>
                 <Underline>重试</Underline>
            </TextBlock>
        </Button>

去除按钮边框: BorderBrush="Transparent" (边框颜色设置为透明)

去掉按钮背景:Background="Transparent"(背景颜色设置为透明)

Content添加下划线:Button 标签内添加 TextBlock 文本标签,通过使用Underline来实现下划线功能

相关推荐
碎碎念的安静4 小时前
WPF可拖拽ListView
c#·wpf
界面开发小八哥11 小时前
界面组件DevExpress WPF中文教程:Grid - 如何识别行和卡片?
.net·wpf·界面控件·devexpress·ui开发
TwilightLemon2 天前
WPF 使用CompositionTarget.Rendering实现平滑流畅滚动的ScrollViewer,支持滚轮、触控板、触摸屏和笔
wpf
Vae_Mars3 天前
WPF中自定义消息弹窗
wpf
Magnum Lehar3 天前
GameEngine游戏引擎前端界面wpf页面实现
前端·游戏引擎·wpf
TA远方4 天前
【C#】一个简单的http服务器项目开发过程详解
服务器·http·c#·wpf·web·winform·console
陈奕昆4 天前
2.1HarmonyOS NEXT开发工具链进阶:DevEco Studio深度实践
华为·wpf·harmonyos
Dr.多喝热水4 天前
WPF prism
windows·wpf
Hare_bai5 天前
WPF响应式UI的基础:INotifyPropertyChanged
ui·c#·wpf·xaml
上元星如雨5 天前
WPF 全局加载界面、多界面实现渐变过渡效果
wpf