You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Saurabh Thakkur <sa...@idealinvent.com> on 2010/07/15 11:37:58 UTC

Unwanted blank lines on creating Text Files

Hi All,

I'm generating one plain text (MimeConstants.MIME_PLAIN_TEXT) file. Where I'm taking the data from the XML and writing it according to one defined template(XSL)

I'm getting unwanted blank lines on the generated Text file. Same template works fine for PDF and RTF formats. I'm not getting any unwanted lines with these formats.

Can any one suggest? I'm new to this.

Thanks in advance.

Regards
Saurabh
---------------------------------------------------------------------------------------------------------------------------------------- CAUTION - Disclaimer -------------------------------------------------------------------------------------------------------------------

This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely for the use of the addressee(s). If you are not the intended recipient, please notify the sender by e-mail and delete the original message. Further, you are not to copy, disclose, or distribute this e-mail or its contents to any other person and any such actions are unlawful. IDEAL INVENT Technologies Pvt. Ltd. and its subsidiaries, reserve the right to monitor and review the content of all messages sent to or from this e-mail address. Messages sent to or from this e-mail address may be stored on the e-mail system of IDEAL INVENT Technologies Pvt. Ltd. and its subsidiaries.

------------------------------------------------------------------------------------------------------------------------------------------- End of Disclaimer -------------------------------------------------------------------------------------------------------------------

 

Re: Unwanted blank lines on creating Text Files

Posted by "J.Pietschmann" <j3...@yahoo.de>.
On 15.07.2010 11:37, Saurabh Thakkur wrote:
> I'm generating one plain text (MimeConstants.MIME_PLAIN_TEXT) file.
> Where I'm taking the data from the XML and writing it according to
> one defined template(XSL)
>
> I'm getting unwanted blank lines on the generated Text file. Same
> template works fine for PDF and RTF formats. I'm not getting any
> unwanted lines with these formats.

While this is surprising to unsuspecting users, that's the way the
text renderer is supposed to work. The page is basically divided into
a grid defined by the characters-per-inch and lines-per-inch values,
and the positions determined by FOPs layout engine are rounded by the
renderer to the next grid position. If the line height determined by
the layout doesn't match exactly the line height defined by the
renderers lines-per-inch value, empty lines are likely to appear. The
only way to avoid them is to take measures to ensure a constant line
height which matches the renderers lines-per-inch value.
How the renderer's lines-per-inch value is determined depends on the
FOP version. Which release are you using?

(Ow, was it lines per inch or lines per page? Anyway, the effect is
the same.)

J.Pietschmann

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