errorMaxLines property

int? errorMaxLines
final

The maximum number of lines the errorText can occupy.

Defaults to null, which means that soft line breaks in errorText are truncated with an ellipse while hard line breaks are respected. For example, an errorText that overflows the width of the field will be truncated with an ellipse. However, an errorText with explicit linebreak characters (\n) will display on multiple lines.

To cause a long errorText to wrap, either set errorMaxLines or use error which offers more flexibility. For instance, it can be set to a Text widget with a specific overflow value.

This value is passed along to the Text.maxLines attribute of the Text widget used to display the error.

See also:

Implementation

final int? errorMaxLines;