Flutter--不同样式字符串拼接

332 阅读1分钟
Widget textSpan() {
    return Text.rich(TextSpan(
        children: [
          TextSpan(
              text: "Home: "
          ),
          TextSpan(
              text: "https://flutterchina.club",
              style: TextStyle(
                  color: Colors.blue
              ),
          ),
        ]
    )).center();
  }