Pyrogenesis  trunk
Classes | Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
CFont Class Reference

Storage for a bitmap font. More...

#include <Font.h>

Collaboration diagram for CFont:
Collaboration graph
[legend]

Classes

struct  GlyphData
 
class  GlyphMap
 Relatively efficient lookup of GlyphData from 16-bit Unicode codepoint. More...
 

Public Member Functions

bool HasRGB () const
 
int GetLineSpacing () const
 
int GetHeight () const
 
int GetCharacterWidth (wchar_t c) const
 
void CalculateStringSize (const wchar_t *string, int &w, int &h) const
 
void GetGlyphBounds (float &x0, float &y0, float &x1, float &y1) const
 
const GlyphMapGetGlyphs () const
 
CTexturePtr GetTexture () const
 

Private Member Functions

 CFont ()
 

Private Attributes

CTexturePtr m_Texture
 
bool m_HasRGB
 
GlyphMap m_Glyphs
 
int m_LineSpacing
 
int m_Height
 
float m_BoundsX0
 
float m_BoundsY0
 
float m_BoundsX1
 
float m_BoundsY1
 

Friends

class CFontManager
 

Detailed Description

Storage for a bitmap font.

Loaded by CFontManager.

Constructor & Destructor Documentation

CFont::CFont ( )
inlineprivate

Member Function Documentation

void CFont::CalculateStringSize ( const wchar_t string,
int &  w,
int &  h 
) const
int CFont::GetCharacterWidth ( wchar_t  c) const
void CFont::GetGlyphBounds ( float &  x0,
float &  y0,
float &  x1,
float &  y1 
) const
inline
const GlyphMap& CFont::GetGlyphs ( ) const
inline
int CFont::GetHeight ( ) const
inline
int CFont::GetLineSpacing ( ) const
inline
CTexturePtr CFont::GetTexture ( ) const
inline
bool CFont::HasRGB ( ) const
inline

Friends And Related Function Documentation

friend class CFontManager
friend

Member Data Documentation

float CFont::m_BoundsX0
private
float CFont::m_BoundsX1
private
float CFont::m_BoundsY0
private
float CFont::m_BoundsY1
private
GlyphMap CFont::m_Glyphs
private
bool CFont::m_HasRGB
private
int CFont::m_Height
private
int CFont::m_LineSpacing
private
CTexturePtr CFont::m_Texture
private

The documentation for this class was generated from the following files: