File indexing completed on 2024-12-22 04:17:20
0001 /*************************************************************************** 0002 * * 0003 * copyright : (C) 2007 The University of Toronto * 0004 * netterfield@astro.utoronto.ca * 0005 * copyright : (C) 2005 University of British Columbia * 0006 * dscott@phas.ubc.ca * 0007 * * 0008 * This program is free software; you can redistribute it and/or modify * 0009 * it under the terms of the GNU General Public License as published by * 0010 * the Free Software Foundation; either version 2 of the License, or * 0011 * (at your option) any later version. * 0012 * * 0013 ***************************************************************************/ 0014 0015 #ifndef GENERATEDMATRIX_H 0016 #define GENERATEDMATRIX_H 0017 0018 #include "matrix.h" 0019 #include "kst_export.h" 0020 0021 namespace Kst { 0022 0023 class KSTCORE_EXPORT GeneratedMatrix : public Matrix { 0024 Q_OBJECT 0025 0026 public: 0027 virtual const QString& typeString() const; 0028 static const QString staticTypeString; 0029 static const QString staticTypeTag; 0030 0031 virtual void save(QXmlStreamWriter &xml); 0032 0033 void change(uint nX, uint nY, 0034 double minX, double minY, double stepX, double stepY, 0035 double gradZMin, double gradZMax, bool xDirection); 0036 0037 // return gradient min and maxes in order 0038 double gradZMin() { return _gradZMin; } 0039 double gradZMax() { return _gradZMax; } 0040 bool xDirection() { return _xDirection; } 0041 0042 protected: 0043 GeneratedMatrix(ObjectStore *store); 0044 0045 friend class ObjectStore; 0046 0047 private: 0048 double _gradZMin; 0049 double _gradZMax; 0050 bool _xDirection; 0051 }; 0052 0053 typedef SharedPtr<GeneratedMatrix> GeneratedMatrixPtr; 0054 typedef ObjectList<GeneratedMatrix> GeneratedMatrixList; 0055 0056 } 0057 0058 #endif 0059 // vim: ts=2 sw=2 et