Flutter & Dart · Component
Text
The Flutter Text widget displays a string or inline span. It supports inherited styles, wrapping, overflow handling, text scaling, accessibility labels, and selection.
Last updated
Syntax
const Text(String data, {Key? key, TextStyle? style, StrutStyle? strutStyle, TextAlign? textAlign, TextDirection? textDirection, Locale? locale, bool? softWrap, TextOverflow? overflow, double? textScaleFactor, TextScaler? textScaler, int? maxLines, String? semanticsLabel, String? semanticsIdentifier, TextWidthBasis? textWidthBasis, TextHeightBehavior? textHeightBehavior, Color? selectionColor})In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.
SubscribeRelated
RichTextDefaultTextStyleSelectableRegionSelectionAreaSelectionContainer.disabledTextSpanTextStyleTextOverflow