博客
关于我
Card
阅读量:254 次
发布时间:2019-03-01

本文共 1699 字,大约阅读时间需要 5 分钟。

/// Flutter code sample for Card// This sample shows creation of a [Card] widget that shows album information// and two actions.import 'package:flutter/material.dart';void main() => runApp(const MyApp());/// This is the main application widget.class MyApp extends StatelessWidget {  const MyApp({Key? key}) : super(key: key);  static const String _title = 'Flutter Code Sample';  @override  Widget build(BuildContext context) {    return MaterialApp(      title: _title,      home: Scaffold(        appBar: AppBar(title: const Text(_title)),        body: const MyStatelessWidget(),      ),    );  }}/// This is the stateless widget that the main application instantiates.class MyStatelessWidget extends StatelessWidget {  const MyStatelessWidget({Key? key}) : super(key: key);  @override  Widget build(BuildContext context) {    return Center(      child: Card(        child: Column(          mainAxisSize: MainAxisSize.min,          children: 
[ const ListTile( leading: Icon(Icons.album), title: Text('The Enchanted Nightingale'), subtitle: Text('Music by Julie Gable. Lyrics by Sidney Stein.'), ), Row( mainAxisAlignment: MainAxisAlignment.end, children:
[ TextButton( child: const Text('BUY TICKETS'), onPressed: () {/* ... */}, ), const SizedBox(width: 8), TextButton( child: const Text('LISTEN'), onPressed: () {/* ... */}, ), const SizedBox(width: 8), ], ), ], ), ), ); }}

 

转载地址:http://eakx.baihongyu.com/

你可能感兴趣的文章
MySQL 报错:Duplicate entry 'xxx' for key 'UNIQ_XXXX'
查看>>
Mysql 拼接多个字段作为查询条件查询方法
查看>>
mysql 排序id_mysql如何按特定id排序
查看>>
Mysql 提示:Communication link failure
查看>>
mysql 插入是否成功_PDO mysql:如何知道插入是否成功
查看>>
Mysql 数据库InnoDB存储引擎中主要组件的刷新清理条件:脏页、RedoLog重做日志、Insert Buffer或ChangeBuffer、Undo Log
查看>>
mysql 数据库中 count(*),count(1),count(列名)区别和效率问题
查看>>
mysql 数据库备份及ibdata1的瘦身
查看>>
MySQL 数据库备份种类以及常用备份工具汇总
查看>>
mysql 数据库存储引擎怎么选择?快来看看性能测试吧
查看>>
MySQL 数据库操作指南:学习如何使用 Python 进行增删改查操作
查看>>
MySQL 数据库的高可用性分析
查看>>
MySQL 数据库设计总结
查看>>
Mysql 数据库重置ID排序
查看>>
Mysql 数据类型一日期
查看>>
MySQL 数据类型和属性
查看>>
mysql 敲错命令 想取消怎么办?
查看>>
Mysql 整形列的字节与存储范围
查看>>
mysql 断电数据损坏,无法启动
查看>>
MySQL 日期时间类型的选择
查看>>