页面布局 Paddiing Row Column Expanded 组件详解
案例代码
class HomenCenter extends StatelessWidget {
Widget build(BuildContext context) {
// TODO: implement build
return Padding(
padding: EdgeInsets.all(5),
child: Column(
children: <Widget>[
Row(
children: <Widget>[
Expanded(
child: Container(child: Text('你好啊', style: TextStyle(color: Colors.white),), height: 150, decoration: BoxDecoration(color: Colors.black),
),
)
],
),
SizedBox(height: 5,),
Container(
height: 150,
child: Row(
children: <Widget>[
Expanded(flex: 2, child: Container(decoration: BoxDecoration(color: Colors.yellow))
),
SizedBox(width: 5,),
Expanded(
flex: 1,
child: Column(
children: <Widget>[
Expanded(flex: 1, child: Container(decoration: BoxDecoration(color: Colors.red),)),
SizedBox(height: 5,),
Expanded(flex: 1, child: Container(decoration: BoxDecoration(color: Colors.blue),))
]
)
)
],
),
)
],
),
);
}
}
页面布局 Paddiing Row Column Expanded 组件详解的更多相关文章
- 10Flutter页面布局 Padding Row Column Expanded组件详解:
Padding组件: main.dart import 'package:flutter/material.dart'; import 'res/listData.dart'; /* flutter页 ...
- flutter 页面布局 Paddiing Row Column Expanded 组件
Flutter Paddiing 组件 在 html 中常见的布局标签都有 padding 属性,但是 Flutter 中很多 Widget 是没有 padding 属 性.这个时候我们可以用 Pad ...
- Tomcat负载均衡、调优核心应用进阶学习笔记(一):tomcat文件目录、页面、架构组件详解、tomcat运行方式、组件介绍、tomcat管理
文章目录 tomcat文件目录 bin conf lib logs temp webapps work 页面 架构组件详解 tomcat运行方式 组件介绍 tomcat管理 tomcat文件目录 ➜ ...
- Echars 6大公共组件详解
Echars 六大组件详解 : title tooltip toolbox legend dataZoom visualMap 一.title标题详解 myTitleStyle = { color ...
- Angular6 学习笔记——组件详解之组件通讯
angular6.x系列的学习笔记记录,仍在不断完善中,学习地址: https://www.angular.cn/guide/template-syntax http://www.ngfans.net ...
- Angular6 学习笔记——组件详解之模板语法
angular6.x系列的学习笔记记录,仍在不断完善中,学习地址: https://www.angular.cn/guide/template-syntax http://www.ngfans.net ...
- Tomcat系列之服务器的安装与配置以及各组件详解
Tomcat系列之服务器的安装与配置以及各组件详解 大纲 一.前言 二.安装与配置Tomcat 三.Tomcat 目录的结构 四.Tomcat 配置文件 注,本文的测试的操作系统为CentOS 6.4 ...
- Android中Intent组件详解
Intent是不同组件之间相互通讯的纽带,封装了不同组件之间通讯的条件.Intent本身是定义为一个类别(Class),一个Intent对象表达一个目的(Goal)或期望(Expectation),叙 ...
- Android笔记——四大组件详解与总结
android四大组件分别为activity.service.content provider.broadcast receiver. ------------------------------- ...
随机推荐
- python使用libnum,gmpy2快速解RSA
直接贴出Pcat师傅的解题脚本 # -*- coding:utf8 -*- __author__='pcat@chamd5.org' import libnum import gmpy2 n=7306 ...
- Federal Learning(联邦学习)认知
本人是学生党,同时也是小菜鸡一枚,撞运气有机会能够给老师当项目助理,在这个过程中肯定会学到一些有趣的知识,就在此平台上记录一下,在知识点方面有不对的还请各位指正. What(什么是联邦学习?) 联邦学 ...
- CentOS7识别不到win10启动项的解决方法
Windows的文件系统是NTFS格式的,而CentOS是不支持NTFS格式的.因此,我们要安装另外的工具使CentOS能识别NTFS格式的文件系统. 这里我们选择ntfs-3g这个工具,安装过程如下 ...
- spring(四):IoC
IoC-Inversion of Control,即控制反转 IoC意味着将你设计好的对象交给容器控制,而不是传统的在你的对象内部直接控制. 理解IoC的关键:"谁控制谁,控制什么,为何是反 ...
- Scale9Sprite不要在初始化的时候setCapInsets
let scale9Sprite = new ccui.Scale9Sprite(filePath);scale9Sprite.setCapInsets(cc.rect(x,y,w,h)); 而非 l ...
- 通过Spring Resource接口获取资源
目录 1 Resource简介 2 通过ResourceLoader获取资源 3 在bean中获取Resource的方式 1 Resource简介 在S ...
- ieee-explore文献免费下载办法
假设文献网址为:http://ieeexplore.ieee.org/document/xxxxxxx/ 下载保存的话,改为http://ieeexplore.ieee.org.sci-hub.tw/ ...
- Ultra-Thin LED Downlight Selection: 6 Things
LED Decorative Light Manufacturer description: ultra-thin LED downlight features can maintain the ...
- 【原】AMFObject数据格式详解
AMF AMF是Action Message Format(动作消息格式)的简写,它是一种二进制的数据格式.它的设计是为了把actionscript里面的数据(包括Object, Array, Boo ...
- Navicat图形更改表结构的时,设置外键时出现1452错误
原文地址:http://www.mamicode.com/info-detail-1296600.html 提示1452错误,如下图所示. 然后百度了一下,得到了一个靠谱的答案: 这是因为表设置了外键 ...