Delphi XE2 listview artifacts

杀马特。学长 韩版系。学妹 提交于 2019-12-17 16:57:09

问题


I am using listview in vsreport virtual mode, have two columns and after I populate the list, select one row, and then select some other row there's an artifact left on a previously selected row, see image below. How to fix this?

and this is my code that gets the data from an array

procedure TForm1.ListView1Data(Sender: TObject; Item: TListItem);
begin
  Item.Caption := FloatToStr(Item.Index + 1);
  Item.SubItems.Add(FloatToStr(a[Item.Index]));
end;

When I hover the mouse, the artifacts dissapear. Thanks


回答1:


Setting the listview's DoubleBuffered property to true solves the artifacts problem.



来源:https://stackoverflow.com/questions/15487136/delphi-xe2-listview-artifacts

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!