With PDFsharp-GDI 6.1.0 the following code crashes:
var pdfDocument = new PdfDocument();
var pdfPage = pdfDocument.AddPage();
var xGraphics = XGraphics.FromPdfPage(pdfPage);
var container = xGraphics.BeginContainer();
xGraphics.EndContainer(container);
Stacktrace:
System.InvalidOperationException : _gfx
at PdfSharp.Drawing.XGraphics.BeginContainer(XRect dstrect, XRect srcrect, XGraphicsUnit unit)
at PdfSharp.Drawing.XGraphics.BeginContainer()
Expected Behavior
It should be possible to use containers when XGraphics was created from a pdf page.
Actual Behavior
With PDFsharp-GDI 6.1.0 the following code crashes:
Stacktrace:
Expected Behavior
It should be possible to use containers when XGraphics was created from a pdf page.