美文网首页UI
android shapeableimageview的使用

android shapeableimageview的使用

作者: hao_developer | 来源:发表于2021-06-25 10:00 被阅读0次

效果


image.png

依赖

implementation 'com.google.android.material:material:1.2.1'
image.png
<com.google.android.material.imageview.ShapeableImageView

    android:layout_width="wrap_content"

    android:layout_height="wrap_content"

    android:layout_margin="10dp"

    android:src="@mipmap/ic_avatar" />

<!--ShapeableImageView 圆角-->

<style name="RoundedStyle">

    <item name="cornerFamily">rounded</item>

    <item name="cornerSize">10dp</item>

</style>

属性

关于xml属性,我也做了一个整理,属性不多,只有4个。

image.png
这位好友的总结(https://www.jianshu.com/p/19e3c3b77e93)

相关文章

网友评论

    本文标题:android shapeableimageview的使用

    本文链接:https://www.haomeiwen.com/subject/eobnyltx.html