android - ShapeableImageView 的笔画被边框切割
问题描述
我在这里有一个 ShapeableImageView,笔画为 5dp:
<com.google.android.material.imageview.ShapeableImageView
android:id="@+id/profile_picture"
android:layout_width="100dp"
android:layout_height="100dp"
android:layout_marginTop="20dp"
android:scaleType="centerCrop"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@id/profile_toolbar"
app:shapeAppearanceOverlay="@style/circular"
app:strokeColor="@color/dark_blue"
app:strokeWidth="5dp" />
这是结果:
解决方案
我一直在尝试一些东西,最后,在视图中添加填充解决了问题
推荐阅读
- c# - Apache Ignite .NET 客户端靠近缓存
- javascript - HTML-JS:大量按钮,每个按钮产生不同的形式
- excel - VBA 需要以特定顺序使用多个值和多列将多行从一个工作表移动到另一个工作表
- c# - 正则表达式完全匹配特定字符的 1 个
- cassandra-2.0 - 如何在 Cassandra 中强制设置表的非分区字段
- sql - 为什么在 phpmyadmin 中重命名表时出现错误 #1054
- performance - 计算加速
- angular - 如何以角度显示过滤的对象列表?
- python - 如何识别字符串的最小形式?
- unity3d - 无法使用“屏幕空间叠加”在画布中获取对象的真实位置