On Fri, 28 Jul 2017 13:31:13 +0300 Alexey via Lazarus <lazarus@lists.lazarus-ide.org> wrote:
> Problem: CudaText editor opens 400K file at the end, syntax parser is > slow, I hold "d" char. expected: "d" or "d"*n chars appears from time to > time. Eg each 1-2 seconds. Seen: > "ddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddd" > > chars appears each 5-6 seconds. Not ok. > > Maybe LCL don't call Paint method during holding a key (if component > paints slowly)? How to solve it? Or i must force repaint to canvas each > 1-2 seconds (not all platforms support it, Mac don't). A forced repaint will only decrease the responsiveness of your application even more. If the syntax parser is so slow, the first thing to do is to *not* call it after every key stroke. Call it on idle or in OnPaint. Mattias -- _______________________________________________ Lazarus mailing list Lazarus@lists.lazarus-ide.org https://lists.lazarus-ide.org/listinfo/lazarus