Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1646)

Unified Diff: Source/core/rendering/RenderBlockLineLayout.cpp

Issue 50413008: Rendering text-justify:none (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: patch for landing Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/fast/css3-text/css3-text-justify/text-justify-none-expected.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/RenderBlockLineLayout.cpp
diff --git a/Source/core/rendering/RenderBlockLineLayout.cpp b/Source/core/rendering/RenderBlockLineLayout.cpp
index 35540fab37bd914c92b34e68482cf7c37c389fbe..05df1ddbd394006bdefdc1b9559467d5c5ef0aee 100644
--- a/Source/core/rendering/RenderBlockLineLayout.cpp
+++ b/Source/core/rendering/RenderBlockLineLayout.cpp
@@ -1013,6 +1013,7 @@ BidiRun* RenderBlockFlow::computeInlineDirectionPositionsForSegment(RootInlineBo
bool isAfterExpansion = true;
Vector<unsigned, 16> expansionOpportunities;
RenderObject* previousObject = 0;
+ TextJustify textJustify = style()->textJustify();
BidiRun* r = firstRun;
for (; r; r = r->next()) {
@@ -1026,7 +1027,7 @@ BidiRun* RenderBlockFlow::computeInlineDirectionPositionsForSegment(RootInlineBo
// Similarly, line break boxes have no effect on the width.
if (r->m_object->isText()) {
RenderText* rt = toRenderText(r->m_object);
- if (textAlign == JUSTIFY && r != trailingSpaceRun) {
+ if (textAlign == JUSTIFY && r != trailingSpaceRun && textJustify != TextJustifyNone) {
if (!isAfterExpansion)
toInlineTextBox(r->m_box)->setCanHaveLeadingExpansion(true);
unsigned opportunitiesInRun;
« no previous file with comments | « LayoutTests/fast/css3-text/css3-text-justify/text-justify-none-expected.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698