public GraphicContent(bool autoLayerCreating = true) { Command = new CommandReceiver(); f_workSpace = new Canvas(); f_graphicToolProperties = new GraphicToolProperties() { Color = Colors.White, Softness = 1, Thickness = 10 }; ConfigureWorkSpace(); Layers = new List<Layer>(); if (autoLayerCreating) AddLayer(new Layer("New layer " + Layers.Count)); // Set current tool is Pointer f_currentTool = new PointerTool(this); }
public void Unsubscribe(GraphicToolProperties observer) { if (f_subscribes.Contains(observer)) f_subscribes.Remove(observer); }
public void Notify() { IToolProperties properties = new GraphicToolProperties() { Color = null, Softness = SoftnessValue, Thickness = ThicknessValue }; foreach (GraphicToolProperties graphicToolProperty in f_subscribes) graphicToolProperty.UpdateProperties(properties); }
public void Subscribe(GraphicToolProperties observer) { f_subscribes.Add(observer); }