diff options
Diffstat (limited to 'layout/generic/nsTextFrame.cpp')
-rw-r--r-- | layout/generic/nsTextFrame.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/layout/generic/nsTextFrame.cpp b/layout/generic/nsTextFrame.cpp index 4bc542626..a9ed168fb 100644 --- a/layout/generic/nsTextFrame.cpp +++ b/layout/generic/nsTextFrame.cpp @@ -8245,6 +8245,16 @@ nsTextFrame::AddInlineMinISizeForFlow(nsRenderingContext *aRenderingContext, return; } + // If overflow-wrap is break-word, we can wrap everywhere. + if (textStyle->WordCanWrap(this)) { + aData->OptionallyBreak(); + aData->mCurrentLine += + textRun->GetMinAdvanceWidth(Range(start, flowEndInTextRun)); + aData->mTrailingWhitespace = 0; + aData->OptionallyBreak(); + return; + } + AutoTArray<bool,BIG_TEXT_NODE_SIZE> hyphBuffer; bool *hyphBreakBefore = nullptr; if (hyphenating) { |