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.
32 lines
738 B
C++
32 lines
738 B
C++
#pragma once
|
|
|
|
#include "nmObjToolBase.h"
|
|
#include "ZxPlot.h"
|
|
|
|
class NM_PLOT_EXPORT nmObjRegionMarkTool : public nmObjToolBase
|
|
{
|
|
Q_OBJECT
|
|
|
|
public:
|
|
|
|
nmObjRegionMarkTool();
|
|
nmObjRegionMarkTool(ZxPlot* m_pCurPlot);
|
|
|
|
// 鼠标各种响应
|
|
virtual bool onLeftDown(const QPointF& pt) override;
|
|
virtual bool onMouseMove(const QPointF& pt) override;
|
|
virtual bool onLeftUp(const QPointF& pt) override;
|
|
|
|
// 绘制
|
|
virtual void onPaint(QPainter* painter, const ZxPaintParam& param) override;
|
|
|
|
protected:
|
|
|
|
// 根据鼠标当前选择情况确定不同的光标类型
|
|
virtual Qt::CursorShape getCursorBy(const int& nOption, \
|
|
const int& nSubIndex) override;
|
|
|
|
public:
|
|
ZxPlot* m_pCurPlot; // 获取当前画布
|
|
};
|