Ian Hickson 7cf2dbdf37 Fix crash when dumping the app if it uses RichText
Specifically:

* Handle null styles in TextSpan without crashing in toString().

* Handle null children in TextSpan child lists without crashing in
  toString().

* Handle entirely empty TextSpans in toString() explicitly.

* Assert that TextSpans don't contain nulls in various places. This is
  done more often than one might think necessary, because it turns out
  that TextSpan takes a (mutable) List for one of its arguments, so
  who knows what it will contain at any given time. By asserting all
  over the place, hopefully we'll catch it near the change if they do
  change it.

* Add a RichText example to Stocks to exercise RichText and TextSpans.

See also: https://github.com/flutter/flutter/issues/2514, https://github.com/flutter/flutter/issues/2519
2016-03-10 20:48:50 -08:00
..
2016-02-12 08:27:47 -08:00

Flutter Examples

This directory contains several examples of using Flutter. Each of these is an individual Dart application package.

To run a sample with the flutter tool, run pub get inside its directory, then run flutter run. (See the getting started guide to install the flutter tool.)

Available examples include:

  • Hello, world The hello world app is a basic app that shows the text "hello, world."

  • Stocks The stocks app is an example of a typical mobile app built using Flutter. The app shows a list of all the stocks in the NASDAQ.

  • Widgets The widget apps demonstrate a number of Flutter widgets so you can experiment with them in a simple container. There is no main.dart in this directory because each file is a standalone sample. To run a particular file, use flutter run -t filename.dart.