| Index: Source/core/rendering/InlineTextBox.cpp
|
| diff --git a/Source/core/rendering/InlineTextBox.cpp b/Source/core/rendering/InlineTextBox.cpp
|
| index bea9c71653c2b7edfb7b3a01ab983b5e5829098c..dc45708006c91581c377b7af15d12ab66409a21d 100644
|
| --- a/Source/core/rendering/InlineTextBox.cpp
|
| +++ b/Source/core/rendering/InlineTextBox.cpp
|
| @@ -186,7 +186,7 @@ LayoutRect InlineTextBox::localSelectionRect(int startPos, int endPos)
|
|
|
| LayoutUnit selTop = root().selectionTop();
|
| LayoutUnit selHeight = root().selectionHeight();
|
| - RenderStyle* styleToUse = renderer().style(isFirstLineStyle());
|
| + const RenderStyle* styleToUse = renderer().style(isFirstLineStyle());
|
| const Font& font = styleToUse->font();
|
|
|
| StringBuilder charactersWithHyphen;
|
| @@ -329,7 +329,7 @@ bool InlineTextBox::nodeAtPoint(const HitTestRequest& request, HitTestResult& re
|
| return false;
|
| }
|
|
|
| -bool InlineTextBox::getEmphasisMarkPosition(RenderStyle* style, TextEmphasisPosition& emphasisPosition) const
|
| +bool InlineTextBox::getEmphasisMarkPosition(const RenderStyle* style, TextEmphasisPosition& emphasisPosition) const
|
| {
|
| // This function returns true if there are text emphasis marks and they are suppressed by ruby text.
|
| if (style->textEmphasisMark() == TextEmphasisMarkNone)
|
| @@ -375,12 +375,12 @@ void InlineTextBox::selectionStartEnd(int& sPos, int& ePos) const
|
| ePos = std::min(endPos - m_start, (int)m_len);
|
| }
|
|
|
| -void InlineTextBox::paintDocumentMarker(GraphicsContext* pt, const FloatPointWillBeLayoutPoint& boxOrigin, DocumentMarker* marker, RenderStyle* style, const Font& font, bool grammar)
|
| +void InlineTextBox::paintDocumentMarker(GraphicsContext* pt, const FloatPointWillBeLayoutPoint& boxOrigin, DocumentMarker* marker, const RenderStyle* style, const Font& font, bool grammar)
|
| {
|
| InlineTextBoxPainter(*this).paintDocumentMarker(pt, boxOrigin.toFloatPoint(), marker, style, font, grammar);
|
| }
|
|
|
| -void InlineTextBox::paintTextMatchMarker(GraphicsContext* pt, const FloatPointWillBeLayoutPoint& boxOrigin, DocumentMarker* marker, RenderStyle* style, const Font& font)
|
| +void InlineTextBox::paintTextMatchMarker(GraphicsContext* pt, const FloatPointWillBeLayoutPoint& boxOrigin, DocumentMarker* marker, const RenderStyle* style, const Font& font)
|
| {
|
| InlineTextBoxPainter(*this).paintTextMatchMarker(pt, boxOrigin.toFloatPoint(), marker, style, font);
|
| }
|
| @@ -415,7 +415,7 @@ int InlineTextBox::offsetForPosition(FloatWillBeLayoutUnit lineOffset, bool incl
|
| return isLeftToRightDirection() ? 0 : len();
|
|
|
| RenderText& text = renderer();
|
| - RenderStyle* style = text.style(isFirstLineStyle());
|
| + const RenderStyle* style = text.style(isFirstLineStyle());
|
| const Font& font = style->font();
|
| return font.offsetForPosition(constructTextRun(style, font), lineOffset - logicalLeft(), includePartialGlyphs);
|
| }
|
| @@ -429,7 +429,7 @@ FloatWillBeLayoutUnit InlineTextBox::positionForOffset(int offset) const
|
| return logicalLeft();
|
|
|
| RenderText& text = renderer();
|
| - RenderStyle* styleToUse = text.style(isFirstLineStyle());
|
| + const RenderStyle* styleToUse = text.style(isFirstLineStyle());
|
| ASSERT(styleToUse);
|
| const Font& font = styleToUse->font();
|
| int from = !isLeftToRightDirection() ? offset - m_start : 0;
|
| @@ -466,7 +466,7 @@ void InlineTextBox::characterWidths(Vector<FloatWillBeLayoutUnit>& widths) const
|
| {
|
| FontCachePurgePreventer fontCachePurgePreventer;
|
|
|
| - RenderStyle* styleToUse = renderer().style(isFirstLineStyle());
|
| + const RenderStyle* styleToUse = renderer().style(isFirstLineStyle());
|
| const Font& font = styleToUse->font();
|
|
|
| TextRun textRun = constructTextRun(styleToUse, font);
|
| @@ -481,7 +481,7 @@ void InlineTextBox::characterWidths(Vector<FloatWillBeLayoutUnit>& widths) const
|
| }
|
| }
|
|
|
| -TextRun InlineTextBox::constructTextRun(RenderStyle* style, const Font& font, StringBuilder* charactersWithHyphen) const
|
| +TextRun InlineTextBox::constructTextRun(const RenderStyle* style, const Font& font, StringBuilder* charactersWithHyphen) const
|
| {
|
| ASSERT(style);
|
| ASSERT(renderer().text());
|
| @@ -496,7 +496,7 @@ TextRun InlineTextBox::constructTextRun(RenderStyle* style, const Font& font, St
|
| return constructTextRun(style, font, string, renderer().textLength() - startPos, charactersWithHyphen);
|
| }
|
|
|
| -TextRun InlineTextBox::constructTextRun(RenderStyle* style, const Font& font, StringView string, int maximumLength, StringBuilder* charactersWithHyphen) const
|
| +TextRun InlineTextBox::constructTextRun(const RenderStyle* style, const Font& font, StringView string, int maximumLength, StringBuilder* charactersWithHyphen) const
|
| {
|
| ASSERT(style);
|
|
|
| @@ -522,7 +522,7 @@ TextRun InlineTextBox::constructTextRun(RenderStyle* style, const Font& font, St
|
| return run;
|
| }
|
|
|
| -TextRun InlineTextBox::constructTextRunForInspector(RenderStyle* style, const Font& font) const
|
| +TextRun InlineTextBox::constructTextRunForInspector(const RenderStyle* style, const Font& font) const
|
| {
|
| return InlineTextBox::constructTextRun(style, font);
|
| }
|
|
|