I'm not sure exactly what you mean--are you indicating
it might be best to pull out the interators from
FOText and flow.Inline and have everything done within
flow.Block?  That could work well.

A further optimization might be to do all this before
the Block is even parsed into FOText and Inline
objects, as many spaces-only objects would end up not
even needing to be created.

I was originally thinking of the other
direction--instead of all the bouncing code between
Block and FOText, just put all the logic in FOText,
and have FOText completely responsible for its own
whitespace removal.  Problem with this though is that
we'd have to duplicate the whitespace processing logic
into Inline as well, also, there's the issue of
whitespace between consecutive FOText and/or Inline
objects still needing to be handled.  So this probably
wouldn't be a good idea.

Thanks,
Glen


--- Simon Pepping <[EMAIL PROTECTED]> wrote:
> I should add that I have realized that the rules of
> whitespace
> handling in the FO spec are quite complicated, and
> that it is unwise
> to handle whitespace outside of the
> Block.handleWhiteSpace method.
> 
> Regards, Simon
> 
> -- 
> Simon Pepping
> home page: http://www.leverkruid.nl
> 

Reply via email to