Пример #1
0
        private void OnCloneComplete()
        {
            IList <IGraphic> lines = CollectionUtils.Select(base.Graphics,
                                                            delegate(IGraphic test) { return(test is InvariantLinePrimitive); });

            _left  = lines[0] as InvariantLinePrimitive;
            _right = lines[1] as InvariantLinePrimitive;

            Initialize();
        }
Пример #2
0
		private void OnCloneComplete()
		{
			IList<IGraphic> lines = CollectionUtils.Select(base.Graphics,
			                                               delegate(IGraphic test) { return test is InvariantLinePrimitive; });

			_left = lines[0] as InvariantLinePrimitive;
			_right = lines[1] as InvariantLinePrimitive;

			Initialize();
		}
Пример #3
0
        private void Initialize()
        {
            if (_left == null)
            {
                base.Graphics.Add(_left    = new InvariantLinePrimitive());
                _left.InvariantBottomRight = PointF.Empty;
            }

            if (_right == null)
            {
                base.Graphics.Add(_right    = new InvariantLinePrimitive());
                _right.InvariantBottomRight = PointF.Empty;
            }

            RecomputeArrow();
        }
Пример #4
0
		private void Initialize()
		{
			if (_left == null)
			{
				base.Graphics.Add(_left = new InvariantLinePrimitive());
				_left.InvariantBottomRight = PointF.Empty;
			}

			if (_right == null)
			{
				base.Graphics.Add(_right = new InvariantLinePrimitive());
				_right.InvariantBottomRight = PointF.Empty;
			}

			RecomputeArrow();
		}
Пример #5
0
		/// <summary>
		/// Draws a <see cref="InvariantLinePrimitive"/>.  Must be overridden and implemented.
		/// </summary>
		protected abstract void DrawInvariantLinePrimitive(InvariantLinePrimitive line);
Пример #6
0
		/// <summary>
		/// Draws a <see cref="InvariantLinePrimitive"/>.
		/// </summary>
		protected override void DrawInvariantLinePrimitive(InvariantLinePrimitive line)
		{
			InternalDrawLinePrimitive(line);
		}
Пример #7
0
		/// <summary>
		/// Draws a <see cref="InvariantLinePrimitive"/>.
		/// </summary>
		protected override void DrawInvariantLinePrimitive(InvariantLinePrimitive line)
		{
			DrawLinePrimitive(Surface.FinalBuffer, _pen, line, Dpi);
		}
        private void Initialize()
        {
            if (_left == null)
            {
                Graphics.Add(_left = new InvariantLinePrimitive());
                _left.InvariantBottomRight = PointF.Empty;
            }

            if (_right == null)
            {
                Graphics.Add(_right = new InvariantLinePrimitive());
                _right.InvariantBottomRight = PointF.Empty;
            }

            if (_top == null)
            {
                Graphics.Add(_top = new InvariantLinePrimitive());
                _top.InvariantBottomRight = PointF.Empty;
            }

            if (_bottom == null)
            {
                Graphics.Add(_bottom = new InvariantLinePrimitive());
                _bottom.InvariantBottomRight = PointF.Empty;
            }

            RecomputeCrosshair();
        }