RE: Fo Span all
Hi Vincent Thank you so very much with your help it works exactly how I need. Barry -Original Message- From: Vincent Hennebert [mailto:vhenneb...@gmail.com] Sent: 19 November 2009 17:24 To: fop-users@xmlgraphics.apache.org Subject: Re: Fo Span all Hi Barry, The overflow warning comes from the region-before, whose content is higher than the extent. You can get rid of the warning by setting the extent to 1.37in (or making the content smaller). If I understood your need correctly, you can achieve what you want by making use of an elastic space, that must be as big as possible but is allowed to be reduced down to zero. In your example below, replace the block-container that has span=all and a red border and plenty of fo:block children with the following: fo:block-container span=all background-color=white fo:block space-before.minimum=0 space-before.optimum={height of the region-body} space-before.conditionality=retain/ /fo:block-container The block-container is to prevent the space from creating a mess with the preceding content (a so-called fence in the Recommendation); the conditionality must be set to retain so that the space, which starts a reference area, isn’t discarded. HTH, Vincent Barry Whiting wrote: Hi Venkat Thanks for all your help so far. Here is a generated fo file from my application where the problem lies is at the base the block container overlays the region after. I need the block container height to be larger than necessary as I dont know where my content will end with the span all so I cant set an explicit height to it. ?xml version=1.0 encoding=UTF-8? fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format; xmlns:exslt=http://exslt.org/common; fo:layout-master-set fo:simple-page-master master-name=whatsonneville page-height=11.00in page-width=8.27in margin-top=0.50in margin-left=0.47in margin-right=0.47in margin-bottom=0.35in fo:region-body region-name=region-body margin-bottom=0.91in margin-top=1.38in column-count=4 column-gap=0.17in background-position-horizontal=center background-repeat=repeat-y background-image=url(images/4_column.gif)/ fo:region-before region-name=region-before extent=1.17in/ fo:region-after region-name=region-after extent=0.81in precedence=true/ /fo:simple-page-master /fo:layout-master-set fo:page-sequence master-reference=whatsonneville fo:static-content flow-name=region-before fo:block line-height=0.01in height=0.01in fo:leader leader-pattern=rule leader-length=100% rule-style=solid rule-thickness=0.01in color=#00 margin=0px/ /fo:block fo:block font-family=CaeciliaRomanOsF font-weight=bold font-size=30pt line-height=34pt space-before=0.27in space-after=0.25in Hello /fo:block fo:block line-height=0.12in height=0.15in padding=0px margin=0px white-space-treatment=ignore linefeed-treatment=preserve white-space-collapse=true fo:leader leader-pattern=rule leader-length=100% rule-style=solid rule-thickness=0.15in color=#0AC4FF margin=0px/ /fo:block /fo:static-content fo:static-content flow-name=region-after fo:block-container position=absolute border=1px solid black fo:block border-top=0.01in solid #00 fo:table inline-progression-dimension=7.33in table-layout=fixed fo:table-column column-number=1 column-width=0.50in/ fo:table-column column-number=1 column-width=5.15in/ fo:table-column column-number=1 column-width=1.68in/ fo:table-body fo:table-row fo:table-cell fo:block font-family=CaeciliaRomanOsF font-weight=bold font-size=10pt line-height=12pt color=#00 padding-top=0.31in fo:page-number/ /fo:block /fo:table-cell fo:table-cell fo:block font-family=CaeciliaRomanOsF font-weight=bold font-size=10pt line-height=12pt color=#00 padding-top=0.31in Me/fo:block fo:block font-family=CaeciliaLTLight font-weight=normal font-size=10pt line-height=12pt color=#00 Place/fo:block fo:block font-family=CaeciliaLTLight font-weight=normal font-style=italic font-size=10pt line-height=12pt color=#00 padding-top=0.04in Dates/fo:block /fo:table-cell fo:table-cell fo:block/ /fo:table-cell /fo:table-row /fo:table-body /fo:table /fo:block /fo:block-container /fo:static-content fo:flow flow-name=region-body fo:block Loads and loads of text spanning 4 columns then a spanned block
Re: How to avoid vertical space between blocks containing images
Hi, I have the same problem as Richard. Setting font-size=0 does not really work for me. Although the space is gone I still have a very thin border around the pictures. I realized this using a block with background-color and ebmbedded image. When I use zoom factor above 150% I can see it clearly in my PDFs. I guess this is no FOP issue because I get the same results in XEP. I already set any space-* and padding-* values to 0. Any ideas? Cheers, Tobias On Fri, Nov 13, 2009 at 11:19 AM, fopaddict rich...@uttner.de wrote: Pascal and Peter, perfect answer, it works for FOP 0.94 and 0.95 with font-size=0. Regards, Richard Pascal Sancho wrote: Hi list, This is due to how FOP (and other FO engines) handles half-leading (Cf REC 1.1 §4.5: line-area [1] and $6.5.2 - fo:block [2]) To avoid blank space between 2 contigous blocks containing only graphical materials, you should ensure that both line-height and font-size traits are set to zero. As line-height initial value is [1.2] (witch means 1.2 * font-size), setting font-size property to 0pt is sufficient. [1] http://www.w3.org/TR/2006/REC-xsl11-20061205/#area-line [2] http://www.w3.org/TR/2006/REC-xsl11-20061205/#fo_block HTH, Pascal Peter Coppens a écrit : Perhaps you find inspiration in http://www.antennahouse.com/support/qa/QA/2005052701.html Because fo:external-graphic is an inline element, it makes line area. The default height of line area is 1.2em, so you should specify line-height=1 for the block. However, even though line-height=1 is specified, a graphic is placed on top of a baseline and there remains a space under the baseline as a result. In order to avoid this, you should specify font-size=0pt, too. Hth Peter From: fopaddict rich...@uttner.de My .fo code contains nothing but a sequence of images exactly fitting into page height (because page margins are defined accordingly): fo:block space-before=0mm space-after=0mm fo:external-graphic src=url(images/{...@picture}) / /fo:block When printing to the page, FOP 0.94 and 0.95 are inserting 2mm vertical space between each block. Only when I set space-after to -2mm, the output is as I would expect it normally (exactly no gap between images). Is there another way to keep FOP from adding space in general? If not: How do I know how much I have to subtract in order to get zero space? - To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org -- View this message in context: http://old.nabble.com/How-to-avoid-vertical-space-between-blocks-containing-images-tp26252057p26334354.html Sent from the FOP - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org - To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
Re: Problem using attributes with xsl:value-of select=/
On 20.11.2009 23:54, Glen Mazza wrote: Hello, I'm having difficulty gettingxsl:value-of select=/ to work with attributes ... batch myattval= ... xsl:template match=batch fo:blockxsl:value-of select=@myattval//fo:block fo:blockxsl:value-of select=./@myattval//fo:block Both approaches work for me (the first is the canonical one). I suspect your original problem is somewhat different, common problems are misspellings, wrong context and namespace confusions. You might get more help if you cutpaste the actual xml and xslt code into the mail. J.Pietschmann - To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org