• LinearProgressIndicator & CircularProgressIndicator(每日Flutter 小部件)


    LinearProgressIndicator &  CircularProgressIndicator  条形 圆形进度条

    class ProgressIndicatorWidget extends StatefulWidget {
      ProgressIndicatorWidget({Key key}) : super(key: key);
    
      _ProgressIndicatorWidgetState createState() =>
          _ProgressIndicatorWidgetState();
    }
    
    class _ProgressIndicatorWidgetState extends State<ProgressIndicatorWidget> {
      _ProgressIndicatorWidgetState();
    
      @override
      Widget build(BuildContext context) {
        // TODO: implement build
        return Column(
            mainAxisAlignment: MainAxisAlignment.center,
            crossAxisAlignment: CrossAxisAlignment.center,
            textDirection: TextDirection.ltr,
            verticalDirection: VerticalDirection.down,
            textBaseline: TextBaseline.alphabetic,
            children: [
              LinearProgressIndicator(
                value: 0.3,
                valueColor: new AlwaysStoppedAnimation<Color>(Colors.red),
                backgroundColor: Color(0xff00ff00),
              ),
              CircularProgressIndicator(
    
                backgroundColor: Color(0xff00ff00),
                valueColor: new AlwaysStoppedAnimation<Color>(Colors.red),
    
              )
            ]);
      }
    }
    

      

  • 相关阅读:
    C# winform 选择文件保存路径
    笔记
    Redis 队列好处
    异步线程
    WebApi 运行原理
    MVC ---- 怎删改查
    如何快速掌握一门新技术/语言/框架...
    膝盖中了一箭之康复篇
    翻译-Salt与Ansible全方位比较
    膝盖中了一箭之手术篇
  • 原文地址:https://www.cnblogs.com/wjw334/p/12572457.html
Copyright © 2020-2023  润新知