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

Unified Diff: Source/platform/fonts/harfbuzz/FontPlatformDataHarfBuzz.cpp

Issue 138273018: Use synthetic bold/italic terminology consistently (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 11 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
Index: Source/platform/fonts/harfbuzz/FontPlatformDataHarfBuzz.cpp
diff --git a/Source/platform/fonts/harfbuzz/FontPlatformDataHarfBuzz.cpp b/Source/platform/fonts/harfbuzz/FontPlatformDataHarfBuzz.cpp
index 2c8ec376e57b49f801ad8acfd63a25f58a9e9686..c8f143086d2ff9fb731709f9c7f1fbba514aeca9 100644
--- a/Source/platform/fonts/harfbuzz/FontPlatformDataHarfBuzz.cpp
+++ b/Source/platform/fonts/harfbuzz/FontPlatformDataHarfBuzz.cpp
@@ -80,8 +80,8 @@ void FontPlatformData::setSubpixelRendering(bool useSubpixelRendering)
FontPlatformData::FontPlatformData(WTF::HashTableDeletedValueType)
: m_textSize(0)
, m_emSizeInFontUnits(0)
- , m_fakeBold(false)
- , m_fakeItalic(false)
+ , m_syntheticBold(false)
+ , m_syntheticItalic(false)
, m_orientation(Horizontal)
, m_isHashTableDeletedValue(true)
{
@@ -90,18 +90,18 @@ FontPlatformData::FontPlatformData(WTF::HashTableDeletedValueType)
FontPlatformData::FontPlatformData()
: m_textSize(0)
, m_emSizeInFontUnits(0)
- , m_fakeBold(false)
- , m_fakeItalic(false)
+ , m_syntheticBold(false)
+ , m_syntheticItalic(false)
, m_orientation(Horizontal)
, m_isHashTableDeletedValue(false)
{
}
-FontPlatformData::FontPlatformData(float textSize, bool fakeBold, bool fakeItalic)
+FontPlatformData::FontPlatformData(float textSize, bool syntheticBold, bool syntheticItalic)
: m_textSize(textSize)
, m_emSizeInFontUnits(0)
- , m_fakeBold(fakeBold)
- , m_fakeItalic(fakeItalic)
+ , m_syntheticBold(syntheticBold)
+ , m_syntheticItalic(syntheticItalic)
, m_orientation(Horizontal)
, m_isHashTableDeletedValue(false)
{
@@ -112,8 +112,8 @@ FontPlatformData::FontPlatformData(const FontPlatformData& src)
, m_family(src.m_family)
, m_textSize(src.m_textSize)
, m_emSizeInFontUnits(src.m_emSizeInFontUnits)
- , m_fakeBold(src.m_fakeBold)
- , m_fakeItalic(src.m_fakeItalic)
+ , m_syntheticBold(src.m_syntheticBold)
+ , m_syntheticItalic(src.m_syntheticItalic)
, m_orientation(src.m_orientation)
, m_style(src.m_style)
, m_harfBuzzFace(0)
@@ -121,13 +121,13 @@ FontPlatformData::FontPlatformData(const FontPlatformData& src)
{
}
-FontPlatformData::FontPlatformData(PassRefPtr<SkTypeface> tf, const char* family, float textSize, bool fakeBold, bool fakeItalic, FontOrientation orientation, bool subpixelTextPosition)
+FontPlatformData::FontPlatformData(PassRefPtr<SkTypeface> tf, const char* family, float textSize, bool syntheticBold, bool syntheticItalic, FontOrientation orientation, bool subpixelTextPosition)
: m_typeface(tf)
, m_family(family)
, m_textSize(textSize)
, m_emSizeInFontUnits(0)
- , m_fakeBold(fakeBold)
- , m_fakeItalic(fakeItalic)
+ , m_syntheticBold(syntheticBold)
+ , m_syntheticItalic(syntheticItalic)
, m_orientation(orientation)
, m_isHashTableDeletedValue(false)
{
@@ -139,8 +139,8 @@ FontPlatformData::FontPlatformData(const FontPlatformData& src, float textSize)
, m_family(src.m_family)
, m_textSize(textSize)
, m_emSizeInFontUnits(src.m_emSizeInFontUnits)
- , m_fakeBold(src.m_fakeBold)
- , m_fakeItalic(src.m_fakeItalic)
+ , m_syntheticBold(src.m_syntheticBold)
+ , m_syntheticItalic(src.m_syntheticItalic)
, m_orientation(src.m_orientation)
, m_harfBuzzFace(0)
, m_isHashTableDeletedValue(false)
@@ -166,8 +166,8 @@ FontPlatformData& FontPlatformData::operator=(const FontPlatformData& src)
m_typeface = src.m_typeface;
m_family = src.m_family;
m_textSize = src.m_textSize;
- m_fakeBold = src.m_fakeBold;
- m_fakeItalic = src.m_fakeItalic;
+ m_syntheticBold = src.m_syntheticBold;
+ m_syntheticItalic = src.m_syntheticItalic;
m_harfBuzzFace = 0;
m_orientation = src.m_orientation;
m_style = src.m_style;
@@ -201,8 +201,8 @@ void FontPlatformData::setupPaint(SkPaint* paint, GraphicsContext*) const
const float ts = m_textSize >= 0 ? m_textSize : 12;
paint->setTextSize(SkFloatToScalar(ts));
paint->setTypeface(m_typeface.get());
- paint->setFakeBoldText(m_fakeBold);
- paint->setTextSkewX(m_fakeItalic ? -SK_Scalar1 / 4 : 0);
+ paint->setFakeBoldText(m_syntheticBold);
+ paint->setTextSkewX(m_syntheticItalic ? -SK_Scalar1 / 4 : 0);
}
SkFontID FontPlatformData::uniqueID() const
@@ -234,8 +234,8 @@ bool FontPlatformData::operator==(const FontPlatformData& a) const
return typefacesEqual
&& m_textSize == a.m_textSize
- && m_fakeBold == a.m_fakeBold
- && m_fakeItalic == a.m_fakeItalic
+ && m_syntheticBold == a.m_syntheticBold
+ && m_syntheticItalic == a.m_syntheticItalic
&& m_orientation == a.m_orientation
&& m_style == a.m_style
&& m_isHashTableDeletedValue == a.m_isHashTableDeletedValue;
« no previous file with comments | « Source/platform/fonts/harfbuzz/FontPlatformDataHarfBuzz.h ('k') | Source/platform/fonts/skia/FontCacheSkia.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698