Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

osgText::Font Class Reference

Inheritance diagram for osgText::Font:

Inheritance graph
[legend]
List of all members.

Public Methods

 Font ()
 Font (const Font &font, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
virtual bool isSameKindAs (const osg::Object *obj) const
virtual const char * libraryName () const
 return the name of the object's library.

virtual const char * className () const
 return the name of the object's class type.

bool open (const char *font)
bool open (const std::string &font)
virtual bool create (osg::State &state, int pointSize, const unsigned int res=72)
virtual bool create (osg::State &state)
virtual void output (osg::State &state, const char *text)
virtual bool isOk (void) const
virtual bool isCreated (void) const
virtual float getWidth (const char *text) const
virtual int getHeight () const
virtual int getDescender () const
virtual int getAscender () const
int getPointSize (void) const
int getTextureSize (void) const
const std::string & getFontName () const
void copyAndInvalidate (Font &dest)
 Transfer font settings to another Font object and invalidate this one.

FTFont * getFont (void)

Protected Methods

virtual ~Font ()
virtual void clear ()
virtual FTFont * createFontObj (void)=0
bool init (const std::string &font)

Protected Attributes

bool _init
bool _created
FTFont * _font
std::string _fontName
int _pointSize
int _res
int _textureSize

Constructor & Destructor Documentation

osgText::Font::Font (    ) 
 

osgText::Font::Font (  const Font &    font,
const osg::CopyOp &    copyop = osg::CopyOp::SHALLOW_COPY
)  [inline]
 

virtual osgText::Font::~Font (    )  [protected, virtual]
 


Member Function Documentation

virtual const char* osgText::Font::className (    )  const [inline, virtual]
 

return the name of the object's class type.

Must be defined by derived classes.

Implements osg::Object.

Reimplemented in osgText::RasterFont, and osgText::VectorFont.

virtual void osgText::Font::clear (    )  [protected, virtual]
 

void osgText::Font::copyAndInvalidate (  Font &    dest ) 
 

Transfer font settings to another Font object and invalidate this one.

virtual bool osgText::Font::create (  osg::State &    state )  [virtual]
 

virtual bool osgText::Font::create (  osg::State &    state,
int    pointSize,
const unsigned int    res = 72
)  [virtual]
 

virtual FTFont* osgText::Font::createFontObj (  void    )  [protected, pure virtual]
 

Implemented in osgText::BitmapFont, osgText::PixmapFont, osgText::TextureFont, osgText::OutlineFont, and osgText::PolygonFont.

virtual int osgText::Font::getAscender (    )  const [virtual]
 

virtual int osgText::Font::getDescender (    )  const [virtual]
 

FTFont* osgText::Font::getFont (  void    )  [inline]
 

const std::string& osgText::Font::getFontName (    )  const [inline]
 

virtual int osgText::Font::getHeight (    )  const [virtual]
 

int osgText::Font::getPointSize (  void    )  const [inline]
 

int osgText::Font::getTextureSize (  void    )  const [inline]
 

virtual float osgText::Font::getWidth (  const char *    text )  const [virtual]
 

bool osgText::Font::init (  const std::string &    font )  [protected]
 

virtual bool osgText::Font::isCreated (  void    )  const [inline, virtual]
 

virtual bool osgText::Font::isOk (  void    )  const [inline, virtual]
 

virtual bool osgText::Font::isSameKindAs (  const osg::Object *    obj )  const [inline, virtual]
 

Reimplemented in osgText::RasterFont, and osgText::VectorFont.

virtual const char* osgText::Font::libraryName (    )  const [inline, virtual]
 

return the name of the object's library.

Must be defined by derived classes. The OpenSceneGraph convention the is that the namspace of a library is the same as the library name.

Implements osg::Object.

Reimplemented in osgText::RasterFont, and osgText::VectorFont.

bool osgText::Font::open (  const std::string &    font ) 
 

bool osgText::Font::open (  const char *    font ) 
 

virtual void osgText::Font::output (  osg::State &    state,
const char *    text
)  [virtual]
 


Member Data Documentation

bool osgText::Font::_created [protected]
 

FTFont* osgText::Font::_font [protected]
 

std::string osgText::Font::_fontName [protected]
 

bool osgText::Font::_init [protected]
 

int osgText::Font::_pointSize [protected]
 

int osgText::Font::_res [protected]
 

int osgText::Font::_textureSize [protected]
 


The documentation for this class was generated from the following file:
Generated at Wed Sep 18 13:55:55 2002 for the Open Scene Graph by doxygen 1.2.16.