C4 Engine Terathon Software C4 Engine API Documentation

• Interface Manager

API Links
Developer Links

class Font

Defined in:  C4Fonts.h
The Font class encapsulates a text font.
Definition

class Font : public Shared

Member Functions
Font::Get Returns a new reference to a font object.
Font::GetFontHeader Returns the font header.
Font::GetLineSpacing Returns the font's machine line spacing.
Font::GetTextWidth Returns the width of a text string.
Constructor

Font(FontResource *resource, const char *name);

The Font constructor has private access. The Font::Get function should be used to create font objects.
Description
The Font object encapsulates the resources needed to manage a text font. New font objects are created by calling the Font::Get function.
Base Classes
Shared Font objects are reference counted.