android 布局一种好看的高亮布局
来源:互联网 发布:数据库接口类型有哪些 编辑:程序博客网 时间:2024/05/01 19:51
高亮设定
<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/bg_color">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="10dp"
android:orientation="vertical" >
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/bg_more_button"
android:clickable="true"
android:padding="10dp" >
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="10dp"
android:text="@string/luyin"
android:textColor="@color/text_color"
android:textSize="@dimen/textsize16" />
<Switch
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/can_record"
android:textOff="@string/luyinclose"
android:textOn="@string/luyinstart"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
/>
</RelativeLayout>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/bg_more_button"
android:layout_marginTop="10dp"
android:clickable="true"
android:padding="10dp" >
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="10dp"
android:text="@string/luyinshangchuan"
android:textColor="@color/text_color"
android:textSize="@dimen/textsize16" />
<Switch
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/up_record"
android:textOff="@string/luyinclose"
android:textOn="@string/luyinstart"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
/>
</RelativeLayout>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/bg_more_button"
android:layout_marginTop="10dp"
android:clickable="true"
android:padding="10dp" >
<EditText
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="4dp"
android:hint="192.168.0.181"
android:id="@+id/ipPort"
android:textColor="@color/text_color"
android:textSize="@dimen/textsize16" />
<Switch
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/ipSure"
android:textOff="@string/ipport1"
android:textOn="@string/ipport2"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
/>
</RelativeLayout>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/bg_more_button"
android:layout_marginTop="10dp"
android:clickable="true"
android:padding="10dp" >
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="10dp"
android:text="@string/saveposition"
android:id="@+id/stragePos"
android:textColor="@color/text_color"
android:textSize="@dimen/textsize16" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_toRightOf="@+id/stragePos"
android:layout_marginLeft="4dp"
android:id="@+id/recordPath"
android:textColor="@color/text_color"
android:textSize="@dimen/textsize16" />
<Switch
android:layout_width="2dp"
android:layout_height="2dp"
android:id="@+id/sdcardOption"
android:textOff="@string/storage1"
android:textOn="@string/storage2"
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
/>
</RelativeLayout>
</LinearLayout>
</ScrollView>
// 对应的背景 android:background="@drawable/bg_more_button"
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android"><item android:state_pressed="true"><shape>
<gradient android:angle="270" android:endColor="#cfcfcf" android:startColor="#cfcfcf" />
<stroke android:width="1dp" android:color="#cfcfcf" />
<corners android:bottomLeftRadius="0dp" android:bottomRightRadius="0dp" />
</shape></item>
<item android:state_focused="true"><shape>
<gradient android:angle="270" android:endColor="#cfcfcf" android:startColor="#cfcfcf" />
<stroke android:width="1dp" android:color="#cfcfcf" />
<corners android:bottomLeftRadius="0dp" android:bottomRightRadius="0dp" />
</shape></item>
<item><shape>
<gradient android:angle="270" android:endColor="#ffffff" android:startColor="#ffffff" />
<stroke android:width="1dp" android:color="#d0d0d0" />
<corners android:bottomLeftRadius="0dp" android:bottomRightRadius="0dp" />
s </shape></item>
</selector>
- android 布局一种好看的高亮布局
- 好看的网站布局
- 好看的网站布局2
- 好看的网站布局3
- 好看的网站布局4
- 好看的网站布局5
- Android高性能的布局
- android一种较为复杂的布局
- android一种较为复杂的布局
- Android 自适应的一种布局,weight
- SXPhotoShow三种好看的布局
- android高亮布局引导Hlight
- 一种新的布局方式
- android一种较为复杂的布局参考(xml文件)
- android一种较为复杂的布局参考(xml文件)
- 40个布局排版好看的网页设计作品
- 40个布局排版好看的网页设计作品
- 如何写出布局好看而且漂亮的博客
- LeetCode 401 Binary Watch (状态压缩)
- 友盟sdk2.6升级到友盟3.0.1遇到的坑,最后解决问题
- 第四周项目1-建立单链表
- 第四周--单链表的应用
- 第四周【项目三-单链表应用(1)节点逆置】
- android 布局一种好看的高亮布局
- 【第四周项目2-建设“单链表”算法库】
- AS内开发NDK
- 自定义QTP执行日志
- Linux常用命令大全
- 第4周项目1-建立单链表
- AndroidStudio debug调试!
- BigDecimal 和 RoundingMode 相关备注
- llinux根文件系统/etc/passwd文件详解