/external/pdfium/xfa/fxfa/ |
D | cxfa_fontmgr.cpp | 38 RetainPtr<CFGAS_GEFont> pFont; in GetFont() local 40 pFont = pMgr->GetFont(wsEnglishName.AsStringView(), dwFontStyles, true); in GetFont() 41 if (pFont) in GetFont() 42 return pFont; in GetFont() 44 if (!pFont) { in GetFont() 45 pFont = CFGAS_DefaultFontManager::GetFont(hDoc->GetApp()->GetFDEFontMgr(), in GetFont() 48 if (!pFont && pMgr) { in GetFont() 49 pFont = pMgr->GetFont(wsEnglishName.AsStringView(), dwFontStyles, false); in GetFont() 50 if (pFont) in GetFont() 51 return pFont; in GetFont() [all …]
|
/external/pdfium/xfa/fgas/font/ |
D | cfgas_gefont.cpp | 28 auto pFont = pdfium::MakeRetain<CFGAS_GEFont>(pFontMgr); in LoadFont() local 29 if (!pFont->LoadFontInternal(pszFontFamily, dwFontStyles, wCodePage)) in LoadFont() 31 return pFont; in LoadFont() 43 auto pFont = pdfium::MakeRetain<CFGAS_GEFont>(pFontMgr); in LoadFont() local 44 if (!pFont->LoadFontInternal(pPDFFont)) in LoadFont() 47 return pFont; in LoadFont() 54 auto pFont = pdfium::MakeRetain<CFGAS_GEFont>(pFontMgr); in LoadFont() local 55 if (!pFont->LoadFontInternal(std::move(pInternalFont))) in LoadFont() 57 return pFont; in LoadFont() 168 RetainPtr<CFGAS_GEFont> pFont; in GetCharWidth() local [all …]
|
D | cfgas_defaultfontmanager.cpp | 19 RetainPtr<CFGAS_GEFont> pFont = in GetFont() local 21 if (pFont) in GetFont() 22 return pFont; in GetFont() 27 return pFont; in GetFont() 46 pFont = pFontMgr->LoadFont(wsReplace.c_str(), dwStyle, 0xFFFF); in GetFont() 47 if (pFont) in GetFont() 54 return pFont; in GetFont() 62 RetainPtr<CFGAS_GEFont> pFont = in GetDefaultFont() local 64 if (!pFont) { in GetDefaultFont() 65 pFont = pFontMgr->LoadFont(static_cast<const wchar_t*>(nullptr), in GetDefaultFont() [all …]
|
D | cfgas_fontmgr.cpp | 33 bool VerifyUnicode(const RetainPtr<CFGAS_GEFont>& pFont, wchar_t wcUnicode) { in VerifyUnicode() argument 34 RetainPtr<CFX_Face> pFace = pFont->GetDevFont()->GetFace(); in VerifyUnicode() 56 int32_t GetSimilarityScore(FX_FONTDESCRIPTOR const* pFont, in GetSimilarityScore() argument 60 FontStyleIsSymbolic(pFont->dwFontStyles)) { in GetSimilarityScore() 64 FontStyleIsFixedPitch(pFont->dwFontStyles)) { in GetSimilarityScore() 67 if (FontStyleIsSerif(dwFontStyles) == FontStyleIsSerif(pFont->dwFontStyles)) in GetSimilarityScore() 69 if (FontStyleIsScript(dwFontStyles) == FontStyleIsScript(pFont->dwFontStyles)) in GetSimilarityScore() 201 RetainPtr<CFGAS_GEFont> pFont = in GetFontByUnicodeImpl() local 203 if (!pFont) in GetFontByUnicodeImpl() 206 pFont->SetLogicalFontStyle(dwFontStyles); in GetFontByUnicodeImpl() [all …]
|
/external/pdfium/core/fpdfapi/render/ |
D | cpdf_charposlist.cpp | 17 CPDF_Font* pFont, in CPDF_CharPosList() argument 20 CPDF_CIDFont* pCIDFont = pFont->AsCIDFont(); in CPDF_CharPosList() 22 bool bToUnicode = !!pFont->GetFontDict()->GetStreamFor("ToUnicode"); in CPDF_CharPosList() 33 WideString unicode = pFont->UnicodeFromCharCode(CharCode); in CPDF_CharPosList() 35 charpos.m_GlyphIndex = pFont->GlyphFromCharCode(CharCode, &bVert); in CPDF_CharPosList() 38 charpos.m_ExtGID = pFont->GlyphFromCharCodeExt(CharCode); in CPDF_CharPosList() 44 bool bIsTrueTypeZeroGlyph = GlyphID == 0 && pFont->IsTrueTypeFont(); in CPDF_CharPosList() 48 pFont->FallbackFontFromCharcode(CharCode); in CPDF_CharPosList() 49 charpos.m_GlyphIndex = pFont->FallbackGlyphFromCharcode( in CPDF_CharPosList() 71 pCurrentFont = pFont->GetFontFallback(charpos.m_FallbackFontPosition); in CPDF_CharPosList() [all …]
|
D | cpdf_textrenderer.cpp | 22 CFX_Font* GetFont(CPDF_Font* pFont, int32_t position) { in GetFont() argument 23 return position == -1 ? pFont->GetFont() : pFont->GetFontFallback(position); in GetFont() 32 CPDF_Font* pFont, in DrawTextPath() argument 41 const CPDF_CharPosList CharPosList(charCodes, charPos, pFont, font_size); in DrawTextPath() 54 CFX_Font* font = GetFont(pFont, fontPosition); in DrawTextPath() 64 CFX_Font* font = GetFont(pFont, fontPosition); in DrawTextPath() 77 CPDF_Font* pFont, in DrawTextString() argument 83 if (pFont->IsType3Font()) in DrawTextString() 86 int nChars = pFont->CountChar(str.AsStringView()); in DrawTextString() 97 codes[i] = pFont->GetNextChar(str.AsStringView(), &offset); in DrawTextString() [all …]
|
D | cpdf_textrenderer.h | 28 CPDF_Font* pFont, 38 CPDF_Font* pFont, 51 CPDF_Font* pFont,
|
D | cpdf_docrenderdata.cpp | 39 CPDF_Type3Font* pFont) { in GetCachedType3() argument 40 auto it = m_Type3FaceMap.find(pFont); in GetCachedType3() 44 auto pCache = pdfium::MakeRetain<CPDF_Type3Cache>(pFont); in GetCachedType3() 45 m_Type3FaceMap[pFont].Reset(pCache.Get()); in GetCachedType3()
|
/external/pdfium/core/fxge/ |
D | cfx_glyphcache.cpp | 64 const CFX_Font* pFont, in GenKey() argument 75 if (pFont->GetSubstFont()) { in GenKey() 77 anti_alias, pFont->GetSubstFont()->m_Weight, in GenKey() 78 pFont->GetSubstFont()->m_ItalicAngle, in GenKey() 79 pFont->IsVertical(), 3); in GenKey() 85 if (pFont->GetSubstFont()) { in GenKey() 87 anti_alias, pFont->GetSubstFont()->m_Weight, in GenKey() 88 pFont->GetSubstFont()->m_ItalicAngle, in GenKey() 89 pFont->IsVertical()); in GenKey() 104 const CFX_Font* pFont, in RenderGlyph() argument [all …]
|
D | cfx_unicodeencodingex.cpp | 46 CFX_Font* pFont, in FXFM_CreateFontEncoding() argument 48 if (FXFT_Select_Charmap(pFont->GetFaceRec(), nEncodingID)) in FXFM_CreateFontEncoding() 50 return pdfium::MakeUnique<CFX_UnicodeEncodingEx>(pFont, nEncodingID); in FXFM_CreateFontEncoding() 55 CFX_UnicodeEncodingEx::CFX_UnicodeEncodingEx(CFX_Font* pFont, in CFX_UnicodeEncodingEx() argument 57 : CFX_UnicodeEncoding(pFont), m_nEncodingID(EncodingID) {} in CFX_UnicodeEncodingEx() 105 CFX_Font* pFont) { in FX_CreateFontEncodingEx() argument 106 if (!pFont || !pFont->GetFaceRec()) in FX_CreateFontEncodingEx() 110 auto pFontEncoding = FXFM_CreateFontEncoding(pFont, id); in FX_CreateFontEncodingEx()
|
D | cfx_fontcache.cpp | 22 RetainPtr<CFX_GlyphCache> CFX_FontCache::GetGlyphCache(const CFX_Font* pFont) { in GetGlyphCache() argument 23 RetainPtr<CFX_Face> face = pFont->GetFace(); in GetGlyphCache() 36 CFX_TypeFace* CFX_FontCache::GetDeviceCache(const CFX_Font* pFont) { in GetDeviceCache() argument 37 return GetGlyphCache(pFont)->GetDeviceCache(pFont); in GetDeviceCache()
|
D | cfx_glyphcache.h | 36 const CFX_GlyphBitmap* LoadGlyphBitmap(const CFX_Font* pFont, 43 const CFX_PathData* LoadGlyphPath(const CFX_Font* pFont, 51 CFX_TypeFace* GetDeviceCache(const CFX_Font* pFont); 61 std::unique_ptr<CFX_GlyphBitmap> RenderGlyph(const CFX_Font* pFont, 68 const CFX_Font* pFont, 73 CFX_GlyphBitmap* LookUpGlyphBitmap(const CFX_Font* pFont,
|
D | cfx_folderfontinfo.cpp | 307 FontFaceInfo* pFont = it.second.get(); in FindFont() local 308 if (!(pFont->m_Charsets & charset_flag) && charset != FX_CHARSET_Default) in FindFont() 315 GetSimilarValue(weight, bItalic, pitch_family, pFont->m_Styles); in FindFont() 318 pFind = pFont; in FindFont() 343 const FontFaceInfo* pFont = static_cast<FontFaceInfo*>(hFont); in GetFontData() local 347 datasize = pFont->m_FontOffset ? 0 : pFont->m_FileSize; in GetFontData() 349 datasize = pFont->m_FontOffset ? pFont->m_FileSize : 0; in GetFontData() 351 uint32_t nTables = pFont->m_FontTables.GetLength() / 16; in GetFontData() 353 const uint8_t* p = pFont->m_FontTables.raw_str() + i * 16; in GetFontData() 365 fopen(pFont->m_FilePath.c_str(), "rb")); in GetFontData()
|
/external/pdfium/core/fxge/apple/ |
D | fx_apple_platform.cpp | 38 CFX_Font* pFont, in CGDrawGlyphRun() argument 53 if (!pFont->GetPlatformFont()) { in CGDrawGlyphRun() 54 if (pFont->GetPsName() == "DFHeiStd-W5") in CGDrawGlyphRun() 57 pdfium::span<const uint8_t> span = pFont->GetFontSpan(); in CGDrawGlyphRun() 58 pFont->SetPlatformFont(quartz2d.CreateFont(span.data(), span.size())); in CGDrawGlyphRun() 59 if (!pFont->GetPlatformFont()) in CGDrawGlyphRun() 81 return quartz2d.DrawGraphicsString(pContext, pFont->GetPlatformFont(), in CGDrawGlyphRun() 107 CFX_Font* pFont, in DrawDeviceText() argument 111 if (!pFont) in DrawDeviceText() 114 bool bBold = pFont->IsBold(); in DrawDeviceText() [all …]
|
/external/pdfium/fpdfsdk/ |
D | fpdf_edittext.cpp | 69 CFX_Font* pFont, in LoadFontDesc() argument 76 if (FXFT_Is_Face_fixedwidth(pFont->GetFaceRec())) in LoadFontDesc() 80 if (FXFT_Is_Face_Italic(pFont->GetFaceRec())) in LoadFontDesc() 82 if (FXFT_Is_Face_Bold(pFont->GetFaceRec())) in LoadFontDesc() 90 pFont->GetBBox(&bbox); in LoadFontDesc() 94 pFontDesc->SetNewFor<CPDF_Number>("ItalicAngle", pFont->IsItalic() ? -12 : 0); in LoadFontDesc() 96 pFontDesc->SetNewFor<CPDF_Number>("Ascent", pFont->GetAscent()); in LoadFontDesc() 97 pFontDesc->SetNewFor<CPDF_Number>("Descent", pFont->GetDescent()); in LoadFontDesc() 100 pFontDesc->SetNewFor<CPDF_Number>("CapHeight", pFont->GetAscent()); in LoadFontDesc() 101 pFontDesc->SetNewFor<CPDF_Number>("StemV", pFont->IsBold() ? 120 : 70); in LoadFontDesc() [all …]
|
/external/pdfium/core/fpdfapi/page/ |
D | cpdf_docpagedata.cpp | 82 void InsertWidthArray1(CFX_Font* pFont, in InsertWidthArray1() argument 90 widths[i] = pFont->GetGlyphWidth(glyph_index); in InsertWidthArray1() 185 RetainPtr<CPDF_Font> pFont = in GetFont() local 187 if (!pFont) in GetFont() 190 m_FontMap[pFontDict].Reset(pFont.Get()); in GetFont() 191 return pFont; in GetFont() 201 CPDF_Font* pFont = it.second.Get(); in GetStandardFont() local 202 if (!pFont) in GetStandardFont() 204 if (pFont->GetBaseFontName() != fontName) in GetStandardFont() 206 if (pFont->IsEmbedded()) in GetStandardFont() [all …]
|
D | cpdf_textobject.cpp | 45 RetainPtr<CPDF_Font> pFont = GetFont(); in GetItemInfo() local 46 if (!pFont->IsCIDFont() || !pFont->AsCIDFont()->IsVertWriting()) in GetItemInfo() 49 uint16_t CID = pFont->AsCIDFont()->CIDFromCharCode(pInfo->m_CharCode); in GetItemInfo() 54 pFont->AsCIDFont()->GetVertOrigin(CID, vx, vy); in GetItemInfo() 105 RetainPtr<CPDF_Font> pFont = GetFont(); in CountWords() local 113 WideString swUnicode = pFont->UnicodeFromCharCode(charcode); in CountWords() 131 RetainPtr<CPDF_Font> pFont = GetFont(); in GetWordString() local 140 WideString swUnicode = pFont->UnicodeFromCharCode(charcode); in GetWordString() 206 RetainPtr<CPDF_Font> pFont = GetFont(); in SetSegments() local 209 nChars += pFont->CountChar(pStrs[i].AsStringView()); in SetSegments() [all …]
|
D | cpdf_textstate.cpp | 25 void CPDF_TextState::SetFont(const RetainPtr<CPDF_Font>& pFont) { in SetFont() argument 26 m_Ref.GetPrivateCopy()->SetFont(pFont); in SetFont() 119 void CPDF_TextState::TextData::SetFont(const RetainPtr<CPDF_Font>& pFont) { in SetFont() argument 120 m_pDocument = pFont ? pFont->GetDocument() : nullptr; in SetFont() 121 m_pFont = pFont; in SetFont()
|
/external/pdfium/core/fpdfdoc/ |
D | cba_fontmap.cpp | 86 return m_Data[nFontIndex]->pFont; in GetPDFFont() 133 if (!pData->pFont) in CharCodeFromUnicode() 136 if (pData->pFont->IsUnicodeCompatible()) in CharCodeFromUnicode() 137 return pData->pFont->CharCodeFromUnicode(word); in CharCodeFromUnicode() 240 RetainPtr<CPDF_Font> pFont = pData->GetFont(pElement); in FindResFontSameCharset() local 241 if (!pFont) in FindResFontSameCharset() 244 const CFX_SubstFont* pSubst = pFont->GetSubstFont(); in FindResFontSameCharset() 250 pFind = std::move(pFont); in FindResFontSameCharset() 309 void CBA_FontMap::AddFontToAnnotDict(const RetainPtr<CPDF_Font>& pFont, in AddFontToAnnotDict() argument 311 if (!pFont) in AddFontToAnnotDict() [all …]
|
D | cpdf_interactiveform.cpp | 41 const RetainPtr<CPDF_Font>& pFont, 94 RetainPtr<CPDF_Font> pFont = CPDF_InteractiveForm::AddStandardFont( in InitDict() local 96 if (pFont) in InitDict() 97 AddFont(pFormDict, pDocument, pFont, &csBaseName); in InitDict() 102 if (!pFont || csFontName != CFX_Font::kDefaultAnsiFontName) { in InitDict() 103 pFont = CPDF_InteractiveForm::AddNativeFont(pDocument); in InitDict() 104 if (pFont) { in InitDict() 106 AddFont(pFormDict, pDocument, pFont, &csBaseName); in InitDict() 110 if (pFont) in InitDict() 186 const CPDF_Font* pFont, in FindFont() argument [all …]
|
D | cpdf_formcontrol.cpp | 208 RetainPtr<CPDF_Font> pFont = GetDefaultControlFont(); in GetDefaultControlFontName() local 209 if (!pFont) in GetDefaultControlFontName() 212 return WideString::FromDefANSI(pFont->GetBaseFontName().AsStringView()); in GetDefaultControlFontName() 229 RetainPtr<CPDF_Font> pFont = pData->GetFont(pElement); in GetDefaultControlFont() local 230 if (pFont) in GetDefaultControlFont() 231 return pFont; in GetDefaultControlFont()
|
/external/pdfium/core/fxge/android/ |
D | cfpf_skiafontmgr.cpp | 284 const CFPF_SkiaPathFont* pFont = face_iter->get(); in CreateFont() local 285 if (!(pFont->charsets() & FPF_SkiaGetCharset(uCharset))) in CreateFont() 288 uint32_t dwSysFontName = FPF_SKIANormalizeFontName(pFont->family()); in CreateFont() 292 if (FontStyleIsForceBold(dwStyle) == FontStyleIsForceBold(pFont->style())) in CreateFont() 294 if (FontStyleIsItalic(dwStyle) == FontStyleIsItalic(pFont->style())) in CreateFont() 297 FontStyleIsFixedPitch(pFont->style())) { in CreateFont() 300 if (FontStyleIsSerif(dwStyle) == FontStyleIsSerif(pFont->style())) in CreateFont() 302 if (FontStyleIsScript(dwStyle) == FontStyleIsScript(pFont->style())) in CreateFont() 314 if (bMatchedName || pFont->glyph_num() > nGlyphNum) { in CreateFont() 316 nGlyphNum = pFont->glyph_num(); in CreateFont() [all …]
|
/external/pdfium/core/fpdfapi/font/ |
D | cpdf_font.cpp | 297 RetainPtr<CPDF_Font> pFont = pFontGlobals->Find(pDoc, font_id.value()); in GetStockFont() local 298 if (pFont) in GetStockFont() 299 return pFont; in GetStockFont() 306 pFont = CPDF_Font::Create(nullptr, pDict.Get(), nullptr); in GetStockFont() 307 pFontGlobals->Set(pDoc, font_id.value(), pFont); in GetStockFont() 308 return pFont; in GetStockFont() 316 RetainPtr<CPDF_Font> pFont; in Create() local 324 pFont = pdfium::MakeRetain<CPDF_CIDFont>(pDoc, pFontDict); in Create() 328 if (!pFont) in Create() 329 pFont = pdfium::MakeRetain<CPDF_TrueTypeFont>(pDoc, pFontDict); in Create() [all …]
|
/external/pdfium/core/fxge/win32/ |
D | fx_win32_print.cpp | 204 CFX_Font* pFont, in DrawDeviceText() argument 212 if (nChars < 1 || !pFont || !pFont->IsEmbedded() || !pFont->IsTTFont()) in DrawDeviceText() 233 lf.lfWeight = pFont->IsBold() ? FW_BOLD : FW_NORMAL; in DrawDeviceText() 234 lf.lfItalic = pFont->IsItalic(); in DrawDeviceText() 238 WideString::FromUTF8(pFont->GetFaceName().AsStringView()); in DrawDeviceText() 508 CFX_Font* pFont, in DrawDeviceText() argument 512 return m_PSRenderer.DrawText(nChars, pCharPos, pFont, mtObject2Device, in DrawDeviceText() 621 CFX_Font* pFont, in DrawDeviceText() argument 627 if (nChars < 1 || !pFont || !pFont->IsEmbedded() || !pFont->IsTTFont()) in DrawDeviceText()
|
/external/pdfium/core/fpdfapi/edit/ |
D | cpdf_pagecontentgenerator.cpp | 496 RetainPtr<CPDF_Font> pFont(pTextObj->GetFont()); in ProcessText() local 497 if (!pFont) in ProcessText() 498 pFont = CPDF_Font::GetStockFont(m_pDocument.Get(), "Helvetica"); in ProcessText() 502 if (pFont->IsType1Font()) { in ProcessText() 504 pEncoding = pFont->AsType1Font()->GetEncoding(); in ProcessText() 505 } else if (pFont->IsTrueTypeFont()) { in ProcessText() 507 pEncoding = pFont->AsTrueTypeFont()->GetEncoding(); in ProcessText() 508 } else if (pFont->IsCIDFont()) { in ProcessText() 513 data.baseFont = pFont->GetBaseFontName(); in ProcessText() 519 CPDF_Object* pIndirectFont = pFont->GetFontDict(); in ProcessText() [all …]
|