On 24/03/2012 20:02, Bernd Kreuss wrote:
I recently updated my ancient Ubuntu Hardy to Oneiric which has
GTK-2.24.6. Now I noticed that the SynEdit in the Lazarus IDE feels
painfully sluggish. If I press a key there is a 0.2 seconds delay until
it updates the screen. If I keep the key pressed (auto-repeat) then xorg
will burn 60% and kernel (IO or something) the remaining 40% of my CPU.
It gets worse the bigger the editor window is (maximize window for
maximum pain).

Although one could argue that a Pentium-M (1 core at 1.3GHz) is not the
fastest CPU I am not yet willing to throw away my good old thinkpad T40
which has served me so well for such a long time.

It does not happen if I use the Qt widgetset (but I rather do not want
to use Qt but if this can't be fixed then I will have to, otherwise it
is completely unusable, currently it feels like I'm sitting in front a
66MHz 386 from 1990).

I can NOT reproduce it if I create a minimal application with a synedit
and Pascal highlighter on it. I'm unable to reproduce this, no matter
what options I set in my synedit or what highlighter I use and on the


Interesting.

This is without scrolling?

I would reckon that there is unnecessary painting going on (at least it's a possibility). Any none painting code should be the same for QT, so ...

Compile the SynEdit package with the following defines
SynDebug
SynCaretDebug
SYNSCROLLDEBUG
VerboseSynEditInvalidate
SynCheckPaintLock

and get a logfile.

Please also try if switching the overview gutter (right hand site) (Options/Editor/Display) makes a different. IIRC some WS does unnecessary invalidates (but not as bad as you described)

Or switch off highlight of all occurrences of the word under caret (obviously that can lead to a full invalidate, but usually it has a time delay, so it does not affect editing)


--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to