Poster of Linux kernelThe best gift for a Linux geek
tlp::GlNominativeAxis

tlp::GlNominativeAxis

Section: Tulip Open GL Library (3) Updated: 19 Jul 2010
Local index Up
 

NAME

tlp::GlNominativeAxis -

A class to render an axis graduated with string values.

 

SYNOPSIS


#include <GlNominativeAxis.h>

Inherits tlp::GlAxis.  

Public Member Functions


GlNominativeAxis (const std::string &axisName, const Coord &axisBaseCoord, const float axisLength, const AxisOrientation &axisOrientation, const Color &axisColor)

void setAxisGraduationsLabels (const std::vector< std::string > &axisGradsLabels, const LabelPosition &labelsPosition)

void updateAxis ()

Coord getAxisPointCoordForValue (std::string value)

std::string getValueAtAxisPoint (const Coord &axisPointCoord)

void translate (const Coord &c)
 

Detailed Description

A class to render an axis graduated with string values.

This class allow to draw a nominative axis (i.e. an axis graduated with string values)  

Constructor & Destructor Documentation

 

tlp::GlNominativeAxis::GlNominativeAxis (const std::string & axisName, const Coord & axisBaseCoord, const float axisLength, const AxisOrientation & axisOrientation, const Color & axisColor)GlNominativeAxis constructor. Build a nominative axis with no graduations (need to call setAxisGraduationsLabels to build them)

Parameters:

axisName the name of the axis the base coord of the axis (if the axis is horizontal, it is the the left end, if vertical it is the down end) the length of the axis the orientation of the axis, 2 possible values (HORIZONTAL_AXIS or VERTICAL_AXIS) the color of the axis

 

Member Function Documentation

 

Coord tlp::GlNominativeAxis::getAxisPointCoordForValue (std::string value)Method to get the axis point coordinates associated to string value

Parameters:

value the string value we want to retrieve axis point coordinates

 

std::string tlp::GlNominativeAxis::getValueAtAxisPoint (const Coord & axisPointCoord)Method to get the string value associated to an axis point. Return '' if there is not.

Parameters:

axisPointCoord the axis point coordinates we want to retrieve the associated string value

 

void tlp::GlNominativeAxis::setAxisGraduationsLabels (const std::vector< std::string > & axisGradsLabels, const LabelPosition & labelsPosition)Method to set the axis graduations labels. A call to updateAxis has to be done after calling this method to build or update the axis graduations. The labels will be placed on the axis in the same order as the vector passed as parameter (from bottom to top if the axis is vertical, from left to right if it is horizontal).

Parameters:

axisGradsLabels a vector of string containing the graduations labels
labelsPosition the relative position of the axis graduations label. Two possible values : LEFT_OR_BELOW (if the axis is vertical, labels will be on the left of the axis, otherwise below) or RIGHT_OR_ABOVE

 

void tlp::GlNominativeAxis::translate (const Coord & mouvement) [virtual]translate the composite with children

Reimplemented from tlp::GlAxis.  

void tlp::GlNominativeAxis::updateAxis () [virtual]Method to update the axis drawing. It has to be called when one (or more) of the setters method above has been used. This method redraw the whole axis and the graduations.

Reimplemented from tlp::GlAxis.

 

Author

Generated automatically by Doxygen for Tulip Open GL Library from the source code.


 

Index

NAME
SYNOPSIS
Public Member Functions
Detailed Description
Constructor & Destructor Documentation
tlp::GlNominativeAxis::GlNominativeAxis (const std::string & axisName, const Coord & axisBaseCoord, const float axisLength, const AxisOrientation & axisOrientation, const Color & axisColor)GlNominativeAxis constructor. Build a nominative axis with no graduations (need to call setAxisGraduationsLabels to build them)
Member Function Documentation
Coord tlp::GlNominativeAxis::getAxisPointCoordForValue (std::string value)Method to get the axis point coordinates associated to string value
std::string tlp::GlNominativeAxis::getValueAtAxisPoint (const Coord & axisPointCoord)Method to get the string value associated to an axis point. Return '' if there is not.
void tlp::GlNominativeAxis::setAxisGraduationsLabels (const std::vector< std::string > & axisGradsLabels, const LabelPosition & labelsPosition)Method to set the axis graduations labels. A call to updateAxis has to be done after calling this method to build or update the axis graduations. The labels will be placed on the axis in the same order as the vector passed as parameter (from bottom to top if the axis is vertical, from left to right if it is horizontal).
void tlp::GlNominativeAxis::translate (const Coord & mouvement) [virtual]translate the composite with children
void tlp::GlNominativeAxis::updateAxis () [virtual]Method to update the axis drawing. It has to be called when one (or more) of the setters method above has been used. This method redraw the whole axis and the graduations.
Author

This document was created by man2html, using the manual pages.
Time: 22:28:15 GMT, April 16, 2011