[prev in list] [next in list] [prev in thread] [next in thread] 

List:       fop-user
Subject:    Re: [fop-0.91beta] RTF errors
From:       Jeremias Maerki <dev () jeremias-maerki ! ch>
Date:       2006-01-26 8:21:31
Message-ID: 20060126091154.3A73.DEV () jeremias-maerki ! ch
[Download RAW message or body]


On 25.01.2006 23:53:04 Ian & Chris wrote:
> Thanks for the info,
> 
> I would like to assist you with the development of the RTF component to
> address this, but I have no Java skills, how hard would this be to change in
> the existing code. I think it would be a good exercise for me to get
> involved, but I am not sure if I would be a good candidate.

Hey, everyone is a good candidate to get involved in this project. Even
if someone only helps out on this mailing list answering questions,
that's a big help and a good way to give something back to the project.

Since you say you have no Java skills, it's going to be a bit difficult
to add the missing functionality I'm afraid. There's that interface
called "PercentBaseContext" that has to be provided through the whole
RTFHandler class. For all page-oriented output formats (PDF, PS, etc).
this is handled in the various layout managers but that's not possible
for the RTFHandler because it produces a flow-oriented format. Maybe you
can do some hacks in XSLT to convert the column-widths but if that
doesn't work, some Java coding will be necessary.

> The style sheet has a percentage value on the proportional-column-width()
> function in the column-width attribute of fo:table-column as you thought,
> This is done to allow for an automated conversion from existing documents.
> Once the style sheets require changing, they are updated (manually), the
> general rule is to use absolute widths during this update, but that doesn't
> help in the short term. The XSL snippet is as follows:
> 
> <fo:table xsl:use-attribute-sets="table">
> 		<fo:table-column
> column-width="proportional-column-width(40)"/>
> 			<!-- company -->
> 		<fo:table-column
> column-width="proportional-column-width(60)"/>
> 			<!-- spaces -->
> 		<fo:table-column
> column-width="proportional-column-width(5)"/>
> 			<!-- text -->
> 		<fo:table-column
> column-width="proportional-column-width(1)"/>
> 			<!-- spaces -->
> 		<fo:table-column
> column-width="proportional-column-width(8)"/>
> 			<!-- formattted date -->
> 		<fo:table-column
> column-width="proportional-column-width(1)"/>
> 			<!-- spaces -->
> 		<fo:table-column
> column-width="proportional-column-width(5)"/>
> 			<!-- text -->
> 		<fo:table-column
> column-width="proportional-column-width(1)"/>
> 			<!-- spaces -->
> 		<fo:table-column
> column-width="proportional-column-width(8)"/>
> 			<!-- formatted time -->
> 		<fo:table-column
> column-width="proportional-column-width(3)"/>
> 			<!-- spaces -->
> 			<fo:table-body>
> 				<fo:table-row>
> 					<fo:table-cell>
> 						<fo:block>
> 							<xsl:value-of
> select="CMPNY_"/>
> 						</fo:block>
> 					</fo:table-cell>
> Etc..........
> 
> -----Original Message-----
> From: Jeremias Maerki [mailto:dev@jeremias-maerki.ch] 
> Sent: Wednesday, 25 January 2006 6:50 PM
> To: fop-users@xmlgraphics.apache.org
> Subject: Re: [fop-0.91beta] RTF errors
> 
> Thanks for the feedback. As is hinted at on our website, the RTF support
> is not as extensive as for PDF. To a certain degree that is due to the
> fact that RTF is in many points not as expressive as XSL-FO. But what
> you hit here are restrictions on non-absolute values which are not
> properly handled in the current code, yet. You didn't post a sample file
> but from the error I guess you've used either a percentage value or the
> proportional-column-width() function in the column-width attribute of
> fo:table-column. The RTF handler doesn't support that, yet. You will
> have to rewrite your stylesheet to use absolute widths everywhere to
> make it usable for both PDF and RTF output. The alternative is to help
> us improve RTF support. I hope that helps.
> 
> On 25.01.2006 04:04:56 bakeric wrote:
> > 
> > I am currently looking at the new version of FOP, in particular the RTF
> > component, it would be nice to create RTF document from the same
> > process that creates the PDF.
> > 
> > The PDF works well in with the new version (very impressed (not just
> > sucking up)), but I am now trying to use the same style sheets to
> > create RTF, and it doesn't even get past go.
> > 
> > Is it a bug, or do I need to change the format of my XSL code..
> 
> <snip/>


Jeremias Maerki


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic