ADi-FontEngine  1.0
PDF Optimized FontEngine
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FontEngine::TGlyph Struct Reference

the glyph data struct, used as main type in font cache data bank class More...

#include <FontEngineTypes.h>

Inheritance diagram for FontEngine::TGlyph:
FontEngine::TEmbFontData

Public Types

enum  EGSelector {
  egsGID, egsCharCode, egsPSName, egsUnicode,
  egsCID
}
 enum to define the comparison selectors More...
 
enum  EGValid {
  egvGID, egvCharCode, egvPSName, egvUnicode,
  egvCID, egvTTEmpty
}
 < enum to get info about valid member or not More...
 
typedef std::bitset< egvTTEmpty+1 > TValidBS
 

Public Member Functions

 TGlyph ()
 default ctor More...
 
 TGlyph (const TCharCode &ccode, const TCharCode &unicode, unsigned int gid, const std::string &psname, unsigned short cid)
 ctor More...
 
bool operator() (const TGlyph &g1, const TGlyph &g2, EGSelector sel) const
 callback comparison function to sort TGlyph items into the data bank class, see struct TDBComp More...
 
EDBCompActionRes operator() (const TGlyph &g, EGSelector sel) const
 callback function called by data bank class before insert an TGlyph item, see struct TDBComp. More...
 

Public Attributes

TValidBS _vmask
 the valid mask see EGSelector More...
 
unsigned int _gid
 [0 - 65535] valid range, to mark it as unknown glyph use any number greater as number of glyphs in current font More...
 
TCharCode _charcode
 character code used by this glyph is depends from encoding More...
 
std::string _psname
 PostScript name of glyph if present or needed. More...
 
TCharCode _unicode
 the unicode derived from internal font encoding or PostScript More...
 
unsigned short _cid
 [in] the cid (character collection id) in cid fonts More...
 

Detailed Description

the glyph data struct, used as main type in font cache data bank class

Member Typedef Documentation

typedef std::bitset< egvTTEmpty + 1> FontEngine::TGlyph::TValidBS

Member Enumeration Documentation

enum to define the comparison selectors

Enumerator
egsGID 

create a gid (glyph index) primary key set

egsCharCode 

create a character code primary key set

egsPSName 

create a glyph PostScript name primary key set

egsUnicode 

create a unicode primary key set

egsCID 

create a cid (character collection id) primary key set

< enum to get info about valid member or not

Enumerator
egvGID 

if set _gid is valid

egvCharCode 

if set _charcode is valid

egvPSName 

if set _psname is valid

egvUnicode 

if set _unicode is valid

egvCID 

if set _cid is valid

egvTTEmpty 

empty TrueType glyph, without any contour

Constructor & Destructor Documentation

FontEngine::TGlyph::TGlyph ( )
inline

default ctor

FontEngine::TGlyph::TGlyph ( const TCharCode ccode,
const TCharCode unicode,
unsigned int  gid,
const std::string &  psname,
unsigned short  cid 
)
inline

ctor

Parameters
ccodea character code
unicodea unicode
gida glyph index
psnamea glyph PostScript name
cida character collection id

Member Function Documentation

bool FontEngine::TGlyph::operator() ( const TGlyph g1,
const TGlyph g2,
EGSelector  sel 
) const
inline

callback comparison function to sort TGlyph items into the data bank class, see struct TDBComp

Parameters
g1the first TGlyph item
g2the second TGlyph item
selthe comparison selector, see EGSelector
Returns
true if v1 < v2, depends from sel
EDBCompActionRes FontEngine::TGlyph::operator() ( const TGlyph g,
EGSelector  sel 
) const
inline

callback function called by data bank class before insert an TGlyph item, see struct TDBComp.

Parameters
gthe data bank TGlyph item to insert
selthe comparison selector, see EGSelector
Returns
one of the EDBCompActionRes values to set insert action

Member Data Documentation

TCharCode FontEngine::TGlyph::_charcode

character code used by this glyph is depends from encoding

unsigned short FontEngine::TGlyph::_cid

[in] the cid (character collection id) in cid fonts

unsigned int FontEngine::TGlyph::_gid

[0 - 65535] valid range, to mark it as unknown glyph use any number greater as number of glyphs in current font

std::string FontEngine::TGlyph::_psname

PostScript name of glyph if present or needed.

TCharCode FontEngine::TGlyph::_unicode

the unicode derived from internal font encoding or PostScript

TValidBS FontEngine::TGlyph::_vmask

the valid mask see EGSelector


The documentation for this struct was generated from the following file:
InsideFont and ADI-FontEngine : Andreas Dippe, © 2013
http://www.insidefont.de