SDL SPOOKY PLATFORMER ENGINE  0.2.0
An implementation of a platformer using sdl, implemented using an entity component system and efficient collision management.
Public Member Functions | Static Public Member Functions | Protected Attributes | List of all members
TextManager Class Reference

#include <TextManager.hpp>

Inheritance diagram for TextManager:
ResourceManager< TextManager, TTF_Font >

Public Member Functions

int startUp (SDL_Renderer *in)
 
int shutDown ()
 
std::shared_ptr< TTF_Font > Load (const std::string &path)
 
 TextManager (TextManager const &) = delete
 Forbidden. More...
 
void operator= (TextManager const &) = delete
 Forbidden. More...
 
- Public Member Functions inherited from ResourceManager< TextManager, TTF_Font >
bool AddAllResource ()
 
bool AddResource (const std::string &resourceName)
 
std::shared_ptr< TTF_Font > GetResource (const std::string &resourceName)
 
std::shared_ptr< TTF_Font > Load (const std::string &path)
 
int shutDown ()
 

Static Public Member Functions

static TextManager & instance ()
 

Protected Attributes

SDL_Renderer * ren
 The renderer. More...
 
- Protected Attributes inherited from ResourceManager< TextManager, TTF_Font >
std::map< std::string, std::string > fileMap
 stores location of resources More...
 
std::map< std::string, std::pair< std::shared_ptr< TTF_Font >, int > > resourceMap
 Internal resource mapping inherited by manager implementations. More...
 

Additional Inherited Members

- Protected Member Functions inherited from ResourceManager< TextManager, TTF_Font >
 ResourceManager ()
 
 ResourceManager (ResourceManager const &)
 Allow subclasses to create a resource manager, but subclasses must ensure singleton functionality. More...
 
void operator= (ResourceManager const &)
 Allow subclasses to assign to a resource manager, but subclasses must ensure singleton functionality. More...
 

Detailed Description

Singleton class for managing TTF_Font Resources

Constructor & Destructor Documentation

TextManager::TextManager ( TextManager const &  )
delete

Forbidden.

Member Function Documentation

static TextManager& TextManager::instance ( )
inlinestatic

Retrieves a singleton instance

std::shared_ptr<TTF_Font> TextManager::Load ( const std::string &  path)
inline

Loads a resource using the ttf engine.

void TextManager::operator= ( TextManager const &  )
delete

Forbidden.

int TextManager::shutDown ( )
inline

Shuts down the TTF engine and resource manager.

int TextManager::startUp ( SDL_Renderer *  in)
inline

starts up the TTF engine

Parameters
inthe renderer to use for this manager.

Member Data Documentation

SDL_Renderer* TextManager::ren
protected

The renderer.


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