Android Xi. landing Page analysis

Source: Internet
Author: User

Android Xi. landing page Analysis
second, the layout of the login interface analysis
1, Login.xml
STEP1: First establish drawable folder, create Logintopbg_roundcorner.xml
<?xml version= "1.0" encoding= "Utf-8"? ><shape xmlns:android= "Http://schemas.android.com/apk/res/android" >    <solid  android:color= "#55ffffff"/><corners android:radius= "15DP"/></shape>
STEP2: Create Btn_select.xml
<?xml version= "1.0" encoding= "Utf-8"? ><selector xmlns:android= "http://schemas.android.com/apk/res/ Android ">    <item android:drawable=" @drawable/btn_shape "android:state_pressed=" false "></item>     <item android:drawable= "@drawable/btn_shape_after" android:state_pressed= "true" ></item></ Selector>
where the Btn_shape.xml file and the Btn_shape_after.xml file are as follows
Btn_shape.xml
<?xml version= "1.0" encoding= "Utf-8"? ><shape xmlns:android= "Http://schemas.android.com/apk/res/android" >    <solid android:color= "#ff72CAE1"/>    <corners android:radius= "10DP"/></shape>
Btn_shape_after.xml
<?xml version= "1.0" encoding= "Utf-8"? ><shape xmlns:android= "Http://schemas.android.com/apk/res/android" >        <solid android:color= "#87cefa"/>    <corners android:radius= "10DP"/></shape>
Step3: Define the Login_tio.xml file with the following layout
<?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:layout_width=" Match_parent "android:background=" @drawable/logintopbg_roundcorner "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=".        Loginactivity "><edittext android:id=" @+id/tdname "android:drawableleft=" @drawable/icons_user_img " Android:layout_width= "Match_parent" android:layout_height= "Wrap_content" Android:layout_alignparentleft = "true" android:layout_alignparenttop= "true" android:ems= "android:background=" @android:d rawable/e Dit_text "android:drawablepadding=" 10DP "Android:hint= "@string/etname"/><edittext android:id= "@+id/tdpassword" android:layout_width= "Match_parent" Andro id:layout_height= "Wrap_content" android:layout_alignparenttop= "true" android:layout_centerhorizontal= "true" Andro id:layout_margintop= "62DP" android:background= "@android:d rawable/edit_text" android:drawableleft= "@drawable/ Icons_password_img "android:drawablepadding=" 10DP "android:hint=" @string/etpassword "android:ems="/><Li Nearlayout android:layout_width= "match_parent" android:layout_height= "50DP" android:layout_below= "@id/tdpasswor D "> <button android:id=" @+id/button1 "android:layout_width=" 50DP "android:layout_height= "50DP" android:layout_weight= "1" android:background= "@drawable/btn_select" android:text= "@string/btnl Ogin "/> <button android:id=" @+id/button2 "android:layout_width=" 50DP "android:layout_height = "50DP" Android:background= "@drawable/btn_select" android:layout_weight= "1" android:layout_marginleft= "5DP" android:text= "@st Ring/btnregister "/> </LinearLayout></RelativeLayout>

activity_main.xml
<span style= "FONT-SIZE:18PX;" ><relativelayout xmlns:android= "http://schemas.android.com/apk/res/android" xmlns:tools= "http// Schemas.android.com/tools "android:layout_width=" match_parent "android:layout_height=" Match_parent "android:backg round= "@drawable/btn_shape" tools:context= ".        Mainactivity "> <imageview android:id=" @+id/imageview1 "android:layout_width=" Wrap_content " android:layout_height= "Wrap_content" android:layout_alignparentbottom= "true" android:layout_alignparentright = "true" android:layout_marginbottom= "34DP" android:layout_marginright= "27DP" android:src= "@drawable/M OnKey "/> <linearlayout android:id=" @+id/tt "android:layout_width=" Wrap_content "Android:lay out_height= "Wrap_content" > </LinearLayout> <textview android:id= "@+id/textview1" android:l Ayout_width= "80DP" android:layout_height= "30DP" Android:layout_alignpaRentright= "true" android:layout_centervertical= "true" android:text= "@string/etpassword2"/> <includ        E android:id= "@+id/include1" android:layout_width= "294DP" android:layout_height= "Wrap_content" Android:layout_alignparenttop= "true" android:layout_centerhorizontal= "true" layout= "@layout/login_top"/&gt ;</relativelayout></span>


Android Xi. landing Page analysis

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.