diff options
Diffstat (limited to 'fpdfsdk')
-rw-r--r-- | fpdfsdk/include/pdfwindow/PWL_FontMap.h | 6 | ||||
-rw-r--r-- | fpdfsdk/src/fpdf_sysfontinfo.cpp | 6 |
2 files changed, 8 insertions, 4 deletions
diff --git a/fpdfsdk/include/pdfwindow/PWL_FontMap.h b/fpdfsdk/include/pdfwindow/PWL_FontMap.h index a7aac6d698..2ff6c0f38c 100644 --- a/fpdfsdk/include/pdfwindow/PWL_FontMap.h +++ b/fpdfsdk/include/pdfwindow/PWL_FontMap.h @@ -7,6 +7,7 @@ #ifndef _PWL_FONTMAP_H_ #define _PWL_FONTMAP_H_ +#include "../../../public/fpdf_sysfontinfo.h" #include "../fxedit/fx_edit.h" class CPDF_Document; @@ -111,10 +112,7 @@ private: CFX_ByteString GetNativeFont(FX_INT32 nCharset); public: - struct CharsetFontMap { - FX_INT32 charset; - const char* fontname; - }; + using CharsetFontMap = FPDF_CharsetFontMap; static const CharsetFontMap defaultTTFMap[]; protected: diff --git a/fpdfsdk/src/fpdf_sysfontinfo.cpp b/fpdfsdk/src/fpdf_sysfontinfo.cpp index 9be2fe9223..6bb41b82ff 100644 --- a/fpdfsdk/src/fpdf_sysfontinfo.cpp +++ b/fpdfsdk/src/fpdf_sysfontinfo.cpp @@ -6,6 +6,7 @@ #include "../../public/fpdf_sysfontinfo.h" #include "../include/fsdk_define.h" +#include "../include/pdfwindow/PWL_FontMap.h" class CSysFontInfo_Ext FX_FINAL : public IFX_SystemFontInfo { @@ -94,6 +95,11 @@ DLLEXPORT void STDCALL FPDF_SetSystemFontInfo(FPDF_SYSFONTINFO* pFontInfoExt) CFX_GEModule::Get()->GetFontMgr()->SetSystemFontInfo(pFontInfo); } +DLLEXPORT const FPDF_CharsetFontMap* STDCALL FPDF_GetDefaultTTFMap() +{ + return CPWL_FontMap::defaultTTFMap; +} + struct FPDF_SYSFONTINFO_DEFAULT : public FPDF_SYSFONTINFO { IFX_SystemFontInfo* m_pFontInfo; |