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

Unified Diff: Source/core/platform/graphics/chromium/FontPlatformDataChromiumWin.h

Issue 24874002: Have all skia platforms share FontPlatformData::hash() implementation (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/core/platform/graphics/chromium/FontPlatformDataChromiumWin.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/platform/graphics/chromium/FontPlatformDataChromiumWin.h
diff --git a/Source/core/platform/graphics/chromium/FontPlatformDataChromiumWin.h b/Source/core/platform/graphics/chromium/FontPlatformDataChromiumWin.h
index 35c18f2baf72c34cd260a04eb43743c0c49785ac..73ac10115cda6f30d13c3ceafee7f84118a35605 100644
--- a/Source/core/platform/graphics/chromium/FontPlatformDataChromiumWin.h
+++ b/Source/core/platform/graphics/chromium/FontPlatformDataChromiumWin.h
@@ -87,7 +87,7 @@ public:
bool isFixedPitch() const;
HFONT hfont() const { return m_font ? m_font->hfont() : 0; }
- float size() const { return m_size; }
+ float size() const { return m_textSize; }
SkTypeface* typeface() const { return m_typeface.get(); }
int paintTextFlags() const { return m_paintTextFlags; }
@@ -96,14 +96,18 @@ public:
FontOrientation orientation() const { return m_orientation; }
void setOrientation(FontOrientation orientation) { m_orientation = orientation; }
+#if ENABLE(GDI_FONTS_ON_WINDOWS)
unsigned hash() const
{
return m_font ? m_font->hash() : NULL;
}
+#else
+ unsigned hash() const;
+#endif
bool operator==(const FontPlatformData& other) const
{
- return m_font == other.m_font && m_size == other.m_size && m_fakeBold == other.m_fakeBold && m_fakeItalic == other.m_fakeItalic && m_orientation == other.m_orientation;
+ return m_font == other.m_font && m_textSize == other.m_textSize && m_fakeBold == other.m_fakeBold && m_fakeItalic == other.m_fakeItalic && m_orientation == other.m_orientation;
}
#if ENABLE(OPENTYPE_VERTICAL)
@@ -155,7 +159,7 @@ private:
};
RefPtr<RefCountedHFONT> m_font;
- float m_size; // Point size of the font in pixels.
+ float m_textSize; // Point size of the font in pixels.
FontOrientation m_orientation;
bool m_fakeBold;
bool m_fakeItalic;
« no previous file with comments | « no previous file | Source/core/platform/graphics/chromium/FontPlatformDataChromiumWin.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698