I am deriving a custom control from TVirtualDrawTree and I am overriding the DoPaintBackground
event to draw a background gradient effect for the tree view.
I am also overriding the DoBeforeItemPaint
function so I can custom draw the tree view items. However, I can't quite manage to get the items to paint with a transparent background.
Looking into the source for TVirtualDrawTree, it looks as though the item is copied to a TBitmap image and then copied onto the canvas, however, I have tried editing the source and setting the transparency options on the bitmap itself and it still doesn't seem to be working.
I have also tried clearing the canvas before drawing e.g. Canvas.Brush.Style := bsClear
and filling the item rect but no joy.