copasi API
0.1
|
00001 // Begin CVS Header 00002 // $Source: /fs/turing/cvs/copasi_dev/copasi/barChart/qwt3dScale.h,v $ 00003 // $Revision: 1.4 $ 00004 // $Name: Build-33 $ 00005 // $Author: shoops $ 00006 // $Date: 2009/02/19 15:17:50 $ 00007 // End CVS Header 00008 00009 // Copyright (C) 2008 by Pedro Mendes, Virginia Tech Intellectual 00010 // Properties, Inc., EML Research, gGmbH, University of Heidelberg, 00011 // and The University of Manchester. 00012 // All rights reserved. 00013 00014 // Copyright (C) 2001 - 2007 by Pedro Mendes, Virginia Tech Intellectual 00015 // Properties, Inc. and EML Research, gGmbH. 00016 // All rights reserved. 00017 00018 #ifndef SCALE_H 00019 #define SCALE_H 00020 00021 #include <qstring.h> 00022 #include <qwt3d_scale.h> 00023 #include <qwt3d_types.h> 00024 #include <qwt3d_autoptr.h> 00025 #include <qwt3d_axis.h> 00026 00028 class LinearAutoScaler2 : public Qwt3D::LinearAutoScaler 00029 { 00030 public: 00031 int execute2(double& a, double& b, double start, double stop, int ivals); 00032 }; 00033 00035 class ValueScale : public Qwt3D::Scale 00036 { 00037 friend class Qwt3D::Axis; 00038 friend class Qwt3D::qwt3d_ptr<Qwt3D::Scale>; 00039 protected: 00040 int autoscale(double& a, double& b, double start, double stop, int ivals); 00042 Qwt3D::Scale* clone() const {return new ValueScale(*this);} 00043 void calculate(); 00044 LinearAutoScaler2 autoscaler_p2; 00045 public: 00046 QString ticLabel(unsigned int idx) const; 00047 }; 00048 00049 class ColumnScale : public ValueScale 00050 { 00051 friend class Qwt3D::Axis; 00052 friend class Qwt3D::qwt3d_ptr<Scale>; 00053 protected: 00054 Qwt3D::Scale* clone() const {return new ColumnScale(*this);} 00055 public: 00056 ColumnScale(const std::vector<std::string> * vos, int showColumn = -1); 00057 virtual QString ticLabel(unsigned int idx) const; 00058 const std::vector<std::string> *mpColumnsDes; 00059 unsigned int showColumn; 00060 }; 00061 00062 class RowScale : public ValueScale 00063 { 00064 friend class Qwt3D::Axis; 00065 friend class Qwt3D::qwt3d_ptr<Scale>; 00066 protected: 00067 Qwt3D::Scale* clone() const {return new RowScale(*this);} 00068 public: 00069 RowScale(const std::vector<std::string> * vos, int showRow = -1); 00070 QString ticLabel(unsigned int idx) const; 00071 const std::vector<std::string> *mpRowsDes; 00072 unsigned int showRow; 00073 }; 00074 #endif // SCALE_H