尝试显示轮廓按钮,如 material design docs 中所述.我能做的最好的结果是一个简单的文本按钮(具有透明背景和无边框的文本)。我错过了什么?
<style name="PrimaryOutlinedButton" parent="Widget.MaterialComponents.Button.OutlinedButton">
<item name="android:strokeColor">@color/blue</item>
<item name="android:strokeWidth">4</item>
<item name="android:textSize">14sp</item>
</style>
最佳答案
查看源代码后,我认为您应该删除“android:”限定符,因为新 Material 参数在原始样式中不可用。
关于Android Stroke Around 来自 Style 的 Material Button,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53464050/