各种布局layout

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width
="fill_parent"
    android:layout_height
="fill_parent"
    android:orientation
="vertical" >
    <TextView
        
android:layout_width="fill_parent"
        android:layout_height
="wrap_content"
        android:text
="@string/hello" />
    
  
      <RelativeLayout
        
android:layout_width="fill_parent"
        android:layout_height
="wrap_content"  >    
        
        <TextView
        
android:id="@+id/textView1"
        android:layout_width
="100dp"
        android:layout_height
="wrap_content"
        android:text
="@string/plaseInputPhoneNumber" />
        <EditText
            
android:id="@+id/editText1"
            android:layout_width
="match_parent"
            android:layout_height
="wrap_content" 
            android:layout_toRightOf
="@id/textView1"
            android:layout_alignTop
="@id/textView1"
            android:layout_marginLeft
="5dp"
            
>            
        </EditText>
     </RelativeLayout>   
    <TextView
        
android:id="@+id/textView2"
        android:layout_width
="wrap_content"
        android:layout_height
="wrap_content"
        android:text
="@string/plaseInputSMS" />
    <EditText
        
android:id="@+id/editText2"
        android:layout_width
="match_parent"
        android:layout_height
="wrap_content" />
    <TableLayout
        
android:layout_width="fill_parent"
        android:layout_height
="wrap_content" 
        
>
        <TableRow>
         <Button
             
android:id="@+id/button1"
             android:layout_width
="wrap_content"
             android:layout_height
="wrap_content"
             android:text
="@string/Button" />
    
         <Button
             
android:id="@+id/button2"
             android:layout_width
="wrap_content"
             android:layout_height
="wrap_content"
             android:text
="@string/Button1" />
         </TableRow>
     </TableLayout>
     <FrameLayout 
          
android:layout_width="fill_parent"
        android:layout_height
="wrap_content" 
         
>
         <ImageView 
              
android:layout_width="fill_parent"
            android:layout_height
="fill_parent" 
            android:src
="@drawable/move"
             
/>
          <ImageView 
              
android:layout_width="fill_parent"
            android:layout_height
="wrap_content" 
            android:src
="@drawable/btn"
            android:layout_gravity
="center"
             
/>
         
     </FrameLayout>
</LinearLayout>

---上面代码实现的界面 

 

 

 

posted @ 2012-07-25 00:03  kuailewangzi1212  阅读(193)  评论(0编辑  收藏  举报