#pragma once #include 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; };