Main Page | Namespace List | Class List | File List | Namespace Members | Class Members | File Members

SoFont Class Reference

#include <sofont.h>

List of all members.

Public Member Functions

 SoFont ()
 ~SoFont ()
bool load (SDL_Surface *FontSurface)
void PutString (SDL_Surface *Surface, int x, int y, const char *text, SDL_Rect *clip=NULL)
void PutStringWithCursor (SDL_Surface *Surface, int x, int y, const char *text, int cursPos, SDL_Rect *clip=NULL, bool showCurs=true)
int TextWidth (const char *text, int min=0, int max=255)
int FontHeight ()
void XCenteredString (SDL_Surface *Surface, int y, const char *text, SDL_Rect *clip=NULL)
void CenteredString (SDL_Surface *Surface, const char *text, SDL_Rect *clip=NULL)
void CenteredString (SDL_Surface *Surface, int x, int y, const char *text, SDL_Rect *clip=NULL)
void PutStringCleverCursor (SDL_Surface *Surface, const char *text, int cursPos, SDL_Rect *r, SDL_Rect *clip=NULL, bool showCurs=true)
int TextCursorAt (const char *text, int px)
int CleverTextCursorAt (const char *text, int px, int cursPos, SDL_Rect *r)
int getMinChar ()
int getMaxChar ()
void InternalInput (SDL_Surface *Dest, int x, int y, int PixelWidth, char *text)
void Input (SDL_Surface *Dest, int x, int y, int PixelWidth, char *text)

Protected Member Functions

bool DoStartNewChar (Sint32 x)
void CleanSurface ()

Protected Attributes

int height
SDL_Surface * picture
int * CharPos
int * Spacing
int max_i
int spacew
int cursShift
Uint32 background


Constructor & Destructor Documentation

SoFont::SoFont  ) 
 

SoFont::~SoFont  ) 
 


Member Function Documentation

void SoFont::CenteredString SDL_Surface *  Surface,
int  x,
int  y,
const char *  text,
SDL_Rect *  clip = NULL
 

void SoFont::CenteredString SDL_Surface *  Surface,
const char *  text,
SDL_Rect *  clip = NULL
 

void SoFont::CleanSurface  )  [protected]
 

int SoFont::CleverTextCursorAt const char *  text,
int  px,
int  cursPos,
SDL_Rect *  r
 

bool SoFont::DoStartNewChar Sint32  x  )  [protected]
 

int SoFont::FontHeight  )  [inline]
 

int SoFont::getMaxChar  )  [inline]
 

int SoFont::getMinChar  )  [inline]
 

void SoFont::Input SDL_Surface *  Dest,
int  x,
int  y,
int  PixelWidth,
char *  text
 

void SoFont::InternalInput SDL_Surface *  Dest,
int  x,
int  y,
int  PixelWidth,
char *  text
 

bool SoFont::load SDL_Surface *  FontSurface  ) 
 

void SoFont::PutString SDL_Surface *  Surface,
int  x,
int  y,
const char *  text,
SDL_Rect *  clip = NULL
 

void SoFont::PutStringCleverCursor SDL_Surface *  Surface,
const char *  text,
int  cursPos,
SDL_Rect *  r,
SDL_Rect *  clip = NULL,
bool  showCurs = true
 

void SoFont::PutStringWithCursor SDL_Surface *  Surface,
int  x,
int  y,
const char *  text,
int  cursPos,
SDL_Rect *  clip = NULL,
bool  showCurs = true
 

int SoFont::TextCursorAt const char *  text,
int  px
 

int SoFont::TextWidth const char *  text,
int  min = 0,
int  max = 255
 

void SoFont::XCenteredString SDL_Surface *  Surface,
int  y,
const char *  text,
SDL_Rect *  clip = NULL
 


Member Data Documentation

Uint32 SoFont::background [protected]
 

int* SoFont::CharPos [protected]
 

int SoFont::cursShift [protected]
 

int SoFont::height [protected]
 

int SoFont::max_i [protected]
 

SDL_Surface* SoFont::picture [protected]
 

int SoFont::spacew [protected]
 

int* SoFont::Spacing [protected]
 


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


Little Neo, 2005 (+ doxygen)

  xtratego

  Home