tablelayout.xml表格布局

<?xml version="1.0" encoding="utf-8"?>
<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:stretchColumns="1,2">
<!--stretchColumns 设置自动拉伸列的序号-->
<!--TableRow 表格行-->
<TableRow>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="账号:"
/>
<EditText
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="请输入用户名"
android:layout_span="2"
/>
<!--layout_span 跨列-->/> </TableRow>
<TableRow>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="密码:"
/>
<EditText
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="请输入密码"
android:password="true"
android:layout_span="2"
/>
<!--password 是否是密码框--> </TableRow>
<TableRow>
<Button
android:layout_width="odp"
android:layout_height="wrap_content"
android:text="登陆"
android:layout_weight="1"
/>
<!--layout_weight 权重-->
<Button
android:layout_width="odp"
android:layout_height="wrap_content"
android:text="注册"
android:id="@+id/button2"
android:layout_weight="1"
/>
<Button
android:layout_width="odp"
android:layout_height="wrap_content"
android:text="取消"
android:layout_weight="1"
/>
</TableRow> </TableLayout>

andorid 表格布局的更多相关文章

  1. android——相对布局,表格布局

    1.相对布局 RelativeLayout 又称作相对布局,也是一种非常常用的布局.和LinearLayout 的排列规则不同,RelativeLayout 显得更加随意一些,它可以通过相对定位的方式 ...

  2. Android之UI编程(二):表格布局

    表格布局(TableLayout)继承了LinearLayout,它的本质依然是线性布局管理器,表TableLayout采用行.列的形式来管理UI组件,它并不需要明确地声明暴行多少行.多少列,而是通过 ...

  3. 黑马程序员——HTML表格布局

    ---------------------- <a href="http://edu.csdn.net"target="blank">ASP.Net ...

  4. Android课程---表格布局TableLayout

    特别注意:由于表格布局继承自线性布局,因此并不显示表格线 示例代码: <?xml version="1.0" encoding="utf-8"?> ...

  5. Android布局-TableLayout表格布局

    一.表格布局-TableLayout 1.概念 表格布局采用行列的形式来管理UI的控件.表格布局适合于有规则的布局. TableRow,用来管理行,TableRow中的一个空间占据该行的一列.若不用T ...

  6. 案例:TableLayout表格布局——迷你计算器

    计算器可以常用线性布局(LinearLayout)和表格布局(tableLayout).Gridlayout 今天我用的是表格布局 效果如下: 代码如下: <TableLayout xmlns: ...

  7. TableLayout(表格布局)

    表格布局模型以行列的形式管理子控件,每一行为一个TableRow的对象,当然也可以是一个View的对象.TableRow可以添加子控件,每添加一个为一列. TableLayout属性: android ...

  8. 3月23.CSS表格布局

    360表格布局: CSS定义标签: @charset "utf-8";/* CSS Document */.bt1{ border:#309 solid 1px; height:1 ...

  9. 【转】TableLayout(表格布局)

    转自:http://www.cnblogs.com/zhangs1986/archive/2013/01/17/2864536.html TableLayout(表格布局) 表格布局模型以行列的形式管 ...

随机推荐

  1. ArcGIS案例学习笔记-查找重叠的多边形

    ArcGIS案例学习笔记-查找重叠的多边形 联系方式:谢老师,135-4855-4328,xiexiaokui@qq.com 目的:对于多边形图层,查找具有重叠(相互覆盖)的面 数据: 方法: 1. ...

  2. IT蓝豹强烈推荐:符合1-2年工作经验,开发中的难点及相关优化:

    IT蓝豹强烈推荐:符合1-2年工作经验,开发中的难点及相关优化: IT蓝豹 ------------------> sqlite数据库版本升级 1.sqlite升级步骤: 1.自己写一个类继承自 ...

  3. Kubernetes+Prometheus+Grafana部署笔记

    一.基础概念 1.1 基础概念 Kubernetes(通常写成“k8s”)Kubernetes是Google开源的容器集群管理系统.其设计目标是在主机集群之间提供一个能够自动化部署.可拓展.应用容器可 ...

  4. tomcat 启动报错 Invalid character found in method name. HTTP method names must be tokens

    解决:Invalid character found in method name. HTTP method names must be tokens   阿里云上弄了一个tomcat,经常半夜发送崩 ...

  5. k8s operator

    https://coreos.com/blog/introducing-operators.html Site Reliability Engineer(SRE)是通过编写软件来运行应用程序的人员. ...

  6. vue-cli结构介绍

    vue-cli是vue项目开发的脚手架,非常方便,其结构大致如下, 其中static是存放静态资源的,存放的静态数据可以访问到,如果在static文件夹中创建mock文件夹,在mock文件夹中创建in ...

  7. javascript学习笔记(二):定义函数、调用函数、参数、返回值、局部和全局变量

    定义函数.调用函数.参数.返回值 关键字function定义函数,格式如下: function 函数名(){ 函数体 } 调用函数.参数.返回值的规则和c语言规则类似. <!DOCTYPE ht ...

  8. javascript学习笔记(一):基础、输出、注释、引用、变量、数据类型

    javascript脚本必须位于<script></script>之间,<script>标签可以位于<head>中,也可以位于<body>中 ...

  9. angularjs 粘贴事件

    参考 http://www.jb51.net/article/89708.htm ng-paste 需要setTimeout,否则无法获取到数据

  10. idea使用maven打包jar包

    1.在pom.xml中加入以下内容: <?xml version="1.0" encoding="UTF-8"?> <project xmln ...