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

Side by Side Diff: Source/core/layout/svg/SVGLayoutTreeAsText.cpp

Issue 1043643002: Switch line layout to LayoutUnit. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: More TestExpectations tweaks Created 5 years, 6 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) 2004, 2005, 2007, 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2004, 2005, 2007, 2009 Apple Inc. All rights reserved.
3 * (C) 2005 Rob Buis <buis@kde.org> 3 * (C) 2005 Rob Buis <buis@kde.org>
4 * (C) 2006 Alexander Kellett <lypanov@kde.org> 4 * (C) 2006 Alexander Kellett <lypanov@kde.org>
5 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 5 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
6 * 6 *
7 * Redistribution and use in source and binary forms, with or without 7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions 8 * modification, are permitted provided that the following conditions
9 * are met: 9 * are met:
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after
378 { 378 {
379 return writePositionAndStyle(ts, root); 379 return writePositionAndStyle(ts, root);
380 } 380 }
381 381
382 static void writeLayoutSVGTextBox(TextStream& ts, const LayoutSVGText& text) 382 static void writeLayoutSVGTextBox(TextStream& ts, const LayoutSVGText& text)
383 { 383 {
384 SVGRootInlineBox* box = toSVGRootInlineBox(text.firstRootBox()); 384 SVGRootInlineBox* box = toSVGRootInlineBox(text.firstRootBox());
385 if (!box) 385 if (!box)
386 return; 386 return;
387 387
388 ts << " " << enclosingIntRect(FloatRect(FloatPoint(text.location()), FloatSi ze(box->logicalWidth(), box->logicalHeight()))); 388 ts << " " << enclosingIntRect(LayoutRect(LayoutPoint(text.location()), Layou tSize(box->logicalWidth(), box->logicalHeight())));
389 389
390 // FIXME: Remove this hack, once the new text layout engine is completly lan ded. We want to preserve the old layout test results for now. 390 // FIXME: Remove this hack, once the new text layout engine is completly lan ded. We want to preserve the old layout test results for now.
391 ts << " contains 1 chunk(s)"; 391 ts << " contains 1 chunk(s)";
392 392
393 if (text.parent() && (text.parent()->resolveColor(CSSPropertyColor) != text. resolveColor(CSSPropertyColor))) 393 if (text.parent() && (text.parent()->resolveColor(CSSPropertyColor) != text. resolveColor(CSSPropertyColor)))
394 writeNameValuePair(ts, "color", text.resolveColor(CSSPropertyColor).name ForLayoutTreeAsText()); 394 writeNameValuePair(ts, "color", text.resolveColor(CSSPropertyColor).name ForLayoutTreeAsText());
395 } 395 }
396 396
397 static inline void writeSVGInlineTextBox(TextStream& ts, SVGInlineTextBox* textB ox, int indent) 397 static inline void writeSVGInlineTextBox(TextStream& ts, SVGInlineTextBox* textB ox, int indent)
398 { 398 {
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after
670 ts << " "; 670 ts << " ";
671 writeNameAndQuotedValue(ts, "filter", svgStyle.filterResource()); 671 writeNameAndQuotedValue(ts, "filter", svgStyle.filterResource());
672 ts << " "; 672 ts << " ";
673 writeStandardPrefix(ts, *filter, 0); 673 writeStandardPrefix(ts, *filter, 0);
674 ts << " " << filter->resourceBoundingBox(&layoutObject) << "\n"; 674 ts << " " << filter->resourceBoundingBox(&layoutObject) << "\n";
675 } 675 }
676 } 676 }
677 } 677 }
678 678
679 } // namespace blink 679 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/layout/svg/LayoutSVGInlineText.cpp ('k') | Source/core/layout/svg/line/SVGInlineFlowBox.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698