Skip to content

Conversation

@chunhtai
Copy link
Contributor

This reverts commit 473744d.

Description

Previous pr was reverted due to internal test failure. It is now ready to reland. Nothing has changed from previous pr

Related Issues

Fixes #63302

Tests

Checklist

Before you create this PR, confirm that it meets all requirements listed below by checking the relevant checkboxes ([x]). This will ensure a smooth and quick review process.

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I signed the CLA.
  • I read and followed the Flutter Style Guide, including Features we expect every widget to implement.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I updated/added relevant documentation (doc comments with ///).
  • All existing and new tests are passing.
  • The analyzer (flutter analyze --flutter-repo) does not report any problems on my PR.
  • I am willing to follow-up on review comments in a timely manner.

Breaking Change

Did any tests fail when you ran them? Please read Handling breaking changes.

@flutter-dashboard flutter-dashboard bot added the framework flutter/packages/flutter repository. See also f: labels. label Aug 20, 2020
@chunhtai chunhtai requested a review from goderbauer August 20, 2020 20:46
@goderbauer
Copy link
Member

I looked at this again in the context of #48679 and I believe this PR does not fix the intrinsics for Wrap. As far as I can tell, in the following code the intrinsic height is still calculated incorrectly to be 1 line when in fact it is 3 lines.

    Center(
      child: Container(
        width: 200,
        height: 200,
        color: Colors.green,
        child: Align(
          alignment: Alignment.topLeft,
          child: IntrinsicHeight(
            child: Container(
              color: Colors.yellow,
              child: Wrap(
                children: [
                  Text('Start'),
                  Row(
                    children: [
                      Icon(Icons.edit, size: 16),
                    ],
                  ),
                  Text('End'),
                ],
              ),
            ),
          ),
        ),
      )
    );

I believe the only fix for that is to implement the API outlined in #48679 (comment) because the problem is the same: We don't have an API to ask the Row-child what its intrinsics size is given the constraints we are gonna give it during layout.

Copy link
Member

@goderbauer goderbauer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The plan is to land this to fix the specific issue in #63302 until we have implemented the more generic fix outlined in #48679 (comment).

@fluttergithubbot
Copy link
Contributor

This pull request is not suitable for automatic merging in its current state.

  • The status or check suite Linux web_tests has failed. Please fix the issues identified (or deflake) before re-applying this label.

@fluttergithubbot fluttergithubbot merged commit 39d7a01 into flutter:master Aug 25, 2020
smadey pushed a commit to smadey/flutter that referenced this pull request Aug 27, 2020
mingwandroid pushed a commit to mingwandroid/flutter that referenced this pull request Sep 6, 2020
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 25, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

framework flutter/packages/flutter repository. See also f: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

IntrinsicHeight around Wrap(Text) is incorrect

4 participants