473,395 Members | 1,418 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Docbook XML: Image in the Page Header

Hello,

I'm using Docbook XML 4.2 and FOP 0.20.5 to create a pdf from my xml
source. I can generate the pdf with no problem, however I could not
manage to include our company logo within the header. The pdf is
created with the correct header, but there is no image.

What I did:

I copied the whole header.template section from pagesetup.xsl into my
customization layer, and tried to insert the picture in the 'right'
section:

<xsl:template name="header.content">
<xsl:param name="pageclass" select="''"/>
<xsl:param name="sequence" select="''"/>
<xsl:param name="position" select="''"/>
<xsl:param name="gentext-key" select="''"/>
<fo:block>

<!-- sequence can be odd, even, first, blank -->
<!-- position can be left, center, right -->
<xsl:choose>

.... snip ...

<xsl:when test="$position='right'">
<fo:external-graphic src="logo.gif"/>
<!-- Same for odd, even, empty, and blank sequences -->
<xsl:call-template name="draft.text"/>
</xsl:when>

.... snip ...

</xsl:template>

The logo.gif is in the same directory as the xml. I also tried
<fo:external-graphic src="url('logo.gif')"/>, but it doesn't work
either.

I thought that the image might be to big to fit into the header, but
neither making it very small nor enlarging the right section of the
header was successfull.

Does anybody have an idea what is wrong? I would highly appreciate a
customization layer example with an image in the header.

Thanks a lot,

Simon Stuber
Jul 20 '05 #1
2 4341
In article <c4*************************@posting.google.com> ,
Simon Stuber <si******@gmx.net> wrote:

% The logo.gif is in the same directory as the xml. I also tried

This is a knee-jerk reaction: are GIF graphics supported? I'd
convert it to PNG and try with that.
--

Patrick TJ McPhee
East York Canada
pt**@interlog.com
Jul 20 '05 #2

Patrick,

According to the Apache FOP webpage, gif is supported natively, but not
png. I also tried bmp with the same result.

Simon

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Dr. Laurence Leff | last post by:
I am having trouble doing the basics with xmlto on Redhat to convert DocBook XML into the various files. I believe the problem is the first line on the files: Here is starter file (notes.xml):...
2
by: Simon Strandgaard | last post by:
I am trying to understand how to create a 'catalog.xml' file for my docbook-xml documents. If I understand correct a local catalog.xml file can both avoid hardcoding in makefiles (portability),...
3
by: ZJT | last post by:
What are the ways and corresponding tools to transform a docbook document to a pdf document? Thanks a lot!
0
by: b | last post by:
When I create chm with docbook I have most of the pages on one file. So, when I search for "Linux" page begins with "Sample HTML" .... I get the page with several pages in one. Can this be...
2
by: softino | last post by:
Hi, I am not sure if this is the correct newsgroup but I have a question about docbook titlepages. I am trying to create a title page for fo processing with two images. One image at the top,...
2
by: Yarco | last post by:
I'm learning for docbook under win32. I download: openjade-1_3_1-2-bin docbook-xml-4.4 docbook-dsssl-1.79 ldp.dsl And then copy all openjade bin\ to win32 system\, and then create a directory...
7
by: mike p. | last post by:
I have a docbook xml file, and am using standard docbook 1.61.3 xsl stylesheets to do xhtml transform. Transform works fine when using MSXML. When I try to do the following using asp.net 1.1: ...
3
by: Otmar Ganahl | last post by:
Hi! In my application I transform a docbook file to a html view using the webcontrol "Xml" (with a xsl).It works fine, except the using of the tag "fileref" in the docbook-file will cause an...
2
by: Joseph Kesselman | last post by:
Since the recent "Docbook on Windows" question brought this up... I did a bit of checking on the current status of these schemas, what they're intended for and how they interrelate. IBM's Robert...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.