ListTile-图文列表
import 'package:flutter/material.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
appBar: AppBar(title: Text("flutterDemo")),
body: HomeContent(),
));
}
}
class HomeContent extends StatelessWidget {
@override
Widget build(BuildContext context) {
return ListView(
padding: EdgeInsets.all(10),
children: <Widget>[
ListTile(
leading: Icon(
Icons.settings,
size: 40,
),
title: Text(
'华为5G芯片只能当4G用 ',
style: TextStyle(
fontSize: 18,
),
),
subtitle: Text(' G手机后,华为5G终端不得不在美国制裁下走向尽头。'),
),
ListTile(
leading: Icon(
Icons.settings,
size: 30,
),
title: Text(
'华为5G芯片只能当4G用 ',
style: TextStyle(
fontSize: 18,
),
),
subtitle: Text(' G手机后,华为5G终端不得不在美国制裁下走向尽头。'),
),
ListTile(
leading: Image.network(
"https://www.itying.com/images/202004/goods_img/1101_P_1587123548040.jpg",
),
title: Text(
'华为5G芯片只能当4G用 ',
style: TextStyle(
fontSize: 18,
),
),
subtitle: Text(' G手机后,华为5G终端不得不在美国制裁下走向尽头。'),
),
ListTile(
leading: Image.network(
"https://www.itying.com/images/202004/goods_img/1101_P_1587123548040.jpg",
),
title: Text(
'华为5G芯片只能当4G用 ',
style: TextStyle(
fontSize: 18,
),
),
subtitle: Text(' G手机后,华为5G终端不得不在美国制裁下走向尽头。'),
),
ListTile(
leading: Image.network(
"https://www.itying.com/images/202004/goods_img/1101_P_1587123548040.jpg",
),
trailing: Image.network(
"https://www.itying.com/images/202004/goods_img/1101_P_1587123548040.jpg",
),
title: Text(
'华为5G芯片只能当4G用 ',
style: TextStyle(
fontSize: 18,
),
),
subtitle: Text(' G手机后,华为5G终端不得不在美国制裁下走向尽头。'),
),
ListTile(
trailing: Image.network(
"https://www.itying.com/images/202004/goods_img/1101_P_1587123548040.jpg",
),
title: Text(
'华为5G芯片只能当4G用 ',
style: TextStyle(
fontSize: 18,
),
),
subtitle: Text(' G手机后,华为5G终端不得不在美国制裁下走向尽头。'),
),
ListTile(
trailing: Icon(Icons.home),
title: Text(
'华为5G芯片只能当4G用 ',
style: TextStyle(
fontSize: 18,
),
),
subtitle: Text(' G手机后,华为5G终端不得不在美国制裁下走向尽头。'),
),
],
);
}
}
我是Eric,手机号是13522679763