My Project
SallyAPI::Core::CFont Class Reference

Font. More...

#include <Font.h>

Inheritance diagram for SallyAPI::Core::CFont:
SallyAPI::Core::CBaseObject

List of all members.

Public Member Functions

 CFont (const std::string &fontFace, int height, bool bold, bool italic, bool underlined)
 Constructor.
virtual ~CFont ()
 Destructor.
RECT CalcualteSize (const std::string &text, int align)
 Calcualte size.
RECT CalcualteSize (const std::string &text, int align, RECT rectSize)
 Calcualte size.
void DrawText (const std::string &text, int x, int y, D3DCOLOR rgbFontColour=NULL, int align=-1)
 Draw text.
void DrawText (const std::string &text, RECT *rect, D3DCOLOR rgbFontColour=NULL, int align=-1)
 Draw text.
void SetAlign (int algin)
 Sets an align.
void SetColor (D3DCOLOR rgbFontColour)
 Sets a color.
HRESULT OnLostDevice ()
 Executes the lost device action.
HRESULT OnResetDevice ()
 Executes the reset device action.
void SetAlphaBlending (int alphaBlending)
 Sets an alpha blending.

Detailed Description

Font.

Author:
Christian Knobloch
Date:
19.04.2010

Constructor & Destructor Documentation

CFont::CFont ( const std::string &  fontFace,
int  height,
bool  bold,
bool  italic,
bool  underlined 
)

Constructor.

Author:
Christian Knobloch
Date:
19.04.2010
Parameters:
fontFaceThe font face.
heightThe height.
boldtrue to bold.
italictrue to italic.
underlinedtrue to underlined.
CFont::~CFont ( ) [virtual]

Destructor.

Author:
Christian Knobloch
Date:
19.04.2010

Member Function Documentation

RECT CFont::CalcualteSize ( const std::string &  text,
int  align 
)

Calcualte size.

Author:
Christian Knobloch
Date:
13.09.2010
Parameters:
textThe text.
alignThe align.
Returns:
.
RECT CFont::CalcualteSize ( const std::string &  text,
int  align,
RECT  rectSize 
)

Calcualte size.

Author:
Christian Knobloch
Date:
13.09.2010
Parameters:
textThe text.
alignThe align.
rectSizeSize of the rectangle.
Returns:
.
void CFont::DrawText ( const std::string &  text,
int  x,
int  y,
D3DCOLOR  rgbFontColour = NULL,
int  align = -1 
)

Draw text.

Author:
Christian Knobloch
Date:
19.04.2010
Parameters:
textThe text.
xThe x coordinate.
yThe y coordinate.
rgbFontColourThe rgb font colour.
alignThe align.
void CFont::DrawText ( const std::string &  text,
RECT *  rect,
D3DCOLOR  rgbFontColour = NULL,
int  align = -1 
)

Draw text.

Author:
Christian Knobloch
Date:
19.04.2010
Parameters:
textThe text.
[in,out]RectIf non-null, the rectangle.
rgbFontColourThe rgb font colour.
alignThe align.
HRESULT CFont::OnLostDevice ( )

Executes the lost device action.

Author:
Christian Knobloch
Date:
01.06.2010
Returns:
.
HRESULT CFont::OnResetDevice ( )

Executes the reset device action.

Author:
Christian Knobloch
Date:
01.06.2010
Returns:
.
void CFont::SetAlign ( int  align)

Sets an align.

Author:
Christian Knobloch
Date:
19.04.2010
Parameters:
alignThe align.
void CFont::SetAlphaBlending ( int  alphaBlending)

Sets an alpha blending.

Author:
Christian Knobloch
Date:
19.04.2010
Parameters:
alphaBlendingThe alpha blending.
void CFont::SetColor ( D3DCOLOR  rgbFontColour)

Sets a color.

Author:
Christian Knobloch
Date:
19.04.2010
Parameters:
rgbFontColourThe rgb font colour.

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines