// RotatedBox旋转容器,4次算一次循环
class RotatedBoxDemo extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Center(
child: Column(
children: [
RotatedBox(
child: Text('ABCDEF', style: TextStyle(fontSize: 28.0),),
// 旋转次数
quarterTurns: 1,
),
SizedBox(height: 20,),
RotatedBox(
child: Text('ABCDEF', style: TextStyle(fontSize: 28.0),),
// 旋转次数
quarterTurns: 2,
),
SizedBox(height: 20,),
RotatedBox(
child: Text('ABCDEF', style: TextStyle(fontSize: 28.0),),
// 旋转次数
quarterTurns: 3,
),
SizedBox(height: 20,),
RotatedBox(
child: Text('ABCDEF', style: TextStyle(fontSize: 28.0),),
// 旋转次数
quarterTurns: 4,
),
],
),
);
}
}
Flutter RotatedBox旋转容器
最新推荐文章于 2024-05-28 22:31:31 发布