From: Tony G. <Ton...@Su...> - 2005-07-21 00:18:56
|
Tim Waugh <tw...@re...> writes: > On Sun, Jul 10, 2005 at 11:58:48PM +0100, Tony Graham wrote: >> The code now in CVS formats fo:external-graphic with the GNOME Print >> backend as well as used to be done with the PDFlib backend. I.e., >> fo:external-graphic works, but you need to specify content-width and >> content-height to get space allocated for the graphic. >> >> Can someone try it out to see if it works for them? If it does, I'll >> then make a 0.3.5 and announce that on the external lists rather than >> 0.3.4. > > Works here in that I get pictures included in the output (yay!), > except of course you need to make this change to libfo-compat.xsl: Committed, thanks. ... > A couple of things seem wrong though: > > * Transparency seems to come out as black though -- is that something > that's easy to fix? Presumably it would be fixed by some combination of GdkPixbuf and libgnomeprint and/or your viewer/printer. xmlroff is just opening the file with GdkPixbuf and handing it to libgnomeprint. There is undoubtedly scope for me to have added bugs, but AFAICT it's just the standard usage of those two libraries. I have a vague memory of seeing something about something like that on the gnome-print-list, but I could be imagining it. > * My captions seem to disappear, perhaps underneath the image. I'm > using DocBook XML like this: > > <figure id="fig-scale"> > <title>Scale image using <application>The GIMP</application></title> > <mediaobject> > <imageobject> > <imagedata fileref="figs/photos-scale-en.png" format="PNG" > contentwidth="3in" contentdepth="4in"/> > </imageobject> > </mediaobject> > </figure> > > I can see the caption in the XSL-FO, but not in the resulting PDF. > Known issue with external-graphic placement? Not previously known, anyway. Pango is supposed to be told the size of the space to leave, but I expect that the title is in a separate fo:block in the FO anyway. Two things come to mind: - The graphic is being rendered at the wrong resolution and is therefore too big; or - You have a small, fixed line-height and the graphic is overflowing that and overwriting the next block area. Of course the other thing that comes to mind is that the graphic (and all inline FO) handling still needs major work. I have a week off work next month so I should have time for xmlroff then. Regards, Tony. |