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

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

Issue 412353004: Clean up GraphicsLayerPaintInfo to remove unused or unnecessary fields. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: f Created 6 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/rendering/RenderObject.h ('k') | Source/core/rendering/RenderText.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 * (C) 1999 Lars Knoll (knoll@kde.org) 2 * (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 2000 Dirk Mueller (mueller@kde.org) 3 * (C) 2000 Dirk Mueller (mueller@kde.org)
4 * Copyright (C) 2004-2009, 2013 Apple Inc. All rights reserved. 4 * Copyright (C) 2004-2009, 2013 Apple Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 113
114 virtual bool canBeSelectionLeaf() const OVERRIDE { return true; } 114 virtual bool canBeSelectionLeaf() const OVERRIDE { return true; }
115 virtual void setSelectionState(SelectionState s) OVERRIDE FINAL; 115 virtual void setSelectionState(SelectionState s) OVERRIDE FINAL;
116 virtual LayoutRect selectionRectForPaintInvalidation(const RenderLayerModelO bject* paintInvalidationContainer, bool clipToVisibleContent = true) OVERRIDE; 116 virtual LayoutRect selectionRectForPaintInvalidation(const RenderLayerModelO bject* paintInvalidationContainer, bool clipToVisibleContent = true) OVERRIDE;
117 virtual LayoutRect localCaretRect(InlineBox*, int caretOffset, LayoutUnit* e xtraWidthToEndOfLine = 0) OVERRIDE; 117 virtual LayoutRect localCaretRect(InlineBox*, int caretOffset, LayoutUnit* e xtraWidthToEndOfLine = 0) OVERRIDE;
118 118
119 LayoutUnit marginLeft() const { return minimumValueForLength(style()->margin Left(), 0); } 119 LayoutUnit marginLeft() const { return minimumValueForLength(style()->margin Left(), 0); }
120 LayoutUnit marginRight() const { return minimumValueForLength(style()->margi nRight(), 0); } 120 LayoutUnit marginRight() const { return minimumValueForLength(style()->margi nRight(), 0); }
121 121
122 virtual LayoutRect clippedOverflowRectForPaintInvalidation(const RenderLayer ModelObject* paintInvalidationContainer, const PaintInvalidationState* = 0) cons t OVERRIDE FINAL; 122 virtual LayoutRect clippedOverflowRectForPaintInvalidation(const RenderLayer ModelObject* paintInvalidationContainer, const PaintInvalidationState* = 0) cons t OVERRIDE FINAL;
123 virtual const RenderLayerModelObject* containerForPaintInvalidation() const OVERRIDE;
123 124
124 InlineTextBox* firstTextBox() const { return m_firstTextBox; } 125 InlineTextBox* firstTextBox() const { return m_firstTextBox; }
125 InlineTextBox* lastTextBox() const { return m_lastTextBox; } 126 InlineTextBox* lastTextBox() const { return m_lastTextBox; }
126 127
127 virtual int caretMinOffset() const OVERRIDE; 128 virtual int caretMinOffset() const OVERRIDE;
128 virtual int caretMaxOffset() const OVERRIDE; 129 virtual int caretMaxOffset() const OVERRIDE;
129 unsigned renderedTextLength() const; 130 unsigned renderedTextLength() const;
130 131
131 virtual int previousOffset(int current) const OVERRIDE FINAL; 132 virtual int previousOffset(int current) const OVERRIDE FINAL;
132 virtual int previousOffsetForBackwardDeletion(int current) const OVERRIDE FI NAL; 133 virtual int previousOffsetForBackwardDeletion(int current) const OVERRIDE FI NAL;
(...skipping 21 matching lines...) Expand all
154 virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle) OV ERRIDE; 155 virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle) OV ERRIDE;
155 156
156 virtual void setTextInternal(PassRefPtr<StringImpl>); 157 virtual void setTextInternal(PassRefPtr<StringImpl>);
157 virtual UChar previousCharacter() const; 158 virtual UChar previousCharacter() const;
158 159
159 virtual void addLayerHitTestRects(LayerHitTestRects&, const RenderLayer* cur rentLayer, const LayoutPoint& layerOffset, const LayoutRect& containerRect) cons t OVERRIDE; 160 virtual void addLayerHitTestRects(LayerHitTestRects&, const RenderLayer* cur rentLayer, const LayoutPoint& layerOffset, const LayoutRect& containerRect) cons t OVERRIDE;
160 161
161 virtual InlineTextBox* createTextBox(); // Subclassed by SVG. 162 virtual InlineTextBox* createTextBox(); // Subclassed by SVG.
162 163
163 private: 164 private:
165 // RenderText objects don't know how to invalidate paint for themselves, sin ce they don't know how to compute their bounds. Instead, they
166 // invalidate paint for the containing block or layer, as computed by this m ethod.
167 const RenderObject* containingObjectForPaintInvalidation() const;
168
164 void computePreferredLogicalWidths(float leadWidth); 169 void computePreferredLogicalWidths(float leadWidth);
165 void computePreferredLogicalWidths(float leadWidth, HashSet<const SimpleFont Data*>& fallbackFonts, GlyphOverflow&); 170 void computePreferredLogicalWidths(float leadWidth, HashSet<const SimpleFont Data*>& fallbackFonts, GlyphOverflow&);
166 171
167 bool computeCanUseSimpleFontCodePath() const; 172 bool computeCanUseSimpleFontCodePath() const;
168 173
169 // Make length() private so that callers that have a RenderText* 174 // Make length() private so that callers that have a RenderText*
170 // will use the more efficient textLength() instead, while 175 // will use the more efficient textLength() instead, while
171 // callers with a RenderObject* can continue to use length(). 176 // callers with a RenderObject* can continue to use length().
172 virtual unsigned length() const OVERRIDE FINAL { return textLength(); } 177 virtual unsigned length() const OVERRIDE FINAL { return textLength(); }
173 178
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
236 inline RenderText* Text::renderer() const 241 inline RenderText* Text::renderer() const
237 { 242 {
238 return toRenderText(CharacterData::renderer()); 243 return toRenderText(CharacterData::renderer());
239 } 244 }
240 245
241 void applyTextTransform(const RenderStyle*, String&, UChar); 246 void applyTextTransform(const RenderStyle*, String&, UChar);
242 247
243 } // namespace blink 248 } // namespace blink
244 249
245 #endif // RenderText_h 250 #endif // RenderText_h
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderObject.h ('k') | Source/core/rendering/RenderText.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698