我想创建一个RatingBar
,它不使用图像来创建边框。但我似乎无法做到。如何在不使用图片的情况下应用RatingBar边框?
这里就是我想要它看起来像:
这就是我得到了(装满 - 一半是空 - 空):
这里是我的布局:
<RatingBar
android:id="@+id/ratingbar_rate"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:numStars="5"
android:rating="2.5"
android:stepSize="0.5"
android:scaleX="3.5"
android:scaleY="3.5"
style="?android:attr/ratingBarStyleIndicator"
android:isIndicator="false"
android:progressTint="@color/star"
android:progressBackgroundTint="@color/star_border"
android:secondaryProgressTint="@color/star_partially_empty"
android:backgroundTint="@color/star_partially_empty"
/>
问题解决了吗? – piotrek1543