protected override void OnRender(swm.DrawingContext dc) { base.OnRender(dc); if (!Handler.tiled) { var rect = new wf.Rect(0, 0, ActualWidth, ActualHeight); var graphics = new Graphics(Handler.Widget.Generator, new GraphicsHandler(this, dc, rect, false)); Handler.Widget.OnPaint(new PaintEventArgs(graphics, rect.ToEto())); } }
protected override void OnRender(swm.DrawingContext drawingContext) { base.OnRender(drawingContext); var rect = new Rectangle(new Size((int)Width, (int)Height)); var graphicsHandler = new GraphicsHandler(this, drawingContext, new wf.Rect(0, 0, Width, Height)); var graphics = new Graphics(Handler.Widget.Generator, graphicsHandler); // needed to set size properly for some reason.. ?? graphics.DrawRectangle(new Pen(Colors.Transparent), rect); var args = new PrintPageEventArgs(graphics, rect.Size, PageNumber); Handler.Widget.OnPrintPage(args); }
protected override void OnRender(swm.DrawingContext drawingContext) { var graphics = new Graphics(Handler.Widget.Generator, new GraphicsHandler(this, drawingContext, bounds.ToWpf(), false)); Handler.Widget.OnPaint(new PaintEventArgs(graphics, Bounds)); }