On Friday 23 February 2007 19:37, Pierre Héroux wrote:
> I was using Fop 0.25 as the basis for an application in which I wrote
> a new Renderer for a specific output format.
> This renderer (extends AbstractRenderer) needed to compute the
> absolute position and position in an x/y coordinate system for every
> area (Block, LineArea, WordArea...)
> It used the following fields and method (currentXPosition,
> currentYPosition, getHeight(), getContentWidth()...)
>
> I now try make my application compliant with fop 0.93. So I have to
> rewrite my renderer but many of this information is not available any
> more.
>
> I tried to rebuild the needed information by using getIPD() and
> getBPD(), but i did not succeed. For example the renderWord(WordArea
> word) method
> getIPD() and getBPD() return 0.
>
> Any hints for having the absolute position and dimension for every
> Area ?

You have to keep track of the absolute position within your renderer.

Have a look at an existing renderer, for example the AFP renderer 
(org.apache.fop.render.afp.AFPRenderer) which needs a lot of absolute 
positioning internally, and see how the currentIPPosition / 
currentBPPosition variables are maintained.

Manuel

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to