public ElementsViewModel(BaseDesignerCanvas designerCanvas) { ServiceFactoryBase.Events.GetEvent<ElementAddedEvent>().Subscribe(OnElementAdded); ServiceFactoryBase.Events.GetEvent<ElementRemovedEvent>().Subscribe(OnElementRemoved); ServiceFactoryBase.Events.GetEvent<ElementSelectedEvent>().Subscribe(OnElementSelected); DesignerCanvas = designerCanvas; Elements = new ObservableCollection<ElementBaseViewModel>(); Update(); }
public RubberbandAdorner(BaseDesignerCanvas designerCanvas) : base(designerCanvas) { rubberband = new Rectangle { Stroke = Brushes.Navy, StrokeThickness = 1 / ZoomFactor, StrokeDashArray = new DoubleCollection(new double[] { 2 }) }; }
public EllipseAdorner(BaseDesignerCanvas designerCanvas) : base(designerCanvas) { }
public GridLineAdorner(BaseDesignerCanvas designerCanvas, Orientation orientation) : base(designerCanvas) { Orientation = orientation; }
public PolygonAdorner(BaseDesignerCanvas designerCanvas) : base(designerCanvas) { }
public TextBoxAdorner(BaseDesignerCanvas designerCanvas) : base(designerCanvas) { }
public ToolboxViewModel(BaseDesignerCanvas designerCanvas) { DesignerCanvas = designerCanvas; RegisterInstruments(); EventManager.RegisterClassHandler(typeof(Window), Keyboard.KeyDownEvent, new KeyEventHandler(OnKeyEventHandler), true); }