HI Bill,

> It may be a good idea to figure out why this is so slow.

I've lost the context on this, but I *think* we are talking about text
manipulation on OSX?

> Apparently 
> *drawing* the text is reasonable, it is only the measurement that is 
> slow? That implies this can be fixed somehow.

Umm, I'm not sure that's quite correct; my experience with (OSX) 10.3
and 10.4 on PPC suggested that it was slow to render text, and slow to
measure the text too.
I think Manolo's patch is caching part of that problem away (the measure
part) to gain speed.

Also (and I have no robust evidence for this) our practice of measuring
and rendering by char seems to exacerbate the OSX slowness, so measuring
and rendering whole strings, or at least whole words, might conceivably
be faster.

I always suspected (at least under 10.4) that it was the decision (well,
I say decision, but it was more just something I did in passing) to turn
on OSX's auto-font-substitution mechanism that made things slow, though.
(That said, font handling is different under Cocoa than Quartz, so that
may no longer be relevant...)


> The fltk2.0 drawing code scrapped all uses of "measure 1 
> character", and 
> instead has a function to get the width of a block of UTF-8. 
> It was not 
> hard to make the text editor use this only.

In general, I think I'd like it if we could render whole words, or even
whole lines, as that would allow us to leverage the host system for
kerning and so forth, which our char-by-char approach does not really
grok.
It could make RtoL text and Bi-dir text easier too, I think...

-- 
Ian




SELEX Galileo Ltd
Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 
3EL
A company registered in England & Wales.  Company no. 02426132
********************************************************************
This email and any attachments are confidential to the intended
recipient and may also be privileged. If you are not the intended
recipient please delete it from your system and notify the sender.
You should not copy it or use it for any purpose nor disclose or
distribute its contents to any other person.
********************************************************************

_______________________________________________
fltk-dev mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-dev

Reply via email to