| OLD | NEW |
| 1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
| 6 | 6 |
| 7 #include "fx_fpf.h" | 7 #include "fx_fpf.h" |
| 8 #if _FX_OS_ == _FX_ANDROID_ | 8 #if _FX_OS_ == _FX_ANDROID_ |
| 9 #define FPF_SKIAMATCHWEIGHT_NAME1 62 | 9 #define FPF_SKIAMATCHWEIGHT_NAME1 62 |
| 10 #define FPF_SKIAMATCHWEIGHT_NAME2 60 | 10 #define FPF_SKIAMATCHWEIGHT_NAME2 60 |
| (...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 201 if (dwStyle & FXFONT_BOLD) { | 201 if (dwStyle & FXFONT_BOLD) { |
| 202 bsFont += "Bold"; | 202 bsFont += "Bold"; |
| 203 } | 203 } |
| 204 if (dwStyle & FXFONT_ITALIC) { | 204 if (dwStyle & FXFONT_ITALIC) { |
| 205 bsFont += "Italic"; | 205 bsFont += "Italic"; |
| 206 } | 206 } |
| 207 if (dwStyle & FXFONT_SERIF) { | 207 if (dwStyle & FXFONT_SERIF) { |
| 208 bsFont += "Serif"; | 208 bsFont += "Serif"; |
| 209 } | 209 } |
| 210 bsFont += uCharset; | 210 bsFont += uCharset; |
| 211 return FPF_GetHashCode_StringA((FX_LPCSTR)bsFont, bsFont.GetLength(), TRUE); | 211 return FPF_GetHashCode_StringA(bsFont.c_str(), bsFont.GetLength(), TRUE); |
| 212 } | 212 } |
| 213 static FX_BOOL FPF_SkiaIsCJK(FX_BYTE uCharset) | 213 static FX_BOOL FPF_SkiaIsCJK(FX_BYTE uCharset) |
| 214 { | 214 { |
| 215 return (uCharset == FXFONT_GB2312_CHARSET) || (uCharset == FXFONT_CHINESEBIG
5_CHARSET) | 215 return (uCharset == FXFONT_GB2312_CHARSET) || (uCharset == FXFONT_CHINESEBIG
5_CHARSET) |
| 216 || (uCharset == FXFONT_HANGEUL_CHARSET) || (uCharset == FXFONT_SHIFTJ
IS_CHARSET); | 216 || (uCharset == FXFONT_HANGEUL_CHARSET) || (uCharset == FXFONT_SHIFTJ
IS_CHARSET); |
| 217 } | 217 } |
| 218 static FX_BOOL FPF_SkiaMaybeSymbol(FX_BSTR bsFacename) | 218 static FX_BOOL FPF_SkiaMaybeSymbol(FX_BSTR bsFacename) |
| 219 { | 219 { |
| 220 CFX_ByteString bsName = bsFacename; | 220 CFX_ByteString bsName = bsFacename; |
| 221 bsName.MakeLower(); | 221 bsName.MakeLower(); |
| (...skipping 330 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 552 pFontDesc->m_dwStyle |= FXFONT_SYMBOLIC; | 552 pFontDesc->m_dwStyle |= FXFONT_SYMBOLIC; |
| 553 } | 553 } |
| 554 pFontDesc->m_dwCharsets = FPF_SkiaGetFaceCharset(pOS2); | 554 pFontDesc->m_dwCharsets = FPF_SkiaGetFaceCharset(pOS2); |
| 555 pFontDesc->m_iFaceIndex = face->face_index; | 555 pFontDesc->m_iFaceIndex = face->face_index; |
| 556 pFontDesc->m_iGlyphNum = face->num_glyphs; | 556 pFontDesc->m_iGlyphNum = face->num_glyphs; |
| 557 } | 557 } |
| 558 void CFPF_SkiaFontMgr::OutputSystemFonts() | 558 void CFPF_SkiaFontMgr::OutputSystemFonts() |
| 559 { | 559 { |
| 560 } | 560 } |
| 561 #endif | 561 #endif |
| OLD | NEW |