zoukankan      html  css  js  c++  java
  • 布局练习

    做一个如图所示的布局。

    <RelativeLayout
        xmlns:android="http://schemas.android.com/apk/res/android"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
         >
    
        <ImageView
            android:id="@+id/image_view"
            android:layout_width="56dp"
            android:layout_height="56dp"
            android:scaleType="centerCrop"
            android:src="@drawable/ocean" />
    
        <TextView
            android:id="@+id/Pebble_Beach_text_view"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="Pebble Beach"
            android:layout_toRightOf = "@id/image_view"
            android:textAppearance="?android:textAppearanceMedium" />
    
        <TextView
            android:id="@+id/california_text_view"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_below="@id/Pebble_Beach_text_view"
            android:layout_toRightOf="@id/image_view"
            android:text="California"
            android:textAppearance="?android:textAppearanceSmall" />
    
        <TextView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
                    android:layout_below="@id/california_text_view"
            android:layout_toRightOf="@id/image_view"
            android:text="10 miles away"
            android:textAppearance="?android:textAppearanceSmall" />
    
    </RelativeLayout>
    View Code
  • 相关阅读:
    Fire
    Apple Tree
    访问艺术馆
    三角关系
    字母表
    折纸
    旅行
    单词分类

    圆桌游戏
  • 原文地址:https://www.cnblogs.com/superxuezhazha/p/9410819.html
Copyright © 2011-2022 走看看