void ICanvasCellViewFrontend.Draw(object ctxBackend, Rectangle cellArea) { using (var ctx = new Context (ctxBackend, Toolkit.CurrentEngine)) { ctx.Reset (null); OnDraw (ctx, cellArea); } }
void Draw(object ctx, Rectangle bounds) { var c = new Context(ctx, ToolkitEngine); c.Reset(null); OnDraw(c, bounds); }
public ImageBuilder(double width, double height) { backend = new VectorContextBackend (); ctx = new Context (backend, ToolkitEngine, vectorImageRecorderContextHandler); ctx.Reset (null); this.width = width; this.height = height; }
public ImageBuilder(double width, double height) { backend = new VectorContextBackend(ToolkitEngine, width, height); ctx = new Context(backend, ToolkitEngine, ToolkitEngine.VectorImageRecorderContextHandler); ctx.Reset(null); this.width = width; this.height = height; }
void Draw(object ctx, Rectangle bounds, ImageDescription idesc, Toolkit toolkit) { var c = new Context (ctx, toolkit); if (idesc.Styles != StyleSet.Empty) c.SetStyles (idesc.Styles); c.Reset (null); c.Save (); c.GlobalAlpha = idesc.Alpha; OnDraw (c, bounds); c.Restore (); }
public ImageBuilder(double width, double height) { backend = new VectorContextBackend (ToolkitEngine, width, height); // Don't set the global styles to the context. The global styles will be used when rendering the image ctx = new Context (backend, ToolkitEngine, ToolkitEngine.VectorImageRecorderContextHandler, false); ctx.Reset (null); this.width = width; this.height = height; }
public ImageBuilder(double width, double height) { backend = new VectorContextBackend(ToolkitEngine, width, height); // Don't set the global styles to the context. The global styles will be used when rendering the image ctx = new Context(backend, ToolkitEngine, ToolkitEngine.VectorImageRecorderContextHandler, false); ctx.Reset(null); this.width = width; this.height = height; }
public void OnDraw (object context, Rectangle dirtyRect) { Context ctx = null; try { ctx = new Context (context, ToolkitEngine); ctx.Reset (Parent); ((Canvas)Parent).OnDraw (ctx, dirtyRect); } finally { ctx.Dispose (); } }
void Draw(object ctx, Rectangle bounds, ImageDescription idesc, Toolkit toolkit) { var c = new Context(ctx, toolkit); c.Reset(null); c.Save(); if (idesc.Styles != StyleSet.Empty) { c.SetStyles(idesc.Styles); } c.GlobalAlpha = idesc.Alpha; OnDraw(c, bounds); c.Restore(); }
void Draw (object ctx, Rectangle bounds) { var c = new Context (ctx, ToolkitEngine); c.Reset (null); OnDraw (c, bounds); }