import 'package:flutter/material.dart'; void main() { runApp( App() ); } class App extends StatelessWidget{ @override Widget build(BuildContext context){ return Center( child:Text( 'hello word', textDirection: TextDirection.ltr, style: TextStyle( fontSize: 40.0, fontWeight: FontWeight.bold, color: Colors.yellow, ), ) , ); } }

本文介绍了一个使用Flutter框架创建简单应用程序的示例代码。通过运行一个显示居中'Hello World'文本的应用,展示了如何使用StatelessWidget类和Material组件库。
7538

被折叠的 条评论
为什么被折叠?



