Skip to content

Error calculating dimensions in SimpleDialog #24

@warriorCoder

Description

@warriorCoder

Steps to Reproduce

  • Create a SimpleDialog being shown in the showDialog call.
  • In the title add a row with an expanded widget which holds the AutoSizeText widget

Code sample

Container(
            color: Colors.black12,
            child: Row(
              crossAxisAlignment: CrossAxisAlignment.center,
              children: <Widget>[
                Expanded(
                  child: Padding(
                    padding:
                        const EdgeInsets.only(left: 10, top: 10, bottom: 5),
                    child: AutoSizeText(
                       "Big long huge title here to shrink",
                      style: Theme.of(context).textTheme.title,
                      minFontSize: 14,
                      maxLines: 1,         
                    ),
                  ),
                ),
                IconButton(
                  alignment: Alignment.topRight,
                  icon: Icon(Icons.close),
                  onPressed: () => Navigator.of(context).pop(),
                )
              ],
            ),
          ),

Screenshots
If applicable, add screenshots to help explain your problem.

Version

  • Flutter version: [1.5.4]
  • auto_size_text version: [2.0.1]

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingwipThis issue is currently being implemented

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions