示例#1
0
 /// <summary>
 /// Draws <paramref name="callout"/> with the specified <paramref name="text"/> at <paramref name="location"/> with the callout
 /// line originating from <paramref name="anchor"/>.
 /// </summary>
 private static void DrawAngleCallout(AngleCalloutGraphic callout, string text, PointF anchor, PointF location)
 {
     callout.Text         = text;
     callout.Visible      = !string.IsNullOrEmpty(text);
     callout.AnchorPoint  = anchor;
     callout.TextLocation = location;
 }
示例#2
0
 private void OnCloneComplete()
 {
     _angleCalloutGraphic1 = (AngleCalloutGraphic)CollectionUtils.SelectFirst(base.Graphics, g => g.Name == "callout1");
     _angleCalloutGraphic2 = (AngleCalloutGraphic)CollectionUtils.SelectFirst(base.Graphics, g => g.Name == "callout2");
     _extenderLine1        = (ILineSegmentGraphic)CollectionUtils.SelectFirst(base.Graphics, g => g.Name == "extender1");
     _extenderLine2        = (ILineSegmentGraphic)CollectionUtils.SelectFirst(base.Graphics, g => g.Name == "extender2");
     _riserLine1           = (ILineSegmentGraphic)CollectionUtils.SelectFirst(base.Graphics, g => g.Name == "riser1");
     _riserLine2           = (ILineSegmentGraphic)CollectionUtils.SelectFirst(base.Graphics, g => g.Name == "riser2");
 }
示例#3
0
			public ShowAnglesToolGraphic()
			{
				base.Graphics.Add(_angleCalloutGraphic1 = new AngleCalloutGraphic());
				base.Graphics.Add(_angleCalloutGraphic2 = new AngleCalloutGraphic());
				base.Graphics.Add(_extenderLine1 = new LinePrimitive());
				base.Graphics.Add(_extenderLine2 = new LinePrimitive());
				base.Graphics.Add(_riserLine1 = new LinePrimitive());
				base.Graphics.Add(_riserLine2 = new LinePrimitive());

				_angleCalloutGraphic1.ShowArrowhead = _angleCalloutGraphic2.ShowArrowhead = false;
				_angleCalloutGraphic1.LineStyle = _angleCalloutGraphic2.LineStyle = LineStyle.Dash;
				_angleCalloutGraphic1.Name = "callout1";
				_angleCalloutGraphic2.Name = "callout2";
				_extenderLine1.Name = "extender1";
				_extenderLine2.Name = "extender2";
				_riserLine1.Name = "riser1";
				_riserLine2.Name = "riser2";

				_endPoints = new PointsList(new PointF[] {PointF.Empty, PointF.Empty, PointF.Empty, PointF.Empty}, this);

				this.Color = Color.Coral;
				this.LineStyle = LineStyle.Dot;
			}
示例#4
0
            public ShowAnglesToolGraphic()
            {
                base.Graphics.Add(_angleCalloutGraphic1 = new AngleCalloutGraphic());
                base.Graphics.Add(_angleCalloutGraphic2 = new AngleCalloutGraphic());
                base.Graphics.Add(_extenderLine1        = new LinePrimitive());
                base.Graphics.Add(_extenderLine2        = new LinePrimitive());
                base.Graphics.Add(_riserLine1           = new LinePrimitive());
                base.Graphics.Add(_riserLine2           = new LinePrimitive());

                _angleCalloutGraphic1.ShowArrowhead = _angleCalloutGraphic2.ShowArrowhead = false;
                _angleCalloutGraphic1.LineStyle     = _angleCalloutGraphic2.LineStyle = LineStyle.Dash;
                _angleCalloutGraphic1.Name          = "callout1";
                _angleCalloutGraphic2.Name          = "callout2";
                _extenderLine1.Name = "extender1";
                _extenderLine2.Name = "extender2";
                _riserLine1.Name    = "riser1";
                _riserLine2.Name    = "riser2";

                _endPoints = new PointsList(new PointF[] { PointF.Empty, PointF.Empty, PointF.Empty, PointF.Empty }, this);

                this.Color     = Color.Coral;
                this.LineStyle = LineStyle.Dot;
            }
示例#5
0
			private void OnCloneComplete()
			{
				_angleCalloutGraphic1 = (AngleCalloutGraphic) CollectionUtils.SelectFirst(base.Graphics, g => g.Name == "callout1");
				_angleCalloutGraphic2 = (AngleCalloutGraphic) CollectionUtils.SelectFirst(base.Graphics, g => g.Name == "callout2");
				_extenderLine1 = (ILineSegmentGraphic) CollectionUtils.SelectFirst(base.Graphics, g => g.Name == "extender1");
				_extenderLine2 = (ILineSegmentGraphic) CollectionUtils.SelectFirst(base.Graphics, g => g.Name == "extender2");
				_riserLine1 = (ILineSegmentGraphic) CollectionUtils.SelectFirst(base.Graphics, g => g.Name == "riser1");
				_riserLine2 = (ILineSegmentGraphic) CollectionUtils.SelectFirst(base.Graphics, g => g.Name == "riser2");
			}
示例#6
0
			/// <summary>
			/// Cloning constructor.
			/// </summary>
			/// <param name="source">The source object from which to clone.</param>
			/// <param name="context">The cloning context object.</param>
			protected AngleCalloutGraphic(AngleCalloutGraphic source, ICloningContext context) : base(source, context)
			{
				context.CloneFields(source, this);
			}
示例#7
0
			/// <summary>
			/// Draws <paramref name="callout"/> with the specified <paramref name="text"/> at <paramref name="location"/> with the callout
			/// line originating from <paramref name="anchor"/>.
			/// </summary>
			private static void DrawAngleCallout(AngleCalloutGraphic callout, string text, PointF anchor, PointF location)
			{
				callout.Text = text;
				callout.Visible = !string.IsNullOrEmpty(text);
				callout.AnchorPoint = anchor;
				callout.TextLocation = location;
			}
示例#8
0
 /// <summary>
 /// Cloning constructor.
 /// </summary>
 /// <param name="source">The source object from which to clone.</param>
 /// <param name="context">The cloning context object.</param>
 protected AngleCalloutGraphic(AngleCalloutGraphic source, ICloningContext context) : base(source, context)
 {
     context.CloneFields(source, this);
 }