I guess there were problems with the attachment of my last e-mail...
Here are the files again, this time in text format.

Thanks,

Julio Lerm


----- Original Message -----
From: "jcplerm" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, March 26, 2003 5:49 PM
Subject: Re: Drawing images with PDFDocumentGraphics2D


> Keiron,
>
> I am sending attached to this message a small test case that should
> reproduce the problem.
> I am loading the image with "Toolkit.getDefaultToolkit().getImage" and
then
> I pass that image to the "drawImage" method, along with "new Panel()" as
an
> observer.
>
> By running "java TestPDFGen>x.pdf" I get only a single square on the page,
> without the image.
>
> I would be very grateful if you could take a look into this and see what I
> am doing wrong.
>
> Thanks a lot,
>
> Julio
>
> ----- Original Message -----
> From: "Keiron Liddle" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Wednesday, March 26, 2003 5:02 PM
> Subject: Re: Drawing images with PDFDocumentGraphics2D
>
>
> > Hi,
> >
> > The ImageObserver is used in the getWidth, getHeight and drawImage
methods
> > with the image that is passed in.
> > So in a sense it depends on the img that you are passing in. The
observer
> is an
> > object waiting for the image to be loaded.
> >
> > How are you creating the image, can you get an abserver from there
> somehow.
> > Maybe you could use a dummy observer if the image is already loaded.
> >
> > Keiron.
> >
> > > How can I obtain an "java.awt.ImageObserver" that
> > > I can pass to one of the "drawImage" methods of
> > > PDFDocumentGraphics2D?
> > >
> > > Example:
> > >
> > >
> > >          pdfgen = new PDFDocumentGraphics2D(true,System.out,800,1100);
> > >          ...
> > >          pdfgen.drawImage(img,100,100,50,50,imgObserver);
> > >
> > > With a pure AWT application, I would pass the java.awt.Panel whose
> "paint"
> > > method invokes "drawImage".
> > >
> > > But with PDFDocumentGraphics2D, I don't have such a Panel object.
> > > Even if I create a surrogate one, the resulting PDF will not have the
> images in it.
> > >
> > > What can act as the "ImageObserver"?
> > >
> > > Thanks,
> > >
> > > Julio Lerm
> > > Chicago, IL
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, email: [EMAIL PROTECTED]
> >
>

<<attachment: Glob.JPEG>>

<<attachment: setenv.bat>>

Attachment: TestPDFGen.java
Description: Binary data

Attachment: TestPDFGen.class
Description: Binary data

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

Reply via email to