25 #ifndef CPP3DS_FONT_HPP 
   26 #define CPP3DS_FONT_HPP 
   31 #include <cpp3ds/Graphics/Glyph.hpp> 
   32 #include <cpp3ds/Graphics/Texture.hpp> 
   33 #include <cpp3ds/Graphics/Rect.hpp> 
   34 #include <cpp3ds/System/Vector2.hpp> 
   35 #include <cpp3ds/System/String.hpp> 
  161     const Glyph& 
getGlyph(Uint32 codePoint, 
unsigned int characterSize, 
bool bold) 
const;
 
  179     int getKerning(Uint32 first, Uint32 second, 
unsigned int characterSize) 
const;
 
  226         Row(
unsigned int rowTop, 
unsigned int rowHeight) : width(0), top(rowTop), height(rowHeight) {}
 
  236     typedef std::map<Uint32, Glyph> GlyphTable; 
 
  248         unsigned int     nextRow; 
 
  249         std::vector<Row> rows;    
 
  268     Glyph loadGlyph(Uint32 codePoint, 
unsigned int characterSize, 
bool bold) 
const;
 
  280     IntRect findGlyphRect(Page& page, 
unsigned int width, 
unsigned int height) 
const;
 
  290     bool setCurrentSize(
unsigned int characterSize) 
const;
 
  295     typedef std::map<unsigned int, Page> PageTable; 
 
  305     mutable PageTable          m_pages;       
 
  306     mutable std::vector<Uint8> m_pixelBuffer; 
 
Class for loading and manipulating character fonts. 
const Glyph & getGlyph(Uint32 codePoint, unsigned int characterSize, bool bold) const 
Retrieve a glyph of the font. 
const Texture & getTexture(unsigned int characterSize) const 
Retrieve the texture containing the loaded glyphs of a certain size. 
Font & operator=(const Font &right)
Overload of assignment operator. 
Holds various information about a font. 
Structure describing a glyph. 
Font()
Default constructor. 
int getLineSpacing(unsigned int characterSize) const 
Get the line spacing. 
bool loadFromFile(const std::string &filename)
Load the font from a file. 
const Info & getInfo() const 
Get the font information. 
std::string family
The font family. 
bool loadFromStream(InputStream &stream)
Load the font from a custom stream. 
some things could easily be broken/////// 
int getKerning(Uint32 first, Uint32 second, unsigned int characterSize) const 
Get the kerning offset of two glyphs. 
bool loadFromMemory(const void *data, std::size_t sizeInBytes)
Load the font from a file in memory.