--- Tomas Frydrych <[EMAIL PROTECTED]> wrote:
> 
> Hi Joaquin,
> 
> > Indeed, this 100 times factor is quite important,
> because we end
> > calling some fp_Run methods (for each run in each
> line).  We have
> > ~25.6 runs by line, so that means that we call
> 2560 times some fp_Run
> > methods.
> 
> I guess your document has the text in it justified?

No, AFAIR the text was right ragged (only left
aligned).

> In non-justified text 
> we only have 1 run per line if the formatting is
> consisten across the 
> line;

I was seeing 1 run per word + 1 run per space, so ~2
runs per word on left aligned text (I will double
check it when I will be back at home).

> in justified text we have two runs per word. I
> think it should be 
> straight forward to improve the hanling of justified
> text so that in the 
> TextRun we would keep a vector of pair of numbers
> {offset,length} 
> which would indicate where in the run chunks of
> spaces start and 
> how long they are, and we could draw then our run in
> segments, 
> advancing the drawing point over the spaces. This
> would save us lot 
> of memory and processing time for justified text,
> costing only 4 extra 
> bytes per textrun in non-justified paragraph.

Something like that may help, but take in account that
our problems comes (AFAICS) from a x1000 times factor
on the number of runs (the x100 times factor is what I
explained in my last email, the 10 times remaining
seems to be due to just little stupid errors).

If you're able to reduce the runs to ~1 run by line I
will rerun the tests and see how it affects speed.

Cheers,



=====
Joaquin Cuenca Abela
[EMAIL PROTECTED]

__________________________________________________
Do You Yahoo!?
Yahoo! Health - Feel better, live better
http://health.yahoo.com

Reply via email to