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

Side by Side Diff: Source/core/rendering/RenderBlockFlow.h

Issue 397723006: Move RenderBlockFlow::constructTextRun out. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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
« no previous file with comments | « Source/core/rendering/RenderBlock.h ('k') | Source/core/rendering/RenderBlockFlow.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2007 David Smith (catfish.man@gmail.com) 4 * (C) 2007 David Smith (catfish.man@gmail.com)
5 * Copyright (C) 2003-2013 Apple Inc. All rights reserved. 5 * Copyright (C) 2003-2013 Apple Inc. All rights reserved.
6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
7 * Copyright (C) 2013 Google Inc. All rights reserved. 7 * Copyright (C) 2013 Google Inc. All rights reserved.
8 * 8 *
9 * Redistribution and use in source and binary forms, with or without 9 * Redistribution and use in source and binary forms, with or without
10 * modification, are permitted provided that the following conditions are 10 * modification, are permitted provided that the following conditions are
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
151 LayoutUnit startAlignedOffsetForLine(LayoutUnit position, bool shouldIndentT ext); 151 LayoutUnit startAlignedOffsetForLine(LayoutUnit position, bool shouldIndentT ext);
152 152
153 void setStaticInlinePositionForChild(RenderBox*, LayoutUnit inlinePosition); 153 void setStaticInlinePositionForChild(RenderBox*, LayoutUnit inlinePosition);
154 void updateStaticInlinePositionForChild(RenderBox*, LayoutUnit logicalTop); 154 void updateStaticInlinePositionForChild(RenderBox*, LayoutUnit logicalTop);
155 155
156 static bool shouldSkipCreatingRunsForObject(RenderObject* obj) 156 static bool shouldSkipCreatingRunsForObject(RenderObject* obj)
157 { 157 {
158 return obj->isFloating() || (obj->isOutOfFlowPositioned() && !obj->style ()->isOriginalDisplayInlineType() && !obj->container()->isRenderInline()); 158 return obj->isFloating() || (obj->isOutOfFlowPositioned() && !obj->style ()->isOriginalDisplayInlineType() && !obj->container()->isRenderInline());
159 } 159 }
160 160
161 // Direction resolved from string value.
162 static TextRun constructTextRun(RenderObject* context, const Font&, const St ring&, RenderStyle*,
163 TextRun::ExpansionBehavior = TextRun::AllowTrailingExpansion | TextRun:: ForbidLeadingExpansion, TextRunFlags = DefaultTextRunFlags);
164 static TextRun constructTextRun(RenderObject* context, const Font&, const Re nderText*, unsigned offset, unsigned length, RenderStyle*,
165 TextRun::ExpansionBehavior = TextRun::AllowTrailingExpansion | TextRun:: ForbidLeadingExpansion);
166
167 // Explicit direction.
168 static TextRun constructTextRun(RenderObject* context, const Font&, const St ring&, RenderStyle*, TextDirection,
169 TextRun::ExpansionBehavior = TextRun::AllowTrailingExpansion | TextRun:: ForbidLeadingExpansion, TextRunFlags = DefaultTextRunFlags);
170
171 static TextRun constructTextRun(RenderObject* context, const Font&, const Re nderText*, RenderStyle*, TextDirection,
172 TextRun::ExpansionBehavior = TextRun::AllowTrailingExpansion | TextRun:: ForbidLeadingExpansion);
173
174 static TextRun constructTextRun(RenderObject* context, const Font&, const Re nderText*, unsigned offset, unsigned length, RenderStyle*, TextDirection,
175 TextRun::ExpansionBehavior = TextRun::AllowTrailingExpansion | TextRun:: ForbidLeadingExpansion);
176
177 static TextRun constructTextRun(RenderObject* context, const Font&, const Re nderText*, unsigned offset, RenderStyle*,
178 TextRun::ExpansionBehavior = TextRun::AllowTrailingExpansion | TextRun:: ForbidLeadingExpansion);
179
180 static TextRun constructTextRun(RenderObject* context, const Font&, const LC har* characters, int length, RenderStyle*, TextDirection,
181 TextRun::ExpansionBehavior = TextRun::AllowTrailingExpansion | TextRun:: ForbidLeadingExpansion);
182
183 static TextRun constructTextRun(RenderObject* context, const Font&, const UC har* characters, int length, RenderStyle*, TextDirection,
184 TextRun::ExpansionBehavior = TextRun::AllowTrailingExpansion | TextRun:: ForbidLeadingExpansion);
185
186 RenderMultiColumnFlowThread* multiColumnFlowThread() const { return m_rareDa ta ? m_rareData->m_multiColumnFlowThread : 0; } 161 RenderMultiColumnFlowThread* multiColumnFlowThread() const { return m_rareDa ta ? m_rareData->m_multiColumnFlowThread : 0; }
187 void resetMultiColumnFlowThread() 162 void resetMultiColumnFlowThread()
188 { 163 {
189 if (m_rareData) 164 if (m_rareData)
190 m_rareData->m_multiColumnFlowThread = 0; 165 m_rareData->m_multiColumnFlowThread = 0;
191 } 166 }
192 167
193 void addOverflowFromInlineChildren(); 168 void addOverflowFromInlineChildren();
194 169
195 // FIXME: This should be const to avoid a const_cast, but can modify child d irty bits and RenderCombineText 170 // FIXME: This should be const to avoid a const_cast, but can modify child d irty bits and RenderCombineText
(...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after
497 472
498 // END METHODS DEFINED IN RenderBlockLineLayout 473 // END METHODS DEFINED IN RenderBlockLineLayout
499 474
500 }; 475 };
501 476
502 DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderBlockFlow, isRenderBlockFlow()); 477 DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderBlockFlow, isRenderBlockFlow());
503 478
504 } // namespace WebCore 479 } // namespace WebCore
505 480
506 #endif // RenderBlockFlow_h 481 #endif // RenderBlockFlow_h
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderBlock.h ('k') | Source/core/rendering/RenderBlockFlow.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698