Example #1
0
        public DiagramControl()
        {
            _mainLayer = Layers[0];             // predefined

            _mainLayer.Shapes = new MSet <LLShape> {
                _shapeGroup
            };
            _selAdornerLayer        = AddLayerAbove(_mainLayer, false);
            _selAdornerLayer.Shapes = new MSet <LLShape> {
                _selAdornerGroup
            };
            _dragAdornerLayer        = AddLayerAbove(_selAdornerLayer, false);
            _dragAdornerLayer.Shapes = new MSet <LLShape> {
                _dragAdornerGroup
            };
            _shapeGroup.Transform       = _scrollZoom;
            _selAdornerGroup.Transform  = _scrollZoom;
            _dragAdornerGroup.Transform = _scrollZoom;

            _gestureAnalyzer = new DiagramGestureAnalyzer(this);
            Document         = new DiagramDocument();

            LineStyle = new DiagramDrawStyle {
                LineColor = Color.Black, LineWidth = 2, TextColor = Color.Blue, FillColor = Color.FromArgb(64, Color.Gray)
            };
            LineStyle.Name     = "Default";
            BoxStyle           = (DiagramDrawStyle)LineStyle.Clone();
            BoxStyle.LineColor = Color.DarkGreen;
            MarkerRadius       = 5;
            MarkerType         = MarkerPolygon.Circle;
            FromArrow          = null;
            ToArrow            = Arrowhead.Arrow30deg;
        }
Example #2
0
 public Marker(DiagramDrawStyle style, PointT point, float radius, MarkerPolygon type)
 {
     LL = new LLMarker(style, point, radius, type)
     {
         ZOrder = NextZOrder++
     };
     Style = style;
 }
Example #3
0
		public DiagramControl()
		{
			_mainLayer = Layers[0]; // predefined
			
			_mainLayer.Shapes = new MSet<LLShape> { _shapeGroup };
			_selAdornerLayer = AddLayerAbove(_mainLayer, false);
			_selAdornerLayer.Shapes = new MSet<LLShape> { _selAdornerGroup };
			_dragAdornerLayer = AddLayerAbove(_selAdornerLayer, false);
			_dragAdornerLayer.Shapes = new MSet<LLShape> { _dragAdornerGroup };
			_shapeGroup.Transform = _scrollZoom;
			_selAdornerGroup.Transform = _scrollZoom;
			_dragAdornerGroup.Transform = _scrollZoom;

			_gestureAnalyzer = new DiagramGestureAnalyzer(this);
			Document = new DiagramDocument();
			
			LineStyle = new DiagramDrawStyle { LineColor = Color.Black, LineWidth = 2, TextColor = Color.Blue, FillColor = Color.FromArgb(64, Color.Gray) };
			LineStyle.Name = "Default";
			BoxStyle = (DiagramDrawStyle)LineStyle.Clone();
			BoxStyle.LineColor = Color.DarkGreen;
			MarkerRadius = 5;
			MarkerType = MarkerPolygon.Circle;
			FromArrow = null;
			ToArrow = Arrowhead.Arrow30deg;
		}
Example #4
0
		public Marker(DiagramDrawStyle style, PointT point, float radius, MarkerPolygon type)
		{
			LL = new LLMarker(style, point, radius, type) { ZOrder = NextZOrder++ };
			Style = style;
		}