Beispiel #1
0
        /// <summary>
        /// Form a ReferencePlane from a line in the Active view.  The cut vector is the Z Axis.
        /// </summary>
        /// <param name="line">The line where the bubble wil be located at the start</param>
        /// <returns></returns>
        public static ReferencePlane ByLine( Line line )
        {
            if (line == null)
            {
                throw new ArgumentNullException("line");
            }

            var start = line.StartPoint.ToXyz();
            var end = line.EndPoint.ToXyz();
            var norm = (end - start).GetPerpendicular();

            return new ReferencePlane(  start, 
                                        end,
                                        norm, 
                                        Document.ActiveView );
        }