旋转盒子

class MyAppextends StatelessWidget {

@override

  Widgetbuild(BuildContext context) {

return new MaterialApp(

title:'RotatedBox旋转盒子示例',

      home:Scaffold(

appBar:AppBar(

title:Text(

'RotatedBox旋转盒子示例',

            style:TextStyle(color: Colors.white),

          ),

        ),

        body:Center(

child:RotatedBox(

quarterTurns: -3,//旋转次数,一次为90度

            child:Text(

'RotatedBox旋转盒子',

              style:TextStyle(fontSize:28.0),

            ),

          ),

        ),

      ),

    );

  }

}

猜你喜欢

转载自blog.csdn.net/weixin_33674976/article/details/90866683
今日推荐