radioButton的简单使用
<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"
tools:context="com.example.homework05.MainActivity" > <RelativeLayout
android:layout_width="fill_parent"
android:layout_height="50dp">
<!-- 城市 -->
<!-- drawableLeft:在文字左边设置图标 -->
<TextView
android:id="@+id/city"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:drawableLeft="@drawable/city"
android:text="北京"
android:gravity="center"/>
<!-- 扫一扫 -->
<!-- android:adjustViewBounds="true" 是否调整自己的边界来保 持所显示图片的长宽比-->
<ImageView
android:id="@+id/image_scan"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:src="@drawable/codescan"
android:layout_alignParentRight="true"
android:adjustViewBounds="true"/>
<!-- 搜索编辑框 -->
<EditText
android:id="@+id/edit"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:hint="请输入。。。"
android:layout_toRightOf="@id/city"
android:layout_toLeftOf="@id/image_scan"/>
<!-- 搜索图标-->
<ImageView
android:id="@+id/image_search"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:src="@drawable/home_search_icon"
android:layout_alignRight="@id/edit"
android:layout_centerVertical="true"/>
</RelativeLayout>
<!-- 右下角的购物车 -->
<ImageView
android:id="@+id/image_buy"
android:layout_width="80dp"
android:layout_height="80dp"
android:src="@drawable/buy"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"/>
<!-- 下面的标签选项 -->
<!-- android:button="@null"不显示单选按钮的圆圈 -->
<RadioGroup
android:id="@+id/group"
android:layout_width="match_parent"
android:layout_height="50dp"
android:layout_alignParentBottom="true"
android:layout_toLeftOf="@id/image_buy"
android:weightSum="4"
android:orientation="horizontal">
<RadioButton
android:id="@+id/btn_home"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:text="首页"
android:gravity="center"
android:button="@null"
android:checked="true"
android:drawableTop="@drawable/select_home"
/>
<RadioButton
android:id="@+id/btn_person"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:text="分类"
android:gravity="center"
android:button="@null"
android:drawableTop="@drawable/select_person"
/>
<RadioButton
android:id="@+id/btn_new"
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="match_parent"
android:text="新品"
android:gravity="center"
android:button="@null"
android:drawableTop="@drawable/select_new"
/>
<RadioButton
android:id="@+id/btn_search"
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="match_parent"
android:text="搜索"
android:gravity="center"
android:button="@null"
android:drawableTop="@drawable/select_search"
/>
</RadioGroup> </RelativeLayout>

radioButton的简单使用的更多相关文章
- viewpage+RadioButton+Fragment简单导航界面
https://blog.csdn.net/qibanxuehua/article/details/47333879
- (转载)SPRINGMVC表单标签简介
SpringMVC表单标签简介 在使用SpringMVC的时候我们可以使用Spring封装的一系列表单标签,这些标签都可以访问到ModelMap中的内容.下面将对这些标签一一介绍. 在正式介绍Spri ...
- SpringMVC表单标签简介
在使用SpringMVC的时候我们可以使用Spring封装的一系列表单标签,这些标签都可以访问到ModelMap中的内容.下面将对这些标签一一介绍. 在正式介绍SpringMVC的表单标签之前,我们需 ...
- SpringMVC框架(三)from标签(转)
原文地址:http://blog.csdn.net/kutim/article/details/46682547 spring表单标签 <%@taglib uri="http:// ...
- [Aaronyang] 写给自己的WPF4.5 笔记5[数据绑定三巴掌1/3]
生活总有意外,微笑对待每一件事,无需抱怨--Aaronyang的博客(www.ayjs.net) 博文摘要:数据库下载 教你如何在vs2013中不安装Mssql数据库,使用了Sqlserver Com ...
- [转]SpringMVC<from:form>表单标签和<input>表单标签简介
原文地址:https://blog.csdn.net/hp_yangpeng/article/details/51906654 在使用SpringMVC的时候我们可以使用Spring封装的一系列表单标 ...
- SpringMVC框架 之 from标签(转)
原文地址:http://blog.csdn.net/kutim/article/details/46682547 spring表单标签 <%@taglib uri="http:// ...
- SpringMVC学习记录(五)--表单标签
在使用SpringMVC的时候我们能够使用Spring封装的一系列表单标签,这些标签都能够訪问到ModelMap中的内容. 以下将对这些标签一一介绍. 1.引入标签头文件 在正式介绍SpringMVC ...
- Spring MVC框架及标签库
1.Spring MVC技术 1. 当DispatcherServlet接到请求时,他先回查找适当的处理程序来处理请求.DispatcherServlet通过一个或者多个处理程序映射,将每个请求映射到 ...
随机推荐
- libvlc 双击,鼠标事件消息响应
基于vlc 2.1 动态库实现接收双击消息的接收,使双击vlc播放画面可以全屏显示. 需要其他版本的vlc可以与我联系(有偿进行修改) 下载地址:http://download.csdn.net/de ...
- c#语言-多线程中的锁系统(一)
介绍 平常在多线程开发中,总避免不了线程同步.本篇就对net多线程中的锁系统做个简单描述. 目录 一:lock.Monitor 1:基础. 2: 作用域. ...
- c#调用c++动态库的一些理解
调用c++动态库一般我们这样写 [DllImport("UCamer.dll", CallingConvention = CallingConvention.Winapi)] ...
- memcached SASL验证状态安全绕过漏洞
漏洞版本: memcached 1.x 漏洞描述: Memcached是一个高性能的分布式内存对象缓存系统,用于动态Web应用以减轻数据库负载. Memcached在处理链接的SASL验证状态时存在错 ...
- Deep Learning Overview
[Ref: http://en.wikipedia.org/wiki/Deep_learning] Definition: a branch of machine learning based on ...
- SharePoint 2010 PowerShell 系列 之 备份、还原、部署 .WSP
转:http://www.cnblogs.com/Fengger/archive/2012/08/24/2654093.html PowerShell系列目录 最近在部署测试环境,就顺便把PowerS ...
- 终极秘籍教你怎么找回被盗iPhone 查询ICCID
iPhone不慎丢失后怎么办?普通青年:立刻报警,基本没用.文艺青年:用Find my iPhone查找位置.但那只是个大概位置,iPhone关机后更是没戏,接着是用iCloud锁定手机,发送警告信息 ...
- 深入理解OAuth2.0
1. 引言 如果你开车去酒店赴宴,你经常会苦于找不到停车位而耽误很多时间.是否有好办法可以避免这个问题呢?有的,听说有一些豪车的车主就不担心这个问题.豪车一般配备两种钥匙:主钥匙和泊车钥匙.当你到酒店 ...
- Mvc自定义分页控件
MVC开发分页常常使用第三方控件,生成的分页HTML带有版权申明,虽然免费,但是总有的别扭.于是,某日,楼主闲来蛋疼,折腾了个自定义分页控件: 先来展示下效果图: 1>当分页不超过10页的时候, ...
- HDU5668 Circle 非互质中国剩余定理
分析:考虑对给定的出圈序列进行一次模拟,对于出圈的人我们显然可以由位置,编号等关系得到一个同余方程 一圈做下来我们就得到了n个同余方程 对每个方程用扩展欧几里得求解,最后找到最小可行解就是答案. 当然 ...