Show / Hide Table of Contents

Class Dimension

The dimension object represents a dimensioning in a model and is a GeoObject. To use a dimension object you must at least set the properties DimensionStyle, DimLineRef, DimLineDirection, and add two points with the AddPoint(GeoPoint) method. Example:

// assuming "project" is a reference to a Project
Dimension d = Dimension.Construct();
d.DimensionStyle = project.DimensionStyleList.Current;
d.DimLineRef = new GeoPoint(200, 200, 0);
d.DimLineDirection = GeoVector.XAxis;
d.AddPoint(new GeoPoint(100, 100, 0));
d.AddPoint(new GeoPoint(200, 100, 0));
d.AddPoint(new GeoPoint(300, 100, 0));
project.GetActiveModel().Add(d);
Inheritance
System.Object
IGeoObjectImpl
Dimension
Implements
IGeoObject
ILayer
IStyle
IOctTreeInsertable
System.IComparable
IFeedBack
System.ICloneable
System.Runtime.Serialization.ISerializable
IDimensionStyle
IGeoObjectOwner
Inherited Members
IGeoObjectImpl.isChanging
IGeoObjectImpl.MakeChange(IGeoObjectImpl, String)
IGeoObjectImpl.SetSerializationValue(String, Object)
IGeoObjectImpl.UniqueId
IGeoObjectImpl.WillChangeEvent
IGeoObjectImpl.DidChangeEvent
IGeoObjectImpl.FeedBackChangedEvent
IGeoObjectImpl.FireWillChange(GeoObjectChange)
IGeoObjectImpl.FireDidChange(GeoObjectChange)
IGeoObjectImpl.ModifyInverse(ModOp)
IGeoObjectImpl.HasChildren()
IGeoObjectImpl.NumChildren
IGeoObjectImpl.Child(Int32)
IGeoObjectImpl.Owner
IGeoObjectImpl.AttributeChanged(INamedAttribute)
IGeoObjectImpl.CopyAttributes(IGeoObject)
IGeoObjectImpl.Attributes
IGeoObjectImpl.CustomAttributeKeys
IGeoObjectImpl.SetNamedAttribute(String, INamedAttribute)
IGeoObjectImpl.GetNamedAttribute(String)
IGeoObjectImpl.UpdateAttributes(IAttributeListContainer)
IGeoObjectImpl.UserData
IGeoObjectImpl.isModifyingWithMouse
IGeoObjectImpl.ModifyWithMouse(Object, String, Boolean)
IGeoObjectImpl.FindSnapPoint(SnapPointFinder)
IGeoObjectImpl.HasValidData()
IGeoObjectImpl.Description
IGeoObjectImpl.PaintTo3DList(IPaintTo3D, ICategorizedDislayLists)
IGeoObjectImpl.OwnedItems
IGeoObjectImpl.IsVisible
IGeoObjectImpl.PropagateAttributes(Layer, ColorDef)
IGeoObjectImpl.Actuator
IGeoObjectImpl.SetColorDef(ColorDef, ColorDef)
IGeoObjectImpl.Layer
IGeoObjectImpl.Style
IGeoObjectImpl.StyleIsValid
IGeoObjectImpl.GetExtent(IGeoObject, Projection, Boolean)
IGeoObjectImpl.IsOwnedByBlockRef(IGeoObject)
IGeoObjectImpl.ChangingUserData(IGeoObject, String, Object)
IGeoObjectImpl.ChangingUserData(IGeoObject, String, Object, Boolean)
IGeoObjectImpl.ICloneable.Clone()
IGeoObjectImpl.IComparable.CompareTo(Object)
IGeoObjectImpl.GetAdditionalContextMenueEvent
IGeoObjectImpl.IFeedBack.GetExtent()
IGeoObjectImpl.JsonGetObjectData(IJsonWriteData)
IGeoObjectImpl.JsonSetObjectData(IJsonReadData)
IGeoObjectImpl.JsonSerializationDone()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: CADability.GeoObject
Assembly: CADability.dll
Syntax
[Serializable]
public class Dimension : IGeoObjectImpl, IGeoObject, ILayer, IStyle, IOctTreeInsertable, IComparable, IFeedBack, ICloneable, ISerializable, IDimensionStyle, IGeoObjectOwner

Constructors

| Improve this Doc View Source

Dimension()

Declaration
protected Dimension()
| Improve this Doc View Source

Dimension(SerializationInfo, StreamingContext)

Constructor required by deserialization

Declaration
protected Dimension(SerializationInfo info, StreamingContext context)
Parameters
Type Name Description
System.Runtime.Serialization.SerializationInfo info

SerializationInfo

System.Runtime.Serialization.StreamingContext context

StreamingContext

Fields

| Improve this Doc View Source

Constructor

Declaration
public static Dimension.ConstructionDelegate Constructor
Field Value
Type Description
Dimension.ConstructionDelegate
| Improve this Doc View Source

OnPaintTo3D

Declaration
public static Dimension.PaintTo3DDelegate OnPaintTo3D
Field Value
Type Description
Dimension.PaintTo3DDelegate

Properties

| Improve this Doc View Source

DimensionStyle

Declaration
public DimensionStyle DimensionStyle { get; set; }
Property Value
Type Description
DimensionStyle
| Improve this Doc View Source

DimLineDirection

Declaration
public GeoVector DimLineDirection { get; set; }
Property Value
Type Description
GeoVector
| Improve this Doc View Source

DimLineRef

Declaration
public GeoPoint DimLineRef { get; set; }
Property Value
Type Description
GeoPoint
| Improve this Doc View Source

DimType

Declaration
public Dimension.EDimType DimType { get; set; }
Property Value
Type Description
Dimension.EDimType
| Improve this Doc View Source

DistToEnd

Declaration
public Angle DistToEnd { get; set; }
Property Value
Type Description
Angle
| Improve this Doc View Source

DistToStart

Declaration
public double DistToStart { get; set; }
Property Value
Type Description
System.Double
| Improve this Doc View Source

EndAngle

Declaration
public Angle EndAngle { get; set; }
Property Value
Type Description
Angle
| Improve this Doc View Source

ExtLineAngle

Declaration
public Angle ExtLineAngle { get; set; }
Property Value
Type Description
Angle
| Improve this Doc View Source

Normal

Declaration
public GeoVector Normal { get; set; }
Property Value
Type Description
GeoVector
| Improve this Doc View Source

Plane

Declaration
public Plane Plane { get; }
Property Value
Type Description
Plane
| Improve this Doc View Source

PointCount

Declaration
public int PointCount { get; }
Property Value
Type Description
System.Int32
| Improve this Doc View Source

PreferredStyle

Declaration
public override Style.EDefaultFor PreferredStyle { get; }
Property Value
Type Description
Style.EDefaultFor
Overrides
IGeoObjectImpl.PreferredStyle
| Improve this Doc View Source

Radius

Declaration
public double Radius { get; set; }
Property Value
Type Description
System.Double
| Improve this Doc View Source

StartAngle

Declaration
public Angle StartAngle { get; set; }
Property Value
Type Description
Angle

Methods

| Improve this Doc View Source

Add(IGeoObject)

Declaration
public void Add(IGeoObject toAdd)
Parameters
Type Name Description
IGeoObject toAdd
| Improve this Doc View Source

AddPoint(GeoPoint)

Declaration
public void AddPoint(GeoPoint p)
Parameters
Type Name Description
GeoPoint p
| Improve this Doc View Source

Clone()

Overrides Clone()

Declaration
public override IGeoObject Clone()
Returns
Type Description
IGeoObject
Overrides
IGeoObjectImpl.Clone()
| Improve this Doc View Source

Construct()

Declaration
public static Dimension Construct()
Returns
Type Description
Dimension
| Improve this Doc View Source

CopyGeometry(IGeoObject)

Overrides CopyGeometry(IGeoObject)

Declaration
public override void CopyGeometry(IGeoObject ToCopyFrom)
Parameters
Type Name Description
IGeoObject ToCopyFrom
Overrides
IGeoObjectImpl.CopyGeometry(IGeoObject)
| Improve this Doc View Source

Decompose()

Overrides Decompose()

Declaration
public override GeoObjectList Decompose()
Returns
Type Description
GeoObjectList
Overrides
IGeoObjectImpl.Decompose()
| Improve this Doc View Source

GetAttributeProperties(IFrame)

Overrides GetAttributeProperties(IFrame)

Declaration
public override IShowProperty[] GetAttributeProperties(IFrame Frame)
Parameters
Type Name Description
IFrame Frame
Returns
Type Description
IShowProperty[]
Overrides
IGeoObjectImpl.GetAttributeProperties(IFrame)
| Improve this Doc View Source

GetBoundingCube()

Overrides GetBoundingCube()

Declaration
public override BoundingCube GetBoundingCube()
Returns
Type Description
BoundingCube
Overrides
IGeoObjectImpl.GetBoundingCube()
| Improve this Doc View Source

GetDimText(Int32)

Declaration
public string GetDimText(int index)
Parameters
Type Name Description
System.Int32 index
Returns
Type Description
System.String
| Improve this Doc View Source

GetExtent(Projection, ExtentPrecision)

Overrides GetExtent(Projection, ExtentPrecision)

Declaration
public override BoundingRect GetExtent(Projection projection, ExtentPrecision extentPrecision)
Parameters
Type Name Description
Projection projection
ExtentPrecision extentPrecision
Returns
Type Description
BoundingRect
Overrides
IGeoObjectImpl.GetExtent(Projection, ExtentPrecision)
| Improve this Doc View Source

GetExtent(Double)

Overrides GetExtent(Double)

Declaration
public override BoundingCube GetExtent(double precision)
Parameters
Type Name Description
System.Double precision
Returns
Type Description
BoundingCube
Overrides
IGeoObjectImpl.GetExtent(Double)
| Improve this Doc View Source

GetHitPosition(Projection, GeoPoint2D, out Int32)

Declaration
public Dimension.HitPosition GetHitPosition(Projection p, GeoPoint2D projectedPoint, out int Index)
Parameters
Type Name Description
Projection p
GeoPoint2D projectedPoint
System.Int32 Index
Returns
Type Description
Dimension.HitPosition
| Improve this Doc View Source

GetObjectData(SerializationInfo, StreamingContext)

Implements System.Runtime.Serialization.ISerializable.GetObjectData(System.Runtime.Serialization.SerializationInfo, System.Runtime.Serialization.StreamingContext)

Declaration
public void GetObjectData(SerializationInfo info, StreamingContext context)
Parameters
Type Name Description
System.Runtime.Serialization.SerializationInfo info

The System.Runtime.Serialization.SerializationInfo to populate with data.

System.Runtime.Serialization.StreamingContext context

The destination (System.Runtime.Serialization.StreamingContext) for this serialization.

| Improve this Doc View Source

GetPoint(Int32)

Declaration
public GeoPoint GetPoint(int Index)
Parameters
Type Name Description
System.Int32 Index
Returns
Type Description
GeoPoint
| Improve this Doc View Source

GetPostfix(Int32)

Declaration
public string GetPostfix(int index)
Parameters
Type Name Description
System.Int32 index
Returns
Type Description
System.String
| Improve this Doc View Source

GetPostfixAlt(Int32)

Declaration
public string GetPostfixAlt(int index)
Parameters
Type Name Description
System.Int32 index
Returns
Type Description
System.String
| Improve this Doc View Source

GetPrefix(Int32)

Declaration
public string GetPrefix(int index)
Parameters
Type Name Description
System.Int32 index
Returns
Type Description
System.String
| Improve this Doc View Source

GetQuadTreeItem(Projection, ExtentPrecision)

Overrides GetQuadTreeItem(Projection, ExtentPrecision)

Declaration
public override IQuadTreeInsertableZ GetQuadTreeItem(Projection projection, ExtentPrecision extentPrecision)
Parameters
Type Name Description
Projection projection
ExtentPrecision extentPrecision
Returns
Type Description
IQuadTreeInsertableZ
Overrides
IGeoObjectImpl.GetQuadTreeItem(Projection, ExtentPrecision)
| Improve this Doc View Source

GetShowProperties(IFrame)

Overrides GetShowProperties(IFrame)

Declaration
public override IShowProperty GetShowProperties(IFrame Frame)
Parameters
Type Name Description
IFrame Frame
Returns
Type Description
IShowProperty
Overrides
IGeoObjectImpl.GetShowProperties(IFrame)
| Improve this Doc View Source

GetTextPos(Int32)

Declaration
public double GetTextPos(int index)
Parameters
Type Name Description
System.Int32 index
Returns
Type Description
System.Double
| Improve this Doc View Source

GetTolMinusText(Int32)

Declaration
public string GetTolMinusText(int index)
Parameters
Type Name Description
System.Int32 index
Returns
Type Description
System.String
| Improve this Doc View Source

GetTolPlusText(Int32)

Declaration
public string GetTolPlusText(int index)
Parameters
Type Name Description
System.Int32 index
Returns
Type Description
System.String
| Improve this Doc View Source

HitTest(ref BoundingCube, Double)

Overrides HitTest(ref BoundingCube, Double)

Declaration
public override bool HitTest(ref BoundingCube cube, double precision)
Parameters
Type Name Description
BoundingCube cube
System.Double precision
Returns
Type Description
System.Boolean
Overrides
IGeoObjectImpl.HitTest(ref BoundingCube, Double)
| Improve this Doc View Source

HitTest(Projection, BoundingRect, Boolean)

Overrides HitTest(Projection, BoundingRect, Boolean)

Declaration
public override bool HitTest(Projection projection, BoundingRect rect, bool onlyInside)
Parameters
Type Name Description
Projection projection
BoundingRect rect
System.Boolean onlyInside
Returns
Type Description
System.Boolean
Overrides
IGeoObjectImpl.HitTest(Projection, BoundingRect, Boolean)
| Improve this Doc View Source

HitTest(Projection.PickArea, Boolean)

Overrides HitTest(Projection.PickArea, Boolean)

Declaration
public override bool HitTest(Projection.PickArea area, bool onlyInside)
Parameters
Type Name Description
Projection.PickArea area
System.Boolean onlyInside
Returns
Type Description
System.Boolean
Overrides
IGeoObjectImpl.HitTest(Projection.PickArea, Boolean)
| Improve this Doc View Source

IsAttributeUsed(Object)

Overrides IsAttributeUsed(Object)

Declaration
public override bool IsAttributeUsed(object Attribute)
Parameters
Type Name Description
System.Object Attribute
Returns
Type Description
System.Boolean
Overrides
IGeoObjectImpl.IsAttributeUsed(Object)
| Improve this Doc View Source

Modify(ModOp)

Overrides Modify(ModOp)

Declaration
public override void Modify(ModOp m)
Parameters
Type Name Description
ModOp m
Overrides
IGeoObjectImpl.Modify(ModOp)
| Improve this Doc View Source

PaintTo3D(IPaintTo3D)

Overrides PaintTo3D(IPaintTo3D)

Declaration
public override void PaintTo3D(IPaintTo3D paintTo3D)
Parameters
Type Name Description
IPaintTo3D paintTo3D
Overrides
IGeoObjectImpl.PaintTo3D(IPaintTo3D)
| Improve this Doc View Source

Position(GeoPoint, GeoVector, Double)

Overrides Position(GeoPoint, GeoVector, Double)

Declaration
public override double Position(GeoPoint fromHere, GeoVector direction, double precision)
Parameters
Type Name Description
GeoPoint fromHere
GeoVector direction
System.Double precision
Returns
Type Description
System.Double
Overrides
IGeoObjectImpl.Position(GeoPoint, GeoVector, Double)
| Improve this Doc View Source

PrePaintTo3D(IPaintTo3D)

Overrides PrePaintTo3D(IPaintTo3D)

Declaration
public override void PrePaintTo3D(IPaintTo3D paintTo3D)
Parameters
Type Name Description
IPaintTo3D paintTo3D
Overrides
IGeoObjectImpl.PrePaintTo3D(IPaintTo3D)
| Improve this Doc View Source

PrepareDisplayList(Double)

Overrides PrepareDisplayList(Double)

Declaration
public override void PrepareDisplayList(double precision)
Parameters
Type Name Description
System.Double precision
Overrides
IGeoObjectImpl.PrepareDisplayList(Double)
| Improve this Doc View Source

Recalc()

Call this, if the DimensionStyle used by this Dimension was modified.

Declaration
public void Recalc()
| Improve this Doc View Source

Recalc(Projection, GeoObjectList)

Declaration
public void Recalc(Projection p, GeoObjectList list)
Parameters
Type Name Description
Projection p
GeoObjectList list
| Improve this Doc View Source

Remove(IGeoObject)

Declaration
public void Remove(IGeoObject toRemove)
Parameters
Type Name Description
IGeoObject toRemove
| Improve this Doc View Source

RemovePoint(Int32)

Declaration
public void RemovePoint(int Index)
Parameters
Type Name Description
System.Int32 Index
| Improve this Doc View Source

SetDimText(Int32, String)

Declaration
public void SetDimText(int index, string text)
Parameters
Type Name Description
System.Int32 index
System.String text
| Improve this Doc View Source

SetPoint(Int32, GeoPoint)

Declaration
public void SetPoint(int Index, GeoPoint p)
Parameters
Type Name Description
System.Int32 Index
GeoPoint p
| Improve this Doc View Source

SetPostfix(Int32, String)

Declaration
public void SetPostfix(int index, string txt)
Parameters
Type Name Description
System.Int32 index
System.String txt
| Improve this Doc View Source

SetPostfixAlt(Int32, String)

Declaration
public void SetPostfixAlt(int index, string txt)
Parameters
Type Name Description
System.Int32 index
System.String txt
| Improve this Doc View Source

SetPrefix(Int32, String)

Declaration
public void SetPrefix(int index, string txt)
Parameters
Type Name Description
System.Int32 index
System.String txt
| Improve this Doc View Source

SetTextPos(Int32, Double)

Declaration
public void SetTextPos(int index, double val)
Parameters
Type Name Description
System.Int32 index
System.Double val
| Improve this Doc View Source

SetTolMinusText(Int32, String)

Declaration
public void SetTolMinusText(int index, string txt)
Parameters
Type Name Description
System.Int32 index
System.String txt
| Improve this Doc View Source

SetTolPlusText(Int32, String)

Declaration
public void SetTolPlusText(int index, string txt)
Parameters
Type Name Description
System.Int32 index
System.String txt
| Improve this Doc View Source

SortPoints()

Call this after a point to a dimension of type EDimType.DimCoord or EDimType.DimPoints has been added or changed, to rorder the list of points

Declaration
public void SortPoints()

Implements

IGeoObject
ILayer
IStyle
IOctTreeInsertable
System.IComparable
IFeedBack
System.ICloneable
System.Runtime.Serialization.ISerializable
IDimensionStyle
IGeoObjectOwner
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX