|
|
|
@ -42,20 +42,75 @@ class _MuseumInfoPageState extends State<MuseumInfoPage> {
|
|
|
|
|
children: [
|
|
|
|
|
// 添加自动滚动图像轮播
|
|
|
|
|
AutoImageSlider(),
|
|
|
|
|
_buildCustomButton('查看博物馆信息', 45, 10, () {
|
|
|
|
|
Navigator.of(context).push(
|
|
|
|
|
MaterialPageRoute(
|
|
|
|
|
builder: (context) => MuseumInfoExtendPage(),
|
|
|
|
|
Padding(
|
|
|
|
|
padding: const EdgeInsets.all(16.0),
|
|
|
|
|
child: Align(
|
|
|
|
|
alignment: Alignment.centerLeft, // 左对齐
|
|
|
|
|
child: InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
// 导航到MuseumInfoExtendPage
|
|
|
|
|
Navigator.of(context).push(
|
|
|
|
|
MaterialPageRoute(
|
|
|
|
|
builder: (context) => MuseumInfoExtendPage(),
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
|
},
|
|
|
|
|
child: Text(
|
|
|
|
|
' 天津博物馆位于天津市河西区平江道62号,'
|
|
|
|
|
'是展示中国古代艺术及天津城市发展历史的大型艺术历史类综合性博物,'
|
|
|
|
|
'是天津地区最大的集收藏、保护、研究、陈列、教育为一体的大型公益性文化机构和对外文化交流的窗口。\n'
|
|
|
|
|
' 天津博物馆的前身可追溯至民国七年(1918年)6月1日,正式成立了天津博物院;'
|
|
|
|
|
'2004年由原天津市艺术博物馆和天津市历史博物馆合并组建;2007年底,天津博物馆旧馆对外免费开放;'
|
|
|
|
|
'2008年,天津博物馆新馆开工建设;'
|
|
|
|
|
'2012年5月,天津博物馆新馆建成对外开放。',
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 16,
|
|
|
|
|
color: Colors.black, // 设置文本颜色为黑色
|
|
|
|
|
),
|
|
|
|
|
textAlign: TextAlign.left,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
|
}),
|
|
|
|
|
_buildCustomButton('查看馆藏信息', 45, 20, () {
|
|
|
|
|
Navigator.of(context).push(
|
|
|
|
|
MaterialPageRoute(
|
|
|
|
|
builder: (context) => CollectionListPage(),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center, // 将按钮居中
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(width: 20),
|
|
|
|
|
InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
Navigator.of(context).push(
|
|
|
|
|
MaterialPageRoute(
|
|
|
|
|
builder: (context) => CollectionListPage(),
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
|
},
|
|
|
|
|
child: Column(
|
|
|
|
|
children: [
|
|
|
|
|
Container(
|
|
|
|
|
width: 80,
|
|
|
|
|
height: 80,
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Colors.green,
|
|
|
|
|
shape: BoxShape.circle,
|
|
|
|
|
),
|
|
|
|
|
child: Icon(
|
|
|
|
|
Icons.calendar_view_month, // 替换为您想要的图标
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
size: 40,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
Text(
|
|
|
|
|
'馆藏信息',
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 18,
|
|
|
|
|
color: Colors.black,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
|
}),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
@ -132,30 +187,3 @@ class _AutoImageSliderState extends State<AutoImageSlider> {
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 用于构建按钮的函数
|
|
|
|
|
Widget _buildCustomButton(String buttonText, double height, double verticalOffset, void Function() onPressed) {
|
|
|
|
|
return SizedBox(
|
|
|
|
|
height: height,
|
|
|
|
|
child: Transform.translate(
|
|
|
|
|
offset: Offset(0, verticalOffset),
|
|
|
|
|
child: ElevatedButton(
|
|
|
|
|
onPressed: onPressed,
|
|
|
|
|
style: ElevatedButton.styleFrom(
|
|
|
|
|
backgroundColor: Colors.green,
|
|
|
|
|
padding: const EdgeInsets.symmetric(
|
|
|
|
|
horizontal: 12,
|
|
|
|
|
vertical: 10,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
child: Text(
|
|
|
|
|
buttonText,
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
fontSize: 18,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|