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.
43 lines
865 B
C++
43 lines
865 B
C++
#pragma once
|
|
|
|
#include <ZxSimpleTool.h>
|
|
|
|
class QPointF;
|
|
class ZxRenderItem;
|
|
|
|
/// 选择工具 (注: 只有选择功能, 没有移动或右键菜单等额外功能)
|
|
/// @see ZxArrowTool
|
|
class I_PLOTBASE_EXPORT ZxSelectTool : public ZxSimpleTool
|
|
{
|
|
Q_OBJECT
|
|
|
|
public:
|
|
|
|
ZxSelectTool(ZxFilterFun filter = 0, \
|
|
bool bLeftSelect = true, \
|
|
bool bRightSelect = true);
|
|
//ZxSelectTool(const ZxSelectTool & c);
|
|
//virtual ZxSelectTool * clone() const;
|
|
|
|
protected:
|
|
|
|
bool onLeftDown(const QPointF& pt);
|
|
bool onLeftUp(const QPointF& pt);
|
|
bool onRightDown(const QPointF& pt);
|
|
// bool onRightUp(const QPointF& pt);
|
|
bool onLeftDoubleClick(const QPointF& pt);
|
|
|
|
virtual bool selectGraphItem(const QPointF& pt);
|
|
|
|
protected:
|
|
|
|
bool m_bLeftSelect;
|
|
bool m_bRightSelect;
|
|
|
|
ZxFilterFun m_funcFilter;
|
|
};
|
|
|
|
|
|
|
|
|