John Levon wrote:
This looks to be very silly indeed, so I guess I'm missing something.
Why are we calling update(text) directly several times for one "lfun" ?
Can we not just post the update, and then call it *once* at the end of
handling the lfun (and at the end of handleKeypress and a couple of
other spots I guess).

It looks to me currently like we do an awful lot of unnecessary
redrawing for no good reason ?

I don't understand code like this :

    400         bv->update(text, BufferView::SELECT | BufferView::FITCUR);
    401         text->toggleFree(font, toggleall);
    402         bv->update(text, BufferView::SELECT | BufferView::FITCUR | 
BufferView::CHANGE);

Is this related to CHANGED_IN_DRAW ? (and if so, how ...)

This code is related to "selections" and their redraw/drawing, it doesn't do that much actually have a better look at the update function and you'll see that actually most of this calls don't do that much.

I explain you also why one update won't work because then we would have
to do "full redraw" as Andre tell's us always. I think that full redraw
was normal at the beginning, but it was (and IMO it still would be) way
too slow when someone is typing fast!

I didn't finish my explanation above ;), if we don't do a "full redraw"
we have to "clear the selection first" then do the change, and after that
"redraw the selection" as otherwise we would have drawing glitches and blue
selection rectangles in spots where they should not be.

Jug

--
-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._
Dr. Jürgen Vigna        E-Mail:  [EMAIL PROTECTED]
Mitterstrich 151/A
I-39050 Steinegg        Web:     http://www.lyx.org/~jug
-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._-._



Reply via email to