Nymph Game Engine
Chaiscript based Game Engine
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Graphics::UI::Font Class Reference

Class for font. More...

#include <font.h>

Public Member Functions

 Font (const unsigned int size=12, const unsigned int pixels_per_unit=32)
 Font constructor. More...
 
void addCharacter (const char text_char, const Character &character)
 Adds a character. More...
 
Character getCharacter (const char text_char)
 Gets the character. More...
 
std::map< char, CharactergetCharacters () const
 Gets the characters. More...
 
unsigned int getSize () const noexcept
 Gets the size. More...
 
float getOpenGLSize () const noexcept
 Gets the open gl size. More...
 

Detailed Description

Class for font.

Constructor & Destructor Documentation

Graphics::UI::Font::Font ( const unsigned int  size = 12,
const unsigned int  pixels_per_unit = 32 
)

Font constructor.

Parameters
[in]sizeThe size
[in]pixels_per_unitThe pixels per unit

Member Function Documentation

void Graphics::UI::Font::addCharacter ( const char  text_char,
const Character character 
)

Adds a character.

Parameters
[in]text_charThe text character
[in]characterThe engine character

Referenced by generated::getFontModule().

Character Graphics::UI::Font::getCharacter ( const char  text_char)

Gets the character.

Parameters
[in]text_charThe text character
Returns
The character.

Referenced by generated::getFontModule().

std::map< char, Character > Graphics::UI::Font::getCharacters ( ) const

Gets the characters.

Returns
The characters.

Referenced by generated::getFontModule().

float Graphics::UI::Font::getOpenGLSize ( ) const
noexcept

Gets the open gl size.

Returns
The open gl size.

Referenced by generated::getFontModule().

unsigned int Graphics::UI::Font::getSize ( ) const
noexcept

Gets the size.

Returns
The size.

Referenced by generated::getFontModule().


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