【问题标题】:How do I make 2 color line below the AppBar?如何在 AppBar 下方制作 2 条颜色线?
【发布时间】:2018-12-03 16:30:44
【问题描述】:

如何在 AppBar 下方制作 2 条颜色线?

如下图所示!

【问题讨论】:

    标签: dart flutter


    【解决方案1】:

    一种方法:示例代码 -

    Scaffold(
            appBar: AppBar(
              title: Text('Demo'),
              bottom: PreferredSize(
                  child: Row(
                    children: <Widget>[
                      Expanded(
                        child: Container(
                          height: 5.0,
                          color: Colors.amber,
                        ),
                      ),
                      Expanded(
                        child: Container(
                          height: 5.0,
                          color: Colors.redAccent,
                        ),
                      )
                    ],
                  ),
                  preferredSize: Size.square(1.0)),
            ),
    

    截图:

    【讨论】:

    • 非常感谢@anmol-majhail 先生。爱你,先生 :) 工作 superBBBB!
    猜你喜欢
    • 1970-01-01
    • 2018-02-23
    • 2013-01-04
    • 1970-01-01
    • 2016-11-08
    • 2020-05-28
    • 1970-01-01
    • 1970-01-01
    • 2020-01-26
    相关资源
    最近更新 更多