Android 5.0以上Button去掉阴影

来源:互联网 发布:sql注入检测网站 编辑:程序博客网 时间:2024/05/22 22:12

1,在Button标签中直接添加以下属性

style=”?Android:attr/borderlessButtonStyle”

2,有的Button的属性已经抽成style,此时直接在style时添加上parent:

<style name="btn_right_angle_bg_text" parent="@style/Widget.AppCompat.Button.Borderless">    <item name="android:layout_width">match_parent</item>    <item name="android:layout_height">48dp</item>    <item name="android:background">@drawable/btn_right_angle_selector</item>    <item name="android:textSize">16sp</item>    <item name="android:textColor">@color/white</item></style>
0 0
原创粉丝点击