auto_size_text icon indicating copy to clipboard operation
auto_size_text copied to clipboard

Add textBuilder(double fontSize, TextStyle style, int maxLines)

Open esDotDev opened this issue 4 years ago • 0 comments

It would be nice to use this widget's ability to calculate the optimal font size, but replace it with our own Widgets that use that info.

For example, I might want to replace the default Text(), with a TextFormField(). Having a builder would be a simple, flexible approach serving any future use cases.

This should be as simple as adding:

if(widget.textBuilder != null) return widget.textBuilder(fontSize, style, maxLines);

@ line 414- auto_size_text.dart

esDotDev avatar Feb 12 '21 20:02 esDotDev