Text Indent
Use indent-{size} utilities to set the indentation of a text block. Values
use the standard spacing scale (indent-N = N × 4 px).
Basic example
Section titled “Basic example”Use utilities like indent-8 to indent text within an element:
Style('indent-8', child: Text('So I started to walk into the water...'))Class reference
Section titled “Class reference”| Class | Indent |
|---|---|
indent-0 | 0 px |
indent-px | 1 px |
indent-0.5 | 2 px |
indent-1 | 4 px |
indent-2 | 8 px |
indent-4 | 16 px |
indent-6 | 24 px |
indent-8 | 32 px |
indent-10 | 40 px |
indent-12 | 48 px |
indent-16 | 64 px |
indent-20 | 80 px |
-indent-N | Not yet supported — first-line-only negative indent has no Flutter API. See the Library prerequisites section in PLAYGROUND_PARITY.md. |
All indent-{size} utilities use the standard spacing scale. The implementation
prepends an invisible WidgetSpan of the indent width to the first line of the
paragraph, so only the first line is shifted (matching CSS text-indent
semantics).