This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Add an adjustment to the line width check in LineBreaker::addWordBreak#8623
Merged
jason-simmons merged 1 commit intoflutter:masterfrom Apr 18, 2019
Merged
Add an adjustment to the line width check in LineBreaker::addWordBreak#8623jason-simmons merged 1 commit intoflutter:masterfrom
jason-simmons merged 1 commit intoflutter:masterfrom
Conversation
currentLineWidth is the width passed into Paragraph layout, which comes from the maxIntrinsicWidth returned by a previous call to Paragraph layout. That width is calculated by Layout::measureText. postBreak is calculated from the character widths in the LineBreaker. A slight mismatch between these two widths may unnecessarily cause the insertion of desperate breaks in addWordBreak. Adding some slack to currentLineWidth works around this. Fixes flutter/flutter#30347
b4cfdf3 to
f22912e
Compare
GaryQian
approved these changes
Apr 17, 2019
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/flutter
that referenced
this pull request
Apr 18, 2019
engine-flutter-autoroll
added a commit
to flutter/flutter
that referenced
this pull request
Apr 18, 2019
flutter/engine@06fea14...4b9966f git log 06fea14..4b9966f --no-merges --oneline 4b9966f Add an adjustment to the line width check in LineBreaker::addWordBreak (flutter/engine#8623) 60bb866 Roll src/third_party/skia a94670bd08cd..2c2240f66805 (2 commits) (flutter/engine#8632) a144f17 Tight Paragraph Width (flutter/engine#8530) The AutoRoll server is located here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+/master/autoroll/README.md If the roll is causing failures, please contact the current sheriff ([email protected]), and stop the roller if necessary.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
currentLineWidth is the width passed into Paragraph layout, which comes
from the maxIntrinsicWidth returned by a previous call to Paragraph layout.
That width is calculated by Layout::measureText.
postBreak is calculated from the character widths in the LineBreaker.
A slight mismatch between these two widths may unnecessarily cause the
insertion of desperate breaks in addWordBreak. Adding some slack to
currentLineWidth works around this.
Fixes flutter/flutter#30347