VisioMove SDK (iOS)  2.1.22
VgEngine::VgFontManager Class Referenceabstract

Public Member Functions

virtual ~VgFontManager ()
 
virtual bool setFont (const std::string &pFontFilename)=0
 
virtual bool setFont (const std::string &pFontFilename, unsigned int pDPIResolution)=0
 
virtual bool setFontDpi (unsigned int pDPIResolution)=0
 

Protected Member Functions

 VgFontManager ()
 

Detailed Description

Set the Font and configures it to render text.

Note
The font manager can set font between VgEngine::VgIDatabase::loadConfiguration and VgEngine::VgIDatabase::unloadConfiguration. However, once a font is set, it will be valid until the font manager is deleted (i.e. when the VgApplication::VgIApplication is deleted).
Version
2.0.8387
2.1.0 updated to be a true interface

Constructor & Destructor Documentation

VgEngine::VgFontManager::VgFontManager ( )
inlineprotected

Constructor.

virtual VgEngine::VgFontManager::~VgFontManager ( )
inlinevirtual

Destructor

References setFont(), and setFontDpi().

Member Function Documentation

virtual bool VgEngine::VgFontManager::setFont ( const std::string &  pFontFilename)
pure virtual

Sets a new font.

Parameters
pFontFilenameFont file to load. The font will be searched locally in the Data bundle's "config" directory otherwise use an absolute path.
Returns
True if the font has been set. False if the font is not found/incorrect.
Note
This is effective only between VgEngine::VgIDatabase::loadConfiguration and the rendering of the first frame. It will have no effect if called outside.
By default, the resolution will be set to 96 dpi. To change the resolution, you may you use either setFont (const std::string& pFontFilename, unsigned int pDPIResolution) or setFontDpi.
If the specified font fails to load, the previous one is still set.

Referenced by ~VgFontManager().

virtual bool VgEngine::VgFontManager::setFont ( const std::string &  pFontFilename,
unsigned int  pDPIResolution 
)
pure virtual

Sets a new font.

Parameters
pFontFilenameFont file to load. The font will be searched locally in the Data bundle's "config" directory. The path is expected to be absolute.
pDPIResolutionDevice resolution in dot-per-inch. By default, the resolution is 96dpi.
Returns
True if the font has been registered. False if the font is not found/incorrect.
Note
This is effective only between VgEngine::VgIDatabase::loadConfiguration and the rendering of the first frame. It will have no effect if called outside.
If the specified font fails to load, the previous one is still set.
virtual bool VgEngine::VgFontManager::setFontDpi ( unsigned int  pDPIResolution)
pure virtual

Sets the resolution of the font.

Parameters
pDPIResolutionDevice resolution in dot-per-inch. By default, the resolution is 96dpi.
Note
This is effective only between VgEngine::VgIDatabase::loadConfiguration and the rendering of the first frame. It will have no effect if called outside.
Returns
True if the resolution has been updated. It returns False and sets the error code to eInvalidOperation if no font is set.

Referenced by ~VgFontManager().


The documentation for this class was generated from the following file:
VisioMove 2.1.22, Visioglobe® 2016