Fix not to wrap in 'nowrap' elements
When a word in 'nowrap' element fits but its trailing space does not, issue 561997 fixed not to wrap before the 'nowrap' element. The fix, however, creates a wrap opportunity even if 'nowrap' content follows. This patch ensures the fix is valid only if no content follows or autowrap content follows; i.e., only when we really have a break opportunity after the space. Ideally, the original fix should have been done when the line breaker reads the next item. But we have a lot of places that call FitsOnLine() without 'ExcludeWhitespace' option and probably some of them are not correct. To make the fix safer, this patch limits the original fix instead of cleaning up all FitsOnLine() calls. Change-Id: I78c499cc6c1d7c30261e031ec19124ae9d3fbcf1 Bug: 561997, 840755 Reviewed-on: https://chromium-review.googlesource.com/1053341Reviewed-by:Emil A Eklund <eae@chromium.org> Commit-Queue: Emil A Eklund <eae@chromium.org> Cr-Commit-Position: refs/heads/master@{#557556}
Showing
Please register or sign in to comment