|
|
#pragma once
|
|
|
|
|
|
#include "ZxObjCurve.h"
|
|
|
|
|
|
class I_PLOTCURVE_T_EXPORT ZxObjCurvePressure : public ZxObjCurve
|
|
|
{
|
|
|
Q_OBJECT
|
|
|
ZX_DECLARE_DYNAMIC
|
|
|
|
|
|
public:
|
|
|
|
|
|
ZxObjCurvePressure();
|
|
|
ZxObjCurvePressure(const QString& sName,
|
|
|
ZxSubAxisX* pAxisX,
|
|
|
ZxSubAxisY* pAxisY);
|
|
|
~ZxObjCurvePressure(void);
|
|
|
|
|
|
virtual void init(const QString& sName,
|
|
|
ZxSubAxisX* pAxisX,
|
|
|
ZxSubAxisY* pAxisY);
|
|
|
|
|
|
// 封装
|
|
|
virtual void initTools();
|
|
|
|
|
|
virtual void paintWithBrotherMode(QPainter* painter,
|
|
|
QPointF ptOld,
|
|
|
QPointF ptNew);
|
|
|
|
|
|
public:
|
|
|
|
|
|
protected:
|
|
|
// 设置图元对象的属性标志
|
|
|
virtual void initFlags();
|
|
|
|
|
|
// 击中
|
|
|
virtual bool hitTest(const QPointF& pt);
|
|
|
|
|
|
// 具体击中实现的函数,单纯击中,不做选项的改变
|
|
|
// nOption用int是因为Rect类的击中选项不一致
|
|
|
// nOption为负值,表示未击中,此时返回false
|
|
|
virtual bool _runHitTest(const QPointF& pt, int& nOption, int& nSubIndex);
|
|
|
|
|
|
// 击中后,ButtonUp后的处理
|
|
|
// pt1:鼠标Down点,pt2:鼠标Up点
|
|
|
virtual bool runMove(const QPointF& pt1, const QPointF& pt2);
|
|
|
|
|
|
// 新增接口,20210918 为了流量和压力对齐,只支持右移动
|
|
|
// dOffsetX > 0,且是Value而不是Pos
|
|
|
// 20210919 更改支持:左右移动,压力
|
|
|
virtual bool runMoveByV(const double dOffsetX);
|
|
|
|
|
|
public:
|
|
|
|
|
|
virtual void paintBack(QPainter* painter, const ZxPaintParam& param);
|
|
|
virtual void drawSegInfos(QPainter* painter);
|
|
|
virtual void drawPoint(QPainter* painter, QPointF arrPoints[], int nCount, ZxDot& dot);
|
|
|
|
|
|
virtual void onSerialize(ZxSerializer* ser);
|
|
|
virtual void onDeserialize(ZxSerializer* ser);
|
|
|
|
|
|
virtual void fillPtyPano(IxPtyPano* sheet);
|
|
|
|
|
|
protected:
|
|
|
|
|
|
double m_fPosMovingX; //临时不序列化
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|