When using Theme.MaterialComponents.Light.NoActionBar style, setting Button Background has no effect

前端 未结 2 1246
自闭症患者
自闭症患者 2021-02-01 02:39

In order to use Chip and ChipGroup, I set Application style extends Theme.MaterialComponents.Light.NoActionBar int manifests.xml, then I set Button \"android:backg

2条回答
  •  礼貌的吻别
    2021-02-01 03:25

    If you want a true Button, but one that you can modify like the framework Button (instead of the MaterialButton), then you can explicitly specify the framework version in your layout file. Replace this:

    with this:

    
    

    This will give you what it says on the tin: an android.widget.Button, which should respond to styling the way you expect.

    Similarly, you could use a if you want support library features but not material components features.

提交回复
热议问题