<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:Calibri
}
--></style></head>
<body class='hmmessage'><div dir='ltr'>Have you tried wrapping your writes in<BR> <BR>memo1.Lines.BeginUpdate and memo1.Lines.BeginUpdate?<br> <BR><div><div id="SkyDrivePlaceholder"></div>> Date: Mon, 29 Apr 2013 18:34:07 +0200<br>> From: juergen.hestermann@gmx.de<br>> To: lazarus@lists.lazarus.freepascal.org<br>> Subject: [Lazarus] TMemo flicker<br>> <br>> After having moved from TStringList over TStringGrid (which both cannot be shifted right to make long text visible) I now use TMemo. But again I have another issue with this component: If there are more rows than can be displayed in the window and I change the text in the last row (Lines.Count-1) rapidly then the whole display flickers. This OnClick event demonstrates it:<br>> <br>> -------------------------------------------------------<br>> with Memo1 do<br>> begin<br>> for i := 1 to 40 do<br>> begin<br>> if odd(i) then<br>> Append('\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\')<br>> else<br>> Append('+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++');<br>> end;<br>> for i := 1 to 1000 do<br>> begin<br>> Lines[Lines.Count-1] := '#### LAST LINE ---'+IntToStr(i)+'-----------------------------------------------------------';<br>> Application.Processmessages;<br>> end;<br>> Memo1.Lines[Lines.Count-1] := '#### READY #### ';<br>> end;<br>> -------------------------------------------------------<br>> <br>> When you click on the memo (so that the routine runs) and the window is small enough then all lines are shifted down for a short time and then are shifted up again when writing to Memo1.Lines[Lines.Count-1]. This flicker is quite disturbing and it does not happen when there are only a few lines (which fit in the window). Is this a known bug?<br>> <br>> <br>> --<br>> _______________________________________________<br>> Lazarus mailing list<br>> Lazarus@lists.lazarus.freepascal.org<br>> http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus<br></div> </div></body>
</html>