Created
September 29, 2016 19:25
-
-
Save vidia/ea22f5a7597e6e72c844b7fd6750d375 to your computer and use it in GitHub Desktop.
State of the tutorial XML for the TextView tutorial
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"?> | |
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:tools="http://schemas.android.com/tools" | |
android:id="@+id/activity_main" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
android:paddingBottom="@dimen/activity_vertical_margin" | |
android:paddingLeft="@dimen/activity_horizontal_margin" | |
android:paddingRight="@dimen/activity_horizontal_margin" | |
android:paddingTop="@dimen/activity_vertical_margin" | |
tools:context="edu.purdue.cs.sigapp.tutorialproject.MainActivity"> | |
<TextView | |
android:layout_width="wrap_content" | |
android:layout_height="wrap_content" | |
android:text="Hello World!" | |
android:layout_above="@+id/button" | |
android:layout_alignParentRight="true" | |
android:layout_alignParentEnd="true" | |
android:layout_alignParentTop="true" | |
android:layout_alignParentLeft="true" | |
android:layout_alignParentStart="true" /> | |
<Button | |
android:text="Button" | |
android:layout_width="wrap_content" | |
android:layout_height="wrap_content" | |
android:layout_alignParentBottom="true" | |
android:layout_alignParentRight="true" | |
android:layout_alignParentEnd="true" | |
android:onClick="onClick" | |
android:id="@+id/button" /> | |
<EditText | |
android:layout_width="wrap_content" | |
android:layout_height="wrap_content" | |
android:inputType="textPersonName" | |
android:text="Name" | |
android:ems="10" | |
android:layout_alignTop="@+id/button" | |
android:layout_alignParentLeft="true" | |
android:layout_alignParentStart="true" | |
android:id="@+id/editText" | |
android:layout_toLeftOf="@+id/button" | |
android:layout_toStartOf="@+id/button" /> | |
</RelativeLayout> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Note: On like #11 you need to change this to the package and name of your MainActivity or else it will be highlighted red.