aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/ports
diff options
context:
space:
mode:
authorGravatar skia.committer@gmail.com <skia.committer@gmail.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2013-02-27 07:10:10 +0000
committerGravatar skia.committer@gmail.com <skia.committer@gmail.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2013-02-27 07:10:10 +0000
commit12eea2b10d6caaafe0a207d10b1e9322510983a2 (patch)
tree0c862c6a14aa41ee3c5d4e812fe936702d88095b /src/ports
parentee619a059a2cd7259226dc0c86a000e3bf5834de (diff)
Sanitizing source files in Skia_Periodic_House_Keeping
git-svn-id: http://skia.googlecode.com/svn/trunk@7875 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src/ports')
-rw-r--r--src/ports/SkFontConfigInterface_direct.cpp48
1 files changed, 23 insertions, 25 deletions
diff --git a/src/ports/SkFontConfigInterface_direct.cpp b/src/ports/SkFontConfigInterface_direct.cpp
index 0fac111c7d..84555a2304 100644
--- a/src/ports/SkFontConfigInterface_direct.cpp
+++ b/src/ports/SkFontConfigInterface_direct.cpp
@@ -164,25 +164,25 @@ FontEquivClass GetFontEquivClass(const char* fontname)
{ SIMHEI, "MYingHeiGB18030" },
{ SIMHEI, "MYingHeiB5HK" },
- // 新細明體
- { PMINGLIU, "PMingLiU"},
- { PMINGLIU, "\xe6\x96\xb0\xe7\xb4\xb0\xe6\x98\x8e\xe9\xab\x94" },
- { PMINGLIU, "MSung B5HK"},
-
- // 細明體
- { MINGLIU, "MingLiU"},
- { MINGLIU, "\xe7\xb4\xb0\xe6\x98\x8e\xe9\xab\x94" },
- { MINGLIU, "MSung B5HK"},
-
- // 新細明體
- { PMINGLIUHK, "PMingLiU_HKSCS"},
- { PMINGLIUHK, "\xe6\x96\xb0\xe7\xb4\xb0\xe6\x98\x8e\xe9\xab\x94_HKSCS" },
- { PMINGLIUHK, "MSung B5HK"},
-
- // 細明體
- { MINGLIUHK, "MingLiU_HKSCS"},
- { MINGLIUHK, "\xe7\xb4\xb0\xe6\x98\x8e\xe9\xab\x94_HKSCS" },
- { MINGLIUHK, "MSung B5HK"},
+ // 新細明體
+ { PMINGLIU, "PMingLiU"},
+ { PMINGLIU, "\xe6\x96\xb0\xe7\xb4\xb0\xe6\x98\x8e\xe9\xab\x94" },
+ { PMINGLIU, "MSung B5HK"},
+
+ // 細明體
+ { MINGLIU, "MingLiU"},
+ { MINGLIU, "\xe7\xb4\xb0\xe6\x98\x8e\xe9\xab\x94" },
+ { MINGLIU, "MSung B5HK"},
+
+ // 新細明體
+ { PMINGLIUHK, "PMingLiU_HKSCS"},
+ { PMINGLIUHK, "\xe6\x96\xb0\xe7\xb4\xb0\xe6\x98\x8e\xe9\xab\x94_HKSCS" },
+ { PMINGLIUHK, "MSung B5HK"},
+
+ // 細明體
+ { MINGLIUHK, "MingLiU_HKSCS"},
+ { MINGLIUHK, "\xe7\xb4\xb0\xe6\x98\x8e\xe9\xab\x94_HKSCS" },
+ { MINGLIUHK, "MSung B5HK"},
};
static const size_t kFontCount =
@@ -296,7 +296,7 @@ bool GetFontProperties(FcPattern* font,
FcChar8* c_family;
if (FcPatternGetString(font, FC_FAMILY, 0, &c_family))
return false;
-
+
int resulting_bold;
if (FcPatternGetInteger(font, FC_WEIGHT, 0, &resulting_bold))
resulting_bold = FC_WEIGHT_NORMAL;
@@ -334,7 +334,7 @@ bool GetFontProperties(FcPattern* font,
///////////////////////////////////////////////////////////////////////////////
-#define kMaxFontFamilyLength 1024
+#define kMaxFontFamilyLength 1024
SkFontConfigInterfaceDirect::SkFontConfigInterfaceDirect() : next_file_id_(0) {
FcInit();
@@ -345,7 +345,7 @@ SkFontConfigInterfaceDirect::~SkFontConfigInterfaceDirect() {
bool SkFontConfigInterfaceDirect::match(const char familyName[],
SkTypeface::Style style,
- unsigned* result_filefaceid,
+ unsigned* result_filefaceid,
SkTypeface::Style* result_style) {
std::string familyStr(familyName ? familyName : "");
if (familyStr.length() > kMaxFontFamilyLength) {
@@ -356,7 +356,7 @@ bool SkFontConfigInterfaceDirect::match(const char familyName[],
// search our cache
{
- FontMatchKey key = FontMatchKey(familyStr, style);
+ FontMatchKey key = FontMatchKey(familyStr, style);
const std::map<FontMatchKey, FontMatch>::const_iterator i =
font_match_cache_.find(key);
if (i != font_match_cache_.end()) {
@@ -559,5 +559,3 @@ SkStream* SkFontConfigInterfaceDirect::openStream(unsigned filefaceid) {
int fd = open(i->second.c_str(), O_RDONLY);
return (fd >= 0) ? SkNEW_ARGS(SkFDStream, (fd, true)) : NULL;
}
-
-