添加项目文件。
This commit is contained in:
66
Mstn.Toolkit/External/DimensionData.cs
vendored
Normal file
66
Mstn.Toolkit/External/DimensionData.cs
vendored
Normal file
@@ -0,0 +1,66 @@
|
||||
using Bentley.DgnPlatformNET;
|
||||
using Bentley.DgnPlatformNET.Elements;
|
||||
using Bentley.GeometryNET;
|
||||
|
||||
namespace Mstn.Toolkit.External
|
||||
{
|
||||
class DimensionData : DimensionCreateData
|
||||
{
|
||||
private DimensionStyle m_dimStyle;
|
||||
private DgnTextStyle m_textStyle;
|
||||
private Symbology m_symbology;
|
||||
private LevelId m_levelId;
|
||||
private DirectionFormatter m_directionFormatter;
|
||||
|
||||
public DimensionData(DimensionStyle dimStyle, DgnTextStyle textStyle, Symbology symb, LevelId levelId, DirectionFormatter formatter)
|
||||
{
|
||||
m_dimStyle = dimStyle;
|
||||
m_textStyle = textStyle;
|
||||
m_symbology = symb;
|
||||
m_levelId = levelId;
|
||||
m_directionFormatter = formatter;
|
||||
}
|
||||
|
||||
public override DimensionStyle GetDimensionStyle()
|
||||
{
|
||||
return m_dimStyle;
|
||||
}
|
||||
|
||||
public override DgnTextStyle GetTextStyle()
|
||||
{
|
||||
return m_textStyle;
|
||||
}
|
||||
|
||||
public override Symbology GetSymbology()
|
||||
{
|
||||
return m_symbology;
|
||||
}
|
||||
|
||||
public override LevelId GetLevelId()
|
||||
{
|
||||
return m_levelId;
|
||||
}
|
||||
|
||||
public override int GetViewNumber()
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
//此函数返回的旋转矩阵与GetViewRotation返回的旋转矩阵共同定义了尺寸标注元素的方向
|
||||
public override DMatrix3d GetDimensionRotation()
|
||||
{
|
||||
return DMatrix3d.Identity;
|
||||
}
|
||||
|
||||
public override DMatrix3d GetViewRotation()
|
||||
{
|
||||
return DMatrix3d.Identity;
|
||||
}
|
||||
|
||||
//用于从数字方向值构造字符串。
|
||||
public override DirectionFormatter GetDirectionFormatter()
|
||||
{
|
||||
return m_directionFormatter;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user