public void Render(Component component, CircuitDiagram.Render.IRenderContext dc, bool absolute) { if (absolute) { dc.DrawEllipse(Point.Add(Centre.Resolve(component), component.Location), RadiusX, RadiusY, Thickness, Fill); } else { dc.DrawEllipse(Centre.Resolve(component), RadiusX, RadiusY, Thickness, Fill); } }
public void Render(LayoutInformation layout, ILayoutContext layoutContext, IDrawingContext drawingContext) { var centre = Centre.Resolve(layout, layoutContext.Options); if (layoutContext.Options.Absolute) { drawingContext.DrawEllipse(Point.Add(centre, layout.Location), RadiusX, RadiusY, Thickness, Fill); } else { drawingContext.DrawEllipse(centre, RadiusX, RadiusY, Thickness, Fill); } }