CVidFont Class


Overview

Note

The CVidFont class handles fonts

The structure used for this class is CVidFont


Quick Reference

Quick Ref

void CVidFont::CVidFont()

void CVidFont::~CVidFont()

short CVidFont::GetFontHeight()

long CVidFont::GetStringHeight(CString& text, int w)

long CVidFont::GetStringLength(CString& str, int w)

int CVidFont::RenderTextWrap(const char* text, int x, int y, int w, int h, CRect& rClip, int halign, int valign, bool shadow, bool backgroundRect)

void CVidFont::SetColor(unsigned long wNewForeground)

void CVidFont::SetResRef(CResRef& cNewResRef, int bSetAutoRequest)

void CVidFont::SetTintColor(unsigned long c)

void CVidFont::SetZoom(int newZoom)


Constructors

Name

Description

CVidFont::CVidFont

Constructs a CVidFont object

CVidFont::CVidFont

Destroys a CVidFont object

CVidFont::CVidFont

Constructs a CVidFont object

void CVidFont::CVidFont();

Remarks

Constructs a CVidFont object


CVidFont::~CVidFont

Destroys the CVidFont object

virtual void CVidFont::~CVidFont();

Remarks

Destroys the CVidFont object


Methods

Name

Description

CVidFont::GetFontHeight

CVidFont::GetStringHeight

CVidFont::GetStringLength

CVidFont::RenderTextWrap

CVidFont::SetColor

CVidFont::SetResRef

CVidFont::SetTintColor

CVidFont::SetZoom


CVidFont::GetFontHeight

short CVidFont::GetFontHeight();

Return Value

Returns short

Remarks


CVidFont::GetStringHeight

long CVidFont::GetStringHeight(
   CString& text,
   int w);

Parameters

Return Value

Returns long

Remarks


CVidFont::GetStringLength

long CVidFont::GetStringLength(
   CString& str,
   int w);

Parameters

Return Value

Returns long

Remarks


CVidFont::RenderTextWrap

int CVidFont::RenderTextWrap(
   const char* text,
   int x,
   int y,
   int w,
   int h,
   CRect& rClip,
   int halign,
   int valign,
   bool shadow,
   bool backgroundRect);

Parameters

  • const char* text -

  • int x -

  • int y -

  • int w -

  • int h -

  • CRect& rClip -

  • int halign -

  • int valign -

  • bool shadow -

  • bool backgroundRect -

Return Value

Returns int

Remarks


CVidFont::SetColor

void CVidFont::SetColor(unsigned long wNewForeground);

Parameters

  • unsigned long wNewForeground -

Remarks


CVidFont::SetResRef

void CVidFont::SetResRef(
   CResRef& cNewResRef,
   int bSetAutoRequest);

Parameters

  • CResRef& cNewResRef -

  • int bSetAutoRequest -

Remarks


CVidFont::SetTintColor

void CVidFont::SetTintColor(unsigned long c);

Parameters

  • unsigned long c -

Remarks


CVidFont::SetZoom

void CVidFont::SetZoom(int newZoom);

Parameters

  • int newZoom -

Remarks