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 JPee <pe...@softwareforen.de> on 2009/10/20 16:33:48 UTC
get position of block
Hi,
I'm working with FOP embedded in a CMS for generating PDFs. I have the
following problem.
In my PDF there are texts, in the texts there are headers, paragraphs, bold
and italic parts. In my project I defined patterns how these things are
mapped to fop. Sometimes it happens that there is a Header in the last lines
of a page. The structure of the generated fop sourcecode is like.
<fo:block headerattributes>headertext</fo:block> (1 time)
<fo:block normaltextattr.>text</fo:block> (n times)
And that iterates several times.
Is there a possibilty to get the position out of a block so i could define a
rule, if the block.height is higher than 200mm page-break-before? Or is
there a possibility to keep the block with the headerattributes together
with the next line, which is used by another block? In my case i don't have
the choice to put a block around the headertext and the normal text, to use
the keep-together.within-page attribute.
Greetings,
JPee
--
View this message in context: http://www.nabble.com/get-position-of-block-tp25976225p25976225.html
Sent from the FOP - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
AW: get position of block
Posted by Georg Datterl <ge...@geneon.de>.
Hi JPee,
No, you won't easily get the height of a block, since that information is only available, after the various breaking and layouting algorithms of fop are finished. But there shouldn't be anything wrong with keep-with-next / keep-with-previous. Helped me a lot.
Regards,
Georg Datterl
------ Kontakt ------
Georg Datterl
Geneon media solutions gmbh
Gutenstetter Straße 8a
90449 Nürnberg
HRB Nürnberg: 17193
Geschäftsführer: Yong-Harry Steiert
Tel.: 0911/36 78 88 - 26
Fax: 0911/36 78 88 - 20
www.geneon.de
Weitere Mitglieder der Willmy MediaGroup:
IRS Integrated Realization Services GmbH: www.irs-nbg.de
Willmy PrintMedia GmbH: www.willmy.de
Willmy Consult & Content GmbH: www.willmycc.de
-----Ursprüngliche Nachricht-----
Von: JPee [mailto:perlet@softwareforen.de]
Gesendet: Dienstag, 20. Oktober 2009 16:34
An: fop-users@xmlgraphics.apache.org
Betreff: get position of block
Hi,
I'm working with FOP embedded in a CMS for generating PDFs. I have the following problem.
In my PDF there are texts, in the texts there are headers, paragraphs, bold and italic parts. In my project I defined patterns how these things are mapped to fop. Sometimes it happens that there is a Header in the last lines of a page. The structure of the generated fop sourcecode is like.
<fo:block headerattributes>headertext</fo:block> (1 time) <fo:block normaltextattr.>text</fo:block> (n times)
And that iterates several times.
Is there a possibilty to get the position out of a block so i could define a rule, if the block.height is higher than 200mm page-break-before? Or is there a possibility to keep the block with the headerattributes together with the next line, which is used by another block? In my case i don't have the choice to put a block around the headertext and the normal text, to use the keep-together.within-page attribute.
Greetings,
JPee
--
View this message in context: http://www.nabble.com/get-position-of-block-tp25976225p25976225.html
Sent from the FOP - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org