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

Unified Diff: Source/core/dom/Text.cpp

Issue 755613002: Fix assertion: !visualMetricsValues.isEmpty() in layoutTextOnLineOrPath (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 1 month 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
Index: Source/core/dom/Text.cpp
diff --git a/Source/core/dom/Text.cpp b/Source/core/dom/Text.cpp
index 1fb61a41933ca5b128f5ec92cd34aad7946dc815..b181f59756e418769f105ecca2492158f614f1ce 100644
--- a/Source/core/dom/Text.cpp
+++ b/Source/core/dom/Text.cpp
@@ -257,6 +257,9 @@ bool Text::textRendererIsNeeded(const RenderStyle& style, const RenderObject& pa
if (!parent.canHaveWhitespaceChildren())
return false;
+ if (style.whiteSpace() == PRE_WRAP && parent.isSVG()) // pre-wrap in SVG never makes renderer.
kouhei (in TOK) 2014/12/09 09:15:23 Should we also care about pre/pre-line?
fs 2014/12/09 10:18:32 All cases in which the metrics builder will end up
+ return false;
+
if (style.preserveNewline()) // pre/pre-wrap/pre-line always make renderers.
return true;

Powered by Google App Engine
This is Rietveld 408576698