Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2012-02

SynEdit painting while paintlocked

2 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Graeme Geldenhuys

Hi,

I got a lazarus update this morning, and rebuilt the IDE via the Tools menu. While it was compiling, I was scrolling the editor window. Then suddenly the IDE froze up! Luckily I ran the IDE from a console window, and saw the following warning message. In the end I had to kill the Lazarus process.

----------------------------------
...
Compiling showdeletingfilesdlg.pas
Compiling compatibilityrestrictions.pas
Compiling restrictionbrowser.pas
Compiling projectwizarddlg.pas
Compiling resource ../units/x86_64-linux/lazarus.or Linking /opt/lazarus/lazarus
/usr/bin/ld: warning: /opt/lazarus/link.res contains output sections; did you forget -T?
268290 lines compiled, 26.9 sec
Warning: SynEdit.Paint called during PaintLock

----------------------------------

Regards, ? - Graeme - _______________________________________________ fpGUI - a cross-platform Free Pascal GUI toolkit http://fpgui.sourceforge.net

Reply by email

Martin
to Graeme Geldenhuys
Graeme Geldenhuys wrote 7 lines
Hi, I got a lazarus update this morning, and rebuilt the IDE via the Tools menu. While it was compiling, I was scrolling the editor window. Then suddenly the IDE froze up! Luckily I ran the IDE from a console window, and saw the following warning message. In the end I had to kill the Lazarus process.

...

Warning: SynEdit.Paint called during PaintLock

This is a recoverable message (and unfortunately, not helping to trace the hang problem). It doesn't even indicate if the issue is in SynEdi or not...

Something called "SynEdit.BeginUpdate", and either did not call EndUpdate or did call ProcessMessages.

While in an "Update" SynEdit can not paint (BeginUpdate is to speed up things, so it defers all updates, like highlighter scan, until all changes are done. This avoids doing the work over and over again) If SynEdit gets a pain event in Paintlock it just paints the area blank, and remembers it. On EndUpdate, it will issue an Invalidate to fix the situation.

So it is not clear who called the BeginUpdate.
It is also not clear if this was cause or reaction.

Reply by email