Skip to content

Instantly share code, notes, and snippets.

@the-cybersapien
Created January 12, 2018 08:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save the-cybersapien/149f182ebe55576608b6f816e086eabd to your computer and use it in GitHub Desktop.
Save the-cybersapien/149f182ebe55576608b6f816e086eabd to your computer and use it in GitHub Desktop.
Activity Code
<?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="horizontal">
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
<TextView
android:id="@+id/scoreA"
android:text="5"
android:textSize="40sp"
android:layout_margin="20dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<Button
android:id="@+id/fivePointsA"
android:text="5 POINTS"
style="@style/Base.Widget.AppCompat.Button.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<Button
android:id="@+id/tenPointsA"
android:layout_width="wrap_content"
android:text="10 Points"
style="@style/Base.Widget.AppCompat.Button.Colored"
android:layout_height="wrap_content" />
<Button
android:id="@+id/twentyPointA"
android:layout_width="wrap_content"
android:text="20 Points"
style="@style/Base.Widget.AppCompat.Button.Colored"
android:layout_height="wrap_content" />
</LinearLayout>
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:orientation="vertical"
android:gravity="center"
android:layout_weight="1">
<TextView
android:id="@+id/scoreB"
android:text="5"
android:textSize="40sp"
android:layout_margin="20dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<Button
android:id="@+id/fivePointsB"
android:layout_width="wrap_content"
android:text="5 POINTS"
style="@style/Base.Widget.AppCompat.Button.Colored"
android:layout_height="wrap_content" />
<Button
android:id="@+id/tenPointsB"
android:layout_width="wrap_content"
android:text="10 POINTS"
style="@style/Base.Widget.AppCompat.Button.Colored"
android:layout_height="wrap_content" />
<Button
android:id="@+id/twentyPointB"
android:layout_width="wrap_content"
android:text="20 POINTS"
style="@style/Base.Widget.AppCompat.Button.Colored"
android:layout_height="wrap_content" />
</LinearLayout>
</LinearLayout>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment