美文网首页
flutter 遇见的坑

flutter 遇见的坑

作者: yinlang | 来源:发表于2019-07-18 10:41 被阅读0次

    1、Row嵌套textfiled
    解决办法:

    用Expanded 包裹一下Textfiled
    
    Expanded(
                   child: TextField(
                     controller: _textEditingController2,
                     decoration: InputDecoration(
                         prefixIcon: Icon(Icons.code,size: ScreenUtil().setWidth(28),),
                         border: InputBorder.none,
                         hintText:"验证码"
                     ),
                   ),
                 ),
    

    2、Waiting for another flutter command to release the startup lock...

    解决办法:删除flutter->bin->cache->lockfile文件。
    3、RenderRepaintBoundary 文件截屏

    4、Flutter Widget - Spacer
    更个性化的分配空间:

    Row (
    children:[
     MyBox(),
     Spacer(),
     MyBox(),
     Spacer(flex:3),
     MyBox(),
    ],
    
    

    相关文章

      网友评论

          本文标题:flutter 遇见的坑

          本文链接:https://www.haomeiwen.com/subject/ogczhctx.html