You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by "Peter B. West" <pb...@powerup.com.au> on 2001/05/02 05:58:33 UTC

Area tree again

Arved et al.,

I'm still a bit of an area tree skeptic, I'm afraid.  I just seems to me
that the area tree is one step too far removed from the renderer.  A
tree of some kind makes sense, but surely it should be flattened as much
as possible before rendering?

The idea of flattening the tree comes from the discussion of bidi
processing in the spec. (5.8)  In order to apply the algorithm, the text
has to be converted into a flattened sequence.

For rendering generally, once all of the layout decisions have been
made, doesn't it make sense to have the flattest possible
representation:  a sequence of pages, each of which has a series of
layers (z-indexed), each of which contains a sequence of absolutely
positioned elements?  Doesn't "layout" imply such a flattening?  In the
case of text glyphs, it probably makes sense to specify these as
absolutely positioned line areas, or line area fragments, where the
fragment shares font characteristics, including baseline.  Isn't that
effectively the way text was originally represented in FOP for rendering
in PDF - runs of text?

I'm not just trying to be difficult here, but I am looking for the
appropriate internal representations for the transformations that have
to be done before the renderer can start putting marks on paper.

Peter
-- 
Peter B. West  pbwest@powerup.com.au  http://powerup.com.au/~pbwest
"Lord, to whom shall we go?"

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org


Re: Area tree again

Posted by Karen Lease <kl...@club-internet.fr>.
Hi guys,

First, I wanted to let Peter know that I have read his long post from
last week commenting on my "new architecture" and that most of his ideas
are pretty much in line with my thinking, although I'm still turning
over a lot of stuff in my head.

Maybe this flattening idea is another candidate for the new architecture
discussion. I've certainly often thought that it would be a lot easier
to make break decisions if we didn't have so many (potentially) levels
in the area tree. In fact, calculating the effective space specifier in
those situations is one of those hard things we have to solve.

But every time I tried to imagine building an Area sequence rather than
a tree, I came up against the problem of borders and padding being
attached to Areas at different levels. So if I just put LineAreas in the
sequence, I have to have some way to know which background, border and
padding to draw when and where. I never made a breakthrough with that,
but I'm willing to believe there's one to be made.

Regards,
Karen

"Peter B. West" wrote:
> 
> Arved Sandstrom wrote:
> >
> > OK, we were on completely different planets before. :-) I had no idea that
> > you were worrying at the idea of "tree".
> 
> Arved,
> 
> Same planet.  This is a new worry.  I worry a lot.
> 
> > Short answer is, I don't believe that we are married to the concept that the
> > final result of the formatter must actually be a tree, per se. Obviously the
> > renderers expect that at the moment, but that's just how things are.
> >
> > Everything like this is on the table. I am personally not convinced, for
> > example, that after objectification and refinement that the _FO_ tree needs
> > to be a real tree.
> 
> Do you have any further ruminations about this?
> 
> > Regards,
> > Arved
> 
> Peter
> --
> Peter B. West  pbwest@powerup.com.au  http://powerup.com.au/~pbwest
> "Lord, to whom shall we go?"
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
> For additional commands, email: fop-dev-help@xml.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org


Re: Area tree again

Posted by "Peter B. West" <pb...@powerup.com.au>.
Arved Sandstrom wrote:
> 
> OK, we were on completely different planets before. :-) I had no idea that
> you were worrying at the idea of "tree".

Arved,

Same planet.  This is a new worry.  I worry a lot.

> Short answer is, I don't believe that we are married to the concept that the
> final result of the formatter must actually be a tree, per se. Obviously the
> renderers expect that at the moment, but that's just how things are.
> 
> Everything like this is on the table. I am personally not convinced, for
> example, that after objectification and refinement that the _FO_ tree needs
> to be a real tree.

Do you have any further ruminations about this?

> Regards,
> Arved

Peter
-- 
Peter B. West  pbwest@powerup.com.au  http://powerup.com.au/~pbwest
"Lord, to whom shall we go?"

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org


Re: viewBox

Posted by Karen Lease <kl...@club-internet.fr>.
Now it's committed. It seems to work with my dia sequence diagram!

-Karen

Jeroen de Zwart wrote:
> 
> Almost all of the patches were committed except ONE. the patch for SVG.java
> without it the viewbox does not do a thing!
> 
> Hope anybody can commit it, so everybody can enjoy svg in fop.
> 
> ----- Original Message -----
> From: "Karen Lease" <kl...@club-internet.fr>
> To: <fo...@xml.apache.org>
> Sent: Wednesday, May 02, 2001 11:19 PM
> Subject: Re: viewBox
> 
> > Hi Alex,
> >
> > I can't remember if Aaron's patch was every committed. But I was trying
> > to import SVG generated by the "dia" tool and the viewBox it is using
> > isn't working right. From a quick look at the SVGRenderer code, I'd say
> > the current implementation is quite partial. However, as I understand it
> > (which could easily be wrong, as I'm quite a novice at SVG) viewBox on
> > the top level svg element defines a kind of automatic transformation
> > (scaling, translation). It doesn't really seem designed for clipping,
> > although I guess if the svg coordinates are outside the viewbox, it
> > should probably clip too.
> >
> > HTH,
> > Karen
> >
> > Alex McLintock wrote:
> > >
> > > Hi folks,
> > >
> > > I see from the demo examples that viewBox seems to be doing something -
> > > but I was hoping to use it to clip some SVG objects and it doesn't seem
> to work
> > > (or do what I expected).
> > >
> > > Can anyone say whether it is working correctly ?
> > >
> > > I asked a similar question a couple of months ago and Aaron said he had
> submitted
> > > a patch for viewBox... Has it been committed?
> > >
> > > Alex
> > >
> > > ----------------
> > >
> > > Subject:  Re: [fop-dev] SVG Clipping
> > > From:     Aaron Optimizer Digulla <di...@hepe.com>
> > > Date:     2001-01-29 13:21:46
> > > [Download message RAW]
> > >
> > > On Mon, Jan 29, 2001 at 04:33:08AM -0800, Alex McLintock wrote:
> > >
> > > > Hi folks,
> > > >
> > > > We've just started using SVG style images instead of bitmap images but
> seem to have
> > > > problems with clipping. The source code suggests this is work in
> progress.
> > >
> > > The bigger problem is scaling :-) I have yet to find a way to make
> > > the same SVG look the same in Batik and FOP :-( The biggest
> > > problem is that FOP doesn't support the viewBox attribute. I've
> > > created a patch and posted it but it didn't show up in the CVS,
> > > yet.
> > >
> > > Without this, you cannot specify which part of the SVG should
> > > show up where (ie. you will not see the correct portion
> > > of the SVG and you won't get the correct size).
> > >
> > > Question: What base unit is FOP using when I don't specify one ?
> > > Ie. how large will this rectangle be ?
> > >
> > >     <svg width="5cm" height="5cm">
> > >         <g>
> > >             <rect x="0" y="0" width="10" height="10"/>
> > >         </g>
> > >     </svg>
> > >
> > > =====
> > > Alex McLintock        alex@OWAL.co.uk
> > > OpenWeb Analysts Ltd, http://www.OWAL.co.uk/
> > > COMPETITION:
> http://www.diversebooks.com/cgi-bin/caption/captions.cgi?date=200104
> > > Get Your XML T-Shirt <t-shirt/> at http://www.inversity.co.uk/
> > >
> > > ____________________________________________________________
> > > Do You Yahoo!?
> > > Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
> > > or your free @yahoo.ie address at http://mail.yahoo.ie
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
> > > For additional commands, email: fop-dev-help@xml.apache.org
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
> > For additional commands, email: fop-dev-help@xml.apache.org
> 
>   ------------------------------------------------------------------------
>                      Name: viewBox3.patch
>    viewBox3.patch    Type: unspecified type (application/octet-stream)
>                  Encoding: 7bit
> 
>   ------------------------------------------------------------------------
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
> For additional commands, email: fop-dev-help@xml.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org


Re: viewBox

Posted by Jeroen de Zwart <fa...@dds.nl>.
Almost all of the patches were committed except ONE. the patch for SVG.java
without it the viewbox does not do a thing!

Hope anybody can commit it, so everybody can enjoy svg in fop.

----- Original Message -----
From: "Karen Lease" <kl...@club-internet.fr>
To: <fo...@xml.apache.org>
Sent: Wednesday, May 02, 2001 11:19 PM
Subject: Re: viewBox


> Hi Alex,
>
> I can't remember if Aaron's patch was every committed. But I was trying
> to import SVG generated by the "dia" tool and the viewBox it is using
> isn't working right. From a quick look at the SVGRenderer code, I'd say
> the current implementation is quite partial. However, as I understand it
> (which could easily be wrong, as I'm quite a novice at SVG) viewBox on
> the top level svg element defines a kind of automatic transformation
> (scaling, translation). It doesn't really seem designed for clipping,
> although I guess if the svg coordinates are outside the viewbox, it
> should probably clip too.
>
> HTH,
> Karen
>
> Alex McLintock wrote:
> >
> > Hi folks,
> >
> > I see from the demo examples that viewBox seems to be doing something -
> > but I was hoping to use it to clip some SVG objects and it doesn't seem
to work
> > (or do what I expected).
> >
> > Can anyone say whether it is working correctly ?
> >
> > I asked a similar question a couple of months ago and Aaron said he had
submitted
> > a patch for viewBox... Has it been committed?
> >
> > Alex
> >
> > ----------------
> >
> > Subject:  Re: [fop-dev] SVG Clipping
> > From:     Aaron Optimizer Digulla <di...@hepe.com>
> > Date:     2001-01-29 13:21:46
> > [Download message RAW]
> >
> > On Mon, Jan 29, 2001 at 04:33:08AM -0800, Alex McLintock wrote:
> >
> > > Hi folks,
> > >
> > > We've just started using SVG style images instead of bitmap images but
seem to have
> > > problems with clipping. The source code suggests this is work in
progress.
> >
> > The bigger problem is scaling :-) I have yet to find a way to make
> > the same SVG look the same in Batik and FOP :-( The biggest
> > problem is that FOP doesn't support the viewBox attribute. I've
> > created a patch and posted it but it didn't show up in the CVS,
> > yet.
> >
> > Without this, you cannot specify which part of the SVG should
> > show up where (ie. you will not see the correct portion
> > of the SVG and you won't get the correct size).
> >
> > Question: What base unit is FOP using when I don't specify one ?
> > Ie. how large will this rectangle be ?
> >
> >     <svg width="5cm" height="5cm">
> >         <g>
> >             <rect x="0" y="0" width="10" height="10"/>
> >         </g>
> >     </svg>
> >
> > =====
> > Alex McLintock        alex@OWAL.co.uk
> > OpenWeb Analysts Ltd, http://www.OWAL.co.uk/
> > COMPETITION:
http://www.diversebooks.com/cgi-bin/caption/captions.cgi?date=200104
> > Get Your XML T-Shirt <t-shirt/> at http://www.inversity.co.uk/
> >
> > ____________________________________________________________
> > Do You Yahoo!?
> > Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
> > or your free @yahoo.ie address at http://mail.yahoo.ie
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
> > For additional commands, email: fop-dev-help@xml.apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
> For additional commands, email: fop-dev-help@xml.apache.org

Re: viewBox

Posted by Karen Lease <kl...@club-internet.fr>.
Hi Alex,

I can't remember if Aaron's patch was every committed. But I was trying
to import SVG generated by the "dia" tool and the viewBox it is using
isn't working right. From a quick look at the SVGRenderer code, I'd say
the current implementation is quite partial. However, as I understand it
(which could easily be wrong, as I'm quite a novice at SVG) viewBox on
the top level svg element defines a kind of automatic transformation
(scaling, translation). It doesn't really seem designed for clipping,
although I guess if the svg coordinates are outside the viewbox, it
should probably clip too.

HTH,
Karen

Alex McLintock wrote:
> 
> Hi folks,
> 
> I see from the demo examples that viewBox seems to be doing something -
> but I was hoping to use it to clip some SVG objects and it doesn't seem to work
> (or do what I expected).
> 
> Can anyone say whether it is working correctly ?
> 
> I asked a similar question a couple of months ago and Aaron said he had submitted
> a patch for viewBox... Has it been committed?
> 
> Alex
> 
> ----------------
> 
> Subject:  Re: [fop-dev] SVG Clipping
> From:     Aaron Optimizer Digulla <di...@hepe.com>
> Date:     2001-01-29 13:21:46
> [Download message RAW]
> 
> On Mon, Jan 29, 2001 at 04:33:08AM -0800, Alex McLintock wrote:
> 
> > Hi folks,
> >
> > We've just started using SVG style images instead of bitmap images but seem to have
> > problems with clipping. The source code suggests this is work in progress.
> 
> The bigger problem is scaling :-) I have yet to find a way to make
> the same SVG look the same in Batik and FOP :-( The biggest
> problem is that FOP doesn't support the viewBox attribute. I've
> created a patch and posted it but it didn't show up in the CVS,
> yet.
> 
> Without this, you cannot specify which part of the SVG should
> show up where (ie. you will not see the correct portion
> of the SVG and you won't get the correct size).
> 
> Question: What base unit is FOP using when I don't specify one ?
> Ie. how large will this rectangle be ?
> 
>     <svg width="5cm" height="5cm">
>         <g>
>             <rect x="0" y="0" width="10" height="10"/>
>         </g>
>     </svg>
> 
> =====
> Alex McLintock        alex@OWAL.co.uk
> OpenWeb Analysts Ltd, http://www.OWAL.co.uk/
> COMPETITION: http://www.diversebooks.com/cgi-bin/caption/captions.cgi?date=200104
> Get Your XML T-Shirt <t-shirt/> at http://www.inversity.co.uk/
> 
> ____________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
> or your free @yahoo.ie address at http://mail.yahoo.ie
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
> For additional commands, email: fop-dev-help@xml.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org


viewBox

Posted by Alex McLintock <al...@yahoo.com>.
Hi folks, 

I see from the demo examples that viewBox seems to be doing something - 
but I was hoping to use it to clip some SVG objects and it doesn't seem to work 
(or do what I expected).

Can anyone say whether it is working correctly ?

I asked a similar question a couple of months ago and Aaron said he had submitted 
a patch for viewBox... Has it been committed?

Alex


----------------



Subject:  Re: [fop-dev] SVG Clipping
From:     Aaron Optimizer Digulla <di...@hepe.com>
Date:     2001-01-29 13:21:46
[Download message RAW]

On Mon, Jan 29, 2001 at 04:33:08AM -0800, Alex McLintock wrote:

> Hi folks, 
> 
> We've just started using SVG style images instead of bitmap images but seem to have
> problems with clipping. The source code suggests this is work in progress.

The bigger problem is scaling :-) I have yet to find a way to make
the same SVG look the same in Batik and FOP :-( The biggest
problem is that FOP doesn't support the viewBox attribute. I've
created a patch and posted it but it didn't show up in the CVS,
yet.

Without this, you cannot specify which part of the SVG should
show up where (ie. you will not see the correct portion
of the SVG and you won't get the correct size).

Question: What base unit is FOP using when I don't specify one ?
Ie. how large will this rectangle be ?

    <svg width="5cm" height="5cm">
        <g>
            <rect x="0" y="0" width="10" height="10"/>
        </g>
    </svg>


=====
Alex McLintock        alex@OWAL.co.uk
OpenWeb Analysts Ltd, http://www.OWAL.co.uk/ 
COMPETITION: http://www.diversebooks.com/cgi-bin/caption/captions.cgi?date=200104
Get Your XML T-Shirt <t-shirt/> at http://www.inversity.co.uk/

____________________________________________________________
Do You Yahoo!?
Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
or your free @yahoo.ie address at http://mail.yahoo.ie

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org


Re: Area tree again

Posted by Arved Sandstrom <Ar...@chebucto.ns.ca>.
At 01:58 PM 5/2/01 +1000, Peter B. West wrote:
>Arved et al.,
>
>I'm still a bit of an area tree skeptic, I'm afraid.  I just seems to me
>that the area tree is one step too far removed from the renderer.  A
>tree of some kind makes sense, but surely it should be flattened as much
>as possible before rendering?

[ Lots of good stuff ]

OK, we were on completely different planets before. :-) I had no idea that 
you were worrying at the idea of "tree".

Short answer is, I don't believe that we are married to the concept that the 
final result of the formatter must actually be a tree, per se. Obviously the 
renderers expect that at the moment, but that's just how things are.

Everything like this is on the table. I am personally not convinced, for 
example, that after objectification and refinement that the _FO_ tree needs 
to be a real tree.

Regards,
Arved

P.S. For folks who are peripherally following, and just getting a handle on 
the spec, all of the trees are conceptual. We also, in FOP, have real 
implementation trees.

Fairly Senior Software Type
e-plicity (http://www.e-plicity.com)
Wireless * B2B * J2EE * XML --- Halifax, Nova Scotia


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-dev-unsubscribe@xml.apache.org
For additional commands, email: fop-dev-help@xml.apache.org