Created
July 22, 2013 02:52
-
-
Save eveliotc/6051035 to your computer and use it in GitHub Desktop.
A sample of a bad way of doing rounded avatars
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<!-- From post http://evel.io/2013/07/21/rounded-avatars-in-android/ --> | |
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent"> | |
<FrameLayout | |
android:layout_width="wrap_content" | |
android:layout_height="wrap_content" | |
android:layout_gravity="center" | |
android:foreground="@drawable/overlay" | |
android:foregroundGravity="center" | |
> | |
<ImageView | |
android:layout_width="wrap_content" | |
android:layout_height="wrap_content" | |
android:layout_gravity="center" | |
android:src="@drawable/avatar" | |
/> | |
</FrameLayout> | |
</FrameLayout> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment