Android Layout 01_activity_Login.xml
activity_login.xml
<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"
android:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
tools:context=".MainActivity" > <TextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:text="账户:" />
<EditText
android:id="@+id/et_loginname"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_toRightOf="@id/textView1"
android:hint="登录名"
android:ems="10" >
<requestFocus />
</EditText>
<TextView
android:id="@+id/textView2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@id/et_loginname"
android:text="密码:" />
<EditText
android:id="@+id/et_loginpwd"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/et_loginname"
android:layout_toRightOf="@id/textView2"
android:layout_marginLeft="8dp"
android:hint="账户密码"
android:ems="10"
android:inputType="numberPassword" />
<Button
android:id="@+id/button2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="8dp"
android:layout_below="@id/et_loginpwd"
android:layout_alignParentRight="true"
android:text="重置" />
<Button
android:id="@+id/button1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@id/et_loginpwd"
android:layout_toLeftOf="@id/button2"
android:onClick="login"
android:text="确定" /> </RelativeLayout>
Android Layout 01_activity_Login.xml的更多相关文章
- Android layout的XML
[注]此文是在学习andriod中的一些理解和总结,若有错望留言指教,谢谢 1 <RelativeLayout xmlns:android="http://schemas.androi ...
- Android--应用开发3(Android layout XML属性)
Android layout XML属性 转载:http://www.cnblogs.com/playing/archive/2011/04/07/2008620.html Layout对于迅速的搭建 ...
- android获取string.xml的值(转)
为什么需要把应用中出现的文字单独存放在string.xml文件中呢? 一:是为了国际化,当需要国际化时,只需要再提供一个string.xml文件,把里面的汉子信息都修改为对应的语言(如,English ...
- Android性能优化xml之<include>、<merge>、<ViewStub>标签的使用
一.使用<include>标签对"重复代码"进行复用 <include>标签是我们进行Android开发中经常用到的标签,比如多个界面都同样用到了一个左侧筛 ...
- android获取string.xml的值
在android开发过程中,编写java代码中的常量过一般情况下,我们是定义在string.xml这个文件中.这样修改起来也很方便,而且做国际化也很简单. 这个string.xml的值会被R文件映射, ...
- Android Studio “懒人”必备插件android layout id converter
在一个布局文件里.假设定义了非常多非常多id,代码中一个个findview是一件非常枯燥而且浪费时间的事情. 所以这里向大家推荐一个必备插件android layout id converter. 配 ...
- Android 如何在xmL 里面动态设置padding
如题,Android 如何在xmL 里面动态设置padding 有时候,你的布局加载完成之后,你findViewByid 找到控件,设置padding 会导致白条,布局闪动,那怎么办呢? 你是不是就想 ...
- android学习——Android Layout标签之-viewStub,requestFocus,merge,include
定义Android Layout(XML)时,有四个比较特别的标签是非常重要的,其中有三个是与资源复用有关,分别是<viewStub/>, <requestFocus />, ...
- [转载]关于android SDK安装Failed to fetch URL http://dl-ssl.google.com/android/repository/addons_list-1.xml出错
原文地址为:http://blog.csdn.net/springsky_/article/details/7442388 因为入行移动测试,所以很多测试环境的搭建.从中遇到了和这个GG同样的问题.怕 ...
随机推荐
- _variant_t与其他数据类型的转换
转自:http://kuaixingdong.blog.hexun.com/29627840_d.html 我们先看看COM所支持的一些类型的基本类: (微软提供,在comdef.h中定义) 在COM ...
- Vivado级联Modelsim仿真Re-launch问题
前两天在群里看到有朋友说Vivado级联Modelsim仿真出现修改设计代码后重新run do文件,波形没有随着代码修改而改变,这个问题博主之前没有注意到,因为把Vivado和Modelsim级联好后 ...
- 高并发Web
hadoop适合处理分布式集群系统,本身是支持高速并发海量数据的写入和读取的.解决大量用户并发访问的方案有很多,给你个千万pv的参考方案:1)架构中直接引入软件名称的模块,是个人推荐使用的,如Hapr ...
- spring mvc配置ObjectMapper忽略无法识别的字段,以及一些博客推荐
通过Spring的MethodInvokingFactoryBean类实现的调用configure方法,此方法返回调用该方法的本身实例. 配置完毕后,可以在spring mvc的消息处理器中使用,为了 ...
- 【AppCan 开发者】移动信息化随想
现在的移动信息化,准确来说,是手机智能网络化.从08年到14年这6年时间里,手机发生翻天覆地的变化,成为移动设备智能中心,取得巨大成就,也成就一批公司,带动移动互联网的发展,引来众多人眼红热血投入.其 ...
- WPF 自定义下拉列表
XAML代码: <Popup x:Name="popupStrategy" StaysOpen="False" PopupAnimation=" ...
- C# WPF 登录多线程中 “调用线程无法访问对象,因为另一个线程拥有该对象“
造成这个错误的原因很多,以下是我遇到的 我的思路,开启一个线程A登录.因为服务器响应登录成功需要在主线程做一些操作,我这边需要用到主线程的窗口对象,我把窗口对象传到线程 A,直接用实例方法会有这个错误 ...
- CSS3 & 页面布局
相关链接 视频链接: CSS3 & 页面布局 CSS3与页面布局学习总结(一) CSS3与页面布局学习总结(二) CSS3与页面布局学习总结(三) CSS3与页面布局学习总结(四) CSS3与 ...
- Swagger 导出API
Swagger 导出API 这算是在博客园的第一篇博客吧,之后发的应该也会同步到博客园上. 此前的博客地址: https://blog.mytyiluo.cn Swagger简介 Swagger是一个 ...
- Interesting JavaScript
作者:ManfredHu 链接:http://www.manfredhu.com/2016/07/07/20-interestingJavascript 声明:版权所有,转载请保留本段信息,否则请不要 ...