36#include <Inventor/STL/vector>
540 &addStringVisibility,
SbString &addString)
const ;
555 &path,
SbString &fontName,
float &fontSize,
float &distAxis,
564 &lengthGradOtherSide)
const ;
579 float &subLength,
TickSubDef &def,
unsigned short &numOrPeriod,
580 unsigned short &firstGrad,
unsigned short &lastGrad)
const ;
590 static void initClass() ;
591 static void exitClass() ;
624 float lenGradOtherSide ;
653 std::vector<float> mainGradCoords;
654 std::vector<float> subGradCoords;
668 int getMainGradCoords(
const float* &coords)
const ;
672 int getSubGradCoords(
const float* &coords)
const ;
694 virtual void setDefaultOnNonWritingFields() ;
697 virtual void basicObjectChange(
PbBase *basicObj) ;
700 virtual void saveAxisAttr() ;
703 virtual void setDefaultAttr(Plane plane = XY) ;
706 virtual void computeGradLimit(
float xOrig,
float xExtr,
float &xmOrig,
float &xmExtr) ;
709 virtual void computeTickLen(
size_t numGrad,
float &mainTickLen,
float &secdTickLen) ;
712 virtual void buildArrow(
float orig,
float extr,
SoGroup *group) ;
715 virtual void buildTick(
const std::vector<float>& xGrad,
float tickLen,
719 virtual void buildGridLines(
const std::vector<float>& xGrad,
SoGroup *group) ;
722 void buildTitle(
float xOrig,
float xExtr,
SoGroup *group) ;
726 virtual void buildGrads(
const std::vector<float>& xGrad,
const char **gradStr,
731 void buildMultFactorAtExtr(
int tenPower,
float xOrig,
float xExtr,
float &distAxis,
736 void computeGradList(
float xOrig,
float xExtr,
float step,
size_t numAllGrad,
737 const char** allGradStr,
const std::vector<float>& allGradX,
739 std::vector<float> &mainGradX, std::vector<float> &secondaryGradX) ;
742 static char **allocGradString(
size_t numStr) ;
745 virtual void addElementsAllCaches() ;
746 virtual void preRebuild() ;
757 struct SecondaryLogGrad
765 static void convertLogGradToStr(
SbBool isMainGrad, LogGradType grad_type,
int grad,
766 int ten_pow,
char *string1,
char *string2) ;
769 static void computeLogGradMinDist(
const std::vector<float>& mainGradX,
770 const std::vector<float>& secdGradX,
771 float &min_grad_dist);
774 static void computeDecadeGradList(
size_t numMainGrad,
int **decades,
775 size_t &numDecades) ;
778 void computeLogGradWidth(
const char *str,
const char *tenPowStr,
779 float fontSize,
float &width) ;
782 void computeLogGradsMaxWidth(
const char **strs,
const char **tenPowStrs,
783 size_t numStr,
float fontSize,
float &width,
784 int &indexMaxWidth) ;
787 void drawLogGrad(
float pyAtMax,
float pyAtMin,
float fontSize,
788 LogGradType gradType,
const std::vector<float>& gradX,
789 const char **gradStr,
const char **tenPowStr,
792 static char *PStringToConcat ;
793 static PiText *PLogGradText ;
802 void buildTitleP(
SbBool isTitleBuild,
float xOrig,
float xExtr,
809 FieldSensorList fieldSensorList ;
#define FALSE
Possible value of SbBool.
#define SO_KIT_CATALOG_ENTRY_HEADER(partName)
#define SO_KIT_HEADER(className)
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Abstract class for all b...
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Class to define a numeri...
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Abstract class for axis ...
AxisReverse
Axis reverse type.
@ AXIS_NO_REVERSE
Texts of the axis are no reversed.
@ AXIS_REVERSE
Texts of the axis are reversed (mirror effect).
@ AXIS_REVERSE_DEPEND
Depends on the axis type.
void getMargin(MarginType &type, float &start, float &end) const
Gets the margin axis attributes computed by the last axis rebuilding.
void getTick(Visibility &visibility, TickPosition &position, float &mainLength, float &subLength, TickSubDef &def, unsigned short &numOrPeriod, unsigned short &firstGrad, unsigned short &lastGrad) const
Gets the tick axis attributes computed by the last axis rebuilding.
SoSFFloat gridLengthGradSide
Grid lines length side graduation texts.
SoSFFloat titleFontSize
Font size of the title.
SoSFEnum gradPosition
Graduations position.
SoSFEnum titlePosition
Position of the title.
SoSFEnum tickSubDef
Secondary graduations tick definition.
SoSFFloat marginStart
Margin at the start of the axis.
@ VISIBILITY_OFF
Invisible.
@ VISIBILITY_DEPEND
Depends on the type of the axis.
void getArrow(Visibility &visibility, float &height, float &length) const
Gets the arrow axis attributes computed by the last axis rebuilding.
void setMiscTextAttr(PbMiscTextAttr *textAttr)
Sets a reference to PbMiscTextAttr object for miscellaneous text attributes.
SoSFFloat gradDistAxis
Distance from the graduations to the axis.
SoSFUShort tickFirstGrad
First graduation to display.
SoSFEnum titleVisibility
Visibility of the title.
SoSFString gradAddString
String to be concatenated.
SoSFFloat arrowLength
Arrow length.
SoSFString gradFontName
Graduations font name.
SoSFFloat marginEnd
Margin at the end of the axis.
SoSFUShort tickNumOrPeriod
Number of secondary graduations (tickSubDef = NUM_SUB_TICK), or period of texts of graduations (tickS...
SoSFString titleFontName
Title font name.
SoSFEnum tickVisibility
Tick marks visibility.
SoSFEnum gradPath
Graduations path.
SoSFFloat gridLengthGradOtherSide
Grid lines length other side graduation texts.
SoSFUShort tickLastGrad
Last graduation to display (number starting with the ending one).
void getTitle(Visibility &visibility, TitlePosition &position, TextPath &path, SbString &fontName, float &fontSize, float &distAxis, SbString &string) const
Gets the title axis attributes computed by the last axis rebuilding.
GradPosition
Graduation position type.
@ GRAD_DEPEND
Depends on the type of the axis.
@ GRAD_BELOW
Graduations are below the axis.
@ GRAD_ABOVE
Graduations are above the axis.
SoSFEnum gradVisibility
Graduations visibility.
TitlePosition
Title position type.
@ TITLE_MIDDLE
Title is at the middle of the axis.
@ TITLE_DEPEND
Depends on the axis type.
@ TITLE_END
Title is at the end of the axis.
void getGrad(Visibility &visibility, GradPosition &position, TextPath &path, SbString &fontName, float &fontSize, float &distAxis, SbBool &addStringVisibility, SbString &addString) const
Gets the graduations axis attributes computed by the last axis rebuilding.
@ PATH_LEFT
Writing from right to left.
@ PATH_DOWN
Writing from top to bottom.
@ PATH_UP
Writing from bottom to top.
@ PATH_RIGHT
Writing from left to right.
@ PATH_DEPEND
Depends on the type of the axis.
@ NUM_SUB_TICK
Number of secondary graduations.
@ PERIOD_MAIN_TICK
or period of texts of graduations
SoSFEnum reverseFlag
Allow to reverse the writing path of all axis texts.
SoSFFloat titleDistAxis
Distance from the title to the axis.
SoSFString titleString
Title string.
TickPosition
Tick position type.
@ TICK_GRAD_OTHER_SIDE
Ticks are on the other side of graduations.
@ TICK_ACROSS_AXIS
Ticks across the axis.
@ TICK_GRAD_SIDE
Ticks are on the same side of graduations.
SoSFEnum arrowVisibility
Arrow visibility.
SoSFEnum titlePath
Path of the title.
SoSFFloat arrowHeight
Arrow height.
SoSFFloat gradFontSize
Font size of the graduations.
SoSFEnum tickPosition
Position of the tick marks.
SoSFEnum marginType
Relative or absolute margin.
AxisReverse getReverseFlag() const
Gets the reverse flag axis attributes computed by the last axis rebuilding.
void getGrid(Visibility &visibility, float &lengthGradSide, float &lengthGradOtherSide) const
Gets the grid axis attributes computed by the last axis rebuilding.
const PbMiscTextAttr * getMiscTextAttr() const
Gets a reference to PbMiscTextAttr object for miscellaneous text attributes.
SoSFFloat tickSubLength
Secondary graduations ticks length.
@ REL_MARGIN
Relative margin on the axis.
@ FIXED_MARGIN
Absolute margin on the axis.
SoSFEnum gridVisibility
Grid lines visibility.
SoSFBool gradAddStringVisibility
Specify the visibility of a string concatenated with the graduations.
SoSFFloat tickMainLength
Main graduations ticks length.
<a href="IconLegend.html"><img src="extMV.gif" alt="MeshViz" border="0"></a> Base class for all axis ...
Class for smart character strings.
Maintains a list of pointers to fields.
Base class for all group nodes.
Field containing a single Boolean value.
Field containing an enumerated value.
Field containing a floating-point value.
Field containing a string.
Field containing an unsigned short integer.