This project is read-only.

bug found on XImage.DrawImage

Apr 17, 2011 at 7:00 PM
Edited Apr 17, 2011 at 7:02 PM

I downloaded the source today to save UIElements to Stream to PDF. 

First, I create a Ximage from PNG stream:

XImage ximg = XImage.FromStream(stream); Then when I call

XGraphics.DrawImage(ximg, kvp.Value);
Has this line:
var t = other.Elements.GetObject(key);
Which throws ArgumentNullException
So I changed it to:
var t = other.Elements.GetObject<PdfSharp.Pdf.PdfItem>(key);
And now it works.
Apr 17, 2011 at 7:56 PM
Sorry, can u give me a hint where the XImage class is from? I dont know it.
Apr 17, 2011 at 11:15 PM

Oh wrong project. I meant to post this at SilverPDF.