Main.xml
<?XML version= "1.0" encoding= "Utf-8"?><LinearLayoutxmlns:android= "Http://schemas.android.com/apk/res/android"android:orientation= "vertical"Android:layout_width= "Fill_parent"Android:layout_height= "Fill_parent" > <TextViewAndroid:layout_width= "Fill_parent"Android:layout_height= "Wrap_content"Android:text= "@string/hello" /> <!--hint indicates a message, and there is a hint in the input box - <!--Fill_paren Width extended to entire screen - <!--wrap_content height vs. font, wrapping font - <!--inputtype The input data type, at which point the phone number is entered - <!--background The shape settings of the input box, set the parameters to jump to the Drawable/shape settings - <EditTextAndroid:hint= "I am EditText"Android:layout_width= "Fill_parent"Android:layout_height= "Wrap_content"Android:inputtype= "Phone"Android:background= "@drawable/shape" /> </LinearLayout>
Shape.xml
<?XML version= "1.0" encoding= "UTF-8"?><Shapexmlns:android= "Http://schemas.android.com/apk/res/android"Android:shape= "Rectangle"> <!--the color of the fill - <SolidAndroid:color= "#FFFFFF" /> <!--sets the four corners of a rectangle to be curved - <!--Android:radius radius of Arc - <CornersAndroid:radius= "7dip" /></Shape>
Android EditText button