-
-
Save codingwithsara/ce4db0c3fb97341c962c230ad5dcdd09 to your computer and use it in GitHub Desktop.
Custom Toast
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"?> | |
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
android:orientation="vertical" | |
android:gravity="center_horizontal" | |
android:background="@color/colorPrimary" | |
android:paddingVertical="14dp" | |
android:paddingHorizontal="26dp"> | |
<TextView | |
android:layout_width="wrap_content" | |
android:layout_height="wrap_content" | |
android:text="Custom Toast" | |
android:textSize="20sp" | |
android:textColor="@android:color/white"/> | |
<LinearLayout | |
android:layout_width="wrap_content" | |
android:layout_height="wrap_content" | |
android:gravity="center_vertical" | |
android:layout_marginTop="20dp"> | |
<ImageView | |
android:layout_width="wrap_content" | |
android:layout_height="wrap_content" | |
android:src="@android:mipmap/sym_def_app_icon"/> | |
<TextView | |
android:id="@+id/msg" | |
android:layout_width="wrap_content" | |
android:layout_height="wrap_content" | |
android:text="Message" | |
android:textSize="24sp" | |
android:textColor="@android:color/white" | |
android:layout_marginLeft="10dp"/> | |
</LinearLayout> | |
</LinearLayout> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment