You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.
# pragma once
# include "mAlgDefines.h"
# include "iGuiPlot.h"
# include "iCurveDesc.h"
# include "mSubWnd_global.h"
// 曲线的一些基本信息设置
class M_SUB_WND_EXPORT iModelCurveDesc
{
public :
// 获取对象,单例模式
static iModelCurveDesc * getInstance ( ) ;
// 关闭消耗
static void release ( ) ;
private :
iModelCurveDesc ( ) ;
~ iModelCurveDesc ( ) ;
public :
// 设置曲线数据
void setCurveDescData ( QString s , VecDouble & vecX , VecDouble & vecY ) ;
// 得到曲线的数据iCurveDesc( 主要用于替换)
bool getCurveDescByName ( QString s , int & nIndex , iCurveDesc & o ) ;
// 设置曲线
void changeOrAppendCurveDesc ( QString s , iCurveDesc & o ) ;
private :
// 默认从后台模板加载一下
bool loadFromTeml ( iCurveDesc & o ) ;
// 初始化曲线的线型,颜色等
void initModelCurveDesc ( ) ;
// 原先应编码模式
void initCdByHardCode ( ) ;
# ifdef QT_DEBUG
// 原先编码方式, 可以直接生成ini供新的模式使用
void exportConfigToFile ( const QString & filePath ) ;
# endif
// 新的机制,配置化
bool initCdByNovel ( ) ;
bool loadCdFile ( const QString & filePath ) ;
bool parseCdLine ( const QString & line , \
QString & name , \
QStringList & params ) ;
bool parseInfo2Cd ( iCurveDesc & desc , \
const QStringList & params ) ;
private :
static iModelCurveDesc * m_pInstance ;
private :
QVector < iCurveDesc > m_vecCurveDesc ;
QMap < QString , QStringList > m_mapCdConfigs ;
} ;
# define _curveHelper iModelCurveDesc::getInstance()