osg::TextLayoutResult Class Reference

#include <OSGTextLayoutResult.h>

List of all members.

Public Member Functions

 TextLayoutResult ()
void clear ()
UInt32 getNumGlyphs () const

Public Attributes

std::vector< TextGlyph::Indexindices
std::vector< Vec2fpositions
std::vector< Vec2flineBounds
Vec2f textBounds


Detailed Description

Keeps the result of a layout operation.
Author:
Patrick Dähne

Definition at line 63 of file OSGTextLayoutResult.h.


Constructor & Destructor Documentation

osg::TextLayoutResult::TextLayoutResult (  )  [inline]

Creates a new TextLayoutResult object.

Definition at line 43 of file OSGTextLayoutResult.inl.

00044 : indices(), positions(), lineBounds(), textBounds()
00045 {}


Member Function Documentation

void osg::TextLayoutResult::clear ( void   ) 

Clears the TextLayoutResult object.

Definition at line 56 of file OSGTextLayoutResult.cpp.

References indices, lineBounds, positions, and textBounds.

00057 {
00058     indices.clear();
00059     positions.clear();
00060     lineBounds.clear();
00061     textBounds.setValues(0.f, 0.f);
00062 }

UInt32 osg::TextLayoutResult::getNumGlyphs (  )  const [inline]

Returns the number of glyph indices that have a corresponding position.

Returns:
The number of glyphs.

Definition at line 48 of file OSGTextLayoutResult.inl.

References indices, and positions.

Referenced by osg::TextTXFFace::addToGeom(), osg::TextFace::calculateBoundingBox(), osg::SimpleStatisticsForeground::drawCharacters(), osg::GraphicStatisticsForeground::drawString(), osg::TextVectorFace::fillGeo(), and osg::TextPixmapFace::makeImage().

00049 { return positions.size() < indices.size() ? positions.size() : indices.size(); }


Member Data Documentation

The line bounds

Definition at line 88 of file OSGTextLayoutResult.h.

Referenced by clear().

The text bounds

Definition at line 91 of file OSGTextLayoutResult.h.

Referenced by clear(), and osg::SimpleStatisticsForeground::draw().


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

Generated on Mon Mar 17 12:15:24 2008 for OpenSG by  doxygen 1.5.5