Beispiel #1
0
        public RelationshipRenderer(NavigatorView parentNavigatorView, IRelationshipProxy relationshipProxy)
        {
            Relationship        = relationshipProxy;
            ParentNavigatorView = parentNavigatorView;

            this.Loaded += new RoutedEventHandler(RelationshipRenderer_Loaded);
        }
        public RelationshipRenderer(NavigatorView parentNavigatorView, IRelationshipProxy relationshipProxy)
        {
            Relationship = relationshipProxy;
            ParentNavigatorView = parentNavigatorView;

            this.Loaded += new RoutedEventHandler(RelationshipRenderer_Loaded);
        }
Beispiel #3
0
        public NodeRenderer(NavigatorView parentNavigatorView, INodeProxy nodeProxy, ThemeManager themeManager, string skinName)
            : this()
        {
            Node = nodeProxy;
            ParentNavigatorView   = parentNavigatorView;
            ThemeManagementObject = themeManager;

            SkinName = skinName;
            Skin     = ThemeManagementObject.GetSkin(Node.NodeType, SkinName);

            this.Loaded += new RoutedEventHandler(OnLoaded);

            this.MouseLeftButtonDown += new MouseButtonEventHandler(OnMouseLeftButtonDown);
            this.MouseLeftButtonUp   += new MouseButtonEventHandler(OnMouseLeftButtonUp);
            this.MouseMove           += new MouseEventHandler(OnMouseMove);
        }
Beispiel #4
0
        public ImprovedArrow(NavigatorView parentNavigatorView, IRelationshipProxy relationship)
            : base()
        {
            Relationship = relationship;
            ParentNavigatorView = parentNavigatorView;
            
            this.SetValue(Canvas.ZIndexProperty, -1);

            DropShadowEffect selectionEffect = new DropShadowEffect();
            selectionEffect.BlurRadius = 0;
            selectionEffect.ShadowDepth = 0;
            selectionEffect.Color = Colors.Red;
            selectionEffect.Direction = 0;
            this.Effect = selectionEffect;

            _arrowBody = new LineSegment();

            _arrowFigure = new PathFigure();
            _arrowFigure.Segments.Add(_arrowBody);

            _arrow = new PathGeometry();
            _arrow.Figures.Add(_arrowFigure);

            _arrowPath = new Path();
            _arrowPath.Stroke = new SolidColorBrush(Color.FromArgb(255, 0, 0, 0));
            _arrowPath.StrokeEndLineCap = PenLineCap.Triangle;
            _arrowPath.StrokeThickness = 1.25;
            _arrowPath.Data = _arrow;

            _arrowHead = new Line();
            _arrowHead.StrokeEndLineCap = PenLineCap.Triangle;
            _arrowHead.StrokeThickness = 8;
            _arrowHead.Stroke = new SolidColorBrush(Colors.Black);

            this.Children.Add(_arrowHead);
            this.Children.Add(_arrowPath);

            _toSelectionRect = new Rectangle();
            _toSelectionRect.Width = 6;
            _toSelectionRect.Height = 6;
            _toSelectionRect.Stroke = new SolidColorBrush(Colors.Black);
            _toSelectionRect.StrokeThickness = 1;
            _toSelectionRect.Visibility = Visibility.Collapsed;
            _toSelectionRect.Fill = new SolidColorBrush(Colors.White);
            _toSelectionRect.Opacity = 0.7;
            _toSelectionRect.MouseLeftButtonDown += new MouseButtonEventHandler(_toSelectionRect_MouseLeftButtonDown);
            _toSelectionRect.MouseLeftButtonUp += new MouseButtonEventHandler(_toSelectionRect_MouseLeftButtonUp);

            _fromSelectionRect = new Rectangle();
            _fromSelectionRect.Width = 6;
            _fromSelectionRect.Height = 6;
            _fromSelectionRect.Stroke = new SolidColorBrush(Colors.Black);
            _fromSelectionRect.StrokeThickness = 1;
            _fromSelectionRect.Visibility = Visibility.Collapsed;
            _fromSelectionRect.Fill = new SolidColorBrush(Colors.White);
            _fromSelectionRect.Opacity = 0.7;
            _fromSelectionRect.MouseLeftButtonDown += new MouseButtonEventHandler(_fromSelectionRect_MouseLeftButtonDown);
            _fromSelectionRect.MouseLeftButtonUp += new MouseButtonEventHandler(_fromSelectionRect_MouseLeftButtonUp);

            this.Children.Add(_toSelectionRect);
            this.Children.Add(_fromSelectionRect);

            this.Loaded += new RoutedEventHandler(OnLoaded);
        }
Beispiel #5
0
 public UpdatedRendererNodesEventArgs(NavigatorView view)
 {
     View = view;
 }
Beispiel #6
0
        public ImprovedArrow(NavigatorView parentNavigatorView, IRelationshipProxy relationship)
            : base()
        {
            Relationship        = relationship;
            ParentNavigatorView = parentNavigatorView;

            this.SetValue(Canvas.ZIndexProperty, -1);

            DropShadowEffect selectionEffect = new DropShadowEffect();

            selectionEffect.BlurRadius  = 0;
            selectionEffect.ShadowDepth = 0;
            selectionEffect.Color       = Colors.Red;
            selectionEffect.Direction   = 0;
            this.Effect = selectionEffect;

            _arrowBody = new LineSegment();

            _arrowFigure = new PathFigure();
            _arrowFigure.Segments.Add(_arrowBody);

            _arrow = new PathGeometry();
            _arrow.Figures.Add(_arrowFigure);

            _arrowPath                  = new Path();
            _arrowPath.Stroke           = new SolidColorBrush(Color.FromArgb(255, 0, 0, 0));
            _arrowPath.StrokeEndLineCap = PenLineCap.Triangle;
            _arrowPath.StrokeThickness  = 1.25;
            _arrowPath.Data             = _arrow;

            _arrowHead = new Line();
            _arrowHead.StrokeEndLineCap = PenLineCap.Triangle;
            _arrowHead.StrokeThickness  = 8;
            _arrowHead.Stroke           = new SolidColorBrush(Colors.Black);

            this.Children.Add(_arrowHead);
            this.Children.Add(_arrowPath);

            _toSelectionRect                      = new Rectangle();
            _toSelectionRect.Width                = 6;
            _toSelectionRect.Height               = 6;
            _toSelectionRect.Stroke               = new SolidColorBrush(Colors.Black);
            _toSelectionRect.StrokeThickness      = 1;
            _toSelectionRect.Visibility           = Visibility.Collapsed;
            _toSelectionRect.Fill                 = new SolidColorBrush(Colors.White);
            _toSelectionRect.Opacity              = 0.7;
            _toSelectionRect.MouseLeftButtonDown += new MouseButtonEventHandler(_toSelectionRect_MouseLeftButtonDown);
            _toSelectionRect.MouseLeftButtonUp   += new MouseButtonEventHandler(_toSelectionRect_MouseLeftButtonUp);

            _fromSelectionRect                      = new Rectangle();
            _fromSelectionRect.Width                = 6;
            _fromSelectionRect.Height               = 6;
            _fromSelectionRect.Stroke               = new SolidColorBrush(Colors.Black);
            _fromSelectionRect.StrokeThickness      = 1;
            _fromSelectionRect.Visibility           = Visibility.Collapsed;
            _fromSelectionRect.Fill                 = new SolidColorBrush(Colors.White);
            _fromSelectionRect.Opacity              = 0.7;
            _fromSelectionRect.MouseLeftButtonDown += new MouseButtonEventHandler(_fromSelectionRect_MouseLeftButtonDown);
            _fromSelectionRect.MouseLeftButtonUp   += new MouseButtonEventHandler(_fromSelectionRect_MouseLeftButtonUp);

            this.Children.Add(_toSelectionRect);
            this.Children.Add(_fromSelectionRect);

            this.Loaded += new RoutedEventHandler(OnLoaded);
        }
        public SingleDepthNodeRenderer(NavigatorView parentNavigatorView, INodeProxy nodeProxy, ThemeManager themeManager, string skinName)
            : base(parentNavigatorView, nodeProxy, themeManager, skinName)
        {

        }
Beispiel #8
0
 public UpdatedRendererNodesEventArgs(NavigatorView view)
 {
     View = view;
 }