version 3.3

VRS::TEXT::FontSize Class Reference

A size class, for absolute and also relative Sizing. More...

#include <vrs/text/fontsize.h>

Inheritance diagram for VRS::TEXT::FontSize:

VRS::SharedObj VRS::Visitable

List of all members.

Public Member Functions

 FontSize ()
 Constructor.
 FontSize (float value, bool absolute)
 Constructor.
 FontSize (SO< FontSize > size)
 Copy Constructor.
virtual ~FontSize ()
 Destructor.
float toPoint (unsigned int dpi) const
 Returns the value of this FontSize in point.
float toPixel (unsigned int dpi) const
 Returns the value of this FontSize in pixel.
float toMillimeter (unsigned int dpi) const
 Returns the value of this FontSize in millimeters.
float toInch (unsigned int dpi) const
 Returns the value of this FontSize in inch.
float toCentimeter (unsigned int dpi) const
 Returns the value of this FontSize in centimeters.
bool isAbsolute () const
 Returns if the size is absolute, meaning pixel-sized.
float getSizeValue () const
 Returns the size (if absolute it represents pixels, otherwise points).
 VRS_TYPEINFO (FontSize, SharedObj)
 VRS_SERIALIZABLE (FontSize)

Static Public Member Functions

static SO< FontSizefromPoint (float points)
 Creates a FontSize from the given points.
static SO< FontSizefromPixel (float pixels)
 Creates a FontSize from the given pixels.
static SO< FontSizefromMillimeter (float mm)
 Creates a FontSize from the given mm.
static SO< FontSizefromInch (float inch)
 Creates a FontSize from the given inch.
static SO< FontSizefromCentimeter (float cm)
 Creates a FontSize from the given cm.


Detailed Description

A size class, for absolute and also relative Sizing.

Constructor & Destructor Documentation

VRS::TEXT::FontSize::FontSize (  ) 

Constructor.

VRS::TEXT::FontSize::FontSize ( float  value,
bool  absolute 
)

Constructor.

VRS::TEXT::FontSize::FontSize ( SO< FontSize size  ) 

Copy Constructor.

virtual VRS::TEXT::FontSize::~FontSize (  )  [virtual]

Destructor.


Member Function Documentation

static SO<FontSize> VRS::TEXT::FontSize::fromPoint ( float  points  )  [static]

Creates a FontSize from the given points.

static SO<FontSize> VRS::TEXT::FontSize::fromPixel ( float  pixels  )  [static]

Creates a FontSize from the given pixels.

static SO<FontSize> VRS::TEXT::FontSize::fromMillimeter ( float  mm  )  [static]

Creates a FontSize from the given mm.

static SO<FontSize> VRS::TEXT::FontSize::fromInch ( float  inch  )  [static]

Creates a FontSize from the given inch.

static SO<FontSize> VRS::TEXT::FontSize::fromCentimeter ( float  cm  )  [static]

Creates a FontSize from the given cm.

float VRS::TEXT::FontSize::toPoint ( unsigned int  dpi  )  const

Returns the value of this FontSize in point.

float VRS::TEXT::FontSize::toPixel ( unsigned int  dpi  )  const

Returns the value of this FontSize in pixel.

float VRS::TEXT::FontSize::toMillimeter ( unsigned int  dpi  )  const

Returns the value of this FontSize in millimeters.

float VRS::TEXT::FontSize::toInch ( unsigned int  dpi  )  const

Returns the value of this FontSize in inch.

float VRS::TEXT::FontSize::toCentimeter ( unsigned int  dpi  )  const

Returns the value of this FontSize in centimeters.

bool VRS::TEXT::FontSize::isAbsolute (  )  const

Returns if the size is absolute, meaning pixel-sized.

float VRS::TEXT::FontSize::getSizeValue (  )  const

Returns the size (if absolute it represents pixels, otherwise points).

VRS::TEXT::FontSize::VRS_TYPEINFO ( FontSize  ,
SharedObj   
)

VRS::TEXT::FontSize::VRS_SERIALIZABLE ( FontSize   ) 


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

Generated on Wed May 23 06:00:35 2012 by Doxygen 1.5.6
© 2001-2010 Hasso-Plattner-Institut | Impressum | Contact