diff options
author | Ben Murdoch <benm@google.com> | 2011-05-24 11:24:40 +0100 |
---|---|---|
committer | Ben Murdoch <benm@google.com> | 2011-06-02 09:53:15 +0100 |
commit | 81bc750723a18f21cd17d1b173cd2a4dda9cea6e (patch) | |
tree | 7a9e5ed86ff429fd347a25153107221543909b19 /Source/WebCore/rendering/InlineTextBox.h | |
parent | 94088a6d336c1dd80a1e734af51e96abcbb689a7 (diff) | |
download | external_webkit-81bc750723a18f21cd17d1b173cd2a4dda9cea6e.zip external_webkit-81bc750723a18f21cd17d1b173cd2a4dda9cea6e.tar.gz external_webkit-81bc750723a18f21cd17d1b173cd2a4dda9cea6e.tar.bz2 |
Merge WebKit at r80534: Intial merge by Git
Change-Id: Ia7a83357124c9e1cdb1debf55d9661ec0bd09a61
Diffstat (limited to 'Source/WebCore/rendering/InlineTextBox.h')
-rw-r--r-- | Source/WebCore/rendering/InlineTextBox.h | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/Source/WebCore/rendering/InlineTextBox.h b/Source/WebCore/rendering/InlineTextBox.h index 095fa16..a900a71 100644 --- a/Source/WebCore/rendering/InlineTextBox.h +++ b/Source/WebCore/rendering/InlineTextBox.h @@ -112,12 +112,12 @@ public: private: virtual void clearTruncation() { m_truncation = cNoTruncation; } - virtual int placeEllipsisBox(bool flowIsLTR, int visibleLeftEdge, int visibleRightEdge, int ellipsisWidth, bool& foundBox); + virtual float placeEllipsisBox(bool flowIsLTR, float visibleLeftEdge, float visibleRightEdge, float ellipsisWidth, bool& foundBox); public: virtual bool isLineBreak() const; - void setExpansion(int expansion) { m_logicalWidth -= m_expansion; m_expansion = expansion; m_logicalWidth += m_expansion; } + void setExpansion(float expansion) { m_logicalWidth -= m_expansion; m_expansion = expansion; m_logicalWidth += m_expansion; } private: virtual bool isInlineTextBox() const { return true; } @@ -129,11 +129,11 @@ public: private: virtual unsigned caretMaxRenderedOffset() const; - int textPos() const; // returns the x position relative to the left start of the text line. + float textPos() const; // returns the x position relative to the left start of the text line. public: - virtual int offsetForPosition(int x, bool includePartialGlyphs = true) const; - virtual int positionForOffset(int offset) const; + virtual int offsetForPosition(float x, bool includePartialGlyphs = true) const; + virtual float positionForOffset(int offset) const; bool containsCaretOffset(int offset) const; // false for offset after line break @@ -154,18 +154,18 @@ private: #endif protected: - void paintCompositionBackground(GraphicsContext*, const IntPoint& boxOrigin, RenderStyle*, const Font&, int startPos, int endPos); - void paintDocumentMarkers(GraphicsContext*, const IntPoint& boxOrigin, RenderStyle*, const Font&, bool background); - void paintCompositionUnderline(GraphicsContext*, const IntPoint& boxOrigin, const CompositionUnderline&); + void paintCompositionBackground(GraphicsContext*, const FloatPoint& boxOrigin, RenderStyle*, const Font&, int startPos, int endPos); + void paintDocumentMarkers(GraphicsContext*, const FloatPoint& boxOrigin, RenderStyle*, const Font&, bool background); + void paintCompositionUnderline(GraphicsContext*, const FloatPoint& boxOrigin, const CompositionUnderline&); #if PLATFORM(MAC) void paintCustomHighlight(int tx, int ty, const AtomicString& type); #endif private: - void paintDecoration(GraphicsContext*, const IntPoint& boxOrigin, int decoration, const ShadowData*); - void paintSelection(GraphicsContext*, const IntPoint& boxOrigin, RenderStyle*, const Font&); - void paintSpellingOrGrammarMarker(GraphicsContext*, const IntPoint& boxOrigin, const DocumentMarker&, RenderStyle*, const Font&, bool grammar); - void paintTextMatchMarker(GraphicsContext*, const IntPoint& boxOrigin, const DocumentMarker&, RenderStyle*, const Font&); + void paintDecoration(GraphicsContext*, const FloatPoint& boxOrigin, int decoration, const ShadowData*); + void paintSelection(GraphicsContext*, const FloatPoint& boxOrigin, RenderStyle*, const Font&); + void paintSpellingOrGrammarMarker(GraphicsContext*, const FloatPoint& boxOrigin, const DocumentMarker&, RenderStyle*, const Font&, bool grammar); + void paintTextMatchMarker(GraphicsContext*, const FloatPoint& boxOrigin, const DocumentMarker&, RenderStyle*, const Font&); void computeRectForReplacementMarker(const DocumentMarker&, RenderStyle*, const Font&); TextRun::TrailingExpansionBehavior trailingExpansionBehavior() const { return m_expansion && nextLeafChild() ? TextRun::AllowTrailingExpansion : TextRun::ForbidTrailingExpansion; } |