diff options
Diffstat (limited to 'core/fpdfapi/font')
-rw-r--r-- | core/fpdfapi/font/cpdf_cidfont.h | 6 | ||||
-rw-r--r-- | core/fpdfapi/font/cpdf_cmap.h | 6 | ||||
-rw-r--r-- | core/fpdfapi/font/cpdf_cmapmanager.cpp | 9 | ||||
-rw-r--r-- | core/fpdfapi/font/cpdf_cmapmanager.h | 12 | ||||
-rw-r--r-- | core/fpdfapi/font/cpdf_font.h | 2 | ||||
-rw-r--r-- | core/fpdfapi/font/cpdf_type3char.cpp | 2 | ||||
-rw-r--r-- | core/fpdfapi/font/cpdf_type3char.h | 4 |
7 files changed, 20 insertions, 21 deletions
diff --git a/core/fpdfapi/font/cpdf_cidfont.h b/core/fpdfapi/font/cpdf_cidfont.h index f4ddcfd577..653cc5f98e 100644 --- a/core/fpdfapi/font/cpdf_cidfont.h +++ b/core/fpdfapi/font/cpdf_cidfont.h @@ -11,10 +11,10 @@ #include <vector> #include "core/fpdfapi/font/cpdf_font.h" -#include "core/fxcrt/cfx_retain_ptr.h" #include "core/fxcrt/cfx_unowned_ptr.h" #include "core/fxcrt/fx_string.h" #include "core/fxcrt/fx_system.h" +#include "core/fxcrt/retain_ptr.h" enum CIDSet : uint8_t { CIDSET_UNKNOWN, @@ -73,13 +73,13 @@ class CPDF_CIDFont : public CPDF_Font { void LoadSubstFont(); wchar_t GetUnicodeFromCharCode(uint32_t charcode) const; - CFX_RetainPtr<CPDF_CMap> m_pCMap; + RetainPtr<CPDF_CMap> m_pCMap; CFX_UnownedPtr<CPDF_CID2UnicodeMap> m_pCID2UnicodeMap; CIDSet m_Charset; bool m_bType1; bool m_bCIDIsGID; uint16_t m_DefaultWidth; - CFX_RetainPtr<CPDF_StreamAcc> m_pStreamAcc; + RetainPtr<CPDF_StreamAcc> m_pStreamAcc; bool m_bAnsiWidthsFixed; FX_RECT m_CharBBox[256]; std::vector<uint32_t> m_WidthList; diff --git a/core/fpdfapi/font/cpdf_cmap.h b/core/fpdfapi/font/cpdf_cmap.h index 3e23d03a01..6e90c3936b 100644 --- a/core/fpdfapi/font/cpdf_cmap.h +++ b/core/fpdfapi/font/cpdf_cmap.h @@ -10,7 +10,7 @@ #include <vector> #include "core/fpdfapi/font/cpdf_cidfont.h" -#include "core/fxcrt/cfx_retain_ptr.h" +#include "core/fxcrt/retain_ptr.h" class CPDF_CMapManager; struct FXCMAP_CMap; @@ -26,7 +26,7 @@ enum CIDCoding : uint8_t { CIDCODING_UTF16, }; -class CPDF_CMap : public CFX_Retainable { +class CPDF_CMap : public Retainable { public: enum CodingScheme : uint8_t { OneByte, @@ -48,7 +48,7 @@ class CPDF_CMap : public CFX_Retainable { }; template <typename T, typename... Args> - friend CFX_RetainPtr<T> pdfium::MakeRetain(Args&&... args); + friend RetainPtr<T> pdfium::MakeRetain(Args&&... args); void LoadPredefined(CPDF_CMapManager* pMgr, const ByteString& name, diff --git a/core/fpdfapi/font/cpdf_cmapmanager.cpp b/core/fpdfapi/font/cpdf_cmapmanager.cpp index a449db6a45..53183af340 100644 --- a/core/fpdfapi/font/cpdf_cmapmanager.cpp +++ b/core/fpdfapi/font/cpdf_cmapmanager.cpp @@ -16,21 +16,20 @@ CPDF_CMapManager::CPDF_CMapManager() {} CPDF_CMapManager::~CPDF_CMapManager() {} -CFX_RetainPtr<CPDF_CMap> CPDF_CMapManager::GetPredefinedCMap( - const ByteString& name, - bool bPromptCJK) { +RetainPtr<CPDF_CMap> CPDF_CMapManager::GetPredefinedCMap(const ByteString& name, + bool bPromptCJK) { auto it = m_CMaps.find(name); if (it != m_CMaps.end()) return it->second; - CFX_RetainPtr<CPDF_CMap> pCMap = LoadPredefinedCMap(name, bPromptCJK); + RetainPtr<CPDF_CMap> pCMap = LoadPredefinedCMap(name, bPromptCJK); if (!name.IsEmpty()) m_CMaps[name] = pCMap; return pCMap; } -CFX_RetainPtr<CPDF_CMap> CPDF_CMapManager::LoadPredefinedCMap( +RetainPtr<CPDF_CMap> CPDF_CMapManager::LoadPredefinedCMap( const ByteString& name, bool bPromptCJK) { const char* pname = name.c_str(); diff --git a/core/fpdfapi/font/cpdf_cmapmanager.h b/core/fpdfapi/font/cpdf_cmapmanager.h index 6a860e6859..089eb3d705 100644 --- a/core/fpdfapi/font/cpdf_cmapmanager.h +++ b/core/fpdfapi/font/cpdf_cmapmanager.h @@ -12,24 +12,24 @@ #include "core/fpdfapi/font/cpdf_cidfont.h" #include "core/fxcrt/bytestring.h" -#include "core/fxcrt/cfx_retain_ptr.h" +#include "core/fxcrt/retain_ptr.h" class CPDF_CMapManager { public: CPDF_CMapManager(); ~CPDF_CMapManager(); - CFX_RetainPtr<CPDF_CMap> GetPredefinedCMap(const ByteString& name, - bool bPromptCJK); + RetainPtr<CPDF_CMap> GetPredefinedCMap(const ByteString& name, + bool bPromptCJK); CPDF_CID2UnicodeMap* GetCID2UnicodeMap(CIDSet charset, bool bPromptCJK); private: - CFX_RetainPtr<CPDF_CMap> LoadPredefinedCMap(const ByteString& name, - bool bPromptCJK); + RetainPtr<CPDF_CMap> LoadPredefinedCMap(const ByteString& name, + bool bPromptCJK); std::unique_ptr<CPDF_CID2UnicodeMap> LoadCID2UnicodeMap(CIDSet charset, bool bPromptCJK); - std::map<ByteString, CFX_RetainPtr<CPDF_CMap>> m_CMaps; + std::map<ByteString, RetainPtr<CPDF_CMap>> m_CMaps; std::unique_ptr<CPDF_CID2UnicodeMap> m_CID2UnicodeMaps[6]; }; diff --git a/core/fpdfapi/font/cpdf_font.h b/core/fpdfapi/font/cpdf_font.h index e92e2f24e5..570d5d5a11 100644 --- a/core/fpdfapi/font/cpdf_font.h +++ b/core/fpdfapi/font/cpdf_font.h @@ -111,7 +111,7 @@ class CPDF_Font { CFX_Font m_Font; std::vector<std::unique_ptr<CFX_Font>> m_FontFallbacks; ByteString m_BaseFont; - CFX_RetainPtr<CPDF_StreamAcc> m_pFontFile; + RetainPtr<CPDF_StreamAcc> m_pFontFile; CPDF_Dictionary* m_pFontDict; mutable std::unique_ptr<CPDF_ToUnicodeMap> m_pToUnicodeMap; mutable bool m_bToUnicodeLoaded; diff --git a/core/fpdfapi/font/cpdf_type3char.cpp b/core/fpdfapi/font/cpdf_type3char.cpp index e11193fdaa..c0ed88d4db 100644 --- a/core/fpdfapi/font/cpdf_type3char.cpp +++ b/core/fpdfapi/font/cpdf_type3char.cpp @@ -35,7 +35,7 @@ bool CPDF_Type3Char::LoadBitmap(CPDF_RenderContext* pContext) { // |pSource| actually gets assigned a CPDF_DIBSource, which has pointers // into objects owned by |m_pForm|. Make sure it is out of scope before // clearing the form. - CFX_RetainPtr<CFX_DIBSource> pSource = + RetainPtr<CFX_DIBSource> pSource = pPageObj->AsImage()->GetImage()->LoadDIBSource(); // Clone() is non-virtual, and can't be overloaded by CPDF_DIBSource to diff --git a/core/fpdfapi/font/cpdf_type3char.h b/core/fpdfapi/font/cpdf_type3char.h index 9f2f94f603..444c9930e1 100644 --- a/core/fpdfapi/font/cpdf_type3char.h +++ b/core/fpdfapi/font/cpdf_type3char.h @@ -9,9 +9,9 @@ #include <memory> -#include "core/fxcrt/cfx_retain_ptr.h" #include "core/fxcrt/fx_coordinates.h" #include "core/fxcrt/fx_system.h" +#include "core/fxcrt/retain_ptr.h" class CFX_DIBitmap; class CPDF_Form; @@ -25,7 +25,7 @@ class CPDF_Type3Char { bool LoadBitmap(CPDF_RenderContext* pContext); std::unique_ptr<CPDF_Form> m_pForm; - CFX_RetainPtr<CFX_DIBitmap> m_pBitmap; + RetainPtr<CFX_DIBitmap> m_pBitmap; bool m_bColored; int m_Width; CFX_Matrix m_ImageMatrix; |