直接从官网文档中复制记录,方便以后查看

contain → const BoxFit

As large as possible while still containing the source entirely within the target box.

const BoxFit(1)

cover → const BoxFit

As small as possible while still covering the entire target box.

const BoxFit(2)

fill → const BoxFit

Fill the target box by distorting the source's aspect ratio.

const BoxFit(0)

fitHeight → const BoxFit

Make sure the full height of the source is shown, regardless of whether this means the source overflows the target box horizontally.

const BoxFit(4)

fitWidth → const BoxFit

Make sure the full width of the source is shown, regardless of whether this means the source overflows the target box vertically.

const BoxFit(3)

none → const BoxFit

Align the source within the target box (by default, centering) and discard any portions of the source that lie outside the box.

The source image is not resized.

const BoxFit(5)

scaleDown → const BoxFit

Align the source within the target box (by default, centering) and, if necessary, scale the source down to ensure that the source fits within the box.

This is the same as contain if that would shrink the image, otherwise it is the same as none.

const BoxFit(6)

flutter image boxfit相关推荐

  1. 转:Flutter Decoration背景设定(边框、圆角、阴影、形状、渐变、背景图像等)...

    1 继续关系: BoxDecoration:实现边框.圆角.阴影.形状.渐变.背景图像 ShapeDecoration:实现四个边分别指定颜色和宽度.底部线.矩形边色.圆形边色.体育场(竖向椭圆).  ...

  2. 利用Flutter写一个跨平台的果核APP(4)——数据存储

    前言 目前我们已经实现了几个界面,今天这篇文章开始着手进行登录页的制作,主要流程就是获取输入框中的内容,发送给后台进行验证,如果成功将返回信息保存在本地并跳转至首页,如果失败就提示用户重新输入. 在这 ...

  3. Flutter Widget

    文章目录 一.Widget分类 二.widget的状态 三.根widget 四.Basics 4.1 模板和主题 4.2 Text文本 4.3 图片 4.4 凸起按钮 4.5 其他widget 4.5 ...

  4. Flutter开发之ListView使用第三方pull_to_refresh加载更多(36)

    在Flutter开发之ListView下拉刷新&上拉加载更多(35) 中我们实现了下拉刷新.上拉分页加载的功能.但是使用起来非常不方便,且不满一屏时难以处理. 今天介绍ListView使用第三 ...

  5. Flutter开发之ListView组件(21)

    欢迎点赞+关注.你的鼓励是我写作的动力! ListView是一个类似列的widget,它的内容对于其渲染框太长时会自动提供滚动. ListView 摘要: 用于组织盒子中列表的特殊Column 可以水 ...

  6. 【Flutter】监听滚动动作 控制组件 透明度渐变 ( 移除顶部状态栏空白 | 帧布局组件 | 透明度组件 | 监听滚动组件 )

    文章目录 前言 一.移除顶部状态栏空白 二.帧布局组件 三.透明度组件 四.监听滚动事件 五.完整代码示例 六.相关资源 前言 在上一篇博客 [Flutter]Banner 轮播组件 ( flutte ...

  7. 【Flutter】Banner 轮播组件 ( flutter_swiper 插件 | Swiper 组件 )

    文章目录 一.flutter_swiper 插件 二.Swiper 组件使用 三.完整代码示例 四.相关资源 一.flutter_swiper 插件 到 https://pub.dev/package ...

  8. 【Flutter】Hero 动画 ( Hero 实现径向动画 | Hero 组件 createRectTween 设置 )

    文章目录 ◯.Hero 构造函数 一.圆形方形组件 二.创建页面 1 的组件 ( Hero 组件 1 ) 三.创建页面 2 的组件 ( Hero 组件 2 ) 四.完整代码示例 五.相关资源 ◯.He ...

  9. 【Flutter】Hero 动画 ( Hero 动画使用流程 | 创建 Hero 动画核心组件 | 创建源页面 | 创建目的页面 | 页面跳转 )

    文章目录 ◯.Hero 动画简介 一.创建 Hero 动画核心组件 二.创建源页面 三.创建目的页面 四.页面跳转 五.完整代码示例 六.相关资源 ◯.Hero 动画简介 Hero Widget 动画 ...

最新文章

  1. 秒杀(PHP,Redis,Lua)
  2. 论文笔记:Inception v1
  3. Linux 环境下/etc/profile和/etc/profile.d 的区别和用法!
  4. mPaas-RPC拦截器各种场景下的使用指南
  5. 附加数据库失败,版本为655,此服务器支持611及更低版本。不支持降级路径。...
  6. python第五次作业——陈灵院
  7. python爬虫lxml xpath测试
  8. 将hive查询内容存储到文件中
  9. Appium 解决手势密码 (java篇)
  10. ShardingSphere Raw JDBC 主从示例
  11. C#类库项目创建config文件
  12. 3款简单实用的在线PCR引物设计软件
  13. 禅道及与JIRA区别
  14. mini programe
  15. 信息安全概论———网络安全协议
  16. PyTorch 音频处理教程
  17. word2Vec基础背景知识
  18. 33岁跳槽无路,走投无路之际受贵人指点,成功上岸阿里(Java岗)
  19. 唐诗页面爬取 --- 预研阶段
  20. “大数据杀熟”杀的是你吗?

热门文章

  1. iOS手势操作简介(六)
  2. vue父组件异步获取动态数据传递给子组件获取不到值
  3. Python爬虫学习二
  4. LED音乐频谱之点阵
  5. redis安装(linux)
  6. sublime 正则搜索日语字符
  7. stack overflow at line
  8. iOS CoreTelephony框架介绍与使用案列
  9. [bzoj2729][HNOI2012]排队 题解 (排列组合 高精)
  10. k8s学习笔记-调度之Affinity