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

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

Issue 977113003: Rename renderer() to layoutObject(). (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 9 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/layout/line/EllipsisBox.cpp ('k') | Source/core/layout/line/InlineBox.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) 2003, 2004, 2005, 2006, 2007, 2009, 2010, 2011 Apple Inc. All r ights reserved. 2 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2009, 2010, 2011 Apple Inc. All r ights reserved.
3 * 3 *
4 * This library is free software; you can redistribute it and/or 4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public 5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; either 6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version. 7 * version 2 of the License, or (at your option) any later version.
8 * 8 *
9 * This library is distributed in the hope that it will be useful, 9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 172
173 InlineBox* nextLeafChild() const; 173 InlineBox* nextLeafChild() const;
174 InlineBox* prevLeafChild() const; 174 InlineBox* prevLeafChild() const;
175 175
176 // Helper functions for editing and hit-testing code. 176 // Helper functions for editing and hit-testing code.
177 // FIXME: These two functions should be moved to RenderedPosition once the c ode to convert between 177 // FIXME: These two functions should be moved to RenderedPosition once the c ode to convert between
178 // Position and inline box, offset pair is moved to RenderedPosition. 178 // Position and inline box, offset pair is moved to RenderedPosition.
179 InlineBox* nextLeafChildIgnoringLineBreak() const; 179 InlineBox* nextLeafChildIgnoringLineBreak() const;
180 InlineBox* prevLeafChildIgnoringLineBreak() const; 180 InlineBox* prevLeafChildIgnoringLineBreak() const;
181 181
182 LayoutObject& renderer() const { return m_renderer; } 182 LayoutObject& layoutObject() const { return m_renderer; }
183 183
184 InlineFlowBox* parent() const 184 InlineFlowBox* parent() const
185 { 185 {
186 ASSERT(!m_hasBadParent); 186 ASSERT(!m_hasBadParent);
187 return m_parent; 187 return m_parent;
188 } 188 }
189 void setParent(InlineFlowBox* par) { m_parent = par; } 189 void setParent(InlineFlowBox* par) { m_parent = par; }
190 190
191 const RootInlineBox& root() const; 191 const RootInlineBox& root() const;
192 RootInlineBox& root(); 192 RootInlineBox& root();
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
269 virtual bool canAccommodateEllipsis(bool ltr, int blockEdge, int ellipsisWid th) const; 269 virtual bool canAccommodateEllipsis(bool ltr, int blockEdge, int ellipsisWid th) const;
270 // visibleLeftEdge, visibleRightEdge are in the parent's coordinate system. 270 // visibleLeftEdge, visibleRightEdge are in the parent's coordinate system.
271 virtual FloatWillBeLayoutUnit placeEllipsisBox(bool ltr, FloatWillBeLayoutUn it visibleLeftEdge, FloatWillBeLayoutUnit visibleRightEdge, FloatWillBeLayoutUni t ellipsisWidth, FloatWillBeLayoutUnit &truncatedWidth, bool&); 271 virtual FloatWillBeLayoutUnit placeEllipsisBox(bool ltr, FloatWillBeLayoutUn it visibleLeftEdge, FloatWillBeLayoutUnit visibleRightEdge, FloatWillBeLayoutUni t ellipsisWidth, FloatWillBeLayoutUnit &truncatedWidth, bool&);
272 272
273 #if ENABLE(ASSERT) 273 #if ENABLE(ASSERT)
274 void setHasBadParent(); 274 void setHasBadParent();
275 #endif 275 #endif
276 276
277 int expansion() const { return m_bitfields.expansion(); } 277 int expansion() const { return m_bitfields.expansion(); }
278 278
279 bool visibleToHitTestRequest(const HitTestRequest& request) const { return r enderer().visibleToHitTestRequest(request); } 279 bool visibleToHitTestRequest(const HitTestRequest& request) const { return l ayoutObject().visibleToHitTestRequest(request); }
280 280
281 EVerticalAlign verticalAlign() const { return renderer().style(m_bitfields.f irstLine())->verticalAlign(); } 281 EVerticalAlign verticalAlign() const { return layoutObject().style(m_bitfiel ds.firstLine())->verticalAlign(); }
282 282
283 // Use with caution! The type is not checked! 283 // Use with caution! The type is not checked!
284 LayoutBoxModelObject* boxModelObject() const 284 LayoutBoxModelObject* boxModelObject() const
285 { 285 {
286 if (!renderer().isText()) 286 if (!layoutObject().isText())
287 return toLayoutBoxModelObject(&renderer()); 287 return toLayoutBoxModelObject(&layoutObject());
288 return 0; 288 return 0;
289 } 289 }
290 290
291 FloatPointWillBeLayoutPoint locationIncludingFlipping(); 291 FloatPointWillBeLayoutPoint locationIncludingFlipping();
292 void flipForWritingMode(FloatRect&); 292 void flipForWritingMode(FloatRect&);
293 FloatPoint flipForWritingMode(const FloatPoint&); 293 FloatPoint flipForWritingMode(const FloatPoint&);
294 void flipForWritingMode(LayoutRect&); 294 void flipForWritingMode(LayoutRect&);
295 LayoutPoint flipForWritingMode(const LayoutPoint&); 295 LayoutPoint flipForWritingMode(const LayoutPoint&);
296 296
297 bool knownToHaveNoOverflow() const { return m_bitfields.knownToHaveNoOverflo w(); } 297 bool knownToHaveNoOverflow() const { return m_bitfields.knownToHaveNoOverflo w(); }
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
439 439
440 } // namespace blink 440 } // namespace blink
441 441
442 #ifndef NDEBUG 442 #ifndef NDEBUG
443 // Outside the WebCore namespace for ease of invocation from gdb. 443 // Outside the WebCore namespace for ease of invocation from gdb.
444 void showTree(const blink::InlineBox*); 444 void showTree(const blink::InlineBox*);
445 void showLineTree(const blink::InlineBox*); 445 void showLineTree(const blink::InlineBox*);
446 #endif 446 #endif
447 447
448 #endif // InlineBox_h 448 #endif // InlineBox_h
OLDNEW
« no previous file with comments | « Source/core/layout/line/EllipsisBox.cpp ('k') | Source/core/layout/line/InlineBox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698