GClasses

GClasses::GPlotLabelSpacerLogarithmic Class Reference

Similar to GPlotLabelSpacer, except for logarithmic grids. To plot in logarithmic space, set your plot window to have a range from log_e(min) to log_e(max). When you actually plot things, plot them at log_e(x), where x is the position of the thing you want to plot. More...

#include <GPlot.h>

List of all members.

Public Member Functions

 GPlotLabelSpacerLogarithmic (double log_e_min, double log_e_max)
 Pass in the log (base e) of your min and max values. (We make you pass them in logarithmic form, so you can't use a negative min value.)
bool next (double *pos, bool *primary)
 Returns true and sets *pos to the position of the next label. (You should actually plot it at log_e(*pos) in your plot window.) Returns false if there are no more (and doesn't set *pos). primary is set to true if the label is the primary label for the new scale.

Protected Attributes

double m_max
int m_n
int m_i

Detailed Description

Similar to GPlotLabelSpacer, except for logarithmic grids. To plot in logarithmic space, set your plot window to have a range from log_e(min) to log_e(max). When you actually plot things, plot them at log_e(x), where x is the position of the thing you want to plot.


Constructor & Destructor Documentation

GClasses::GPlotLabelSpacerLogarithmic::GPlotLabelSpacerLogarithmic ( double  log_e_min,
double  log_e_max 
)

Pass in the log (base e) of your min and max values. (We make you pass them in logarithmic form, so you can't use a negative min value.)


Member Function Documentation

bool GClasses::GPlotLabelSpacerLogarithmic::next ( double *  pos,
bool *  primary 
)

Returns true and sets *pos to the position of the next label. (You should actually plot it at log_e(*pos) in your plot window.) Returns false if there are no more (and doesn't set *pos). primary is set to true if the label is the primary label for the new scale.


Member Data Documentation