On Thu, Mar 18, 2010 at 11:47 PM, rgheck <rgh...@bobjweil.com> wrote:
>
> And adding the list here, too....
>
> On 03/18/2010 05:22 PM, Dov Feldstern wrote:
>>
>> On Thu, Mar 18, 2010 at 5:48 PM, rgheck<rgh...@comcast.net>  wrote:
>> .
>> .
>>
>>> I'm guessing that this is the cause of the problem.
>>>
>>>
>>> Where ought the position to have been set?
>>>
>>>
>> I'm not sure I understand this question... Isn't the real question:
>> why have the metrics not been calculated?
>>
>>
> Yes, pretty much, though some of the other metrics have been calculated,
> from what I can tell. We end up in redoParagraph, which sets lots of things.
> But not position.
>
>> Mmmm, reading your description again, could this be an answer to my
>> question: if the cursor is in par 58, and then par 58 is scrolled off
>> the screen (but the cursor is still in it!), so then since par 58 is
>> not painted (it's off the screen) no metrics have been calculated for
>> it.
>>
>>
> Yes, that's right. So does the attached make sense? It seems to solve it for
> me, but I have no idea what it does to the RTL stuff.
>

I don't remember: is it correct that boundary only affect the cursor's display?

If so, and if we're correct that the metrics will not exist only when
the cursor's paragraph is off the screen, then your fix would seem to
be safe...

But then the question is: why is a function which only affects the
cursor's display being called when the cursor is off the screen? In
other words, if our above assumptions are correct, then the function
should not actually be called at all when we're off the screen --- but
it is...

So, in order to figure this out, I added the debug prints mentioned
above, and then I noticed that only when we're at the end of a word,
but not anywhere else, then a line is printed every time the cursor
blinks --- whether or not the cursor is on the screen. And that's also
the only time when we see the error occur, when the paragraph is moved
off the screen (so it's the end of a word that matters, not a word
that has a completion, as someone mentioned somewhere). In other
words: something is causing isRTLBoundary to be called every time the
cursor blinks when it is at the end of the word, even if it is off the
screen, and the first time that that happens, there are no metrics!
It's 100% reproducible this way: create a document with just enough
paragraphs such that the last one can be scrolled entirely off the
screen. Now, stand at the end of any word in the paragraph. you'll see
a line printed every cursor blink. Now, if you scroll, then as soon as
the paragraph is entirely off the screen, there'll be a single
printout which says "empty", and then again printouts which have the
metrics...

I have no idea what this means yet, but thought this is interesting
information...

Dov

Reply via email to