Created
September 18, 2019 19:40
-
-
Save isabellatea/1518f074a0120ee4341cf5ed3a3e5a79 to your computer and use it in GitHub Desktop.
Linear Layout: Nested (Example)
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
<LinearLayout | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
android:orientation="vertical" > | |
<TextView | |
android:text="Ocean Guide " | |
android:layout_width="wrap_content" | |
android:layout_height="wrap_content" | |
android:textSize="50sp" | |
android:gravity="center" | |
android:fontFamily="sans-serif-light" | |
android:textColor="@android:color/white" | |
android:background="#000000" | |
android:padding="20dp" | |
android:layout_marginTop="12dp" | |
android:layout_marginBottom="12dp"/> | |
<TextView | |
android:text="⚠️ Log In to for even more content!" | |
android:layout_width="wrap_content" | |
android:layout_height="wrap_content" | |
android:textSize="22sp" | |
android:fontFamily="sans-serif-light" | |
android:textColor="@android:color/white" | |
android:background="#2DABC8" | |
android:padding="10dp"/> | |
<LinearLayout | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
android:orientation="horizontal" | |
android:layout_marginTop="40dp" > | |
<ImageView | |
android:id="@+id/photo_image_view" | |
android:layout_width="200dp" | |
android:layout_height="match_parent" | |
android:scaleType="center" | |
android:layout_margin="12dp" | |
android:src="@drawable/ocean" /> | |
<ImageView | |
android:id="@+id/photo_image_view" | |
android:layout_width="200dp" | |
android:layout_height="match_parent" | |
android:scaleType="center" | |
android:layout_margin="12dp" | |
android:src="@drawable/fish" /> | |
</LinearLayout> | |
<LinearLayout | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
android:orientation="horizontal" | |
android:layout_marginTop="60dp" > | |
<Button | |
android:id="@+id/sign_up" | |
android:layout_width="120dp" | |
android:layout_height="wrap_content" | |
android:background="#000000" | |
android:textSize="20sp" | |
android:textColor="@android:color/white" | |
android:gravity="center" | |
android:padding="10dp" | |
android:layout_marginRight="20dp" | |
android:layout_marginLeft="50dp" | |
android:text="Sign Up" /> | |
<Button | |
android:id="@+id/next_button" | |
android:layout_width="120dp" | |
android:layout_height="wrap_content" | |
android:background="#000000" | |
android:textSize="20sp" | |
android:textColor="@android:color/white" | |
android:gravity="center" | |
android:padding="10dp" | |
android:text="Log In" /> | |
</LinearLayout> | |
</LinearLayout> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment