c# Custom ListView Control - Painting of Custom Header is awfully slow
Posted on 2004-04-23
I have derived a custom ListView in C# and I draw a custom Header(Native Window).
(I draw multi line strings in the headers - not provided by Native ListView)
I am drawing the header seperation lines and the header text in WM_DRAWITEM message where ctrltype is ODT_HEADER
Everything works fine. But when I fit the columns, the custom drawing happens visibly and it is slow and looks awkward.
I want the drawing of the custom header to happen only on EndUpdate.
(It happens when I am specifying the widths of the columns
ie., I am saying listview.columns(1).width = -1 for fitting data and the painting happens then)
Help Experts. Please help...
Thanks in advance