Customizing RatingBar
shows me shadow
How to hide this shadow ?
<RatingBar
android:id="@+id/ratingBarMain"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/textView6"
android:layout_toRightOf="@+id/imgThumbFix"
android:clickable="false"
android:progressDrawable="@drawable/ratingbar_red_small"
android:stepSize="1" />
set
android:layout_height="EQUAL_TO_IMAGE_HEIGHT"
example
android:layout_height="35dp"
Adil Soomro
The problem here is:
It is repeating the last bit line of the image if the height of your View is 50 px and the height of image is 40 px, then for rest of the 10 px it will be filled by repeating the last bit of your image.
You have to give the exact height equals to your image height to RatingBar.
android:layout_height="40dp"
Same problem was solved here
Another simple solution woud be to leave a row of empty pixels in the star image using an image editor like photoshop. Then the repeated or stretched row of pixels in the ratingbar would be empty. This aproach solved my issue.
来源:https://stackoverflow.com/questions/11430367/hide-shadow-of-rating-bar