![]() |
Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
|
#include <cfx_face.h>
Classes | |
struct | CharCodeAndIndex |
Public Types | |
using | CharMap = void* |
Public Member Functions | |
bool | HasGlyphNames () const |
bool | IsTtOt () const |
bool | IsTricky () const |
bool | IsFixedWidth () const |
bool | IsItalic () const |
bool | IsBold () const |
ByteString | GetFamilyName () const |
ByteString | GetStyleName () const |
FX_RECT | GetBBox () const |
uint16_t | GetUnitsPerEm () const |
int16_t | GetAscender () const |
int16_t | GetDescender () const |
pdfium::span< uint8_t > | GetData () const |
size_t | GetSfntTable (uint32_t table, pdfium::span< uint8_t > buffer) |
std::optional< std::array< uint32_t, 4 > > | GetOs2UnicodeRange () |
std::optional< std::array< uint32_t, 2 > > | GetOs2CodePageRange () |
std::optional< std::array< uint8_t, 2 > > | GetOs2Panose () |
int | GetGlyphCount () const |
FX_RECT | GetGlyphBBox () const |
std::unique_ptr< CFX_GlyphBitmap > | RenderGlyph (const CFX_Font *pFont, uint32_t glyph_index, bool bFontStyle, const CFX_Matrix &matrix, int dest_width, int anti_alias) |
std::unique_ptr< CFX_Path > | LoadGlyphPath (uint32_t glyph_index, int dest_width, bool is_vertical, const CFX_SubstFont *subst_font) |
int | GetGlyphWidth (uint32_t glyph_index, int dest_width, int weight, const CFX_SubstFont *subst_font) |
ByteString | GetGlyphName (uint32_t glyph_index) |
int | GetCharIndex (uint32_t code) |
int | GetNameIndex (const char *name) |
FX_RECT | GetCharBBox (uint32_t code, int glyph_index) |
std::vector< CharCodeAndIndex > | GetCharCodesAndIndices (char32_t max_char) |
CharMap | GetCurrentCharMap () const |
std::optional< fxge::FontEncoding > | GetCurrentCharMapEncoding () const |
int | GetCharMapPlatformIdByIndex (size_t index) const |
int | GetCharMapEncodingIdByIndex (size_t index) const |
fxge::FontEncoding | GetCharMapEncodingByIndex (size_t index) const |
size_t | GetCharMapCount () const |
void | SetCharMap (CharMap map) |
void | SetCharMapByIndex (size_t index) |
bool | SelectCharMap (fxge::FontEncoding encoding) |
bool | SetPixelSize (uint32_t width, uint32_t height) |
FXFT_FaceRec * | GetRec () |
const FXFT_FaceRec * | GetRec () const |
Public Member Functions inherited from fxcrt::Retainable | |
Retainable ()=default | |
bool | HasOneRef () const |
Public Member Functions inherited from fxcrt::Observable | |
Observable () | |
Observable (const Observable &that)=delete | |
Observable & | operator= (const Observable &that)=delete |
~Observable () | |
void | AddObserver (ObserverIface *pObserver) |
void | RemoveObserver (ObserverIface *pObserver) |
void | NotifyObservers () |
Static Public Member Functions | |
static RetainPtr< CFX_Face > | New (FT_Library library, RetainPtr< Retainable > pDesc, pdfium::span< const FT_Byte > data, FT_Long face_index) |
static RetainPtr< CFX_Face > | Open (FT_Library library, const FT_Open_Args *args, FT_Long face_index) |
Private Member Functions | |
~CFX_Face () override |
Additional Inherited Members | |
Protected Member Functions inherited from fxcrt::Retainable | |
virtual | ~Retainable ()=default |
Protected Member Functions inherited from fxcrt::Observable | |
size_t | ActiveObserversForTesting () const |
Definition at line 32 of file cfx_face.h.
using CFX_Face::CharMap = void* |
Definition at line 34 of file cfx_face.h.
|
overrideprivatedefault |
int16_t CFX_Face::GetAscender | ( | ) | const |
Definition at line 370 of file cfx_face.cpp.
References GetRec().
Referenced by GetCharBBox().
FX_RECT CFX_Face::GetBBox | ( | ) | const |
Definition at line 359 of file cfx_face.cpp.
References GetRec().
FX_RECT CFX_Face::GetCharBBox | ( | uint32_t | code, |
int | glyph_index ) |
Definition at line 672 of file cfx_face.cpp.
References FX_RECT::FX_RECT(), FX_RECT::bottom, GetAscender(), GetDescender(), GetGlyphBBox(), GetRec(), IsTricky(), FX_RECT::operator=(), and FX_RECT::top.
std::vector< CFX_Face::CharCodeAndIndex > CFX_Face::GetCharCodesAndIndices | ( | char32_t | max_char | ) |
Definition at line 727 of file cfx_face.cpp.
References CFX_Face::CharCodeAndIndex::char_code, GetRec(), and CFX_Face::CharCodeAndIndex::glyph_index.
int CFX_Face::GetCharIndex | ( | uint32_t | code | ) |
Definition at line 663 of file cfx_face.cpp.
References GetRec().
size_t CFX_Face::GetCharMapCount | ( | ) | const |
Definition at line 776 of file cfx_face.cpp.
fxge::FontEncoding CFX_Face::GetCharMapEncodingByIndex | ( | size_t | index | ) | const |
Definition at line 770 of file cfx_face.cpp.
References GetRec().
int CFX_Face::GetCharMapEncodingIdByIndex | ( | size_t | index | ) | const |
Definition at line 764 of file cfx_face.cpp.
References GetRec().
int CFX_Face::GetCharMapPlatformIdByIndex | ( | size_t | index | ) | const |
Definition at line 758 of file cfx_face.cpp.
References GetRec().
CFX_Face::CharMap CFX_Face::GetCurrentCharMap | ( | ) | const |
Definition at line 747 of file cfx_face.cpp.
References GetRec().
std::optional< fxge::FontEncoding > CFX_Face::GetCurrentCharMapEncoding | ( | ) | const |
Definition at line 751 of file cfx_face.cpp.
References GetRec().
pdfium::span< uint8_t > CFX_Face::GetData | ( | ) | const |
Definition at line 384 of file cfx_face.cpp.
References GetRec().
int16_t CFX_Face::GetDescender | ( | ) | const |
Definition at line 374 of file cfx_face.cpp.
References GetRec().
Referenced by GetCharBBox().
ByteString CFX_Face::GetFamilyName | ( | ) | const |
Definition at line 351 of file cfx_face.cpp.
References GetRec().
FX_RECT CFX_Face::GetGlyphBBox | ( | ) | const |
Definition at line 716 of file cfx_face.cpp.
References GetRec(), and GetUnitsPerEm().
Referenced by GetCharBBox().
int CFX_Face::GetGlyphCount | ( | ) | const |
Definition at line 436 of file cfx_face.cpp.
References GetRec().
ByteString CFX_Face::GetGlyphName | ( | uint32_t | glyph_index | ) |
Definition at line 656 of file cfx_face.cpp.
References fxcrt::ByteString::ByteString(), and GetRec().
int CFX_Face::GetGlyphWidth | ( | uint32_t | glyph_index, |
int | dest_width, | ||
int | weight, | ||
const CFX_SubstFont * | subst_font ) |
Definition at line 632 of file cfx_face.cpp.
References GetRec(), GetUnitsPerEm(), and CFX_SubstFont::IsBuiltInGenericFont().
int CFX_Face::GetNameIndex | ( | const char * | name | ) |
Definition at line 667 of file cfx_face.cpp.
References GetRec().
std::optional< std::array< uint32_t, 2 > > CFX_Face::GetOs2CodePageRange | ( | ) |
Definition at line 418 of file cfx_face.cpp.
std::optional< std::array< uint8_t, 2 > > CFX_Face::GetOs2Panose | ( | ) |
Definition at line 427 of file cfx_face.cpp.
std::optional< std::array< uint32_t, 4 > > CFX_Face::GetOs2UnicodeRange | ( | ) |
Definition at line 407 of file cfx_face.cpp.
|
inline |
Definition at line 126 of file cfx_face.h.
Referenced by GetCharBBox(), GetCharCodesAndIndices(), GetCharIndex(), GetGlyphName(), GetGlyphWidth(), GetNameIndex(), GetSfntTable(), LoadGlyphPath(), RenderGlyph(), SetCharMap(), SetCharMapByIndex(), and SetPixelSize().
|
inline |
Definition at line 127 of file cfx_face.h.
Referenced by GetAscender(), GetBBox(), GetCharMapEncodingByIndex(), GetCharMapEncodingIdByIndex(), GetCharMapPlatformIdByIndex(), GetCurrentCharMap(), GetCurrentCharMapEncoding(), GetData(), GetDescender(), GetFamilyName(), GetGlyphBBox(), GetGlyphCount(), GetStyleName(), and GetUnitsPerEm().
size_t CFX_Face::GetSfntTable | ( | uint32_t | table, |
pdfium::span< uint8_t > | buffer ) |
Definition at line 390 of file cfx_face.cpp.
References GetRec().
ByteString CFX_Face::GetStyleName | ( | ) | const |
Definition at line 355 of file cfx_face.cpp.
References GetRec().
uint16_t CFX_Face::GetUnitsPerEm | ( | ) | const |
Definition at line 366 of file cfx_face.cpp.
References GetRec().
Referenced by GetGlyphBBox(), and GetGlyphWidth().
bool CFX_Face::HasGlyphNames | ( | ) | const |
Definition at line 317 of file cfx_face.cpp.
bool CFX_Face::IsBold | ( | ) | const |
Definition at line 347 of file cfx_face.cpp.
bool CFX_Face::IsFixedWidth | ( | ) | const |
Definition at line 329 of file cfx_face.cpp.
bool CFX_Face::IsItalic | ( | ) | const |
Definition at line 343 of file cfx_face.cpp.
bool CFX_Face::IsTricky | ( | ) | const |
Definition at line 325 of file cfx_face.cpp.
Referenced by GetCharBBox(), and LoadGlyphPath().
bool CFX_Face::IsTtOt | ( | ) | const |
Definition at line 321 of file cfx_face.cpp.
Referenced by LoadGlyphPath(), and RenderGlyph().
std::unique_ptr< CFX_Path > CFX_Face::LoadGlyphPath | ( | uint32_t | glyph_index, |
int | dest_width, | ||
bool | is_vertical, | ||
const CFX_SubstFont * | subst_font ) |
Definition at line 566 of file cfx_face.cpp.
References GetRec(), CFX_SubstFont::IsBuiltInGenericFont(), IsTricky(), IsTtOt(), kShiftJIS, CFX_SubstFont::m_Charset, CFX_SubstFont::m_ItalicAngle, and CFX_SubstFont::m_Weight.
|
static |
Definition at line 291 of file cfx_face.cpp.
|
static |
Definition at line 306 of file cfx_face.cpp.
std::unique_ptr< CFX_GlyphBitmap > CFX_Face::RenderGlyph | ( | const CFX_Font * | pFont, |
uint32_t | glyph_index, | ||
bool | bFontStyle, | ||
const CFX_Matrix & | matrix, | ||
int | dest_width, | ||
int | anti_alias ) |
Definition at line 440 of file cfx_face.cpp.
References CFX_Matrix::a, CFX_Matrix::b, CFX_Matrix::c, CFX_Matrix::d, GetRec(), CFX_Font::GetSubstFont(), CFX_SubstFont::IsBuiltInGenericFont(), IsTtOt(), CFX_Font::IsVertical(), CFX_SubstFont::m_bItalicCJK, CFX_SubstFont::m_bSubstCJK, CFX_SubstFont::m_ItalicAngle, CFX_SubstFont::m_Weight, and CFX_SubstFont::m_WeightCJK.
bool CFX_Face::SelectCharMap | ( | fxge::FontEncoding | encoding | ) |
Definition at line 792 of file cfx_face.cpp.
Definition at line 782 of file cfx_face.cpp.
References GetRec().
Referenced by SetCharMapByIndex().
void CFX_Face::SetCharMapByIndex | ( | size_t | index | ) |
Definition at line 786 of file cfx_face.cpp.
References GetRec(), and SetCharMap().
bool CFX_Face::SetPixelSize | ( | uint32_t | width, |
uint32_t | height ) |
Definition at line 797 of file cfx_face.cpp.
References GetRec().