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

Side by Side Diff: Source/core/layout/line/BreakingContextInlineHeaders.h

Issue 1318713003: Make classes and structures in core/layout fast-allocated. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 3 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org)
3 * Copyright (C) 2003, 2004, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ight reserved. 3 * Copyright (C) 2003, 2004, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ight reserved.
4 * Copyright (C) 2010 Google Inc. All rights reserved. 4 * Copyright (C) 2010 Google Inc. All rights reserved.
5 * Copyright (C) 2013 Adobe Systems Incorporated. 5 * Copyright (C) 2013 Adobe Systems Incorporated.
6 * 6 *
7 * This library is free software; you can redistribute it and/or 7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public 8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either 9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version. 10 * version 2 of the License, or (at your option) any later version.
(...skipping 24 matching lines...) Expand all
35 #include "core/layout/line/InlineTextBox.h" 35 #include "core/layout/line/InlineTextBox.h"
36 #include "core/layout/line/LayoutTextInfo.h" 36 #include "core/layout/line/LayoutTextInfo.h"
37 #include "core/layout/line/LineBreaker.h" 37 #include "core/layout/line/LineBreaker.h"
38 #include "core/layout/line/LineInfo.h" 38 #include "core/layout/line/LineInfo.h"
39 #include "core/layout/line/LineWidth.h" 39 #include "core/layout/line/LineWidth.h"
40 #include "core/layout/line/TrailingObjects.h" 40 #include "core/layout/line/TrailingObjects.h"
41 #include "core/layout/line/WordMeasurement.h" 41 #include "core/layout/line/WordMeasurement.h"
42 #include "core/layout/svg/LayoutSVGInlineText.h" 42 #include "core/layout/svg/LayoutSVGInlineText.h"
43 #include "core/paint/DeprecatedPaintLayer.h" 43 #include "core/paint/DeprecatedPaintLayer.h"
44 #include "platform/text/TextBreakIterator.h" 44 #include "platform/text/TextBreakIterator.h"
45 #include "wtf/Allocator.h"
45 #include "wtf/Vector.h" 46 #include "wtf/Vector.h"
46 47
47 namespace blink { 48 namespace blink {
48 49
49 // We don't let our line box tree for a single line get any deeper than this. 50 // We don't let our line box tree for a single line get any deeper than this.
50 const unsigned cMaxLineDepth = 200; 51 const unsigned cMaxLineDepth = 200;
51 52
52 class BreakingContext { 53 class BreakingContext {
54 STACK_ALLOCATED();
53 public: 55 public:
54 BreakingContext(InlineBidiResolver& resolver, LineInfo& inLineInfo, LineWidt h& lineWidth, LayoutTextInfo& inLayoutTextInfo, FloatingObject* inLastFloatFromP reviousLine, bool appliedStartWidth, LineLayoutBlockFlow block) 56 BreakingContext(InlineBidiResolver& resolver, LineInfo& inLineInfo, LineWidt h& lineWidth, LayoutTextInfo& inLayoutTextInfo, FloatingObject* inLastFloatFromP reviousLine, bool appliedStartWidth, LineLayoutBlockFlow block)
55 : m_resolver(resolver) 57 : m_resolver(resolver)
56 , m_current(resolver.position()) 58 , m_current(resolver.position())
57 , m_lineBreak(resolver.position()) 59 , m_lineBreak(resolver.position())
58 , m_block(block) 60 , m_block(block)
59 , m_lastObject(m_current.object()) 61 , m_lastObject(m_current.object())
60 , m_nextObject(nullptr) 62 , m_nextObject(nullptr)
61 , m_currentStyle(nullptr) 63 , m_currentStyle(nullptr)
62 , m_blockStyle(block.style()) 64 , m_blockStyle(block.style())
(...skipping 847 matching lines...) Expand 10 before | Expand all | Expand 10 after
910 912
911 if (style.textIndentType() == TextIndentHanging) 913 if (style.textIndentType() == TextIndentHanging)
912 shouldIndentText = shouldIndentText == IndentText ? DoNotIndentText : In dentText; 914 shouldIndentText = shouldIndentText == IndentText ? DoNotIndentText : In dentText;
913 915
914 return shouldIndentText; 916 return shouldIndentText;
915 } 917 }
916 918
917 } 919 }
918 920
919 #endif // BreakingContextInlineHeaders_h 921 #endif // BreakingContextInlineHeaders_h
OLDNEW
« no previous file with comments | « Source/core/layout/line/AbstractInlineTextBox.h ('k') | Source/core/layout/line/GlyphOverflow.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698