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

Side by Side Diff: Source/core/rendering/svg/RenderSVGText.cpp

Issue 145493012: <br> nodes should not be allowed within SVG text (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Reupload ps#3. Created 6 years, 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006 Apple Computer, Inc. 2 * Copyright (C) 2006 Apple Computer, Inc.
3 * Copyright (C) 2006 Alexander Kellett <lypanov@kde.org> 3 * Copyright (C) 2006 Alexander Kellett <lypanov@kde.org>
4 * Copyright (C) 2006 Oliver Hunt <ojh16@student.canterbury.ac.nz> 4 * Copyright (C) 2006 Oliver Hunt <ojh16@student.canterbury.ac.nz>
5 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org> 5 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org>
6 * Copyright (C) 2008 Rob Buis <buis@kde.org> 6 * Copyright (C) 2008 Rob Buis <buis@kde.org>
7 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org> 7 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org>
8 * Copyright (C) Research In Motion Limited 2010-2012. All rights reserved. 8 * Copyright (C) Research In Motion Limited 2010-2012. All rights reserved.
9 * Copyright (C) 2012 Google Inc. 9 * Copyright (C) 2012 Google Inc.
10 * 10 *
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 { 63 {
64 } 64 }
65 65
66 RenderSVGText::~RenderSVGText() 66 RenderSVGText::~RenderSVGText()
67 { 67 {
68 ASSERT(m_layoutAttributes.isEmpty()); 68 ASSERT(m_layoutAttributes.isEmpty());
69 } 69 }
70 70
71 bool RenderSVGText::isChildAllowed(RenderObject* child, RenderStyle*) const 71 bool RenderSVGText::isChildAllowed(RenderObject* child, RenderStyle*) const
72 { 72 {
73 return child->isSVGInline() || (child->isText() && !SVGRenderSupport::isEmpt ySVGInlineText(child)); 73 return child->isSVGInline() || (child->isText() && SVGRenderSupport::isRende rableTextNode(child));
74 } 74 }
75 75
76 RenderSVGText* RenderSVGText::locateRenderSVGTextAncestor(RenderObject* start) 76 RenderSVGText* RenderSVGText::locateRenderSVGTextAncestor(RenderObject* start)
77 { 77 {
78 ASSERT(start); 78 ASSERT(start);
79 while (start && !start->isSVGText()) 79 while (start && !start->isSVGText())
80 start = start->parent(); 80 start = start->parent();
81 if (!start || !start->isSVGText()) 81 if (!start || !start->isSVGText())
82 return 0; 82 return 0;
83 return toRenderSVGText(start); 83 return toRenderSVGText(start);
(...skipping 453 matching lines...) Expand 10 before | Expand all | Expand 10 after
537 return 0; 537 return 0;
538 } 538 }
539 539
540 // Fix for <rdar://problem/8048875>. We should not render :first-letter CSS Styl e 540 // Fix for <rdar://problem/8048875>. We should not render :first-letter CSS Styl e
541 // in a SVG text element context. 541 // in a SVG text element context.
542 void RenderSVGText::updateFirstLetter() 542 void RenderSVGText::updateFirstLetter()
543 { 543 {
544 } 544 }
545 545
546 } 546 }
OLDNEW
« no previous file with comments | « Source/core/rendering/svg/RenderSVGTSpan.cpp ('k') | Source/core/rendering/svg/RenderSVGTextPath.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698