FIFE::TrueTypeFont Class Reference

#include <truetypefont.h>

Inheritance diagram for FIFE::TrueTypeFont:
Inheritance graph
[legend]
Collaboration diagram for FIFE::TrueTypeFont:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 TrueTypeFont (const std::string &filename, int size)
virtual ~TrueTypeFont ()
virtual int getWidth (const std::string &text) const
virtual int getHeight () const

Detailed Description

SDL True Type Font implementation of Font. It uses the SDL_ttf library to display True Type Fonts with SDL.

NOTE: You must initialize the SDL_ttf library before using this class. Also, remember to call the SDL_ttf libraries quit function.

Original author of this class is Walluce Pinkham. Some modifications made by the Guichan team, and additonal modifications by the FIFE team.

Definition at line 51 of file truetypefont.h.


Constructor & Destructor Documentation

FIFE::TrueTypeFont::TrueTypeFont ( const std::string &  filename,
int  size 
)

Constructor.

Parameters:
filename the filename of the True Type Font.
size the size the font should be in.

Definition at line 41 of file truetypefont.cpp.

FIFE::TrueTypeFont::~TrueTypeFont (  )  [virtual]

Destructor.

Definition at line 54 of file truetypefont.cpp.


Member Function Documentation

int FIFE::TrueTypeFont::getHeight (  )  const [virtual]

gets height of this font

Implements FIFE::AbstractFont.

Definition at line 65 of file truetypefont.cpp.

References FIFE::FontBase::getRowSpacing().

int FIFE::TrueTypeFont::getWidth ( const std::string &  text  )  const [virtual]

gets width of given text

Implements FIFE::AbstractFont.

Definition at line 58 of file truetypefont.cpp.


The documentation for this class was generated from the following files:
Generated on Wed Nov 23 13:05:14 2011 for FIFE by  doxygen 1.6.3