zoukankan      html  css  js  c++  java
  • Row

    代码:

    new Row(
    children: <Widget>[
    new RaisedButton(
    onPressed: (){},
    color: Colors.red,
    child: new Text('红色按钮'),
    ),
    Expanded(child: new RaisedButton(
    onPressed: (){},
    color: Colors.green,
    child: new Text('绿色按钮'),
    ),),
    new RaisedButton(
    onPressed: (){},
    color: Colors.blue,
    child: new Text('蓝色按钮'),
    )
    总结:

    //横向布局

    Row(

    children:<widget>{

    //不灵活布局

    new ReisedButton(

    onPressed:(){}//不处理

    color ://颜色

    child:new Text(‘’)按钮文字

     

    ),

     

    //灵活布局

     

    Expanded(child: new RaisedButton(

    同上

     

    ),),

    如果两边不灵活布局 中间一个灵活,那就会不灵活布局是根据内容大小展示,灵活的自动撑满一行

     

    }




    ],
    ),
     
  • 相关阅读:
    POJ 3630
    Codeforces Round #219 (Div. 2) D题
    Codeforces Round #232 (Div. 2) On Sum of Fractions
    Codeforces Round #232 (Div. 2) C
    撸呀撸的左手(KMP+DP)
    hdu poj KMP简单题目总结
    LCT总结
    bzoj1019 [SHOI2008]汉诺塔
    NOIP2016总结
    p1199八数码问题
  • 原文地址:https://www.cnblogs.com/pp-pping/p/12162526.html
Copyright © 2011-2022 走看看