apologies wrong mailing group
./asitha

On Fri, Jul 22, 2011 at 9:06 AM, intasi <[email protected]> wrote:

> if im not mistaken u can use a xsl number format funtion... we had the same
> issue in our project and this was the solution.
>
> eg: format-number(1.2 - 0.1,'#.##########') would return 1.1
>
> http://www.w3schools.com/xsl/func_formatnumber.asp
>
> Hope it helps
> Regards
> Asitha Weerasinghe
>
>
>
>
> On Fri, Jul 22, 2011 at 1:01 AM, Andreas L. Delmelle <
> [email protected]> wrote:
>
>> On 21 Jul 2011, at 14:37, Marcos García wrote:
>>
>> Hi Marcos
>>
>> > <snip />
>>
>> > Is there something I am missing, or do you think I should change my
>> approach altogether, and use another mechanism for inserting textboxes or
>> other floating elements using Apache-Fop?
>>
>> XSL-FO defines fo:float, which FOP unfortunately does not yet support. I
>> am unsure whether that is what you would need. fo:float can be used for
>> before/start/end floating content. To have content float on the after-edge
>> (i.e. the bottom of the page), one would have to resort to fo:footnotes,
>> which would imply that the floating content is then mixed with other
>> footnotes, if present.
>>
>> That said, you might be able to pull it off using a regular
>> block-container that takes up 100% of the available height, and then insert
>> the text-boxes in 'absolute' positioned block-containers within the regular
>> block-container. Absolute will then mean relative to the outer
>> block-container.
>> Granted, the boxes would then be independent of the surrounding content
>> --i.e. there would be no intrusions; the surrounding content will just be
>> rendered as if they weren't there--, so that may not correspond with the
>> expectations about 'floating'...
>>
>> At any rate, if you can use explicit 'top' coordinates, it would not
>> matter in which order they appear in the FO. The only constraints are that
>> FOP has no support for z-index, so if the boxes would overlap, the one that
>> appears last in the stream will always be rendered 'on top'.
>>
>> The following sample probably may give a better idea of what I mean:
>>
>> <fo:block-container height="100%" border="0.5pt solid red">
>>  <fo:block-container absolute-position="absolute" top="100% - 1.2em"
>> left="0" border="0.5pt solid blue">
>>    <fo:block>Bottom of the page</fo:block>
>>  </fo:block-container>
>>  <fo:block-container absolute-position="absolute" top="0" left="0"
>> border="0.5pt solid blue">
>>    <fo:block>Top of the page</fo:block>
>>  </fo:block-container>
>> </fo:block-container>
>>
>> Try putting a fo:block in between those two fo:block-containers, and
>> you'll also see what I mean by 'no intrusions' higher up. That block would
>> just overlap with the text-box at the top.
>>
>> Also, unless it is really needed for some reason (special text-effects,
>> rotations, transformations...), I would try to cut out SVG and work as much
>> in pure XSL-FO as possible.
>>
>> HTH!
>>
>> Regards,
>>
>> Andreas
>> ---
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [email protected]
>> For additional commands, e-mail: [email protected]
>>
>>
>

Reply via email to