80 lines
1.8 KiB
C++
80 lines
1.8 KiB
C++
//-------------------------------------------------------------------------------------------------------+
|
|
// Copyright (C), 1998-2007, Beijing Tangent Software Co. Ltd.
|
|
// = FileName : TDbGrip.h
|
|
// = Version : ver2.0
|
|
// = Author : xlc
|
|
// = CreateDate : 2002-09-09
|
|
// = Description: 夹点对象类的声明
|
|
// = Maintainers:
|
|
//
|
|
//-------------------------------------------------------------------------------------------------------+
|
|
#ifndef _TDBGRIP_H_
|
|
#define _TDBGRIP_H_
|
|
|
|
#if ADS > 15
|
|
|
|
#ifndef _TDBGRIPDIM_H_
|
|
#include "TDbGripDim.h"
|
|
#endif
|
|
|
|
#ifndef _TSPTABLE_H_
|
|
#include "TSPTable.h"
|
|
#endif
|
|
|
|
#include "dbGrip.h"
|
|
class TEntityBase;
|
|
|
|
class GEOAPI TDbGrip
|
|
{
|
|
public:
|
|
TDbGrip(TEntityBase *pEnt,const AcGePoint3d&pt,int type = 0);
|
|
virtual ~TDbGrip();
|
|
|
|
bool operator>(const TDbGrip&) const;
|
|
bool operator<(const TDbGrip&) const;
|
|
|
|
|
|
int Index() const;
|
|
void SetIndex(long id);
|
|
|
|
const AcGePoint3d Position() const;
|
|
|
|
TEntityBase* Owner() const;
|
|
|
|
CString ToolTip() const;
|
|
|
|
TDbGripDim* GetDim(long i) const;
|
|
|
|
int FindDim(TDbGripDim* pDim) const;
|
|
int GetDimNum() const;
|
|
|
|
AcDbGripData* CreateGripData() const;
|
|
|
|
void GetHoverDimension(const AcDbObjectId &entId,double dimScale,AcDbDimDataPtrArray& dimData) const;
|
|
void GetHotDimension(const AcDbObjectId &entId,double dimScale,AcDbDimDataPtrArray& dimData) const;
|
|
|
|
bool WorldDraw(AcGiWorldDraw* pWd,AcDbGripOperations::DrawType type,double dGripSize) const;
|
|
void ViewportDraw(AcGiViewportDraw* pVd,AcDbGripOperations::DrawType type,int gripSize) const;
|
|
|
|
//更新关联动态标注
|
|
void UpdateDimEnt();
|
|
|
|
void AppendDim(TDbGripDim*pDim);
|
|
|
|
protected:
|
|
int m_iId;
|
|
|
|
AcGePoint3d m_ptGrip;//位置
|
|
|
|
unsigned int m_bitFlags;//标志
|
|
|
|
TSPTable<TDbGripDim> m_allDims;
|
|
|
|
int m_iType;//夹点类型,>0是自定义夹点,<0,JIG夹点
|
|
|
|
TEntityBase* m_pGripEntity;//所属实体
|
|
};
|
|
#endif
|
|
|
|
#endif
|