墨迹天气-模仿主页面ui

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="fill_parent"
    android:orientation="vertical" >

    <RelativeLayout
        android:id="@+id/frameLayout1"
        android:layout_width="fill_parent"
        android:layout_height="40dp"
        android:background="#636363"
        android:gravity="fill"
        android:orientation="horizontal" >

        <ImageButton
            android:id="@+id/imageButton2"
            android:layout_width="wrap_content"
            android:layout_height="40dp"
            android:background="@drawable/title_city" />

        

        <ImageButton
            android:id="@+id/imageButton1"
            android:layout_width="wrap_content"
            android:layout_height="40dp"
            android:layout_alignParentRight="true"
            android:layout_alignParentTop="true"
            android:background="@drawable/title_update" />

        <ImageButton
            android:layout_width="wrap_content"
            android:layout_height="40dp"
            android:layout_alignParentTop="true"
            android:layout_toLeftOf="@+id/imageButton1"
            android:background="@drawable/title_voice" />

        <TextView
            android:layout_width="fill_parent"
            android:layout_height="40dp"
            android:layout_alignParentTop="true"
            android:gravity="center"
            android:layout_toRightOf="@+id/imageButton2"
            android:text="淮安"
            android:textSize="20dp" />

        <View
            android:layout_width="1dp"
            android:layout_height="40dp"
            android:layout_alignParentTop="true"
            android:layout_toLeftOf="@+id/imageButton1"
            android:background="#FFFFFF" />

        <View
            android:layout_width="1dp"
            android:layout_height="40dp"
            android:layout_alignParentTop="true"
            android:layout_toRightOf="@+id/imageButton2"
            android:background="#FFFFFF" />

    </RelativeLayout>

    <TextView
        android:id="@+id/textView1"
        android:layout_width="152dp"
        android:layout_height="wrap_content"
        android:layout_gravity="right" 
        android:textSize="100dp"
        android:text="5°"
        android:gravity="right"/>

 <LinearLayout 
     android:layout_width="match_parent"
        android:layout_height="fill_parent"
        android:orientation="horizontal"
         >
<LinearLayout 
     android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:orientation="vertical"
         android:layout_gravity="bottom">
     <TextView
         android:textColor="#454545"
         android:id="@+id/textView2"
         android:layout_width="wrap_content"
         android:layout_height="80dp"
         android:layout_gravity="bottom"
         android:layout_weight="1"
         android:text="晴\nxx度-xx度\n西北风n级\n" 
         android:textSize="20dp"/>

     <TextView
         android:textColor="#454545"
         android:id="@+id/textView3"
         android:layout_width="wrap_content"
         android:layout_height="80dp"
         android:layout_gravity="bottom"
         android:layout_weight="1"
         android:textSize="12dp" 
         android:text="02/13 壬辰年正月二十二\n北京市专业气象台14:15发布"/>
     
     </LinearLayout>
<LinearLayout android:layout_width="fill_parent"
        android:layout_height="wrap_content"
        android:orientation="vertical"
        >
      <Button android:layout_width="fill_parent"
         android:layout_height="wrap_content"
         android:background="#30FFFFFF"
         android:text="周二\nxx℃/xx℃"
         android:drawableRight="@drawable/w0"
         android:layout_marginTop="0dp"></Button>
      <Button android:layout_width="fill_parent"
         android:layout_height="wrap_content"
         android:background="#30FFFFFF"
         android:text="周三\nxx℃/xx℃"
         android:drawableRight="@drawable/w1"
         android:layout_marginTop="5dp"></Button>
       <Button android:layout_width="fill_parent"
         android:layout_height="wrap_content"
         android:background="#30FFFFFF"
         android:text="周四\nxx℃/xx℃"
         android:drawableRight="@drawable/w2"
         android:layout_marginTop="5dp"></Button>
       <Button android:layout_width="fill_parent"
         android:layout_height="wrap_content"
         android:background="#30FFFFFF"
         android:text="周五\nxx℃/xx℃"
         android:drawableRight="@drawable/w3"
         android:layout_marginTop="5dp"
         android:layout_marginBottom="5dp"></Button>
       </LinearLayout>
       </LinearLayout>

</LinearLayout>

闲着无聊

就模仿写了下墨迹天气的主页面ui

上效果图:



上部分核心代码如上所示



Jave作品,转载请注明转载处:http://blog.csdn.net/jave_/article/details/7256746

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值