3 #ifndef __zqb_natgroup_hpp
4 #define __zqb_natgroup_hpp
8 #include "zqb_macros.h"
9 #include "zqb_autoname.hpp"
10 #include "zqb_pixgroup.hpp"
11 #include "zqb_natgrpmember.hpp"
53 virtual void getCoords (
double c[2])
const;
63 virtual bool setCoords (
double c[2],
bool bForce =
false);
68 bool bForce =
false) {
69 double prev_c[2], new_c[2];
72 if(prev_c[0] < prev_c[1])
74 new_c[0] = ZqbMIN(c[0], c[1]);
75 new_c[1] = ZqbMAX(c[0], c[1]);
79 new_c[0] = ZqbMAX(c[0], c[1]);
80 new_c[1] = ZqbMIN(c[0], c[1]);
95 bool bForce =
false) {
105 bool bForce =
false) {
116 if(range[0] < range[1])
117 return range[0] <= c && c <= range[1];
120 return range[0] >= c && c >= range[1];
162 virtual bool getBounds (
double b[2] = NULL)
const;
202 bool operator< (
const Tick& t)
const {
205 bool operator== (
const Tick& t)
const {
208 bool operator!= (
const Tick& t)
const {
209 return !operator==(t);
295 static int m_iNameCounter;
double m_fCoord
Definition: zqb_natgroup.hpp:198
virtual void getCoords(double c[2]) const
virtual double calcMainTickStep(int *pMainTicksPrec=NULL) const
virtual double getMainTickStep() const
virtual bool n2p(ZqbPixGroup &pg, double nc, int &pc)
virtual bool removeMember(ZqbNatGrpMember *pMember)
bool setCoordsSameOrder(double c[2], bool bForce=false)
Definition: zqb_natgroup.hpp:67
Definition: zqb_natgroup.hpp:35
bool m_bAutoCalcFreq
Definition: zqb_natgroup.hpp:277
virtual void unsetBounds()
double m_fMainTicksStep
Definition: zqb_natgroup.hpp:281
virtual void setAutoTickMode(bool bAuto)
virtual bool addMember(ZqbNatGrpMember *pMember)
virtual bool setCoords(double c[2], bool bForce=false)
double m_fBounds[2]
Definition: zqb_natgroup.hpp:271
virtual int getSubTickFreq() const
virtual void setMainTickStep(double fStep)
bool isVisible(double c) const
Definition: zqb_natgroup.hpp:113
virtual bool p2n(ZqbPixGroup &pg, int pc, double &nc)
Definition: zqb_autoname.hpp:18
virtual bool getBounds(double b[2]=NULL) const
bool m_bMain
Definition: zqb_natgroup.hpp:199
bool m_bKnownBounds
Definition: zqb_natgroup.hpp:268
std::vector< Tick > Ticks
Definition: zqb_natgroup.hpp:214
void setBounds(double b1, double b2)
Definition: zqb_natgroup.hpp:151
virtual void calcTicks(Ticks &ticks) const
bool setCoords(double c1, double c2, bool bForce=false)
Definition: zqb_natgroup.hpp:94
bool setCoordsSameOrder(double c1, double c2, bool bForce=false)
Definition: zqb_natgroup.hpp:104
virtual int getMainTickPrec() const
virtual void setSubTickFreq(int nTicks)
Definition: zqb_natgroup.hpp:197
int m_nMainTicksPrec
Definition: zqb_natgroup.hpp:285
Definition: zqb_natgrpmember.hpp:26
ZqbNatGrpMembers m_Members
Definition: zqb_natgroup.hpp:264
virtual void unifyBounds()
ZqbNatGroup(const char *szName=NULL)
double m_fCoords[2]
Definition: zqb_natgroup.hpp:274
int m_nSubTicks
Definition: zqb_natgroup.hpp:290
virtual bool getAutoTickMode() const
Definition: zqb_pixgroup.hpp:34
virtual void setBounds(double b[2])