7#ifndef CORE_FXGE_CFX_FOLDERFONTINFO_H_
8#define CORE_FXGE_CFX_FOLDERFONTINFO_H_
14#include "core/fxcrt/fx_codepage_forward.h"
15#include "core/fxcrt/unowned_ptr.h"
16#include "core/fxge/cfx_fontmapper.h"
17#include "core/fxge/systemfontinfo_iface.h"
19#define CHARSET_FLAG_ANSI (1
<< 0
)
20#define CHARSET_FLAG_SYMBOL (1
<< 1
)
21#define CHARSET_FLAG_SHIFTJIS (1
<< 2
)
22#define CHARSET_FLAG_BIG5 (1
<< 3
)
23#define CHARSET_FLAG_GB (1
<< 4
)
24#define CHARSET_FLAG_KOREAN (1
<< 5
)
31 void AddPath(
const ByteString& path);
39 const ByteString& face)
override;
40 void*
GetFont(
const ByteString& face)
override;
43 pdfium::span<uint8_t> buffer)
override;
45 bool GetFaceName(
void* hFont, ByteString* name)
override;
55 ByteString fontTables,
68 void ScanPath(
const ByteString& path);
69 void ScanFile(
const ByteString& path);
79 const ByteString& family,
const ByteString m_FaceName
const ByteString m_FilePath
const uint32_t m_FontOffset
FontFaceInfo(ByteString filePath, ByteString faceName, ByteString fontTables, uint32_t fontOffset, uint32_t fileSize)
const uint32_t m_FileSize
const ByteString m_FontTables
~CFX_FolderFontInfo() override
void ScanFile(const ByteString &path)
bool GetFontCharset(void *hFont, FX_Charset *charset) override
std::vector< ByteString > m_PathList
size_t GetFontData(void *hFont, uint32_t table, pdfium::span< uint8_t > buffer) override
void * GetSubstFont(const ByteString &face)
void DeleteFont(void *hFont) override
UnownedPtr< CFX_FontMapper > m_pMapper
void * FindFont(int weight, bool bItalic, FX_Charset charset, int pitch_family, const ByteString &family, bool bMatchName)
void ReportFace(const ByteString &path, FILE *pFile, FX_FILESIZE filesize, uint32_t offset)
bool GetFaceName(void *hFont, ByteString *name) override
void ScanPath(const ByteString &path)
void * MapFont(int weight, bool bItalic, FX_Charset charset, int pitch_family, const ByteString &face) override
void AddPath(const ByteString &path)
void * GetFont(const ByteString &face) override
std::map< ByteString, std::unique_ptr< FontFaceInfo > > m_FontList
bool EnumFontList(CFX_FontMapper *pMapper) override
static CFX_GEModule * Get()
const char ** GetUserFontPaths() const
void * CreateFont(pdfium::span< const uint8_t > pFontData)
ByteString & operator+=(const char *str)
ByteString & operator=(const char *str)
ByteString & operator=(const ByteString &that)
ByteString & operator=(ByteString &&that) noexcept
bool FontFamilyIsFixedPitch(uint32_t family)
bool FontFamilyIsRoman(uint32_t family)