7#ifndef CORE_FPDFAPI_FONT_CPDF_CIDFONT_H_
8#define CORE_FPDFAPI_FONT_CPDF_CIDFONT_H_
16#include "core/fpdfapi/font/cpdf_font.h"
17#include "core/fxcrt/fx_coordinates.h"
18#include "core/fxcrt/fx_string.h"
19#include "core/fxcrt/retain_ptr.h"
20#include "core/fxcrt/unowned_ptr.h"
56 const CPDF_CIDFont*
AsCIDFont()
const override;
77 enum class CIDFontType :
bool {
85 int GetGlyphIndex(uint32_t unicodeb,
bool* pVertGlyph);
86 int GetVerticalGlyph(
int index,
bool* pVertGlyph);
88 wchar_t GetUnicodeFromCharCode(uint32_t charcode)
const;
93 std::unique_ptr<CFX_CTTGSUBTable> m_pTTGSUBTable;
94 CIDFontType m_FontType = CIDFontType::kTrueType;
95 bool m_bCIDIsGID =
false;
96 bool m_bAnsiWidthsFixed =
false;
97 bool m_bAdobeCourierStd =
false;
99 int16_t m_DefaultWidth = 1000;
100 int16_t m_DefaultVY = 880;
101 int16_t m_DefaultW1 = -1000;
102 std::vector<
int> m_WidthList;
103 std::vector<
int> m_VertMetrics;
fxcrt::ByteString ByteString
wchar_t UnicodeFromCID(uint16_t cid) const
CPDF_CID2UnicodeMap(CIDSet charset)
size_t CountChar(ByteStringView pString) const override
uint32_t GetNextChar(ByteStringView pString, size_t *pOffset) const override
bool IsCIDFont() const override
bool IsUnicodeCompatible() const override
CFX_Point16 GetVertOrigin(uint16_t cid) const
int GetCharWidthF(uint32_t charcode) override
const CPDF_CIDFont * AsCIDFont() const override
uint16_t CIDFromCharCode(uint32_t charcode) const
const CIDTransform * GetCIDTransform(uint16_t cid) const
int GlyphFromCharCode(uint32_t charcode, bool *pVertGlyph) override
int16_t GetVertWidth(uint16_t cid) const
FX_RECT GetCharBBox(uint32_t charcode) override
static float CIDTransformToFloat(uint8_t ch)
void AppendChar(ByteString *str, uint32_t charcode) const override
bool IsVertWriting() const override
uint32_t CharCodeFromUnicode(wchar_t Unicode) const override
int GetCharSize(uint32_t charcode) const
WideString UnicodeFromCharCode(uint32_t charcode) const override
CPDF_CIDFont * AsCIDFont() override
std::map< ByteString, RetainPtr< CPDF_Object >, std::less<> > DictMap
CFX_PTemplate< int16_t > CFX_Point16
#define CONSTRUCT_VIA_MAKE_RETAIN
fxcrt::ByteStringView ByteStringView
fxcrt::WideString WideString